Is there a trigger or sensor that happen when home assistant has finished startup (every thing started) not the startup trigger it seems to happen before everything has loaded
So do i but there a message on the screen that disappears when it finishes it would be great to beable to trigger from that!!
Hmm, that’s how this trigger works for me. The actions don’t execute until the same time the toast message about starting up disappears.
trigger:
- platform: homeassistant
event: start
As an experiment while I was restarting for the HACS update, I also went in to the developer tools and listened for the event homeassistant_started
and it also fired when the start up message disappeared. So maybe you could use an event trigger instead?
There was another one called homeassistant_start
, which I assume would fire at the beginning of startup.
I might be using start will see if I can find started (thought there would be one)
I get this what am i doing wrong
It did have start in it & was working
dont know how to get to the started option
Use an Event Trigger to detect the homeassistant_started
event.
platform: event
event_type: homeassistant_started
ok it takes that I will see if it makes a difference thanks
must be another issue the alex notfy still fails if I dont have the delay in the automation
do you know if theres a way to tell if the alex app is running (seems you can tell with addons)
According to the documentation link I posted above, the homeassistant_started
event occurs after the homeassistant_start
event.
In other words, all integrations have been loaded. I relied on that behavior to create a Graceful Shutdown Sensor. It’s a Template Sensor so the Template integration must be loaded in order for it to detect the homeassistant_started
event (it can’t detect the homeassistant_start
event).
i dont get why the alex notify fails at startup without the delay
What’s “alex notify”?
its the “alexa media player” intergration that allow you to send a message (notify) to your alexa devices
In what way is the Alexa Media Player integration “failing at startup” unless you include a delay? Are you trying to make it notify you after all integrations have been loaded?
Post the automation you have created.
alias: bondhome started
description: ""
trigger:
- platform: event
event_type: homeassistant_started
- platform: homeassistant
event: start
enabled: false
condition: []
action:
- delay:
hours: 0
minutes: 0
seconds: 10
milliseconds: 0
enabled: false
- data:
data:
method: all
type: announce
target:
- media_player.lounge_echo_dot
- media_player.lounge_tv_cube
- media_player.kitchen_echo_dot
- media_player.spare_echo_dot_dining
- media_player.loung_show_8_2nd_gen
message: Home assistance has started
action: notify.alexa_media
mode: single
This is what I now have but it does not appear to tigger when using the other one it needs the delay I also would like to know if its possible to stop & start an interation on startup and shutdown as my 3d printer more often than not are switch off when HA starts so it waiste time looking for them
As an experiment, try this automation. It should post a persistent notification on startup.
alias: Startup Monitor
description: For testing purposes.
mode: single
trigger:
- platform: event
event_type: homeassistant_started
condition: []
action:
- action: notify.persistent_notification
data:
title: "{{ now().timestamp()|timestamp_custom() }}"
message: Home Assistant started.
It appears that sometimes the Alexa Media integration isn’t immediately available on startup. It’s a custom integration so you will need to check with whoever is maintaining it. It’s my understanding that it has been orphaned by its original author and volunteers are attempting to keep it operational.
EDIT
Correction. condition
not conditions
.
well thats a big shame! (thanks anyway)
Let me know if the automation I suggested works for you.
If it does then it means that the problem you are encountering (that you need a delay
after startup is detected) is due to the Alexa Media integration not being ready immediately after startup.
no that appear to do nothing just did not run as far as i could tell (just gone back to the delay option for now)