v2

latestOpenAPI 3.1.02026-08-05267431678.1 KB
billing

Start a credit purchase via Stripe Checkout

Create a Stripe Checkout session for a one-time credit purchase.

Credits are not granted here — the user is redirected to Stripe's hosted checkout, and the checkout.session.completed webhook applies the credits to the team's paid balance once payment is confirmed.

Requires MANAGE_BILLING (owner, admin, or billing role).

post/billing/team/{team_id}/purchase-credits

Path parameters

team_idstring required

Request body

amount_usdnumber required

Amount in USD to purchase (max $500 per transaction)

success_urlstring required

URL Stripe redirects to after a successful payment

cancel_urlstring required

URL Stripe redirects to if the purchase is cancelled

Response

Successful Response

successboolean required
checkout_urlstring nullable

Stripe-hosted Checkout URL to redirect the user to

messagestring

Human-readable status detail