Skip to main content

simple API to access the STWNO canteen's menus

Project description

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.

Project details


Release history Release notifications | RSS feed

This version

0.1

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

stwno_canteen-0.1.tar.gz (6.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

stwno_canteen-0.1-py3-none-any.whl (8.2 kB view details)

Uploaded Python 3

File details

Details for the file stwno_canteen-0.1.tar.gz.

File metadata

  • Download URL: stwno_canteen-0.1.tar.gz
  • Upload date:
  • Size: 6.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.24.0 setuptools/50.3.2 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.8.6

File hashes

Hashes for stwno_canteen-0.1.tar.gz
Algorithm Hash digest
SHA256 eb6291e15d544f9e1ccd1ca64e16252bfcecc63745515e8aac54c4c9e8272513
MD5 6eeee87e20f29b70fbfb4d9cc4b24594
BLAKE2b-256 b7aa8f0fcd3c25e68fd49226a9a764f84cb1a3a4c96524ed2e42ea052c0f4cbc

See more details on using hashes here.

File details

Details for the file stwno_canteen-0.1-py3-none-any.whl.

File metadata

  • Download URL: stwno_canteen-0.1-py3-none-any.whl
  • Upload date:
  • Size: 8.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.24.0 setuptools/50.3.2 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.8.6

File hashes

Hashes for stwno_canteen-0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 39fdb9fb3ac1acac56268cf4f7394262003bc179cfb4ff4a4f99e6d61a5426bb
MD5 939f4014ce9dcacd4ddb9eb192792afd
BLAKE2b-256 2e9bd8c6d2942a75c861e4bd4908b2f96ae2ff82a2b99e7e8472f1ab30c45015

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page