Creates a price ramp for an item price. Use this operation to schedule how the item price changes across a subscription's billing cycles by defining an ordered set of ramp_intervals.
Pass an overridden price for an interval using price (or price_in_decimal when multi-decimal pricing is enabled), or set apply_catalog_price to true to reuse the item price's catalog price for that interval.
Chargebee merges adjacent ramp_intervals that have the same pricing before saving. Intervals are merged when they have the same price, or when consecutive intervals have apply_catalog_price set to true. Intervals with different prices, a mix of catalog and fixed pricing, or gaps in billing cycles aren't merged.
The ramp must contain at least two intervals after merging. If the submitted intervals merge into a single interval, the request is rejected.
Prerequisites & Constraints
- Price Ramps must be enabled for the site. Contact Chargebee Support to enable them. Until they are enabled, this operation returns
API_RESTRICTED. - The
item_price_idmust not already be linked to a price ramp. An item price can have at most one price ramp.
Sample Request
Sample Result[JSON]
URL Format
Input Parameters
The ID of the item price for which the price ramp is created. The price defined by the ramp intervals overrides the catalog price of this item price for the applicable billing cycles.
The unique ID of the business entity for this price_ramp. This is applicable only when multiple business entities have been created for the site. When provided, the operation will read or write data associated with the specified business entity. If not provided, the resource will be created at the site level, and the business_entity_id will not be included in the API response.
Note: An alternative way of passing this parameter is by using a custom HTTP header or query string parameter.