How to Set Up Affiliate Program Postbacks to Run Automations (FirstPromoter Webhooks)
In this article, we will cover how to set up webhooks for your affiliate links so that you can run automation off sales when someone signs up using your affiliate link.
4 min read991 wordsUpdated Tue, 16 Jun at 12:57 AM
In this article, we will cover how to set up postbacks (webhooks) for your affiliate links so that you can run automation off sales when someone signs up using your affiliate link.
Update
You can now opt-in to receive email notifications for referral activity in the portal.
To do so...
- Click your profile name in the top-right of the Affiliate Dashboard.
- Open Notification Settings.
- Turn notifications on and customizeVideo 1Open in a new tabBy default, these notifications may be turned off, so it's worth checking this setting.
Turning notifications on is highly recommended. It’s the easiest way to stay informed without needing to check your portal every time something changes.
For each Postback, you will need a corresponding Workflow that starts with an Inbound Webhook trigger.
That means for every workflow, you'll need to...
Create the postback
Send a test postback
Fetch the sample request inside the workflow
Save the mapping reference
Save and publish the workflow
Without a sample payload, the workflow trigger will not save correctly.
WorkFlow
Postback name
Campaign
Trigger Name
Referral State
Purpose
1 - Lead GHL Customer Care
1- Lead (Step 1)
GHL Customer Care Affiliate Program
Lead Subscribed
Subscribed
Captures the Lead that Fills out step 1 of checkout form
2 - Trial Postback GHL Customer Care
2 - On Trial (Step 2)
GHL Customer Care Affiliate Program
New Referral
Signup
Captures when a customer completes checkout and start a trial
3 - GHL Customer Care Customer
3 - GHL Customer Care Customer
GHL Customer Care Affiliate Program
New Customer
Lead Becomes Referral
Captures when a customer makes a charge in-app (Might not be a commissionable)
4 - Paying Affiliate Commission
4 - Paying Affiliated Customer
GHL Customer Care Affiliate Program
New Commission
Reward Created
Captures when a trial ends or when the customer makes a commissionable payment
5 - Cancelled Customers
5 - Cancellation
GHL Customer Care Affiliate Program
Lead Cancelled
Lead Cancelled
Captures when a customer cancellation is triggered and subscription ends
The 5 Core Postbacks
Following along with the table above, you will set up five postbacks to correspond with the five workflows included in The Core Postback Snapshot
Lead Subscribed
New Referral (Trial Started)
First Payment Customer
New Commission
Cancelled Customer
Step 1: Lead Subscribed Postback
This triggers when someone completes the first step of the affiliate signup form but has not started a trial yet.
Create the Postback
Inside Postbacks:
Click Create Postback
Name: 1 - Lead Subscribed
Campaign: GHL Customer Care Affiliate Program
Trigger: Lead Subscribed
Connect the Workflow
Open the corresponding workflow
Copy the Webhook URL
Paste it into the Postback URL field
Send Test Data
Click Test Postback
Go back to the workflow trigger
Click Fetch Sample Request
Save the mapping reference
Save the trigger
Save the workflow
Step 2: Trial Signup / New Referral
This triggers when someone starts a trial.
Create the Postback
Name: 2 - Trial Signup
Campaign: GHL Customer Care Affiliate Program
Trigger: New Referral
Connect the Workflow
Paste the second workflow webhook URL into the Postback URL field.
Finish Setup
Click Test Postback
Fetch the sample request
Save the mapping reference
Save the workflow
Step 3: First Payment Customer
This triggers the first time a user becomes a paying customer.
This can happen when:
A trial user makes an in-app payment
A trial converts into a paid customer
Important: This trigger only fires once per customer.
Create the Postback
Name: 3 - First Payment Customer
Campaign: GHL Customer Care Affiliate Program
Trigger: New Customer
Connect the Workflow
Paste the webhook URL from the third workflow.
Finish Setup
Click Test Postback
Fetch the sample request
Save the mapping reference
Save the workflow
Step 4: New Commission
This triggers every time a commission is generated.
Unlike the previous trigger, this can happen multiple times for the same customer.
Create the Postback
Name: 4 - New Commission
Campaign: GHL Customer Care Affiliate Program
Trigger: New Commission
Connect the Workflow
Paste the webhook URL from the fourth workflow.
Finish Setup
Click Test Postback
Fetch the sample request
Save the mapping reference
Save the workflow
Tip: If you do not want contacts repeatedly re-entering workflows every time a commission occurs, disable workflow re-entry or use tagging logic instead.
Step 5: Cancelled Customer
This triggers when a customer account is cancelled.
Important
The cancellation postback fires when the account actually closes, not when the cancellation request is submitted.
Examples:
Trial users remain active until the trial ends
Paid users remain active until the billing cycle finishes
Create the Postback
Name: 5 - Cancelled Customer
Campaign: GHL Customer Care Affiliate Program
Trigger: Lead Cancelled
Connect the Workflow
Paste the webhook URL from the fifth workflow.
Finish Setup
Click Test Postback
Fetch the sample request
Save the mapping reference
Save the workflow
Publish Your Workflows
After all five workflows are configured:
Open each workflow
Click Publish
Click Save
If workflows are not published, postbacks will not trigger.
Adding a SubID
Understanding and Setting Up Sub IDs
Sub IDs are crucial for tracking the origin of your leads, sources, or trials. They help you pinpoint exactly where your traffic is coming from.
Recommendation: Since creating a unique link for every piece of content is tedious, it is recommended to create one Sub ID to use for the entire platform (e.g., Instagram) to track its overall performance.