sendBitcoin
发送 BTC
方法
async function sendBitcoin(
toAddress: string,
satoshis: number,
options?: { feeRate: number }
): string参数
toAddress— 必填string接收地址satoshis— 必填number发送的聪数options— 可选feeRate— 必填number网络费率
响应
txid — string
示例
const provider = (window.$onekey && window.$onekey.btc) || window.unisat;
const address = "010203"
const txid = async provider.sendBitcoin(address, 1000);
演示
Last updated on