Hangupsbot is a chat bot designed for working with Google Hangouts.
Please see:
Note: First run? See the installation instructions
To execute: python3 hangupsbot.py
usage: hangupsbot [-h] [-d] [--log LOG] [--cookies COOKIES] [--memory MEMORY] [--config CONFIG] [--version]
optional arguments:
-h, --help show this help message and exit
-d, --debug log detailed debugging messages (default: False)
--log LOG log file path (default:
~/.local/share/hangupsbot/hangupsbot.log)
--cookies COOKIES cookie storage path (default:
~/.local/share/hangupsbot/cookies.json)
--memory MEMORY memory storage path (default:
~/.local/share/hangupsbot/memory.json)
--config CONFIG config storage path (default:
~/.local/share/hangupsbot/config.json)
--version show program's version number and exit
Configuration directives can be specified in config.json
.
Please note that the config.json
file supplied with the repository is not
supposed to be edited/changed. It is the reference file used by the bot to
create the actual configuration file located elsewhere in the system. To find out
where the actual file is, please see the Additional Configuration section
in the installation
instructions.
Most configuration directives are specified globally
config.json
.config.conversations[<conversation-id>].<configuration option>
.The plugins
key in config.json
allows you to optionally specify a list of plugins
that will be loaded by the bot on startup. If this option is left as null
, then
all available plugins will be loaded.
To specify the plugins to be loaded, first ensure that the correct .py
files are
inside your hangupsbot/plugin/
directory, then modify the plugins
key in
config.json
to reflect which plugins/files you want to load e.g.
plugins: ["mentions", "default", "chance", "syncrooms"]
Some plugins may require extra configuration.
config.json
is the the configuration provider for the bot and its plugins.
Some interesting plugins:
The wiki has a more comprehensive list of plugins...
There are two general types of interactions with the bot:
/bot
commands begin with /bot
e.g. /bot dosomething
The base bot supports some basic command even without any plugins loaded. Here is a partial list:
/bot help
/bot ping
pong
./bot version
A full list of commands supported by the base framework is available at the Core Commands wiki page.
The wiki also has a list of plugins detailing available plugins with commands lists and usage.
cd ~/hangupsbot
)git checkout master
git pull
to pull the latest version of hangupsbotpip3 install -r requirements.txt --upgrade
-d
parameter e.g. python3 hangupsbot.py -d
- this
lowers the log level to INFO
for a more verbose and informative log file.tail
the log file, which is probably located at
/<user>/.local/share/hangupsbot/hangupsbot.log
- the location varies by
distro!Program isn't running:
hangupsbot
and hangups
hangups
to check if the original hangups library is working
`~/.local/share/hangupsbot/cookies.json
and try againBot isn't responding to messages:
Please see https://github.com/hangoutsbot/hangoutsbot/wiki/Authoring-Bot-Extensions
Hangoutsbot is derived from the mogunsamang bot, which itself is a fork of xmikos's hangupsbot
On 2015-06-20, this fork was detached and made standalone on GitHub
On 2015-07-03, the fork was made into a Github Organisation