Skip to content

clamytoe/bdaybot

Repository files navigation

Birthday Bot (bdaybot)

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.

Python version Build Status BCH compliance GitHub issues GitHub forks GitHub Stars License

Design Concept

flowchart

Intial Setup

git clone https://github.com/clamytoe/bdaybot.git
cd bdaybot

Python VENV Environment

python3 -m venv venv
source ./venv/bin/activate
pip install -r requirements.txt

Anaconda Development Environment

conda env create -f environment.yml
source activate bdaybot

Package Installation

python setup.py install

How to use

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.

help

Sample run:

sample

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.

next_birthday

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!

next_tuesday

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!

Releases

No releases published

Packages

No packages published

Languages