开源免费 TRON 波场区块链 API 接口服务
支持钱包生成 · 余额查询 · TRX/USDT 转账 · 助记词转换 · 交易记录查询
Base URL:https://tronapi.net
🔓 全部接口免费开放,无需注册即可调用
GET /api/address/generate
curl https://tronapi.net/api/address/generate返回:
{"success":true,"data":{"result":"成功","privatekey":"64位hex私钥","wallet":"T开头地址"}}GET /api/mnemonic/generate
curl https://tronapi.net/api/mnemonic/generate返回:
{"success":true,"data":{"result":"成功","mnemonic":"word1 word2 ... word12"}}POST /api/mnemonic/recover
curl -X POST https://tronapi.net/api/mnemonic/recover \
-H "Content-Type: application/json" \
-d '{"mnemonic":"abandon ability able ..."}'POST /api/mnemonic/to-private-key
curl -X POST https://tronapi.net/api/mnemonic/to-private-key \
-H "Content-Type: application/json" \
-d '{"mnemonic":"word1 word2 ... word12"}'POST /api/address/from-private-key
curl -X POST https://tronapi.net/api/address/from-private-key \
-H "Content-Type: application/json" \
-d '{"private_key":"64位hex私钥"}'POST /api/balance/trx
curl -X POST https://tronapi.net/api/balance/trx \
-H "Content-Type: application/json" \
-d '{"address":"TPhh7UeRf4h6SaU69RqQdRepT3sDHKVTUC"}'返回:
{"success":true,"data":{"result":"成功","address":"Txxx...","balance":"163.331747","unit":"TRX"}}POST /api/balance/trc20
curl -X POST https://tronapi.net/api/balance/trc20 \
-H "Content-Type: application/json" \
-d '{"address":"TPhh7UeRf4h6SaU69RqQdRepT3sDHKVTUC"}'POST /api/transfer/trx
| 参数 | 说明 |
|---|---|
| private_key | 64位hex私钥 |
| to | 收款地址(T开头或41开头) |
| amount | 转账数量(TRX) |
curl -X POST https://tronapi.net/api/transfer/trx \
-H "Content-Type: application/json" \
-d '{"private_key":"你的私钥","to":"收款地址","amount":100}'POST /api/transfer/trc20
| 参数 | 说明 |
|---|---|
| private_key | 64位hex私钥 |
| to | 收款地址(T开头或41开头) |
| amount | 转账数量(USDT) |
curl -X POST https://tronapi.net/api/transfer/trc20 \
-H "Content-Type: application/json" \
-d '{"private_key":"你的私钥","to":"收款地址","amount":100}'POST /api/transaction/trc20
curl -X POST https://tronapi.net/api/transaction/trc20 \
-H "Content-Type: application/json" \
-d '{"address":"Txxx...","limit":50}'POST /api/transaction/by-address
curl -X POST https://tronapi.net/api/transaction/by-address \
-H "Content-Type: application/json" \
-d '{"address":"Txxx...","limit":50}'// 生成钱包
$res = file_get_contents('https://tronapi.net/api/address/generate');
print_r(json_decode($res, true));
// 查余额
$ch = curl_init('https://tronapi.net/api/balance/trx');
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode([
'address' => 'TPhh7UeRf4h6SaU69RqQdRepT3sDHKVTUC'
]));
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Content-Type: application/json']);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
print_r(json_decode(curl_exec($ch), true));- USDT 交易查询:okxcha.com
- 助记词转换工具:bip39.tronapi.org
- GitHub 仓库:github.com/Anonymapi/TronApi