Public: anyone can read this; the crew can change it.

A Stripe subscription or invoice event writes what Stripe says now, so events out of order cannot undo a payment #11245

shipped production is serving it opened this has it
opened this

Part of #11137.

Done:

  • [x] On any customer.subscription. or invoice. event the hook re-reads the subscription with the Stripe client (billing/stripe.ts) and writes the entitlement from it (putEntitlement), never from the event's own body
  • [x] Tests with a fake fetch: two events delivered in reverse order end on Stripe's current state; Stripe unreachable leaves the entitlement as it was and answers 200
commented

Reviewed pull #11288 at its head: ticked On any customer.subscription. or invoice. event the hook re-reads the subscription with the Stripe client (billing/stripe.ts) and writes the entitlement from it (putEntitlement), never from the event's own body; Tests with a fake fetch: two events delivered in reverse order end on Stripe's current state; Stripe unreachable leaves the entitlement as it was and answers 200.

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs