-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathautomations.yaml
1390 lines (1389 loc) · 39.5 KB
/
automations.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
- id: '1609443032391'
alias: 'Tesla: Charging at home'
description: ''
trigger:
- platform: state
entity_id: device_tracker.tesla_location_tracker
to: home
from: not_home
for:
hours: 0
minutes: 15
seconds: 0
condition:
- condition: state
entity_id: binary_sensor.tesla_charger_sensor
state: 'off'
action:
- service: notify.notify
data:
message: Tesla is not charging!
mode: single
- id: '1610935846736'
alias: HomeAssistant Shutdown
description: ''
trigger:
- platform: homeassistant
event: shutdown
condition: []
action:
- service: notify.mobile_app_matts_iphone
data:
message: HomeAssistant is shutting down!
mode: single
- id: '1610935910066'
alias: HomeAssistant Restarted
description: ''
trigger:
- platform: homeassistant
event: start
condition: []
action:
- service: notify.mobile_app_matts_iphone
data:
message: HomeAsistant restarted!
- service: script.reset_system_on_restart
mode: single
- id: '1621807402601'
alias: Energy saver (everyone away)
description: ''
trigger:
- platform: state
entity_id: device_tracker.life360_anna
from: home
to: not_home
- platform: state
entity_id: device_tracker.life360_julie_kotler
from: home
to: not_home
- platform: state
entity_id: device_tracker.life360_katie
from: home
to: not_home
- platform: state
entity_id: device_tracker.life360_matt
from: home
to: not_home
condition:
- condition: and
conditions:
- condition: template
value_template: '{% if not is_state(''device_tracker.life360_anna'', ''home'')
%}true{%else%}false{%endif%}'
- condition: template
value_template: '{% if not is_state(''device_tracker.life360_julie_kotler'',
''home'') %}true{%else%}false{%endif%}'
- condition: template
value_template: '{% if not is_state(''device_tracker.life360_matt'', ''home'')
%}true{%else%}false{%endif%}'
- condition: template
value_template: '{% if not is_state(''device_tracker.life360_katie'', ''home'')
%}true{%else%}false{%endif%}'
- condition: state
entity_id: input_boolean.guestroom_in_use
state: 'off'
action:
- device_id: 42ab0e799b3a0660d840520e3e64f283
domain: climate
entity_id: climate.master_bedroom
type: set_preset_mode
preset_mode: Away
- device_id: 2d1a500f9a7fee5518963d35f32d5307
domain: climate
entity_id: climate.downstairs_hall
type: set_preset_mode
preset_mode: Away
- service: script.turn_off_all_lights
data: {}
- service: script.turn_off_all_upstairs_lights_except_kids
data: {}
- service: script.turn_off_kids_lights
data: {}
- type: turn_off
device_id: 894bb86f8d542d016d773a9c3f30358d
entity_id: switch.master_fireplace
domain: switch
mode: single
- id: '1621807523686'
alias: Energy saver (welcome home)
description: ''
trigger:
- platform: state
entity_id: device_tracker.life360_anna
to: Home
attribute: place
- platform: state
entity_id: device_tracker.life360_julie_kotler
to: Home
attribute: place
- platform: state
entity_id: device_tracker.life360_katie
to: Home
attribute: place
- platform: state
entity_id: device_tracker.life360_matt
to: Home
attribute: place
condition: []
action:
- device_id: 42ab0e799b3a0660d840520e3e64f283
domain: climate
entity_id: climate.master_bedroom
type: set_preset_mode
preset_mode: Home
- device_id: 2d1a500f9a7fee5518963d35f32d5307
domain: climate
entity_id: climate.downstairs_hall
type: set_preset_mode
preset_mode: Home
- service: switch.turn_on
target:
entity_id:
- switch.garage_lights
data: {}
- choose:
- conditions:
- condition: numeric_state
entity_id: sun.sun
attribute: elevation
below: '6'
sequence:
- service: switch.turn_on
target:
entity_id:
- switch.front_porch_lights
- switch.laundry_room_lights
data: {}
default: []
mode: queued
max: 10
- id: '1622433479281'
alias: 'Anna''s Room: Turn off when Anna leaves'
description: ''
trigger:
- platform: state
entity_id: device_tracker.life360_anna
from: home
to: not_home
condition: []
action:
- type: turn_off
device_id: d8c1e1f1292a82d5ff174bbec10f80a5
entity_id: switch.annas_room_closet_light
domain: switch
- type: turn_off
device_id: d8c1e1f1292a82d5ff174bbec10f80a5
entity_id: switch.annas_room_overhead_light
domain: switch
- condition: template
value_template: '{% if not is_state(''device_tracker.life360_katie'', ''home'')
%}true{%else%}false{%endif%}'
- type: turn_off
device_id: cfe3edbb953f6b6e2a9de89d980b3502
entity_id: switch.katies_room_lights
domain: switch
- type: turn_off
device_id: 2c4da0e1ab2882801b43c83cc4ad40cf
entity_id: switch.kids_toilet_light
domain: switch
- type: turn_off
device_id: 2c4da0e1ab2882801b43c83cc4ad40cf
entity_id: switch.kids_toilet_heat_lamp
domain: switch
- condition: state
entity_id: input_boolean.guestroom_in_use
state: 'off'
- type: turn_off
device_id: 05e41542a9224aac321fbf76508b0fe5
entity_id: switch.guest_bathroom_lights
domain: switch
- type: turn_off
device_id: 05e41542a9224aac321fbf76508b0fe5
entity_id: switch.guest_bathroom_heat_lamp
domain: switch
mode: single
- id: '1623539585816'
alias: 'Announcement: Someone is almost home'
description: ''
trigger:
- platform: state
entity_id: device_tracker.life360_anna
attribute: place
to: Home
id: Anna
- platform: state
entity_id: device_tracker.life360_julie_kotler
id: Mom
to: Home
- platform: state
entity_id: device_tracker.life360_katie
id: Katie
to: Home
- platform: state
entity_id: device_tracker.life360_matt
id: Dad
to: Home
condition: []
action:
- service: notify.alexa_media_kitchen_alexa
data:
data:
type: announce
method: speak
message: '{{ trigger.id }} is almost home'
mode: single
- id: '1624618838472'
alias: 'Matt’s iPhone: Storage Warning'
description: ''
trigger:
- platform: numeric_state
entity_id: sensor.matts_iphone_storage
below: '0.5'
condition: []
action:
- service: notify.mobile_app_matts_iphone
data:
message: 'Warning: Your phone’s storage space is low'
mode: single
- id: '1624690742681'
alias: 'Family Room Lamp: Turn on when turn on family room lights manually'
description: ''
trigger:
- platform: device
type: turned_on
device_id: 19bb98b06940d043ed1bb0152485f0c7
entity_id: light.family_room_light
domain: light
condition: []
action:
- type: turn_on
device_id: 861e337a796679e71de4e3bb44fe864a
entity_id: switch.family_room_lamp
domain: switch
mode: single
- id: '1624690821908'
alias: 'Family Room Lamp: Turn off when turn off family room lights manually'
description: ''
trigger:
- platform: state
entity_id: light.family_room_light
from: 'on'
to: 'off'
condition: []
action:
- type: turn_off
device_id: 861e337a796679e71de4e3bb44fe864a
entity_id: switch.family_room_lamp
domain: switch
mode: single
- id: '1625478716821'
alias: 'Announcement: Left door open'
description: ''
trigger:
- platform: state
entity_id: binary_sensor.front_door
id: front door
to: 'on'
for:
hours: 0
minutes: 5
seconds: 0
- platform: state
entity_id: binary_sensor.inside_garage_door
id: door into the garage
to: 'on'
for:
hours: 0
minutes: 5
seconds: 0
- platform: state
entity_id: binary_sensor.kitchen_sliding_door
id: sliding door
to: 'on'
for: 00:15:00
- platform: state
entity_id: binary_sensor.outside_garage_door
id: door to the dog run
to: 'on'
for: 00:15:00
- platform: device
device_id: 126611f2ed378ebe7c139b2543132f69
domain: cover
entity_id: cover.garage_door
type: opened
id: garage door
for:
hours: 0
minutes: 10
seconds: 0
variables:
action_close: '{{"CLOSE_" ~ trigger.to_state.context.id}}'
condition: []
action:
- choose:
- conditions:
- condition: template
value_template: '{{ trigger.to_state.state|int(0) == 0 }}'
sequence:
- choose:
- conditions:
- condition: trigger
id: garage door
sequence:
- service: notify.alexa_media_kitchen_alexa
data:
data:
type: announce
method: speak
message: Did you forget to close the {{ trigger.id }}?
- service: notify.mobile_app_matts_iphone
data:
message: Did you forget to close the {{ trigger.id }}?
data:
actions:
- action: '{{ action_close }}'
title: Close Garage Door
- wait_for_trigger:
- platform: event
event_type: mobile_app_notification_action
event_data:
action: '{{ action_close }}'
- choose:
- conditions:
- condition: template
value_template: '{{ ("CLOSE_" ~ trigger.to_state.context.id) == action_close
}}'
sequence:
- device_id: 126611f2ed378ebe7c139b2543132f69
domain: cover
entity_id: cover.garage_door
type: close
default: []
default:
- service: notify.alexa_media_kitchen_alexa
data:
data:
type: tts
message: "{% set door = trigger.id %} {% set messages = \n [\"Surprise\
\ surprise, the \" ~ door ~ \" is open\", \n \"Roses are <prosody\
\ pitch='medium'>red</prosody>, violets are blue, the \" ~ door ~ \"\
\ is open, but I still <prosody pitch='medium'>love you</prosody>\"\
,\n \"Really? I just closed it. Your turn. The \" ~ door ~ \" is\
\ open.\",\n \"Oops! You did <say-as interpret-as='interjection'>it</say-as>\
\ again. The \" ~ door ~ \" is open.\",\n \"<prosody rate='fast'>Knock<prosody\
\ pitch='high'>knock</prosody></prosody><voice name='Joey'>Who's there?</voice>Clothes.<voice\
\ name='Joey'>Clothes <prosody pitch='high'>who?</prosody></voice>Close\
\ the <say-as interpret-as='expletive'>fricking</say-as> \" ~ door,\
\ \n \"For the billionth time, close the \" ~ door, \n \"The \"\
\ ~ door ~ \" is a jar. <voice name='Joey'>A <prosody pitch='high'>what?</prosody></voice>A\
\ jar. Close it!\",\n \"The barn door is open. Wait, that's not right.\
\ It's the \" ~ door,\n \"Are we at a seder? You didn't need to leave\
\ the \" ~ door ~ \" open for elijah.\",\n \"Please, for the sake\
\ of everything that is holy, will you close the \" ~ door, \n \"\
Stop letting all the cold air in! Close the \" ~ door, \n \"If I've\
\ asked you once, I've asked you a thousand times. Close the \" ~ door,\n\
\ \"Pretty please with sugar on top. Will you close the \" ~ door\
\ ~ \"?\",\n \"Would it kill you to close the \" ~ door ~ \"?\",\n\
\ \"The \" ~ door ~ \" is open. Tag, you're it.\",\n \"You want\
\ the <prosody pitch='50%'>truth</prosody>? <prosody pitch='50%' rate='x-slow'>You</prosody>\
\ can't handle the <prosody pitch='-20%'> truth!</prosody> The \" ~\
\ door ~ \" is open.\",\n \"If you were the \" ~ door ~ \"<break\
\ time='500ms' />would you want to still be open? <break time='700ms'\
\ />I didn't <emphasis level='moderate'>think</emphasis> <prosody rate='fast'>so</prosody>.\"\
,\n \"If I had just one wish, it would be that you would close the\
\ \" ~ door,\n \"This place is going downhill fast. The \" ~ door\
\ ~ \" is still open!\", \n \"Hey! I'm talking to you. Stop messing\
\ around. The \" ~ door ~ \" is open.\"] \n%} {% set rand = range(0,\
\ messages | count) | random %} {{ messages[rand] }}\n"
- service: notify.mobile_app_matts_iphone
data:
message: Did you forget to close the {{ trigger.id }}?
mode: single
- id: '1630504836253'
alias: 'Office: Turn on desk lamp when turn on lights manually'
description: ''
trigger:
- platform: device
type: turned_on
device_id: 21d2904ab5e4e63611f6304cbdbcf15b
entity_id: light.office_light
domain: light
condition:
- condition: template
value_template: '{{ trigger.to_state.context.parent_id is none }}'
action:
- type: turn_on
device_id: 52a568acd1f3b04f9214c056c506d39b
entity_id: switch.office_lamp
domain: switch
- service: input_text.set_value
target:
entity_id:
- input_text.office_lamp_why_on
data:
value: 'Office: Turn on desk lamp when turn on lights'
mode: single
- id: '1630504880049'
alias: 'Office: Turn off desk lamp when turn off lights manually'
description: ''
trigger:
- platform: device
type: turned_off
device_id: 21d2904ab5e4e63611f6304cbdbcf15b
entity_id: light.office_light
domain: light
condition:
- condition: template
value_template: '{{ trigger.to_state.context.parent_id is none }}'
action:
- type: turn_off
device_id: 52a568acd1f3b04f9214c056c506d39b
entity_id: switch.office_lamp
domain: switch
mode: single
- id: '1635738239928'
alias: 'Manual: Log if turned on/off manually'
description: ''
trigger:
- platform: state
entity_id: switch.powder_room_lights, switch.garage_lights, switch.back_stairs_lights,
switch.front_stairs_lights, switch.dog_run_light, switch.kids_hall_lights, switch.master_hall_lights,
switch.master_lights, switch.master_toilet_fan, switch.master_toilet_light,
switch.outside_shower_light, switch.powder_room_fan, switch.shower_light, switch.bathroom_bath_light,
switch.bathroom_vanity_lights, switch.downstairs_playroom_lights, switch.entry_way_light,
switch.front_porch_lights, switch.guest_bedroom_lights, switch.outside_pantry_light,
switch.outside_powder_lights, switch.patio_lights, switch.shower_fan, switch.kitchen_nook_lights,
switch.laundry_room_lights, light.office_light, light.julie_bedside_lamp, light.matt_bedside_lamp,
switch.kitchen_island_lights, switch.kitchen_lights, switch.kitchen_nook_lights,
light.family_room_light, switch.master_fireplace, switch.downstairs_fireplace,
switch.annas_room_closet_light, switch.annas_room_overhead_light, switch.office_lamp,
switch.family_room_lamp, switch.kids_toilet_light, switch.kids_toilet_heat_lamp,
switch.guest_bathroom_lights, switch.guest_bathroom_heat_lamp
condition:
- condition: template
value_template: '{{ trigger.to_state != none and trigger.to_state.context.parent_id
is none }}'
action:
- service: system_log.write
data:
level: info
message: '{{trigger.entity_id}} manually turned {{trigger.to_state}}'
mode: parallel
max: 25
- id: '1637978707230'
alias: 'Shower: Turn on light with increase in humidity/temperature'
description: ''
trigger:
- platform: state
entity_id: binary_sensor.master_shower_temp_rising
from: 'off'
to: 'on'
- platform: state
entity_id: binary_sensor.master_shower_humidity_rising
from: 'off'
to: 'on'
condition:
- condition: or
conditions:
- condition: device
type: is_on
device_id: 8c22ac95adf287b795831ca2d91a0ffa
entity_id: switch.bathroom_vanity_lights
domain: switch
- condition: device
type: is_on
device_id: 8c22ac95adf287b795831ca2d91a0ffa
entity_id: switch.bathroom_bath_light
domain: switch
action:
- service: switch.turn_on
target:
entity_id:
- switch.shower_light
- switch.outside_shower_light
data: {}
mode: queued
max: 10
- id: '1638059972413'
alias: 'Bedroom Lamps: Toggle individual lamp on single button press'
description: ''
trigger:
- device_id: 478fe285a6ad8d83694828db93087130
domain: zha
platform: device
type: remote_button_short_press
subtype: remote_button_short_press
id: Matt
- device_id: 8a9adfdefb9e9937dd8007f41553f90a
domain: zha
platform: device
type: remote_button_short_press
subtype: remote_button_short_press
id: Julie
condition: []
action:
- choose:
- conditions:
- condition: trigger
id: Matt
sequence:
- type: toggle
device_id: 76c8408f221cf14367785b05facdd4a2
entity_id: light.matt_bedside_lamp
domain: light
- conditions:
- condition: trigger
id: Julie
sequence:
- type: toggle
device_id: 86c0ee3d478271d8d61b30f77fd26c3e
entity_id: light.julie_bedside_lamp
domain: light
default: []
mode: single
- id: '1638064239246'
alias: 'Bedroom Lamps: Toggle both lamps on double button press'
description: ''
trigger:
- device_id: 478fe285a6ad8d83694828db93087130
domain: zha
platform: device
type: remote_button_double_press
subtype: remote_button_double_press
id: Matt
- device_id: 8a9adfdefb9e9937dd8007f41553f90a
domain: zha
platform: device
type: remote_button_double_press
subtype: remote_button_double_press
id: Julie
condition: []
action:
- choose:
- conditions:
- condition: device
type: is_off
device_id: 76c8408f221cf14367785b05facdd4a2
entity_id: light.matt_bedside_lamp
domain: light
- condition: device
type: is_off
device_id: 86c0ee3d478271d8d61b30f77fd26c3e
entity_id: light.julie_bedside_lamp
domain: light
sequence:
- type: turn_on
device_id: 76c8408f221cf14367785b05facdd4a2
entity_id: light.matt_bedside_lamp
domain: light
- type: turn_on
device_id: 86c0ee3d478271d8d61b30f77fd26c3e
entity_id: light.julie_bedside_lamp
domain: light
- conditions:
- condition: device
type: is_on
device_id: 76c8408f221cf14367785b05facdd4a2
entity_id: light.matt_bedside_lamp
domain: light
- condition: device
type: is_on
device_id: 86c0ee3d478271d8d61b30f77fd26c3e
entity_id: light.julie_bedside_lamp
domain: light
sequence:
- type: turn_off
device_id: 76c8408f221cf14367785b05facdd4a2
entity_id: light.matt_bedside_lamp
domain: light
- type: turn_off
device_id: 86c0ee3d478271d8d61b30f77fd26c3e
entity_id: light.julie_bedside_lamp
domain: light
- conditions:
- condition: trigger
id: Matt
sequence:
- type: toggle
device_id: 86c0ee3d478271d8d61b30f77fd26c3e
entity_id: light.julie_bedside_lamp
domain: light
- conditions:
- condition: trigger
id: Julie
sequence:
- type: toggle
device_id: 76c8408f221cf14367785b05facdd4a2
entity_id: light.matt_bedside_lamp
domain: light
default: []
mode: single
- id: '1638065083446'
alias: 'Bedroom Lamps: Turn off all lights (except kids and guestroom if occupied)
on long press '
description: ''
trigger:
- device_id: 478fe285a6ad8d83694828db93087130
domain: zha
platform: device
type: remote_button_long_release
subtype: remote_button_long_release
- device_id: 8a9adfdefb9e9937dd8007f41553f90a
domain: zha
platform: device
type: remote_button_long_release
subtype: remote_button_long_release
condition: []
action:
- service: script.turn_off_all_lights
- service: script.turn_off_all_upstairs_lights_except_kids
mode: single
- id: '1638508599908'
alias: 'Water Heater: Notify of water presence'
description: ''
trigger:
- type: moist
platform: device
device_id: 8c948c3a63b78afe67a307b92d8f85d2
entity_id: binary_sensor.water_heater_water_leak
domain: binary_sensor
condition: []
action:
- service: notify.mobile_app_matts_iphone
data:
message: 'WARNING: Water Heater Leak Detected!'
data:
push:
interruption-level: critical
- service: notify.alexa_media_all_alexas
data:
message: 'WARNING: Water Heater Leak Detected!'
data:
type: announce
method: speak
mode: single
- id: '1640284605302'
alias: RTL 433 Shutdown
description: ''
trigger:
- platform: state
entity_id: binary_sensor.rtl_error
from: 'off'
to: 'on'
condition: []
action:
- service: notify.mobile_app_matts_iphone
data:
message: RTL 433 is shutting down!
mode: single
- id: '1640284642031'
alias: RTL 433 Restarted
description: ''
trigger:
- platform: state
entity_id: binary_sensor.rtl_error
from: 'on'
to: 'off'
condition: []
action:
- service: notify.mobile_app_matts_iphone
data:
message: RTL 433 restarted!
mode: single
- id: unavailable_entities_notification
alias: 'Unavailable Entities: Send notifications and log error'
description: Create persistent notification if there are unavailable entities, dismiss
if none.
trigger:
- platform: state
entity_id: sensor.unavailable_entities
action:
- choose:
- conditions:
- condition: numeric_state
entity_id: sensor.unavailable_entities
below: '1'
sequence:
- service: persistent_notification.dismiss
data:
notification_id: unavailable_entities
default:
- delay:
hours: 0
minutes: 0
seconds: 15
milliseconds: 0
- condition: numeric_state
entity_id: sensor.unavailable_entities
above: '0'
- service: persistent_notification.create
data:
title: Unavailable Entities
message: '- {{ expand(state_attr(''sensor.unavailable_entities'',''entities''))|map(attribute=''entity_id'')|join(''
- '') }}'
notification_id: unavailable_entities
- service: system_log.write
data:
level: warning
message: 'Unavailable entities: {{ state_attr("sensor.unavailable_entities","entities")|join(",
") }}'
- service: notify.mobile_app_matts_iphone
data:
title: Unavailable Entities
message: '{{ expand(state_attr(''sensor.unavailable_entities'',''entities''))|map(attribute=''entity_id'')|join('',
'') }}'
mode: restart
- id: '1640683290094'
alias: 'Movie Night: Turn off downstairs lights when start movie'
description: ''
trigger:
- platform: state
entity_id: input_boolean.movie_night
from: 'off'
to: 'on'
condition: []
action:
- service: homeassistant.turn_off
target:
entity_id: group.downstairs
mode: single
- id: '1640898211676'
alias: 'RTL_433: Update timer based on MQTT message'
description: ''
trigger:
- platform: mqtt
topic: 'home-assistant/sensors/rtl_error '
condition: []
action:
- service: timer.start
data:
duration: 00:01:30
target:
entity_id: timer.rtl_timer
mode: single
- id: '1640898901185'
alias: 'RTL_433: Set error if timer expires'
description: ''
trigger:
- platform: event
event_type: timer.finished
event_data:
entity_id: timer.rtl_timer
condition: []
action:
- service: mqtt.publish
data:
topic: home-assistant/sensors/rtl_error
payload: '{"cmd": 911}'
mode: single
- id: '1641721781084'
alias: 'Bed Sensor: Turn on lamps if get in bed'
description: ''
trigger:
- platform: state
entity_id: binary_sensor.julie_in_bed
id: Julie
to: 'on'
from: 'off'
- platform: state
entity_id: binary_sensor.matt_in_bed
id: Matt
from: 'off'
to: 'on'
condition: []
action:
- choose:
- conditions:
- condition: trigger
id: Julie
- condition: state
entity_id: light.julie_bedside_lamp
state: 'off'
for:
hours: 8
minutes: 0
seconds: 0
sequence:
- service: homeassistant.turn_on
data:
lights: light.julie_bedside_lamp
duration: 01:00:00
- conditions:
- condition: trigger
id: Matt
- condition: state
entity_id: light.matt_bedside_lamp
state: 'off'
for:
hours: 8
minutes: 0
seconds: 0
sequence:
- service: homeassistant.turn_on
data:
lights: light.matt_bedside_lamp
duration: 01:00:00
default: []
mode: queued
max: 10
- id: '1641723240534'
alias: 'Movie Night: Turn on one lights when finish movie'
description: ''
trigger:
- platform: state
entity_id: input_boolean.movie_night
from: 'on'
to: 'off'
condition: []
action:
- type: turn_on
device_id: 544bb27d0b76922e27d1056796669a1d
entity_id: switch.outside_powder_lights
domain: switch
mode: single
- id: '1641775549338'
alias: 'HomeAssistant: Notify when there are updates'
description: ''
trigger:
- platform: state
entity_id: update.home_assistant_core_update
to: 'on'
variables:
action_update: '{{ ''UPDATE_'' ~ trigger.to_state.context.id }}'
condition: []
action:
- service: notify.mobile_app_matts_iphone
data:
message: Home Assistant is ready for an update to {{ state_attr('update.home_assistant_core_update',
'latest_version') }}
data:
actions:
- action: URI
title: View Release Notes
uri: '{{ state_attr(''update.home_assistant_core_update'', ''release_url'')
}}'
- action: '{{ action_update }}'
title: Update Home Assistant
- wait_for_trigger:
- platform: event
event_type: mobile_app_notification_action
event_data:
action: '{{ action_update }}'
- choose:
- conditions:
- condition: template
value_template: '{{ (''UPDATE_'' ~ trigger.to_state.context.id) == action_update
}}'
sequence:
- service: update.install
target:
entity_id:
- update.home_assistant_core_update
data:
backup: true
default: []
mode: single
- id: '1642316274583'
alias: 'Powder Room: Turn on fan 5 minutes after door closes'
description: ''
trigger:
- platform: state
entity_id: binary_sensor.powder_room_door
from: 'on'
to: 'off'
condition:
- condition: state
entity_id: switch.powder_room_lights
state: 'on'
action:
- delay:
hours: 0
minutes: 5
seconds: 0
milliseconds: 0
- condition: state
entity_id: binary_sensor.powder_room_door
state: 'off'
- type: turn_on
device_id: 473ea148622c80694fb8d21c55c157c9
entity_id: switch.powder_room_fan
domain: switch
mode: restart
- id: '1642441606947'
alias: 'Bed Sensor: Shorten lamp timer if get out of bed'
description: ''
trigger:
- platform: state
entity_id: binary_sensor.julie_in_bed
id: Julie
to: 'off'
from: 'on'
- platform: state
entity_id: binary_sensor.matt_in_bed
id: Matt
from: 'on'
to: 'off'
condition: []
action:
- choose:
- conditions:
- condition: trigger
id: Julie
sequence:
- service: homeassistant.turn_on
data:
lights: light.julie_bedside_lamp
duration: 00:03:00
- conditions:
- condition: trigger
id: Matt
sequence:
- service: homeassistant.turn_on
data:
lights: light.matt_bedside_lamp
duration: 00:03:00
default: []
mode: queued
max: 10
- id: '1644211200619'
alias: 'Dining Room: Setup lights for dinner in dining room'
description: ''
trigger:
- platform: state
entity_id: input_boolean.dining_room_in_use
to: 'on'
from: 'off'
condition: []
action:
- service: switch.turn_on
target:
entity_id:
- switch.entry_way_light
- switch.outside_powder_lights
- switch.outside_pantry_light
- switch.front_stairs_lights
mode: single
- id: '1645294479994'
alias: 'Announcement: Dryer is done drying'
description: ''
trigger:
- platform: state
entity_id: binary_sensor.dryer_vibration
id: dryer
to: 'off'
for:
hours: 0
minutes: 5
seconds: 0
from: 'on'
condition: []
action:
- service: input_text.set_value
data:
value: "{% if (((as_timestamp(now()) - state_attr('input_datetime.last_dryer_start',\
\ 'timestamp')) / 60) > 30) %} \n The dryer is done. Time to fluff. \n{%\
\ elif states('input_boolean.washer_pending_notification') == 'on' %}\n The\
\ dryer is done. Time to turn over the laundry. \n{% else %}\n The dryer\
\ is done.\n{% endif %}\n"
target:
entity_id: input_text.dryer_done_message
- service: notify.alexa_media_kitchen_alexa
data:
data:
type: announce
method: speak
message: "{% set message = states('input_text.dryer_done_message') %} {{ message\
\ }} \n"
- service: notify.mobile_app_matts_iphone
data:
message: "{% set message = states('input_text.dryer_done_message') %} {{ message\