https://github.com/mcartmell/sghaze-api
Singapore PSI (haze) readings JSON API
https://github.com/mcartmell/sghaze-api
Last synced: 4 months ago
JSON representation
Singapore PSI (haze) readings JSON API
- Host: GitHub
- URL: https://github.com/mcartmell/sghaze-api
- Owner: mcartmell
- Created: 2014-06-30T13:38:20.000Z (almost 11 years ago)
- Default Branch: master
- Last Pushed: 2015-06-21T03:57:43.000Z (almost 10 years ago)
- Last Synced: 2025-01-10T09:13:25.718Z (5 months ago)
- Language: Ruby
- Size: 133 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# sghaze-api
A simple webservice for fetching the Pollutant Standards Index (PSI) reading from http://www.nea.gov.sg/psi/.
I tried to find an existing server for something like this, but couldn't. I
found similar web apps and scrapers in various languages, but they had too many
dependencies, so I rolled this lightweight one.Currently it just returns the latest 3-hr measurement for each of the 5 areas,
because that's all I wanted.# Public server
I'm running a server at http://sghaze.herokuapp.com/
```
$ curl http://sghaze.herokuapp.com
{"North":"56","South":"56","East":"56","West":"56","Central":"56"}⏎
```# Running
This should suffice as long as you have Rack installed:
```
rackup
```