An enhanced API that gets all transaction receipts for a given block by number or block hash. Supported on all networks for Ethereum, Polygon, and Arbitrum.

Chains Supported

alchemy_getTransactionReceiptsAll NetworksAll NetworksAll NetworksAll NetworksAll NetworksUnsupportedUnsupportedUnsupported

Alternative Query

The alternative to using alchemy_getTransactionReceipts would be to use the Ethereum JSON-RPC API to retrieve the list of transaction hashes for the block using eth_getBlockByNumber or eth_getBlockByHash methods and then use eth_getTransactionReceipt to retrieve the receipt for each transaction. This approach requires making multiple API calls, one for each transaction receipt. This is way slower than alchemy_getTransactionReceipts due to the large number of API calls.

Overall, alchemy_getTransactionReceipts is performant and simple-to-use at the same time.

Use Cases

alchemy_getTransactionReceipts can be used in a variety of use cases where developers need to retrieve transaction receipts for a specific block. Some examples include:

  • Extracting data for analysis: Developers may need to extract data from transaction receipts for analysis purposes, such as measuring transaction volumes, gas usage, or average block times.

  • Building a blockchain explorer: Developers building blockchain explorers may need to retrieve all transaction receipts for a given block in order to display details about the transactions in a user-friendly way.

  • Building decentralized applications: Decentralized applications (dApps) may need to retrieve transaction receipts to confirm the success or failure of a transaction in order to execute subsequent transactions or operations.