getTokensScreener

Returns 2 DEX trades by token on Arbitrum, where block time since 2024-10-09, block time till 2024-10-16 and currency decimals is above 0, sorted by volume24 h, highest first: block time, currency symbol, currency name, smart contract, decimals, amount in USD, trade amount and 5 more fields.

By Jose · saved 16 October 2024 · run 52 times · Bitquery API v2

What it returns

Filters

The query

query getTokensScreener(
  $dataset: dataset_arg_enum!
  $network: evm_network!
  $timeFrom1w: DateTime!
  $timeFrom24h: DateTime!
  $timeFrom6h: DateTime!
  $timeFrom1h: DateTime!
  $timeFrom5m: DateTime!
  $till: DateTime!
) {
  EVM(dataset: $dataset, network: $network) {
    DEXTradeByTokens(
      limit: {count: 2}
      orderBy: {descendingByField: "volume24h"}
      where: {Trade: { Currency: { Symbol: { not: "" }, Decimals: { gt: 0 } } }, Block: {Time: {since: $timeFrom1w, till: $till}}}
    ) {
      Block {
        Time
      }
      Trade {
        Currency {
          Symbol
          Name
          SmartContract
          Decimals
        }
        AmountInUSD
        Amount
        Side {
          Currency {
            Symbol
            Name
            SmartContract
          }
        }
        Dex {
          SmartContract
        }
      }
      volume1w: sum(of: Trade_AmountInUSD)
      volume24h: sum(
        of: Trade_AmountInUSD
        if: {Block: {Time: {since: $timeFrom24h}}}
      )
      volume6h: sum(of: Trade_AmountInUSD, if: {Block: {Time: {since: $timeFrom6h}}})
      volume1h: sum(of: Trade_AmountInUSD, if: {Block: {Time: {since: $timeFrom1h}}})
      volume5m: sum(of: Trade_AmountInUSD, if: {Block: {Time: {since: $timeFrom5m}}})
      tradeCount1w: count
      tradeCount24h: count(if: {Block: {Time: {since: $timeFrom24h}}})
      tradeCount6h: count(if: {Block: {Time: {since: $timeFrom6h}}})
      tradeCount1h: count(if: {Block: {Time: {since: $timeFrom1h}}})
      tradeCount5m: count(if: {Block: {Time: {since: $timeFrom5m}}})
      buys1w: count(if: {Trade: {Side: {Type: {is: sell}}}})
      sells1w: count(if: {Trade: {Side: {Type: {is: buy}}}})
      buys24h: count(
        if: {Trade: {Side: {Type: {is: sell}}}, Block: {Time: {since: $timeFrom24h}}}
      )
      sells24h: count(
        if: {Trade: {Side: {Type: {is: buy}}}, Block: {Time: {since: $timeFrom24h}}}
      )
      buys6h: count(
        if: {Trade: {Side: {Type: {is: sell}}}, Block: {Time: {since: $timeFrom6h}}}
      )
      sells6h: count(
        if: {Trade: {Side: {Type: {is: buy}}}, Block: {Time: {since: $timeFrom6h}}}
      )
      buys1h: count(
        if: {Trade: {Side: {Type: {is: sell}}}, Block: {Time: {since: $timeFrom1h}}}
      )
      sells1h: count(
        if: {Trade: {Side: {Type: {is: buy}}}, Block: {Time: {since: $timeFrom1h}}}
      )
      buys5m: count(
        if: {Trade: {Side: {Type: {is: sell}}}, Block: {Time: {since: $timeFrom5m}}}
      )
      sells5m: count(
        if: {Trade: {Side: {Type: {is: buy}}}, Block: {Time: {since: $timeFrom5m}}}
      )
      uniqueTraders: count(distinct: Trade_Buyer)
    }
  }
}

Variables

{
  "network": "arbitrum",
  "dataset": "combined",
  "timeFrom5m": "2024-10-16T12:39:09.086Z",
  "timeFrom1h": "2024-10-16T11:44:09.086Z",
  "timeFrom6h": "2024-10-16T06:44:09.086Z",
  "timeFrom24h": "2024-10-15T12:44:09.086Z",
  "timeFrom1w": "2024-10-09T12:44:09.086Z",
  "till": "2024-10-16T12:44:09.086Z"
}

Similar queries