Hi, I’m trying to convert a HA automation into Node Red, but I’m still new and don’t know how to manage this.
This automation is working:
- id: '1590223080774'
alias: Presence - Home based on Netatmo John
description: ''
trigger:
- event_data:
type: person
event_type: netatmo_event
platform: event
condition:
- condition: template
value_template: '{{ trigger.event.data["data"]["name"] == ''John'' }}
'
action:
- data:
dev_id: virtual_john
location_name: home
service: device_tracker.see
I figured I should use the events: all node to trigger, but I can only get to the level of netatmo_event (and not the sublevel ‘person’ like in the automation.
I used the debugger in node red and the following data comes out of the event:all trigger. I want to retrieve the “name” from this message, but I cannot get it to work. Can anybody help?
(sorry for the long code block. Don’t know how to do it otherwise).