Process Credit Card Purchase

​

Processes a credit card purchase transaction. Charges the specified amount to the provided credit card and returns transaction details including the PAR Pay transaction ID.

Headers

  • A custom HTTP header that accepts a free-form string value. It is used to identify the application making the API request. For example, if Punchh invokes the API, the value could be "punchh".

  • The unique location identifier for the store or business location processing the transaction.

  • The media type of the request body. Must be set to application/json.

  • Bearer token for API authorization. Send in the format: Bearer ACCESS_TOKEN_GOES_HERE.

Body·

application/json

Request details for purchase transaction

  • A unique reference number for the transaction.

  • Properties: 5
  • The transaction date and time in UTC format.

  • Contains the user's billing-related details (cardholder information) for Address Verification System (AVS) processing and for populating records at the payment gateway. This object is optional; passing null or omitting it maintains backward compatibility. This object is request-only and is not returned in API responses.

    Validation & Error Handling

    If any field inside billingAddress fails its length or format validation rules (for example, an invalid email format in billingEmailId or a string that exceeds the specified character limit), the API rejects the request before contacting the gateway.

    • HTTP Status: 422 Unprocessable Entity
    • Behavior: The transaction is aborted before the payment processor is contacted.

    Gateway Processing & Data Security

    Gateway Forwarding

    • Aurus Gateway: Full support. Forwards billingAddress data to Aurus for AVS checks.
    • Other Payment Gateways: Gracefully ignore billingAddress without returning an error.

    Data Privacy & Log Masking

    • Masked PII: billingFirstName, billingLastName, billingEmailId, and billingMobileNumber are redacted or masked in stored application and audit logs.
    • Unmasked Address Information: billingAddressLine1, billingAddressLine2, billingCity, billingState, billingCountry, and billingZip remain visible in logs to facilitate AVS decline analysis.
    Properties: 10
  • values
    NonePOSKiosk
  • The invoice number associated with the transaction.

  • Indicates whether this saved card should be set as the user's preferred payment method.

  • A temporary, single-use token generated to securely represent the credit card used for the purchase. This token is exchanged for a reusable paymentMethodToken that can be used for future transactions. Required if paymentMethodToken is not provided.

  • A reusable token generated from a one time token (oneTimeToken), representing a saved credit card for recurring payments.

  • values
    ScanToPayOnlineNone
  • Gets or sets a value indicating whether the user's card information should be saved for future use.

  • The transaction date and time in local format.

Responses

  • application/json
  • application/json
  • application/json
  • application/json
  • application/json
  • application/json
  • application/json
  • application/json
Request Example for post/creditcard/v1/purchase
curl https://SERVER_NAME_GOES_HERE.partech.com/creditcard/v1/purchase \
  --request POST \
  --header 'x-applicationSource: ' \
  --header 'X-LocationId: ' \
  --header 'Content-Type: application/json' \
  --header 'Authorization: Bearer ACCESS_TOKEN_GOES_HERE' \
  --data '{
  "paymentMethodToken": "PAYMENT_TOKEN_GOES_HERE",
  "oneTimeToken": "ONETIME_TOKEN_GOES_HERE",
  "walletPay": null,
  "saveCard": true,
  "userId": null,
  "isPreferred": false,
  "referenceNumber": "258",
  "invoiceNumber": 2148,
  "transactionDateTimeUTC": "2026-03-06T11:28:29.7008363Z",
  "transactionDateTimeLocal": "2026-03-06T11:28:29.7",
  "transactionAmountDetails": {
    "taxAmount": 50,
    "discount": 0,
    "productTotalAmount": 950,
    "totalAmount": 1000,
    "tip": 0
  },
  "paymentSource": "ScanToPay",
  "channel": null,
  "billingAddress": {
    "billingAddressLine1": "100 Innovation Way",
    "billingCity": "San Jose",
    "billingState": "CA",
    "billingCountry": "US",
    "billingZip": "95134",
    "billingFirstName": "Alex",
    "billingLastName": "Smith",
    "billingEmailId": "alex.smith@example.com",
    "billingMobileNumber": "14085550123"
  }
}'
{
  "transactionAmount": "5000.00",
  "cardNumber": "XXXX-XXXX-XXXX-1111",
  "paymentMethodToken": "paymentToken",
  "lastFourDigits": "1111",
  "cardType": "Visa",
  "expireMonth": 10,
  "expireYear": 2027,
  "cardHolderName": "CARDHOLDER_NAME_GOES_HERE",
  "parPayTransactionId": "TRANSACTION_ID_GOES_HERE",
  "statusMessage": "APPROVAL",
  "transactionDateTimeUTC": "2026-03-06T11:28:29.7009419Z",
  "status": "Success"
}