Error codes for Binance SPOT Testnet
Errors consist of two parts: an error code and a message. Codes are universal, but messages can vary. Here is the error JSON payload:
{
"code": -1121,
"msg": "Invalid symbol."
}
10xx - General Server or Network issues
-1000 UNKNOWN
- An unknown error occurred while processing the request.
-1001 DISCONNECTED
- Internal error; unable to process your request. Please try again.
-1002 UNAUTHORIZED
- You are not authorized to execute this request.
-1003 TOO_MANY_REQUESTS
- Too many requests queued.
- Too much request weight used; current limit is %s request weight per %s. Please use WebSocket Streams for live updates to avoid polling the API.
- Way too much request weight used; IP banned until %s. Please use WebSocket Streams for live updates to avoid bans.
-1006 UNEXPECTED_RESP
- An unexpected response was received from the message bus. Execution status unknown.
-1007 TIMEOUT
- Timeout waiting for response from backend server. Send status unknown; execution status unknown.
-1008 SERVER_BUSY
- Server is currently overloaded with other requests. Please try again in a few minutes.
-1013 INVALID_MESSAGE
- The request is rejected by the API. (i.e. The request didn't reach the Matching Engine.)
- Potential error messages can be found in Filter Failures or Failures during order placement.
-1014 UNKNOWN_ORDER_COMPOSITION
- Unsupported order combination.
-1015 TOO_MANY_ORDERS
- Too many new orders.
- Too many new orders; current limit is %s orders per %s.
-1016 SERVICE_SHUTTING_DOWN
- This service is no longer available.
-1020 UNSUPPORTED_OPERATION
- This operation is not supported.
-1021 INVALID_TIMESTAMP
- Timestamp for this request is outside of the recvWindow.
- Timestamp for this request was 1000ms ahead of the server's time.
-1022 INVALID_SIGNATURE
- Signature for this request is not valid.
-1033 COMP_ID_IN_USE
SenderCompId(49)is currently in use. Concurrent use of the same SenderCompId within one account is not allowed.
-1034 TOO_MANY_CONNECTIONS
- Too many concurrent connections; current limit is '%s'.
- Too many connection attempts for account; current limit is %s per '%s'.
- Too many connection attempts from IP; current limit is %s per '%s'.
-1035 LOGGED_OUT
- Please send Logout
<5>message to close the session.
11xx - Request issues
-1100 ILLEGAL_CHARS
- Illegal characters found in a parameter.
- Illegal characters found in parameter '%s'; legal range is '%s'.
-1101 TOO_MANY_PARAMETERS
- Too many parameters sent for this endpoint.
- Too many parameters; expected '%s' and received '%s'.
- Duplicate values for a parameter detected.
-1102 MANDATORY_PARAM_EMPTY_OR_MALFORMED
- A mandatory parameter was not sent, was empty/null, or malformed.
- Mandatory parameter '%s' was not sent, was empty/null, or malformed.
- Param '%s' or '%s' must be sent, but both were empty/null!
- Required tag '%s' missing.
- Field value was empty or malformed.
- '%s' contains unexpected value. Cannot be greater than %s.
-1103 UNKNOWN_PARAM
- An unknown parameter was sent.
- Undefined Tag.
-1104 UNREAD_PARAMETERS
- Not all sent parameters were read.
- Not all sent parameters were read; read '%s' parameter(s) but was sent '%s'.
-1105 PARAM_EMPTY
- A parameter was empty.
- Parameter '%s' was empty.
-1106 PARAM_NOT_REQUIRED
- A parameter was sent when not required.
- Parameter '%s' sent when not required.
- A tag '%s' was sent when not required.
-1108 PARAM_OVERFLOW
- Parameter '%s' overflowed.
-1111 BAD_PRECISION
- Parameter '%s' has too much precision.
-1112 NO_DEPTH
- No orders on book for symbol.
-1114 TIF_NOT_REQUIRED
- TimeInForce parameter sent when not required.
-1115 INVALID_TIF
- Invalid timeInForce.
-1116 INVALID_ORDER_TYPE
- Invalid orderType.
-1117 INVALID_SIDE
- Invalid side.
-1118 EMPTY_NEW_CL_ORD_ID
- New client order ID was empty.
-1119 EMPTY_ORG_CL_ORD_ID
- Original client order ID was empty.
-1120 BAD_INTERVAL
- Invalid interval.
-1121 BAD_SYMBOL
- Invalid symbol.
-1122 INVALID_SYMBOLSTATUS
- Invalid symbolStatus.
-1125 INVALID_LISTEN_KEY
- This listenKey does not exist.
-1127 MORE_THAN_XX_HOURS
- Lookup interval is too big.
- More than %s hours between startTime and endTime.
-1128 OPTIONAL_PARAMS_BAD_COMBO
- Combination of optional parameters invalid.
- Combination of optional fields invalid. Recommendation: '%s' and '%s' must both be sent.
- Fields [%s] must be sent together or omitted entirely.
- Invalid
MDEntryType (269)combination. BID and OFFER must be requested together. - Conflicting fields: ['%s'...]
-1130 INVALID_PARAMETER
- Invalid data sent for a parameter.
- Data sent for parameter '%s' is not valid.
-1134 BAD_STRATEGY_TYPE
strategyTypewas less than 1000000.TargetStrategy (847)was less than 1000000.
-1135 INVALID_JSON
- Invalid JSON Request.
- JSON sent for parameter '%s' is not valid
-1139 INVALID_TICKER_TYPE
- Invalid ticker type.
-1145 INVALID_CANCEL_RESTRICTIONS
cancelRestrictionshas to be eitherONLY_NEWorONLY_PARTIALLY_FILLED.
-1151 DUPLICATE_SYMBOLS
- Symbol is present multiple times in the list.
-1152 INVALID_SBE_HEADER
- Invalid
X-MBX-SBEheader; expected<SCHEMA_ID>:<VERSION>. - Invalid SBE message header.
-1153 UNSUPPORTED_SCHEMA_ID
- Unsupported SBE schema ID or version specified in the
X-MBX-SBEheader. - Invalid SBE schema ID or version specified.
-1155 SBE_DISABLED
- SBE is not enabled.
-1158 OCO_ORDER_TYPE_REJECTED
- Order type not supported in OCO.
- If the order type provided in the
aboveTypeand/orbelowTypeis not supported.
-1160 OCO_ICEBERGQTY_TIMEINFORCE
- Parameter '%s' is not supported if
aboveTimeInForce/belowTimeInForceis not GTC. - If the order type for the above or below leg is
STOP_LOSS_LIMIT, andicebergQtyis provided for that leg, thetimeInForcehas to beGTCelse it will throw an error. TimeInForce (59)must beGTC (1)whenMaxFloor (111)is used.
-1161 DEPRECATED_SCHEMA
- Unable to encode the response in SBE schema 'x'. Please use schema 'y' or higher.
-1165 BUY_OCO_LIMIT_MUST_BE_BELOW
- A limit order in a buy OCO must be below.
-1166 SELL_OCO_LIMIT_MUST_BE_ABOVE
- A limit order in a sell OCO must be above.
-1168 BOTH_OCO_ORDERS_CANNOT_BE_LIMIT
- At least one OCO order must be contingent.
-1169 INVALID_TAG_NUMBER
- Invalid tag number.
-1170 TAG_NOT_DEFINED_IN_MESSAGE
- Tag '%s' not defined for this message type.
-1171 TAG_APPEARS_MORE_THAN_ONCE
- Tag '%s' appears more than once.
-1172 TAG_OUT_OF_ORDER
- Tag '%s' specified out of required order.
-1173 GROUP_FIELDS_OUT_OF_ORDER
- Repeating group '%s' fields out of order.
-1174 INVALID_COMPONENT
- Component '%s' is incorrectly populated on '%s' order. Recommendation: '%s'
-1175 RESET_SEQ_NUM_SUPPORT
- Continuation of sequence numbers to new session is currently unsupported. Sequence numbers must be reset for each new session.
-1176 ALREADY_LOGGED_IN
- Logon
<A>should only be sent once.
-1177 GARBLED_MESSAGE
CheckSum(10)contains an incorrect value.BeginString (8)is not the first tag in a message.MsgType (35)is not the third tag in a message.BodyLength (9)does not contain the correct byte count.- Only printable ASCII characters and SOH (Start of Header) are allowed.
- Tag specified without a value.
- Invalid encodingType.
-1178 BAD_SENDER_COMPID
SenderCompId(49)contains an incorrect value. The SenderCompID value should not change throughout the lifetime of a session.
-1179 BAD_SEQ_NUM
MsgSeqNum(34)contains an unexpected value. Expected: '%d'.