You can connect Kore.ai assistants to your Mattermost account using either:
Before you begin, ensure that you have access to the administrative functions of your Mattermost account.
WebHook based Integration
Step 1: Setup Outgoing Webhook
- Login to your Mattermost account
- From the Main Menu choose Integrations.
- Select the Outgoing Webhooks menu and click Add Outgoing Webhook.
- Provide required information as per the below image.
- Enter your preferred values for Title, Description and Bot Name fields.
- Choose application/json as Content Type.
- If you would like your bot to be available only for a specific channel, then choose the required channel from the Channel dropdown.
- Provide your Kore.ai assistant Name in the Trigger Words field.
- Copy the Callback URL for the Kore VA (located in the XO Platform > Deploy > Channels > Mattermost)Â and provide it in the Callback URLs field.
- Click on Save to complete the Outgoing Webhook setup.
- You will be redirected to the confirmation page with the Token displayed.
- Copy this Token and provide it in the ‘Outgoing Webhook Token’ field present in the XO Platform Channel Configurations section.
Step 2: Setup Incoming Webhook
- Select the ‘Incoming Webhooks’ menu and click ‘Add Incoming Webhook’.
- Provide required information as per the below image.
- Click on Save to complete the Incoming Webhook setup.
- You would be redirected to the confirmation page along with the URL associated with this newly created incoming webhook.
- Copy this URL and provide it in the ‘Incoming Webhook URL’ field in the Kore Bot Channel Configurations section.
WebSocket based Integration
Step 1: Enable Personal Access Tokens
To enable a WebSocket connection, you would need to create a Mattermost account to be provisioned as a bot.
- First, enable usage of Personal Access Tokens to allow your Mattermost users to generate personal access tokens.
- Personal access tokens are used to authenticate and provide full access to an account.
- Login to Mattermost from an account that has access to System Console.
- Go to System Console > Integrations > Integrations Management.
- Locate the Enable Personal Access Tokens setting, set it to true, and Save.
Step 2: Create an Account to be Provisioned as a Bot
- From your Mattermost account, go to Integrations > Bot Accounts > Add Bot Account.
- Configure the Bot’s details:Â
- Choose a Username.
- Add an Icon, a Display Name.and a Description.
- Choose the Member role.
- Select additional permissions for the account:Â
- post:all to allow the bot to post to all Mattermost channels including direct messages.
- post:channels: to allow the bot to post to all Mattermost public channels, but not in direct messages or private channels.
- Click Create Bot Account to complete the setup.
- A success page will be shown to you next, where you will also find the access token you can use to connect to this assistant.
XO Platform Channel Configuration
To configure the XO Platform channel, after having completed the setup in Mattermost, please follow the steps below:
- In the XO Platform, select the Assistant that you are working with.Â
- Go to Deploy > Channels > Mattermost.
- Select the Configuration tab and provide the following details, which you have just generated in Mattermost:
- Outgoing Webhook Token.
- Incoming Webhook URL.
- Select Yes to enable the channel.
- Click Save to save your configuration.
After the channel is enabled and all configurations are verified, you can optionally publish the assistant to make it available for end-users, with the new channel. Learn more about Publishing your Virtual Assistant.
To learn more about working with Channels within the Kore.ai XO Platform, please see Channel Enablement.