Billing
Billing endpoints integrate with Stripe for subscription management.
Plans
| Plan | Price | Events/mo | Endpoints | Retention |
|---|---|---|---|---|
| Free | $0 | 1,000 | 1 | 7 days |
| Starter | $29/mo | 100,000 | 10 | 30 days |
| Pro | $99/mo | 1,000,000 | 50 | 90 days |
Create Checkout Session
POST /api/v1/billing/checkoutRequest Body
json
{
"plan": "starter",
"success_url": "https://example.com/success",
"cancel_url": "https://example.com/cancel"
}Response
json
{
"url": "https://checkout.stripe.com/..."
}Redirect the user to the Stripe checkout URL.
Customer Portal
GET /api/v1/billing/portalQuery Parameters
| Param | Required | Description |
|---|---|---|
return_url | Yes | URL to redirect after portal session |
Response
json
{
"url": "https://billing.stripe.com/..."
}Redirect the user to the Stripe customer portal to manage their subscription.
Stripe Webhook
POST /api/v1/billing/webhookReceives Stripe webhook events (e.g., checkout.session.completed, customer.subscription.updated). No authentication required — verified via Stripe webhook signature.
Note: Billing endpoints are stubs for the MVP. Full Stripe integration will be available in v1.0.