What's my plan?
Suite Team, Growth, Professional, Enterprise, or Enterprise Plus
This functionality is part of AI agents.

Although autoreplies with articles are operational as soon as it is set up in the Web Widget (Classic), you can configure some functionality by modifying the JS API, including:

  • Suppressing autoreplies
  • Temporarily suppressing contact channels
  • Updating the appearance of the bot
  • Filtering autoreplies by label
Note: Autoreply APIs are currently using legacy terminology (Answer Bot).

Related articles:

  • Enabling Article Recommendations in Web Widget (Classic)
  • Zendesk bot resources
  • Web Widget (Classic) resources

Suppressing autoreplies

If there are situations where you don't want to suggest answers you can now use the JS API to suppress it, similar to what you would do with other channel options:

window.zESettings = {
webWidget: {
answerBot: {
suppress: true
}
}
};

For more information, see the suppress JS API call.

Temporarily suppressing contact channels

You can use a JS API to force attempted self-service before the contact options are displayed:

window.zESettings = {
webWidget: {
answerBot: {
contactOnlyAfterQuery: true
}
}
};

When this is set to true, users will be required to attempt to self-serve (by simply asking their question / stating their problem), after which the contact channel choice options will be presented as usual.

Updating the appearance of the bot

You can control the displayed widget title, bot name, and avatar through the basic JS API shown below. By default, the "Bot" tag will always be present to help indicate to users that the experience is not with a human.

Add the following code snippet BEFORE the widget script is loaded. Then, you can control and define the title, bot name, and avatar image source, for example:

<script type="text/javascript">window.zESettings = { 
webWidget: { 
answerBot: {
avatar: { 
url: 'https://link-to-some-image', 
name: { "*": 'Zendesk' 
} 
}, 
title: { "en-US": "Support" 
} 
} 
} 
};
</script>

Filtering article suggestions by label

You can use the JS API to set labels which are passed through to suggested articles. Then, autoreply can search for suggestions using only articles that contain those labels.

Add the following code snippet BEFORE the widget script is loaded. Then, you can set your labels:
<script>zESettings = { webWidget: { answerBot: { search: { labels:
                        ['hello', 'world'] } } }}</script>
This option can useful in the following scenarios:
  • Creating a url mapping that sets labels based on where the user is on the website (perhaps they are in a particular product category, you can set labels to ensure only articles for that product are filtered on).
  • Filtering articles for a particular platform based on the detected device.
  • And many more...
Powered by Zendesk