# Retrieve Payment Methods for Checkout

This request retrieves a checkout session using the unique identifier that was generated when the session was first created.

**GET** `/checkout/sessions/{checkout_session}/payment-methods`

Base URL: `https://api-sandbox.whitelabel.com/v1`

Retrieve Payment Methods for Checkout

## Authorization

- public-api-key (apiKey in header)
- private-secret-key (apiKey in header)

## Path parameters

- `checkout_session` (string, required)
  The unique identifier of the checkout session (UUID, 36 chars).

## Query parameters

- `category` (string)
  Optional category filter.

## Responses

### 200

200

- `name` (string)
- `vaulted_token` (string)
- `description` (string)
- `type` (string)
- `category` (string)
- `icon` (string)
- `last_successfully_used` (boolean)
- `last_successfully_used_at` (string)
- `checkout` (object)
  - `session` (string)
  - `sdk_required_action` (boolean)
  - `conditions` (object)
    - `enabled` (boolean)
    - `rules` (object[])
      List of condition rules (INCLUDE/EXCLUDE) applied to the payment method. Each rule has a type (e.g. METADATA, AMOUNT, COUNTRY) and values.
      - `condition` (string)
        INCLUDE or EXCLUDE
      - `condition_group_code` (string)
        UUID of the condition group
      - `condition_name` (string)
        Human-readable name of the condition
      - `type` (string)
        Rule type: METADATA, AMOUNT, COUNTRY, etc.
      - `values` (object)
        Values used by the rule. Structure depends on rule type: `currency`, `max`, and `min` are strings (nullable); `countries` is an array of strings (e.g. ["AF"]); `metadata` is an array of objects with `key` and `value` (e.g. [{"key": "test", "value": "test"}]).
        - `countries` (string[])
          Array of country codes (e.g. ["AF"], ["US"]). Null when not used by the rule.
        - `currency` (string)
          Currency code when rule type is AMOUNT. Null otherwise.
        - `max` (string)
          Maximum value when applicable. Null otherwise.
        - `metadata` (object[])
          Array of key-value objects (e.g. [{"key": "test", "value": "test"}]). Null when not used by the rule.
          - `key` (string)
          - `value` (string)
        - `min` (string)
          Minimum value when applicable. Null otherwise.
- `card_data` (object)
  - `iin` (string)
  - `lfd` (string)
  - `expiration_month` (integer)
  - `expiration_year` (integer)
  - `number_length` (integer)
  - `security_code_length` (integer)
  - `brand` (string)
  - `issuer` (string)
  - `issuer_code` (any)
  - `category` (string)
  - `type` (string)
- `preferred` (boolean)

Example:

```json
[
  {
    "name": "VISA ****1111",
    "vaulted_token": "de00c1bd-624b-4e7b-ae28-47d86c94b15f",
    "description": "VISA ****1111",
    "type": "CARD",
    "category": "CARD",
    "icon": "https://icons.prod.whitelabel.com/visa_logosimbolo.png",
    "last_successfully_used": false,
    "last_successfully_used_at": "",
    "checkout": {
      "session": "d313047b-4f96-44ef-bbad-caf1d7ba4c2b",
      "sdk_required_action": false,
      "conditions": {
        "enabled": true,
        "rules": [
          {
            "condition": "INCLUDE",
            "condition_group_code": "2b273309-2c63-4ef8-b5f8-2953abf7ad4a",
            "condition_name": "Country-US",
            "type": "COUNTRY",
            "values": {
              "countries": [
                "AF"
              ],
              "currency": null,
              "max": null,
              "metadata": null,
              "min": null
            }
          }
        ]
      }
    },
    "card_data": {
      "iin": "41111111",
      "lfd": "1111",
      "expiration_month": 3,
      "expiration_year": 26,
      "number_length": 16,
      "security_code_length": 3,
      "brand": "VISA",
      "issuer": "JPMORGAN CHASE BANK N A",
      "issuer_code": null,
      "category": "CREDIT",
      "type": "CREDIT"
    },
    "preferred": false
  }
]
```

### 400

400

- `code` (string)
- `messages` (string[])

Example:

```json
{
  "code": "INVALID_REQUEST",
  "messages": [
    "Invalid request"
  ]
}
```

### 401

401

- `code` (string)
- `messages` (string[])

Example:

```json
{
  "code": "INVALID_CREDENTIALS",
  "messages": [
    "Invalid credentials"
  ]
}
```

### 403

403

- `code` (string)
- `messages` (string[])

Example:

```json
{
  "code": "AUTHORIZATION_REQUIRED",
  "messages": [
    "The merchant has no authorization to use this API."
  ]
}
```