signPsbts

Sign PSBT List

Method

async function signPsbts(
    psbtHex: string, 
    options: { autoFinalized: boolean },
): string[]

Params

  • psbtHexs — required Array<string> the hex string of psbt to sign

  • options — optional object

    • autoFinalized — optional boolean: whether finalize psbt after signing, default is true

Response

signeds — Array<string>

Example

const provider = (window.$onekey && window.$onekey.btc) || window.unisat;

const psbtHexs = ["010203", "010203"]
const signeds = async provider.signPsbts(psbtHexs);

Demo

Last updated