Files
MagicMirror/tests/mocks/weather_owm_current.json
Kristjan ESPERANTO 22a58d4ae5 fix(weather): restore OpenWeatherMap v2.5 support (#4101)
After the big weather refactor (#4032), OpenWeatherMap was effectively
hard-wired to One Call v3. One Call 2.5 is deprecated and no longer
available, so it looked like v2.5 support was effectively over — but the
classic `/weather` and `/forecast` endpoints were never actually
dropped. This restores support for those.

Fixes #4100.

## What this PR does
- handles OpenWeatherMap responses by endpoint again (`/onecall`,
`/weather`, `/forecast`)
- restores v2.5 current and forecast support (including hourly via
3-hour forecast slots)
- filters outdated hourly entries centrally while keeping the current
hour visible (if available)

## Screenshot
<img width="768" height="481" alt="bildo"
src="https://github.com/user-attachments/assets/9bce3531-3731-4fd7-b41e-e20603afa725"
/>
2026-04-10 22:20:41 +02:00

29 lines
578 B
JSON

{
"coord": { "lon": 11.58, "lat": 48.14 },
"weather": [{ "id": 804, "main": "Clouds", "description": "overcast clouds", "icon": "04d" }],
"base": "stations",
"main": {
"temp": -0.27,
"feels_like": -3.9,
"temp_min": -1.0,
"temp_max": 0.5,
"pressure": 1018,
"humidity": 54
},
"visibility": 10000,
"wind": { "speed": 3.09, "deg": 220 },
"clouds": { "all": 100 },
"dt": 1744200000,
"sys": {
"type": 2,
"id": 2002112,
"country": "DE",
"sunrise": 1744170000,
"sunset": 1744218000
},
"timezone": 7200,
"id": 2867714,
"name": "Munich",
"cod": 200
}