CCXT

One adapter, 100+ crypto exchanges. Binance, Coinbase, Kraken, OKX, Bybit, KuCoin, ...

CCXT is a unified Python client covering 100+ crypto exchanges with a common API shape. The Horizon CcxtVenue wraps one CCXT Exchange instance; instantiate one per exchange you trade.

Connect

python
import horizon as hz

ex = hz.connect("ccxt",
    exchange_id="binance",             # ccxt exchange id
    sandbox=True,                      # testnet where supported
    api_key="...",
    api_secret="...",
)
ex.buy("BTC/USDT", qty=0.001, limit=65_000.0)
print(ex.balance())
ex.close()

Kwargs

KwargTypeDefaultNotes
exchange_idstrrequired"binance", "coinbase", "kraken", "okx", "bybit", "kucoin", …
api_keystr \| NoneNoneFalls back to secrets.get("<exchange_id>.key").
api_secretstr \| NoneNoneFalls back to secrets.get("<exchange_id>.secret").
api_passphrasestr \| NoneNoneRequired for Coinbase, OKX, KuCoin, Bitget.
sandboxboolFalseEnable testnet mode where the exchange supports it.
optionsdict \| NoneNonePer-exchange CCXT options (e.g. {"defaultType": "swap"}).
asset_classAssetClassCryptoSet to Perp when trading perpetuals on the same venue.
budget_usdfloat0.0Optional hard cap.

Unified symbol format: "BASE/QUOTE" ("BTC/USDT"). CCXT normalizes across exchanges.

Install

bash
pip install horizon[ccxt]
# or
pip install ccxt

Status

  • Unified REST submit, cancel, amend, balance, positions: shipped.
  • WebSocket feeds via ccxt.pro (separate commercial license): horizon.data.live.ccxt_ws.
  • Per-exchange quirks (Binance margin mode, Bybit unified account): surface via options.

Exchange-specific credential conventions, symbol mapping, rate-limit tuning: CCXT (professionals).