Using a third-party 3DS provider to run transactions

Background
Before starting this tutorial, make sure you understand the following topics from the Quick start section:

You can use your own external or third-party 3DS (three-domain secure) provider to run transactions. You do this directly through the API.

For information about running transactions with Nexio as 3DS provider, see Using 3DS to run transactions.

For information about running transactions without 3DS, see Creating a card checkout page with the iframe, Creating a card checkout page with your own form, and Running a card transaction with the API.

For more information about 3DS, see the following pages:

Running transactions using external 3DS provider

  1. Complete Step 1 in the Creating a card checkout page with your own form tutorial by creating your checkout page and including a form element.

  2. Add form fields to collect any necessary user and payment information.
    The following information is required by Nexio:

    • Amount (data.amount)
    • Card information (either a saved card token or full card information).
      Optionally, you can include the currency (data.currency). If you do not specify a value for this parameter, the system defaults to USD.
      See the Run card transaction endpoint for a complete list of possible parameters.

  3. Send the payment information to your external 3DS provider.
    Through the 3DS provider, the customer may get prompted to confirm they are being redirected for authentication.

  4. After the customer successfully authenticates, you get a response from the 3DS provider.
    From the response, you must pass on at least the following parameters to Nexio for running the transaction: eci; either cavv or xid, depending on the card brand; and version.

  5. Send a POST request to the Run card transaction endpoint. Make sure to include the required parameters, including the following:

    • data.amount with the total for the transaction.
    • tokenex.token with the saved card token or card.pan and the expiration date information.
    • external3ds.eci is required. Send the value received from your 3DS provider.
    • Either external3ds.cavv or external3ds.xid, depending on the card brand. One of the two is required. Send the parameter and value received from your 3DS provider.
    • external3ds.version may be required, depending on your transaction gateway or connection. Send the value received from your 3DS provider.
    • You may also need to include the currency (data.currency). If you do not specify a value for this parameter, the system defaults to USD.
    • Include any other parameters that you want (see the endpoint reference for potential parameters).
    curl -X POST https://api.nexiopaysandbox.com/pay/v3/process \
      -H 'Content-Type: application/json' \
      -H 'Accept: application/json' \
      -H 'Authorization: Basic [Base64_encoded_login]'
      -d '{
      "data": {
      	"amount": 29.99
      },
      "tokenex": {
        "token": "6ee140a0-05d1-4958-8325-b38a690dbb9d"
      },
      "external3ds": {
      	"eci": "05",
        "cavv": "MzM2OGI2ZjkwYjYwY2FjODQ3ZWU=",
        "xid": "ZGUzNzgwYzQxM2ZlMWM0MzVkMjc=",
        "version": "2.2.0"
      }
    }'
    

  6. Listen for Nexio's response. Use the response to create a success (such as a receipt) or failure page for the customer. You may also want to send a receipt to the customer via email.

    πŸ“˜

    Notes

    • The response schema will be the same as that of a standard POST request to the Run card transaction endpoint.
    • The page does not generate a default confirmation page. We recommend using our response to create your own confirmation page.