Monetization model¶
Product pricing (Stripe Checkout + Customer Portal + webhooks):
| Plan | Price | Limits | Features |
|---|---|---|---|
| Free | $0 | 1 agent | Dashboard, metrics, ingest |
| Pro | $99/mo | 10 agents | Full analytics |
| Business | $499/mo | 50 agents | ROI, comparison, reports |
| Enterprise | custom | Unlimited | All features (plan=enterprise via super_admin) |
Subscription gate¶
For pro / business, plan features and agent limits apply only while subscription_status is active or trialing. Otherwise the tenant is treated as free (402 on gated features / agent slots).
enterprise is manual (super_admin) and is not gated on Stripe status.
API¶
| Method | Path | Notes |
|---|---|---|
| GET | /api/v1/billing/status |
Plan + limits |
| GET | /api/v1/billing/subscription |
Live subscription summary for Settings |
| POST | /api/v1/billing/checkout |
{ "plan": "pro" \| "business" } → Checkout URL |
| POST | /api/v1/billing/create-portal-session |
{ "url" } Customer Portal |
| POST | /api/v1/billing/portal |
Legacy alias → { "portal_url" } |
| POST | /api/v1/billing/webhook |
Stripe signed webhooks |
Env: STRIPE_SECRET_KEY, STRIPE_WEBHOOK_SECRET, STRIPE_PRICE_PRO, STRIPE_PRICE_BUSINESS,
STRIPE_SUCCESS_URL / STRIPE_CANCEL_URL → /src/pages/settings.html?billing=success|cancel.
UI¶
Settings → Subscription & billing — plan status, Checkout, Manage subscription (Portal).
Return from Stripe lands on Settings with toast (billing=success|cancel).
New tenants start on Free. Exceeding agent limits or using gated features returns 402.