post https://api.infstones.com/starknet/mainnet/
Returns the number of transactions in the designated block.
Parameters
Object Name | Required | Type | Detail |
---|---|---|---|
BLOCK PARAMETER | ✅ | String | "block_hash", "block_number", "latest", "pending" |
"params": [
{
"block_number": 5000
}
]
Result
The number of transactions in the designated block.
Example
Request
curl <your-endpoint> \
-X POST \
-H "Content-Type: application/json" \
-d '{
"jsonrpc": "2.0",
"method": "starknet_getBlockTransactionCount",
"params": [
{
"block_number": 5000
}
],
"id": 0
}'
Return
{
"jsonrpc": "2.0",
"result": 284,
"id": 1
}