POSTGet Blocks Within Range

Data APIhttps://web3.nodit.io/v1/ethereum/mainnet/blockchain/getBlocksWithinRange

Retrieves the list of blocks within a specific period or block range.

Path Parameters
chainstring (enum)required

Parameter to specify the target chain for the query.

networkstring (enum)required

Parameter to specify the network of the target chain. Supported networks may vary depending on the chain.

Request Body
fromBlockstring

Parameter specifying the starting block for the query. You can enter one of the following formats:

  • block number: Enter block number as a decimal string.
  • block hash: 64-character hexadecimal (including "0x").
  • block tag: Use "earliest" or "latest" to specify the first block or the most recent block.

Notes:

  • This field cannot be used together with fromDate and toDate.
  • If provided without fromBlock, results are queried from genesis block to this block.
  • toBlock value cannot be less than fromBlock value.
  • If fromBlock and toBlock have the same value, only that block is queried.
  • "earliest" for toBlock is only allowed when fromBlock is "earliest".
  • If fromBlock and toBlock are not provided, the API queries data from the latest 30 days.
toBlockstring

Parameter specifying the ending block for the query. You can enter one of the following formats:

  • block number: Enter block number as a decimal string.
  • block hash: 64-character hexadecimal (including "0x").
  • block tag: Use "earliest" or "latest" to specify the first block or the most recent block.

Notes:

  • This field cannot be used together with fromDate and toDate.
  • If provided without fromBlock, results are queried from genesis block to this block.
  • toBlock value cannot be less than fromBlock value.
  • If fromBlock and toBlock have the same value, only that block is queried.
  • "earliest" for toBlock is only allowed when fromBlock is "earliest".
  • If fromBlock and toBlock are not provided, the API queries data from the latest 30 days.
fromDatestring

Parameter specifying the start date for the query. Date must follow ISO 8601 format (YYYY-MM-DDThh:mm:ss{time zone}) including seconds.

Notes:

  • If provided without toDate, results are queried from this date to the latest block.
  • fromDate value must be equal to or earlier than toDate value.
  • If fromDate and toDate have the same value, only blocks from that date are queried.
  • This field cannot be used together with fromBlock and toBlock.
  • If fromDate and toDate are not provided, the API queries data from the latest 30 days.
toDatestring

Parameter specifying the end date for the query. Date must follow ISO 8601 format (YYYY-MM-DDThh:mm:ss{time zone}) including seconds.

Notes:

  • If provided without fromDate, results are queried from genesis block to this date.
  • toDate value must be equal to or later than fromDate value.
  • If fromDate and toDate have the same value, only blocks from that date are queried.
  • This field cannot be used together with fromBlock and toBlock.
  • If fromDate and toDate are not provided, the API queries data from the latest 30 days.
pageinteger

The page parameter specifies the data page to query. It accepts values up to 100; for pages exceeding 100, use the cursor pagination method.

The page and cursor parameters cannot be used together. If both page and cursor are empty, cursor pagination is used.

rppinteger

rpp stands for results per page and specifies the page size. You can specify a number greater than 0 and up to 100.

cursorstring

The cursor parameter supports pagination and data navigation between pages. Provide the cursor value from the previous page in the next request to load the next page of data.

The page and cursor parameters cannot be used together. If both page and cursor are empty, cursor pagination is used.

withCountboolean

Parameter specifying whether to include the count field in the response. The count field indicates the total number of requested data items. When set to true, the count field is included and response speed may be slower.

Responses
pageinteger

Field representing the page number specified in the page parameter. This field is only included in the response when a value greater than 0 is specified for the page parameter.

rppinteger

Field representing the number of results per page specified in the rpp parameter.

cursorstring

A field for cursor pagination. This value must be provided in the next request to load the next page of data.

countinteger

Field representing the total count of requested data. This field is only included in the response when true is set for the withCount parameter.

fromDatestring

Field representing the start of the query range in Date mode. Returned in ISO 8601 format.

toDatestring

Field representing the end of the query range in Date mode. Returned in ISO 8601 format.

fromBlockinteger

Field representing the start block height of the query range in Block mode.

toBlockinteger

Field representing the end block height of the query range in Block mode.

fromLedgerinteger

Field representing the start ledger index of the query range in Ledger mode.

toLedgerinteger

Field representing the end ledger index of the query range in Ledger mode.

hashstringrequired

A field representing the block hash. Provided as a 64-character hexadecimal string prefixed with 0x.

numberintegerrequired

A field representing the block number or block height. Provided as a decimal string.

timestampintegerrequired

A field representing the time when the block was created. This field is provided as a UNIX timestamp.

parentHashstringrequired

A field representing the hash of the parent block. Provided as a 64-character hexadecimal string prefixed with 0x.

noncestring

A value used to prove block validity in Proof of Work (PoW). Returns 0x0000000000000000 for blocks after the transition to Proof of Stake (PoS).

stateRootstringrequired

A field representing the root hash of the block state. Provided as a 64-character hexadecimal string prefixed with 0x.

receiptsRootstringrequired

