curl --request POST \
--url https://api.uniblock.dev/uni/v1/json-rpc?chainId=43114 \
--header 'content-type: application/json' \
--data '{
"id": 1,
"jsonrpc": "2.0",
"method": "eth_getBlockTransactionCountByNumber",
"params": [
"0x1b4"
]
}'
{
"jsonrpc": "2.0",
"id": 1,
"result": "0x1b"
}
Returns the number of transactions in a block from a block matching the given block number.
curl --request POST \
--url https://api.uniblock.dev/uni/v1/json-rpc?chainId=43114 \
--header 'content-type: application/json' \
--data '{
"id": 1,
"jsonrpc": "2.0",
"method": "eth_getBlockTransactionCountByNumber",
"params": [
"0x1b4"
]
}'
{
"jsonrpc": "2.0",
"id": 1,
"result": "0x1b"
}
eth_getBlockTransactionCountByNumber:params[0]: Block identifier. Can be an integer block number or a string tag: “latest”, “earliest”, or “pending”.“0x1b”.curl --request POST \
--url https://api.uniblock.dev/uni/v1/json-rpc?chainId=43114 \
--header 'content-type: application/json' \
--data '{
"id": 1,
"jsonrpc": "2.0",
"method": "eth_getBlockTransactionCountByNumber",
"params": [
"0x1b4"
]
}'
{
"jsonrpc": "2.0",
"id": 1,
"result": "0x1b"
}
Was this page helpful?