Trade error codes
The code values returned on RFS quote and order responses.
These are the code values carried on RFS quote and order responses over the
WebSocket. They do not apply to the REST API, which reports failures as a
resultCode on its own scale.
A code beginning RFS comes from the quoting and execution service, and one
beginning PRE from the pre-deal checks that run before an order is accepted —
limits, permissions and instrument availability.
Error frame
Sent as messageType: "error". It is the frame a code arrives in when the
request has no response of its own to carry it.
It is almost entirely an order frame. Six of the eight paths that produce
one only fire on an order request, and the price channel does not use it at
all — a refused subscribe answers SubscribeResponse with success: false, and
a refused unsubscribe answers nothing. See the
price channel.
You will receive one when:
- a
messageTypethe gateway does not handle is sent —messageisUnsupported message typeandcodeisRFS500001 - an order fails validation, carrying the validator's own code
- an order is refused for per-session capacity, or throttled by the rate limit
- an order carries a
clientRequestIdorsessionIdthat is too long or holds a control character - handling threw anywhere the gateway has no more specific answer
- the connection fails to authenticate. This one carries
messageand nothing else, and the socket closes immediately after it
Correlation is best-effort, so match on what is present rather than expecting
it. Which of clientRequestId, quoteId and transactionId are filled in
depends on the path, and the generic handling failure fills in none of them.
code itself is empty on the authentication frame, which is the one case where
a code cannot be looked up below.
| Field | Type | Notes |
|---|---|---|
messageType | string | Always error |
message | string | Human-readable detail. Where the source text contains %s, the offending value is substituted at the point of failure |
clientRequestId | string | Your own reference from the order this answers, when the path that produced the frame had it to hand |
code | string | The code, from the table below. Empty when the connection failed to authenticate |
quoteId | string | The quote from the order this answers, on the same terms |
transactionId | string | The order identifier, set on a capacity refusal and on a throttled order |
chanId | string | The connection the message was delivered on. Not set on the generic handling failure |
timestamp | integer | When the gateway produced this message, in milliseconds |
Codes
The message shown is the one the platform returns.
| Code | Meaning |
|---|---|
PRE200003 | This user not allowed to trade with passed currency pair |
PRE200004 | User doesn't have enough prefunded funds to perform trade |
PRE200005 | User doesn't have enough limit to perform trade |
PRE200006 | Request-for-stream trading is not enabled for your site |
PRE200029 | Per transaction limit exceeded |
PRE200032 | Trade amount is less than the allowed |
PRE200035 | Currency pair is currently disabled for trading |
PRE200036 | Beneficiary wallet not found |
PRE200037 | API key does not contain RSA public key for signed intent verification |
PRE200038 | Signed intent verification failed |
PRE200039 | Broker limit check failed. Please contact support |
PRE200040 | Broker limit exceeded. Please contact support |
PRE200061 | PSP limit is not available |
PRE200062 | Insufficient PSP limit for a trade |
PRE200063 | PSP trade limit not found |
RFS100001 | An unexpected error. Retry, and contact support if it persists |
RFS100002 | Trading is currently unavailable. Contact support |
RFS100003 | Client subscription was not found for a given order request |
RFS100004 | Instrument must not be empty |
RFS100005 | Instrument %s is not valid |
RFS100006 | Such a pair of currencies %s is unavailable |
RFS100007 | Price %s is not valid |
RFS100008 | Currency %s is not valid |
RFS100009 | Quantity %s is not valid |
RFS100010 | quoteId is required |
RFS100011 | No corresponding price level for the request |
RFS100012 | Some error occurred during the order request |
RFS100013 | Some error occurred during the subscribe request |
RFS100014 | Some error occurred during trade capture |
RFS100015 | quoteId is not valid |
RFS100016 | Your account groups could not be returned. This is also what you receive when you have none, so the two are indistinguishable — see reading account groups |
RFS100017 | Client already has this subscription |
RFS100018 | No price feed |
RFS100019 | quoteId is Expired |
RFS100020 | quoteId is owned by other user |
RFS100021 | Tenor must not be empty |
RFS100022 | Currency pair is disabled for trading |
RFS100023 | Order could not complete due to breaching LP slippage limit |
RFS100024 | Broker rejected the order |
RFS100025 | Maximum allowed precision is %s decimal points |
RFS100026 | Rate limit breached |
RFS100027 | Per-session order capacity reached; retry once open orders resolve |
RFS300001 | Pre-deal service is down |
RFS400001 | Upstream provider not found |
RFS500001 | The request could not be processed. Retry, and contact support if it persists |
RFS600001 | Price no longer available, please use another quote |
RFS600002 | Response for the order request was not retrieved |
RFS600003 | Returned order status is unexpected |
RFS600004 | Account group is empty or blank |
RFS600006 | Beneficiary not found |
RFS600007 | Beneficiary wallet not found |
RFS600008 | Invalid network details provided |
RFS600009 | Beneficiary trade request is not valid |
RFS600010 | Network settings not found |
RFS600011 | Beneficiary details not valid. %s |
RFS600012 | Sender payin currency must be crypto |
RFS600013 | Sender wallet not found |
RFS600021 | Quote amount exceeded |
RFS600031 | Order with this idempotency key already exists |