getBlockByDate

Returns the latest block on Base, where block time till 2024-10-15: block number, block time, block hash and parent hash.

By Jose · saved 18 October 2024 · Bitquery API v2

What it returns

Filters

The query

query getBlockByDate($dataset: dataset_arg_enum!, $network: evm_network!, $till: DateTime!) {
  EVM(dataset: $dataset, network: $network) {
    Blocks(
      limit: { count: 1 }
      orderBy: { descending: Block_Time }
      where: {Block: {Time: {till: $till}}}
    ) {
      Block {
        Number
        Time
        Hash
        ParentHash
      }
    }
  }
}

Variables

{
  "dataset": "combined",
  "network": "base",
  "till": "2024-10-15T19:40:59Z"
}

Similar queries