Tool 1: geocode
Request URL
Waiting…
Trimmed JSON response
Waiting…
Change the wording, keep your experiment. Saved in this browser when storage is available.
Open-Meteo. Two tools. Browser only.
To check a place’s weather, first turn its name into map coordinates. Then send those coordinates to the forecast service. This page makes those requests and shows their replies. A fixed script connects the steps; no AI model runs.An agent often cannot answer “Do I need an umbrella?” with one call. It must geocode a place, then forecast rain. This page runs that chain live and shows the exact request URLs and trimmed JSON the agent would see. The page plays the agent’s part with a fixed script; no AI model runs here.
Loading Seattle…
1. Geocode 2. Forecast 3. Decide
Fetching Open-Meteo…
Calls leave your browser for Open-Meteo only. Use my location sends approximate coordinates with the forecast request.
Starting default Seattle chain…
The place search returns the coordinates that the weather request needs. That is how the two tools connect.Distinct from the dog demo’s single tool call: here the second tool’s inputs come from the first tool’s output.
Request URL
Waiting…
Trimmed JSON response
Waiting…
Request URL
Waiting…
Trimmed JSON response
Waiting…
The page looks at the next 6 hours. Yes if any hour has probability ≥ 50% or precipitation ≥ 0.5 mm. No if the peak probability is < 20% and peak precipitation is < 0.1 mm. Otherwise maybe.
| Local time | Precip. probability (%) | Precipitation (mm) |
|---|
Grade band: grades 9–12 / intro CS (estimated one class period).
Any modern browser, including Chromebooks.
Printable one-page handout (use your browser’s Print on that section).
| Score | Student can… |
|---|---|
| 3 | Name both tools in order, point to lat/lon leaving geocode and entering forecast, and state the yes/no/maybe rule inputs. |
| 2 | Name both tools and describe chaining in plain words, with one specific field from the JSON. |
| 1 | Recognizes that two API calls happened, but cannot connect an output field to the next input. |
| 0 | No evidence of reading the request URLs or JSON. |
Press “Show saved example.” The full lesson still completes with a bundled Seattle recording. The banner will say “Showing a saved example.”
const g = await fetch('https://geocoding-api.open-meteo.com/v1/search?name=Seattle&count=1&language=en&format=json').then(r => r.json());
const { latitude, longitude } = g.results[0];
const f = await fetch('https://api.open-meteo.com/v1/forecast?latitude=' + latitude + '&longitude=' + longitude + '&hourly=precipitation_probability,precipitation&forecast_hours=6&timezone=auto').then(r => r.json());
console.log(g.results[0], f.hourly); Weather data by Open-Meteo, CC BY 4.0.
Weather data by Open-Meteo, CC BY 4.0.
Format, size and a short SHA-256 identifier, measured when this page was built.