eth_getUncleByBlockHashAndIndex - Ethereum

Shows the ‘Uncle’ and its index position after you enter the block’s hash

How to Use the eth_getUncleByBlockHashAndIndex Method

Parameters

QUANTITY|TAG - the string "latest", "earliest" or "pending", or an integer block number., as it is shown in the default block parameter.

QUANTITY - the uncle's index position.

What you receive

Object - A block object with the following fields, or null when no block was found:

  • number: QUANTITY - the block number. null when its pending block.

  • hash: DATA, 32 Bytes - hash of the block. null when its pending block.

  • parentHash: DATA, 32 Bytes - the parent block’s hash.

  • nonce: DATA, 8 Bytes - hash of the generated proof-of-work. null in case its a pending block.

  • sha3Uncles: DATA, 32 Bytes - SHA3 of the uncles data.

  • logsBloom: DATA, 256 Bytes - the bloom filter for the logs in this block. returns null in case it's a pending block.

  • transactionsRoot: DATA, 32 Bytes - the root of the transaction trie.

  • stateRoot: DATA, 32 Bytes - the root of the final state trie of the block.

  • receiptsRoot: DATA, 32 Bytes - the root of the receipts trie related to this block.

  • miner: DATA, 20 Bytes - the address of the beneficiary that received the mining rewards.

  • difficulty: QUANTITY - the block’s difficulty rate.

  • totalDifficulty: QUANTITY - the total chain difficulty until this block presented as an integer. extraData: DATA - field for extra data about this block..

  • size: QUANTITY -measuring the block size in bytes.

  • gasLimit: QUANTITY - the maximum gas amount possible in this block.

  • gasUsed: QUANTITY - the total gas used for proceeding all transactions in this block.

  • timestamp: QUANTITY - the unix timestamp showing the block collation time.

  • transactions: Array consisting of transaction objects, or 32 Bytes transaction hashes that will depend on the last given parameter.

  • uncles: Array of uncle hashes.

Sample

Here is a typical appliance example.

Call

Outcome

Last updated