Overview
How to use the generated Spot Trading API OpenAPI reference on this site.
The REST reference lists every gateway operation published for Spot Trading API, grouped in sections: Market Data, Trading, Funding, WebSockets Authentication. Server: https://gateway.bit2me.com.
| Section | What it is |
|---|---|
| Market Data | Markets, candles, order book, tickers, last trades. No API key needed. Historical OHLCV: Fetch market data (limit maximum 1000) |
| Trading | Create, get and cancel orders; trades |
| Funding | Wallet ↔ Pro: POST /v1/trading/wallet/deposit (fromPocketId, amount, currency) and POST /v1/trading/wallet/withdraw (amount, currency, optional toPocketId). Also balance, working capital, movements. Walkthrough: First order |
| WebSockets Authentication | POST /v1/signin/apikey: token for the Pro WebSocket, valid 1 minute |
Pro deposit and withdraw move funds between Wallet and Pro, not to an external chain. External crypto out is address book or Wallet legacy.
Per-endpoint limits are on Rate limits, and the order error codes on Errors.
Playground
Market data needs no key. For Trading and Funding, enter your key and secret under Authorization once; the playground signs every request in your browser until you reload. It calls production, and write requests stay blocked until you allow them. See Playground.
Samples
Each operation shows generated request samples. Official samples: trading-spot-samples (node/auth, node/rest/{market-data,trading,funding,ws-auth}, node/ws/{public,private}).
The older bit2me-api-node-tool repository is discontinued. Cite it only as a historical HMAC helper, not as an SDK.
Postman
Import the OpenAPI specification into Postman:
- By link: in Postman, go to Import → Link and paste
https://gateway.bit2me.com/docs/openapi.json. - By file: download openapi.json, then Import → File.
Postman does not compute the HMAC signature for you: add a pre-request script that signs each call, as in Authentication.
Changelog
Deprecated Spot Trading API endpoints and what to use instead.
Get OHLCV candles GET
Returns OHLCV candles (open, high, low, close, volume) of a market between `startTime` and `endTime`. No authentication is required. Sort by the timestamp (`[0]`) before plotting. The last candle is the current one and is still changing. Intervals with no trades produce no candle, so the series can have gaps: fill them on the client if a continuous series is needed. A request returns at most `limit` candles. To cover a longer range, split it into windows of `limit * interval` and request them one after another.