CustomDomain Docs
Billing

Open a Stripe Billing Portal session

Open a Stripe Billing Portal session: CustomDomain™ API reference in the billing group. Covers request parameters, the request body, responses and error codes.

POST
/billing/portal

Opens the Stripe Billing Portal (invoices, the card, cancellation) for the caller's workspace. Requires billing:manage (owners and admins) and a Stripe customer (a completed checkout). flow deep-links into one task: payment_method_update (the "update your card" link of a payment failure email) or subscription_cancel.

AuthorizationBearer <token>

Long-lived tenant API key, cd_live_… (production) or cd_test_… (staging, development), stored hashed. Keys created before the switch to cd_ start with sk_live_… / sk_test_… and are still accepted. Scoped to the owning application's tenant.

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

application/json

application/json

application/json

curl -X POST "https://example.com/billing/portal" \  -H "Content-Type: application/json" \  -d '{    "return_url": "http://example.com"  }'
{  "id": "string",  "url": "http://example.com"}
{  "code": "string",  "title": "string",  "details": "string"}
{  "code": "string",  "title": "string",  "details": "string"}
{  "code": "string",  "title": "string",  "details": "string"}
{  "code": "string",  "title": "string",  "details": "string"}