Skip to main content
POST
/
billing
/
api
/
v1
/
billing
/
resolver
/
{organization_id}
/
portal
Create billing portal session
curl --request POST \
  --url https://www.closient.com/billing/api/v1/billing/resolver/{organization_id}/portal \
  --header 'Content-Type: application/json' \
  --header 'X-API-Key: <api-key>' \
  --data '
{
  "return_url": "<string>"
}
'
{
  "portal_url": "<string>"
}

Authorizations

X-API-Key
string
header
required

Path Parameters

organization_id
string<shortuuid>
required

UUID of the organization.

Required string length: 22
Pattern: ^[23456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz]{22}$

Body

application/json

Request body for opening a Stripe Customer Portal session.

return_url
string
required

Absolute URL Stripe Customer Portal redirects the customer back to after they finish managing their subscription (e.g. updating a payment method, downloading invoices, or self-service cancelling).

Response

OK

Response for POST /billing/resolver/{organization_id}/portal.

portal_url
string
required

Stripe-hosted Customer Portal URL. Single-use; expires after a short window. The customer manages their subscription, payment methods, and invoices on Stripe's side — Closient receives webhooks for any state changes that result.