Error codes
Learn about common errors you might encounter when integrating with Airwallex.js. For errors specific to Elements, refer to the relevant sections.
Common errors
Error code | Error message | Next steps |
---|---|---|
UNAUTHORIZED | Cannot authenticate ${elementName} : missing credentials. Please call init() with authCode , clientId , and codeVerifier . Note: This error is not applicable to Payment Elements. |
Please check if the authentication was completed, the code verifier was generated successfully, and matching values are provided for the same authorization chain. |
UNAUTHORIZED | Token exchange failed. Please make sure the authCode has not expired.Note: This error is not applicable to Payment Elements. |
If the authCode has expired, restart the entire flow to get a new authCode , initialize the component, and create the component again. |
AUTH_TIMEOUT | Authentication failed because the authCode has expired (valid for 30 seconds). Please generate a new code and try again.Note: This error is not applicable to Payment Elements. |
Restart the entire flow to get a new authCode , initialize the component, and create the component again. |
INIT_ERROR | Element name or instance is missing. Please specify a valid element. | The SDK did not receive the required parameters and values while initializing. Please check the init() parameters for valid options. |
INIT_ERROR | Please try again, or contact support if the issue persists. | The SDK did not receive the required parameters and values while initializing. Please check the init() parameters for valid options. |
INIT_ERROR | env: {{env}} is not supported. Please specify a supported environment key.
|
Check for correct environment keys in SDK reference. |
INIT_ERROR | locale: {{langKey}} is not supported. Please specify a supported locale key.
|
Check for correct locale values in SDK reference. |
INIT_ERROR | authCode is missing. Please specify a valid authorization code in init() .
|
Specify a valid value for authCode |
INIT_ERROR | codeVerifier is missing. Please specify a valid code verifier in init() . |
Specify a valid value for codeVerifier |
INIT_ERROR | clientId is missing. Please specify a valid client ID in init() .
|
Specify a valid value for cliendId |
CREATE_ELEMENT_ERROR | createElement() with type ${elementName} is not supported. Please specify a valid Element type.
|
Specify a valid Element type in createElement() . |
ELEMENT_NOT_FOUND | $(elementName) is not supported. Please initialize the Element before creating it.
|
Please initialize the Element before creating it. |
MOUNT_ELEMENT_ERROR | Cannot find Element with DOM Element id: ${domElement} . Please make sure the Element is available in the DOM.
|
Check if the container DOM id or the DOM element passed in the mount() function is valid. |
(no code) | Please initialize the Element before creating it. | Ensure the Element is initialized with the correct parameters before creating it. |
(no code) | Please call the init() function in a browser environment.
|
- |
(no code) | Element type is missing. Please specify a valid element. | - |
Payment errors
The following errors are specific to payment Elements, Hosted Payment Page, Drop-in Element, Card Element, Split Card Element, Apple Pay Element, or Google Pay Element.
Error code | Error message | Next steps |
---|---|---|
unauthorized | Access denied, authentication failed. | Regenerate the access token and re-authenticate to Airwallex. |
awx_pay_error | Your payment was declined. Please try a different account or choose another payment method. | Retry with another payment method and if the issue persists, try a different account. |
custom_code | Your current bank account balance is ${balanceAmount} EUR. To complete your payment, please add sufficient funds or choose a different account. | Add sufficient funds to your bank account or choose a different bank account. |
resource_not_found | ${resourceID} cannot be found. Note: Resource may be either Payment Intent or Customer. |
Provide a valid identifier for Payment Intent or Customer. |
required | ${inputName} is required. | Provide values for the required checkout fields. |
invalid | ${inputName} is invalid. | Ensure values provided in the checkout fields are valid. |
un_support | This card is not supported for payment. Please specify a different card. | Try payment with a different card. See supported card payment methods. |
expired | The card’s expiration date cannot be in the past. Please enter a valid expiration date. | Check the card expiry date and ensure the value is valid. |
no_payment_methods | No available payment methods. Please contact support to enable payment methods. | See supported card payment methods. |
Payout errors
The following errors are specific to payout Elements, Beneficiary Element, Transfer Element, or Tax form Element.
Transfer form
onError events
Events indicating errors to listen for after the component is mounted.
Error code | Error message | Next Steps |
---|---|---|
INVALID_BENEFICIARY_ID | The beneficiary_id you provided in the defaultValue is invalid. | Provide a valid beneficiary ID that belongs to this account, or specify parameters for the beneficiary instead. |
SCHEMA_NOT_FOUND | The defaultValue provided is not supported in our schema. | Provide a supported combination of values for sourceCurrency , transferCurrency , bankCountryCode , transferMethod , and localClearingSystem . |
formState events
Events to listen for as the user interacts with the component with suggestions to handle on your user interface.
Error Code | Error message | Next Steps |
---|---|---|
SCHEMA_NOT_FOUND | The values provided are not supported in our schema. | Provide a supported combination of values for sourceCurrency , transferCurrency , bankCountryCode , transferMethod , and localClearingSystem . |
AMOUNT_ABOVE_LIMIT | The amount exceeds the transfer limit. | Provide a lower amount. |
AMOUNT_ABOVE_TRANSFER_LIMIT | The amount exceeds the transfer limit. | Provide a lower amount. |
AMOUNT_BELOW_LIMIT | This amount is lower than the minimum transfer limit. | Provide a higher amount. |
AFTER_FEE_IS_TOO_SMALL | This amount is lower than the minimum transfer limit after deducting transfer fee. | Provide a higher amount. |
INVALID_AMOUNT_MAX_THREE_DECIMALS | This amount only supports three decimal places maximum. | Provide a valid amount with no more than three decimal places. |
INVALID_AMOUNT_MAX_TWO_DECIMALS | This amount only supports two decimal places maximum. | Provide a valid amount with no more than two decimal places. |
INVALID_AMOUNT_NO_DECIMALS | This amount does not support any decimal places. | Provide a valid amount without any decimal places. |
INVALID_AMOUNT_MUST_POSITIVE | This amount can only be positive. | Provide a positive amount. |
INVALID_SETTLEMENT_DATE | The transfer date is not supported. | Provide a valid transfer date. |
INVALID_CURRENCY_PAIR | The sourceCurrency and transferCurrency combination specified is not supported or enabled for this account. | Provide a supported sourceCurrency and transferCurrency pair. |
UNSUPPORTED_CURRENCY | The currency specified is not supported or enabled for this account. | Provide a valid sourceCurrency or transferCurrency . |
MISSING_FEE_CONFIG | There is a problem with this account’s transfer fee configuration. | Contact your Account Manager and report this issue. |
CNY_TRANSFER_NOT_ALLOWED | Your account is not enabled for CNY Local transfer method. Please contact Airwallex to enable it. | Contact your Account Manager and report this issue. |
ENROLLMENT_PENDING | We are currently processing your request to enable CNY Local transfer method, and will notify you of the result within 0-2 business days. Thank you for your patience. | Contact your Account Manager if the issue persists. |
ENROLLMENT_FAILED | Your application to enable the CNY Local transfer method was not approved. Please submit again, or select the SWIFT transfer method. | Resubmit or change transfer method. |
ENROLLMENT_NOT_SUBMITTED | Please enable the CNY Local transfer method, or select the SWIFT transfer method. | Contact your Account Manager to enable CNY local transfer or select the SWIFT transfer method. |
CNY_QUOTA_EXCEEDED | The amount exceeds your transfer limit. Please enter a lower amount or increase your transfer limit. | Enter an amount lower than your transfer limit or increase your transfer limit. |
Beneficiary form
onError events
Events indicating errors to listen for after the component is mounted.
Error code | Error message | Next Steps |
---|---|---|
SCHEMA_NOT_FOUND | The defaultValue provided is not supported in our schema. | Provide a supported combination of values for sourceCurrency , transferCurrency , bankCountryCode , transferMethod , and localClearingSystem . |
formState events
Events to listen for as the user interacts with the component with suggestions to handle on your user interface.
Error code | Error message | Next Steps |
---|---|---|
SCHEMA_NOT_FOUND | The values provided are not supported in our schema. | Provide a supported combination of values for sourceCurrency , transferCurrency , bankCountryCode , transferMethod , and localClearingSystem . |
VALIDATION_FAILED | The request failed our schema validation. | Check the errors on the form and update with accepted values. |
Tax form
ERROR CODE | ERROR MESSAGE | NEXT STEPS |
---|---|---|
REQUEST_ERROR | UNAUTHORIZED | The refreshToken might be expired (currently 1 hour). Please redo the entire flow to get a new authCode and initialize the SDK, then create the element again. |
REQUEST_ERROR | string | Please check the params are valid before you submit the form. |
Onboarding errors
The following errors are specific to onboarding Elements, KYC Element, Payments KYB Element and its associated RFI elements, KYC RFI Element and Payment Enablement RFI Element.
Error code | Error message | Next steps |
---|---|---|
SUBMIT_FAILED | An internal error occurred while submitting the form. Please try again or contact support if the issue persists. | Contact your Airwallex Account Manager if the issue persists. |
INVALID_RFI_STATUS | No open RFI is currently available for this account. Please specify an open RFI where information is still needed. | Ensure the specified RFI is still open. |
INVALID_RFI_STATUS | Invalid RFI status `NO_ACTION_REQUIRED`. No valid RFI session available for this account. | Ensure the specified RFI is valid. |
INVALID_KYC_STATUS | Cannot enter the RFI flow when the account's `kycStatus` is `INIT` or `FAILURE`. | Ensure the account's KYC status is valid (NOT `INIT` or `FAILURE`) for the RFI flow. |
API_ERROR | Error occurred when calling <API_name> API. Please retry or contact Airwallex support.
|
Contact your Airwallex Account Manager if the issue persists. |
UNKNOWN | Please retry or contact Airwallex support. | Contact your Airwallex Account Manager if the issue persists. |
Compliance errors
The following errors are specific to compliance Elements, namely SCA Element.
Error code | Error message | Next steps |
---|---|---|
CAPTCHA_ERROR | Captcha verification failed. Please try again. | Contact your Airwallex Account Manager if the issue persists. |
API_ERROR | Error occurred when calling <API_name> API. Please retry or contact Airwallex support.
|
Contact your Airwallex Account Manager if the issue persists. |
INVALID_TOKEN | Please specify a valid identity and regenerate the authorization code. | Regenerate the authorization code with valid credentials. |