1a: Initial Recurring Transaction {#pa-3ri-1a-test-initial-first-recur-txn}
===========================================================================

In this instance, the merchant initiates a 3RI recurring transaction that is a fixed amount for a set of transactions with no established expiration, such as with a subscription purchase.

|       **Card Type**        | **Test Card Number** |
|----------------------------|----------------------|
| Mastercard Card Type = 002 | 52XXXX XX XXXX 28X5  |

Endpoint
--------

**Production:** `POST ``https://api.cybersource.com``/risk/v1/authentication-setups`  
**Test:** `POST ``https://apitest.cybersource.com``/risk/v1/authentication-setups`

Required Fields for 3RI 1a: Initial Recurring Transaction {#pa-3ri-1a-test-initial-first-recur-txn-req}
=======================================================================================================

Required Fields
---------------

[consumerAuthenticationInformation. challengeCode](https://developer.cybersource.com/docs/cybs/en-us/api-fields/reference/all/rest/api-fields/cons-auth-info-aa/cons-auth-info-challenge-code.md "")
:
Set this field value to `03`.

[consumerAuthenticationInformation. deviceChannel](https://developer.cybersource.com/docs/cybs/en-us/api-fields/reference/all/rest/api-fields/cons-auth-info-aa/cons-auth-info-device-channel.md "")
:
Set this field value to `Browser`.

[consumerAuthenticationInformation. messageCategory](https://developer.cybersource.com/docs/cybs/en-us/api-fields/reference/all/rest/api-fields/cons-auth-info-aa/cons-auth-info-message-category.md "")
:
Set this field value to `01`.

[consumerAuthenticationInformation. strongAuthentication.authenticationIndicator](https://developer.cybersource.com/docs/cybs/en-us/api-fields/reference/all/rest/api-fields/cons-auth-info-aa/cons-auth-info-strong-auth-auth-indicator.md "")
:
Set this field value to `02`.

[recurringPaymentInformation. endDate](https://developer.cybersource.com/docs/cybs/en-us/api-fields/reference/all/rest/api-fields/recurring-payment-info-aa/recurring-payment-info-end-date.md "")
:

[recurringPaymentInformation. frequency](https://developer.cybersource.com/docs/cybs/en-us/api-fields/reference/all/rest/api-fields/recurring-payment-info-aa/recurring-payment-info-frequency.md "")
:

[recurringPaymentInformation. numberOfPayments](https://developer.cybersource.com/docs/cybs/en-us/api-fields/reference/all/rest/api-fields/recurring-payment-info-aa/recurring-payment-info-number-of-payments.md "")
:

[recurringPaymentInformation. originalPurchaseDate](https://developer.cybersource.com/docs/cybs/en-us/api-fields/reference/all/rest/api-fields/recurring-payment-info-aa/recurring-payment-info-original-purchase-date.md "")
:

recurringPaymentInformation. sequenceNumber
:

Related Information
-------------------

* [API field reference guide for the REST API](https://developer.cybersource.com/docs/cybs/en-us/api-fields/reference/all/rest/api-fields/rest-api-fields-intro.md "")

REST Example: Checking Enrollment for a 3RI Initial Recurring Transaction {#pa-3ri-1a-test-initial-recur-txn-check-enroll-rest-ex}
==================================================================================================================================

Request

```
{
     "orderInformation": {
    "amountDetails": {
      "currency": "eur",
      "totalAmount": "100.00"
    },
    "billTo": {
      "address1": "201 S. Division St.",
      "administrativeArea": "MI",
      "country": "US",
      "locality": "Ann Arbor",
      "firstName": "RTS",
      "lastName": "VDP",
      "email": "test@email.com",
      "postalCode": "48104-2201"
    }
  },
  "paymentInformation": {
    "card": {
      "type": "002",
      "expirationMonth": "12",
      "expirationYear": "2027",
      "number": "52XXXXXXXXXX28X5"
    }
  },
  "deviceInformation": {
    "httpAcceptContent": "all",
    "httpBrowserLanguage": "en",
    "httpBrowserJavaEnabled": "y",
    "httpBrowserColorDepth": 1,
    "httpBrowserScreenHeight": 1,
    "httpBrowserScreenWidth": 1,
    "httpBrowserTimeDifference": 5,
    "userAgentBrowserValue": "chrome"
  },
  "recurringPaymentInformation": {
    "endDate": "20240906",
    "frequency": "31",
    "numberOfPayments": "1",
    "originalPurchaseDate": "2024080511243877",
    "sequenceNumber": "1"
  },
  "consumerAuthenticationInformation": {
    "strongAuthentication": {
      "authenticationIndicator": "02"
    },
    "challengeCode": "03",
    "deviceChannel": "Browser",
    "messageCategory": "01",
    "referenceId": "CybsCruiseTester-ddb08174"
  }
}       
```

Response to a Successful Request

```
{
    "clientReferenceInformation": {
        "code": "RTS-Auth"
    },
    "consumerAuthenticationInformation": {
        "challengeRequired": "N",
        "authenticationTransactionId": "ZtO0mD5q7PmRUG4v2NZ0",
        "strongAuthentication": {
            "OutageExemptionIndicator": "0"
        },
        "token": "AxjzbwSTiS4ZKSmMkFZDABECT34jGC2P0h04ghLLtaSZV0ekj0yAsAAAUgae",
        "acsUrl": "https://0merchantacsstag.cardinalcommerce.com/MerchantACSWeb/creq.jsp",
        "acsReferenceNumber": "Cardinal ACS",
        "pareq": "eyJtZXNzYWdlVHlwZSI6IkNSZXEiLCJtZXNzYWdlVmVyc2lvbiI6IjIuMi4wIiwidGhyZWVEU1NlcnZlclRyYW5zSUQiOiJiMjQ3MWRmYS0zYWFkLTQ3OWQtOGIxMy1iODZjNTE0Mzk3OWMiLCJhY3NUcmFuc0lEIjoiYzkyNWQ3M2MtMGNiMC00YjNhLWIzZmEtMmM0Y2E0MDJkOGI2IiwiY2hhbGxlbmdlV2luZG93U2l6ZSI6IjAyIn0",
        "directoryServerTransactionId": "bf67e7e6-c8cf-4b93-a211-3f4f60b07524",
        "veresEnrolled": "Y",
        "threeDSServerTransactionId": "b2471dfa-3aad-479d-8b13-b86c5143979c",
        "acsOperatorID": "MerchantACS",
        "specificationVersion": "2.2.0",
        "acsTransactionId": "c925d73c-0cb0-4b3a-b3fa-2c4ca402d8b6"
    },
    "errorInformation": {
        "reason": "CONSUMER_AUTHENTICATION_REQUIRED",
        "message": "The cardholder is enrolled in Payer Authentication. Please authenticate the cardholder before continuing with the transaction."
    },
    "id": "7252892152426444904003",
    "paymentInformation": {
        "card": {
            "bin": "520000",
            "type": "MASTERCARD"
        }
    },
    "status": "PENDING_AUTHENTICATION",
    "submitTimeUtc": "2024-09-02T15:00:15Z"
}
```

REST Example: Validating the Challenge for a 3RI Initial Recurring Transaction {#pa-3ri-1a-test-initial-recur-txn-validate-rest-ex}
===================================================================================================================================

Request

```
{
    "clientReferenceInformation": {
        "code": "pavalidatecheck",
        "partner": {
            "developerId": "7891234",
            "solutionId": "89012345"
        }
    },

  "paymentInformation": {
        "card": {
            "type": "002"
        }
    },
    "consumerAuthenticationInformation": {
        "authenticationTransactionId": "ZtO0mD5q7PmRUG4v2NZ0"
    }
}
```

Response to a Successful Request

```
{
    "clientReferenceInformation": {
        "code": "pavalidatecheck",
        "partner": {
            "developerId": "7891234",
            "solutionId": "89012345"
        }
    },
    "consumerAuthenticationInformation": {
        "indicator": "spa",
        "eciRaw": "07",
        "authenticationResult": "0",
        "strongAuthentication": {
            "OutageExemptionIndicator": "0"
        },
        "authenticationStatusMsg": "Success",
        "eci": "07",
        "token": "AxijLwSTiS5mZJ9Q0OxhABFPfiMZU1QCEtDJpJlXR6SPTIAA9Rdp",
        "cavv": "AAIBBYNoEwAAACcKhAJkdQAAAAA=",
        "paresStatus": "Y",
        "xid": "AAIBBYNoEwAAACcKhAJkdQAAAAA=",
        "directoryServerTransactionId": "bf67e7e6-c8cf-4b93-a211-3f4f60b07524",
        "threeDSServerTransactionId": "b2471dfa-3aad-479d-8b13-b86c5143979c",
        "specificationVersion": "2.2.0",
        "acsTransactionId": "c925d73c-0cb0-4b3a-b3fa-2c4ca402d8b6"
    },
    "id": "7252913891376641404001",
    "paymentInformation": {
        "card": {
            "bin": "520000",
            "type": "MASTERCARD"
        }
    },
    "status": "AUTHENTICATION_SUCCESSFUL",
    "submitTimeUtc": "2024-09-02T15:36:29Z"
}
```

