Page 1 of 1

Lost with Openweathermap

Posted: Tuesday 19 March 2024 12:12
by pipiche
I'm running Domoticz 2024.4 and I'm still lost with OWM

When using the URL http://api.openweathermap.org/data/2.5/ ... PID=xxxxxx. it works well.

If I put the APIKEY in the OpenWeatherMap Hardware plugin I'm always getting the error message

"OpenWeatherMap: Error getting http data!"

From what I understood , the APIID that I'm using is working on API 2.5 and not API 3.0. Is Domoticz only able to work with 3.0 ? and that is why I'm getting this error ?

Mar 19 12:16:59 bigpi domoticz[25273]: domoticz: OpenWeatherMap: Using Domoticz home location (Lon 6.939814, Lat 43.527639)!
Mar 19 12:16:59 bigpi domoticz[25273]: 2024-03-19 12:16:59.228 Status: OpenWeatherMap: Using Domoticz home location (Lon 6.939814, Lat 43.527639)!
Mar 19 12:16:59 bigpi domoticz[25273]: OpenWeatherMap: Using Domoticz home location (Lon 6.939814, Lat 43.527639)!
Mar 19 12:16:59 bigpi domoticz[25273]: domoticz: OpenWeatherMap: Lat/Long = 43.5276,6.9398 -> (Nearest) City (6618150)
Mar 19 12:16:59 bigpi domoticz[25273]: 2024-03-19 12:16:59.534 Status: OpenWeatherMap: Lat/Long = 43.5276,6.9398 -> (Nearest) City (6618150)
Mar 19 12:16:59 bigpi domoticz[25273]: OpenWeatherMap: Lat/Long = 43.5276,6.9398 -> (Nearest) City (6618150)
Mar 19 12:16:59 bigpi domoticz[25273]: domoticz: OpenWeatherMap: Updating preferences for forecastscreen to use OpenWeatherMap!
Mar 19 12:16:59 bigpi domoticz[25273]: 2024-03-19 12:16:59.534 Status: OpenWeatherMap: Updating preferences for forecastscreen to use OpenWeatherMap!
Mar 19 12:16:59 bigpi domoticz[25273]: domoticz: OpenWeatherMap: Started
Mar 19 12:16:59 bigpi domoticz[25273]: 2024-03-19 12:16:59.534 Status: OpenWeatherMap: Started
Mar 19 12:16:59 bigpi domoticz[25273]: OpenWeatherMap: Updating preferences for forecastscreen to use OpenWeatherMap!
Mar 19 12:16:59 bigpi domoticz[25273]: OpenWeatherMap: Started
Mar 19 12:17:02 bigpi domoticz[25273]: domoticz: OpenWeatherMap: Error getting http data!
Mar 19 12:17:02 bigpi domoticz[25273]: 2024-03-19 12:17:02.806 Error: OpenWeatherMap: Error getting http data!
Mar 19 12:17:02 bigpi domoticz[25273]: OpenWeatherMap: Error getting http data!

Re: Lost with Openweathermap

Posted: Thursday 21 March 2024 16:26
by habahabahaba
Are you subscribed on API 3.0 plan in OWM ?
2024-03-21_18-23-53.png

Re: Lost with Openweathermap

Posted: Thursday 21 March 2024 18:28
by pipiche
Yes I do ! And it does work, buyt not inside Domoticz

Re: Lost with Openweathermap

Posted: Thursday 21 March 2024 19:25
by habahabahaba
https://www.domoticz.com/wiki/Open_Weather_Map

It seems that Dz supports only apis of free plan.

What if you try to make api 3.0 call from dzvents script?

Re: Lost with Openweathermap

Posted: Wednesday 31 July 2024 10:26
by Filip
Hi all,

Has somebody found a clarification?
The same happens for me... If I use "https://api.openweathermap.org/data/2.5 ... &appid=xxx" in a browser, I got a correct JSON information.
However if I configure the openweathermap plugin with the same coordinates, api_key and API version 2.5, I got the error "Error getting http data!"

Btw I used it without any problem since a long time, but migrated recently to 2024.7 version.

So very strange.

F

Re: Lost with Openweathermap

Posted: Wednesday 31 July 2024 12:25
by habahabahaba
OW blocking some IPs so may be your browser is under VPN and DZ is not?

As for me I'm usung dzvents script for getting data from OW

Re: Lost with Openweathermap

Posted: Wednesday 31 July 2024 20:43
by Filip
Both are on the same network... So should not give a difference.

***Update*** Just tried with CURL on the Raspberry running Domoticz and it works also... So seems not any blocking IP address...
curl "https://api.openweathermap.org/data/2.5 ... appid=xxxx"

Re: Lost with Openweathermap

Posted: Wednesday 31 July 2024 23:00
by Filip
Finally solved and the only way is to add a subscription.
I subscribed and defined the max. API calls to 1000 so that there is no risk to exceed the "free" limit...
Drawback: credit card information is used...