---
title: "Create a Stripe Checkout link for a credit pack (the user pays)"
method: POST
path: "/api/v1/checkout"
---

# Create a Stripe Checkout link for a credit pack (the user pays)

`POST /api/v1/checkout`

## Request

- Base URL: `https://api.recolorthepast.com`
- URL: `https://api.recolorthepast.com/api/v1/checkout`
- Auth: one of:
  - HTTP bearer
  - OAuth 2 (authorization code, authorization URL `https://recolorthepast.com/oauth/authorize`, token URL `https://api.recolorthepast.com/oauth/token`, scopes: `billing`)

## Request body

- object
  - `pack` string, required: Pack ID from GET /api/v1/packs
  - `currency` 'eur' | 'usd' | 'gbp'
  - `platform` 'web' | 'mobile'

## Response `200`

Checkout link for the user to open

- CheckoutLink
  - `url` string, uri, required
  - `route` string
  - `simulated` boolean

## Other responses

- `400`: Unknown pack, missing billing country or billing identity
- `401`: Missing, invalid or revoked credential
- `403`: delegated_forbidden or insufficient_scope
- `503`: Billing is unavailable

---

[API](https://skmtc.dev/recolorthepast/apis/recolor-the-past-ai-tools-and-developer-api.md) · [All operations](https://skmtc.dev/recolorthepast/apis/recolor-the-past-ai-tools-and-developer-api/llms.txt) · [OpenAPI document](https://skmtc.dev/recolorthepast/apis/recolor-the-past-ai-tools-and-developer-api/revisions/c42019712c73?raw)
