Act 1 named the structural flaw: internal models mirror Stripe's models. Act 2 describes what the platform looks like when that's no longer true. The same services, the same data, but organized around billing concepts instead of Stripe concepts. Four pillars define the destination. None are on the current roadmap directly — but every item on the current roadmap is a prerequisite for at least one.

1. Provider-Agnostic Models

Internal domain models that Stripe, PayPal, and future providers implement. A PaymentAttempt that works regardless of backend. A CollectionMethod that abstracts card tokens, billing agreements, and bank debits. The 15 Stripe packages collapse to one provider boundary with adapters.

2. Customer State

One place that knows everything about a customer's billing health — across providers, products, and time. The recompute engine already reads all 5 stores. It becomes the kernel of a unified customer state model.

3. Invoice Sovereignty

Own the invoicing cycle. Credits applied before charging. Complex proration rules. Usage-based line items. Multi-provider settlement. Invoice presentment that isn't limited to what Stripe's invoice object supports.

4. Dunning Policy Engine

The recompute engine evolves from a state reconciler into a rule engine. Segment-based escalation. Revenue-aware retry. Product-specific consequences. Provider-aware recovery. Graduated consequences replace blunt flags.

Area 1: Blind → Smart Surface

From blind references to Stripe objects → a surface that understands customer state natively. 6 new capabilities: billing history shows Resolved vs Paid, bad debt payment isolated, NinjaPanel recompute, Grafana business observability, PayPal path corrected, Unified Checkout for account setup. Account health, cross-product billing status, and self-service recovery.

Area 2: Many Paths → One Path

From 126 Stripe API calls → domain-level pricing that delegates to providers. Pay-before-commit for all subscription mutations. Single collection path. Explicit payment outcome matrix — 6 rows, every case handled. The changes_calculator speaks billing nouns. Entitlements sync simplified from Sync+Unsync to Sync only.

Area 3: Blind Handlers → Seeing Engine

From 27 blind handlers responding to individual Stripe events → one recompute function that reads all 5 stores, computes correct state, and applies the delta. 5 event types replace 196. Temporal orchestration. Events are triggers, not the logic. ~5 billing-webhooks processors removed.

MetricStartTargetDelivered By
Rollbacks / day1960PDE — payment before commit eliminates rollback entirely
Bad debt from upgrades48 / day0PDE — no orphaned charges, no uncollectible invoices
Disagreeing accounts6910Recompute engine — single computation reads all state
Invoice coverage19%100%Recompute engine + domain events — every event type covered
Dunning code paths5+1One Code Path — all dunning through the recompute engine

These capabilities require two or more initiatives to complete. The value isn't additive — it's multiplicative. Neither initiative alone is sufficient.

Segment-Based Dunning

Recompute engine provides the policy layer; PDE provides clean payment states to act on. Without PDE, the input signal is noisy. With both, dunning policy can vary by customer segment, revenue tier, and product type.

Automatic Restoration

Recompute detects drift; entitlements mapping provides a single function to re-provision. Without mapping, restoration requires per-product logic. With both, accounts self-heal when payment succeeds.

Fallback Payment Methods

Pay-before-commit enables trying a second payment method on failure; Stripe consolidation makes it safe. Without consolidation, adding a fallback touches 15 packages. With both, Stripe fails → offer PayPal automatically.

Threshold Billing

Pay-before-commit enables billing at usage thresholds, not calendar intervals. Without PDE, a threshold hit would commit before payment. Requires invoice sovereignty, PDE ordering, and the policy engine — all three pillars converge.

Credits & Adjustments

Own the invoice → apply credits before charging. Customer credit balances, promotional credits, goodwill adjustments, overpayment application. Not possible when Stripe owns the invoice lifecycle.

Provider-Aware Dunning

PayPal failures get PayPal-appropriate recovery paths. Card failures get card-appropriate retry schedules. The policy engine distinguishes provider semantics instead of treating all failures identically.

Multi-Provider Fallback

Stripe charge fails → offer PayPal. PayPal lapses → prompt for card. Requires provider-agnostic payment attempts and the consolidation boundary.

Provider Migration

Move customers between providers without domain model changes. The provider is an implementation detail behind the boundary. Adding a new payment provider means writing one adapter.

Complex Proration

Own the invoice → own proration math. Mid-cycle upgrades, downgrades, plan stacking, usage overages — all computed in domain logic, not delegated to Stripe's proration engine.

Threshold Billing

Bill at usage thresholds, not calendar intervals. All three pillars converge: invoice sovereignty for flexible billing cycles, PDE for safe commitment, and the policy engine for threshold rules.