OneShot

All packsSaaS Billing + Tax CoreSolve

stripe current_period_end subscription item api change

current_period_end moved off the subscription object

Since Stripe API 2025-03-31.basil, current_period_end lives on the subscription item, not the subscription -- the pack pins where to read it (D7).

3 of 3 runs passedOne decision inside SaaS Billing + Tax Core (nextjs-prisma-postgres).

What goes wrong

Since Stripe's 2025-03-31.basil API version, current_period_start and current_period_end moved off the subscription object and onto its line items. Code that still reads subscription.current_period_end gets undefined on any account created against a current API version -- billing-cycle countdowns, renewal-date displays, and access windows silently break.

Why agents get it wrong

Cached training knowledge and a lot of still-indexed tutorial code predate the move, and the subscription object doesn't error when you read a field that no longer exists there -- it just returns undefined, so the bug surfaces as a wrong or missing date on a screen, not a stack trace an agent has to explain.

What SaaS Billing + Tax Core pre-decides

ARCHITECTURE.md D7 states the fix as a one-line rule and names the failure mode directly: read sub.items.data[0].current_period_end. It calls this out as "the #1 agent error on modern Stripe APIs" -- every date the pack's webhook handlers and /billing page render already comes from the item, not the subscription.

Source: ARCHITECTURE.md D7

Coming soon — $149Full receipt and details for SaaS Billing + Tax Core

Related problems