When verifying users, the verification checks performed by Adyen can return a range of error messages.
In your test environment, all verification checks are passed by default when the required fields and documents are provided. To test your error handling flow, you can force a scenario where one or more verification checks fail.
This allows you to reproduce an unsuccessful verification flow, including the result and corresponding verification codes. You can then also test the remediating flow to resolve the verification errors.
Requirements
Before you begin, take into account the following requirements, limitations, and preparations.
Requirement | Description |
---|---|
Integration type | You have an Adyen for Platforms or Adyen Issuing integration. |
API credentials | You must have a API credential for legal entity management. To check verification errors by making API requests, you must have a API web service user credential for the Configuration API.. |
Webhooks | To get updates about the failed verification, make sure you are subscribed to the balancePlatform.accountHolder.updated |
Step 1: Make an API request
Using the Legal Entity Management API, you can include a x-requested-verification-code in the header of your API request.
Note that requested verification codes cannot be used with hosted onboarding.
You can use requested verification codes for the following endpoints:
Use a suberror code as your requested verification code. You can include one code at a time in your request header. Requested verification codes can only be used in your test environment.
Step 2: Create account holder
For error tests for legal entities, you need to create an account holder for the legal entity of the organization, individual, or sole proprietorship.
For error tests for documents or transfer instruments, you need to create an account holder for the legal entity who owns the resource.
Step 3: Check verification errors
To get updates about the failed verification and the corresponding error codes, you can:
- Listen to the balancePlatform.accountHolder.updated or
- Make a GET API request for the particular legal entity, document, or transfer instrument.
Step 4: Test the remediating flow and resolve verification errors
To simulate the resolution of the verification errors, in your test environment, include the x-requested-verification-code: 0_0001
in the header of your API request.
Note that requested verification codes cannot be used with hosted onboarding.
The requested verification code can be used for the following endpoints in the Legal Entity Management API:
If your error handling is successful, the requested verification code resolves any suberrors associated with the legal entity, document, or transfer instrument.