Botium Connector for Kore.ai Webhooks
MIT License
This is a Botium connector for testing your Kore.ai chatbot.
Did you read the Botium in a Nutshell articles ? Be warned, without prior knowledge of Botium you won't be able to properly use this library!
Botium uses a Kore.ai Webhook channel to connect to your chatbot.
It can be used as any other Botium connector with all Botium Stack components:
When using Botium CLI:
> npm install -g botium-cli
> npm install -g botium-connector-koreai-webhook
> botium-cli init
> botium-cli run
When using Botium Bindings:
> npm install -g botium-bindings
> npm install -g botium-connector-koreai-webhook
> botium-bindings init mocha
> npm install && npm run mocha
When using Botium Box:
Already integrated into Botium Box, no setup required
You have to attach a Webhook channel to your Kore.ai chatbot:
Open the file botium.json in your working directory and add the Webhook settings.
{
"botium": {
"Capabilities": {
"PROJECTNAME": "<whatever>",
"CONTAINERMODE": "koreai-webhook",
"KOREAI_WEBHOOK_URL": "https://bots.kore.ai/chatbot/hooks/...",
"KOREAI_WEBHOOK_CLIENTID": "...",
"KOREAI_WEBHOOK_CLIENTSECRET": "..."
}
}
}
Botium setup is ready, you can begin to write your BotiumScript files.
Set the capability CONTAINERMODE to koreai-webhook to activate this connector.
The full Webhook URL from the Webhook configuration settings in V1 format:
{{host_url}}/chatbot/hooks/{{bot id}}
or{{host_url}}/chatbot/hooks/{{bot id}}/hookInstance/{{webHookId}}
The CLIENT ID from the Webhook configuration settings
The CLIENT SECRET from the Webhook configuration settings
It is recommended to actually not add this to the botium.json file, but to use the environment variable BOTIUM_KOREAI_WEBHOOK_CLIENTSECRET instead
Turn it on to extract NLP metadata, like recognized intent, and entities.
It is an advanced capability. In special cases it might be required to overwrite the URL calculated by Botium.
The name of the Bot. If NLP Analytics is enabled, then this capability is required.
If set, this userId will be used as sender. Otherwise, for each convo a new userId is generated.
If set, this userId will be used as receiver. Otherwise, for each convo a new userId is generated.
The CLIENT ID of an app, created in Kore AI Admin Console
The CLIENT SECRET of an app, created in Kore AI Admin Console