Requirements
Before you begin, take into account the following requirements, limitations, and preparations.How it works
With standalone authentication, you perform the 3D Secure 2 authentication independently of the payment authorization flow.- Make a payment request, where you use the
authenticationOnlyparameter to specify that the request is only for performing authentication. - In the /payments response, use the
actionobject to determine the authentication flow you need to perform. - Perform the required authentication flow.
- Get the 3D Secure 2 authentication data.
- Use the authentication data to authorize the payment with Adyen, or with another PSP or acquirer.
Make a payment request for authentication
A payment request to perform standalone authentication is similar to making a /payments request for a payment authorization with your standard 3D Secure 2 integration. You add theauthenticationOnly parameter to specify that you only want to authenticate the shopper.
To perform standalone authentication:
-
In your POST /payments request, specify:
Required for all transactions.
Required for particular setups, or issuers and card schemes.
Recommended for all transactions, but not required. We recommend that you do the following to prevent authorization refusals:
- Include additional acquirer-related data if you plan to authorize the payment with a different acquirer. Refusals often happen when acquirer data mismatches between the authentication and authorization requests.
- Include additional shopper information to increase the likelihood of achieving a frictionless flow.
curl
Java
PHP
C#
NodeJS (JavaScript)
Go
Python
Ruby
NodeJS (TypeScript)
-
In the /payments response, check the
resultCode:-
If the result code is
AuthenticationNotRequired, You can proceed to authorize the payment with Adyen by making a standard /payments request, or with another PSP or acquirer. -
If you get a 3D Secure 2 authentication result code, proceed to perform the authentication.
-
If the result code is
Provide additional acquirer-related data
If you authorize the payment that you authenticate with Adyen with a different PSP, it is recommended to include additional acquirer-related data. Get the following details from your acquirer. These details are part of the 3D Secure 2 enrollment process between your acquirer and card schemes. If you are unable to get these details from your acquirer, contact our Support Team.
Make a POST /payments request containing the parameters required for the standalone authentication, together with the acquirer data listed above.
Example standalone authentication request with additional acquirer-related data
Perform the authentication
-
In the /payments response, you receive
action.type: ThreeDS2. Use theaction.subtypeobject to determine your next steps. The way to handle theactionobject for the standalone authentication flow is the same as handling it for your native or redirect 3D Secure implementation. -
When authentication is completed, submit the authentication result in a /payments/details request, including authenticationData.authenticationOnly: true.
Below is an example /payments/details request: /payments/details requestcurl
Java
PHP
C#
NodeJS (JavaScript)
Go
Python
Ruby
NodeJS (TypeScript)
-
In the /payments/details response, check the following fields:
-
resultCode: If the authentication process has finished, you receive AuthenticationFinished. If an error occurs during the authentication flow, and the authentication process is not completed, you receive Refused. -
threeDS2Result: The object that contains the authentication data that you need to authorize the payment following a successful authentication. -
threeDS2Result.transStatus: Indicates the result of the authentication. The value Y means that authentication is successful. If the authentication went through the redirect flow, the result of the authentication is in additionalData.threeDAuthenticatedResponse.
-
Get the 3D Secure 2 authentication data
After a successful authentication, you get aresultCode with the value of AuthenticationFinished in the /payments/details response. The response contains threeDS2Result object, that contains the authentication data produced by a Merchant Plug-in (MPI).
Some schemes do not provide all fields; the Applies to column shows which schemes provide each field.
Some of these fields are also returned in the threeDAuthenticatedResponse object, but we recommend to use the threeDS2Result object.
**
Possible ‘transStatusReason’ values
Authorize the payment
Use the 3D Secure 2 authentication produced by the MPI to authorize the payment with Adyen, or with another PSP. For information on authorizing with other PSPs, refer to their documentation. For payment authorizations, keep the following in mind:- You cannot reuse the authentication data across PSPs. For example, if you send a request to authorize the payment using the data to a PSP and it fails, you can not pass the same data to another PSP.
- Make sure to use the authentication data before it expires.
Authorize the payment with Adyen
To authorize the payment with Adyen, make a POST /payments request, including:- The standard parameters required to make a payment. Make sure to pass the scheme that authenticated the transaction in the
paymentMethod.brandobject for co-badged cards. - The authentication data you received in the
additionalDataorthreeDS2Resultobject of the /payments/details response. Send this data in the mpiData object. The fields you need to send in your request map to thethreeDS2Resultfields as shown in the table below. - For Cartes Bancaires, include the required additional fields from the
additionalDataand thethreeDS2RequestDataobjects. It is possible that you do not receive all Cartes Bancaires fields for each transaction, these fields are only required when they are returned in the /payments/details response that contains the authentication data.
Example /payments request including authentication data
resultCode if the payment authorization was successful. See Result codes for a complete list of possible responses.
/payments response
Authentication data expiry
Authentication data and cryptograms expire depending on card schemes. This means that you can no longer use the authentication data after it expires.Authentication not required reasons
You get an AuthenticationNotRequired result code in the /payments response when a transaction doesn’t require 3D Secure authentication. If you get this code, you can proceed with the standard payment flow with Adyen, or another PSP. Below is the list of possibleauthenticationNotRequiredReason values: