Card

3-D Secure 2

schedule 5 min read

Authenticating the cardholder.

Edit "3-D Secure 2" on GitHub

3-D Secure 2

When dealing with card payments, 3-D Secure authentication of the cardholder is an essential topic. 3-D Secure 2 is an improved version of the old protocol, now allowing frictionless payments where transactions can be completed without input from the cardholder. Therefore, there are certain fields that should be included when implementing 3-D Secure 2. These are listed below and can be seen in the abbreviated request example below.

Request

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
POST /psp/creditcard/payments HTTP/1.1
Authorization: Bearer <AccessToken>
Content-Type: application/json

{
    "payment": {
        "operation": "Purchase",
        "intent": "Authorization",
        "currency": "SEK",
        "description": "Test Purchase",
        "urls": {
            "hostUrls": ["https://example.com"]
        }, 
        "cardholder": {
            "firstName": "Olivia",
            "lastName": "Nyhuus",
            "email": "olivia.nyhuus@payex.com",
            "msisdn": "+4798765432",
            "homePhoneNumber": "+4787654321",
            "workPhoneNumber": "+4776543210",
            "shippingAddress": {
                "addressee": "Olivia Nyhuus",
                "email": "olivia.nyhuus@payex.com",
                "msisdn": "+4798765432",
                "streetAddress": "Saltnestoppen 43",
                "coAddress": "",
                "city": "Saltnes",
                "zipCode": "1642",
                "countryCode": "NO",
            },
        },
        "riskIndicator": {
            "deliveryEmailAddress": "olivia.nyhuus@payex.com",
            "deliveryTimeFrameIndicator": "01",
            "preOrderDate": "19801231",
            "preOrderPurchaseIndicator": "01",
            "shipIndicator": "01",
            "giftCardPurchase": false,
            "reOrderPurchaseIndicator": "01"
            "pickUpAddress" : {
                "name" : "Company Megashop Sarpsborg",
                "streetAddress" : "Hundskinnveien 92",
                "coAddress" : "",
                "city" : "Sarpsborg",
                "zipCode" : "1711",
                "countryCode" : "NO"
            }
        }
    }
}
Field Type Description
payment object The payment object.
└➔ cardholder object Cardholder object that can hold information about a buyer (private or company). The information added increases the chance for frictionless 3-D Secure 2 flow.
└➔ firstname string Payer’s first name.
└➔ lastname string Payer’s last name.
└➔ email string Payer’s registered email address. The field is related to 3-D Secure 2.
└➔ msisdn string Payer’s registered mobile phone number. The field is related to 3-D Secure 2.
└➔ homePhoneNumber string Payer’s registered home phone number. The field is related to 3-D Secure 2.
└➔ workPhoneNumber string Payer’s registered work phone number. The field is related to 3-D Secure 2.
└➔ shippingAddress object The shipping address object related to the payer. The field is related to 3-D Secure 2.
└─➔ addresse string The name of the addressee – the receiver of the shipped goods.
└─➔ coAddress string Payer’ s c/o address, if applicable.
└─➔ streetAddress string Payer’s street address. Maximum 50 characters long.
└─➔ zipCode string Payer’s zip code
└─➔ city string Payer’s city of residence
└─➔ countryCode string Country Code for country of residence.
└➔ riskIndicator object This object consist of information that helps verifying the payer. Providing these fields decreases the likelihood of having to promt for 3-D Secure authentication of the payer when they are authenticating the purchase.
└─➔ deliveryEmailAdress string For electronic delivery, the email address to which the merchandise was delivered. Providing this field when appropriate decreases the likelyhood of a 3-D Secure authentication for the payer.
└─➔ deliveryTimeFrameIndicator string ndicates the merchandise delivery timeframe.
01 (Electronic Delivery)
02 (Same day shipping)
03 (Overnight shipping)
04 (Two-day or more shipping).
└─➔ preOrderDate string For a pre-ordered purchase. The expected date that the merchandise will be available. Format: YYYYMMDD.
└─➔ preOrderPurchaseIndicator string Indicates whether the payer is placing an order for merchandise with a future availability or release date.
01 (Merchandise available)
02 (Future availability).
└─➔ shipIndicator string Indicates shipping method chosen for the transaction.
01 (Ship to cardholder’s billing address)
02 (Ship to another verified address on file with merchant)
03 (Ship to address that is different than cardholder’s billing address)
04 (Ship to Store / Pick-up at local store. Store address shall be populated in the riskIndicator.pickUpAddress and payer.shippingAddress fields)
05 (Digital goods, includes online services, electronic giftcards and redemption codes)
06 (Travel and Event tickets, not shipped)
07 (Other, e.g. gaming, digital service)
└─➔ giftCardPurchase bool true if this is a purchase of a gift card.
└─➔ reOrderPurchaseIndicator string Indicates whether the cardholder is reordering previously purchased merchandise.
01 (First time ordered)
02 (Reordered).