Gist (Formerly Convertfox) Event Listener

Get insights into how users interact with your Gist widget and how these interactions impact your marketing funnel, conversions, website engagement and other business KPIs. Google Tag Manager and the Gist event listener make tracking this interaction in your analytics tool easy.

How to track Gist Interactions & Conversions with google tag manager

Measuring Gist (Formerly Convertfox) activity in your analytics tools such as Google Analytics, Heap, Piwik Pro, Mixpanel, Amplitude, etc. gives you valuable insights into the impact these interactions have on your marketing funnel, conversions, and other business KPIs.

To implement the Gist interaction and conversion tracking, you’ll need Google Tag Manager and the Convertflow event listener javascript code.

To begin, create a custom HTML tag where you’ll paste the event listener code and fire it on pageview or DOM ready (always recommended).

💡PRO TIP: if you installed the Gist script through Google Tag Manager, please use the DOM ready trigger instead.

What the Convertflow event listener does, is fire an event on conversion and every user interaction with Gist.

The next step in this implementation is to create a custom event with the event name of [gist_action], which gets fired on all chat activity

To get more information on what chat activity happened, you’ll need to create a dataLayer variable with the key [gistAction]

[gistAction] returns the following event description;

  • Article Viewed
  • Article Feedback Submitted
  • Article Searched
  • Chatbot Message Button Clicked
  • Welcome Message of The Chatbot Shown
  • Opened Gist Widget
  • Closed Gist Widget
  • Conversation Has Started
  • Previous Conversation Opened
  • Chat Rating Submitted
  • User Sends Message
  • User Receives Message
  • Email Address Captured
  • GDPR Consent Submitted
  • Gist Meeting Booking Requested
  • Gist Meeting Scheduled
  • In-app Chat Message Shown
  • In-app Chat Message Clicked
  • In-app Chat Message Dismissed

You can use the [gistAction] dataLayer variable as event parameters or for streamlining your trigger to fire on specific Gist interactions.

You can enrich your event data, by creating dataLayer variables in Google Tag Manager, which captures useful information about the event, some of the dataLayer variables keys are;

[gistArticleID] –> Returns article ID for article viewed and rating event 

[gistArticleURL] –> Returns the article URL for article viewed event

[gistArticleTitle] –> Returns the article title for article viewed event

[gistArticleAurthorID] –> Returns the article aurthor ID for article viewed event

[gistArticleRating] –> Returns the article rating for article feedback event

[gistSearchTerm] –> Returns search term in the article section of the chat widget

[gistSearchResultCount] –> Returns the search result count

[gistConversationID] –> Returns the conversation ID for certain chat events

[gistConversationRating] –> Returns the chat rating for chat rate submitted events

[gistMessage] –> Returns the chat message for chat message event

[gistUserEmail] –> The visitor email when capture event and GDPR consent event happens

[gistMeeting] –> Returns the meeting data in object

[gistVisitorID] –> Returns the user visitor ID when GDPR consent is given

[gistBotButtonText] –> Returns the chat bot button text

[gistBotButtonID] –> Returns the chatbot button ID

[gistAgentID] –> Returns the Operator ID for in-app message event

[gistGDPRStatus] –> Returns GDPR status

After creating the dataLayer variables, create your marketing tag/pixels, add the appropriate trigger and the event parameters you need for analysis.

Once done, debug to ensure it’s working fine, and publish once everything is okay.

Having the data in your analytics tools, such as Google Analytics, Mixpanel, Piwik Pro, Heap, Fullstory, Amplitude, etc. gives you actionable insights into your marketing and customer support strategy.

You can also use the data to understand how these chat interactions impacts conversions, website engagements, your marketing funnel and other business KPIs.

<script>
// Triggers when an article has been viewed
document.addEventListener('article:viewed', function (data) {
window.dataLayer = window.dataLayer || [];
window.dataLayer.push({
'event': 'gist_action',
'gistAction': "Article Viewed",
'gistArticleID': data.detail.articleId,
'gistArticleURL': data.detail.articleURL,
'gistArticleTitle': data.detail.articleTitle,
'gistArticleAurthorID': data.detail.authorId
});
}, false);
// Triggers when a visitor leaves a feedback on any article
document.addEventListener('article:feedback', function (data) {
window.dataLayer = window.dataLayer || [];
window.dataLayer.push({
'event': 'gist_action',
'gistAction': "Article Feedback Submitted",
'gistArticleID': data.detail.articleId,
'gistArticleRating': data.detail.rating.score
});
}, false);
// Triggers when an article has been searched
document.addEventListener('article:searched', function (data) {
window.dataLayer = window.dataLayer || [];
window.dataLayer.push({
'event': 'gist_action',
'gistAction': "Article Searched",
'gistSearchTerm': data.detail.searchTerm,
'gistSearchResultCount': data.detail.resultsCount
});
}, false);
// Triggers when a button response in a chatbot has been clicked
document.addEventListener('chatbot:buttonClicked', function (data) {
window.dataLayer = window.dataLayer || [];
window.dataLayer.push({
'event': 'gist_action',
'gistAction': "Chatbot Message Button Clicked",
'gistConversationID': data.detail.conversationId,
'gistBotButtonText': data.detail.buttonText,
'gistBotButtonID': data.detail.buttonId,
'gistBotQuestionID': data.detail.questionId,
'gistBotCreation': data.detail.createdAt
});
}, false);
// Triggers when a chat bot has been triggered
document.addEventListener('chatbot:fired', function (data) {
window.dataLayer = window.dataLayer || [];
window.dataLayer.push({
'event': 'gist_action',
'gistAction': "Welcome Message of The Chatbot Shown",
'gistConversationID': data.detail.conversationId,
'gistBotButtonText': data.detail.buttonText,
'gistBotButtonID': data.detail.buttonId,
'gistBotQuestionID': data.detail.questionId,
'gistBotCreation': data.detail.createdAt
});
}, false);
// Triggers when the Messenger has been opened
document.addEventListener('messenger:opened', function (data) {
window.dataLayer = window.dataLayer || [];
window.dataLayer.push({
'event': 'gist_action',
'gistAction': "Opened Gist Widget"
});
}, false);
// Triggers when the Messenger has been closed
document.addEventListener('messenger:closed', function (data) {
window.dataLayer = window.dataLayer || [];
window.dataLayer.push({
'event': 'gist_action',
'gistAction': "Closed Gist Widget"
});
}, false);
// Triggers when a new conversation has started
document.addEventListener('conversation:started', function (data) {
window.dataLayer = window.dataLayer || [];
window.dataLayer.push({
'event': 'gist_action',
'gistAction': "Conversation Has Started",
'gistConversationID': data.detail.conversationId
});
}, false);
// Triggers when a conversation has been opened
document.addEventListener('conversation:opened', function (data) {
window.dataLayer = window.dataLayer || [];
window.dataLayer.push({
'event': 'gist_action',
'gistAction': "Previous Conversation Opened",
'gistConversationID': data.detail.conversationId
});
}, false);
// Triggers when a satisfaction rating has been left
document.addEventListener('conversation:feedback', function (data) {
window.dataLayer = window.dataLayer || [];
window.dataLayer.push({
'event': 'gist_action',
'gistAction': "Chat Rating Submitted",
'gistConversationID': data.detail.conversationId,
'gistConversationRating': data.detail.rating
});
}, false);
// Triggers when a message has been sent
document.addEventListener('message:sent', function (data) {
window.dataLayer = window.dataLayer || [];
window.dataLayer.push({
'event': 'gist_action',
'gistAction': "User Sends Message",
'gistConversationID': data.detail.conversationId,
'gistMessage': data.detail.message
});
}, false);
// Triggers when a message has been received
document.addEventListener('message:received', function (data) {
window.dataLayer = window.dataLayer || [];
window.dataLayer.push({
'event': 'gist_action',
'gistAction': "User Receives Message",
'gistConversationID': data.detail.conversationId,
'gistMessage': data.detail.message
});
}, false);
// Triggers when an email address has been captured
document.addEventListener('email:captured', function (data) {
window.dataLayer = window.dataLayer || [];
window.dataLayer.push({
'event': 'gist_action',
'gistAction': "Email Address Captured",
'gistUserEmail': data.detail.email
});
}, false);
// Triggers when the GDPR form has been submitted
document.addEventListener('gdpr:clicked', function (data) {
window.dataLayer = window.dataLayer || [];
window.dataLayer.push({
'event': 'gist_action',
'gistAction': "GDPR Consent Submitted",
'gistUserEmail': data.detail.email,
'gistGDPRStatus': data.detail.accepted,
'gistVisitorID': data.detail.visitorId
});
}, false);
// Triggers when a meeting has been requested
document.addEventListener('meeting:requested', function (data) {
window.dataLayer = window.dataLayer || [];
window.dataLayer.push({
'event': 'gist_action',
'gistAction': "Gist Meeting Booking Requested",
'gistConversationID': data.detail.conversationId
});
}, false);
// Triggers when a meeting has been scheduled
document.addEventListener('meeting:booked', function (data) {
window.dataLayer = window.dataLayer || [];
window.dataLayer.push({
'event': 'gist_action',
'gistAction': "Gist Meeting Scheduled",
'gistMeeting': data.detail.meeting
});
}, false);
// Triggers when an in-app chat message has been sent
document.addEventListener('triggeredMessage:fired', function (data) {
window.dataLayer = window.dataLayer || [];
window.dataLayer.push({
'event': 'gist_action',
'gistAction': "In-app Chat Message Shown",
'gistConversationID': data.detail.conversationId,
'gistMessage': data.detail.message,
'gistAgentID': data.detail.assistantId
});
}, false);
// Triggers when an in-app chat message has been clicked
document.addEventListener('triggeredMessage:clicked', function (data) {
window.dataLayer = window.dataLayer || [];
window.dataLayer.push({
'event': 'gist_action',
'gistAction': "In-app Chat Message Clicked",
'gistConversationID': data.detail.conversationId,
'gistMessage': data.detail.message,
'gistAgentID': data.detail.assistantId
});
}, false);
// Triggers when an in-app chat message has been dismissed
document.addEventListener('triggeredMessage:dismissed', function (data) {
window.dataLayer = window.dataLayer || [];
window.dataLayer.push({
'event': 'gist_action',
'gistAction': "In-app Chat Message Dismissed",
'gistConversationID': data.detail.conversationId,
'gistMessage': data.detail.message,
'gistAgentID': data.detail.assistantId
});
}, false);
</script>

Video of how to use the listener

Related Event Listener

Convertflow

Seamlessly measure Convertflow users’ interactions and fire your marketing tags/pixels on conversions using this event listener.

Calendy

Track your Calendly booking funnels and interactions, using this Calendly event listener, making it possible to fire your trigger on bookings.
gravity form event listener

Gravity form

Capture your Gravity form conversions as they happen in a dataLayer format which can be used in GTM to trigger marketing tags.

download the google tag manager recipe for tracking Gist Interactions & Conversions

we make you smarter with data

made with ❤️

The DumbData Team
Before you leave, try out these free tools.
FREE GA4 AUDIT TOOL & UTM AUDIT TOOL