ETHdextradesn8n

Returns the latest 5 DEX trades on Ethereum, where buy currency smart contract is {{ $json.chatInput }}: block time, buy currency symbol, buy smart contract, buy amount, sell currency symbol, sell amount and count.

By Philip · saved 9 August 2025 · run 1 time · Bitquery API v2

What it returns

Filters

The query

query GetDEXTrades($tokenAddress: String!) {
  EVM(network: eth, dataset: combined) {
    DEXTrades(
      orderBy: {descending: Block_Number}
      limit: {count: 5}
      where: {
        Trade: {
          Buy: {
            Currency: {
              SmartContract: {is: $tokenAddress}
            }
          }
        }
      }
    ) {
      Block {
        Time(interval: {in: minutes, count: 5})
      }
      Trade {
        Buy {
          Currency {
            Symbol
            SmartContract
          }
          Amount
        }
        Sell {
          Currency {
            Symbol
          }
          Amount
        }
      }
      count
    }
  }
}

Variables

{
 "tokenAddress": "{{ $json.chatInput }}"
}

Similar queries