The Weather API provides an HTTP API method to retrieve and personalize the weather data provided by NOAA's National Weather Service. The format of the response can either be a nearly display ready string for an application or it can be a simple HTML web page or table.
Unlike most APIs which can only return their payload data with the same data elements and structure every time, the Weather API is programmable so that the user can more precisely define what is returned from the API. This allows the API to respond with a smaller payload that more closely matches the user's needs. For example, I have built a digital Weather Clock with live weather using an old 2x20 Point Of Sale display and a Raspberry Pi.
The documentation for this API is broken down into two parts.
- The first, Current Observations, describes how to personalize the current observed weather conditions and return them as a text string.
- The second Weather Forecast, describes how to personalize the forecasted weather conditions and return them as a text string.
Follow these simple steps to build your first current observation weather report:
- Find the ICAO Station ID for the weather station that is nearest to you. Follow the instuctions in the ICAO Station ID page.
- In your browser's address bar build your own URL
- Start with "https://rest.omegatower.ninja/weather/nws/?icao="
- End with the ICAO Station ID from Step 1
Observe the results (this example uses the John F. Kennedy International Airport)
Your first current observation weather report
Save your personalized weather report URL as a bookmark, embed it in your WordPress site, etc...
You can further define your weather report following the instructions in the other parts.