usd_price_last_7_days

Returns the latest 7 DEX trades on Ethereum, where quote currency is 0xc02a…6cc2, base currency is 0xbe04…5bd6 and date since 2023-08-26: expression, block height, trade index, base amount, quote amount and date date.

By Omkar Acharekar · saved 1 September 2023 · run 20 times · Bitquery API v1

What it returns

Filters

The query

{
  ethereum(network: ethereum) {
    dexTrades(
      options: { limitBy: {each: "date.date", limit: 1}, desc: ["date.date", "block.height", "tradeIndex"], limit: 7}
      quoteCurrency: {is: "0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2"}
      baseCurrency: {is: "0xbe042e9d09CB588331Ff911c2B46FD833A3E5bd6"}
      date: {since: "2023-08-26", till: "2023-09-01"}
    ) {
      USDPrice: expression(get: "quoteAmountUSD / baseAmount")
      block {
        height
      }
      tradeIndex
      baseAmount
      quoteAmountUSD: quoteAmount(in: USD)
      date {
        date
      }
    }
  }
}

Similar queries