How to handle 3DSecure redirect for Server to Server integration - asynchronous payments


If you integrate using the server to server method, you would need to handle the redirect of the customer to their bank's 3DSecure page, and then wait for the response on the outcome. 

You can then display an appropriate message from your systems, to the customer on the frontend. The ShopperResultURL is important for this communication.

CopyAndPay widget handles this asychronous workflow out-of-the-box. However for Server to server, you would need to implement as below :

1. Send initial payment request.

This will return the 3D Secure redirect url as well as the 3D Secure parameters and their values


2. Redirect the shopper to the 3D Secure Page by parsing the redirect url and parameters into a form.

Please see some sample code below. Please note that the parameters and their values may change with each payment

<form name="submitForm" action=";ndcid=01DB19AD58009BBAE81DFB85B7137519.sbg-vm-tx0" method="POST" >

            <input type="hidden" name="MD" value="8a82944a5ad7d3f5015adb73209358b1">
            <input type="hidden" name="connector" value="THREEDSECURE">
            <input type="hidden" name="TermUrl" value=";jsessionid=9B781F19283F51EB35D12F04DE782216.sbg-vm-con01?asyncsource=THREEDSECURE&amp;ndcid=01DB19AD58009BBAE81DFB85B7137519.sbg-vm-tx01">
            <input type="hidden" name="PaReq" value="IT8ubu+5z4YupUCOEHKsbiPep8UzIAcPKJEjpwGlzD8">

                <input type='submit' name='submitButton'/>


3. The payment status is returned to you in JSON format.

The payment response for a successful payment in the TEST system will always have a result code of 000.100.110. In the LIVE system, the result code is 000.000.000. Any other result code besides this is a failed payment. Below is the JSON response for a successful payment in the TEST system: 

"descriptor":"4195.9294.6338 OPP_Channel",
"description":"Request successfully processed in 'Merchant in Integrator Test Mode'"
"buildNumber":"38eae4de39e48cd5449b8ca8a087641065defcb2@2017-03-23 13:23:41 +0000",
"timestamp":"2017-03-24 08:33:09+0000",

Have more questions? Submit a request


Powered by Zendesk