eth_getBlockReceipts | Base

Base API method eth_getBlockReceipts retrieves all transaction receipts for a specified block. This method enables applications to access detailed information about every transaction within a block, including outcomes, gas used, and event logs.

๐Ÿ‘

Get you own node endpoint today

Start for free and get your app to production levels immediately. No credit card required.

You can sign up with your GitHub, X, Google, or Microsoft account.

Parameters

  • blockIdentifier โ€” a string that specifies the block number in hexadecimal format or one of the strings "earliest", "latest", or "pending", indicating which block's receipts to retrieve. For instance, using "latest" fetches the receipts for the most recent block.

Response

  • result โ€” an array of objects, each representing a transaction receipt within the specified block. Key fields in each receipt include:
    • transactionHash โ€” the hash of the transaction.
    • transactionIndex โ€” the transaction's index position within the block.
    • blockHash โ€” the hash of the block containing the transaction.
    • blockNumber โ€” the number of the block containing the transaction.
    • from โ€” the address of the sender.
    • to โ€” the address of the receiver (null for contract creation transactions).
    • cumulativeGasUsed โ€” the total amount of gas used in the block up until this transaction.
    • gasUsed โ€” the amount of gas used by this transaction.
    • contractAddress โ€” the contract address created by the transaction, if any.
    • logs โ€” an array of log objects generated by the transaction.
    • status โ€” the status of the transaction (0x1 for success, 0x0 for failure).

Use case

The eth_getBlockReceipts method is crucial for applications requiring comprehensive transactional data from a block, such as:

  • Analyzing gas consumption and efficiency across transactions.
  • Monitoring smart contract interactions and logging for decentralized applications (DApps).
  • Verifying transaction execution outcomes for auditing and security analysis.

Try the eth_getBlockReceipts RPC method yourself

This method offers a granular view of block transactions, facilitating detailed analysis and monitoring of transaction outcomes, gas usage, and smart contract events on the Base blockchain.

Language
Click Try It! to start a request and see the response here!