fundEscrow
Build an unsigned fund transaction for an escrow.
Build an unsigned fund transaction for an escrow.
Import
import { TrustlessWorkClient } from "@trustless-work/escrow-js";Signature
client.rest.fundEscrow(
payload: FundEscrowPayload,
type: EscrowType,
): Promise<BuildTransactionResponse>Returns BuildTransactionResponse: { unsignedXdr, txHash }.
FundEscrowPayload: { contractId, amount, signer }.
Example
import { TrustlessWorkClient, development } from "@trustless-work/escrow-js";
const client = new TrustlessWorkClient({
baseURL: development,
apiKey: process.env.API_KEY,
});
// see signature aboveSee Operate and sendTransaction.