Cover Image for Price Index for DEX Tokens

Price Index for DEX Tokens

DEX

One of the major problems we see in DEX space is that many of the DEX assets do not have trading pairs with some popular DEX currencies such as USDT, WETH(Wrapped Ether), USDC, WBNB (Wrapped BNB), etc.

Or if they have pairs with WETH or WBNB, they do not have pairs with stablecoins such as USDT or USDC.

Besides, most of these pairs don’t have much trade data. Therefore calculating USD price against these unpopular assets is challenging, and if you are trying to create TradingView-like charts, then life becomes hell.

Working with DEXs

We have seen this problem faced by many businesses trying to build DEX-related tools. While our original DEX APIs provided the foundation, we've now launched a dedicated Crypto Price API that eliminates most of these challenges.

How the New Crypto Price API Solves DEX Pricing Problems

The new Crypto Price API (Price Index) and Streams addresses the core issues in DEX space:

Problem 1: Missing Trading Pairs

  • Before: Had to calculate prices through intermediate currencies (e.g., 1INCH → WETH → USDT)
  • Now: Direct USD pricing for any token across all chains via cross-DEX aggregation

Problem 2: Manual Price Calculations

  • Before: Required complex GraphQL queries with manual OHLC aggregation
  • Now: Pre-aggregated OHLC data with 1-second granularity, ready to use

Problem 3: Low-Quality Trade Data

  • Before: Had to manually filter out bad trades and outliers
  • Now: Built-in filtering automatically excludes low-quality trades for accurate pricing

Problem 4: Chain-Specific Limitations

  • Before: Separate queries needed for Ethereum, Solana, Tron, etc.
  • Now: Chain-agnostic API that aggregates data across all supported networks

What This Means for Developers

Instead of spending hours building complex price calculation logic, you now get:

  • Real-time price streams that update every second
  • Ready-to-use OHLC data for TradingView charts. SDK available here
  • Cross-chain price discovery without manual aggregation
  • Professional-grade data quality with built-in filtering

This transforms DEX price discovery from a complex engineering task into a simple API call, making it possible to build sophisticated trading applications in minutes rather than weeks.

DEX Price Index

The New Crypto Price API

Since we first published this blog, we've launched a new Crypto Price API (Price Index) and Streams that solves many of the challenges we discussed above. This new API provides:

  • Pre-aggregated OHLC data - No more manual calculations needed
  • Real-time streaming with 1-second granularity
  • Cross-chain aggregation - Get unified prices across Ethereum, Solana, Tron, and more
  • Built-in filtering - Automatically excludes low-quality trades and outliers
  • Ready-to-use metrics - SMA, WMA, EMA, and other technical indicators included

How It Solves the Original Problem

Instead of manually calculating prices through intermediate currencies like WETH, the new Crypto Price API gives you:

  1. Direct USD pricing for any token across all chains
  2. Real-time OHLC data that you can feed directly to TradingView charts
  3. Volume-weighted price calculations that automatically handle the complexity
  4. Cross-DEX aggregation that combines data from Uniswap, PancakeSwap, Raydium, and more

Example : Getting Bitcoin/USD Price in Real-time

Run Stream

subscription {
  Trading {
    Pairs(
      where: {
        Currency: {Id: {is: "bid:bitcoin"}},
        QuoteCurrency: {Id: {is: "usdt"}},
        Interval: {Time: {Duration: {eq: 1}}}
      }
    ) {
      Token { Symbol }
      QuoteToken { Symbol }
      Price {
        Ohlc { Open High Low Close }
        Average { Mean WeightedSimpleMoving }
      }
      Volume { Usd Base Quote }
      Interval { Time { Start Duration End } }
    }
  }
}

Key Benefits:

  • No manual calculations - OHLC data is pre-aggregated
  • Real-time streaming - 1-second updates
  • Cross-chain data - Combines prices from all supported networks
  • TradingView ready - Direct integration with charting libraries
  • Kafka streams - Available via trading.prices topic for high-frequency applications

We are in the process of building a DEX price index, and if you are interested in it, join our Telegram channel.

You might also be interested in:

About Bitquery

Bitquery is a set of software tools that parse, index, access, search, and use information across blockchain networks in a unified way. Our products are:

  • Coinpath® APIs provide blockchain money flow analysis for more than 24 blockchains. With Coinpath’s APIs, you can monitor blockchain transactions, investigate crypto crimes such as bitcoin money laundering, and create crypto forensics tools. Read this to get started with Coinpath®.

  • Digital Assets API provides index information related to all major cryptocurrencies, coins, and tokens.

  • DEX API provides real-time deposits and transactions, trades, and other related data on different DEX protocols like Uniswap, Kyber Network, Airswap, Matching Network, etc.

If you have any questions about our products, ask them on our Telegram channel. Also, subscribe to our newsletter below, we will keep you updated with the latest in the cryptocurrency world.


Updated in August 2025

Subscribe to our newsletter

Subscribe and never miss any updates related to our APIs, new developments & latest news etc. Our newsletter is sent once a week on Monday.