3DS2 - autentificación con challenge, con 3DS Method
Para probar este escenario, use uno de los números de tarjeta a continuación:
Tarjeta | Fecha de vencimiento. | Marca |
---|---|---|
4970110000001003 | A elección | VISA |
5100010000000106 | A elección | MASTERCARD |
375900000010015 | A elección | AMEX |
Secuencia de los intercambios
1. Llamada al al Web Service PCI/Authentication/CreateSession con una tarjeta afiliada a 3DS2.
{ "amount": "990", "currency": "EUR", "transactionCategory": "PAYMENT", "productType": "GOODS_OR_SERVICE_PURCHASE", "merchant": { "mid":"" }, "paymentForm": { "pan": "4970110000001003", "expiryMonth": "11", "expiryYear": "23", "networkPreference": "VISA" }, "customer": { "email": "<sample@example.com>" }, "protocolRequest": { "name": "THREEDS", "version": "2" }, "ianTargetUrl": "<https://merchant.ian.com>" }
Respuesta
{
"webService":"PCI/Authentication/CreateSession",
"version":"V4",
(...)
"answer":{
"operationSessionId":"30641640cba14eab8e6766094fd201da",
"operationUrl":"https://api.lyra.com/api-payment/V4/Charge/Public/Authenticate/Session/30641640cba14eab8e6766094fd201da;JSESSIONID=7A4beEA2d5fdbFeA7389F3B91a7bDBaBc8DA9df5.default-hostname",
"_type":"V4/PCI/Authentication/AuthenticationSessionResponse"
}
}
En el ejemplo:
answer.operationUrl
: "https://api.lyra.com/api-payment/V4/Charge/Public/Authenticate/Session/30641640cba14eab8e6766094fd201da;JSESSIONID=7A4beEA2d5fdbFeA7389F3B91a7bDBaBc8DA9df5.default-hostname"Transmettez le champ
operationUrl
à la méthode d'authentificationkr-authenticate.js
de la librairie JS (plus d'infos : Guide d'intégration (mode simple)).
2. Redirección al ACS del banco del titular de la tarjeta.
- La biblioteca JS realiza automáticamente todas las acciones necesarias, el vendedor no necesita realizar ningún desarrollo específico.
3. Retorno del servidor de la plataforma de pago de la autentificación (Método 3DS).
{ "webService":"PCI/Authentication/CreateSession", "version":"V4", "applicationVersion":"5.23.0", "serverDate":"2023-05-05T09:33:32+00:00", "ticket":"3b68064f80f346919828dee761bd22b5", "applicationProvider":"", "metadata":null, "status":"SUCCESS", "mode":"TEST", "serverUrl":"https://static.lyra.com", "_type":"V4/WebService/Response", "answer":{ { "id":"18e1a1a0-92f1-4722-b60b-80ec4a1f78d3", "operationSessionId":null, "protocol":{ "name":"THREEDS", "version":"2.1.0", "network":"VISA", "challengePreference":"NO_PREFERENCE", "simulation":true, "_type":"V4/Charge/Authenticate/Protocol" }, "value":{ "authenticationType":"CHALLENGE", "authenticationId":{ "authenticationIdType":"dsTransId", "value":"86cabade-96bb-4cc0-921b-6df6e5bd608f", "_type":"V4/Charge/Authenticate/AuthenticationId" }, "authenticationValue":{ "authenticationValueType":"CAVV", "value":"ccvGMhCneJLVi5BlqDOgDtdbvSM=", "_type":"V4/Charge/Authenticate/AuthenticationValue" }, "status":"SUCCESS", "commerceIndicator":"05", "extension":{ "authenticationType":"THREEDS_V2", "challengeCancelationIndicator":null, "cbScore":null, "cbAvalgo":null, "cbExemption":null, "paymentUseCase":null, "threeDSServerTransID":"18e1a1a0-92f1-4722-b60b-80ec4a1f78d3", "dsTransID":"86cabade-96bb-4cc0-921b-6df6e5bd608f", "acsTransID":"0bd22c3e-582f-430a-a9d0-8e99fb54b9b4", "sdkTransID":null, "transStatusReason":null, "requestedExemption":null, "requestorName":"Lyra SMS", "cardHolderInfo":null, "dataOnlyStatus":null, "dataOnlyDecision":null, "dataOnlyScore":null, "_type":"V4/Charge/Authenticate/AuthenticationResultExtensionThreedsV2" }, "reason":{ "code":null, "message":null, "_type":"V4/Charge/Authenticate/AuthenticationResultReason" }, "_type":"V4/Charge/Authenticate/AuthenticationResult" }, "_type":"V4/AuthenticationResponseData" } }