Mattermost connector
The Mattermost connector connects a bot to Mattermost, with webhooks. It answers the messages of a channel (optionally only those starting with a trigger word), or a slash command.
- Connector type:
mattermost - Sources and README: connector-mattermost
Prerequisites
- A Mattermost server, with the system administrator rights to create webhooks and allow the calls to the Tock host
- A URL of the bot that the Mattermost server can reach
Configuration
- In the Mattermost System Console (Environment > Developer), allow Mattermost to call the Tock host (Allow untrusted internal connections to).
- Create an incoming webhook (used by Tock to post messages) on the channel: its URL ends with its token.
- Create an outgoing webhook (or a slash command) on the same channel, with the connector URL as callback,
for instance
https://<bot-host>/io/<namespace>/<bot>/mattermost. Mattermost gives its token. - In Tock Studio, create a Mattermost connector in Settings > Configurations:
| Field | Description |
|---|---|
| Mattermost Server Url | For instance https://mattermost.mydomain.com |
| Incoming webhook token | Token of the incoming webhook |
| Outgoing webhook token | Token of the outgoing webhook or slash command |
| Optional Channel Id | (optional) dedicated channel |
| Optional Tock Username | (optional) username displayed for the bot |