URL:
Available on Premium, Business, and Enterprise plans.
wss://datastream.solanatracker.io/{apiKey}Available on Premium, Business, and Enterprise plans.
Connect
All Datastream channels use the same WebSocket connection. Send JSON messages to join and leave rooms. See the Datastream protocol for heartbeat (ping/pong), auth failures, and leave semantics.
Price by Token
Subscribe toprice-by-token:{tokenAddress} to get price updates from the primary pool. The primary pool is usually the pool with the most liquidity, meaning the most funds available for trading.
Aggregated Price
Subscribe toprice:aggregated:{tokenAddress} for one price made from many pools. The message includes median, average, min, max, and pool count. Use this for high-liquidity tokens that trade across multiple pools.
Price by Pool
Subscribe toprice:{poolId} for price updates from one specific pool. Use this when you care about a particular DEX or liquidity source.
All Pool Prices
Subscribe toprice:{tokenAddress} (without aggregated) to receive individual price updates from every pool a token trades on.
Token Changes (Full Updates)
Subscribe totoken:{tokenAddress} for comprehensive pool updates — price, liquidity, market cap, supply, and security data all in one message.
Live Transactions
Subscribe totransaction:{tokenAddress} to see every swap as it happens.
Build a Live Chart
Combine the price stream with the OHLCV REST endpoint to build a real-time chart. OHLCV means open, high, low, close, and volume. Use REST for historical candles, then update the latest candle with WebSocket ticks.Open-Source Chart Examples
We have two open-source chart implementations you can use as a starting point:Liveline Chart
Minimal real-time line chart using the Datastream WebSocket. Good starting point for custom UIs.
TradingView Advanced Chart
Full TradingView Advanced Charts integration with real-time candle updates from the Datastream.
Volume & Statistics
Token Volume
Subscribe tovolume:token:{tokenAddress} for aggregated volume updates:
Token Statistics
Subscribe tostats:token:{tokenAddress} for multi-timeframe stats (1m, 5m, 1h, 6h, 24h buy/sell counts, volume, unique traders):
Room Reference
Price & Charts (REST)
REST endpoints for historical OHLCV, price snapshots, and ATH data.
Token Discovery Streams
Stream new tokens, graduating tokens, and market events.