Skip to main content

3.3) Webhook Attribution (Optional)

How to setup attribution through webhook submissions

Updated over 2 weeks ago

Video Transcript

Alright guys, so now we are going to get into this concept of webhook attribution. Now, before watching this guys, I implore you, if you haven't already seen the pixel attribution videos part one and part two, please go back and watch those. Those are essential to making sure that you have crisp, clean tracking and attribution, and most of the time you will rely on that. However, this is going to be more for the advanced user that understands what webhooks are, that understands how to pass data through a webhook, and wants to set up attribution from the webhook directly for whatever use case.

So, to talk about webhook versus pixel attribution real quick, again, the pixel attribution, which is going to be on this side, the pixel attribution simply works because you put a pixel on a website, right? If you remember watching that video, you put our pixel at the top of your website which is basically just code, and then our pixel can now track a bunch of stuff, meaning we can track the first page view, right? Then we can track the second, the third, we can track the fourth. And let's say this is a landing page, right? And then on the landing page, they submit a form, and then they go to a booking page, booking page. On the landing page where they submit the form, we can now track the user via phone and email, right? We can track them again via phone and email through our pixel that is added onto your website. And then we can track every page they view, where they viewed it, where they're coming from, and all this really rich data. So that is our pixel.

If however, you're not going to set up our pixel, now we're going to get into the concept of webhook tracking which comes from our conversion setup. So inside of our platform, you guys will see there's this button here called Conversion Setup. And when you go to conversion setup, you literally see some pre-built conversions. You can add a custom conversion. Again, we have an entire training curriculum on this for conversion tracking setup. So please go watch that to familiarize yourself with the conversion setup if you haven't already. But when you are going to set up a conversion, you then have what's called a conversion source. So we can add a webhook, we can say this is a GHL Form Submitted for whatever reason. Let's say we want to just use GHL attribution and we don't want to add a pixel, we only want to use GoHighLevel. We then come here, we set up the webhook, we copy this, we paste it inside of GoHighLevel. Again, we have a training video that is going to be the conversion tracking setup training, so please go check that out for a full tutorial on how to do this. But once we add this URL and trigger it, we are going to see something like this.

We are going to see a pop-up appear with all of the data that came from the original GoHighLevel webhook, and then we have all the different stuff that we want inside of here, right? So inside of here, we are going to obviously want to track the name, the email, right? The user, to track the lead's page view history and link their activity to conversions. And their phone number. So again, this is core because this is our contact resolution with name and email, or with phone, email, and phone. We can go ahead and we can track the user across our platform and everything that they've ever done and put together a timeline and a storyboard for them. But we are obviously going to need, you know, the email, the phone, go ahead and add the name. If this is revenue, again, that's another video, I'm actually not going to talk about that here, but we are going to have a section called attribution. Now inside of attribution, we can go ahead and we can start adding the actual attribution. So if I just search for source here and we see the source is going to be, cool, last attribution source... no, uh... let's go... cool, last attribution source, so it's going to show anything in here, social media. Perfect. We'll just kind of leave it as social media for now. It's not that really important. Coming from Facebook or Google, we can find that it's from Facebook or Google anyway. Then we're going to go for campaign, right? So here is going to be the name of the campaign. Then we're going to go for medium, which is going to be this one. Then we're going to go for ad, or I think GoHighLevel calls it content in their webhook. Uh, so this is now going to be the content.

And then the most important thing guys, is going to be the content ID. So let me see if I have content_id, utm_id. Uh, let's see what we have. I just want to see if we track this. Give me a second here. Okay, so it wasn't tracked. If you guys can get an ad ID, this is going to be the best and I'll just quickly explain how this works for any of the more technical users. When you send us this data in, when you connect your ad platform, let's say it's Facebook, we can then track the ad name against your Facebook. So we're going to get an ad name, we're then going to go into your Facebook, we're going to see, can we find a matching ad name. If we do find a matching ad name which in this case was 1007C implementing AI... 30k a month with AI. If we find a matching ad in your Facebook ads manager, then we will take the ad name, we can then go and we can find the ad set name and ID, and then the campaign name and ID. So it allows us to track everything perfectly by name and by ID. And again, ad ID is going to be your most accurate. If you can't get it, don't worry, give us the UTM ad, just make it a habit that once you publish the ad, you don't change the name because if you change the name, Facebook is still going to send us the old name that was first published. So that is one caveat. But then guys, once you have this in the correct spot, you would hit save. And now every time the webhook fires for this conversion, we would not only get the conversion event, who this person was, we would also attach attribution to this contact and we can now see he came from this ad, from this ad set, from this campaign, and from this source. So yeah guys, I hope that makes sense. If you have any questions, please feel free to reach out, but this is how you set up webhook attribution by basically attaching the attribution to the conversion via the webhook. Again if you have any questions please feel free to reach out to us and if not, then feel free to continue watching and go set up your conversions tracking.


Introduction

Welcome to the guide on setting up Webhook Attribution. This is an alternative and more advanced method for tracking conversions that works without relying solely on the page view pixel. It is especially useful when using iFrame or embedded forms where the pixel cannot directly access form data. This process involves sending conversion data from an external platform (like a CRM or form builder) directly to AgentKong.

Step 1: Navigate to Conversion Setup

All webhook attribution is managed within the Conversion Setup tab. Here, you will define the conversion events you want to track (e.g., "Lead," "Appointment Booked") and connect them to data sources.

  1. Inside your business, navigate to Ad Tracking > Conversion Setup.

  2. You will see a list of default conversion events. Click Edit on the event you wish to configure, such as "Lead."

Step 2: Create a New Webhook Source

For each conversion event, you'll create a source that will listen for incoming data from your external platform.

  1. In the "Edit Conversion" window, click + Add Source.

  2. Select Webhook as the integration type.

  3. Give your webhook a descriptive name (e.g., "GHL - Form Submitted") to identify where the data is coming from.

  4. Click Submit.

Step 3: Test the Webhook and Map Your Data Fields

This is the most critical step. You will send a test event from your external platform to AgentKong so you can map the incoming data fields correctly.

  1. After creating the source, click Setup Webhook. A new window will appear with a unique Webhook URL.

  2. Copy the Webhook URL.

  3. Configure Your External Platform: Go to your external tool (e.g., GoHighLevel, Zapier, Typeform) and paste this URL as the destination for your form submission or automation webhook.

  4. Listen for Events: Back in AgentKong, click Start Listening for Events.

  5. Trigger a Test Event: Submit a test form from your external platform. Make sure the form submission includes attribution data (e.g., UTM source, campaign, ad name).

  6. Map the Fields: Once AgentKong receives the test data, you can map the fields. Drag the incoming data fields from the left (e.g., originalPayload.contact.lastAttributionSource.source) to the corresponding tracking fields on the right (e.g., UTM Source). Be sure to map:

    • Contact Information: Name, Email, and Phone are crucial for identifying the user.

    • Attribution Data: Map all available UTM parameters (Source, Campaign, Medium, Ad) to link the conversion back to your ads.

  7. Click Save Mappings.

Your webhook attribution is now configured. Every time a new conversion event is sent to this URL from your platform, AgentKong will automatically capture and attribute it.

Did this answer your question?