subscription.* event, keyed by its id, and decide access from the stored copy:
Handle events idempotently
- Events can arrive more than once and out of order. Upsert the subscription by
id, and ignore an event whosecreatedAtis older than the copy you stored. - Grant access on
subscription.createdfor a trial, and onsubscription.createdorsubscription.renewedfor a paid start. - Re-evaluate access on every
subscription.updated,subscription.past_dueandsubscription.cancelled. - When in doubt, read
GET /subscriptions/:id; it is always current.