Subscription Latest Trades of NFT Tokens in Network

Returns the latest 10 DEX trades on Arbitrum, where buy currency smart contract is not 0x, sell currency smart contract is not 0x and sell seller is not 0x: block time, block number, transaction hash, protocol family, protocol name, protocol version, smart contract and 12 more fields.

By Nadia · saved 16 August 2023 · run 6 times · Bitquery API v2

What it returns

Filters

The query

query ($network: evm_network, $limit: Int!, $from: String, $till: String) {
  EVM(network: $network, dataset: combined) {
    DEXTrades(
      orderBy: {descending: Block_Number}
      limit: {count: $limit}
      where: {Trade: {Buy: {Currency: {Fungible: false, SmartContract: {not: "0x"}}}, Sell: {Currency: {SmartContract: {not: "0x"}}, Seller: {not: "0x"}}}, Block: {Date: {till: $till, since: $from}}}
    ) {
      Block {
        Time
        Number
      }
      Transaction {
        Hash
      }
      Trade {
        Dex {
          ProtocolFamily
          ProtocolName
          ProtocolVersion
          SmartContract
        }
        Buy {
          Currency {
            SmartContract
            Symbol
          }
          Price
          Amount
          Seller
          Buyer
          Ids
          URIs
        }
        Sell {
          Amount
          Currency {
            Symbol
            SmartContract
          }
        }
      }
      ChainId
    }
  }
}

Variables

{
  "network": "arbitrum",
  "limit": 10,
  "offset": 0,
  "from": "2023-08-06",
  "till": "2023-08-16"
}

Similar queries