Purpose
Handles Stripe webhook events for subscription management. Updates both database and Clerk organization metadata.Handled Events
Architecture
Signature Verification
UsesSTRIPE_WEBHOOK_SECRET to verify webhook authenticity.
Documentation Index
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
Architecture for the Stripe Webhook endpoint
| Event | Action |
|---|---|
checkout.session.completed | Link Stripe customer to org, set status active |
customer.subscription.created | Update subscription status |
customer.subscription.updated | Update subscription status |
customer.subscription.deleted | Set status to canceled |
STRIPE_WEBHOOK_SECRET to verify webhook authenticity.
src/app/webhooks/stripe_webhook/routes.py