Skip to main content

eth_getBlockByHash

POST 

/

Returns information about a block by its hash.

Parameters:

  • hash: the hash (32 bytes) of the block.
  • transaction_detail: if true, returns the full transaction objects, otherwise only the hashes of the transactions.

Returns:

  • result: a block object, or null when no block was found.
  • number: the block number or null when its pending.
  • hash: the hash of the block or null when its pending.
  • parentHash: the hash of the parent block.
  • nonce: the hash of the generated proof-of-work.
  • sha3Uncles: the SHA3 of the uncles data in the block.
  • logsBloom: the bloom filter for the logs of the block. null when its pending block.
  • transactionsRoot: the root of the transaction trie of the block.
  • stateRoot: the root of the final state trie of the block.
  • receiptsRoot: the root of the receipts trie of the block.
  • miner: the address of the beneficiary to whom the mining rewards were given.
  • difficulty: integer of the difficulty for this block.
  • totalDifficulty: integer of the total difficulty of the chain until this block.
  • extraData: the "extra data" field of this block.
  • size: integer the size of this block in bytes.
  • gasLimit: the maximum gas allowed in this block.
  • gasUsed: the total used gas by all transactions in this block.
  • timestamp: the unix timestamp for when the block was collated.
  • transactions: an array of transaction objects. For details, see eth_getTransactionByHash.
  • uncles: an array of uncle hashes.

Request

Query Parameters

    apikey stringrequired

    Your API key

Body

    id integer
    jsonrpc string
    method string
    params string[]

Responses

Successful response

Schema

    jsonrpc string
    id integer
    result string
Loading...