Articles in this section
Category / Section

How to retrieve Subscriptions with Scheduled Changes from Chargebee data source

Published:

This article provides a step-by-step guide on how to retrieve subscriptions with scheduled changes from Chargebee and pull this data into a Bold BI report.

Step 1: Create a Chargebee Data Source

The first step is to create a Chargebee data source that lists all subscriptions with the has_scheduled_changes column set to true. This will ensure that only subscriptions with scheduled changes are retrieved. The URL format for this is as follows:

https://<site>.chargebee.com/api/v2/subscriptions?has_scheduled_changes[is]=true  

image.png

Step 2: Create a Dashboard Parameter

Next, create a dashboard parameter for the Subscription Id id(list_subscription) column. More details on how to create dashboard parameters can be found here.

image.png

Step 3: Save the Data Source

After creating the dashboard parameter, save this data source.

Step 4: Create Another Chargebee Data Source

Create another Chargebee data source for the /retrieve_with_scheduled_changes endpoint. This endpoint allows only one subscription at a time. The URL format for this is as follows:

https://{site}.chargebee.com/api/v2/subscriptions/{subscription_id}/retrieve_with_scheduled_changes 

To fetch data from all the subscriptions, replace {subscription_id} with the created dashboard parameter. The format for this is @{{:DsName.ParameterName}}, where DsName is the data source name created for the subscriptions endpoint and ParameterName is the dashboard parameter created earlier. The URL format will then look like this:

https://{site}.chargebee.com/api/v2/subscriptions/@{{:chargebee_sub_ds.subscription_id}}/retrieve_with_scheduled_changes 

Connecting to this endpoint will retrieve all the subscriptions with scheduled changes in a single table.

image.png

Additional References

Was this article useful?
Like
Dislike
Help us improve this page
Please provide feedback or comments
RM
Written by Reethika Moovendhan
Updated
Comments (0)
Please  to leave a comment
Access denied
Access denied