Coinbase Wallet SDK
eth_getBlockTransactionCountByNumber
Get the number of transactions in a block by block number
Defined in the Ethereum JSON-RPC Specification
Returns the number of transactions in a block by block number.
Parameters
Integer block number, or the string “latest”, “earliest” or “pending”.
Returns
The number of transactions in this block as a hexadecimal string.
Error Handling
Code | Message | Description |
---|---|---|
-32602 | Invalid block parameter | The provided block parameter is invalid |
4100 | Requested method not supported | The method is not supported by the wallet |
This method returns the count of transactions in a specific block identified by its number.