@bsv/wallet-toolbox
Version:
BRC100 conforming wallet, wallet storage and wallet signer components
50 lines • 1.78 kB
TypeScript
import { Beef, SendWithResult } from '@bsv/sdk';
import { EntityProvenTxReq, sdk, StorageProvider, TableProvenTx, TableProvenTxReq } from '../../index.client';
import { ReviewActionResult } from '../../sdk';
export declare function processAction(storage: StorageProvider, auth: sdk.AuthId, args: sdk.StorageProcessActionArgs): Promise<sdk.StorageProcessActionResults>;
export interface GetReqsAndBeefDetail {
txid: string;
req?: TableProvenTxReq;
proven?: TableProvenTx;
status: 'readyToSend' | 'alreadySent' | 'error' | 'unknown';
error?: string;
}
export interface GetReqsAndBeefResult {
beef: Beef;
details: GetReqsAndBeefDetail[];
}
export interface PostBeefResultForTxidApi {
txid: string;
/**
* 'success' - The transaction was accepted for processing
*/
status: 'success' | 'error';
/**
* if true, the transaction was already known to this service. Usually treat as a success.
*
* Potentially stop posting to additional transaction processors.
*/
alreadyKnown?: boolean;
blockHash?: string;
blockHeight?: number;
merklePath?: string;
}
/**
* Verifies that all the txids are known reqs with ready-to-share status.
* Assigns a batch identifier and updates all the provenTxReqs.
* If not isDelayed, triggers an initial attempt to broadcast the batch and returns the results.
*
* @param storage
* @param userId
* @param txids
* @param isDelayed
*/
export declare function shareReqsWithWorld(storage: StorageProvider, userId: number, txids: string[], isDelayed: boolean): Promise<{
swr: SendWithResult[];
ndr: ReviewActionResult[] | undefined;
}>;
export interface CommitNewTxResults {
req: EntityProvenTxReq;
log?: string;
}
//# sourceMappingURL=processAction.d.ts.map