Pancakeswap historical OHLCV

Returns 10000 DEX trades on Ethereum and bsc_testnet, where tx to is 0x9Ac6…e5c3, base currency is 0xae13…a7cd and quote currency is 0xed24…12ee, sorted by time interval minute: minute, base amount, quote price, minimum of block and maximum of block.

By Giang · saved 17 April 2025 · run 1 time · Bitquery API v1

What it returns

Filters

The query

query ($limit: Int, $network: EthereumNetwork, $minuteInterval: Int, $base: String, $quote: String, $contract: String, $start: ISO8601DateTime) {
        ethereum(network: $network) {
          dexTrades(
            options: {limit: $limit, asc: "timeInterval.minute"}
            date: {since: $start}
            txTo: {is: $contract}
            baseCurrency: {is: $base}
            quoteCurrency: {is: $quote}
          ) {
            timeInterval {
              minute(count: $minuteInterval)
            }
            volume: baseAmount(calculate: sum)
            low: quotePrice(calculate: minimum)
            high: quotePrice(calculate: maximum)
            open: minimum(of: block, get: quote_price)
            close: maximum(of: block, get: quote_price)
          }
        }
      }

Variables

{
  "network": "bsc_testnet",
  "limit": 10000,
  "start": "2024-01-01T00:00:00.000Z",
  "base": "0xae13d989dac2f0debff460ac112a837c89baa7cd",
  "quote": "0xed24fc36d5ee211ea25a80239fb8c4cfd80f12ee",
  "minuteInterval": 1,
  "contract": "0x9Ac64Cc6e4415144C455BD8E4837Fea55603e5c3"
}

Similar queries