Shelf’s Chatbot Configuration Guide


Purpose

This document describes steps that are necessary to set up and configure Chatbot.

In order to use the Knowledge Assist feature, Shelf Support needs to be contacted to configure your account.

If you require further assistance, please do not hesitate to contact us at support@shelf.io, via the live chat on the Shelf website or from the in-app chat support within the Shelf platform.

Last Update: 30-July 2021

Create a chatbot configuration

  1. On the Shelf Admin Panel, go to ‘Chatbot Configuration’ tab and click ‘Add Configuration’.




Configure JSON

  1. Go to the ‘Settings’ tab and configure the JSON as instructed below (the items highlighted in green color are not required, you can use this documentation as extra help):

{
"configs": [
{
"chatResponseSize": 1,
"intents": [
"type here an intent saved in Dialogflow (up to 100 characters) (you can use up to 20 intents for one provider)",
],
"type": "API",
"providersConfiguration": [
{
"size": 1,
"libraryIds": [
"paste here the library id where the gems with the required content are located (you can use up to 100 different ids)",
],
"providers": [
"faq"
]
}
]
},
{
"type": "text",
"intents": [
"type here another intent saved in Dialogflow"
],
"text": [
"Type here some text that will be used as a default response when the predefined intent is triggered"
]
}
],
"unknownIntentHandler": {
"type": "text",
"text": [
"Type here a text that will be used as a default response for unknown intents"
]
}}


2. Save the configuration.





Test the configuration

  1. Use an API client tool (e.g. ‘Postman’) and do the following request:
  • paste the following request in the request URL field:

https://api.shelf.io/chatbot/webhook?settingsId=paste here the id of your configuration

  • Select method ‘POST’
  • On ‘Headers’ tab, type ‘x-shelf-email’ and ‘x-shelf-password’ in ‘KEY’ column, your Shelf email address and your Shelf password in ‘VALUE’ column, using the corresponding rows for each


  • On ‘Body’ tab paste the following JSON

{
"message": "{{Type here a text that should trigger content from the providers saved in your configuration}}",
"intent": "{{Type here the intent from the corresponding provider from your configuration}}"
}

You can copy your configuration id on the ‘General’ tab of your created configuration.



2. Send the request and check the response.