Skip to content

Instantly share code, notes, and snippets.

@andersonimes
Created August 24, 2025 14:36
Show Gist options
  • Save andersonimes/7bf331ce730cd8c5f9cde2abbebddd9c to your computer and use it in GitHub Desktop.
Save andersonimes/7bf331ce730cd8c5f9cde2abbebddd9c to your computer and use it in GitHub Desktop.
blueprint:
name: Moisture Sensor
description: Perform action when moisture sensor turns wet
domain: automation
input:
actions:
name: Actions
description: Notifications or similar to be run.
{{ trigger.event.data.new_state.attributes.friendly_name }} will be the name of the
sensor
selector:
action: {}
trigger:
- event_data: {}
event_type: state_changed
platform: event
condition:
- condition: template
value_template: '{{ trigger.event.data.new_state.attributes.device_class == "moisture" }}'
- condition: template
value_template: '{{ trigger.event.data.new_state.state == "on" }}'
action:
- choose: []
default: !input 'actions'
mode: single
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment