Difference between revisions of "ATC/Current/AdminGuide/Tracking snippet"

From Genesys Documentation
Jump to: navigation, search
m (Text replacement - "https://help.mypurecloud.com/articles/altocloud-permissions-overview" to "https://help.mypurecloud.com/articles/?p=195191")
m (Text replacement - "Genesys Cloud" to "Genesys Cloud CX")
 
(13 intermediate revisions by 2 users not shown)
Line 1: Line 1:
 
{{Article
 
{{Article
 
|Standalone=No
 
|Standalone=No
|DisplayName=Tracking snippet
+
|DisplayName=Predictive Engagement tracking snippet
 
|TocName=Tracking snippet
 
|TocName=Tracking snippet
|Context=Learn how to enable visitor tracking on your website.
+
|Context=Learn about Genesys Predictive Engagement's tracking abilities and how you can start tracking visitors on your website.
 
|ComingSoon=No
 
|ComingSoon=No
 
|Platform=PureConnect, GenesysCloud, GenesysEngage-cloud
 
|Platform=PureConnect, GenesysCloud, GenesysEngage-cloud
 
|Prereq='''Prerequisites'''
 
|Prereq='''Prerequisites'''
  
*[https://help.mypurecloud.com/articles/?p=195191 Configure the following permissions in Genesys Cloud:]
+
*[https://help.mypurecloud.com/articles/?p=195191 Configure the following permissions in Genesys Cloud CX:]
 
**'''Journey '''>''' Settings''' > '''Edit''', or '''View'''
 
**'''Journey '''>''' Settings''' > '''Edit''', or '''View'''
 
|Section={{Section
 
|Section={{Section
|sectionHeading=Overview
+
|alignment=Vertical
|anchor=Deploy
+
|structuredtext={{NoteFormat|This article only applies to customers using {{Link-SomewhereInThisVersion|manual=AdminGuide|topic=About_web_chats|display text=web chat}}. If you are a Genesys Cloud CX customer, we encourage you to use the new {{Link-AnywhereElse|product=ATC|version=Current|manual=AdminGuide|topic=About_web_messaging|display text=web messaging}} feature to replace web chat.|}}
|alignment=Horizontal
 
|Media=Image
 
|image=SnippetProcess.png
 
|structuredtext=#Review {{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Tracking_snippet|anchor=BeforeYouBegin|display text=Before you begin}}.
 
#{{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Tracking_snippet#GetSnippet|display text=Copy the snippet.}}
 
#{{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Tracking_snippet#Customize|display text=Optionally customize the snippet.}}
 
#{{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Tracking_snippet|anchor=DeploySnippet|display text=Deploy the snippet.}}
 
#{{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Tracking_snippet#VerifySnippet|display text=Verify that the snippet works.}}
 
#{{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Web_tracking|display text=Configure web tracking.}}
 
{{NoteFormat|See a solutions article that includes the tracking snippet: {{#mintydocs_link:topic=Solution/ChatSolutions|standalone}}|2}}
 
 
|Status=No
 
|Status=No
 
}}{{Section
 
}}{{Section
|sectionHeading=Before you begin
+
|sectionHeading=About the tracking snippets
|anchor=BeforeYouBegin
+
|anchor=AboutSnippets
 
|alignment=Vertical
 
|alignment=Vertical
|structuredtext=Before you deploy the {{MINTYDOCSPRODUCT}} tracking snippet be sure you understand:
+
|structuredtext=Customers who want to use web chat must deploy the Predictive Engagement tracking snippet. This snippet deploys Predictive Engagement tracking on your website and also allows you to use the {{Link-SomewhereInThisVersion|manual=AdminGuide|topic=About_web_chats|display text=web chat}} feature.
  
*{{Link-SomewhereInThisVersion|manual=AdminGuide|topic=About_tracking|display text=All about tracking with {{MINTYDOCSPRODUCT}}}}.
+
Genesys Cloud CX customers who want to use web messaging must deploy the {{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Messenger_configuration|display text=Messenger snippet}}. This snippet deploys Predictive Engagement tracking on your website and also allows you to use the {{Link-SomewhereInThisVersion|manual=AdminGuide|topic=About_web_messaging|display text=web messaging}} feature.{{NoteFormat|This article provides instructions for deploying the Predictive Engagement tracking snippet only.|}}
*How to deploy the tracking snippet to be compliant with {{Link-SomewhereInThisVersion|manual=AdminGuide|topic=GDPR}}.
 
*The effect of {{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Tracking_snippet|anchor=AdBlockers|display text=ad blockers}} on {{MINTYDOCSPRODUCT}}.
 
*How to {{Link-Standalone|topic=ATC/GPEandWidgets|display text=prepare widgets for use with {{MINTYDOCSPRODUCT}}}}.
 
 
|Status=No
 
|Status=No
 
}}{{Section
 
}}{{Section
|sectionHeading=Ad blockers
+
|sectionHeading=Before you begin
|anchor=AdBlockers
+
|anchor=BeforeYouBegin
 
|alignment=Vertical
 
|alignment=Vertical
|structuredtext=Ad blockers are plug-ins or browser extensions that improve page load times and minimize questionable tracking. The majority of ad blockers tested with out-of-the-box settings do not interfere with {{MINTYDOCSPRODUCT}}'s tracking capabilities. However, there are a couple considerations if you use uBlock Origin: 
+
|structuredtext=Read about the type of data that Genesys Predictive Engagement tracks and how to ensure that you track visitor data in a regulatory-compliant manner. Understand the implications of using ad blocking software. Finally, learn how the tracking snippet works and the types of tracking snippets available.
  
*uBlock Origin disables {{MINTYDOCSPRODUCT}}'s tracking web beacons; this effectively prevents {{MINTYDOCSPRODUCT}}'s tracking capabilities.
+
*{{Link-AnywhereElse|product=ATC|version=Current|manual=AdminGuide|topic=About_data_tracking}}
*uBlock Origin and uBlock Plus Adblocker block popular tag managers such as Adobe Tag Manager, Google Tag Manager, and more.
+
*{{Link-SomewhereInThisVersion|manual=AdminGuide|topic=GDPR|display text=Predictive Engagement and GDPR}}
 
+
*{{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Tracking_snippet|anchor=AdBlockers|display text=Ad blockers}}
{{NoteFormat|If you use a tag manager to manage JavaScript and tracking on your website, consider adding ad blocker detection to your site in order to notify your users with detected ad blockers that they may be missing some important functionality.
+
*{{Link-SomewhereInThisVersion|manual=SDK|topic=About_the_tracking_snippet}}
 
+
**{{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Tracking_snippet|anchor=TypesofSnippets|display text=Types of snippets}}
Also, instead of using tag a manager to deploy the {{MINTYDOCSPRODUCT}} tracking snippet, consider manually placing the tracking snippet directly in the body or header of your website.|}}
+
**{{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Tracking_snippet|anchor=SnippetRecs|display text=Snippet recommendations}}
 +
*{{Link-Standalone|topic=ATC/GPEandWidgets|display text={{MINTYDOCSPRODUCT}} and widgets}}
 +
*{{Link-AnywhereElse|product=ATC|version=Current|manual=AdminGuide|topic=Tracking_snippet|anchor=Deploy|display text=Deployment overview}}
 
|Status=No
 
|Status=No
 
}}{{Section
 
}}{{Section
Line 54: Line 43:
 
|Media=Image
 
|Media=Image
 
|image=TrackingSnippet.png
 
|image=TrackingSnippet.png
|structuredtext={{MINTYDOCSPRODUCT}} provides a tracking snippet that you can copy and paste. Since you are logged in to Genesys Cloud, the tracking snippet already contains your organization ID and region.
+
|structuredtext={{MINTYDOCSPRODUCT}} provides a tracking snippet that you can copy and paste. Since you are logged in to Genesys Cloud CX, the tracking snippet already contains your organization ID and region.
  
#Determine which snippet to use:
+
#Determine {{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Tracking_snippet#TypesofSnippets|display text=which snippet}} to use.
#*{{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Tracking_snippet#TypesofSnippets|display text=Types of snippets.}}
+
#In Admin in Genesys Cloud CX, open the '''Global Settings''' page and then click the '''Tracking Snippet''' tab.
#*{{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Tracking_snippet|anchor=SnippetRecs|display text=Snippet recommendations.}}
 
#In Admin in Genesys Cloud, open the '''Tracking Snippet''' page.  
 
 
#Copy the tracking snippet.
 
#Copy the tracking snippet.
 
#Paste the snippet. For more information about where to paste the snippet, see {{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Tracking_snippet|anchor=DeploySnippet|display text=Deploy the snippet}}. <br />
 
#Paste the snippet. For more information about where to paste the snippet, see {{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Tracking_snippet|anchor=DeploySnippet|display text=Deploy the snippet}}. <br />
 
|Status=No
 
|Status=No
 
}}{{Section
 
}}{{Section
|sectionHeading=Types of tracking snippets
+
|sectionHeading=Ad blockers
 +
|anchor=AdBlockers
 +
|alignment=Vertical
 +
|structuredtext=Ad blockers are plug-ins or browser extensions that improve page load times and minimize questionable tracking. The majority of ad blockers tested with out-of-the-box settings do not interfere with {{MINTYDOCSPRODUCT}}'s tracking capabilities. However, there are a couple considerations if you use uBlock Origin: 
 +
 
 +
*uBlock Origin disables {{MINTYDOCSPRODUCT}}'s tracking web beacons; this effectively prevents {{MINTYDOCSPRODUCT}}'s tracking capabilities.
 +
*uBlock Origin and uBlock Plus Adblocker block popular tag managers such as Adobe Tag Manager, Google Tag Manager, and more.
 +
 
 +
{{NoteFormat|If you use a tag manager to manage JavaScript and tracking on your website, consider adding ad blocker detection to your site to notify visitors with detected ad blockers that they may be missing some important functionality.
 +
 
 +
Also, instead of using a tag manager to deploy the {{MINTYDOCSPRODUCT}} tracking snippet, consider placing the tracking snippet directly in the body or header of your website.|}}
 +
|Status=No
 +
}}{{Section
 +
|sectionHeading=Types of tracking snippets and recommendations
 
|anchor=TypesofSnippets
 
|anchor=TypesofSnippets
 
|alignment=Vertical
 
|alignment=Vertical
 
|structuredtext====Website snippet===
 
|structuredtext====Website snippet===
The Website snippet provides tracking support to traditional webpages that contain little or no dynamic content. Traditional websites load a new HTML page whenever the user navigates to a different URL. To provide tracking support to traditional webpages, the Website snippet calls <tt>{{Link-SomewhereInThisVersion|manual=SDK|topic=Pageview|display text=ac('pageview')}}</tt> each time the a new page is loaded by the web browser.
+
The Website snippet provides tracking support to traditional webpages that contain little or no dynamic content. Traditional websites load a new HTML page whenever the visitor navigates to a different URL. To provide tracking support to traditional webpages, the Website snippet calls <tt>{{Link-SomewhereInThisVersion|manual=SDK|topic=Pageview|display text=ac('pageview')}}</tt> each time the web browser loads a new page.
 
===SPA snippet===
 
===SPA snippet===
The SPA snippet can track activity on Single Page Applications (SPAs). SPAs load dynamic content on demand without requiring a hard reload of the HTML page. The SPA snippet can also track when users click relative links, which the Website snippet does not. The SPA snippet works on SPAs such as Angular, React, Vue.js, and so on. For more information about the additional tracking options available with the SPA snippet, see {{Link-SomewhereInThisVersion|manual=SDK|topic=autoTrackURLChange}}.
+
The SPA snippet can track activity on Single Page Applications (SPAs). SPAs load dynamic content on demand without requiring a hard reload of the HTML page. The SPA snippet can also track when visitors click relative links, which the Website snippet does not. The SPA snippet works on SPAs such as Angular, React, and Vue.js. For more information about the additional tracking options available with the SPA snippet, see {{Link-AnywhereElse|product=ATC|version=Current|manual=SDK|topic=autotrackURLChange}}.
|Status=No
+
 
}}{{Section
+
===Snippet recommendations===
|sectionHeading=Snippet recommendations
+
{{{!}} class="wikitable" style="font-size: 14px;"
|anchor=SnippetRecs
 
|alignment=Vertical
 
|structuredtext={{{!}} class="wikitable" style="font-size: 14px;"
 
 
{{!}}-
 
{{!}}-
 
{{!}}{{!}}'''If you have this type of website...'''
 
{{!}}{{!}}'''If you have this type of website...'''
Line 92: Line 89:
 
|Status=No
 
|Status=No
 
}}{{Section
 
}}{{Section
|sectionHeading=Customize how the snippet tracks activity (optional)
+
|sectionHeading=Deployment overview
 +
|anchor=Deploy
 +
|alignment=Horizontal
 +
|Media=Image
 +
|image=GPE_deploy_diagram.png
 +
|structuredtext=#{{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Tracking_snippet#GetSnippet|display text=Copy the snippet.}}
 +
#(Optional) {{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Tracking_snippet#Customize|display text=Customize the snippet.}}
 +
#{{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Tracking_snippet|anchor=DeploySnippet|display text=Deploy the snippet.}}
 +
#{{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Tracking_snippet#VerifySnippet|display text=Verify that the snippet works.}}
 +
#{{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Web_tracking|display text=Configure web tracking.}}
 +
{{NoteFormat|For more information about advanced chat routing, see  {{#mintydocs_link:topic=Solution/ChatSolutions|standalone}}.|2}}
 +
|Status=No
 +
}}{{Section
 +
|sectionHeading=(Optional) Customize how the snippet tracks activity
 
|anchor=Customize
 
|anchor=Customize
 
|alignment=Vertical
 
|alignment=Vertical
|structuredtext=If needed, you can customize how the snippet tracks activity on your website:
+
|structuredtext=You can customize how the snippet tracks activity on your website.
  
*If you need to refine how {{MINTYDOCSPRODUCT}} tracks activity on your website, see {{Link-SomewhereInThisVersion|manual=Event|topic=About_event_tracking}}.
+
*To customize how {{MINTYDOCSPRODUCT}} tracks activity on your website, see {{Link-SomewhereInThisVersion|manual=Event|topic=About_event_tracking}}.
*You can also customize the {{MINTYDOCSPRODUCT}} tracking snippet with functions from the {{Link-SomewhereInThisVersion|manual=SDK}}. For example:
+
*To customize the {{MINTYDOCSPRODUCT}} tracking snippet with functions, see the {{Link-SomewhereInThisVersion|manual=SDK}}.
**{{Link-SomewhereInThisVersion|manual=SDK|display text=Use the Journey JavaScript SDK to track page view events and to configure how {{MINTYDOCSPRODUCT}} updates cookies. }}
 
**{{Link-SomewhereInThisVersion|manual=SDK|topic=Configure_advanced_tracking|display text=Configure advanced tracking to enable tracking across multiple domains.}}
 
 
|Status=No
 
|Status=No
 
}}{{Section
 
}}{{Section
Line 106: Line 114:
 
|anchor=DeploySnippet
 
|anchor=DeploySnippet
 
|alignment=Vertical
 
|alignment=Vertical
|structuredtext=After you {{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Tracking_snippet|anchor=GetSnippet|display text=copy the snippet}}, review the {{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Tracking_snippet|anchor=DeploymentNotes|display text=deployment notes}}.
+
|structuredtext====About deploying the snippet===
Then follow the instructions to deploy the tracking snippet:
 
  
*{{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Tracking_snippet|anchor=TagManagers|display text=Deploy the snippet with a tag manager.}}
+
*Deploy the widgets transport above the location where you deploy the {{MINTYDOCSPRODUCT}} tracking snippet.
*{{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Tracking_snippet|anchor=DeployManually|display text=Deploy the snippet manually.}}
+
*Deploy the {{MINTYDOCSPRODUCT}} tracking snippet on the main window of the website to track.
|Status=No
 
}}{{Section
 
|sectionHeading=Deployment notes
 
|anchor=DeploymentNotes
 
|alignment=Vertical
 
|structuredtext=*{{Link-Standalone|topic=ATC/GPEandWidgets|display text=Deploy the widgets transport}} above the location where you deploy the {{MINTYDOCSPRODUCT}} tracking snippet.
 
*Deploy the {{MINTYDOCSPRODUCT}} tracking snippet on the main window of the website you want to track.
 
 
*Paste the tracking snippet in the head section of the website template page before the closing tag.
 
*Paste the tracking snippet in the head section of the website template page before the closing tag.
 
*Do not deploy the tracking snippet in an iframe.
 
*Do not deploy the tracking snippet in an iframe.
*The {{MINTYDOCSPRODUCT}} tracking snippet loads JavaScript asynchronously without slowing down page loading. For more details about how the tracking snippet works, see {{Link-SomewhereInThisVersion|manual=SDK|topic=About_the_tracking_snippet}}.
+
*The {{MINTYDOCSPRODUCT}} tracking snippet loads JavaScript asynchronously without slowing down page loading. For more information about how the tracking snippet works, see {{Link-SomewhereInThisVersion|manual=SDK|topic=About_the_tracking_snippet}}.
 
 
<br />
 
|Status=No
 
}}{{Section
 
|sectionHeading=Deploy the snippet with a tag manager
 
|anchor=TagManagers
 
|alignment=Vertical
 
|structuredtext=To easily deploy the {{MINTYDOCSPRODUCT}} tracking snippet, use your preferred tag manager. For example:
 
  
*{{Link-SomewhereInThisVersion|manual=Event|topic=Google_Tag_Manager|anchor=VideoGTMDeploy|display text=Deploy the tracking snippet with Google Tag Manager}}
+
===Deployment instructions===
*{{Link-AnywhereElse|product=ATC|version=Current|manual=Event|topic=Adobe_Launch}}
+
{{NoteFormat|{{Link-Standalone|topic=ATC/GPEandWidgets|display text=Deploy the widgets transport}} transport above the location where you deploy the {{MINTYDOCSPRODUCT}} tracking snippet.
*Any other tag manager
+
|}}After you {{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Tracking_snippet|anchor=GetSnippet|display text=copy the snippet}}, do one of the following:
  
 +
*To deploy the tracking snippet manually, paste the copied snippet on your website.
 +
*To deploy the tracking snippet using Google Tag Manager, see {{Link-SomewhereInThisVersion|manual=Event|topic=Google_Tag_Manager|anchor=VideoGTMDeploy|display text=Deploy the tracking snippet with Google Tag Manager}}.
 +
*To deploy the tracking snippet using Adobe Launch, see {{Link-AnywhereElse|product=ATC|version=Current|manual=Event|topic=Adobe_Launch}}.
 +
*To deploy the tracking snippet using another tag manager, see the tag manager vendor's instructions.
 
{{NoteFormat|
 
{{NoteFormat|
*Deploy the widgets transport above the location where you deploy the {{MINTYDOCSPRODUCT}} tracking snippet.
+
uBlock and other ad blocking software is known to block tag managers, in which case the tracking snippet deployed through the tag manager would also be blocked. For more information, see {{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Tracking_snippet|anchor=AdBlockers|display text=Ad blockers}}.|}}<br />
*uBlock and other ad blocking software is known to block tag managers, in which case the tracking snippet deployed through the tag manager would also be blocked. For more information, see {{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Tracking_snippet|anchor=AdBlockers|display text=Ad blockers}}.|}}
 
|FAQHeading=Can I use a tag management system to deploy the tracking snippet?
 
|Status=No
 
}}{{Section
 
|sectionHeading=Deploy the snippet manually
 
|anchor=DeployManually
 
|alignment=Vertical
 
|structuredtext=#On the '''Tracking Snippet''' page in Genesys Cloud, copy the {{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Tracking_snippet|anchor=TypesofSnippets|display text=type of tracking snippet}} that you need.
 
#Before you paste the snippet on your website, review the {{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Tracking_snippet|anchor=DeploymentNotes|display text=deployment notes}}.
 
{{NoteFormat|Deploy the widgets transport above the location where you deploy the {{MINTYDOCSPRODUCT}} tracking snippet.
 
|}}<br />
 
 
|Status=No
 
|Status=No
 
}}{{Section
 
}}{{Section
Line 152: Line 137:
 
|anchor=VerifySnippet
 
|anchor=VerifySnippet
 
|alignment=Vertical
 
|alignment=Vertical
|structuredtext=When the tracking snippet is properly executed and initialized:
+
|structuredtext=After deploying the tracking snippet, use Live Now to verify that {{MINTYDOCSPRODUCT}} is tracking your website activity. You should see an update every 4-5 seconds.
  
*Use Live Now to verify that {{MINTYDOCSPRODUCT}} is tracking your website activity.
+
===Troubleshoot the snippet===
*You should see an update every 4-5 seconds.<br />
+
If the tracking snippet does not work properly when you load your web pages, check the following:
|Status=No
 
}}{{Section
 
|sectionHeading=Troubleshoot the snippet
 
|anchor=TroubleshootSnippet
 
|alignment=Vertical
 
|structuredtext=If the tracking snippet does not work properly when you load your web pages, check the following things:
 
  
 
*Is the snippet on the correct page?
 
*Is the snippet on the correct page?
*Is the snippet correctly placed in the header?
+
*Is the snippet in the correct place in the page header?
*Are all of the parameters specified correctly?
+
*Are the parameters defined correctly?
 
*Are there any typos, missing characters, or extra white space?
 
*Are there any typos, missing characters, or extra white space?
*Have any characters been replaced by their printable equivalents?
+
*Were any characters replaced with their printable equivalents?
 
*Is the domain on the list of allowed domains?
 
*Is the domain on the list of allowed domains?
  
For more suggestions, see {{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Tracking_snippet|anchor=DeploymentNotes|display text=Deployment notes}}.<br />
+
For more suggestions, see {{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Tracking_snippet|anchor=DeploySnippet|display text=about deploying the snippet}}.
|FAQHeading=How can I troubleshoot the tracking snippet?
+
 
|Status=No
+
===Error reference===
}}{{Section
+
{{{!}} class="wikitable" width="865" data-mce-style="height: 266px;" style="height: 266px;"
|sectionHeading=Error reference
 
|anchor=ErrorSnippet
 
|alignment=Vertical
 
|structuredtext={{{!}} class="wikitable" style="height: 266px;" width="865" data-mce-style="height: 266px;"
 
 
{{!}}-
 
{{!}}-
{{!}} style="width: 178.828px;" data-mce-style="width: 178.828px;"{{!}}'''Error code'''
+
{{!}} data-mce-style="width: 178.828px;" style="width: 178.828px;"{{!}}'''Error code'''
{{!}} style="width: 660.078px;" data-mce-style="width: 660.078px;"{{!}}'''Description'''
+
{{!}} data-mce-style="width: 660.078px;" style="width: 660.078px;"{{!}}'''Description'''
 
{{!}}-
 
{{!}}-
{{!}} style="width: 178.828px;" data-mce-style="width: 178.828px;"{{!}}403 error
+
{{!}} data-mce-style="width: 178.828px;" style="width: 178.828px;"{{!}}403 error
{{!}} style="width: 660.078px;" data-mce-style="width: 660.078px;"{{!}}Is your domain in the list of {{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Web_tracking|anchor=AllowedDomains|display text=allowed domains}}?
+
{{!}} data-mce-style="width: 660.078px;" style="width: 660.078px;"{{!}}Is your domain in the list of {{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Web_tracking|anchor=AllowedDomains|display text=allowed domains}}?
 
{{!}}-
 
{{!}}-
{{!}} style="width: 178.828px;" data-mce-style="width: 178.828px;"{{!}}404 error
+
{{!}} data-mce-style="width: 178.828px;" style="width: 178.828px;"{{!}}404 error
{{!}} style="width: 660.078px;" data-mce-style="width: 660.078px;"{{!}}Is there extra white space in the snippet?
+
{{!}} data-mce-style="width: 660.078px;" style="width: 660.078px;"{{!}}Is there extra white space in the snippet?
 
+
'''Note:''' In a URL, white space is encoded as %20.
'''Note:''' In a URL, white space is encoded as %20.<br />
 
 
{{!}}-
 
{{!}}-
{{!}} style="width: 178.828px;" data-mce-style="width: 178.828px;"{{!}}Bad request
+
{{!}} data-mce-style="width: 178.828px;" style="width: 178.828px;"{{!}}Bad request
{{!}} style="width: 660.078px;" data-mce-style="width: 660.078px;"{{!}}Is there extra white space in the snippet?
+
{{!}} data-mce-style="width: 660.078px;" style="width: 660.078px;"{{!}}Is there extra white space in the snippet?
 
+
'''Note:''' In a URL, white space is encoded as %20.
'''Note:''' In a URL, white space is encoded as %20.<br />
 
 
{{!}}-
 
{{!}}-
{{!}} style="width: 178.828px;" data-mce-style="width: 178.828px;"{{!}}Initialization error
+
{{!}} data-mce-style="width: 178.828px;" style="width: 178.828px;"{{!}}Initialization error
{{!}} style="width: 660.078px;" data-mce-style="width: 660.078px;"{{!}}Are there any of the following in the snippet:<br />
+
{{!}} data-mce-style="width: 660.078px;" style="width: 660.078px;"{{!}}Are there any of the following in the snippet:<br />
  
 
*Typos
 
*Typos
Line 202: Line 175:
 
*Dashes and quotes in URLs replaced with printable equivalents<br />
 
*Dashes and quotes in URLs replaced with printable equivalents<br />
 
{{!}}}
 
{{!}}}
 +
|Status=No
 +
}}{{Section
 +
|sectionHeading=Call the tracking snippet
 +
|anchor=CallSnippet
 +
|alignment=Vertical
 +
|structuredtext=After the tracking snippet is on your webpages, call it using one of the following:
 +
 +
*If you use the traditional snippet, call <code>ac('init')</code> to initialize the Journey JavaScript SDK. For more information, see {{Link-SomewhereInThisVersion|manual=SDK|topic=Init}}.
 +
*If you use the SPA snippet, use <code>ac('load')</code> to load the '''autotrackUrlChange''' module and initialize the Journey JavaScript SDK. For more information, see {{Link-SomewhereInThisVersion|manual=SDK|topic=Load_modules}} and {{Link-AnywhereElse|product=ATC|version=Current|manual=SDK|topic=autotrackURLChange}}.
 +
 +
After you initialize the Journey JavaScript SDK, Predictive Engagement tracks <code>pageview</code> events when visitors arrive on your webpages. For more information, see {{Link-SomewhereInThisVersion|manual=SDK|topic=Tracking_Methods}}.
 +
|Status=No
 +
}}{{Section
 +
|sectionHeading=Other tracking options
 +
|anchor=OtherOptions
 +
|alignment=Vertical
 +
|structuredtext====Web tracking===
 +
Use the {{Link-SomewhereInThisVersion|manual=AdminGuide|topic=Web_tracking}} feature to specify the domains to track and configure web-related tracking settings.
 +
 +
===Custom modules===
 +
Use a set of {{Link-AnywhereElse|product=ATC|version=Current|manual=SDK|topic=About_modules|display text=modules}} to enhance the functionality that the Journey JavaScript SDK provides.
 +
 +
===Event tracking with tag managers===
 +
Use your tag manager to build custom tags and triggers that define how Predictive Engagement tracks activity on your website. For more information, see {{Link-AnywhereElse|product=ATC|version=Current|manual=Event|topic=About_event_tracking}}.
 +
 +
===Domain and subdomain tracking with cookies===
 +
Use cookies to track domains and subdomains. For more information, see {{Link-SomewhereInThisVersion|manual=SDK|topic=Cookie_usage}} and {{Link-SomewhereInThisVersion|manual=SDK|topic=Configure_advanced_tracking}}.
 
|Status=No
 
|Status=No
 
}}
 
}}
 
}}
 
}}

Latest revision as of 21:28, November 9, 2021

Learn about Genesys Predictive Engagement's tracking abilities and how you can start tracking visitors on your website.

Prerequisites

Important
This article only applies to customers using web chat. If you are a Genesys Cloud CX customer, we encourage you to use the new web messaging feature to replace web chat.

About the tracking snippets

Customers who want to use web chat must deploy the Predictive Engagement tracking snippet. This snippet deploys Predictive Engagement tracking on your website and also allows you to use the web chat feature.

Genesys Cloud CX customers who want to use web messaging must deploy the Messenger snippet. This snippet deploys Predictive Engagement tracking on your website and also allows you to use the web messaging feature.
Important
This article provides instructions for deploying the Predictive Engagement tracking snippet only.

Before you begin

Read about the type of data that Genesys Predictive Engagement tracks and how to ensure that you track visitor data in a regulatory-compliant manner. Understand the implications of using ad blocking software. Finally, learn how the tracking snippet works and the types of tracking snippets available.

Copy the snippet

Genesys Predictive Engagement provides a tracking snippet that you can copy and paste. Since you are logged in to Genesys Cloud CX, the tracking snippet already contains your organization ID and region.

  1. Determine which snippet to use.
  2. In Admin in Genesys Cloud CX, open the Global Settings page and then click the Tracking Snippet tab.
  3. Copy the tracking snippet.
  4. Paste the snippet. For more information about where to paste the snippet, see Deploy the snippet.

Ad blockers

Ad blockers are plug-ins or browser extensions that improve page load times and minimize questionable tracking. The majority of ad blockers tested with out-of-the-box settings do not interfere with Genesys Predictive Engagement's tracking capabilities. However, there are a couple considerations if you use uBlock Origin:

  • uBlock Origin disables Genesys Predictive Engagement's tracking web beacons; this effectively prevents Genesys Predictive Engagement's tracking capabilities.
  • uBlock Origin and uBlock Plus Adblocker block popular tag managers such as Adobe Tag Manager, Google Tag Manager, and more.
Important
If you use a tag manager to manage JavaScript and tracking on your website, consider adding ad blocker detection to your site to notify visitors with detected ad blockers that they may be missing some important functionality. Also, instead of using a tag manager to deploy the Genesys Predictive Engagement tracking snippet, consider placing the tracking snippet directly in the body or header of your website.

Types of tracking snippets and recommendations

Website snippet

The Website snippet provides tracking support to traditional webpages that contain little or no dynamic content. Traditional websites load a new HTML page whenever the visitor navigates to a different URL. To provide tracking support to traditional webpages, the Website snippet calls ac('pageview') each time the web browser loads a new page.

SPA snippet

The SPA snippet can track activity on Single Page Applications (SPAs). SPAs load dynamic content on demand without requiring a hard reload of the HTML page. The SPA snippet can also track when visitors click relative links, which the Website snippet does not. The SPA snippet works on SPAs such as Angular, React, and Vue.js. For more information about the additional tracking options available with the SPA snippet, see autotrackURLChange.

Snippet recommendations

If you have this type of website... Use this snippet...
Not sure SPA
Mix of traditional and SPA pages SPA
Traditional pages only Website

Deployment overview

(Optional) Customize how the snippet tracks activity

You can customize how the snippet tracks activity on your website.

Deploy the snippet

About deploying the snippet

  • Deploy the widgets transport above the location where you deploy the Genesys Predictive Engagement tracking snippet.
  • Deploy the Genesys Predictive Engagement tracking snippet on the main window of the website to track.
  • Paste the tracking snippet in the head section of the website template page before the closing tag.
  • Do not deploy the tracking snippet in an iframe.
  • The Genesys Predictive Engagement tracking snippet loads JavaScript asynchronously without slowing down page loading. For more information about how the tracking snippet works, see About the tracking snippet.

Deployment instructions

Important
Deploy the widgets transport transport above the location where you deploy the Genesys Predictive Engagement tracking snippet.
After you copy the snippet, do one of the following:
Important
uBlock and other ad blocking software is known to block tag managers, in which case the tracking snippet deployed through the tag manager would also be blocked. For more information, see Ad blockers.

Verify that the snippet works

After deploying the tracking snippet, use Live Now to verify that Genesys Predictive Engagement is tracking your website activity. You should see an update every 4-5 seconds.

Troubleshoot the snippet

If the tracking snippet does not work properly when you load your web pages, check the following:

  • Is the snippet on the correct page?
  • Is the snippet in the correct place in the page header?
  • Are the parameters defined correctly?
  • Are there any typos, missing characters, or extra white space?
  • Were any characters replaced with their printable equivalents?
  • Is the domain on the list of allowed domains?

For more suggestions, see about deploying the snippet.

Error reference

Error code Description
403 error Is your domain in the list of allowed domains?
404 error Is there extra white space in the snippet?

Note: In a URL, white space is encoded as %20.

Bad request Is there extra white space in the snippet?

Note: In a URL, white space is encoded as %20.

Initialization error Are there any of the following in the snippet:
  • Typos
  • Missing characters
  • Dashes and quotes in URLs replaced with printable equivalents

Call the tracking snippet

After the tracking snippet is on your webpages, call it using one of the following:

  • If you use the traditional snippet, call ac('init') to initialize the Journey JavaScript SDK. For more information, see init.
  • If you use the SPA snippet, use ac('load') to load the autotrackUrlChange module and initialize the Journey JavaScript SDK. For more information, see load and autotrackURLChange.

After you initialize the Journey JavaScript SDK, Predictive Engagement tracks pageview events when visitors arrive on your webpages. For more information, see Tracking methods.

Other tracking options

Web tracking

Use the Web tracking feature to specify the domains to track and configure web-related tracking settings.

Custom modules

Use a set of modules to enhance the functionality that the Journey JavaScript SDK provides.

Event tracking with tag managers

Use your tag manager to build custom tags and triggers that define how Predictive Engagement tracks activity on your website. For more information, see About event tracking with tag managers.

Domain and subdomain tracking with cookies

Use cookies to track domains and subdomains. For more information, see Cookies and Advanced tracking with cookies.

Comments or questions about this documentation? Contact us for support!