概览
What is Bitkub Trading MCP?
Bitkub Trading MCP is an MCP server that exposes Bitkub’s REST and WebSocket endpoints as tools, built with Bun + TypeScript and the official @modelcontextprotocol/sdk, served over stdio. It is read-only by design — it never places orders, cancels orders, generates addresses, or initiates withdrawals. It is intended for users who want to query Bitkub exchange data (market data, account balances, order history, etc.) via an AI assistant (e.g., Claude) without risking fund movement.
How to use Bitkub Trading MCP?
Install via npx with an MCP client. The quickest method is using the Claude Code CLI: claude mcp add bitkub-trading-mcp -- npx -y bitkub-trading-mcp. For full features, add environment variables BITKUB_API_KEY and BITKUB_API_SECRET. Manual configuration is also supported by editing the client’s mcpServers JSON block. Requires Node.js 20+. Public tools work without an API key; secure tools require the key and secret in the env block (never as tool arguments).
Key features of Bitkub Trading MCP
- Provides 9 public REST tools (market data, status, ticker, etc.)
- Offers 12 secure read-only REST tools (balances, orders, history)
- Includes one public WebSocket ticker snapshot tool
- Exposes two private WebSocket tools (order updates, match updates)
- WebSocket tools are snapshot‑based, stateless, with configurable duration
- Auth signing uses HMAC‑SHA256 (v3 and v4)
- Concurrency cap of 5 private WebSocket connections per API key
Use cases of Bitkub Trading MCP
- Check current market prices, order books, and recent trades
- View wallet balances (crypto and fiat) without exposing private keys
- Review open orders, order history, and individual order details
- Monitor real‑time ticker data for a specific trading pair
- Observe order and match update events for active trading sessions
FAQ from Bitkub Trading MCP
Why is the server read‑only?
The server intentionally omits endpoints that place, cancel, or modify orders, and never initiates withdrawals or address generation. Even with a key that has full trading permissions, Bitkub Trading MCP cannot move money or submit orders — only data‑retrieval and observation endpoints are implemented.
What if I don’t provide an API key?
Without BITKUB_API_KEY and BITKUB_API_SECRET set, the 9 public REST tools and the public WebSocket ticker tool work immediately. The 12 secure REST tools and 2 private WebSocket tools register but each call returns an auth error explaining how to add the env block.
What are the runtime requirements?
Node.js 20 or later is required. The MCP client downloads the package via npx on first launch; no manual clone or build is needed.
Where does the data come from?
Data is fetched live from Bitkub’s REST (v3/v4) and WebSocket APIs. The tool does not cache or store any data; every call hits the Bitkub exchange endpoints.
How do WebSocket tools work?
Each call opens a WebSocket, collects events for a bounded duration (default 10–30 seconds depending on tool), then closes. They are stateless — no long‑lived subscriptions or MCP notifications. The private streams deliver only events that occur after the subscribe message is sent; they do not replay history.