API Error Codes
When an API request fails, a JSON error response is returned with an HTTP status code.
Response Format
{
"error": "error_code",
"message": "Human-readable description"
}Error Codes
400 — Bad Request
| Code | Meaning | Fix |
|---|---|---|
| invalid_pair | The from/to pair is not supported | Check /pairs endpoint |
| invalid_address | Destination address is malformed | Verify address format |
| invalid_amount | Amount is below minimum or invalid | Check minimum for the pair |
| invalid_rate_type | Rate type must be "float" or "fixed" | Use "float" or "fixed" |
| missing_field | A required field is missing | Check request body |
401 — Unauthorized
| Code | Meaning | Fix |
|---|---|---|
| invalid_api_key | API key is invalid or revoked | Check your API key |
| missing_api_key | No X-API-Key header provided | Add the header |
404 — Not Found
| Code | Meaning | Fix |
|---|---|---|
| order_not_found | The order ID doesn't exist | Verify the order ID |
| pair_not_found | The requested pair doesn't exist | Check /pairs endpoint |
429 — Rate Limited
| Code | Meaning | Fix |
|---|---|---|
| rate_limited | Too many requests | Wait and retry, check X-RateLimit headers |
500 — Server Error
| Code | Meaning | Fix |
|---|---|---|
| internal_error | Something went wrong on our end | Retry after a few seconds |
| service_unavailable | Maintenance or temporary outage | Check /status or retry later |
Retry Strategy
For 429 and 500 errors, implement exponential backoff:
1. Wait 1 second, retry
2. Wait 2 seconds, retry
3. Wait 4 seconds, retry
4. After 3 failures, surface the error to the user
Need Help?
If you encounter persistent errors, contact Support with:
- —The error code and message
- —Your request (redact the API key)
- —Timestamp of the request