Developer Guide
Integrations
Stripe
How to Connect Stripe and Churnkey
After you register for a Churnkey account, you can connect it to your Stripe account on our Settings | Billing Provider page.
Once your account has been successfully connected, you should see something like this:
How is the Stripe connection used?
I. Add discounts to your cancel flow
40_off_2_months
in Stripe live mode, this coupon will also need to exist in your Stripe test account to use in Churnkey’s test mode. After you connect Stripe (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 Stripe 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 Stripe Coupon”
- Choose the coupon you’d like to offer customers in the dropdown labeled “Stripe 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
- Plan
- Price
- Subscription age
- Subscription creation date
- Billing interval (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.
Pause Subscription
Churnkey uses Stripe's built-in pause feature which will update the subscription's pause_collection[behavior]
to mark_uncollectible
. The 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 Stripe 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 Stripe 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).
Cancel Subscription
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 Stripe'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 Stripe 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
- Stripe
- How to Connect Stripe and Churnkey
- How is the Stripe 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