Trades By Pairs

Returns 10 DEX trades on Ethereum, where block date since 2023-07-11 and block date till 2023-07-11, sorted by count, highest first: chain ID, unique of block date, count, sum of trade buy amount, buy currency symbol, buy smart contract, sell currency symbol and sell smart contract.

By Aleksey · saved 12 July 2023 · run 3 times · Bitquery API v2

What it returns

Filters

The query

query ($network: evm_network, $limit: Int!, $offset: Int!, $from: String, $till: String) {
  EVM(dataset: combined, network: $network) {
    DEXTrades(
      limit: {count: $limit, offset: $offset}
      where: {Block: {Date: {since: $from, till: $till}}}
      orderBy: {descendingByField: "count"}
    ) {
      ChainId
      uniq(of: Block_Date)
      count
      Buy_Amount: sum(of: Trade_Buy_Amount)
      Trade {
        Buy {
          Currency {
            Symbol
            SmartContract
          }
        }
        Sell {
          Currency {
            Symbol
            SmartContract
          }
        }
      }
    }
  }
}

Variables

{
  "network": "eth",
  "limit": 10,
  "offset": 0,
  "from": "2023-07-11",
  "till": "2023-07-11"
}

Similar queries