Skip to main content

Overview

The onPriceUpdated subscription allows you to receive real-time price updates for a specific cryptocurrency symbol. Price data is streamed as it becomes available from the exchange.

Subscription

symbol
string
required
The cryptocurrency symbol to subscribe to (e.g., “BTCUSDT”, “ETHUSDT”)

Response

Returns a stream of Price objects with the following fields:
symbol
string
required
The cryptocurrency trading pair symbol
open
decimal
required
Opening price for the current time bucket
high
decimal
required
Highest price in the current time bucket
low
decimal
required
Lowest price in the current time bucket
close
decimal
required
Most recent closing price
volume
decimal
Total trading volume for the time bucket
bucket
DateTimeOffset
Timestamp for the price data bucket
exchange
Exchange
Exchange information where the price data originated

Examples

subscription {
  onPriceUpdated(symbol: "BTCUSDT") {
    symbol
    open
    high
    low
    close
    volume
    bucket
  }
}

Response Example

{
  "type": "next",
  "id": "1",
  "payload": {
    "data": {
      "onPriceUpdated": {
        "symbol": "BTCUSDT",
        "open": 45230.50,
        "high": 45350.75,
        "low": 45180.25,
        "close": 45295.00,
        "volume": 123.456,
        "bucket": "2026-03-03T10:15:00Z"
      }
    }
  }
}
The subscription filters price updates server-side, only sending data for the requested symbol. This reduces bandwidth and improves performance.

Build docs developers (and LLMs) love