trade stats 24 h of a token on eth mainnet

Returns DEX trades by token on Ethereum, where currency smart contract is 0x812B…53Ee, DEX protocol name is uniswap_v2 and block time since 2024-09-28: count.

By Akshat · saved 29 September 2024 · run 1 time · Bitquery API v2

What it returns

Filters

The query

query MyQuery {
  EVM(network: eth, dataset: combined) {
    DEXTradeByTokens(
      where: {TransactionStatus: {Success: true}, Trade: {Currency: {SmartContract: {is: "0x812Ba41e071C7b7fA4EBcFB62dF5F45f6fA853Ee"}}, Dex: {ProtocolName: {is: "uniswap_v2"}}}, Block: {Time: {since: "2024-09-28T07:07:00Z"}}}
    ) {
      trades: count
      buyers:count(distinct: Trade_Buyer)
      sellers:count(distinct: Trade_Seller)
      buys: count(if:{Trade:{Side:{Type:{is:sell}}}})
      sells: count(if:{Trade:{Side:{Type:{is:buy}}}})
    }
  }
}

Similar queries