---
title: "Create a Stripe SetupIntent for self-serve hosted topup"
method: POST
path: "/v1/billing/stripe/setup-intents"
tags: ["billing"]
---

# Create a Stripe SetupIntent for self-serve hosted topup

`POST /v1/billing/stripe/setup-intents`

## Request

- Base URL: `https://api.runx.ai`
- URL: `https://api.runx.ai/v1/billing/stripe/setup-intents`
- Auth: HTTP bearer

## Request body

- StripeSetupIntentRequest
  - `idempotency_key` string

## Response `201`

Stripe setup intent.

- StripeSetupIntentEnvelope
  - `status` 'created', required
  - `stripe_setup` object, required
    - `customer` string, required
    - `setup_intent_id` string, required
    - `client_secret` string, required

## Other responses

- `400`: Validation error.
- `401`: Unauthorized.
- `503`: Stripe setup is not configured.

---

[API](https://skmtc.dev/runx/apis/runx-hosted-api.md) · [All operations](https://skmtc.dev/runx/apis/runx-hosted-api/llms.txt) · [OpenAPI document](https://skmtc.dev/runx/apis/runx-hosted-api/revisions/6c940d8edacc?raw)
