anon_email
API referenceBilling

Open the card billing portal

POST
/billing/portal

Returns a hosted Polar customer-portal URL for managing the card subscription (update card, cancel at period end). Crypto subscriptions renew manually and have no portal.

Authorization

CognitoUserPool
headerAuthorizationBearer <token>

Cognito user pool ID token. API Gateway validates the token (identity token: no OAuth scopes are configured on the authorizer) and forwards its claims; the sub claim is the tenant key.

Response Body

Hosted portal URL.

application/json
  1. response
checkout_url*string

Hosted checkout or customer-portal URL to redirect to.

Formaturi
curl -X POST "https://example.com/billing/portal"
{  "checkout_url": "http://example.com"}