Integrate with HubSpot for Advocate
This integration supports the following standard HubSpot objects: Deals, Companies, and Contacts.
Looking to integrate with Performance? This guide explains how to integrate with HubSpot for your Advocate program. Refer to Integrate with HubSpot for Performance-specific instructions.
impact.com can receive event data (e.g., lead form submissions) from HubSpot and track it as an action within the impact.com platform. You'll be able to identify specific event conditions that represent a conversion event, then configure a flexible mapping of data points to be sent from HubSpot to impact.com.
If you're running an Advocate referral program, you can also use HubSpot to sync data about your customer advocates between HubSpot and impact.com. After setup, HubSpot can send referral tracking, deal stage, and contact information directly to impact.com. Important Advocate program properties like referral codes, share links, and more will be visible on contact records. You can also set up a HubSpot lead capture form that sends referral data to your Advocate program.
Step 1: Connect & configure the HubSpot integration
Advocate adds special settings to your impact.com HubSpot integration. If you haven't set up the integration yet, follow our Integrate with HubSpot guide to do the following. Then, return to this guide for Advocate-specific setup steps.
- Install and connect the impact.com app in HubSpot.
- On the Settings page in the connector, make sure you toggle on Advocate Program opt-in.
- Enable event triggers.
- Configure field mappings.
- For Advocate, you must set up a few specific field mappings for the Deals object.
-
You must pass the
customerEmail
field on the conversion so it maps with your participants. - In most cases, it's not required to map fields for either the Contact or Company objects. If your specific implementation requires mappings from either of these, a custom set of mappings will be provided to you by your impact.com-assigned Implementation Engineer.
impact.com Mapping | HubSpot Mapping | Required? |
---|---|---|
EventDate | lastmodifieddate | Yes |
CustomerId | hs_object_id | Yes |
CustomerEmail | Yes | |
OrderId
This is the default field used by impact.com to differentiate between unique conversion events. However, you can select another field to use instead. |
deal_[stage]_id | Yes |
EventTypeCode
This is the default field used by impact.com to differentiate between unique conversion events. However, you can select another field to use instead. |
deal_[deal stage] | Yes |
OrderSubTotal | amount | Recommended |
Date3 | closedate | Recommended |
Text2 | hs_deal_stage_probability | Recommended |
Step 2: Configure HubSpot for Advocate
If you already have impact.com and HubSpot connected, you can reopen the connector to configure Advocate for HubSpot.
Important: HubSpot can only integrate with one Advocate program at a time. We use this program as the source of information when creating these new contact properties in HubSpot: Referral Code, Share Link, Message Links, Referred-by Code, Advocate User and Account ID, and Referral Cookie.
Manage your data sharing rules
This step takes place within the HubSpot to impact.com connector.
- Choose which data is shared between impact.com and HubSpot when a new contact or participant is created.

