Customer-Initiated Unscheduled COF Payment with `TMS` {#credentials-ucof-cit-tms-intro}
=======================================================================================

An unscheduled credentials-on-file (COF) transaction uses stored payment information for a fixed or variable amount that does not occur regularly. An account top-up is one kind of unscheduled COF.

Supported Card Types
--------------------

These are the supported card types for processing credentialed transactions:

* American Express{#credentials-ucof-cit-tms-intro_d9e147}
  {#credentials-ucof-cit-tms-intro_d9e147}
* Mastercard{#credentials-ucof-cit-tms-intro_d9e150}
  {#credentials-ucof-cit-tms-intro_d9e150}
* Visa{#credentials-ucof-cit-tms-intro_d9e153}
  {#credentials-ucof-cit-tms-intro_d9e153}

Creating a `TMS` Token
----------------------

When sending the initial CIT, you can create a `TMS` token to store the customer's credentials for the subsequent MITs. To create a `TMS` token, include the processingInformation.actionTokenTypes field in the authorization request. Set the field to one of these values based on the `TMS` token type you want to create:

**Customer**
:
Customer tokens store one or more customer payment instrument tokens and shipping address tokens.
:
Including a customer token in subsequent MITs eliminates the need to include billing information, card information, and the previous transaction's ID.
:

    ```
    "processingInformation": {
        "actionTokenTypes": [
          "customer"
    ]
    ```

**Payment Instrument**
:
Payment instrument tokens store an instrument identifier token, card information, and billing information. Payment instruments are not linked to a customer token. Including a payment instrument in subsequent MITs eliminates the need to include billing information, card information, and the previous transaction's ID.
:

    ```
    "processingInformation": {
        "actionTokenTypes": [
          "paymentInstrument"
    ]
    ```

**Instrument Identifier**
:
Instrument identifier tokens store a PAN. Including an instrument identifier in subsequent MITs eliminates the need to include a PAN and the previous transaction's ID.
:

    ```
    "processingInformation": {
        "actionTokenTypes": [
          "instrumentIdentifier"
    ]
    ```

**Instrument Identifier, Payment Instrument, and Customer Identifier**
:
You can also create multiple `TMS` token types in the same authorization. This example includes an instrument identifier, a payment instrument, and a customer token in the same authorization:
:

    ```
     "processingInformation": {
        "actionTokenTypes": [
            "instrumentIdentifier",
            "paymentInstrument",
            "customer"
    ]
    ```

Endpoint {#credentials-ucof-cit-tms-intro_d10e16}
-------------------------------------------------

**Production:** `POST ``https://api.visaacceptance.com``/pts/v2/payments`{#credentials-ucof-cit-tms-intro_d10e25}  
**Test:** `POST ``https://apitest.visaacceptance.com``/pts/v2/payments`{#credentials-ucof-cit-tms-intro_d10e35}

Required Fields for CIT Unscheduled COF Payments with `TMS` {#credentials-ucof-cit-tms-reqfields}
=================================================================================================

orderInformation.amountDetails.currency
:

orderInformation.amountDetails.totalAmount
:

orderInformation.billTo.address1
:

orderInformation.billTo.administrativeArea
:

orderInformation.billTo.country
:

orderInformation.billTo.email
:

orderInformation.billTo.firstName
:

orderInformation.billTo.lastName
:

orderInformation.billTo.locality
:

orderInformation.billTo.phoneNumber
:

orderInformation.billTo.postalCode
:

paymentInformation.card.expirationMonth
:

paymentInformation.card.expirationYear
:

paymentInformation.card.number
:

processingInformation.actionList
:
Set the value to `TOKEN_CREATE`

processingInformation.actionTokenTypes
:
Set to one or more of these values:

    * `customer`
    * `instrumentIdentifier`
    * `paymnentInstrument`

processingInformation.commerceIndicator
:
Set the value to `internet`, `MOTO`, or a payer authentication value.

REST Example: Initial CIT Unscheduled COF Payment in TMS {#credentials-ucof-cit-tms-ex-rest}
============================================================================================

Request

```keyword
{
  "processingInformation": {
    "actionList": [
      "TOKEN_CREATE"
    ],
    "actionTokenTypes": [
      "customer"
    ],
    "commerceIndicator": "internet"
  },
  "paymentInformation": {
    "card": {
      "number": "4111111111111111",
      "expirationMonth": "12",
      "expirationYear": "2031"
    }
  },
  "orderInformation": {
    "amountDetails": {
      "totalAmount": "102.21",
      "currency": "ABC"
    },
    "billTo": {
      "firstName": "John",
      "lastName": "Doe",
      "address1": "1 Market St",
      "locality": "san francisco",
      "administrativeArea": "CA",
      "postalCode": "94105",
      "country": "US",
      "email": "test@vas.com",
      "phoneNumber": "444-4444-4444"
    }
  }
}
```

Response to a Successful Request

```
{
  "_links": {
    "authReversal": {
      "method": "POST",
      "href": "/pts/v2/payments/6976866073586557303955/reversals"
    },
    "self": {
      "method": "GET",
      "href": "/pts/v2/payments/6976866073586557303955"
    },
    "capture": {
      "method": "POST",
      "href": "/pts/v2/payments/6976866073586557303955/captures"
    }
  },
  "clientReferenceInformation": {
    "code": "1697686607441"
  },
  "id": "6976866073586557303955",
  "orderInformation": {
    "amountDetails": {
      "authorizedAmount": "102.21",
      "currency": "ABC"
    }
  },
  "paymentAccountInformation": {
    "card": {
      "type": "001"
    }
  },
  "paymentInformation": {
    "tokenizedCard": {
      "type": "001"
    },
    "card": {
      "type": "001"
    }
  },
  "pointOfSaleInformation": {
    "terminalId": "111111"
  },
  "processorInformation": {
    "approvalCode": "888888",
    "networkTransactionId": "123456789619999",
    "transactionId": "123456789619999",
    "responseCode": "100",
    "avs": {
      "code": "X",
      "codeRaw": "I1"
    }
  },
  "reconciliationId": "62699023FNN143DG",
  "status": "AUTHORIZED",
  "submitTimeUtc": "2023-10-19T03:36:47Z",
  "tokenInformation": {
    "customer": {
      "id": "080A6C3842C72DCBE063A2598D0AA98B"
    }
  }
}
```

