ATS Labs · Episode 02 · Open data, production-grade map
Forecast Anywhere
Click any point on the planet, and a 7-day forecast comes back in about a second.
The problem
A forecast for every point, and then the details
Every coordinate on Earth has a model forecast waiting for it, and you can ask for one without an account or a token. The hard part is what the response does to you the first time: timestamps that carry no time zone, a longitude that keeps counting past the date line, and one value that ignores the units you asked for.
Watch it work
Episode 2 — Forecast Anywhere (6:14)
One weather service end to end: the forecast and geocoding endpoints, the request the app actually makes, the three details that cost the most time, and the map they turn into.
What it covers
Two endpoints, three details, one map
- The forecast endpoint: one request returns a 7-day model forecast for any latitude and longitude, with the location's own time zone and UTC offset attached. Seven hourly variables and seven daily; forecast_days=7 means 168 hourly entries.
- The geocoding endpoint: a typed place name in, coordinates out. When nothing matches it leaves the results key out of the response entirely rather than returning an empty list.
- The code: one function, one abort signal. Type a second place before the first answers and the first request is canceled rather than raced.
- Detail one, the timestamps: local times arrive with no offset on the end of them. Parsed with the browser's own date constructor they are read in the viewer's zone, and the night shading on the chart moves by however many hours the viewer sits from the place.
- Detail two, the antimeridian: pan west past the date line and the longitude under the cursor does not wrap. The API refuses anything outside -180 to 180, so every click is normalized back into range before the request is built.
- Detail three, units: the app asks for Fahrenheit, miles per hour and inches once, and derives Celsius, kilometers per hour and millimeters in the browser at render time. Elevation ignores the unit parameters and always returns in meters.
- How it becomes a map: a click gives a coordinate, the coordinate gives one request, the request fills the panel. There is no catalog to load and no layer to refresh.
What it does not do
- No historical archive — the app shows the 7-day forecast and 48 hours of hourly detail, not the past.
- No reverse geocoding — click raw ocean and the label falls back to the coordinate, because the geocoder only runs name to coordinates.
- No severe-weather alerts — this is model forecast data, not a warning service. That is the next episode.
Where the data comes from
Every endpoint in the episode
- Open-Meteo Weather Forecast API — open-meteo.com/en/docs
- Open-Meteo Geocoding API — open-meteo.com/en/docs/geocoding-api
- Open-Meteo license — open-meteo.com/en/license
- Open-Meteo terms — open-meteo.com/en/terms
- Source sheet with every endpoint and parameter — allthingsspatial.io/pages/sources.html
Open-Meteo data is licensed CC BY 4.0, so attribution travels with it — it sits in the app footer, on the forecast card and in the About dialog. The free API tier is for non-commercial use with a published ceiling under 10,000 calls a day; commercial use requires an API subscription. Those are the provider's terms, linked above.
Build with us
Need this on your data?
Forecast Anywhere is an ATS Labs build — React and Tailwind on the ArcGIS Maps SDK for JavaScript, over a public weather API — and it is a demonstration of what All Things Spatial builds. The real thing — your data, your brand, your infrastructure — is the work we do for clients.