WETH/CAL Pair Unique Buyer Seller Count

Returns DEX trades on Ethereum, where buy currency smart contract is 0xc02a…6cc2, sell currency smart contract is 0x2056…36e1 and sell currency smart contract is 0xc02a…6cc2: count.

By Divyasshree N · saved 27 September 2023 · run 2 times · Bitquery API v2

What it returns

Filters

The query

query ($network: evm_network, $token: String!, $token2: String!) {
  EVM(network: $network, dataset: combined) {
    Unique_Buyers: DEXTrades(
      where: {Block: {Time: {since: "2023-09-27T01:00:00Z", till: "2023-09-27T02:00:00Z"}}, Trade: {Buy: {Currency: {SmartContract: {is: $token}}}, Sell: {Currency: {SmartContract: {is: $token2}}}}}
    ) {
      count(distinct: Trade_Buy_Buyer)
    }
    Unique_Sellers: DEXTrades(
      where: {Block: {Time: {since: "2023-08-26T01:00:00Z", till: "2023-08-26T02:00:00Z"}}, Trade: {Sell: {Currency: {SmartContract: {is: $token}}}, Buy:{Currency:{SmartContract:{is: $token2}}}}}
    ) {
      count(distinct: Trade_Sell_Seller)
    }
  }
}

Variables

{"network":"eth","token":"0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2", "token2":"0x20561172f791f915323241e885b4f7d5187c36e1"}

Similar queries