I’m trying to use the sendHttpPutRequest command to select a scene saved on the Hue bridge.
When I use the /debug/clip.html the Put request works fine, but I’m struggling to get the right format for adding it to a hue rule.
I’ve seen that the format should be:
sendHttpPutRequest(String url, String contentType, String content)
I’m unclear on what to put for String contentType
Grateful for any help in fixing this.
rule looks like:
rule "Set lights"
when
Item lgNightLight received command
then
switch(receivedCommand) {
case ON : sendHttpPutRequest(http:///api//groups/1/action/,‘Content-Type’: ‘text/plain’,“scene”: “”)
case OFF : sendHttpPutRequest(http:///api//groups/1/action/,‘Content-Type’: ‘text/plain’,“scene”: )
end