Looking to add some more data to the notifications i received on my phone of when the gate is opened. Id like to add which user device triggered opening the gate and time. (I have 10 users on our house and it will be nice to get some more info when gate is opened)
Thanks a lot in advance!
here other photo of the same automation, it works but looking to add some more info to the notification, any help is greatly appreciate
FAQ Guideline 11 - Format it properly
FAQ Guideline 14 - Screenshots
Don’t post a screenshot of the automation, post it in YAML format.
Sorry im new here, but here of the yaml
alias: Opening Ace Link Gate
- platform: state
- service: notify.mobile_app_s23_ultra_jonnathan
message: "Opening Ace Gate by "
You might want to read up on this:
If someone manually opens the gate (via its control switch), Home Assistant has no way of knowing that person’s identity.
If they open the gate via Home Assistant’s UI, then their identity is known. However, the process of determining their identity requires a bit of work.
trigger variable contains a
context property and it contains three other properties:
user_id. Depending on the values of these three properties, you can determine if the
cover was activated manually, by another script/automation, or by a user. Multiple conditions are used to make this determination (here’s an example to determine if the entity was manually controlled).
If it was activated by a user, the only thing it will report is a
user_id (containing a long alphanumeric string).
The final step in the process is to identify which
person entity has a matching
user_id and that entity contains the person’s name. Alternately, if you’re not using
person entities, you can create a hard-coded cross-reference table of user_ids and names (example).
Amazing! it works amazing! Thanks a lot for the quick turn around!