Skip to main content

Gain insight into customer activity (MT4)

This article explains how to integrate a user-friendly GeniusLink Insight experience into your existing CRM/CEM. With GeniusLink Insights, agents can instantly see a full history of customer view and search activity across every channel. The primary benefits for the organization are:

  • Better context: Agents can see exactly what the customer was trying to accomplish before filing the case.
  • Avoid resending content: To avoid customer frustration, agents can ensure customers haven't yet seen the articles that will be sent. (Or, if the correct article has been seen, agents can verify if all steps were performed correctly.)
  • Identify gaps in self-service: Agents can notice whether relevant results were clicked after searching, and suggest new search recommendations that should appear.
  • Lowers costs: Agents improve their Mean Time To Resolution by quickly identifying what the customer is trying to accomplish.


After completing this how-to you will have a GeniusLink Insights interface similar to the following, running inside your existing application.:


This sample code brings the power of GeniusLink Insights into your CRM/CEM. The key features for agents include:

  • Instant access to customer history, which is loaded when the case is opened
  • Quick access to the exact searches and pages performed by clicking the link
  • Detailed information about the exact date (and time) a customer performed the request


In order to setup this integration, you should have:

  • A CRM/CEM which can run HTML code
  • Basic familiarity with Javascript
  • Basic familiarity with CSS (if styling customization is desired)

Step 1: Download the Sample Code

Download the sample file file to your computer.

Step 2: Set Configuration Variables

The sample code is configured to use the MindTouch Success Center at In the top of the file, modify the following settings:


var MindTouch = {};
MindTouch.SITE_URL = "";
MindTouch.CUSTOMER_ID = '';


  • SITE_URL - the MindTouch site to connect to (connect to the HTTPS version of the site, since most CRM/CEM systems are HTTPS themselves)
  • CUSTOMER_ID - the username (or anonymous session ID) of the customer. The customer username is a more reliable way to track activity between sessions.

Step 3: Enable Customer History Tracking

Ensure you are logged-in with a Pro Member with the USERHISTORY permission enabled for the site. This can be enabled via the API or you can contact MindTouch support to configure a specific Pro Member role with USERHISTORY enabled. You can then add users with that role to a group. When enabled, verify that you can visit the User Activity Report and lookup the history for a customer.

Next, ensure the CUSTOMER_ID is available in your case management system. Although MindTouch provides anonymous session IDs as part of the GeniusLink workflow, it's best to provide the username of the customer. (Using SSO, your customers can automatically log into MindTouch).

Using the customer username provides better tracking and avoids the risk of losing information if the customer changes browsers or clears browser cookies, which would clear the anonymous session. Learn more about the customer activity API

Step 4: Integrate The Code With Your CRM/CEM Software

The last step is to integrate the code into your CRM. Using the HTML widget functionality, copy the widget HTML code into the appropriate location. A few caveats:


  • Single SIgn On (SSO): The search widget uses the API and no SSO is performed. If the user has an existing session with MindTouch, it will be re-used by these API requests (more on setting up SSO with MindTouch).
  • jQuery: The widget code uses a version of jQuery hosted by Google, and is stored as $j in noConflict mode. If the CRM/CEM has an existing jQuery library, this can be used instead.
        <!-- PREREQUISITE: jQuery -->
        <script src=""></script>
  • API Requests: The widget makes direct API calls using jQuery's $.ajax() function. If the CRM/CEM provides its own AJAX library, this can be used instead.
    var url = MindTouch.SITE_URL + '/@api/deki/events/support-agent/=' + customerId + '?dream.out.format=jsonp&dream.out.pre=?';
    var params = {
       limit: 50,
       include: "page,file",
       origin: MindTouch.WIDGET_NAME
  • Custom Behavior: The code was written to be modular. The rendering of the activity interface can be easily modified to support a different look and feel.
  • Accessing the Customer ID: When SSO is setup, the customer username is often the customer's email address. If a different system is in place, ensure the CRM/CEM has this as a variable that can be passed to the Insights widget.
  • Custom Styling: The CSS at the bottom of the widget can be modified to restyle the widget. This code sample references the Font Awesome icon font to for the page and search icons. 
  • Was this article helpful?