# Create a Single-Step Card Present Payment

This guide walks you through processing a complete single-step payment transaction using the Getnet Global API for **Card Present (CP)** environments. This flow involves capturing payment data directly from physical hardware without a previous authorization.

## Requirements

Before following the steps, you need to:

- **Credentials**: Obtain your `client_id` and `client_secret` from the Integration Support team.
- **Authentication**: Generate a Bearer token via the [Authentication endpoint](https://api.pre.globalgetnet.com/authentication/oauth2/access_token).
- **Hardware Identification**: Have the terminal identifiers registered to your physical device: `terminal_number`, `logical_code`, and `serial_number`.

> **Payment facilitators**: When Getnet enables your credential as a payment facilitator, you must also send the `data.sub_merchant` object on this request. Card-present payment facilitator transactions are available in Brazil. See [Payment Facilitators](/en/global-api/reference-global/payment-facilitators).

## Use Case Specifics: Card Verification Methods

Card Present transactions require a **Cardholder Verification Method (CVM)** and an **Entry Mode** defined in the `card` object.

- **Chip + PIN**: Requires the hardware to capture an encrypted `pin_block` and a `ksn` (Key Serial Number).
- **Chip (No CVM)**: Used for low-value transactions or contactless taps that do not require a PIN.
- **Magnetic Stripe**: The card is swiped, and the full `track_2` data is transmitted.

## Single-Step Card Present Process

For single-step flows, set the `payment_method` to **`DIRECT_CREDIT`** or **`DIRECT_DEBIT`** to ensure immediate capture.

### Step 1: Capture the Payment

To process a single-step CP payment, use the [Create – Authorize endpoint](https://docs.globalgetnet.com/en/products/online-payments/regional-api/swagger#tag/payments/post/dpm/payments-gwproxy/v2/payments) with the `x-transaction-channel-entry: XX` header.

#### Mandatory Attributes for Card Present

For a full list of base attributes (amount, currency, etc.), refer to the [Payment API Reference](https://docs.globalgetnet.com/en/products/online-payments/regional-api/swagger#tag/payments). The table below highlights the specific objects required for physical card interactions:

| Object | Attribute | Description | Required |
| --- | --- | --- | --- |
| `terminal` | `terminal_number` | The unique ID of the device reading the card. | **Yes** |
| `terminal` | `logical_code` | The logical code assigned to the terminal. | **Yes** |
| `terminal` | `serial_number` | The physical serial number of the terminal device. | **Yes** |
| `card` | `entry_mode` | Set to `chip` or `magnetic_stripe`. | **Yes** |
| `card` | `cardholder_verification_method` | Use `online_pin` or `no_cvm`. | **Yes (Chip)** |
| `card` | `emv` | The encrypted TLV data string from the chip. | **Yes (Chip)** |
| `card` | `track_2` | The card's track data captured during swipe or chip read. | **Yes** |
| `card` | `pin_block` | The ISO-9564 encrypted PIN block. | **Yes (PIN)** |
| `card` | `ksn` | The DUKPT Key Serial Number for PIN decryption. | **Yes (PIN)** |

Choose the example below that matches your terminal's hardware interaction.

#### Example 1: Chip + Online PIN

Used when the customer inserts their card and enters a PIN on the device.

```json
{
  "idempotency_key": "5e019fb3-ebf8-4fab-b826-ece982236440",
  "request_id": "f0612285-9493-4c2c-a05a-00268a51ea3a",
  "order_id": "64af4497-864e-430c-9271-826601427a1d",
  "data": {
    "amount": 30960,
    "currency": "CLP",
    "customer_id": "ed2da8dd-1ba9-46e9-8501-f7987dcd9964",
    "payment": {
      "payment_id": "6137278d-28a6-4293-9343-c73fbb2d9bda",
      "payment_method": "DIRECT_CREDIT",
      "transaction_type": "FULL",
      "number_installments": 1,
      "soft_descriptor": "MINHA*LOJA",
      "card": {
        "number": "your_card_number",
        "entry_mode": "chip",
        "cardholder_verification_method": "online_pin",
        "seq_number": "000",
        "pin_block": "A0B6BA8D53C8D3C3",
        "ksn": "BC756011020000400001",
        "emv": "9f2701809f3303e0f8c8950580000080009f37045d21705a9f100706010a03a0b8089f2608819ba36f3f7934149f360205b782021c009c01009f1a0204849a032002279f02060000000309605F2A0200325f3401019f34031e03009f120c56495341204352454449544f5f201a2f435249535449414e2047414c494e444f2043484156455a2020",
        "aid": "A0000000031010",
        "track_2": "4508830000001759=281028102800006930"
      },
      "terminal": {
        "terminal_number": "21000334",
        "logical_code": "21000334",
        "serial_number": "CS21000334A"
      }
    }
  }
}
```

#### Example 2: Chip (No CVM)

Used for chip transactions where no PIN or signature is required.

```json
{
  "idempotency_key": "c07372cf-6d11-4980-801f-a365840a0386",
  "request_id": "f01db451-fe50-42d3-82d1-d64cedfdc7e8",
  "order_id": "d14c1129-964f-4fc7-b284-87d890820660",
  "data": {
    "amount": 30960,
    "currency": "CLP",
    "customer_id": "30ca15ad-db8b-4571-858e-dfe4cd46e3f8",
    "payment": {
      "payment_id": "your payment_id",
      "payment_method": "DIRECT_DEBIT",
      "transaction_type": "FULL",
      "number_installments": 1,
      "soft_descriptor": "MINHA*LOJA",
      "card": {
        "number": "you_card_number",
        "entry_mode": "chip",
        "cardholder_verification_method": "no_cvm",
        "emv": "9f2701809f3303e0f8c8950580000080009f37045d21705a9f100706010a03a0b8089f2608819ba36f3f7934149f360205b782021c009c01009f1a0204849a032002279f02060000000309605F2A0200325f3401019f34031e03009f120c56495341204352454449544f5f201a2f435249535449414e2047414c494e444f2043484156455a2020",
        "aid": "A0000000031010",
        "track_2": "4508830000001759=281028102800006930"
      },
      "terminal": {
        "terminal_number": "123456",
        "logical_code": "123456",
        "serial_number": "CS123456A"
      }
    }
  }
}
```

#### Example 3: Magnetic Stripe (Swipe)

Used when the card's magnetic stripe is swiped through the reader.

```json
{
  "idempotency_key": "a61a2391-1372-46d9-9b8b-e3e265036367",
  "request_id": "140214fa-ff1d-4ecb-a6c8-2e1c828a944c",
  "order_id": "22e6bc02-0b55-4ed8-a131-a5e35b400297",
  "data": {
    "amount": 5000,
    "currency": "CLP",
    "payment": {
      "payment_method": "DIRECT_CREDIT",
      "transaction_type": "FULL",
      "number_installments": 1,
      "soft_descriptor": "MINHA*LOJA",
      "card": {
        "number": "5213120418132948",
        "expiration_month": "08",
        "expiration_year": "28",
        "entry_mode": "magnetic_stripe",
        "track_2": "5213120418132948=301220111379456001"
      },
      "terminal": {
        "terminal_number": "21000335",
        "logical_code": "21000335",
        "serial_number": "CS21000335A"
      }
    }
  }
}
```

#### Example 4: Purchase with Cash Withdrawal (Cashout)

Cashout lets the cardholder withdraw cash at the point of sale during a purchase. Send the withdrawal amount in `data.cashout.cashout_amount`, and make `data.amount` the total of the operation: purchase plus withdrawal. Getnet Argentina (AR) only.

Cashout has tighter constraints than a standard single-step sale:

| Rule | Value |
| --- | --- |
| `payment_method` | `DIRECT_DEBIT` only |
| Card type | Domestic debit or domestic prepaid |
| `entry_mode` | `chip` or `chip_contactless` only |
| Authorization records | One record covers the purchase and the withdrawal |

In the example below, `amount` is 200000: a 190000 purchase plus a 10000 withdrawal.

```json
{
  "idempotency_key": "655813d3-a9d9-4163-a4d3-290de5a72716",
  "request_id": "35a71684-466b-4ba1-88d5-d61d759fb11e",
  "order_id": "1357fd92-7c5c-42e9-828b-fbed427421a7",
  "data": {
    "amount": 200000,
    "currency": "ARS",
    "cashout": {
      "cashout_amount": 10000
    },
    "payment": {
      "payment_method": "DIRECT_DEBIT",
      "transaction_type": "FULL",
      "number_installments": 1,
      "card": {
        "number": "4517510045707615",
        "entry_mode": "chip",
        "seq_number": "1",
        "cardholder_verification_method": "no_cvm",
        "emv": "9F2701809F3303E0F8C8950580000080009F37045D21705A57104055310000003334D3312102000000009F100706010A03A0B8089F2608819BA36F3F7934149F360205B782021C009C01009F1A0204849A032002279F02060000000309605F2A0200325F3401019F34031E03009F120C56495341204352454449544F5F201A2F435249535449414E2047414C494E444F2043484156455A2020",
        "track_2": "4517510045707615=331210200000000"
      },
      "terminal": {
        "terminal_number": "PAR5533A"
      }
    }
  }
}
```

To reverse a cashout sale, see [Cancel a Card Present Payment](/en/global-api/sep-card-present/payment-guides-cp/cancel-a-payment-cp) — the cancellation contract differs from a standard reversal.

### Step 2: Verify the Response

Upon success, the API returns the status and the unique `payment_id` for the physical sale.

```json
{
  "status": "APPROVED",
  "payment_id": "6137278d-28a6-4293-9343-c73fbb2d9bda",
  "amount": 30960,
  "authorization_code": "204050",
  "reason_message": "captured"
}

```

## Next Steps

Now that you have processed a single-step sale, explore these advanced Card Present features:

- **[Two-Step Pre-Authorization](/en/global-api/sep-card-present/payment-guides-cp/pre-auth-payment-cp)**: Learn how to reserve funds on a physical card for later capture.
- **[Handling Installments](/en/global-api/sep-card-present/payment-guides-cp/installment-payments-cp)**: Offer splitting the purchase price into multiple payments directly at the terminal.