Price of a token historically

Returns DEX trades by token on Solana, where currency mint address is cbbtcf…iMij, side currency mint address is 111111…1111, So1111…1112 or 4 more and block time since 2025-05-04, sorted by block time: block time, quantile of trade price in USD, price in USD and sum of trade side amount in USD.

By gaurav · saved 7 November 2025 · run 2 times · Bitquery API v2

What it returns

Filters

The query

{
  Solana(dataset: combined) {
    DEXTradeByTokens(
      orderBy: {ascendingByField: "Block_Time"}
      where: {Trade: {Currency: {MintAddress: {is: "cbbtcf3aa214zXHbiAZQwf4122FBYbraNdFqgw4iMij"}}, 
        Side: {Currency: {MintAddress: 
          {in: ["11111111111111111111111111111111",
            "So11111111111111111111111111111111111111112", 
            "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v", 
            "Es9vMFrzaCERmJfrF4H2FYD4KCoNkY11McCe8BenwNYB",
            "JUPyiwrYJFskUPiHa7hkeR8VUtAeFoSYbKedZNsDvCN", 
            "EKpQGSJtjMFqKZ9KQanSqYXRcF8fBopzLHYxdM65zcjm"]}}}},
        Block: {Time: {since: "2025-05-04T10:21:31Z", till: "2025-05-04T10:30:31Z"}},
        Transaction: {Result: {Success: true}}}
    ) {
      Block {
        Time(interval: {count: 1, in: minutes}) #here you can change minutes to days, hours, weeks, months
      }
      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

{

}

Similar queries