query OHLC

Returns 1000 tokens, where token address is 0x02bc…c54d, token network bid is bid:bsc and block time since 2026-05-20, sorted by interval time start, highest first: start, USD, open, close, low and high.

By Aleksey · saved 27 May 2026 · run 7 times · Bitquery API v2

What it returns

Filters

The query

query HistoricalOhlcv(
      $network: String!,
      $tokenAddress: String!,
      $resolution: Int!,
      $from: DateTime!,
      $to: DateTime!,
      $limit: Int!
    ) {
      Trading {
        Tokens(
          where: {
            Token: { NetworkBid: { is: $network }, Address: { is: $tokenAddress } }
            Interval: { Time: { Duration: { eq: $resolution } } }
            Block: { Time: { since: $from, till: $to } }
          }
          orderBy: { descending: Interval_Time_Start }
          limit: { count: $limit }
        ) {
          Interval { Time { Start } }
          Volume { Usd }
          Price { Ohlc { Open Close Low High } }
        }
      }
    }

Variables

{
  "network": "bid:bsc",
  "tokenAddress": "0x02bcc4c181b83a8c0a342bc003389cbecb4bc54d",
  "resolution": 3600,
  "limit": 1000,
  "from": "2026-05-20T00:00:00Z",
  "to": "2026-05-27T00:00:00Z"
}

Similar queries