Skip to content
revenue-sdk
Esc
↑↓navigate↵open⌘Jpreview

Changelog

v0.5.0

November 29, 2026

Release

0.5.0 (2026-11-29)

⚠ BREAKING CHANGES

  • RevenueCapabilities has a new required key checkoutTrial. A custom provider does not compile until it adds it.

Features

  • let a checkout skip the trial of its product (#22) (bd95ae2)
v0.4.0

November 29, 2026

Release

0.4.0 (2026-11-29)

⚠ BREAKING CHANGES

  • polar: RevenueProvider has a new required method changeSubscriptionQuantity, and RevenueCapabilities has a new required key subscriptionQuantity. A custom provider does not compile until it adds both. On Polar a checkout item quantity is now always sent, also quantity: 1. Pass it only for a product with a unit price, because Polar refuses it for any other product and the call fails with validation. On Polar a checkout whose items have different quantities now throws unsupported. On Polar subscriptions.changePlan now throws unsupported for every quantity, also quantity: 1. Change the quantity with subscriptions.changeQuantity. A Polar price with a unit price now reports Price.model: 'tiered' instead of 'custom'.

Features

  • polar: support quantities on subscriptions (5b0e91a)
v0.3.0

November 24, 2026

Release

0.3.0 (2026-11-24)

⚠ BREAKING CHANGES

  • usage.report takes { events: UsageEvent[] } in place of the fields of one event. Custom providers must add the usageBatchReporting capability and read params.events in reportUsage.

Features

  • take a list of events in usage.report (#16) (5e853ef)
v0.2.0

August 8, 2026

Release

0.2.0 (2026-08-08)

⚠ BREAKING CHANGES

  • types: WebhookEvent payload fields require narrowing on event.type; un-narrowed access no longer compiles.
  • the provider response body moved from RevenueError.cause to a non-enumerable RevenueError.responseBody; cause now carries only the underlying JS error. Non-enumerability hides the body from console.error, util.inspect, JSON.stringify and Sentry, while error.responseBody remains a deliberate read. It is not redacted: the content is customer PII, which a secrets list cannot enumerate.

Features

  • add customers.create and customers.update (9ae21ae)
  • add license keys (#5) (5b8bb65)
  • add pay-what-you-want checkouts and a customerMetadata capability (6e57384)
  • add subscription pause and resume (#2) (775d549)
  • add the orders resource (#6) (580cdeb)
  • add usage-based billing (#4) (b77bf17)
  • add webhook event granularity, dedupe keys and checkout expiry (d675cfa)
  • support custom provider adapters (4c37444)
  • testing: add signWebhook for webhook handler tests (c4603c8)

Bug Fixes

  • client: retry rate limits without Retry-After and honor aborts (a17348f)
  • dodo-payments: redact the license key from error messages (e2992da)
  • http: preserve baseUrl path prefixes (cbe1316)
  • lemon-squeezy: dedupe first-payment webhooks, filter drafts, guard endTrial (41d6743)
  • polar: map license activation-limit 403 to validation, redact the key (9d8b8f7)
  • stripe: refuse plan changes when the subscription has no items (b0b1873)

Code Refactoring

  • types: model WebhookEvent as a discriminated union (0af4d12)
v0.1.0

August 6, 2026

Release

0.1.0 (2026-08-06)

Features

  • client: add createClient with validation, capability gating, retry, and listAll (0753090)
  • core: add normalized types, http client, pagination, and webhook primitives (1e2074c)
  • dodo-payments: add Dodo Payments provider with checkout sessions and webhook verification (0e7cda3)
  • lemon-squeezy: add Lemon Squeezy provider with webhook verification and event parsing (d7baec6)
  • paddle: add Paddle provider with transaction checkouts and webhook verification (11d4a3e)
  • polar: add Polar provider with webhook verification and event parsing (f4d24c2)
  • stripe: add Stripe provider with form encoder and webhook verification (0095081)
  • testing: add in-memory provider on the testing subpath (9a2f45c)

Bug Fixes

  • build: add unrun dev dependency required by tsdown config loading (c9af08e)