# Create a customer portal session
POST /api/billing/portal
## Request
```bash
curl -X POST 'https://sourced.sh/api/billing/portal' \
  -H 'Authorization: Bearer $SOURCED_API_KEY' \
  -H 'Content-Type: application/json' \
  -d '{}'
```
## Request body

type: object
properties:
  returnUrl: string

## Responses

### 200

Hosted billing portal URL.
### 400

The workspace does not have a Stripe customer yet, or Stripe rejected the portal request.
### 401


### 403


### 423

The billing portal is temporarily locked because live Stripe keys are not active in production.
### 501

Stripe billing portal is not configured.
### 502

Stripe billing portal could not be reached or returned an invalid response.
