Skip to main content
This page is a placeholder. All examples on this page are currently AI-generated and are not correct. This documentation will be completed in the future with accurate, tested examples.

Block Methods

8 methods for querying block data, receipts, and transaction counts.

Overview

Block methods provide access to block headers, full blocks, transaction receipts, and metadata. Use these methods to query blockchain state at specific block heights or hashes.

Methods

Get the most recent block number.Returns: Quantity
Get block by number with full transactions or hashes.Parameters:Returns: Block
Get block by hash with full transactions or hashes.Parameters:Returns: Block
Get all transaction receipts for a block.Parameters:Returns: TransactionReceipt[]
Get transaction count in a block by hash.Parameters:Returns: Quantity
Get transaction count in a block by number.Parameters:Returns: Quantity
Get uncle count for a block by hash.Parameters:Returns: Quantity
Uncle blocks were removed in Ethereum’s transition to Proof of Stake (The Merge). This method returns 0 for post-merge blocks.
Get uncle count for a block by number.Parameters:Returns: Quantity
Uncle blocks were removed in Ethereum’s transition to Proof of Stake (The Merge). This method returns 0 for post-merge blocks.

Usage Patterns

Get Latest Block with Transactions

Query Historical Block

Check Block Finality