---
title: "Open a customer-portal session for this account"
method: POST
path: "/api/billing/portal"
tags: ["billing"]
---

# Open a customer-portal session for this account

`POST /api/billing/portal`

## Request

- Base URL: `https://app.nerdit.ai` (the document declares no server; this is the origin it was published from)
- URL: `https://app.nerdit.ai/api/billing/portal`
- Auth: none declared

Refuse an account the provider has never met, then hand over a URL.

The local ``polar_customer_id`` is the gate rather than the key: it is
how this deployment knows a Polar customer exists, while the session
itself is minted against the external id so a stale projection can
never open somebody else's portal.

## Response `200`

Successful Response

- PortalSessionView: A short-lived customer-portal URL for self-service plan management.
  - `portal_url` string, required

## Other responses

- `401`: Unauthorized
- `403`: Forbidden
- `409`: Conflict
- `503`: Service Unavailable

---

[API](https://skmtc.dev/nerdit/apis/nerdit-cloud-web.md) · [All operations](https://skmtc.dev/nerdit/apis/nerdit-cloud-web/llms.txt) · [OpenAPI document](https://skmtc.dev/nerdit/apis/nerdit-cloud-web/revisions/06e3b44b58be?raw)
