Now Online Only
Out of an abundance of caution regarding COVID-19 (coronavirus), we have decided to switch the March 18th meetup to an online-only meetup.
We will provide a Zoom video conference link 20 minutes before the meetup here and in the IndieWeb chat.
Homebrew Website Club is a meetup for an…
Year: 2020
MapInterested in the Indieweb, but you already have a WordPress site? Do you have a WordPress website or thinking of starting one?
Whether you’re a blogger, coder, designer, or just someone who wants to improve their presence on the web, if you have a WordPress site and want to add Indieweb functiona…
Thinking About Weather
However, this is not the first time an API has shut down on me. I created a WordPress plugin called Simple Location. It uses map APIs to show maps of location, reverse geocoding APIs to turn coordinates into location data, and of course, Weather APIs to get the weather for a location at the time of a post.
I like adding weather to my posts, and I maintain my own weather stations at two locations. So, I went through all of the Weather API I have integrated to note some of the pros and cons.
- HERE – The newest provider I’ve added. It returns some info none of the other providers do: Descriptor values for air, sky; a textual description of the air, temperature, and precipitation; Snow cover as well as amount that has fallen; wind speed on the Beaufort scale; UV index; Barometric trend And their free tier offers 250,000 transactions per month. Does not offer historical data.
- National Weather Service – No API key or limits as government data. Doesn’t keep more than a few days of historic data. Good general data. You are also limited to NWS Observation and forecast stations.
- OpenWeatherMap – The free tier limits you to 1000 calls per day, and a limited subset of their APIs. However, in response to the Dark Sky situation, they just added a new API endpoint that is included, which mirrors the Dark Sky API offering. It offers the current weather, hourly forecast for 48 hours, daily forecast for 7 days, and historical weather data for 5 previous days. It also offers a Stations API for retrieving data from a user supplied weather station. UV Index is available, but that is a separate API call. They’ll also sell you 40 years worth of weather data for a single location for 10 cents.
- Weatherbit – Daily forecasts and current weather data is free for non-commercial use. Offers UV Index and Air Quality Index. Allows for historical data.
- WeatherStack – Free tier limits you to 1000 calls per month, so this is the one I’m least likely to use. Does include historical data.
- Met Office UK – The UK’s service has the most basic of all the data provided. Behind a free API key, you can get information for several hundred stations in the UK. However, the Data Point API is set to be replaced in future, but the replacement does not currently have an observation API, only a forecast one.
- Accuweather – Free tier limited to 50 calls per day, and referred to as a trial. And you cannot lookup by location, you need to query for a location key…which means if you look it up every time, that’s only 25 calls per day. Didn’t even bother to implement this.
- Weather Channel – only opened its API for a Call for Code challenge period.
- Weather Underground – While Weather Underground shut its API down, it does still offer one for Personal Weather Station contributors. This appeals to me. I still send my weather data to Weather Underground…as well as 5 other places. But I would only be able to search current conditions for Personal Weather Stations.
- AerisWeather – Same as Weather Underground, free access to their APIs and weather reporting stations if you contribute. Might implement this in future.
Anyone have any other weather sources for current conditions?
Simple Location 4.0.6 for WordPress Released
- HERE Maps is joined by using HERE as a Weather and a Reverse Geocoding provider. While doing this, I discovered they switched to an API key system, and updated the code appropriately. HERE Maps also has a new endpoint, so I switched to that as well.
- I went through the API documentation for all of the existing weather endpoints and made some changes to standardize the units of measurement being stored. Did you know a millbar and a hectopascal are essentially the same thing?
- I added support for the Met Office, which offers several hundred stations in the UK. Like the US National Weather Service, it provides the closest one, and if there isn’t close, it returns nothing. Working on another station-based weather provider interested me in trying to add better support for personal weather stations.
- If you have WP_DEBUG enabled, a new tab appears on the Location Settings page to allow you to see what data is returned by your provider. This is used mostly by me as the developer, but I’ve kept it in in case someone wants to troubleshoot the information they are getting.
Simple Location 4.1.0 Released
- AerisWeather is now a provider
- A lot of code cleanup and documentation
- Improvements to Airport data, adding of airline data, and additional data sources to avoid on demand download.
- Standardization and documentation of units
- Addition of the ability to set a custom icon instead of the location arrow.
- Lots of improvements if you use Compass to what it can derive
- Airport location provider now supports IATA and ICAO airport codes.
I did want to add local weather stations and a few other features, but I decided to release and work on those features later.