Comment on page
eth_getBlockTransactionCountByNumber
Returns the number of transactions in a block matching the given block number
BLOCK NUMBER |TAG
- hexadecimal representation of a block number, or the string "earliest", "latest" or "pending", as in the default block parameter.QUANTITY
- the number of transactions in this block in hexadecimal formatcurl --location 'https://rpc.eth.gateway.fm' \
--header 'Content-Type: application/json' \
--data '{
"method": "eth_getBlockTransactionCountByNumber",
"params": [
"latest"
],
"id": 1,
"jsonrpc": "2.0"
}'
{
"jsonrpc": "2.0",
"id": 1,
"result": "0x91"
}
Last modified 7mo ago