I use the automation below to inform me when HA has stopped and started.
It SEEMS TO ME that sometimes it takes for ever and other times just a minute or so.
Is there a way to track (calculate) the time that it took from start to stop and tell me in my notification.
Thank you for the help.
#########################################################
# HOME ASSISTANT START #
#########################################################
- alias: Home Assistant Started
trigger:
platform: homeassistant
event: start
action:
- service: notify.telegram_carlton
data:
title: "Home Assistant Started"
message: "Home Assistant Has Started as of {{ now().strftime('%A, %B %d, %Y %I:%M:%S %p') }}"
- delay:
minutes: 1
- service: homeassistant.turn_on
entity_id: automation.addon_update_available
#########################################################
# HOME ASSISTANT STOP #
#########################################################
- alias: Home Assistant Stopped
trigger:
platform: homeassistant
event: shutdown
action:
- service: notify.telegram_carlton
data:
title: "Home Assistant Stopped"
message: "Home Assistant Has Stopped as of {{ now().strftime('%A, %B %d, %Y %I:%M:%S %p') }}"
####################################################
# END OF CONFIGURATION FILE #
####################################################