Opt-in: Use for lead/signup/opt-in events where no purchase has occurred.
Sale: Use for purchase/transaction events where revenue is generated.
1. To create a webhook, go to the Settings page > Payment Processing and Carts > Chargebee

2. Enter a Webhook name, select the Funnel to associate the webhook with.
3. To set up the webhook for sales tracking, in the Integrations section, under Conversion type, select Sale (Purchase).
4. To create the webhook automatically without any manual setup, you need to enter your ChargeBee integration credentials (Site Name and API Key) in VisiOpt before clicking Save & Generate Webhook URL.
Do not click Save yet. First, obtain your API credentials as described below.
Site name - Your site name is the first part of your Chargebee URL.
For example:
Chargebee URL: https://acme-test.chargebee.com
Site Name: acme-test
Copy your Site Name and paste it into the Site Name field in Visiopt.
5. To get your API key, log in to your Chargebee account and navigate to Configure → Chargebee → API Keys.

6. If you already have a Full Access API Key with Write permissions, copy it.
7. If you don't have one, click Add API Key.

8. Configure the API key as follows:
- Access Level: Full Access
- Permissions: Write
-
Key Name: Enter any descriptive name (for example, VisiOpt API Key)
Create the API key.

9. Copy the generated API key and paste it into the API Key field in Visiopt.

10. Hit Save & Generate Webhook URL.

Visiopt will generate a webhook URL and automatically create the webhook in your ChargeBee account.
Verify the Webhook
To confirm that the webhook was created successfully:
1. Log in to your ChargeBee account.
2. Navigate to Configure Chargebee → Webhooks.
3. Look for the webhook endpoint created by Visiopt.
If you can see the VisiOpt webhook URL in the list, your integration is complete and ready to use.
Don't want to connect via API? Create webhook manually.
1. In Visiopt hit Save & Generate Webhook URL without entering the API details. Then copy the generated URL.
2. Log in to your ChargeBee account, navigate to Configure Chargebee → Webhooks. Click Add Webhook.

3. Fill in the following details:
Webhook Name: Enter any descriptive name
Webhook URL: Paste the webhook URL generated by Visiopt
Select Latest API version
Select Payment Succeeded as Events to send.
Click Create.

Your Chargebee webhook is now connected to Visiopt and ready to send events.

Verify the Webhook
Chargebee provides a Test Webhook feature that lets you verify whether your VisiOpt webhook is configured correctly.
1. After creating the webhook, locate the Visiopt webhook in your Chargebee account.
2. Click the Test Webhook button for that webhook.

Select the Payment Succeeded event. Click Test URL to send a test webhook.

If the webhook is configured correctly, Chargebee will display a Success message.
Some carts and processors will send a separate webhook notification for the main sale and each upsell purchased. This will cause multiple conversions to be recorded.
For simple instructions to stop this click HERE.
Comments
0 comments
Please sign in to leave a comment.