###################################
##  Start Up Section
###################################

- alias: Startup Notification and Shut startup lights

  trigger:
    - platform: homeassistant
      event: start
  action:
    - service: script.notify_engine
      data_template:
        title: 'Home Assistant StartUp'
        value1: 'Home Assistant is Up and Running!'
        who: 'carlo'

    - service: light.turn_off
      entity_id: group.hallway_lights

    - service: mqtt.publish
      data:
        topic: "garadget/Garadget Small/command"
        payload: "get-status"

    - service: mqtt.publish
      data:
        topic: "garadget/Garadget Large/command"
        payload: "get-status"

    - service: notify.alexa_media
      data:
        target:
          - media_player.office
          - media_player.kitchen
        title: "Home Assistant Restarted"
        data:
          type: announce
          #method: all
        message: "Home Assistant has been restarted."