Add support for custom_unit_amount during product creation
What’s new
Adds the custom_unit_amount parameter to a Product ’s default_price_data parameter.
Added
custom_unit_amount object
When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links. Required unless unit_amount is provided.
Impact
This allows you to specify custom unit amounts when creating a product’s default price data. This change also benefits businesses that need specific price configurations tailored to their unique offerings.
Changes
| Parameter | Change | Resources or endpoints |
|---|---|---|
| custom_unit_amount | Added | Product#create. default_price_data |
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: 2024-09-30. acacia
- Upgrade the API version used for webhook endpoints .
- Test your integration against the new version.
- If you use Connect, test your Connect integration .
- In Workbench, perform the upgrade . You can roll back the version for 72 hours.
Learn more about Stripe API upgrades.
