dzvents - openurl - postdata
Posted: Tuesday 25 June 2019 23:18
Domoticz V4.10717
Plateform : Rpi 3
OS : Raspbian stretch
Hello,
I'm struggling while trying to sent a command to my Philips TV, for example, to set to volume to a given value with the OpenUrl command.
- The URL that has to be used is something like : http://ip-address:1925/1/audio/volume
- The method that should be used is POST
- I guess the parameters intended to my tv should be set in the postdata parameter of the OpenUrl command.
The postdata should be a JSON object ressembling to :
{
"muted": false,
"current": 18
}
This is relatively well documented here:
http://jointspace.sourceforge.net/proje ... -POST.html
However, when I use the domoticz.OpenUrl command, the data shown in the postdata is always empty, whatever the syntax I use to specify the JSON object.
Did someone already face this kind of issues with the openurl command, or does anyone have a example of how he dealed with sending commands to a Philips TV ?
I have tried out more or less all I could think about, unfortunately, still unsuccessfull.
If I do the same without postdata and with the GET method (to get the current volume), this runs fine, so the URL is most probably correct.
Thank you so much to the one(s) who could help me there. I'm trying to find out the solution over 3 days. Now, I'm out of ideas
Plateform : Rpi 3
OS : Raspbian stretch
Hello,
I'm struggling while trying to sent a command to my Philips TV, for example, to set to volume to a given value with the OpenUrl command.
- The URL that has to be used is something like : http://ip-address:1925/1/audio/volume
- The method that should be used is POST
- I guess the parameters intended to my tv should be set in the postdata parameter of the OpenUrl command.
The postdata should be a JSON object ressembling to :
{
"muted": false,
"current": 18
}
This is relatively well documented here:
http://jointspace.sourceforge.net/proje ... -POST.html
However, when I use the domoticz.OpenUrl command, the data shown in the postdata is always empty, whatever the syntax I use to specify the JSON object.
Did someone already face this kind of issues with the openurl command, or does anyone have a example of how he dealed with sending commands to a Philips TV ?
I have tried out more or less all I could think about, unfortunately, still unsuccessfull.
If I do the same without postdata and with the GET method (to get the current volume), this runs fine, so the URL is most probably correct.
Thank you so much to the one(s) who could help me there. I'm trying to find out the solution over 3 days. Now, I'm out of ideas