# Simulate 3DS authentication

**POST** `/simulate/issuing/cards/{card_id}/threeds/challenge`

Simulate a 3DS authentication attempt for a sandbox card and return the resulting 3DS attempt.

Set `realtime_decision` to supply the authentication decision without calling your endpoint. When it is omitted, Column
sends a 3DS authentication decision request to your endpoint subscribed to `decision.issuing.card_authentication`; if
no endpoint is subscribed, the simulator creates an OTP challenge.

`frictionless_approve` authenticates the attempt and fires `issuing.3ds.authentication_completed`.
`challenge` starts an OTP challenge and fires `issuing.3ds.otp_generated`. Finish it with the complete 3DS challenge

endpoint.

`decline_authentication` rejects the attempt and fires `issuing.3ds.authentication_completed`.

### Path Parameters

- `card_id` `string` _(required)_ — Unique identifier for the card.

### Body Parameters

- `amount` `number` _(required)_ — Transaction amount in the smallest unit of the currency (e.g., cents for USD).
- `currency` `string` _(required)_ — ISO 4217 currency code for the transaction.
- `decline_reason` `enum` — The simulated decline reason. Only meaningful when `realtime_decision` is
  `decline_authentication`; when omitted, Column defaults to `suspected_fraud`.
  Possible values: `suspected_fraud`, `transaction_not_permitted`
- `realtime_decision` `enum` — Overrides the real-time 3DS decisioning webhook response for this simulated authentication.
  When omitted and the platform has a webhook endpoint subscribed to
  `decision.issuing.card_authentication`, the webhook is actually invoked.
  Possible values: `frictionless_approve`, `challenge`, `decline_authentication`

**Request**

```shell
curl 'https://api.column.com/simulate/issuing/cards/<card_id>/threeds/challenge' \
  -XPOST \
  -u :<YOUR API KEY> \
  -H 'Content-Type: application/json' \
  -d '{
  "amount": 1000,
  "currency": "USD",
  "decline_reason": "suspected_fraud",
  "realtime_decision": "frictionless_approve"
}'
```

**Response 200**

```json
{
  "acs_transaction_id": "9a2c4e6b-3f1d-4b8a-a5e7-1c3d5f7b9e20",
  "amount": 12345,
  "attempt_count": 1,
  "attempt_status": "authenticated",
  "card_account_id": "cacc_2x8gszy5folpA9s0TOCseE9ABDM",
  "card_id": "card_2x8gszy5folpA9s0TOCseE9ABDM",
  "chosen_challenge": "otp",
  "created_at": "2024-01-15T09:30:00Z",
  "currency": "USD",
  "ds_transaction_id": "4f8b2c1e-9a3d-4e7b-8c6f-2d1a5b9e3c70",
  "id": "tdsa_2x8gszy5folpA9s0TOCseE9ABDM",
  "outcome_reason": "challenged_accepted",
  "realtime_decision": "frictionless_approve",
  "three_ds_message_version": "2.3.1",
  "updated_at": "2024-01-15T09:30:00Z"
}
```
