This is an example URL for what I’m going to send:
(http://192.168.1.100:9876/nodered.html?1=Nettradio&2=6&3=1&4=SECRET_PASSWORD)
This sends a command to Promixis Girder (yeah, it’s old, but so am I!) It’s totally stable (which I may not be) and I like to program in LUA. I have around 8000 lines of code in it, and I really don’t fancy doing all my stuff again, when it works perfectly. In this case it runs web radio (“Nettradio”) in zone 6 (the bathroom) with channel 1 (Norwegian NRK P1). This is done with Foobar, which also is totally stable. I am triggering it from a webpage directly in Girder, but I want to trigger it with Namron K8 8 channel Z-Wave switches in the different rooms as well. This would then go from Z-Wave JS UI to Hass, where the same button does a few other things, depending on the room. And I’d use a template to translate the button pressed to the correct zone and channel.
I have gotten the setup to work on a few test channels, but to send the commands from Hass is too messy. I have to send MQTT from Hass to Node-RED, which then POSTs to Girder. I’d like to run it directly from Hass.
I have tried to read a bit around and it seems like REST is the thing that can do this. But if I have understood that correctly, I would have to have separate entries in configuration.yaml for each command, which is very messy. Or have I misunderstood? I have tried to look for a HTTP/REST plug-in that can do this more elegantly, but I haven’t found one. Does this mean that the multiple entries in configuration.yaml is the only way? I have 12 zones at the cabin and 16 in the house, and each can take 16 radio channels (by long pressing the buttons). That means that I would have 192 and 256 entries in the yaml file.