---
title: "Start a card change: returns a SetupIntent client secret for the Element."
method: POST
path: "/api/v1/billing/setup-intent"
tags: ["Billing"]
---

# Start a card change: returns a SetupIntent client secret for the Element.

`POST /api/v1/billing/setup-intent`

## Request

- Base URL: `https://api.avatarfactory.io` (the document declares no server; this is the origin it was published from)
- URL: `https://api.avatarfactory.io/api/v1/billing/setup-intent`
- Auth: one of:
  - API key in cookie `session`
  - HTTP bearer

## Response `200`

OK

- SetupIntentResponse
  - `client_secret` string, nullable
  - `setup_intent_id` string, required

## Other responses

- `400`: Bad Request
- `422`: Unprocessable Entity

---

[API](https://skmtc.dev/avatarfactory/apis/avatarfactory-api.md) · [All operations](https://skmtc.dev/avatarfactory/apis/avatarfactory-api/llms.txt) · [OpenAPI document](https://skmtc.dev/avatarfactory/apis/avatarfactory-api/revisions/66fc7aa3f296?raw)
