账户
大约 1 分钟
账户
获取账户信息
POST
https://services.tokenview.io/vipapi/trx/accounts/getaccount?apikey={apikey}
参数
- {address}:string, base58或者hex格式的地址;
- {visible}: boolean, 可选项,默认true,和address配套使用。当address为base58格式时,visible必须为true,当address为hex格式时,visible必须为false;
- {trc20only}:int,可选项,默认1,1表示只返回trc20字段。trc20only的值为1或者0,1表示只返回trc20字段,0表示返回trc20字段和HTTP API getaccount的值;
- {apikey}: 可在Tokenview API 后台管理系统获取激活状态的 APIKEY: https://services.tokenview.io
Request
curl --location https://services.tokenview.io/vipapi/trx/accounts/getaccount?apikey={apikey} -X POST -H "Content-Type: application/json" -d '{"address":"TQopP5GM68QoqLzpz8YReDfSoCMkvwcZYd","trc20only":0,"visible":true}'
Response
{
"code": 1,
"msg": "成功",
"enMsg": "SUCCESS",
"data": {
"owner_permission": {
"keys": [
{
"address": "TQopP5GM68QoqLzpz8YReDfSoCMkvwcZYd",
"weight": 1
}
],
"threshold": 1,
"permission_name": "owner"
},
"account_resource": {
"energy_window_optimized": true,
"acquired_delegated_frozenV2_balance_for_energy": 25665000000,
"latest_consume_time_for_energy": 1709040171000,
"energy_window_size": 28800000
},
"active_permission": [
{
"operations": "7fff1fc0033e0300000000000000000000000000000000000000000000000000",
"keys": [
{
"address": "TQopP5GM68QoqLzpz8YReDfSoCMkvwcZYd",
"weight": 1
}
],
"threshold": 1,
"id": 2,
"type": "Active",
"permission_name": "active"
}
],
"asset_optimized": true,
"address": "TQopP5GM68QoqLzpz8YReDfSoCMkvwcZYd",
"create_time": 1675943526000,
"latest_consume_time": 1718689491000,
"acquired_delegated_frozenV2_balance_for_bandwidth": 26956000000,
"latest_opration_time": 1718689491000,
"free_asset_net_usageV2": [
{
"value": 0,
"key": "1004944"
},
{
"value": 0,
"key": "1004977"
},
{
"value": 0,
"key": "1004920"
},
{
"value": 0,
"key": "1004952"
}
],
"is_witness": true,
"assetV2": [
{
"value": 17777776,
"key": "1004944"
},
{
"value": 8888880000,
"key": "1004977"
},
{
"value": 65555552,
"key": "1004920"
},
{
"value": 35400,
"key": "1004952"
}
],
"frozenV2": [
{
},
{
"type": "ENERGY"
},
{
"type": "TRON_POWER"
}
],
"balance": 1009496,
"trc20": [
{
"network": "TRX",
"hash": "TDR4CqUi3VoCqb8CUmhN2wwpvd1wVRMjYG",
"tokenInfo": {
"h": "TDR4CqUi3VoCqb8CUmhN2wwpvd1wVRMjYG",
"f": "TSW Token",
"s": "TSWT",
"d": "18",
"c": "TRC20"
},
"transferCnt": 1,
"balance": "1000000000000000000000000",
"spendTransferCnt": 0,
"receiveTransferCnt": 1
},
{
"network": "TRX",
"hash": "TVh4nokXoSxQGxh7T6Tn6NTb2uSUhAhLwb",
"tokenInfo": {
"h": "TVh4nokXoSxQGxh7T6Tn6NTb2uSUhAhLwb",
"f": "fenergy.fun",
"s": "fenergy.fun",
"d": "6",
"c": "TRC20"
},
"transferCnt": 1,
"balance": "43041000000",
"spendTransferCnt": 0,
"receiveTransferCnt": 1
}
],
"latest_consume_free_time": 1680697932000,
"account_name": "cryptoAI",
"net_window_size": 28800000,
"net_window_optimized": true,
"witness_permission": {
"keys": [
{
"address": "TQopP5GM68QoqLzpz8YReDfSoCMkvwcZYd",
"weight": 1
}
],
"threshold": 1,
"id": 1,
"type": "Witness",
"permission_name": "witness"
}
}
}