Git Product home page Git Product logo

hannover-buergeramt-bot's Introduction

Hannover Bürgeramt Bot

This Telegram bot allows you to subscribe to notifications about early appointments at the citizen centres (Bürgerämter) in Hannover, Germany. Please note that all texts except the documentation are in german.

Usage

You can add @hannover_buergeramt_bot on Telegram. The bot provides the following commands:

  • /deadline: Subscribe to notifications about appointments earlier than a given deadline. The date format is DD.MM.YYYY.
  • /termine: Query the 10 earliest appointments
  • /stop: Disable notifications
  • /start, /hilfe: Print a help message

Hosting

If you want to host this bot yourself you have to clone the repository and create a new virtual environment in the directory of the cloned repo.

git clone https://github.com/Popkornium18/hannover-buergeramt-bot
cd hannover-buergeramt-bot
python -m venv venv
. venv/bin/activate
pip install wheel
pip install -r requirements.txt

If you intend to use systemd for logging and want to use MySQL/MariaDB as your database, you have to install the optional dependencies as well. Make sure that you have the systemd header files installed. On Debian/Ubuntu these headers are provided by libsystemd-dev.

pip install -r optional-requirements.txt

Next you have to copy the default configuration and add the API token of your bot. Available configuration options are documented in the example config file as comments.

cp config.py{.example,}

Now you can run the bot like this:

python bot.py

If you want to use a systemd service to autostart the bot at boot time (which is highly recommended), feel free to copy this template:

[Unit]
Description=Hannover Bürgeramt Bot
After=network.target

[Service]
Type=simple
User=YOUR_USER
Group=YOUR_GROUP
WorkingDirectory=/PATH/TO/hannover-buergeramt-bot
ExecStart=/PATH/TO/hannover-buergeramt-bot/venv/bin/python bot.py
Restart=always

[Install]
WantedBy=multi-user.target

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.