Open badewanne1234 opened 2 months ago
The API does not send the condition, very sorry.
'regionHourlyForecast': [{'precipitationMax': 0.0,
'precipitationMean': 0.0,
'precipitationMin': 0.0,
'temperatureMax': 22.0,
'temperatureMean': 22.0,
'temperatureMin': 22.0,
'time': datetime.datetime(2024, 9, 7, 22, 0, tzinfo=datetime.timezone.utc)},
{'precipitationMax': 0.0,
'precipitationMean': 0.0,
'precipitationMin': 0.0,
'temperatureMax': 21.2,
'temperatureMean': 21.2,
'temperatureMin': 21.2,
'time': datetime.datetime(2024, 9, 7, 23, 0, tzinfo=datetime.timezone.utc)},
{'precipitationMax': 0.0,
'precipitationMean': 0.0,
'precipitationMin': 0.0,
'temperatureMax': 20.5,
'temperatureMean': 20.5,
'temperatureMin': 20.5,
'time': datetime.datetime(2024, 9, 8, 0, 0, tzinfo=datetime.timezone.utc)},
{'precipitationMax': 0.0,
'precipitationMean': 0.0,
'precipitationMin': 0.0,
'temperatureMax': 20.6,
'temperatureMean': 20.6,
'temperatureMin': 20.6,
We use API URL 'https://app-prod-ws.meteoswiss-app.ch/v1/forecast?plz=671000&graph_startLowResolution=true&warning=true'
for obtaining the hourly forecast.
If you can find another API URL , please reopen with the necessary info.
We have found a different URL that provides the condition and the precipitation probability (for every three hours under precipitationProbability3h
) as well as the condition (for every three hours under weatherIcon3h
and weatherIcon3hV2
):
https://app-prod-ws.meteoswiss-app.ch/v1/plzDetail?plz=390000
Sample data attached:
This is now a viable new feature that can be implemented. PRs against hamsclientfork
and this integration welcome, because it's going to take me a few weeks to get this done myself.
The hourly forecast introduction is great but it misses the current condition, it provides temp high, temp low and precipitation, but it misses the condition.
In contrast, the met.no forecast provides that plus additional attributes
Whilst
wind_bearing
,cloud_coverage
andhumidity
are probably not offered by Meteo Schweiz, I would highly assume the currentcondition
attribute itself would be offered by the API?