Skip to main content
This page documents the v3 feed format. Since February 16, 2025, the v4 format separating mark prices from index prices is the recommended one — see the Mark + Index introduction for the v4 endpoints and migration details.

DNS

https://backend-pricing.eu.gains.trade NOTE: No auth is required for accessing REST GET endpoints and the WebSocket event stream. However, rate limiting is in place, so please fetch data only as necessary and rely on the event stream to keep price data updated.

Common Endpoint

Current OHLC snapshots

Fetch the current OHLC snapshot for each pair. /charts Format:
  • Comprehensive list of OHLCs
  • pairId is the index in the array. For example, BTC/USD pairId = 0, so opens[0], highs[0], lows[0], and closes[0] construct the OHLC.
  • { time, opens: [], highs: [], lows: [], closes: [] }
/charts is a current OHLC snapshot endpoint. It is not a historical OHLCV candles API. It does not include volume, interval, from, or to parameters.
For live price updates, use the event stream below. For recent executed trade data that you can use to derive gTrade volume, use the trading history endpoints. Those endpoints do not return price candles. For the v4 response shape with indexPrices, see the Mark + Index introduction.

Event Stream

Subscribe for all price updates. The stream provides updates every 25ms. wss://backend-pricing.eu.gains.trade
  • Format:
    • Array of price updates for a given 25ms interval
    • All even indexes are pairIds, odd are pair prices
    • No particular order
    • [<pairIdX>,<pairIdXPrice>, <pairIdN>, <pairIdNPrice>, <pairIdY>, <pairIdYPrice>...]
Every ~1000ms, the stream sends a single-item array as a ping message with an updated timestamp, for example: [1724244390036].