Tracking
Attach metadata via Helpshift Widget.
Adding Tags to Conversations
You can attach tags while reporting an issue by passing them to the helpshiftWidgetConfig
object at the time of initialization. You can pass an array of strings which will get added as Tags when the issue is created.
For example:
// Make this change to the embed code placed before the closing </body> tag.
window.helpshiftWidgetConfig = {
platformId: "<YOUR_APP_ID>",
domain: "<YOUR_DOMAIN>",
tags: ["foo", "bar"],
};
Note
On tag names & compatibility
- Tags must be pre-created in the Helpshift Dashboard (Settings → Tags), otherwise they will be ignored.
- The attached tags must exactly match the tags present on the dashboard.
Set Custom Issue Fields
If you want to set Custom Issue Fields at the time of issue creation, you can pass them to the helpshiftWidgetConfig
object at the time of initialization.
window.helpshiftWidgetConfig = {
platformId: "<YOUR_APP_ID>",
domain: "<YOUR_DOMAIN>",
cifs: {
// Key of the Custom Issue Field
version: {
// Type of Custom Issue Field
type: "number",
// Value to set for Custom Issue Field
value: "10.0",
},
userInfo: {
// Type of Custom Issue Field
type: "singleline",
// Value to set for Custom Issue Field
value: "We have a new user!",
},
}
};
The following are the valid values for the type property of a Custom Issue Field.
- singleline
- multiline
- number
- checkbox
- dropdown
- date
Compatibility table for type and values:
Type | Value | Comments |
---|---|---|
singleline | string | Character limit of 255 |
multiline | string | Character limit of 100,000 |
number | string | |
dropdown | string | Drop-down options should exist for the given Custom Issue Field |
date | number | Epoch time. For example - Date.now() |
checkbox | boolean |
Note
- This config should be called before the issue is created (i.e. before the Helpshift Widget launcher is clicked or the Open Widget API is called). You won't be able to update Custom Issue Fields after the issue is created.
- If any of the keys, types or values are invalid, that particular Custom Issue Field will get dropped.
- If you want to update the Custom Issue Fields for subsequent issue creations, you need to update the cifs config in the helpshiftWidgetConfig object and then use the updateHelpshiftWidgetConfig API to update the Custom Issue Fields for subsequent issue creations.