I'm running this on a Raspberry Pi.
It's using libcurl to deal with https to weather.gov
I'm parsing the JSON and slapping together HTML to return to the webuser.
Right now I'm just working on getting the most succinct weather info I need into a small and clean space.
The RPi has a good GPS on it so that the webuser does not need location (or JavaScript or https).
For non-mobile use you can just have the "TOP/31,80" fixed.
I need to make this a systemd service so that it will poll a few times a day and not query new location coords unless there has been movement.
Eventually this will be a small section of my (non web) NST status display that's connected to the RPi.
The JSON from weather.gov does include URLs for summarize icons and "shortForecast" text.
There is also this example page (which doesn't quite correlate):
For example, the latest JSON says "Sunny" and there is no "Sunny" on that whole page.
The color icon are not very suitable for an NST anyway.
Drawing icons is definitely something that I don't do well!
It's interesting:
A quick check of weather.gov for my locality uses 1 MB of data (with another 1MB data already cached).
Querying for JSON uses ~10 kB, 1%
It's surprising that public providers don't promote APIs more.
I hit up the John Hopkins Covid site for stats, that's 849 bytes total!