Payments & billing
The 6 endpoints /api/v1 serves under Payments & billing.
POST /api/v1/payments/checkout
http
POST /api/v1/payments/checkout- Auth: required (owner|admin)
- Body: { planId }
200
POST /api/v1/payments/portal
http
POST /api/v1/payments/portal- Auth: required (owner|admin)
200404— no billing customer on file
GET /api/v1/tenants/:id/billing
http
GET /api/v1/tenants/:id/billing- Auth: required (tenant member)
200
GET /api/v1/tenants/:id/billing/invoices
http
GET /api/v1/tenants/:id/billing/invoices- Auth: required (tenant member)
200
GET /api/v1/tenants/:id/billing/invoices/:invoiceId/pdf
http
GET /api/v1/tenants/:id/billing/invoices/:invoiceId/pdf- Auth: required (owner|admin)
200403404409— a PDF is still being generated
POST /webhooks/billing
http
POST /webhooks/billing- Auth: HMAC (BillingWebhookVerifier) — not JWT
200