
Hi,
I have a flow which stores the state of a Philips Hue lamp (a JSON string), changes the light and then restores the initial state after a certain delay.
For now I have to put all the key values manually into the template node ("Reset previous state") like this (there are initially more then those values, when requesting the state):
Template-Node ("Reset previous state"):
{
"on" : {{payload.state.on}},
"bri" : "{{payload.state.bri}}",
"hue" : {{payload.state.hue}},
"sat" : {{payload.state.sat}},
"effect" : "{{payload.state.effect}}",
"xy" : [{{payload.state.xy}}],
"ct" : {{payload.state.ct}},
"alert" : "{{payload.state.alert}}",
"colormode" : "{{payload.state.colormode}}"
}
Is it possible to put the whole msg.payload/ JSON-string from the hue state node ("NodeLamp Status") into the template node, without explicitly listing all the key values manually, so that the msg.payload acts like putting a string into the template node?
Best,
Markus