eth_getTransactionCount
网络: BSC · 主网 · Chain ID 56(0x38)
计为 1 个 Request。 计费规则见 Request Counting。
返回某地址已发送的交易数量。
参数
DATA(20 字节)— 地址。QUANTITY|TAG— 区块号,或"latest"、"earliest"、"pending"。
返回
QUANTITY — 该地址已发送交易数。
请求
{
"jsonrpc": "2.0",
"method": "eth_getTransactionCount",
"params": ["0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045", "latest"],
"id": 1
}响应
{
"jsonrpc": "2.0",
"id": 1,
"result": "0x29d"
}代码示例
curl -X POST https://bsc-rpc.blockreq.com/v1/rpc/public \
-H "Content-Type: application/json" \
-d '{"jsonrpc":"2.0","method":"eth_getTransactionCount","params":["0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045","latest"],"id":1}'