Action | When |
---|---|
Create contacts in HubSpot | An Advocate participant is created. An existing, unmapped participant is updated. |
Create Advocate participants in impact.com | A HubSpot contact is created. An existing, unmapped contact is updated. |
- Refer to HubSpot's documentation to learn how to customize the properties shown on records.
- There are other, non-adjustable rules for deleting and updating participant and contact records. You can return to this screen to review them, or refer to HubSpot & Advocate Data Mapping Explained for more details.
- Update the contact record layout in HubSpot to show participants' Advocate data.
- Review your selections and choose whether to sync all Advocate participant data to HubSpot after setup.
Note: The initial data sync does not transfer your HubSpot contact records to impact.com. If you’d like to import them after setting up the integration, then make sure you sync your HubSpot data.
- Select Finish.
Update your Advocate program rules
If you already have your event sharing and program set up, you can skip this step.
To reward your participants for successful referrals, you’ll need to update your Advocate program rules to trigger based on the new HubSpot event type.
For instructions on creating or editing your program rules, refer to Configure Your Advocate Program.
- In impact.com, create a program rule that triggers when a Friend performs an action.
- From the Event Keys dropdown list, select the corresponding event type created in impact.com to track your conversion.
- Update the rule criteria.
- Set up your rule actions as usual.
Step 3: Set up your rewards and participant touchpoints
When you set up your program in the onboarding checklist, you selected a reward for your customer advocate and the friends they refer. Now you'll need to finish the reward setup.
Reward the customer advocate
Your customer advocate can be rewarded with cash, a coupon code for a discount or credit, or a gift card.
- Cash payouts: Confirm that your impact.com account is adequately funded.
- Discounts and credits: Add coupon codes for your participants to redeem. You'll also need to set up the codes for redemption in your system.
- Gift cards: Fund your Tango Card account .
Reward the referred friend
Referred friends always receive a coupon code. If you didn't add coupon codes for your customer advocates, you'll need to do so now. Make sure that the codes are set up for redemption in your system.
Reversing a conversion event: Conversion events can be reversed or modified as long as the reward is still in its pending phase or hasn't been redeemed. Once a reward has been redeemed, the referral is considered locked and the reward can no longer be cancelled. Refer to Batch Modifications & Reversals Overview for more information on the process. Note that you must send through the totalPostDiscount
as 0 for the reward to be retracted.
Set up your widget
Use instant access widgets to give your customer advocates and their referred friends an easy way to interact with your Advocate program. You’ll need to:
- Set up an advocate referral widget in your program rules.
- Customize the appearance of the advocate referral widget and the friend widget.
- Integrate a small code snippet into your website or landing page.
For instructions, refer to Set Up an Instant Access Widget.
[Optional] Step 4: Register Referred Leads
- Create a new hidden field on your HubSpot form for the
impact_referredby_code
Contact Property. - Load the function below alongside your Hubspot lead form.
- This function will break down the referral cookie and ensure the referred by code is submitted along with the rest of the customer’s information to Hubspot.
- Replace
ProgramID
with your Advocate Program ID.
Note: This function requires the Universal Tracking Tag to be loaded for all transactions.
<script>
document.addEventListener("DOMContentLoaded", function() {
// Delay function to ensure HubSpot form fields are fully rendered
setTimeout(function () {
window.impactOnReady = function () {
// Retrieve the DOM element you want to auto-fill the referral code into
const elements = document.getElementsByName("impact_referredby_code");
if (elements.length > 0) {
const element = elements[0];
// Retrieve referral information from the cookie and set on element
impact.api().referralCookie()
.then(function (response) {
const referralCode = response.codes['PROGRAMID'];
if (referralCode) {
element.value = referralCode;
}
})
.catch(function (error) {
console.error("Error retrieving referral cookie:", error);
});
} else {
console.error("No element found with name 'impact_referredby_code'");
}
}
// Call the impactOnReady function
if (typeof impact !== 'undefined') {
window.impactOnReady();
} else {
console.error("Impact object not found.");
}
}, 1000) // 1-second delay to ensure HubSpot form fields are rendered
});
</script>
[Optional] Sync HubSpot data
Optionally, you can bulk import data into HubSpot to ensure your Advocate program’s participants are synced with your HubSpot leads and contacts.
- Export your contacts from HubSpot as a .CSV file.
- Adjust the .CSV file to match the accepted bulk import format.
- Make sure that the name of the email column in the import file is email. We use this field to map HubSpot contacts with Advocate participants.
- Learn more about bulk imports and download a sample CSV file.
- In your impact.com account, from the left navigation menu, select Participants.
- At the top-right corner of the page, select Import users.
- Upload the .CSV file.
- To avoid errors, check that the .CSV file you’ve prepared follows the accepted import format. Reach out to our support team if you have questions.
Testing the integration
We recommend testing the integration to ensure it’s working as intended. Testing steps will vary based on your integration setup.
Test | Purpose |
---|---|
If your sharing rules create contacts in HubSpot, then create four new Advocate participants. | Confirm that Hubspot contacts are correctly created or updated, and that Advocate properties appear in the Hubspot contact record. |
If your sharing rules create new Advocate participants in impact.com, then create four new HubSpot contacts. | Confirm that Advocate participants map to HubSpot contacts. |
In your impact.com account, manually connect referrals between two of your test participants. Don't use the same participants you use in the following Hubspot → impact.com test. | Confirm that referral tracking information is correctly shared with HubSpot. |
In HubSpot, manually connect referrals between two of your test contacts. Don't use the same contacts you use in the preceding impact.com → HubSpot test. | Confirm that referral tracking information is correctly shared with impact.com. |
Create a deal with one of the new HubSpot contacts and change its status to Closed Won .Use if you set up your program rules to perform an action when a deal’s status changes. If you used another status than Closed Won , test with that. | Confirm that program rules trigger correctly when a deal’s status changes. |
Learn more
Updated 18 days ago
Finally, test your integration to make sure that participants are being correctly registered in impact.com and rewarded for successful referrals.