Domoticz server denies access by some APIs Topic is solved

On various Hardware and OS systems: pi / windows / routers / nas, etc

Moderator: leecollings

Post Reply
roelvdh
Posts: 37
Joined: Saturday 18 January 2020 13:40
Target OS: Raspberry Pi / ODroid
Domoticz version: 2024.7
Location: NL
Contact:

Domoticz server denies access by some APIs

Post by roelvdh »

I have a Raspi running Domoticz. Everything runs fine, except 2 APIs that used to run OK but suddenly stopped communicating. I am not aware of any changes to my system around the time this started. The problematic services are Tado and Weatherchannel:

Code: Select all

2024-01-30 20:49:35.138 Error: Tado systeem: Failed to retrieve API environment from https://my.tado.com/webapp/env.js
2024-01-30 20:49:42.474 Error: Weerkanaal: Error getting http data!
This may not be a Domoticz problem but I am out of options so maybe someone has a quick fix?

Edit:
And I cannot reach the Domoticz site either

Code: Select all

pi@EnergyPi:~/domoticz $ sudo ./updaterelease
Stopping Domoticz...
Making backup of current installation...
Output file: backups/domoticz_backup_20240130_210843.tar.gz
Backup finished...
Downloading latest release version...
Problem downloading new Domoticz version!!. Restarting current version...
pi@EnergyPi:~/domoticz $/code]
lwolf
Posts: 216
Joined: Saturday 10 November 2018 18:29
Target OS: Raspberry Pi / ODroid
Domoticz version:
Location: Hungary
Contact:

Re: Domoticz server denies access by some APIs

Post by lwolf »

roelvdh wrote: Tuesday 30 January 2024 20:55

Code: Select all

2024-01-30 20:49:35.138 Error: Tado systeem: Failed to retrieve API environment from https://my.tado.com/webapp/env.js
2024-01-30 20:49:42.474 Error: Weerkanaal: Error getting http data!
This may not be a Domoticz problem but I am out of options so maybe someone has a quick fix?
Try to ssh into the Raspberry and exec the commands below:

Code: Select all

ping 8.8.8.8
If this shows that 8.8.8.8 is reachable you have a working ip gateway.

Code: Select all

ping www.google.com
If the first command work, but this one said www.google.com is not reachable: your network DNS settings failed, and this is not a Domoticz problem, but system-wide.
willemd
Posts: 621
Joined: Saturday 21 September 2019 17:55
Target OS: Raspberry Pi / ODroid
Domoticz version: 2024.1
Location: The Netherlands
Contact:

Re: Domoticz server denies access by some APIs

Post by willemd »

First thing to do is a router reset. Usually when my domoticz system has trouble accessing other internal systems, it is a router issue.
roelvdh
Posts: 37
Joined: Saturday 18 January 2020 13:40
Target OS: Raspberry Pi / ODroid
Domoticz version: 2024.7
Location: NL
Contact:

Re: Domoticz server denies access by some APIs

Post by roelvdh »

Sure, that works normally. In this case I think something went wrong after installing Domoticz 2024.2. The internal web server works fine for ports 8080 and 443 (internal network) but refuses external connections via port 80, and even internally from my Windows machine on the same network:

Code: Select all

C:\Users\Gebruiker>telnet EnergyPi.local 80
Er wordt verbinding gemaakt met EnergyPi.local...Kan geen verbinding met de host maken, op poort 80: Het maken van de verbinding is mislukt
:\Users\Gebruiker>
I will completely uninstall Domoticz and re-install with the Stable version issued yesterday.
User avatar
waltervl
Posts: 5148
Joined: Monday 28 January 2019 18:48
Target OS: Linux
Domoticz version: 2024.7
Location: NL
Contact:

Re: Domoticz server denies access by some APIs

Post by waltervl »

Because there is nothing on port 80 from Domoticz. So why do you want to use port 80? A reinstall will not fix this.....
Domoticz running on Udoo X86 (on Ubuntu)
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
roelvdh
Posts: 37
Joined: Saturday 18 January 2020 13:40
Target OS: Raspberry Pi / ODroid
Domoticz version: 2024.7
Location: NL
Contact:

Re: Domoticz server denies access by some APIs

Post by roelvdh »

Indeed, https://my.tado.com/webapp/env.js will use port 443, but WeatherChannel probably uses port 80 as per the error message. I am still confused why these services suddenly stopped working without any changes from my side besides updating Domoticz.
User avatar
waltervl
Posts: 5148
Joined: Monday 28 January 2019 18:48
Target OS: Linux
Domoticz version: 2024.7
Location: NL
Contact:

Re: Domoticz server denies access by some APIs

Post by waltervl »

The internal Domoticz webserver has nothing to do with Domoticz server not able to contact your tado website or your weather channel.
Can you telnet from your Domoticz server to weatherchannel or tado? If not something is wrong in your network settings , could also be on the Domoticz server itself but also on a firewall or router.
Domoticz running on Udoo X86 (on Ubuntu)
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
roelvdh
Posts: 37
Joined: Saturday 18 January 2020 13:40
Target OS: Raspberry Pi / ODroid
Domoticz version: 2024.7
Location: NL
Contact:

Re: Domoticz server denies access by some APIs

Post by roelvdh »

Solved. I decided the problem must be in the RPi, so I rebuilt the RPi from scratch and put back my existing Domoticz files. That worked. I still assume something must have happened to the RPi when upgrading to Domoticz 2024.2, but I leave that for now. You were right about the internal web server: it serves pages but does not communicate with APIs. Thanks for helping me out.
roelvdh
Posts: 37
Joined: Saturday 18 January 2020 13:40
Target OS: Raspberry Pi / ODroid
Domoticz version: 2024.7
Location: NL
Contact:

Re: Domoticz server denies access by some APIs

Post by roelvdh »

I called it solved and it was, but now I made the same error again and now I understand what happened. Problem was I had changed the hostname of the RPi. That's the way I work: start an upgrade on another RPi and when it works OK, change back the hostname. But that makes existing calls to external APIs invalid, so it seems. Probably a cache problem somewhere. Now really solved!
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest