Search docs

Are you looking for test card numbers?

Would you like to contact support?

Start searching Adyen's documentation...

  Documentation

Authorise a payment with 3D Secure 2 authenticated data

Submit a payment authorisation with Adyen, using authentication data from a third-party 3D Secure 2 provider.

Before you begin

Before you can start accepting 3D Secure 2 authenticated transactions on browsers or in-app, make sure that you:

  1. Sign up for an Adyen test account at https://www.adyen.com/signup
  2. Get your API Key. Save a copy as you'll need it for API calls you make to the Adyen payments platform.
  3. Install one of our Libraries to connect with the Adyen APIs. For more information on these steps, refer to Get started with Adyen.

Get authentication data

Get the following data from your 3D Secure 2 provider. You will need these values when submitting a payment authorisation request with Adyen.

  • transStatus from the Authentication Response (ARes) sent by the issuer. The ARes indicates if the cardholder has been authenticated or if the issuer requires further interaction to complete the authentication.
  • transStatus from the Results Request (RReq) sent by the ACS to the 3DS Server after a challenge flow is completed. The RReq indicates the result of the authentication.
  • authenticationValue
  • dsTransID
  • eci
  • messageVersion: The value should be 2.1.0.

Send a payment authorisation request with 3D Secure 2 authentication data

Make a POST /authorise request and include mpiData and additionalData objects:

  • mpiData: Object that contains the authenticated data.

    • directoryResponse: This is the transStatus from 3D Secure device fingerprinting.
    • authenticationResponse: This is the transStatus from challenge flow. If the transaction was frictionless, set this value to Y.
    • cavv: This is the authenticationValue.
    • dsTransID
    • eci
    • threeDSVersion: The value should be 2.1.0.
  • additionalData: Object that contains the acquirer information.

    • acquirerCode: This is the name of the Adyen acquirer that you want to authorise the transaction with.
    • authorisationMID: This is the MID of the Adyen acquirer account that you want to authorise the transaction with.

Sample request with mpiData

{  
  "card":{  
    "cvc":"737",
    "expiryMonth":"10",
    "expiryYear":"2020",
    "holderName":"Card Holder",
    "number":"4212345678901245"
  },
  "amount":{  
    "value":1499,
    "currency":"EUR"
  },
  "mpiData":{  
    "cavv":"3q2+78r+ur7erb7vyv66vv\/\/\/\/8=",
    "eci":"05",
    "dsTransID":"c4e59ceb-a382-4d6a-bc87-385d591fa09d",
    "directoryResponse":"C",
    "authenticationResponse":"Y",
    "threeDSVersion":"2.1.0"
  },
  "additionalData":{  
    "acquirerCode":"TestPmmAcquirer",
    "authorisationMid":"1000"
  },
  "reference":"YOUR_REFERENCE_NUMBER",
  "merchantAccount":"YOUR_MERCHANT_ACCOUNT"
}

Response

You will receive an  Authorised  resultCode if the payment authorisation was successful. Otherwise,  see  Result codes f or a complete list of  values and the actions that you need to take.

{
    "additionalData": {
        "liabilityShift": "true",
        "authCode": "76233",
        "avsResult": "4 AVS not supported for this card type",
        "threeDOffered": "true",
        "refusalReasonRaw": "AUTHORISED",
        "authorisationMid": "1000",
        "acquirerAccountCode": "TestPmmAcquirerAccount",
        "cvcResult": "1 Matches",
        "avsResultRaw": "4",
        "threeDAuthenticated": "true",
        "cvcResultRaw": "M",
        "acquirerCode": "TestPmmAcquirer",
        "acquirerReference": "7CAT290GCFV"
    },
    "pspReference": "8535505811653878",
    "resultCode": "Authorised",
    "authCode": "76233"
}