Skip to content

steffsommer/stwno_canteen

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

STWNO Canteen is a simple python API for querying the menu of the canteens operated by the STWNO (Studentenwerk Niederbayern/Oberpfalz) in Lower Bavaria and Upper Palatinate.

Features

  • Simple to use API for querying the menu for any given day in any STWNO canteen
  • Command Line Interface to print todays menu to the terminal

Usage

import datetime
import stwno_canteen

today = datetime.date.today()
menu = getMenu(stwno_canteen.Canteen.OTH_RGB_CANTEEN_LUNCH, datetime.date.today())
print(menu)

Requirements

$ python --version >= 3.8.0

Installation

You can install the API manually, or by using pip:

$ python -m pip install stwno_canteen

Command Line Interface

The command line interface allows to fetch the menu for the current day of a given canteen:

$ python -m stwno_canteen -c <canteen_identifier>

For a list of available identifiers, check out the Canteens dictionary in the constants file.

Additional Notes

I do not guarantee for the correctness and completeness of the parsed ingredients/allergenes. This is mostly because there tend to be errors in the CSV files from STWNO frequently, which makes it hard to parse. If you suffer from an allergy, you should not rely on this API.

About

Python API to access the menu of the STWNO canteens

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages