Skip to main content

Error Codes and Descriptions

This section defines the error codes you may encounter when working with the WebServices API.

The table below defines the error codes that you may encounter when making any of the API calls described in Section 4 and Section 5.

CodeDefinition
UNKNOWN_ERRORAn unknown server error has occured.
INVALID_REQUESTA request validation failure has occured. The possible error descriptions are as following.
NOT_ENOUGH_RIGHTSThe manager who has made the request does not have sufficient rights to perform the requested operation.
CH_BROKER_NOT_FOUNDThe cTrader backend cannot find the broker that the request concerns.

The following table defines the error codes that can only be encountered when making certain calls described in Section 4 and Section 5.

CodeAPI Call(s)Definition
REQUEST_FREQUENCY_EXCEEDEDAny call with a non-GET method.The client has exceeded the request rate limiter (only applies to non-GET requests).
TRADER_NOT_FOUNDAny API call with the login parameter and/or the traderLogin/login keys in the request body.The requested trader is not found.
CH_PLANT_INVALIDAny API calls with the brokerName key in the request body.The cTrader backend cannot find a broker with brokerName at the plant to which the request is made.

Error Codes for Operations with Accounts

The following errors can only be encountered when making certain API call(s) described in Section 4.

CodeAPI Call(s)Definition
NOT_ENOUGH_MONEYAPI calls 4.7 and 4.13.A trader does not have sufficient funds to perform the requested operation or has open positions generating unrealized PnL.
CHANGE_BALANCE_BAD_AMOUNTAPI call 4.7The requested balance change amount is invalid (e.g., if it is less than zero).
TRADER_GROUP_NOT_FOUNDAPI call 4.3The requested trader group is not found.
WRONG_PASSWORDAPI call 4.9The password submitted in the request body is incorrect.

Error Codes for Operations with cTID

You may encounter the following error codes when making certain API calls described in Section 5.

CodeAPI Call(s)Definition
CID_DEFAULT_REGION_NOT_FOUNDAPI call 5.1The plant to which the request is made is lacking a default region in its configuration.
CH_CTID_ALREADY_CONFIRMEDAPI call 5.1The value of the email
CANT_ROUTE_REQUESTAPI call 5.2The environment with the specified environmentName is not found.
INSUFFICIENT_PERMISSIONSAPI call 5.2The broker with the specified brokerName does not have access to the trader with the specified traderLogin.
CH_TRADER_ACCOUNT_CANNOT_BE_LINKEDAPI call 5.2The trader with the specified traderLogin has already been linked.
CH_TRADER_ACCOUNT_NOT_FOUNDAPI calls 5.2 and 5.3The trader with the specified traderLogin is not found.
CH_CTID_TRADER_ACCOUNT_NOT_FOUNDAPI call 5.3The trader with the specified ctidTraderAccountId is not found.