Add Stripe webhook handler for customer.subscription.deleted event #772

Open
opened 2026-04-11 16:42:30 -04:00 by pook · 0 comments
Owner

Add a handler for the customer.subscription.deleted Stripe webhook event. When received: (1) Extract the customer ID from event.data.object.customer. (2) Look up the user by stripe_customer_id in the database. (3) Update the subscription status to 'canceled' in the stripe_subscriptions table. (4) Return 200 acknowledgment. Add this to the webhook event router (issue #755) or as a standalone handler in src/billing/webhooks.ts. Pattern match the existing checkout.session.completed handler (issue #744). Acceptance: subscription.deleted event sets status to 'canceled' in database; returns 200.


Generated by CEO Planner (priority: 3)

Add a handler for the customer.subscription.deleted Stripe webhook event. When received: (1) Extract the customer ID from event.data.object.customer. (2) Look up the user by stripe_customer_id in the database. (3) Update the subscription status to 'canceled' in the stripe_subscriptions table. (4) Return 200 acknowledgment. Add this to the webhook event router (issue #755) or as a standalone handler in src/billing/webhooks.ts. Pattern match the existing checkout.session.completed handler (issue #744). Acceptance: subscription.deleted event sets status to 'canceled' in database; returns 200. --- *Generated by CEO Planner (priority: 3)*
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
pook/compliancebot#772
No description provided.