Script to fetch the Swedish school meal menu and display it on 2.9" EPaper tags.
- Uses the Skolmaten.se API to fetch current menus of your chosen school nightly.
- Generates two json files formatted for 2.9" displays;
- One with the menu of today.
- One with the menu of the next day (if on a weekend, the Monday menu will be displayed).
- Google Drive account
- OpenEPaperLink Access Point
- 2.9" EPaper Tags (no other sizes supported atm)
-
Login to Google Drive. Right click in a folder of your choise. Add a new Google Apps Script
-
Paste the code from Skolmaten.gs into the newly created script.
-
Set schoolId to the ID of your school. Find the correct ID by browsing to your school and copy the ID from the url.
-
Select Triggers from the left side menu. Add a trigger to run "updateSkolmaten" nightly.
-
Go back to the code Editor and hit the Run-button to execute the script once.
Two json files will be created next to your Apps Script on the Drive.
-
Right click on each of the json files and set sharing to public. Click "Copy link" before closing the sharing dialog
-
Get the id part from the copied link and add it to the following format:
-
In the OpenEPaperLink dashboard. Set your tag content type to "Json template" and paste the reformatted link.
-
The current menu should now display on your tag!