I’m trying to write an automation which will respond to an RF button.
The RF bridge that posts MQTT. I’m trying to create an automation, which will fire on the MQTT topic RF_Bridge/tele/RESULT and then extract the actual data from the trigger.payload_json which looks like
{‘RfReceived’: {‘Sync’: 10290, ‘Low’: 340, ‘High’: 980, ‘Data’: ‘0E1932’, ‘RfKey’: 1}}
‘Data’ identifies which rf button was pressed, and I need to set different actions based on that value.
So far, I’m just using a notification with message: “{{ trigger.payload_json }}” which produces the string above. I’ve tried “{{ trigger.payload_json.Data }}” and “{{ trigger.payload_json.attributes[‘Data’] }}” but I just get an empty message.