Adds subscription metadata support to invoice previews
What’s new
Adds the ability to pass subscription_details.metadata when creating invoice previews. This lets you include subscription metadata as part of a preview request, whether you’re previewing a new subscription creation or an update to an existing subscription that sets or changes metadata on the subscription.
Impact
If your integration previews invoices before creating or updating subscriptions that include metadata, you can now pass that metadata in the preview request to get an accurate preview of the resulting invoice.
Changes
| Parameter | Change | Resources or endpoints |
|---|---|---|
| metadata | Added | Invoice#create_preview. subscription_details |
Upgrade
- View your current API version in Workbench.
- If you use an SDK, upgrade to the corresponding SDK version for this API version.
- If you don’t use an SDK, update your API requests to include Stripe-Version: 2026-07-29. dahlia
- Upgrade the API version used for webhook endpoints .
- Test your integration against the new version.
- If you use Connect, test your Connect integration .
Learn more about Stripe API upgrades.