Subscription for the Latest Trades of NFT Token

Streams the latest DEX trades on Ethereum as they happen, where buy currency smart contract is 0xae7a…fe84, buy currency smart contract is not 0x and buy seller is not 0x: chain ID, block time, transaction hash, protocol family, protocol name, protocol version, smart contract and 9 more fields.

By Nadia · saved 10 August 2023 · run 1 time · Bitquery API v2

What it returns

Filters

The subscription

subscription ($network: evm_network, $token: String) {
  EVM(network: $network) {
    DEXTrades(
      orderBy: {descending: Block_Number}
      where: {Trade: {Buy: {Currency: {SmartContract: {is: $token, not: "0x"}}, Seller: {not: "0x"}}}}
    ) {
      ChainId
      Block {
        Time
      }
      Transaction {
        Hash
      }
      Trade {
        Dex {
          ProtocolFamily
          ProtocolName
          ProtocolVersion
          SmartContract
        }
        Buy {
          Currency {
            Symbol
            SmartContract
          }
          Price
          Amount
          Buyer
          Seller
        }
        Sell {
          Amount
          Currency {
            Symbol
            SmartContract
          }
        }
      }
    }
  }
}

Variables

{
  "network": "eth",
  "token": "0xae7ab96520de3a18e5e111b5eaab095312d7fe84"
}

Similar queries