Airwallex logo
Airwallex logoAirwallex logo

Errors

Copy for LLMView as Markdown

Airwallex uses conventional HTTP response codes to indicate the success or failure of an API request. Typically a status code in the 2xx range indicates success, status codes in the 4xx range indicate an error that has been triggered due to the information provided (for example; a parameter does not meet the validation requirements or was not provided), and status codes in the 5xx range indicate an error with our servers.

When we send an error response, the body will generally contain the following fields:

Response body attributes

  • code: Error code
  • source: Name of the request parameter that caused the error
  • message: Description of the error
  • details: A conditional key-value object containing additional details about the error
HTTP status codes
200OK - The request was processed successfully
201Created - The request was processed successfully
400Bad request - The request contains missing parameters, is in an incorrect shape, or failed another validation test
401Unauthorized - The authentication token is invalid
403Forbidden - The authentication token is not provided, or the request was denied due to insufficient permissions
404Not found - The requested endpoint does not exist
409Conflict - The request could not be completed due to a conflict with another request
429Too Many Requests - The user has sent too many requests in a given amount of time
500Server error - Something went wrong on our end; please let us know if you are receiving this error
Example 400 error response body
1{
2 "code": "invalid_argument",
3 "source": "first_name",
4 "message": "Value is too short",
5 "details": {
6 "reason": "First name must contain at least three characters."
7 }
8}
Was this page helpful?