BitMex — Futures with Testnet
BitMex was the first major crypto derivatives exchange and still runs the cleanest Bitcoin-margined futures market in the industry. TVH supports BitMex's live and testnet environments as two separate exchange identifiers. No spot trading on BitMex — futures only.
- 2 exchange identifiers:
bitmex,bitmex-testnet - No spot trading — BitMex is derivatives-only
- Symbol uses XBT (not BTC) — legacy naming
- Testnet has full feature parity — separate site, separate API key
- All variants use
https://alerts.tv-hub.org
Variants
- Live
- Testnet
BitMex Live
| Field | Value |
|---|---|
| Exchange identifier | bitmex |
| Webhook URL | https://alerts.tv-hub.org |
| Symbol format | XBTUSD (perpetual), XBTM26 (quarterly) — XBT not BTC |
| Contract types | Perpetual + Quarterly Futures |
| Max leverage | 100× on XBT pairs, lower on alts |
| Permissions | Order + OrderCancel |
| Sub-account support | ❌ Not supported in TVH |
| Demo support | Use bitmex-testnet identifier |
Webhook URL:
API key creation
BitMex has no third-party binding; an IP/CIDR restriction is optional. No passphrase.
-
Log in at bitmex.com and open Account from the top navigation.

-
In the Account sidebar, open API Keys.

-
Click Create an API Key, give it a name, set Key Permissions to Order (this allows placing and cancelling orders), and leave Withdraw off. CIDR is optional — leave it blank to allow all IPs, or pin it to the TVH IPs. Confirm with your 2FA token and click Create API Key.

-
Write down the Secret immediately — BitMex shows it only once.
-
Add the Key + Secret to TVH at Account → Settings → API Keys with exchange
bitmex(no passphrase needed).
Symbol format reference
| Pair | Perpetual | Quarterly (Jun 2026) |
|---|---|---|
| BTC/USD | XBTUSD | XBTM26 |
| ETH/USD | ETHUSD | ETHM26 |
| SOL/USD | SOLUSD | — |
XBT is the legacy ISO-4217 unofficial code for Bitcoin. BitMex never moved to BTC; the codebase still uses XBT. Every BTC pair on BitMex starts with XBT instead.
Example payload:
{
"token": "your-tvh-token",
"exchange": "bitmex",
"pair": "XBTUSD",
"isMarket": true,
"isBuy": true,
"units": 100,
"leverage": 10,
"marginType": "isolated"
}
BitMex contracts are sized in USD value per contract (e.g. 1 XBTUSD contract = $1 of BTC exposure). When you set "units": 100, that's 100 contracts = $100 of notional. This differs from most other exchanges where units is the underlying coin amount.
BitMex Testnet
| Field | Value |
|---|---|
| Exchange identifier | bitmex-testnet |
| Webhook URL | https://alerts.tv-hub.org |
| Site | testnet.bitmex.com |
| Symbol format | Same as live (XBTUSD, etc.) |
| Test funds | Free test-XBT from BitMex faucet |
| Feature parity | Full — same payload shape works |
BitMex Testnet runs on a fully separate domain with its own accounts and its own API keys. Use bitmex-testnet as the exchange identifier.
Example payload:
{
"token": "your-tvh-token",
"exchange": "bitmex-testnet",
"pair": "XBTUSD",
"isMarket": true,
"isBuy": true,
"units": 100,
"leverage": 5
}
Setup
Create an account at testnet.bitmex.com (separate from live) and use the faucet to get free test-XBT. The API-key flow is identical to live — just on the testnet site.
-
On the testnet site, open Account from the top navigation.
-
Open API Keys in the Account sidebar.

-
Click Create an API Key, name it, set Key Permissions to Order, leave Withdraw off (CIDR optional), and confirm with 2FA.

-
Write down the Secret immediately — it's shown only once.
-
Add the Key + Secret to TVH with exchange
bitmex-testnet(do not tick Demo Account — the testnet identifier already routes to testnet), then use"exchange": "bitmex-testnet"in your payload.
Common BitMex quirks
- XBT, not BTC. Every Bitcoin pair starts with XBT. Don't paste
BTCUSD— it won't resolve. - Cross-margin via the leverage slider. On BitMex, dragging the leverage slider all the way to the left (= 0) sets cross-margin. Any non-zero value sets isolated at that leverage. TVH respects whatever you set in
marginType+leverage. - Contracts, not coins. BitMex sizes positions in contracts (USD-denominated value), not in BTC.
"units": 100onXBTUSD= $100 notional, not 100 BTC. useFixedSizeis awkward. Since contracts are USD-denominated, "fixed quote size" already maps to the contract count. TVH still accepts the flag but it's redundant on BitMex.- 100% Bitcoin-margined PnL. All positions settle in XBT. Your PnL is denominated in XBT, not USD.
- No sub-accounts in TVH. BitMex has sub-accounts on the exchange, but TVH doesn't currently route to them.
Feature support
| Feature | Live | Testnet |
|---|---|---|
| Market & Limit orders | ✅ | ✅ |
| Multiple TPs | ✅ | ✅ |
| Trailing Stop | ✅ | ✅ |
| Scaled Orders | ✅ | ✅ |
useFixedSize | ✅ (redundant — see above) | ✅ |
useEntireAccountBalance | ❌ | ❌ |
| Hedge Mode | ❌ Not supported | ❌ |
| Sub-Accounts | ❌ | ❌ |
| Limit Order Chasing | ✅ | ✅ |
| Demo Account checkbox | ❌ (use testnet id) | ❌ |
Full matrix: Exchange Quirks Reference.
Related
- Common Setup — universal flow
- TradeCommand Futures options —
leverage,marginType - Exchange Quirks Reference