Repository navigation
Hosted: renewal, annual, price-change, and dispute notices - #1414
Merged
Merged
Conversation
The account cron records and sends each subscription notice once, to the Stripe billing email: a yearly renewal notice 30 days ahead, a monthly plan's annual reminder before each renewal that ends a year, and a price change's notice 21 days before the renewal it applies at. An operator's dormouse_price_changes row moves a subscriber to the new Price only after their notice was sent at least 7 days before that renewal, never from a founding Price, and only once Stripe's Prices match the recorded amounts. Opening a dispute records its suspension notice, and closing it in the account's favor its restoration notice, in the webhook's transaction; the send follows the commit and the cron retries one that failed. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The Terms state the notice schedule, the billing-email routing and the records kept, and the dispute suspension and restoration emails. Privacy lists the notice records, Postmark sending them, and their retention. hosted.md gains "Billing notices", pricing.md promotes the built notice gates above the fold, security-hosted.md adds FAIL IF S290, and the Hosted README documents how an operator schedules a price change. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Deploying mouseterm with
|
| Latest commit: |
050a5e2
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://1101f1ae.mouseterm.pages.dev |
| Branch Preview URL: | https://hosted-billing-notices.mouseterm.pages.dev |
dormouse-bot
approved these changes
Oct 28, 2026
…ed-billing-notices # Conflicts: # docs/specs/hosted.md # docs/specs/security-hosted.md # hosted/server/tests/billing-routes.test.ts # scripts/spec-word-budgets.json # website/src/pages/Privacy.tsx
dormouse-bot
approved these changes
Oct 29, 2026
This was referenced Oct 29, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Billing PR 4c, stacked on #1413. Billing stays closed.
dormouse_billing_noticesrow (migration018) recorded before it is sent and stamped once Postmark accepts it, at most once per renewal or dispute, from the 10-minute cron:S291). The operator adds adormouse_price_changesrow (procedure inhosted/README.md→ "Change a price"). From then on both Prices grant the plan. The cron moves a subscriber to the new Price, without proration, only once their notice went out at least 7 days before that renewal. A schema CHECK repeats that rule. A row naming a founding Price, or one Stripe's Prices contradict, gets no notices and fails the cron run.hosted.mdgains "Billing notices".pricing.mdmoves the notice gates above the fold.TERMS_VERSIONand the dates are unchanged, since they are already today's.Decisions for review: the schedule above; the 30-day renewal notice states the current price even if a price-change notice follows; no notice when a lost dispute ends a subscription; "other notices" to the account email or shown at sign-in remain a launch gate.
Legal wording for review: the five emails in
noticeMessageinhosted/server/notices.ts; the price-change and dispute paragraphs ofwebsite/src/pages/Terms.tsx; the notice records, Postmark, and retention inwebsite/src/pages/Privacy.tsx.Not verified: StripeDev models neither Price retrieval nor subscription updates, so price changes run end to end only against the test fake.
Rule IDs: takes
S291.🤖 Generated with Claude Code