input_text: alexa_actionable_notification: name: Alexa Actionable Notification Holder max: 255 initial: '{"text": "This is a test of the alexa actions custom skill. Did it work?", "event": "actionable.skill.test"}' intent_script: ActivateSceneIntent: action: service: input_select.select_option target: entity_id: input_select.{{ Room | replace(" ","_") }}_scenes data: option: "{{ Scene | title }}" speech: text: "Scene is set to {{ Scene }}" automation: - id: 31169983-7a5d-4533-a5f7-172a36339931 alias: Furnace Room Light Reminder trigger: platform: state entity_id: light.furnace_room_overhead to: "on" for: minutes: 15 action: - service: script.activate_alexa_actionable_notification data_template: text: 'The furnace room light is on, should I turn it off?' event_id: 'actionable_notification_furnace_room_light_on' alexa_device: 'media_player.basement_echo_dot' - id: 28a97594-eba9-4bcc-afa4-c161b87fa065 alias: Turn off Furnace Room Light via Actionable Notification trigger: platform: event event_type: alexa_actionable_notification event_data: event_id: actionable_notification_furnace_room_light_on event_response_type: ResponseYes action: - service: light.turn_off entity_id: light.furnace_room_overhead - id: 922740c8-0c23-4e71-81a8-f88de8b2a8ae alias: Shut down computer at end of night trigger: - platform: event event_type: alexa_actionable_notification event_data: event_id: actionable_notification_shutdown_computer event_response_type: ResponseYes id: shutdown-yes - platform: event event_type: alexa_actionable_notification event_data: event_id: actionable_notification_shutdown_computer event_response_type: ResponseNo id: shutdown-no action: - if: - condition: trigger id: shutdown-yes then: - service: script.tony_desktop_shutdown - if: - condition: trigger id: shutdown-no then: - service: script.tony_desktop_lock - id: 21f6ee35-797e-4066-8f0e-cad964cb0f26 alias: Boot up Kallen computer when basement on trigger: - platform: event event_type: alexa_actionable_notification event_data: event_id: actionable_notification_kallen_computer_on event_response_type: ResponseYes action: - service: script.kallen_desktop_wake - id: d1edfcf7-2712-49f4-b8f1-17f5b184b5ce alias: Arm security on Give Me Darkness trigger: - platform: event event_type: alexa_actionable_notification event_data: event_id: actionable_notification_night_security_arm event_response_type: ResponseYes id: security-yes - platform: event event_type: alexa_actionable_notification event_data: event_id: actionable_notification_night_security_arm event_response_type: ResponseNo id: security-no action: - if: - condition: trigger id: security-yes then: - service: script.security_arm_home - delay: seconds: 1 - service: script.speech_engine data: who: "{{ states('sensor.last_alexa') }}" message: > {{ [ "Security is armed, guard dogs deployed, and lasers set from stun to kill!", "The security system is armed. Sentry turrets active, be careful out there!", "Your security is our number one priority. Flamethrower turrets deployed!" ] | random }} - if: - condition: trigger id: security-no then: - service: script.speech_engine data: who: "{{ states('sensor.last_alexa') }}" message: > {{ [ "Security squadron is standing down, but always at your service!", "Our security forces are currently twiddling their thumbs, awaiting some purpose in their life!", "Security not armed. Hopefully the defense turrets do not become bored!" ] | random }} script: activate_alexa_actionable_notification: description: 'Activates an actionable notification on a specific echo device' fields: text: description: 'The text you would like alexa to speak.' example: 'What would you like your thermostat set to?' event_id: description: 'Correlation ID for event responses' example: 'ask_for_temperature' alexa_device: description: 'Alexa device you want to trigger' example: 'media_player.living_room_echo_dot' sequence: - service: input_text.set_value data: entity_id: input_text.alexa_actionable_notification value: '{"text": "{{ text }}", "event": "{{ event_id }}"}' - service: media_player.play_media data: entity_id: "{{ alexa_device }}" media_content_type: skill media_content_id: !secret alexa_actionable_notifications_skill_key