Scope
I would like to display the coupon values for each subscription on my website (portal). How can I fetch it?
How can I get the value of every coupon applied to a subscription?
Summary
If you are trying to fetch the coupons that are applied to a subscription, you can make use of the Retrieve Subscription API.
Alternatively, you can also make use of the Estimates API which would show the estimated amount on creation/renewal for a subscription.
Solution
Coupons applied to a subscription
To fetch the coupons that are applied to a subscription, you can make use of the Retrieve Subscription API for current subscriptions and for subscriptions that are scheduled for changes using Retrieve with scheduled changes API.
Estimate of Coupons value to a new or a subscription Change:
During the process of signing up customers to subscriptions, use the Estimates API to evaluate the details of the purchase before actually signing them up.
Below is the list of Estimate APIs to fetch Coupon details:
Sample Estimate CURL:
Response:
Related Articles