> ## Documentation Index
> Fetch the complete documentation index at: https://docs.ionicfi.com/llms.txt
> Use this file to discover all available pages before exploring further.

# The SetupIntent object

> Save a card for future use without charging it.

<ResponseExample>
  ```json The SetupIntent object theme={null}
  {
    "id": "seti_01JEXAMPLE2K8V4N9C6M1Q7R",
    "object": "setup_intent",
    "customer": null,
    "status": "requires_confirmation",
    "payment_method": null,
    "client_secret": "seti_01JEXAMPLE2K8V4N9C6M1Q7R_secret_EXAMPLE",
    "metadata": {},
    "livemode": false
  }
  ```
</ResponseExample>

A SetupIntent (`seti_…`) guides the process of saving a card for future use without collecting a payment. Your server creates it with a currency and an optional customer, then the buyer's browser confirms it with a single-use payment token. On success, Ionic creates a reusable [PaymentMethod](/api-reference/payment-methods) (`pm_…`) and links it to the SetupIntent. When a `customer` is supplied, a mandate is created on confirm and the PaymentMethod is linked to that customer.

Browser collection uses Ionic.js Payment Blocks with a publishable key and the `client_secret` returned at creation. The management endpoints require a secret key. For the full flow, see [Save cards](/guides/save-cards). Platforms acting for a connected account follow [Save cards for connected accounts](/guides/connect-save-cards).

## Attributes

<ResponseField name="id" type="string">
  Unique identifier for the setup intent (`seti_…`).
</ResponseField>

<ResponseField name="customer" type="string | null">
  The customer this intent is attached to (`cus_…`), or null if not customer-scoped.
</ResponseField>

<ResponseField name="status" type="string">
  `requires_confirmation`: initial state; awaiting a client-side token. `processing`: vault operation is in progress. `succeeded`: card vaulted and payment method created. `canceled`: intent was canceled before completion.
</ResponseField>

<ResponseField name="payment_method" type="string | null">
  The reusable payment method created when the card was vaulted (`pm_…`). Null until `succeeded`.
</ResponseField>

<ResponseField name="client_secret" type="string">
  Returned only when creating the intent. Pass to Ionic Blocks to collect and save a payment method. Keep out of URLs and logs.
</ResponseField>

<ResponseField name="metadata" type="object">
  Custom key-value pairs for your use.
</ResponseField>

See every field in the response of [Retrieve a setup intent](/api-reference/setup-intents/retrieve-a-setup-intent).

## Endpoints

| Endpoint | Use it for |
| - | - |
| [Create a setup intent](/api-reference/setup-intents/create-a-setup-intent) | Start saving a card, optionally for a customer. |
| [List setup intents](/api-reference/setup-intents/list-setup-intents) | Review setup intents. |
| [Retrieve a setup intent](/api-reference/setup-intents/retrieve-a-setup-intent) | Check the current status and the resulting payment method. |
| [Confirm a setup intent](/api-reference/setup-intents/confirm-a-setup-intent) | Submit the single-use payment token to save the card. |
| [Cancel a setup intent](/api-reference/setup-intents/cancel-a-setup-intent) | Cancel an intent that has not been confirmed. |

## Statuses

| Status | Meaning |
| - | - |
| `requires_confirmation` | Initial state, awaiting a client-side token. Collect a token and confirm, or cancel. |
| `processing` | The vault operation is in progress. |
| `succeeded` | The card was saved and a PaymentMethod was created. Read the PaymentMethod from `payment_method`. |
| `canceled` | The intent was canceled before completion. |

## Rules

* If saving the card fails, the intent returns to `requires_confirmation` so you can retry with a fresh token.
* Only an intent in `requires_confirmation` can be canceled. An intent that is `processing`, `succeeded`, or already `canceled` cannot.
* `payment_method` is null until the intent is `succeeded`.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.