PERFECTQUERY

Trades for a specific token on the Pancake DEX

Returns the latest 10000 DEX trades on Ethereum and BNB Chain, where base currency is 0xae80…bf00 and quote currency is 0xbb4c…095c: second, block height, side, quote price, exchange name, maximum of sell amount, minimum of sell amount and tx from address.

By Fizza · saved 21 April 2022 · Bitquery API v1

What it returns

Filters

The query

query ($network: EthereumNetwork!, $baseCurrency: String, $quoteCurrency: String, $from: ISO8601DateTime) {
  ethereum(network: $network) {
    dexTrades(
      options: {desc: ["block.height"], limit: 10000}
      baseCurrency: {is: $baseCurrency}
      quoteCurrency: {is: $quoteCurrency}
      date: {since: $from}
    ) {
      timeInterval {
        second
      }
      timeInterval {
        second
      }
      block {
        height
      }
      side
      quotePrice
      exchange {
        name
      }
      high: quotePrice(calculate: maximum)
      low: quotePrice(calculate: minimum)
      open: maximum(of: sell_amount)
      close: minimum(of: sell_amount)
      transaction {
        txFrom {
          address
        }
      }
    }
  }
}

Variables

{
  "since": "2022-21-04",
  "network": "bsc",
  "baseCurrency": "0xae808c96e7cd2ed4c9b7e35dfae5d5c299cfbf00",
  "quoteCurrency": "0xbb4cdb9cbd36b01bd1cbaebf2de08d9173bc095c"
}

Similar queries