Exchanges
Bybit

Bybit

Bybit connects via classic API key + secret. The terminal uses Bybit's v5 unified API for all endpoints, covering USDT- and USDC-margined perps, inverse (coin-margined) perps, dated (expiry) futures, and the newer builder-dex equity tickers.

Create an API key

  1. Log in to bybit.com (opens in a new tab) and open Profile → API → Create New Key
  2. Choose System-generated API KeysAPI Transaction
  3. Set permissions:
    • Read — Orders, Positions, Wallet
    • Trade — Unified Trading (Spot / Derivatives / Options) and Derivatives (Orders, Positions)
    • Do NOT enable Withdraw
  4. (Recommended) Bind the key to your IP address in the IP Restrictions field
  5. Save the API Key and API Secret — the secret is only displayed once
⚠️

Read + Trade is the full permission set CubeTerminal needs. Never enable withdraw permission on a key pasted into any third-party tool.

Connect in CubeTerminal

  1. Open Settings → Trading Accounts → Bybit
  2. Paste the API Key and API Secret
  3. Click Connect
  4. The terminal fetches balances and positions to confirm the credentials work

If the connection fails, double-check that you copied the secret correctly (no leading/trailing whitespace) and that the key's IP allowlist is configured correctly — see IP allowlist below.

IP allowlist

Bybit lets you restrict an API key to specific IPs. CubeTerminal is a hosted web app, so your Bybit requests originate from CubeTerminal's servers — not your browser. Whitelist these two IPs:

  • 208.77.244.15 — CubeTerminal app (REST)
  • 162.220.232.99 — Exchange WS Proxy (WebSocket)

In Bybit: API Management → edit key → IP Restriction → paste both IPs comma-separated → save.

⚠️

Whitelisting your home IP instead will block every trade. The requests come from our servers, not your machine.

See the Binance IP allowlist section for the full explanation — same two IPs apply to all three CEX keys (Binance, Bybit, Bitget).

v5 API specifics

settleCoin requirement

The v5 Positions endpoint requires a settleCoin parameter — USDT for the linear book, USDC for USDC-margined perps, and BTC/ETH/SOL for inverse. The terminal fans out requests per settle coin so the Positions widget shows everything in one list without you needing to pick a category.

Stop-order trigger semantics

Bybit v5 uses triggerDirection (1 = rise, 2 = fall) instead of inferring direction from the price. The terminal computes this automatically from your stop price vs. the current mark:

  • Stop price above mark → trigger on rise (exit longs, enter shorts)
  • Stop price below mark → trigger on fall (exit shorts, enter longs)

Settlement lag

Closed positions continue appearing in the position list for a few seconds after close while Bybit settles PnL. The terminal polls until the position amount is truly zero before removing the row.

Builder-dex tickers

Bybit's builder-dex feature exposes equity perps (Tesla, Apple, MSFT, Nvidia, etc.) behind a namespaced prefix:

xyz:TSLA
xyz:AAPL
xyz:NVDA

These symbols route to a dedicated book. In CubeTerminal:

  • Search for them in the Symbols widget — they appear alongside crypto pairs
  • The symbol prefix must stay lowercase (xyz:TSLA, not XYZ:TSLA) — Bybit's matching engine rejects uppercased prefixes
  • Chart, order book, and Trade Entry all work identically to crypto perps

Builder-dex tickers respect US equity market hours. Outside market hours the book thins out or pauses; orders placed against a paused book will sit idle until the market reopens.

Sub-accounts

Bybit sub-accounts are supported by adding each sub-account's API key as a separate connection. The Accounts widget aggregates balances across every connected key, tagged by account label.

Troubleshooting

"Invalid signature" errors

Usually a clock-skew issue on the host machine. Sync your system clock — v5 rejects requests where the client timestamp drifts more than a few seconds from server time.

Orders rejected with "insufficient available balance"

Check you are trading in the correct account type (Unified vs. Classic). Bybit separates balances by account mode and the terminal follows whichever mode the API key was issued for.

No position rows after closing

Expected for a few seconds — see settlement lag above.