Price of multiple tokens in realtime

Historical data This query uses the realtime dataset (the default), which holds only a recent window - hours to days depending on the cube. For older data add a dataset to the top-level element: EVM(network: base, dataset: combined) archive full history combined archive + realtime in one result A

By Akshat · saved 11 December 2025 · run 1 time · Bitquery API v2

What it returns

Filters

The query

# Historical data
#   This query uses the realtime dataset (the default), which holds only a
#   recent window - hours to days depending on the cube.
#
#   For older data add a dataset to the top-level element:
#
#     EVM(network: base, dataset: combined)
#
#     archive   full history
#     combined  archive + realtime in one result
#
#   Archive and combined need the historical data add-on:
#   https://bitquery.io/pricing
#
# Datasets:  https://docs.bitquery.io/docs/graphql/dataset/archive/
# Retention: https://docs.bitquery.io/docs/graphql/data-coverage-retention/
#

query MyQuery {
  EVM(network: base, dataset: realtime) {
    DEXTrades(
      limitBy: {by:Trade_Buy_Currency_SmartContract count: 1}
      orderBy: {descending: Block_Time}
      where: {Trade: {Buy: {Currency: {SmartContract: {in: ["0x940181a94a35a4569e4529a3cdfb74e38fd98631","0x04C0599Ae5A44757c0af6F9eC3b93da8976c150A"]}}}, Sell: {Currency: {SmartContract: {is: "0x4200000000000000000000000000000000000006"}}}}, TransactionStatus: {Success: true}}
    ) {
      Trade {
        Buy {
          Currency {
            Symbol
          }
          Price_In_USD: PriceInUSD
          Price_in_native_currency: Price
        }
        Sell {
          Currency {
            Symbol
          }
        }
      }
    }
  }
}

Similar queries