💎 Ethereum
erigon_getBlockReceiptsByBlockHash

erigon_getBlockReceiptsByBlockHash RPC Method

Returns all block receipts for a given block hash. Receipts include information to the transactions and their emitted logs.

Returns

  • array - One block receipt object per transaction in the block.

    • blockHash - The hash of the block being fetched

    • blockNumber - The block number being fetched

    • contractAddress - The contract address, if the transaction was a create contract transaction

    • cumulativeGasUsed - The total amount of gas used during this transaction.

    • effectiveGasPrice - Gas price of the transaction

    • from - The sender of the transaction

    • gasUsed - The amount of gas used by this transaction, not counting internal transactions, calls or delegate calls

    • logs - Array of logs emitted in this transaction. Each object has the same values as in eth_getLogs

      • blockNumber - 20 Bytes - The block where the transaction was included where the log originated from. Null for pending transactions.

      • blockHash - 32 Bytes - The hash of the block where the transaction was included where the log originated from. Null for pending transactions.

      • transactionHash - 32 Bytes - The hash of the transaction that generated the log. Null for pending transactions.

      • transactionIndex - The index of the transaction in the block, where the log originated from.

      • address - The address of the contract that generated the log.

      • topics - An array of 0 to 4 32-byte topics. The first topicis the event signature and the others are indexed filters on the event return data.

      • data - Array of 32-bytes non-indexed return data of the log.

      • logIndex - Index position of the log in the transaction. Null for pending transactions.

      • removed - True when the log was removed, due to a chain reorganization. False if it's a valid log.

Need RPC API keys?

Get 12.5M archival requests for free today.

Parameters

1.BLOCK HASH [required]

The hash of the block to fetch receipts for.

Request

POST https://<network>.chainnodes.org/YOUR-API-KEY

Example

💡

Confusing? Ask blockchain developers in Chainnodes Telegram Chat (opens in a new tab)

  • HTTPS POST Request with a JSON RPC call in the body
  • Replace YOUR-API-KEY with the API key from your Chainnodes.org Dashboard
  • You can use a different supported network by replacing mainnet
curl https://mainnet.chainnodes.org/YOUR-API-KEY \
    -X POST \
    -H "Content-Type: application/json" \
    -d '{"jsonrpc":"2.0","method":"erigon_getBlockReceiptsByBlockHash","params":["0xe9793319714333112d41473d33bc06556b6d32d347517b782eb1cdaec296a20b"],"id":1}'

Body

{
    "jsonrpc": "2.0",
    "id": 1,
    "result": [
        {
            "blockHash": "0xe9793319714333112d41473d33bc06556b6d32d347517b782eb1cdaec296a20b",
            "blockNumber": "0x103441d",
            "contractAddress": null,
            "cumulativeGasUsed": "0x18ffe",
            "effectiveGasPrice": "0x2ef2aa4873",
            "from": "0x5c87ecc36bb97380469be09ef95dc4daf50165ec",
            "gasUsed": "0x18ffe",
            "logs": [
                {
                    "address": "0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2",
                    "topics": [
                        "0xe1fffcc4923d04b559f4d29a8bfc6cda04eb5b0d3c460751c2402c5c5cc9109c",
                        "0x0000000000000000000000007a250d5630b4cf539739df2c5dacb4c659f2488d"
                    ],
                    "data": "0x0000000000000000000000000000000000000000000000001ff43e9a02d13800",
                    "blockNumber": "0x103441d",
                    "transactionHash": "0xd6fd91cfc9698607b375548632cf1fa0f0c5008c55257b986b4c96620fa71934",
                    "transactionIndex": "0x0",
                    "blockHash": "0xe9793319714333112d41473d33bc06556b6d32d347517b782eb1cdaec296a20b",
                    "logIndex": "0x0",
                    "removed": false
                },
                ...............
                ...............
                ...............
 
<GetStarted />