Helorious Apollo

Returns one DEX trade on Ethereum, where base currency is 0xC02a…6Cc2, quote currency is 0xdAC1…1ec7 and time after 2023-05-22, sorted by block timestamp time transaction index, highest first: block height, timestamp time, transaction index, base currency symbol, quote currency symbol and quote price.

By Divyasshree N · saved 23 May 2023 · run 3 times · Bitquery API v1

What it returns

Filters

The query

query getQuotePrice($baseCurrency: String, $quoteCurrency: String) {
  ethereum(network: ethereum) {
    dexTrades(
      baseCurrency: {is: $baseCurrency}
      quoteCurrency: {is: $quoteCurrency}
      options: {desc: ["block.timestamp.time", "transaction.index"], limit: 1}
      time: {after: "2023-05-22"}
    ) {
      block {
        height
        timestamp {
          time(format: "%Y-%m-%d %H:%M:%S")
        }
      }
      transaction {
        index
      }
      baseCurrency {
        symbol
      }
      quoteCurrency {
        symbol
      }
      quotePrice
    }
  }
}

Variables

{
  "baseCurrency":"0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2",
  "quoteCurrency":"0xdAC17F958D2ee523a2206206994597C13D831ec7"
}

Similar queries