Business error codes returned in the code field of every API response
All API responses follow this envelope:
{
"code": 200000,
"message": "Success",
"data": { ... }
}
A code of 200 or 200000 indicates success. Any other value indicates an error. The message field contains a human-readable description.
Error Codes
Common (400xxx)
| Code | Message |
|---|---|
400000 | Invalid parameter — refer to the API documentation |
400001 | Daily time limit exceeded |
400002 | Page size exceeds the allowed limit |
400003 | Page number exceeds the allowed limit |
400004 | startTime must be earlier than endTime |
400005 | startTime must not be in the future |
400006 | endTime must be in the future |
400007 | Invalid limit value |
400008 | Request error |
400009 | Missing required parameter — refer to the API documentation |
400010 | Exchange error |
400011 | Order processing is temporarily unavailable — please try again |
400012 | Service is temporarily unavailable while loading data |
Authentication & API Key (2xxx / 4xxx / 7xxx / 1000xx)
| Code | Message |
|---|---|
500 | Server error |
501 | Client error |
2000 | API verification failed |
2001 | Your IP address is not on this API key's whitelist |
2002 | API authorization invalid |
4000 | Invalid login session |
7000 | Nonce is invalid |
100001 | Portfolio does not exist |
100002 | Invalid user status |
100003 | Invalid user type |
100018 | API key not found |
100041 | API key has been frozen — please contact your account manager |
100429 | Too many requests |
Trading (4010xx)
| Code | Message |
|---|---|
401000 | Invalid portfolioId |
401001 | clientOrderId must be fewer than 64 characters |
401002 | Invalid side |
401003 | Invalid orderType |
401004 | Invalid timeInForce |
401005 | Invalid orderQty |
401006 | Invalid limitPrice |
401007 | orderId must be exactly 16 digits |
401008 | Either orderId or clientOrderId must be provided |
401009 | clientOrderId already exists |
401010 | Portfolio not found for this user |
401011 | Symbol not supported |
401012 | Price is invalid |
401013 | Order quantity precision exceeds the minimum allowed |
401014 | Order quantity is below the minimum |
401015 | Order price precision exceeds the minimum allowed |
401016 | Order price is below the minimum |
401017 | Order amount should be greater than the min notional |
401018 | Order not found |
401019 | This order cannot be cancelled |
401020 | Invalid orderId value |
401021 | Invalid quoteOrderQty |
401023 | Invalid exchange type |
401025 | Order quantity exceeds the maximum |
401026 | Order notional value exceeds the maximum market quote size |
401027 | Order quantity exceeds the maximum market base size |
401028 | Order notional value is below the minimum market quote size |
401029 | Order quantity is below the minimum market base size |
401031 | Precision information not found |
401032 | Position not found |
401033 | Invalid leverage |
401034 | Requested leverage exceeds the maximum allowed |
401035 | Asset does not exist |
401036 | Insufficient available balance to set this leverage |
401037 | Leverage must be set before placing orders |
401038 | An open close order exists — cancel it before proceeding |
401042 | Market orders do not support GTX time-in-force |
401043 | An open order exists — cancel it before proceeding |
401044 | Open order count exceeds the limit |
401045 | Account is under risk control — order placement is suspended |
401046 | Exchange account not initialized — transfer funds to this portfolio first |
401047 | Reduce-only orders must be in the opposite direction of the current position |
401048 | Cannot place a reduce-only order when position quantity is zero |
401049 | Invalid reduceOnly value |
401051 | clientOrderId may only contain letters and numbers |
401052 | GTX order rejected — could not be filled as maker |
401053 | Exchange account is restricted — unable to close position |
401055 | Insufficient available balance |
401056 | Unrealised loss is too large — available margin would be insufficient |
401057 | Insufficient frozen balance |
401058 | Insufficient available margin |
401060 | Position notional exceeds the limit for the current leverage — reduce leverage |
401061 | Order placement is forbidden for this portfolioId |
401062 | Insufficient exchange account balance |
401064 | No account found matching the specified criteria |
401067 | Unsupported business type |
401070 | Open position exceeds the maximum notional limit |
401071 | Order quantity must be a multiple of lotSize |
401072 | Order state or type does not allow replacement |
401073 | Replacement quantity or price is the same as the original |
401074 | Invalid replacement price or quantity |
401075 | Order price must be a multiple of tickSize |
401076 | Replace order failed — insufficient available balance |
401077 | Replacement quantity cannot be less than the already-executed quantity |
401078 | Replace order failed — insufficient available margin |
401082 | Invalid orderId |
401085 | User borrowing limit reached |
401086 | Tier borrowing limit reached |
401087 | Invalid loan currency |
401088 | Invalid positionMode |
401089 | Change failed — cancel all open orders and close all positions first |
401091 | Invalid positionSide — position mode is BOTH, so positionSide must be LONG or SHORT |
401092 | Order would cause the exchange open-interest limit to be exceeded |
401094 | Position mode is already set to the requested value |
401096 | Invalid positionSide |
401097 | No open position to close — position quantity is zero |
401102 | Invalid subPortfolioId |
Strategy / Algo Orders (4012xx)
| Code | Message |
|---|---|
401200 | Invalid algo provider |
401201 | Invalid algo order type |
401202 | Invalid algo parameters |
401203 | Algo order not found |
401204 | Open algo order count exceeds the limit |
401205 | Algo provider is inactive |
401206 | algoOrderId is required |
401207 | Invalid algoOrderId |
401208 | Either algoOrderId or clientOrderId must be provided |
401209 | Invalid order state |
401214 | At least one of tpTriggerPrice or slTriggerPrice must be provided |
401215 | Invalid take-profit trigger price |
401218 | Invalid stop-loss trigger price |
401221 | Algo order not found |
401231 | Algo orders cannot be replaced |
401232 | Attached TP/SL does not support close-all-position |
401235 | TP/SL close-position orders must use market price |
401238 | A TP/SL close-position order already exists |
401444 | Unknown error |
Portfolio Management (402xxx)
| Code | Message |
|---|---|
402000 | Portfolio name cannot be empty |
402001 | Portfolio name already exists |
402003 | Portfolio does not belong to this user |
402004 | Portfolio name cannot exceed 64 characters |
402005 | portfolioId is required |
402006 | portfolioId not found |
402007 | Portfolio count exceeds the limit |
402008 | subPortfolioId is required |
Transfers (403xxx)
| Code | Message |
|---|---|
403000 | Source and target portfolioId cannot both be empty |
403001 | Invalid source portfolioId |
403002 | Invalid target portfolioId |
403003 | Invalid source transfer type |
403004 | Invalid target transfer type |
403005 | Invalid amount |
403006 | Source portfolio not found for this user |
403007 | Target portfolio not found for this user |
403008 | Self-transfer is not allowed |
403009 | Source and target are identical — transfer is not meaningful |
403010 | Currency not supported |
403011 | Amount precision exceeds the allowed maximum |
403012 | Amount is below the minimum allowed |
403013 | Insufficient transferable balance |
403014 | Invalid transferId |
403015 | Invalid requestId |
403016 | requestId must be fewer than 64 characters |
Fees (406xxx)
| Code | Message |
|---|---|
406000 | Cannot set broker fee for the main portfolio |
406001 | Invalid change type |
406002 | At least one of chgMaker or chgTaker must be provided |
406003 | Fixed add-on must be between 0.00 bp and 1000 bp |
406004 | Fixed add-on precision must be 0.01 bp |
406009 | Invalid date format |
406010 | Use /api/v1/broker/feeRate for broker users |
406011 | This endpoint is only available to broker users |
406012 | This endpoint is not available to broker users |
406013 | No valid exchange index prices found |
WebSocket (601xxx)
| Code | Message |
|---|---|
601001 | Invalid parameter — refer to the API documentation |
601002 | Subscribe/unsubscribe inst field is empty |
601003 | Subscribe/unsubscribe inst value is invalid |
601005 | Subscription list exceeds the maximum of 20 instruments |
601006 | Invalid channel |
601007 | API key not found |
601008 | Missing required field |
601009 | Login failed |
601010 | Connection frequency too high |
601011 | Operation not supported |
601014 | Subscription string too long |
601015 | Maximum number of subscriptions exceeded |
601016 | Login failed — invalid nonce |
601017 | Login failed — nonce is empty |
601018 | Login failed — signature is empty |
