Skip to content

feat(billing): add sponsored organization paid continuation - #10784

Draft
mzxchandra wants to merge 1 commit into
codex/grants-s3-sponsored-accessfrom
codex/grants-s4-paid-continuation
Draft

mzxchandra wants to merge 1 commit into
codex/grants-s3-sponsored-accessfrom
codex/grants-s4-paid-continuation

Conversation

@mzxchandra

Copy link
Copy Markdown
Contributor

Summary

Sponsored organization owners can explicitly opt into paid Team billing with a payment method and confirmed plan/seat terms. Early opt-in schedules billing after sponsorship; late opt-in starts normally without backcharging the sponsored period. Usage credits continue to cover usage only.

Adds quote, setup, consent, status, cancellation and payment-recovery operations. Existing outbox delivery reconciles exact Stripe objects and receipts; initial paid access requires the matching paid invoice, not provider subscription status alone. Sponsorship extensions coordinate with pending paid starts and refuse paid/processing boundaries. Personal Pro subscriptions and workspaces remain separate.

Stack and storage

Stacks on #10783. Additive migration 0494 creates one sponsorship_paid_continuation record per sponsorship, with immutable consent/quote and provider receipts. The sponsorship FK restricts deletion; retained organization identity allows explicit reconciliation if its live org disappears. Existing outbox and audit_log are reused. No credit wallet pays subscription charges and no general collection pause/resume control is added.

Testing

  • 20 focused real-PostgreSQL cases passed: 7 paid-continuation and 13 sponsorship lifecycle cases, using a deterministic Stripe peer.
  • SDK-typed partial fixtures and signed webhook fixture parsing pass current TypeScript.
  • Affected-workspace types, generators, operation/route audits and migration safety/schema-drift checks passed.
  • Earlier real Stripe sandbox proofs cover card-free scheduling, extension/cancel, late start, decline/SCA and exact invoice recovery; these are historical provider evidence, not a new sandbox run for this PR publication.
  • Hosted full checks dispatched against the parent SHA. Deployed staging remains NOT RUN; retain personal payer state and verify early/late paid start, exact receipts, payment recovery and extension behavior before rollout.

Boundaries

Stripe does not provide an atomic read-and-cancel collection boundary. The operation refuses paid/processing states and confirms extension only after the old start is noncollectible; observed races require explicit reconciliation. Unknown create responses beyond the provider idempotency window refuse automatic recreation. Recipient product UI remains the separate S5 follow-up.

Type of Change

  • New feature

@vercel

vercel Bot commented Dec 5, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

1 Skipped Deployment
Project Deployment Actions Updated
docs Skipped Skipped Dec 5, 2026 8:59am UTC

Request Review

This branch was previously deployed

1 inactive deployment
Preview — 68fc2a46 Deployed Dec 5, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant