Skip to main content
POST
https://api.blockdb.io
/
v1
/
evm
/
blocks
curl -X POST "https://api.blockdb.io/v1/evm/blocks" \
  -H "Authorization: Bearer $BLOCKDB_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "chain_id": 1,
  "from_block": 12345678,
  "to_block": 12345999,
  "from_timestamp": "2025-10-29T00:00:00Z",
  "to_timestamp": "2025-11-11T00:00:00Z",
  "block_numbers": [
    12345678,
    12345679
  ],
  "block_hashes": [
    "7b5c0972efb6a0b5be4a4d4a0de5d1abd922478a53f32b2c717a800c862ba9e0"
  ],
  "limit": 200,
  "cursor": null
}'
{
  "chain_id": 1,
  "meta": {
    "request_window": {
      "from_block": 12345678,
      "to_block": 12345999,
      "from_timestamp": "2025-10-29T00:00:00Z",
      "to_timestamp": "2025-11-11T00:00:00Z"
    },
    "filters": {
      "block_numbers": [
        12345678,
        12345679
      ],
      "block_hashes": [
        "7b5c0972efb6a0b5be4a4d4a0de5d1abd922478a53f32b2c717a800c862ba9e0"
      ]
    }
  },
  "data": [
    {
      "block_number": 12345678,
      "block_hash": "7b5c0972efb6a0b5be4a4d4a0de5d1abd922478a53f32b2c717a800c862ba9e0",
      "parent_block_hash": "f78e26c5959a94d6a62ed3837f5dcecf0d3761bf0a502e12a08fd7bc44c8568d",
      "receipt_root": "b4d8cfe4b87590afe7ed95fbf7798142e8fb1ce86307ff0eb6580b8bc23de92f",
      "miner": "0000000000000000000000000000000000000000",
      "gas_limit": 30000000,
      "extra_data": "636c61737369635f657468657265756d",
      "size": 124836,
      "timestamp_utc": "2025-11-11T18:42:15.123Z",
      "_tracing_id": "010200000000000000000000000000000000",
      "_computed_receipt_root": "b4d8cfe4b87590afe7ed95fbf7798142e8fb1ce86307ff0eb6580b8bc23de92f",
      "_computed_receipt_timestamp_utc": "2025-11-11T18:43:00.000Z",
      "_created_at": "2025-11-11T18:42:15.123Z",
      "_updated_at": "2025-11-11T18:42:15.123Z"
    },
    ...
  ],
  "cursor": null,
  "count": 1
}

Description

Retrieves canonical EVM blocks with provenance and integrity metadata.

Parameters

chain_id
number
required
Target EVM network. See the Chain enumeration for supported values.

Range Filters (mutually exclusive)

from_block
number
Starting block number (inclusive) for the query. Use with to_block.
to_block
number
Ending block number (inclusive) for the query. Use with from_block.
from_timestamp
string
Starting timestamp (ISO-8601). If it falls between blocks, the next block after this timestamp is used. Use with to_timestamp.
to_timestamp
string
Ending timestamp (ISO-8601). If it falls between blocks, the last block before this timestamp is used. Use with from_timestamp.
Validation rule:
You must provide either a block range, a time range, or explicit selectors.
Providing more than one option (e.g., both ranges or ranges plus selectors) results in HTTP 400.
Providing none results in HTTP 400.

Direct Selectors

block_numbers
number[]
Explicit set of block numbers. Mutually exclusive with block_hashes.
block_hashes
string[]
Explicit set of block hashes (hex string, 32 bytes, no 0x prefix). Mutually exclusive with block_numbers.

Pagination Controls

limit
number
default:"250"
Recommended default 250; maximum 1000 to stay under ~10 MB responses.
cursor
string
Opaque pagination cursor supplied by a previous response.

Response Fields

chain_id
number
EVM chain ID echoed at the response root.

Meta

meta
object
Echo of request metadata applied to the response.
meta.request_window
object
Block/timestamp bounds derived from the request.
meta.filters
object
Filters echoed from the request (contract addresses, block numbers, limit).

Data

data
object[]
Array of block objects.
data.block_number
number
Sequential block height.
data.block_hash
string
Keccak-256 hash of the block header (32 bytes, hex string, no 0x prefix).
data.parent_block_hash
string
Keccak-256 hash of the parent block (32 bytes, hex string, no 0x prefix).
data.receipt_root
string
Merkle root of transaction receipts (32 bytes).
data.miner
string
Fee recipient / coinbase address (20 bytes).
data.gas_limit
number
Block gas limit.
data.extra_data
string
Extra data payload supplied by the miner (<= 32 bytes, hex-encoded).
data.size
number
Block size in bytes.
data.timestamp_utc
string
Timestamp when the block was mined.
data._tracing_id
string
Tracing identifier for the canonical block record (hex string, no 0x prefix).
data._computed_receipt_root
string
Recomputed receipts root for BlockDB integrity checks.
data._computed_receipt_timestamp_utc
string
Timestamp when the receipts root was (re)computed.
data._created_at
string
Record creation timestamp.
data._updated_at
string
Record last update timestamp.

Envelope Fields

cursor
string | null
Cursor token for pagination.
count
number
Number of records returned in data.
curl -X POST "https://api.blockdb.io/v1/evm/blocks" \
  -H "Authorization: Bearer $BLOCKDB_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "chain_id": 1,
  "from_block": 12345678,
  "to_block": 12345999,
  "from_timestamp": "2025-10-29T00:00:00Z",
  "to_timestamp": "2025-11-11T00:00:00Z",
  "block_numbers": [
    12345678,
    12345679
  ],
  "block_hashes": [
    "7b5c0972efb6a0b5be4a4d4a0de5d1abd922478a53f32b2c717a800c862ba9e0"
  ],
  "limit": 200,
  "cursor": null
}'
{
  "chain_id": 1,
  "meta": {
    "request_window": {
      "from_block": 12345678,
      "to_block": 12345999,
      "from_timestamp": "2025-10-29T00:00:00Z",
      "to_timestamp": "2025-11-11T00:00:00Z"
    },
    "filters": {
      "block_numbers": [
        12345678,
        12345679
      ],
      "block_hashes": [
        "7b5c0972efb6a0b5be4a4d4a0de5d1abd922478a53f32b2c717a800c862ba9e0"
      ]
    }
  },
  "data": [
    {
      "block_number": 12345678,
      "block_hash": "7b5c0972efb6a0b5be4a4d4a0de5d1abd922478a53f32b2c717a800c862ba9e0",
      "parent_block_hash": "f78e26c5959a94d6a62ed3837f5dcecf0d3761bf0a502e12a08fd7bc44c8568d",
      "receipt_root": "b4d8cfe4b87590afe7ed95fbf7798142e8fb1ce86307ff0eb6580b8bc23de92f",
      "miner": "0000000000000000000000000000000000000000",
      "gas_limit": 30000000,
      "extra_data": "636c61737369635f657468657265756d",
      "size": 124836,
      "timestamp_utc": "2025-11-11T18:42:15.123Z",
      "_tracing_id": "010200000000000000000000000000000000",
      "_computed_receipt_root": "b4d8cfe4b87590afe7ed95fbf7798142e8fb1ce86307ff0eb6580b8bc23de92f",
      "_computed_receipt_timestamp_utc": "2025-11-11T18:43:00.000Z",
      "_created_at": "2025-11-11T18:42:15.123Z",
      "_updated_at": "2025-11-11T18:42:15.123Z"
    },
    ...
  ],
  "cursor": null,
  "count": 1
}