If you are hosting BrightTALK webinars on your own website using our HTML 5 Embed, it is possible to capture webinar conversion events (i.e. registrations and viewings) in your analytics platform using our Player Conversion Events API.
This article will provide guidance on how to capture this data in Google Analytics using Google Tag Manager.
Please Note: Web tracking varies tremendously from website to website and BrightTALK Support will not be able to provide help or guidance for your specific use case. For that, we recommend reaching out to your web developer or a certified professional.
Steps:
1) Setting up a 'Listener' in Google Tag Manager
2) Capturing the conversion using Variables
3) Passing the data to Google Analytics as Events
4) FAQs
Step 1: Setting up a Listener in Google Tag Manager
To receive the conversion data from the embedded webinar player, you can set up a "Tag" in Google Tag Manager. This can be done by creating a "Custom HTML" tag using a script like this:
<script>
(function(){
window.addEventListener("message", function(){
var receiver = JSON.parse(event.data)
var versionnumber = receiver.header.version
var domain = receiver.header.originator.domain
if(versionnumber === 2 && domain === "www.brighttalk.com") {
dataLayer.push({
'event' : 'brighttalk-activity',
'bteventtype' : receiver.body.eventType,
'bteventaction' : receiver.body.eventAction
})
}
})
})();
</script>
Note: In this example, the trigger is set to look for the events on any page on your website. This can be adjusted as needed.
Step 2: Capturing the Conversion data using Variables
As noted in the API documentation, BrightTALK provides two data points for each interaction:
eventType: Always equal to "BrightTALK Conversion"
eventAction: Will be either "Live Viewing", "On-Demand Viewing", or "Pre-Registration"
Once the Tag in step 1 is in place, you can set up "User-Defined Variables" in Google Tag Manager to capture these two values:
Step 3: Passing the Data to Google Analytics as Events
Now that you are capturing the conversion data, you can pass it to Google Analytics as an "Event". This can be done by creating a Tag with a configuration like this:
Note: We're using a generic "Event Category" here called "BrightTALK." Feel free to change that as needed.
Frequently Asked Questions
Q: Will this also allow me to track impression and conversion data on BrightTALK.com?
A: It will not. This method exclusively applies to your website.
Q: Does this only apply to specific versions of BrightTALK's Embed?
A: Any of our current HTML 5 Embeds are capable of sending these events. This includes the "Webinar or video - with interaction", "Channel - selected content featured", and "Channel - most recent content auto-featured" embeds.
Q: Does this only work with Google Tag Manager and/or Google Analytics?
A: No- any solution that can receive the window.postMessage() function documented here can potentially work. However, please note that BrightTALK will not be able to provide guidance or support on other solutions.
Q: Is it possible to receive any additional data points from BrightTALK like the name of the Webinar?
A: Yes- if you are familiar with the DOM of your website, it is possible to extract additional data points from our HTML 5 embed such as the Webinar Title, the Webinar Description, the Webcast ID, and the name of the Presenter. These can then be stored as variables and passed onto Google Analytics. Please note that this requires javascript knowledge and BrightTALK will not be able to provide support or guidance on how to do this.
Comments
0 comments
Article is closed for comments.