Happy Business Starts Here

Highlighted
Zuora Support

Preview subscription API using Subscription number

Question:

User need need a REST API that does a preview of an existing subscription by only passing the Subscription number as available in the UI

Solution

We do not have the direct API call available to Preview subscription by only providing Subscription key (Subscription number/Subscription ID) option but please find the below example involving two API calls

API 1: GET_SubscriptionsByKey 

Get the below information from the 1st API call by Providing only Subscription key (Subscription number/Subscription ID)

contractEffectiveDate
Accountkey
productRatePlanChargeId
productRatePlanId
termType

API  2:  POST_PreviewSubscription

The mandatory information received from the Get subscription by key API call should be used to POST the Preview subscription call

Example

Subs.jpg

Note: Multiple rate plan charge should be given inside the array

Tags (1)