MCP Server
MCP (Model Context Protocol) is a standardized protocol that allows AI clients to securely call external tools. toobit-trade-mcp implements this protocol, providing 66 trading tools for AI use.
Launch Options
| Use Case | Command |
|---|---|
| Market data only (no Key needed) | toobit-trade-mcp --modules market |
| Full functionality | toobit-trade-mcp --modules all |
| Read-only monitoring | toobit-trade-mcp --read-only |
| Spot only | toobit-trade-mcp --modules market,spot |
| Futures only | toobit-trade-mcp --modules market,futures |
| Specific profile | toobit-trade-mcp --profile sub --modules all |
| Disable logging | toobit-trade-mcp --modules all --no-log |
Permissions
The market module requires no API Key — all endpoints are publicly accessible. Other modules require API Key read permissions; write operations (placing orders, canceling, etc.) also require trade permissions.
Symbol Format
| Endpoint Type | Symbol Format | Example |
|---|---|---|
| Spot (ticker, depth, candles, orders, etc.) | No separator, uppercase | BTCUSDT, ETHUSDT |
| Futures (funding rate, mark price, open interest, long-short ratio, contract ticker, insurance fund, risk limits, place order, positions, leverage, etc.) | Contract format with hyphens | BTC-SWAP-USDT, ETH-SWAP-USDT |
Futures-specific tools in the market module (market_get_mark_price, market_get_funding_rate, market_get_open_interest, market_get_long_short_ratio, market_get_contract_ticker_*, market_get_insurance_fund, market_get_risk_limits) and all futures_* tools require the contract symbol format BTC-SWAP-USDT.
Tool Reference
market — Market Data (21 tools, public)
| Tool | Description |
|---|---|
market_get_server_time | Get Toobit server time |
market_get_exchange_info | Trading rules and symbol information |
market_get_depth | Order book depth |
market_get_merged_depth | Merged order book depth |
market_get_trades | Recent trades |
market_get_klines | Candlestick (OHLCV) data |
market_get_ticker_24hr | 24h price change statistics |
market_get_ticker_price | Latest price |
market_get_book_ticker | Best bid/ask price |
market_get_index_klines | Index candlesticks |
market_get_mark_price | Mark price |
market_get_mark_price_klines | Mark price candlesticks |
market_get_funding_rate | Current funding rate |
market_get_funding_rate_history | Historical funding rates |
market_get_open_interest | Open interest |
market_get_long_short_ratio | Long/short ratio |
market_get_contract_ticker_24hr | Futures 24h ticker |
market_get_contract_ticker_price | Futures latest price |
market_get_index_price | Index price |
market_get_insurance_fund | Insurance fund balance |
market_get_risk_limits | Risk limit configuration |
spot — Spot Trading (10 tools)
| Tool | Description | Type |
|---|---|---|
spot_place_order | Place spot order (LIMIT / MARKET / LIMIT_MAKER) | Write |
spot_place_order_test | Test order (not actually submitted) | Read |
spot_batch_orders | Batch place orders | Write |
spot_cancel_order | Cancel order | Write |
spot_cancel_open_orders | Cancel all open orders | Write |
spot_cancel_order_by_ids | Batch cancel by IDs | Write |
spot_get_order | Query single order | Read |
spot_get_open_orders | Query open orders | Read |
spot_get_trade_orders | Query order history | Read |
spot_get_fills | Query trade records | Read |
futures — USDT-M Perpetual Futures (25 tools)
| Tool | Description | Type |
|---|---|---|
futures_place_order | Open/close position (BUY_OPEN / SELL_CLOSE, etc.) | Write |
futures_batch_orders | Batch place orders | Write |
futures_cancel_order | Cancel order | Write |
futures_cancel_all_orders | Cancel all orders | Write |
futures_cancel_order_by_ids | Batch cancel by IDs | Write |
futures_amend_order | Amend order | Write |
futures_get_order | Query single order | Read |
futures_get_open_orders | Query open orders | Read |
futures_get_history_orders | Query order history | Read |
futures_get_positions | Query current positions | Read |
futures_get_history_positions | Query position history | Read |
futures_set_leverage | Set leverage | Write |
futures_get_leverage | Query leverage settings | Read |
futures_set_margin_type | Switch isolated/cross margin | Write |
futures_adjust_margin | Adjust margin | Write |
futures_set_trading_stop | Set take-profit/stop-loss | Write |
futures_flash_close | Flash close position | Write |
futures_reverse_position | Reverse position | Write |
futures_auto_add_margin | Auto add margin | Write |
futures_get_fills | Query trade records | Read |
futures_get_balance | Query futures balance | Read |
futures_get_balance_flow | Query balance flow | Read |
futures_get_commission_rate | Query commission rate | Read |
futures_get_today_pnl | Query today's PnL | Read |
account — Account Management (10 tools)
| Tool | Description | Type |
|---|---|---|
account_get_info | Query spot account balance | Read |
account_get_balance_flow | Query balance flow | Read |
account_get_sub_accounts | Query sub-account list | Read |
account_sub_transfer | Parent-child account transfer | Write |
account_check_api_key | Verify API Key info | Read |
account_withdraw | Withdraw | Write |
account_get_deposit_address | Query deposit address | Read |
account_get_deposit_orders | Query deposit records | Read |
account_get_withdraw_orders | Query withdrawal records | Read |
trade_get_history | Query local audit log | Read |
system — System
| Tool | Description |
|---|---|
system_get_capabilities | Returns server capability snapshot (module availability, auth status, read-only mode, etc.) |