Skip to main content

Real-Time OHLC Data

Access high-quality candlestick data for technical analysis and trading applications

Overview

Looking for OHLC data? You’re at the right place. The Candlestick API provides real-time access to Open, High, Low, and Close price data at various time intervals.
Currently, we only support OHLC data for onchain data, but it will soon be available for offchain data as well.

Connection

1

Open WebSocket Connection

Connect to our WebSocket endpoint on your preferred environment:
2

Subscribe to Asset Pair

Send a subscription message with your desired pair, network, interval, and number of candles.
3

Receive OHLC Updates

Once subscribed, you’ll receive candlestick data at your specified interval.

Subscription Management

Subscribing to a Pair

You can only subscribe to one pair at a time. Subscribing to a new pair will automatically replace your current subscription.

Available Parameters

Unsubscribing

To stop receiving updates for your current subscription:
The server will unsubscribe you without sending any acknowledgment. Your connection will remain open but you’ll stop receiving updates.

Data Format

Candle Fields

Available Intervals

1min

One-minute candles

5min

Five-minute candles

15min

Fifteen-minute candles

30min

Thirty-minute candles

1hour

One-hour candles

4hour

Four-hour candles

1day

Daily candles

1week

Weekly candles

Best Practices

Start with Small Requests

Begin with smaller time intervals and fewer candles to ensure smooth performance

Handle Reconnections

Implement reconnection logic with subscription restoration when connections drop

Error Handling

Add robust error handling for network issues and malformed responses

Data Storage

Consider implementing local storage to cache historical candles when appropriate