How to Connect Your Chargebee Account
After you register for a Churnkey account, you can connect it to your Chargebee account on our Settings | Billing Provider page. You can enter both live and test credentials. The test credentials are optional, but great to add if you want to test your cancel flow in a staging environment before going live with Churnkey.
Step 1. Generate an API Key
Your API key is used to apply pauses, discounts, and cancellations to customer subscriptions on your behalf. Read all about how we use the API key below.
- Log-in to your Chargebee account
- Navigate to Settings - Configure Chargebee - API Keys
- Click “+ Add API Key”
- Select Full-Access Key
- Select Write Key
- Choose a name for your new API Key
Step 2. Add Webhook Notifications
In order for Churnkey to track reactivation rates (after pauses and discounts), and keep track of total boosted revenue from your cancel flow, you need to add a webhook in your Chargebee account.
- Navigate to Settings - Configure Chargebee - Webhooks
- Click “+Add Webhook”
- Create a name for the webhook
- Set the webhook URL to
YOUR_CHURNKEY_APP_ID(please note to replace
YOUR_CHURNKEY_APP_IDwith your App ID - your account specific URL can be found on your Churnkey settings page)
Step 3. Add API Credentials to Churnkey
The API credentials (site name, API key) can be linked to your Churnkey account on the Billing Provider Settings page:
How is the Chargebee connection used?
I. Add discounts to your cancel flow
40_off_2_monthsin Chargebee live mode, this coupon will also need to exist in your Chargebee test account to use in Churnkey’s test mode.
After you connect Chargebee (live mode), you’ll be able to offer your customers temporary discounts as part of your cancel flow. Please note that you will only see your Stripe coupons after you’ve connected your live Chargebee account. We only pull in coupons from the live account, not your Stripe test account.
- In the “Offers” tab of the flow builder, choose “Apply Chargebee Coupon”
- Choose the coupon you’d like to offer customers in the dropdown labeled “Chargebee Coupon”
II. Personalize cancel flows with customer attributes and segmentation
Use customer segmentation to reduce voluntary churn with targeted cancel flows. With segmentation, you can target specific customers based on subscription attributes and serve up unique cancel flows for each of them. After all, someone who signed up yesterday should be spoken to differently from a customer who’s been a paying subscriber for years.
Available attributes for segmentation
- Subscription age
- Subscription creation date
- Billing interval (weekly, monthly, annual, etc)
- Trial vs Active subscription
III. Updating customer subscriptions on your behalf
When a customer goes through your cancel flow and (hopefully) accepts a pause or discount offer, Churnkey takes care of the billing updates for you.
Churnkey is able to perform the following actions on your behalf
1. Pause a subscription 2. Apply a discount 3. Cancel a subscription
We'll look at each one of these in a little bit more detail.
Churnkey uses Chargebee's built-in pause feature which will update the subscription's
resumes_at field will automatically be set by Churnkey depending on the length of the pause selected.
You can specify the maximum pause length allowed by customers while configuring your offboarding flow.
When a customer chooses to temporarily pause their account, if a subscription ID was provided when initializing the Churnkey embed, the subscription under that ID will be canceled. If just a customer ID is provided, each active subscription will be paused.
If you would like to implement a custom function for handling pause events, you can do so using the
handlePause callback (see Custom Callbacks).
Apply a Discount
In the Churnkey offer builder, you can offer specific discounts to customers. These discounts are populated based on the coupons that you have created in your Chargebee account.
When a customer accepts a discount, if a subscription ID was provided when initializing the Churnkey embed, the coupon will be applied to that subscription. If just a customer ID is provided, that coupon is applied directly to the Chargebee customer account.
If you would like to implement a customer function for applying discounts, you can do so using the
handleDiscount callback (see Custom Callbacks).
Churnkey can handle canceling your customer's subscription for you. By default, a customer's subscription will be set to cancel at the end of the current period, but this behavior can be modified to cancel a user's subscription immediately.
When a customer chooses to cancel their account, if a subscription ID was provided when initializing the Churnkey embed, the subscription under that ID will be canceled. If just a customer ID is provided, each active, delinquent, and past due subscription will be canceled.
Under the hood, Churnkey follows Chargebee's best practices on canceling.
If you would like to implement a customer function for canceling subscriptions, you can do so using the
handleCancel callback (see Custom Callbacks).
IV. Calculating boosted revenue
Once you’ve connected your Chargebee account, you’ll be able to track customer reactivations and boosted revenue - that’s all the extra revenue you receive from customers who stayed on instead of canceling.
You can track boosted revenue on your Churnkey dashboard.
On this page
- How to Connect Your Chargebee Account
- Step 1. Generate an API Key
- Step 2. Add Webhook Notifications
- Step 3. Add API Credentials to Churnkey
- How is the Chargebee connection used?
- I. Add discounts to your cancel flow
- II. Personalize cancel flows with customer attributes and segmentation
- III. Updating customer subscriptions on your behalf
- Pause Subscription
- Apply a Discount
- Cancel Subscription
- IV. Calculating boosted revenue