Create, update, or remove a set of entitlements for a feature.
The behavior depends on the specified action. It tries to create, update, or delete entitlement objects. If any of the entitlement objects fail to process, the entire operation stops with an error, and no entitlements are processed. In essence, the request processes either all the provided entitlements or none of them.
Grandfathering in entitlements
Early Access
Grandfathering in entitlements is in early access. Write to eap@chargebee.com to get this enabled.
By default, this operation impacts all subscriptions that contain the item or item price. However, if you set apply_grandfathering to true, the existing subscriptions are not impacted by the change.
Example
Consider the following example:
On January 1st
- You have a plan price (
id:premium-monthly-usd) entitled to a feature (user_licenses) at value10. - You have a subscription (
id:AzZjAiTl1btqS2lEj) that contains the plan price (premium-monthly-usd).
On January 2nd
- Using this API operation, you change the entitlement level of the plan price
premium-monthly-usdfor theuser_licensesfeature tovalue20. You also setapply_grandfatheringtotrue. - After the API operation completes, you create a new subscription (
id:6oqNGUlMd9Yn4Ui) that contains the same plan price (premium-monthly-usd). - The existing subscription (
id:AzZjAiTl1btqS2lEj) is grandfathered in, so it continues to be entitled touser_licensesatvalue10. The new subscription (id:6oqNGUlMd9Yn4Ui) is entitled touser_licensesatvalue20.
On January 3rd
- Using this API operation, you change the entitlement level of the plan price
premium-monthly-usdfor theuser_licensesfeature tovalue30. You also setapply_grandfatheringtofalse. - After the API operation completes, you create another subscription (
id:99CRh8UgMXTq77tl) that contains the same plan price (premium-monthly-usd). - Because grandfathering was not enabled, all three subscriptions (
AzZjAiTl1btqS2lEj,6oqNGUlMd9Yn4Ui, and99CRh8UgMXTq77tl) are now entitled touser_licensesatvalue30.
Sample Request
URL Format
Input Parameters
The specific action to be performed for each entitlement
specified.
If the entitlement
already exists for the feature_id
and entity_id
combination, the value
of the entitlement
is updated. If it doesn't exist, a new entitlement
is created.
Deletes the entitlement
for the feature_id
and entity_id
combination, if it exists.