I'm looking to call domoticz API from inside a plugin writen with the Python Framework.
While I think it is easy to call http://127.0.0.1/json.htm I'm looking for way to get the port where the Domoticz server is listening too ?
Using Domoticz API from inside a plugin
Moderator: leecollings
- waaren
- Posts: 6028
- Joined: Tuesday 03 January 2017 14:18
- Target OS: Linux
- Domoticz version: Beta
- Location: Netherlands
- Contact:
Re: Using Domoticz API from inside a plugin
I have no clue whatsoever how the Python Framework interact with the main domoticz code but dzVents calls m_webservers.our_listener_port from main/WebServerHelper.cpp and this helper gets it from web_settings.listening_port;pipiche wrote: Tuesday 11 June 2019 21:32 I'm looking to call domoticz API from inside a plugin writen with the Python Framework.
While I think it is easy to call http://127.0.0.1/json.htm I'm looking for way to get the port where the Domoticz server is listening too ?
Debian buster, bullseye on RPI-4, Intel NUC.
dz Beta, Z-Wave, RFLink, RFXtrx433e, P1, Youless, Hue, Yeelight, Xiaomi, MQTT
==>> dzVents wiki
dz Beta, Z-Wave, RFLink, RFXtrx433e, P1, Youless, Hue, Yeelight, Xiaomi, MQTT
==>> dzVents wiki
Re: Using Domoticz API from inside a plugin
Thanks waaren, but unfortunatly not available inside the Framework.