Bitcoin blocks

Returns 10 blocks on Bitcoin, where date since 2021-11-15 and date till 2021-12-14, sorted by height, highest first: timestamp time, height, difficulty, transaction count, block size and chainwork.

By gaurav · saved 14 December 2021 · run 1 time · Bitquery API v1

What it returns

Filters

The query

query ($network: BitcoinNetwork!, $limit: Int!, $offset: Int!, $from: ISO8601DateTime, $till: ISO8601DateTime) {
  bitcoin(network: $network) {
    blocks(
      options: {desc: "height", limit: $limit, offset: $offset}
      date: {since: $from, till: $till}
    ) {
      timestamp {
        time(format: "%Y-%m-%d %H:%M:%S")
      }
      height
      difficulty
      transactionCount
      blockSize
      chainwork
    }
  }
}

Variables

{
  "limit": 10,
  "offset": 0,
  "network": "bitcoin",
  "from": "2021-11-15",
  "till": "2021-12-14T23:59:59",
  "dateFormat": "%Y-%m-%d"
}

Similar queries