Giter VIP home page Giter VIP logo

munich-scripts's Introduction

General

Some useful scripts simplifying bureaucracy, especially when living in Munich, Germany.

termin.py

Small tool to show availability of appointments in different Departments of Munich.

Available departments are:

  • Ausländerbehörde (foreign nationals affairs, residence permits, work visas etc.)
  • Bürgerbüro (civil affairs, residence registration etc.)
  • Führerscheinstelle (driver license and motor vehicles affairs)

Please note the script does not perform appointment booking, it just tells you current status, so you may run it with cron and\or add some custom notifier.

Telegram bot

There is a simple Telegram bot at @MunichTerminBot using termin.py functionality. The bot is written using python-telegram-bot library. Source code is also in this repo, tg_bot.py.

Development

By default bot runs as webhook configured for Heroku. For local development it's easier to use polling and in order to get it, just set DEBUG = True in one of first lines of the script.

Bot deployment

Bot is hosted on Heroku, runnning in Docker and automatic deploy from master branch of this repoi is set, no action should be required.

Manual deployment

Similar to one of basic manuals.

Pre-requisites:

  • Heroku CLI installed.
  • TG_TOKEN environment variable is set in Heroku settings
  • HEROKU_APP_NAME environment variable is set in Heroku settings.

Commands for manual deploy

heroku login
heroku container:login
heroku container:push --app munich-termin-bot web
heroku container:release --app munich-termin-bot web

Shortly after deploy make sure everything is running

heroku logs --tail --app munich-termin-bot

Script usage

Edit script content and select what type of appointments you actually need:

appointments = get_termins(DMV, 'FS Umschreibung Ausländischer FS')
# appointments = get_termins(CityHall, 'An- oder Ummeldung - Einzelperson')
# appointments = get_termins(ForeignLabor, 'Niederlassungserlaubnis Blaue Karte EU')

Run the script

python3 termin.py

Output will be printed in the console

munich-scripts's People

Contributors

okainov avatar

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.