modified OHLC

Returns DEX trades by token on Solana, where currency mint address is 3nTHLK…pump and side currency mint address is 111111…1111, So1111…1112 or 4 more, sorted by block time: block time, quantile of trade price in USD, price in USD and sum of trade side amount in USD.

By Divyasshree · saved 17 June 2025 · Bitquery API v2

What it returns

Filters

The query

query TradingView($token: String, $dataset: dataset_arg_enum, $interval: Int) {
  Solana(dataset: $dataset) {
    DEXTradeByTokens(
      orderBy: {ascendingByField: "Block_Time"}
      where: {Trade: {Currency: {MintAddress: {is: $token}}, Side: {Currency: {MintAddress: {in: ["11111111111111111111111111111111", "So11111111111111111111111111111111111111112", "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v", "Es9vMFrzaCERmJfrF4H2FYD4KCoNkY11McCe8BenwNYB", "JUPyiwrYJFskUPiHa7hkeR8VUtAeFoSYbKedZNsDvCN", "EKpQGSJtjMFqKZ9KQanSqYXRcF8fBopzLHYxdM65zcjm"]}}}}, Transaction: {Result: {Success: true}}}
    ) {
      Block {
        Time(interval: {count: $interval, in: minutes})
      }
      min: quantile(of: Trade_PriceInUSD, level: 0.05)
      max: quantile(of: Trade_PriceInUSD, level: 0.95)
      close: Trade {
        PriceInUSD(maximum: Block_Slot)
      }
      open: Trade {
        PriceInUSD(minimum: Block_Slot)
      }
      volume: sum(of: Trade_Side_AmountInUSD)
    }
  }
}

Variables

{
  "network": "solana",
  "token": "3nTHLKddrMQTn6WMt2ELz5ZtQC6KipZRV4wMEYvRpump",
  "usdc": "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v",
  "usdt": "Es9vMFrzaCERmJfrF4H2FYD4KCoNkY11McCe8BenwNYB",
  "wsol": "So11111111111111111111111111111111111111112",
  "dataset": "realtime",
  "interval": 1
}

Similar queries