-
Payments
Model subscription states correctly
Implements the real subscription lifecycle (trialing, active, past_due, canceled) with access rules per state.
Free Prompt
What This Does / How This Helps
Replaces the single 'subscribed: true/false' flag with the actual states subscriptions live in, and defines what access each state grants. A boolean can't express the situations that matter: the card that failed Tuesday but might succeed Friday, the user who canceled but paid through the end of the month, the trial that ends tonight. Apps with a boolean handle these by accident: cutting off paying customers during a retry, or giving canceled users free months forever. The lifecycle test pass proves the whole loop, including the past_due recovery that determines whether a temporary card problem becomes a lost customer.
Want to skip doing this by hand?
Fortivibe audits your app for all of the areas these prompts cover (and more).