The Kato Hubot adapter allows you to use Hubot in your Kato team.
Install Hubot (consult the Hubot documentation for more information):
$ sudo npm install -g yo generator-hubot
Create a new bot:
$ mkdir myhubot
$ cd myhubot
$ yo hubot
You will be asked which adapter to use, type kato
.
First, create a new Kato account for your bot. It’s best to create a new email address, eg. [email protected]
and invite this address to your Kato team. Verify the email and set a name for your bot in its new account (that name shows up when it posts a message).
Next, you will need to set some environment variables:
$ export HUBOT_KATO_LOGIN="[email protected]"
$ export HUBOT_KATO_PASSWORD="5prz8OKty6"
Once that’s done, you can start Hubot with Kato as the adapter:
$ ./bin/hubot -a kato
Please ignore npm WARN
and deprecated
messages, they are generated by packages unrelated to the Kato adapter. You shoud be able to see your bot online in Kato just a few seconds after you ran this command.
The Kato addapter supports listening for commands in
- all unrestricted rooms
- restricted rooms, to which it has been explicitly added
- 1 on 1 chats with the bot itself
You can address your bot by beginning a message with its name, which defaults to Hubot
.
You can change this and also set an alias using the following additional environment vars:
$ export HUBOT_NAME="Frank"
$ export HUBOT_ALIAS="!"
Your bot should now reply to !ping
with PONG
.
The bot will not respond to itself.
Log filename (the default is kato-hubot.log
):
$ export HUBOT_KATO_LOG_FILE="path/filename.log"
Log level (one of error
, debug
, or info
. Default is error
):
$ export HUBOT_KATO_LOG_LEVEL="debug"
Copyright © LeChat, Inc. See LICENSE for details.