Hong Kong Weather API
What is this for?
Weather in Hong Kong varies greatly day by day and has a huge impact on the life of the average Hongkonger. Normal weather services are not accurate for this region. Luckily the Hong Kong Observatory has really great reporting employing over 300 secientists to carefully monitor weather, storms and typhoons.
The Hong Kong Observatory provide an official website an app. As part of the governments open data initiative they also offer RSS feeds for the data.
I've found that the official feed is lacking a lot of detail, so as well as using that, I looked at the unofficial JSON feeds that the mobile app uses and created a helpful node module to parse those.
This module uses a combination of both of these to generate useful and reliable data.
Install
npm install --save hongkong-weather
Usage
You can create the instance using the following
var HongKongWeather = ; var hkWeather = ; hkWeather;
Supported Methods
Example data
All methods return JSON, please see the examples linked above for more info on how to call each method.
hkWeather ;
Gives this response
Issues
I'm happy to fix any issues, but make sure to send a Gist of your XML or HTML content so I can recreate the problem. The government feeds are inconsistent so sometimes I might not be able to recreate the problem.
Other Handy Modules
- hongkong-pollution - For Air Quality and Pollution Data for Hong Kong.
Contributing
Feel free to submit any pull requests or add functionality, I'm usually pretty responsive.
If you like the module, please consider donating some bitcoin or litecoin.
Bitcoin
LiteCoin