Skip to content

Data Mapping for Adobe Analytics

The Stackchat Adobe Analytics configuration maps your chatbot events and their payloads to Adobe Analytics page variables, props, eVars and events. This page outlines which Stackchat data points map to which Adobe Analytics concepts. You are able to configure mappings in a very granular way using the Mapping tab. Adobe Analytics Cloud

*Click on mappings*

Adobe Analytics Page Variables

These are the Stackchat data points that map directly to Adobe Analytics Page Variables.

Page Variable Description
pageName Populated with the following string: "Chat:<channel-name>" for example, Chat:sc-messenger for web or Chat:facebook for FB Messenger.
pageURL Populated with the same value as pageName above.
channel Not populated.
visitorID Populated with the Stackchat UserId, unless overridden with the browser's ECID by calling the Web Messenger's updateAnalyticsId SDK method.

As an aside, Flows could be considered as analogous to pageName and the Flow / Flow Element concept could then map to a pageURL, but these don't translate well, because in a conversation, your bot may jump around between a handful of Flows and Elements in response to a single user query. This results in a confusing set of data (e.g. 7 page views detected in response to a single user query), so we've opted to NOT populate the pageName and pageURL properties in this way. If you want to see how many times a given flow has been hit, you can see that in the Flow Name report. If you want to see how many times users have queried your bot, you can see that in the User Query report.

Mapping Stackchat Data to Props and eVars

The below table outlines all the Stackchat data points that can be mapped to Adobe Analytics props and eVars via Stackchat's Cloud Configuration UI.

Stackchat Trackable Item Description List Support
Stackchat User Id A unique Id assigned to the user by Stackchat
Conversation Id A unique Id assigned to the current conversation by Stackchat
FlowName The name of the flow visited by the user. Y
ElementName The name of the flow element visited by the user. Y
Flow Name With Element Name A concatenation of the previous two values - useful if you want to reference a unique "url" type of value. Y
Language Not supported yet, but will contain the language currently being spoken by the bot.
Input Method Can only be "voice" or "text" and is only relevant for the SDKs that support both input methods.
User Input Group Id Since User Input Groups don't have a 'name', this is tracked as the value: "${MESSAGE_THREAD_NAME}.USER_INPUT[X]" where X denotes the index of the user input in the message thread (since there could be multiple user input groups in a given thread). Y
Slot Name Tracks the label of the slot being populated in a user input group. It will, for example track 'WineType' (the slot name), not the value passed by the user, like 'shiraz'. This is because slots values may contain PII. Y
Branch Name Tracks the name of the logic branch. Y
Cloud Function Name Tracks the name of the cloud function. Y
Cloud Function Error Type Tracks the type of error (null-pointer, execution timeout, etc.). Y
NLP Intent Name The name of the NLP intent that was predicted in response to the user's message.
NLP Intent Type QA Intent vs Nav Intent.
NLP Confidence Track how confident your NLP provider is of the intent prediction. Registers as a number between 0 and 1, rounded to 2 decimal places.
NLP Confidence Range A convenience field derived from the previous NLP Confidence field. Buckets of ranges in 20% intervals, for example '-20% to -40%' or '60% to 80%'.
NLP Slots Populated This tracks the names of the entities that were extracted, not the values passed by the user. Y
NLP User Query User queries that were sent to the configured NLP provider. Be careful, this may contain PII depending on how your bot is configured. Do not configure this as a prop or eVar in Adobe Analytics if there's a chance it contains PII.
Incoming User Message Tracks all incoming messages from the user. Be careful, this may contain PII depending on how your bot is configured. Do not configure this as a prop or eVar in Adobe Analytics if there's a chance it contains PII.
Sentiment Score Corresponds to the overall emotional leaning of the user query, powered by the response from your NLP provider. Registers as a number between 0 and 1, rounded to 2 decimal places.
Sentiment Magnitude Indicates the overall strength of emotion (both positive and negative) within the user's query.
Action Sequence Tracks the name of the Action Sequence. Y
Clear Slots Action Tracks the name of the Clear Slots action (e.g erase_attraction_facilities_choice). Y
Set Slots Action Tracks the name of the Set Slots action. Y
Analytics Event Action Tracks the name you assigned to the analytics action. Y
Message Thread Name Tracks the name of the Message Thread. Y
Referral Track the value of the referral code used in Facebook Messenger so you can measure attribution to various traffic sources.

Mapping Stackchat Events to Success Events

The below table outlines all the Stackchat events that can be mapped to Adobe Analytics Success Events via Stackchat's Cloud Configuration UI.

Stackchat Trackable Item Description
MESSAGE_SENT Fires whenever any message is sent.
MESSAGE_RECEIVED Fires whenever any message is received.
POSTBACK_RECEIVED Fires whenever a postback is received.
IMAGE_SENT Fires when your bot sends an image message
TEXT_SENT Only fires for a text message declared in CDML. Not, for example, when we send a text prompt before a quick nav.
LIST_SENT Fires when your bot sends a carousel/list
QUICKNAV_SENT Only fires once for a quick nav, even though we send both the prompt message and the actual navs.
UIG_START Fires when a user input group starts.
UIG_COMPLETE Fires on successful completion of the entire user input group.
UIG_CORRECTION_MADE Fires if the user chooses to adjust a field in a user input group, following the confirmation prompt.
UIG_VALIDATION_FAILED Fires if the user provides an invalid value in a user input group (for example, a number if the slot is of type 'date').
BRANCH_RESOLVES_TRUE Fires when a branch resolves as true.
BRANCH_RESOLVES_FALSE Fires when a branch resolves as false.
CLOUD_FUNCTION_START Fires when your cloud function begins execution
CLOUD_FUNCTION_COMPLETE Fires when your cloud function ends execution
CLOUD_FUNCTION_ERROR Fires when there's a runtime exception in the code.