OHLC data for strikex

Returns 2000 DEX trades on Ethereum and BNB Chain, where base currency is 0xd6fd…44ec, quote currency is 0xbb4c…095c and exchange address is 0xcA14…0c73, sorted by time interval minute, highest first: minute, base currency name, quote currency name, count, quote amount, expression, quote price and 2 more fields.

By gaurav · saved 29 December 2023 · run 9 times · Bitquery API v1

What it returns

Filters

The query

query ($interval: Int, $limit: Int, $from: ISO8601DateTime, $to: ISO8601DateTime, $baseCurrency: String, $quoteCurrency: String) {
  ethereum(network: bsc) {
    dexTrades(
      baseCurrency: {is: $baseCurrency}
      quoteCurrency: {is: $quoteCurrency}
      time: {since: $from, till: $to}
      options: {limit: $limit, desc: "timeInterval.minute"}
      exchangeAddress: {is: "0xcA143Ce32Fe78f1f7019d7d551a6402fC5350c73"}
    ) {
      timeInterval {
        minute(count: $interval, format: "%Y-%m-%dT%H:%M:%SZ")
      }
      baseCurrency {
        name
      }
      quoteCurrency {
        name
      }
      count(uniq: txs)
      quoteAmount
      volume: quoteAmount(in: USD)
      wethPriceInUSD: expression(get: "volume / quoteAmount")
      high: quotePrice(calculate: maximum)
      low: quotePrice(calculate: minimum)
      open: minimum(of: block, get: quote_price)
      close: maximum(of: block, get: quote_price)
      highUSD: expression(get: "wethPriceInUSD * high")
      lowUSD: expression(get: "wethPriceInUSD * low")
      openUSD: expression(get: "wethPriceInUSD * open")
      closeUSD: expression(get: "wethPriceInUSD * close")
    }
  }
}

Variables

{
  "limit": 2000,
  "baseCurrency": "0xd6fdde76b8c1c45b33790cc8751d5b88984c44ec",
  "quoteCurrency": "0xbb4cdb9cbd36b01bd1cbaebf2de08d9173bc095c",
  "from": "2023-12-28T19:00:00Z",
  "to": "2023-12-28T20:00:00Z",
  "interval": 15
}

Similar queries