Last active
May 4, 2020 14:55
-
-
Save tongphe/9c907f3ee1c25a0e308eb7ca19a4ed04 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- id: notify_bad_login | |
alias: Send notification failed login attempt | |
initial_state: true | |
trigger: | |
- platform: state | |
entity_id: persistent_notification.http_login | |
condition: | |
- condition: template | |
value_template: '{{ trigger.to_state.state != ''None'' }}' | |
action: | |
- service: notify.telegram | |
data_template: | |
message: '{{ states.persistent_notification.http_login.attributes.message }}' | |
- service: persistent_notification.dismiss | |
data: | |
notification_id: http_login |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment