Connect with a Data Connector
Writing fetch + WebSocket + candle parsing yourself is tedious. Data Connectors are plug-ins that do that work for you. Connect one, pass a symbol, and the chart loads history plus live ticks.
What you are building
A Bitcoin (or Ethereum, BNB, …) chart that:
- Downloads recent history when the page opens.
- Keeps updating as new trades happen.
No API key needed for the public Binance connector.
See it working first
Switch symbol and timeframe with the controls. This is the same integration you will wire in your app.
Step 1 — Install
npm install @efixdata/exeria-chart @efixdata/connector-binance
Step 2 — Create chart with the connector
import { createChart } from "@efixdata/exeria-chart";
import { BinanceAdapter } from "@efixdata/connector-binance";
const connector = new BinanceAdapter();
const chart = createChart({
container,
dataAdapter: connector,
});
chart.init();
The adapter is the middleman between Binance and your chart.
Step 3 — Load history
await chart.loadData("BTCUSDT", {
interval: "1h",
limit: 1000,
});
BTCUSDT is the trading pair. interval is the candle size. limit is how many bars to request.
Step 4 — Subscribe to live prices
chart.subscribeToUpdates("BTCUSDT", (tick) => {
console.log("Last price:", tick.c);
});
You do not call appendTick manually — the connector feeds the chart for you.
When to use a connector vs your own API
| Situation | Best path |
|---|---|
| Public crypto from Binance | Data Connector (this tutorial) |
| Your company's proprietary prices | Chart with your data |
| Another exchange or asset class | Implement DataAdapter — see Data Connectors overview |
More connectors
- Binance — full feature list
- CoinGecko — aggregated crypto data via coin ids
- Gate.io — USDT spot on Gate.io
- Massive — US stocks, forex, and crypto
- EODHD — global EOD + intraday via EODHD
What is next?
- Live data stream — how ticks behave under the hood
- Binance live demo — standalone demo page with sample code
- Bybit connector — same pattern, different exchange
- Bybit live demo — standalone Bybit demo
- OKX connector — OKX spot with
BTC-USDTsymbols - OKX live demo — standalone OKX demo
- Kraken connector — Kraken USD spot with
BTC/USDsymbols - Kraken live demo — standalone Kraken demo
- KuCoin connector — KuCoin USDT spot with
BTC-USDTsymbols - KuCoin live demo — standalone KuCoin demo
- Coinbase connector — Coinbase USD/USDC spot with
BTC-USDproduct ids - Coinbase live demo — standalone Coinbase demo
- Gate.io live demo — standalone Gate.io demo
- EODHD live demo — standalone EODHD demo
- CoinGecko connector — broad asset catalog
- CoinGecko live demo — standalone CoinGecko demo
- CCXT connector — 100+ exchanges via one package (Node.js)
- Twelve Data connector — forex and multi-asset OHLCV (API key)
- Finage connector — forex OHLCV via Finage (API key)