Slack birthday management and greeting bot.
The concept is simple. Tell the bot your birthday and when it comes around, get a nice little birthday message. In order to not wake anyone up at midnight, the messages are displayed at 09:00AM for the local time of the user.
git clone https://github.com/clamytoe/bdaybot.git
cd bdaybot
python3 -m venv venv
source ./venv/bin/activate
pip install -r requirements.txt
conda env create -f environment.yml
source activate bdaybot
python setup.py install
Before you can start the bot you are going to have to set a couple of environment variables on your system:
BOT_ID and SLACK_BOT_TOKEN
To start it simply use the command bdaybot
Once the bot is up and running and you've added it to one of your slack channels, it'll simply respond to any message directed towards it. It's not smart, any message to it should contain the birthday keyword.
It also accepts the help command and returns a short description of how it works.
Sample run:
If a date is not included in the message and you have already given it your birthday before, it will return the number of days left for it.
Now it is pretty smart about filtering out different date formats, it just defaults to accepting the month before the day; sorry International users! You don't even have to supply a year for that matter!
It automatically takes into account the users TimeZone and will give them a random birthday message at 09:00AM their local time. We didn't want it to wake anybody up at midnight!