I have defined 2 rest commands to send text to my wled.
rest_command:
wled_text1:
url: http://192.168.111.215/json/state
method: POST
payload: '{"seg":[{"n": "{{text}}","id":0}]}'
wled_text2:
url: http://192.168.111.215/json/state
method: POST
payload: '{"seg":[{"n": "{{text}}","id":1}]}'
When I’m trying to use them everything is working…
action: rest_command.wled_text1
data: {
text: Welcome to the MATRIX!!!
}
But when I’m trying to send some data from oter devices (weather forecast data for example) it’s not working:
action: rest_command.wled_text1
data: {
text: {{ state_attr('weather.forecast_dom','temperature') }}
}
HA says that there is some syntax error…
Can anyone help me with that problem?