sendToken

创建一个未签名的 TRC10转账交易

用法

tronWeb.transactionBuilder.sendToken(to,amount,tokenID,from,options);

参数

描述

类型

to

转入TRC10 的地址

hexString

amount

转账的TRC10数量

Integer

tokenID

代币的ID

String

from

转出TRC10的可选地址

hexString

options

permission Id

integer

返回

Object

示例

tronWeb.transactionBuilder.sendToken("TVDGpn4hCSzJ5nkHPLetk8KQBtwaTppnkr", 100, "1000086", "TNPeeaaFB7K9cmo4uQpcU32zGK8G1NYqeL");
>{
    "visible": false,
    "txID": "60dc7ab33aadd049509017121ac85e974586c8a6e269df090cdd473ca65c27af",
    "raw_data": {
        "contract": [
            {
                "parameter": {
                    "value": {
                        "amount": 100,
                        "asset_name": "31303030303836",
                        "owner_address": "418840e6c55b9ada326d211d818c34a994aeced808",
                        "to_address": "41d3136787e667d1e055d2cd5db4b5f6c880563049"
                    },
                    "type_url": "type.googleapis.com/protocol.TransferAssetContract"
                },
                "type": "TransferAssetContract"
            }
        ],
        "ref_block_bytes": "0973",
        "ref_block_hash": "0517ef52363f9291",
        "expiration": 1581307599000,
        "timestamp": 1581307540867
    },
    "raw_data_hex": "0a02097322080517ef52363f92914098b19cea822e5a730802126f0a32747970652e676f6f676c65617069732e636f6d2f70726f746f636f6c2e5472616e736665724173736574436f6e747261637412390a07313030303038361215418840e6c55b9ada326d211d818c34a994aeced8081a1541d3136787e667d1e055d2cd5db4b5f6c88056304920647083eb98ea822e"
}