error/message for detail.
Error shape
error is a stable, machine-readable code you can switch on; message is a
human-readable explanation that may include specifics (amounts, the bucket to
transfer from). New codes may be added over time — treat an unrecognized code as
a generic failure of its status class.
Status codes
Common business rejections
These come back on trading and wallet endpoints. They are expected outcomes, not bugs — handle each deliberately.INSUFFICIENT_MARGIN
INSUFFICIENT_MARGIN
The order would breach your available margin. Every order passes a
server-side margin gate before acceptance. Read your headroom from
GET /perps/positions and GET /perps/balances, reduce size, or fund the
venue — do not retry the same order.Insufficient {bucket} balance
Insufficient {bucket} balance
A transfer or withdrawal exceeds the source bucket’s available balance.
Withdrawals draw only from
wallet; transfer back from perps/options/spot
first. Returned as 400.POST_ONLY_WOULD_CROSS
POST_ONLY_WOULD_CROSS
A
postOnly order would have taken liquidity, so it was rejected to keep you
on the maker side. Re-price behind the touch and resubmit.REDUCE_ONLY_REJECTED
REDUCE_ONLY_REJECTED
A
reduceOnly order would have increased your position (e.g. wrong side or
already flat). Check your current position before retrying.Strategy not fully filled
Strategy not fully filled
A multi-leg combo could not fill every leg immediately. Combos are
all-or-none (FOK) — the whole strategy is rejected and nothing executes.
Re-price the legs and resubmit.
Order would not fill (IOC / FOK)
Order would not fill (IOC / FOK)
An
ioc order found no liquidity to take, or a fok order could not be
filled in full. Nothing rests; adjust price or time-in-force.A
422 business rejection is not a transport failure. Retrying it unchanged
will fail the same way and can burn your rate budget — fix the cause first.Rate limits
Requests are rate-limited per client. Authenticated sessions and API keys get a higher budget than anonymous traffic. Every response carries the current window state so you can pace yourself.
When you exceed the budget you receive
429 Too Many Requests. Back off until
X-RateLimit-Reset, ideally with exponential backoff and jitter.
Handling 429 in practice
Idempotency
To make retries safe, send aclientOrderId on order and quote endpoints. If a
response is lost and you retry, the same clientOrderId prevents a duplicate
order — reconcile by reading the resulting order rather than assuming it failed.
Quoting endpoints also accept a quoteId to group and atomically replace a
market-maker’s quote set.