Skip to content

Google Apps Script to fetch Swedish school meal menu and generate json for display on E-Ink price tags

Notifications You must be signed in to change notification settings

leXorNet/Skolmaten

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 

Repository files navigation

Skolmaten

Script to fetch the Swedish school meal menu and display it on 2.9" EPaper tags.

Features

  • 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).

Requirements

Installation

  1. Login to Google Drive. Right click in a folder of your choise. Add a new Google Apps Script

  2. Paste the code from Skolmaten.gs into the newly created script.

  3. Set schoolId to the ID of your school. Find the correct ID by browsing to your school and copy the ID from the url.

  4. Select Triggers from the left side menu. Add a trigger to run "updateSkolmaten" nightly.

  5. 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.

  6. Right click on each of the json files and set sharing to public. Click "Copy link" before closing the sharing dialog

  7. Get the id part from the copied link and add it to the following format:

    https://drive.google.com/uc?export=download&id=[fileid]

  8. In the OpenEPaperLink dashboard. Set your tag content type to "Json template" and paste the reformatted link.
    Json template

  9. The current menu should now display on your tag!

About

Google Apps Script to fetch Swedish school meal menu and generate json for display on E-Ink price tags

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published