Hi All,
I’ve just updated to the latest release 0.36.1 and was pleased to see rest_commands added, which prompted me to move my (non notify rest commands) away from the notify configuration and into the rest_command configuration which was more logical. Here comes the but…
I don’t seem to be able to change the url or payload for a get request using a script or developer tools…
rest_command:
myapi_demo:
url: 'http://api.domain.com/'
Selecting the rest_command domain and myapi_demo from the developer tools the REST command fires but I cannot seem to change the url or more importantly the payload for a get command? Equally, if I use a script in the same way I would have set the parameters for a notify REST they don’t seem to work for the new rest command. I’m going to try templates next but the trouble is I don’t want to use data from another sensor but use literal hard coded data passed in through a script or automation.
I suspect this might just be my understanding of how this works but it’s a real shame the example doc does not give an example to clear this up.
Will update here if I get this fixed but hopefully someone can shed some light on this?
Using the following JSON not working:
{ "payload" : "?parama=123¶mb=456" }
Hopefully someone else is having this problem but my Forum and chat search having turned up anything yet.