Package: pyMensa
pyMensaA python package for accessing mensa menus at ETH and UZH ZürichInstallationpip3 install pyMensaUsageThis package lets you access mensa menus at ETH and UZH Zürich. This package will only let you access menus at lunch time of the current day.Get MealsIt is very simple to get meals for a mensa:import pyMensa

meals = pyMensa.get_meals("Polymensa")

for meal in meals:
    print(meal)
    print()Example Output:LOCAL (STUD:10.50 STAFF:11.50 EXTERN:15.50)
	Dieses Menu servieren wir Ihnen gerne bald wieder!


STREET (STUD:9.90 STAFF:11.90 EXTERN:15.90)
	The New York Burger
	Schweizer Rindfleisch
	oder Vegi-Grillburger
	Sesam Maxi-Bun, Cheddar,
	Eisberg, Tomaten, Gurken, 
	BBQ Relish und Chips

GARDEN (STUD:6.20 STAFF:9.30 EXTERN:12.70)
	Vegan Day
	Seitan mit Blumenkohl,
	Kichererbsen und Harissa-Sauce

etc ...Get MensaYou can also just query for a Mensa Object:import pyMensa

unimensa = pyMensa.get_mensa("uni")

print(unimensa.name)
print(unimensa.aliases)

meals = unimensa.get_meals()
for meal in meals:
    print(meal)
    print()Example Output:UZH Zentrum
['zentrum', 'uni', 'uzh zentrum', 'uzhzentrum']
einfach gut (STUD:5.40 STAFF:7.00 EXTERN:10.50)
	 Rindshackfleisch-Pilzragout
	mit hausgemachten Spätzli und Weisskabis
	Fleisch:Rind, CH


natürlich vegi (STUD:5.40 STAFF:7.00 EXTERN:10.50)
	 Gefüllte Aubergine mit Sojagehacktem Tomatensauce und Bratkartoffeln Menüsalat oder ApfelmusObjectsThis is a descripition of all objects used by this package.MealThis object describes a generic meal.Parameters:NameTypeDescriptionlabelstrThe label/name of that mealprice_studentstrThe price for studentsprice_staffstrThe price for staffprice_externstrThe price for other guestsdescriptionstr arrayA list of descriptions, usually ingredients.Functions:NameReturn TypeDescriptionstrstrReturns the string representation of the mealMensaThis object describes a generic mensa.Parameters:NameTypeDescriptionnamestrThe name of the mensaaliasesstr arrayA list of alternative names that can be entered when searchingFunctions:NameReturn TypeDescriptionget_mealsMeal arrayReturns list of available Mealshas_aliasboolChecks if the given alias corresponds to that mensaETH MensaThis object inherits from the generic Mensa object and implements theget_mealsfunction for theETH Gastro APIParameters:NameTypeDescriptionapi_namestrThe name of the mensa in the ETH Gastro APIFunctions:NameReturn TypeDescriptionget_mealsMeal arrayFetches meals using theETH Gastro APIUNI MensaThis object inherits from the generic Mensa object and implements theget_mealsfunction for theUZH Mensa Websitewhich is unfortunately much slower that working with the proper API ETH provides us with, but we have no choice.Parameters:NameTypeDescriptionapi_namestrThe name of the mensa on the UZH Mensa WebsiteFunctions:NameReturn TypeDescriptionget_mealsMeal arrayFetches meals from theUZH Mensa WebsiteAvailable MensasHere is a list of all available Mensas and their corresponding aliases:NameAliasesMensa Polyterrassepoly, polymensa, polyterrasse, mensa polyterrasseFood&Labfoodlab, food lab, food&labCausiusbarclausius, clausiusbar, lausiusbar, lausiusPolysnackpolysnack, snackTrailerburgerfoodtrailer, trailer, trailerburgerAlumni quattro Loungealumni, alumnilounge, alumni loungeBellavistabellavista, bella vistaFusion Mealfusion, fusionmeal, fusion mealG-ESSbargess, gessbar, g-essbar, essbarTannenbartanne, tannenbar, tannen barDozentenfoyerdozentenfoyer, dozenten, foyer, dozenten foyerPlattenstrasseplatte, plattestross, plattenstrasse, plattestrassRämi 59rämi, raemi, rämi59, raemi59, rämi 59, raemi 59, raemistrasse, rämistrasse, rämistrossUZH MercatomercatoUZH Zentrumzentrum, uni, uzh zentrum, uzhzentrumUZH Lichthoflichthof, rondellUZH Irchelirchel, irchel mensa, irchelmensaUZH Irchel Atriumirchel atrium, atriumUZH Binzmühlebinzmühle, binzmuehleUZH CityportcityportUZH Zahnmedizinzahnmedizin, zzmUZH TierspitaltierspitalUZH Botanischer Gartenbotanischergarten, botanischer garten, garten, botgarten