Weather Sage 0.1.2 Released

August 25, 2019

A couple days ago I released Weather Sage 0.1.2.

Weather Sage is a command-line tool and Ruby library to get the weather forecast and current weather observations for a domestic United States street address.

It uses the Census Bureau Geocoding API to geocode street addresses, and the National Weather Service Weather API to get weather forecasts and current weather observations.

The command-line tool queries the APIs above to obtain the requested information for the given street address, and then prints the results to standard output in CSV format.

Here’s an example of using the weather-sage command-line tool to get the weather forecast for the address 1600 pennsylvania ave nw, washington dc:

> weather-sage forecast '1600 pennsylvania ave nw washington dc'
address,name,temperature,temperature_unit,wind_speed,wind_direction,short_forecast
1600 pennsylvania ave washington dc,Today,97,F,7 mph,SW,Scattered Showers And Thunderstorms
1600 pennsylvania ave washington dc,Tonight,76,F,2 to 7 mph,SW,Scattered Showers And Thunderstorms then Mostly Cloudy
1600 pennsylvania ave washington dc,Tuesday,94,F,6 mph,E,Slight Chance Rain Showers then Chance Showers And Thunderstorms
1600 pennsylvania ave washington dc,Tuesday Night,75,F,2 to 6 mph,S,Chance Showers And Thunderstorms
1600 pennsylvania ave washington dc,Wednesday,94,F,3 to 9 mph,SW,Chance Showers And Thunderstorms
1600 pennsylvania ave washington dc,Wednesday Night,76,F,5 to 8 mph,SW,Chance Showers And Thunderstorms
...

And here’s an example of using the weather-sage command-line tool to get the current weather observations from the weather station closest to the address 1600 pennsylvania ave nw, washington dc:

> weather-sage now '1600 pennsylvania ave washington dc'
address,name,type,value,unit,quality_control
1600 pennsylvania ave washington dc,timestamp,time,2019-08-19T06:52:00+00:00
1600 pennsylvania ave washington dc,textDescription,text,Mostly Cloudy
1600 pennsylvania ave washington dc,temperature,value,26.700000000000045,unit:degC,qc:V
1600 pennsylvania ave washington dc,relativeHumidity,value,81.65039907186703,unit:percent,qc:C
...

You can install Weather Sage via RubyGems like this:

# install weather-sage with rubygems
> gem install weather-sage

Note: This is the initial release, so the API documentation, test suite, and command-line interface are not yet complete.