Webhook replay can grant duplicate account credit
BLOCKER · BILLINGsrc/billing/webhook.ts:84–119 · fixture anchor
The handler writes account credit before recording the provider event ID. A retried delivery can repeat the credit mutation.
- Impact
- One paid event can create more than one credit grant.
- Close condition
- Persist and enforce provider event idempotency in the same transaction as the credit mutation; add a replay test.
- Evidence
- Fixture test replays the same signed event twice and observes two credit rows.