all time high with filtering

Returns one DEX trade by token on Ethereum, where currency smart contract is 0xDee6…3B2D, block time since 2024-12-25 and side amount in USD is above 10: quantile of trade price in USD, price in USD, trade amount, amount in USD, currency name, side amount, side amount in USD and 2 more fields.

By gaurav · saved 9 January 2025 · run 7 times · Bitquery API v2

What it returns

Filters

The query

query AllTimeHighTokenPriceQuery($tokenAddress: String!, $startTime: DateTime!) {
  EVM(dataset: archive, network: eth) {
    DEXTradeByTokens(
      where: {Trade: {Currency: {SmartContract: {is: $tokenAddress}}, Side: {AmountInUSD: {gt: "10"}}}, Block: {Time: {since: $startTime}}}
      limit: {count: 1}
    ) {
      quantile(of: Trade_PriceInUSD, level: 0.03)
      Trade {
        PriceInUSD
        Amount
        AmountInUSD
        Currency {
          Name
        }
        Side {
          Amount
          AmountInUSD
          Currency {
            Name
          }
        }
      }
      Transaction {
        Hash
      }
    }
  }
}

Variables

{
  "tokenAddress": "0xDee6cDd28Da9f51e3A8421395973894a884F3B2D",
  "startTime": "2024-12-25T19:24:33.593Z"
}

Similar queries