Skip to main content
Chargebee needs more hands-on setup than Stripe or Paddle: you create the custom field and the webhook yourself, in your Chargebee dashboard. There are three parts, and all three are required:
  1. Create a custom field in Chargebee to carry the partner key on the customer record.
  2. Authorize Chargebee so Partnero receives the payments your customers make.
  3. Add referral tracking to your site so the partner key reaches Chargebee in the first place.
Your program’s own integration guide, with your program ID and webhook credentials already filled in, lives in the app under Integration → Guides → Chargebee. It is the source of truth for the values below.

Step 1: Create the custom field in Chargebee

Do this before authorizing — Partnero checks that the field exists and will refuse to connect without it. In Chargebee, go to Settings → Configure Chargebee → Custom Fields and add a Customer custom field of type Single Line Text: The API name must match exactly. Copy it from the in-app instructions rather than retyping it.

Step 2: Authorize Chargebee

  1. In Partnero, go to Integration and scroll to Apps & Integrations.
  2. Click Authorize next to Chargebee.
  3. Enter your API key, from Chargebee under Settings → API Keys.
  4. Enter your site name — the subdomain of your Chargebee URL, so your-site-name from your-site-name.chargebee.com.
  5. In Chargebee, go to Settings → Configure Chargebee → API Keys and Webhooks and add a webhook using the endpoint, credentials and event list shown in the Partnero integration window.
Unlike Stripe and Paddle, Chargebee webhooks are not created for you. If you skip the webhook, Partnero never hears about the payments and no commission is generated.

Step 3: Add referral tracking to your site

This is what tells Partnero which partner referred a customer. Without it, Chargebee sends Partnero payments it cannot attribute to anyone.

Install the tracking script

This snippet identifies visitors arriving through a partner’s referral link and stores the partner key in a first-party cookie. Copy your own snippet from the app — don’t retype the one below. It is generated per program and already contains your program ID:
  1. Open the program and go to Integration.
  2. Copy the PartneroJS snippet shown there. It also appears inside every guide on the Guides tab.
Paste it before the closing </head> tag on every page a referred visitor might land on — ideally site-wide. For reference, the snippet looks like this, where YOUR_PROGRAM_ID is filled in for you:

Pass the partner key into Chargebee

Use this if customers check out through Chargebee Hosted Pages.This script finds links to your Chargebee hosted checkout and appends the partner key as the custom field, so Chargebee stores it on the customer it creates. Place it on every page containing hosted checkout links, at the bottom of the page directly above the closing </body> tag.
In a refer-a-friend program change COOKIE to partnero_referral and FIELD to customer[cf_partnero_referral].
Statistics only appear in Partnero after a referred customer completes their first purchase.

What gets tracked

Once all three steps are done, Partnero records successful payments and transactions made by your referred customers, and reverses the commission automatically when a payment is refunded or a transaction is deleted.

Troubleshooting

The custom field is missing or its API name does not match. Partnero validates cf_partnero_partner (or cf_partnero_referral for refer-a-friend) before connecting. Check it is a Customer field, not a subscription or invoice field.
Check the webhook. Chargebee webhooks are created by you, not by Partnero, so confirm the endpoint and credentials in Chargebee match the ones in the Partnero integration window and that the listed events are selected. Chargebee’s own webhook logs will show whether delivery is failing.
The custom field is empty on that customer. Open the customer in Chargebee and check cf_partnero_partner holds a partner key. If it is blank, the tracking script did not reach the hosted page link — usually because the script sits above the link markup, or the visitor had no partnero_partner cookie.

Next steps

Commissions

Set up recurring commissions

Transactions API

Record transactions yourself