Eth
eth_getBlockByNumber
Returns the block for a given number. Second param selects full transactions.
JSON-RPC request
jsonrpcstring
methodstring
params
[blockParameter, returnFullTransactions]
Items
2 <= items <= 2idinteger
Response Body
application/json
application/json
curl -X POST "https://api.avax.network/ext/bc/C/rpc#eth_getBlockByNumber" \ -H "Content-Type: application/json" \ -d '{ "jsonrpc": "2.0", "method": "eth_getBlockByNumber", "params": [ "latest", false ], "id": 1 }'{
"jsonrpc": "2.0",
"result": null,
"error": {
"code": 0,
"message": "string",
"data": null
},
"id": 1
}{
"jsonrpc": "2.0",
"error": {
"code": 0,
"message": "string",
"data": null
},
"id": 1
}Is this guide helpful?