test_evm

Returns the latest DEX trades by token on Ethereum: block time and trade price.

By Divyasshree N · saved 23 December 2023 · Bitquery API v2

What it returns

The query

query ( $since: DateTime, $till: DateTime, $quoteCurrency: String, $baseCurrency: String) {
  EVM(network: eth, dataset: combined) {
    DEXTradeByTokens(
      orderBy: {descending: Block_Time}
      where: {Trade: {Currency: {SmartContract: {is: $baseCurrency}}, Side: {Currency: {SmartContract: {is: $quoteCurrency}}}}, Block: {Time: {since: $since, till: $till}}}
    ) {
      Block {
        Time(interval: {in: hours, count: 1})
      }
      Trade {
        close: Price(maximum: Block_Number)
      }
    }
  }
}

Variables

{
  "since": "2023-12-22T12:03:59.339Z",
  "till": "2023-12-23T12:04:27.555Z",
}

Similar queries