withdrawExchangeTokens

创建一个未签名的交易,用于提取交易对中的代币。

用法

visionWeb.transactionBuilder.withdrawExchangeTokens(
  exchangeId,
  tokenId,
  tokenAmount,
  ownerAddress,
  options
);

入参

参数描述类型默认值
exchangeId交易对 idnumber-
tokenId代币 idstring-
tokenAmount提币数量number0
ownerAddress交易对创建者的地址string默认账户地址
options可选参数,具体参数见下方object-

options 参数

参数描述类型默认值
permissionId设置多重签名时使用number-

返回值

object,创建的 transaction 对象。

示例

visionWeb.transactionBuilder.withdrawExchangeTokens(1,"1000003",100);
> {
  visible: false,
  txID: '0635bb80799f3cc2a73ee6dabd81a68df404c9ecd3c753fe2d2f85a293c55fff',
  raw_data: {
    contract: [ [Object] ],
    ref_block_bytes: 'b53a',
    ref_block_hash: '529136100d100956',
    expiration: 1608553542000,
    timestamp: 1608553482954
  },
  raw_data_hex: '0a02b53a2208529136100d10095640f0e28caae82e5a65080112610a2d747970652e676f6f676c65617069732e636f6d2f70726f746f636f6c2e5472616e73666572436f6e747261637412300a154653cd48c2723cb985679f4e44d99c64d22d89f41d1215462d7a77f8bef6fe225bf5e353dd6a380f588a1496180a70ca9589aae82e'
}