A field representing the root hash of all transaction receipts in the block. Provided as a 64-character hexadecimal string prefixed with 0x.

transactionsRootstringrequired

A field representing the root hash of all transactions in the block. Provided as a 64-character hexadecimal string prefixed with 0x.

minerstringrequired

A field representing the address of the miner who created the block. Provided as a 40-character hexadecimal string prefixed with 0x.

difficultystring

A field representing the block creation difficulty. Returns the difficulty value for Proof of Work (PoW), and 0 for blocks after the transition to Proof of Stake (PoS).

totalDifficultystring

A field representing the cumulative block creation difficulty. Returns the sum of difficulty from block 0 to the current block. Provided as a hexadecimal string prefixed with 0x.

mixHashstringrequired

A value used to prove block validity in Proof of Work (PoW). Provided as a 64-character hexadecimal string prefixed with 0x.

gasLimitstringrequired

A field representing the maximum gas allowed for the block. The sum of gas used by all transactions in the block must be less than this value. Provided as a hexadecimal string prefixed with 0x.

gasUsedstringrequired

A field representing the total gas used by all transactions in the block. Provided as a hexadecimal string prefixed with 0x.

baseFeePerGasstring

A field representing the block base gas fee. Part of the variable fee model introduced in EIP-1559 (London Hard fork). This field is not provided for blocks before this introduction. Provided as a hexadecimal string prefixed with 0x.

sizestringrequired

A field representing the size of the block in bytes. Provided as a hexadecimal string prefixed with 0x.

logsBloomstringrequired

A field representing the logs bloom of all transactions in the block. Provided as a 512-character hexadecimal string prefixed with 0x.

extraDatastringrequired

A field representing additional data added by the block creator. Returns 0x when no value was added. Provided as a hexadecimal string prefixed with 0x.

sha3Unclesstring

A field representing the hash of all uncle blocks in the block. Provided as a 64-character hexadecimal string prefixed with 0x.

transactionsCountintegerrequired

A field representing the number of transactions in the block.

transactionsstring[]required

A field representing the list of transactions in the block.

withdrawalsRootstring

A field representing the root hash of all withdrawal transactions in the block. Provided as a 64-character hexadecimal string prefixed with 0x.

withdrawalsCountinteger

A field representing the number of withdrawal transactions included in the block.

withdrawalsobject[]

A field representing the list of withdrawals of staked assets by validators.

indexstringrequired

A field representing the index of the withdrawal transaction. Provided as an integer starting from 0, in decimal string format.

validatorIndexstringrequired

A field representing the index of the validator who requested the withdrawal. Provided in decimal string format.

addressstringrequired

A field representing the address that receives the withdrawn Native Token. Provided as a 40-character hexadecimal string prefixed with 0x.

amountstringrequired

A field representing the withdrawn amount. Provided in decimal string format.

requestsHashstring

A field in the block header that is a cryptographic commitment of the order and content of all requests in the block. This allows verification of the integrity of the request list within the block without downloading the full data.

X-API-KEY
RequestCU150
cURL
curl -X POST "https://web3.nodit.io/v1/ethereum/mainnet/blockchain/getBlocksWithinRange" \
  -H "X-API-KEY: {YOUR_API_KEY}" \
  -H "Content-Type: application/json" \
  -d '{
  "page": 1,
  "rpp": 10,
  "fromDate": "2026-01-01T00:00:00Z",
  "toDate": "2026-02-01T00:00:00Z"
}'
Response
Example · 200
{
  "page": 0,
  "rpp": 0,
  "cursor": "string",
  "count": 0,
  "range": {
    "fromDate": "string",
    "toDate": "string",
    "fromBlock": 0,
    "toBlock": 0,
    "fromLedger": 0,
    "toLedger": 0
  },
  "items": [
    {
      "hash": "0x91c90676cab257a59cd956d7cb0bceb9b1a71d79755c23c7277a0697ccfaf8c4",
      "number": 100000,
      "timestamp": 1439799138,
      "parentHash": "0xfbafb4b7b6f6789338d15ff046f40dc608a42b1a33b093e109c6d7a36cd76f61",
      "nonce": "0x9f63aafeec219854",
      "stateRoot": "0x209230089ff328b2d87b721c48dbede5fd163c3fae29920188a7118275ab2013",
      "receiptsRoot": "0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421",
      "transactionsRoot": "0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421",
      "miner": "0xe6a7a1d47ff21b6321162aea7c6cb457d5476bca",
      "difficulty": "0x37f5c0b3e61",
      "totalDifficulty": "0x259ec16a4e5ec78",
      "mixHash": "0x9769104bc21358e422d8b0938334c16072e5168cfdbba49614e4cb821ff26176",
      "gasLimit": "0x2fefd8",
      "gasUsed": "0x0",
      "size": "0x225",
      "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
      "extraData": "0x476574682f76312e302e312d38326566323666362f6c696e75782f676f312e34",
      "sha3Uncles": "0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347",
      "transactionsCount": 0,
      "transactions": [],
      "withdrawals": null
    }
  ]
}