# Open billing portal

`POST /v1/billing/portal`

Answers with the address of the page where the card, the plan and past invoices are managed.

Needs the scope: `workspace:write`

## Returns

- `object` ("checkout"): Always `checkout`.
- `url` (string): The address of the page to send the person to.

## Example

cURL:

```bash
curl -X POST "$OPENSEND_API_URL/v1/billing/portal" \
  -H "Authorization: Bearer $OPENSEND_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'
```

TypeScript:

```ts
await opensend.billing.portal()
```

CLI:

```bash
opensend billing portal
```

MCP:

```json
{
  "name": "billing_portal",
  "arguments": {}
}
```

Answer:

```json
{
  "object": "checkout",
  "url": "https://pay.example.com/portal"
}
```
