6209 lines
366 KiB
JSON
6209 lines
366 KiB
JSON
[
|
||
{
|
||
"id": "turn_on_alarm",
|
||
"automation": "- alias: turn_on_alarm\n id: turn_on_alarm\n initial_state: true\n triggers:\n - trigger: state\n entity_id: input_boolean.alarm_gateway_button\n to: 'on'\n actions:\n - action: scene.create\n data:\n scene_id: before_alarm_on\n snapshot_entities:\n - light.gateway_light_04cf8cabd77b\n - parallel:\n - action: script.turn_on\n target:\n entity_id: script.alarm_gateway_light\n - action: script.turn_on\n target:\n entity_id: script.alarm_gateway_sound\n - action: script.turn_on\n target:\n entity_id: script.alarm_tts_yandex_stations\n - action: timer.start\n target:\n entity_id: timer.alarm_gateway_sound\n data:\n duration: 1800",
|
||
"config": [
|
||
{
|
||
"name": "gateway light",
|
||
"room": "hallway",
|
||
"type": "light",
|
||
"id": {
|
||
"entity_id": "light.gateway_light_04cf8cabd77b",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "alarm gateway button",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.alarm_gateway_button",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "alarm gateway sound timer",
|
||
"room": null,
|
||
"type": "timer",
|
||
"id": {
|
||
"entity_id": "timer.alarm_gateway_sound",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "alarm gateway light script",
|
||
"room": null,
|
||
"type": "script",
|
||
"id": {
|
||
"entity_id": "script.alarm_gateway_light",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "alarm gateway sound script",
|
||
"room": null,
|
||
"type": "script",
|
||
"id": {
|
||
"entity_id": "script.alarm_gateway_sound",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "alarm tts yandex stations script",
|
||
"room": null,
|
||
"type": "script",
|
||
"id": {
|
||
"entity_id": "script.alarm_tts_yandex_stations",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "turn_off_alarm",
|
||
"automation": "- alias: turn_off_alarm\n id: turn_off_alarm\n initial_state: true\n triggers:\n - trigger: state\n entity_id: input_boolean.alarm_gateway_button\n to: 'off'\n actions:\n - parallel:\n - action: script.turn_off\n target:\n entity_id: script.alarm_gateway_light\n - action: script.turn_off\n target:\n entity_id: script.alarm_gateway_sound\n - action: script.turn_off\n target:\n entity_id: script.alarm_tts_yandex_stations\n - action: light.turn_off\n target:\n entity_id: light.gateway_light_04cf8cabd77b\n - action: xiaomi_aqara.stop_ringtone\n data:\n gw_mac: secret gateway1_mac\n - action: timer.cancel\n target:\n entity_id: timer.alarm_gateway_sound\n - choose:\n - conditions:\n - '{{ states.group.dynamic_group_gateway_alarm_last_state_disarmed is not\n none }}'\n sequence:\n - variables:\n entities: '{{ expand(''group.dynamic_group_gateway_alarm_last_state_disarmed'')\n | map(attribute = ''entity_id'') | list | join('', '') }}'\n - action: alarm_control_panel.alarm_arm_away\n target:\n entity_id: '{{ entities }}'\n - action: alarm_control_panel.alarm_disarm\n target:\n entity_id: '{{ entities }}'\n - action: group.remove\n data:\n object_id: dynamic_group_gateway_alarm_last_state_disarmed\n - choose:\n - conditions:\n - '{{ states.group.dynamic_group_gateway_alarm_last_state_armed_away is not\n none }}'\n sequence:\n - variables:\n entities: '{{ expand(''group.dynamic_group_gateway_alarm_last_state_armed_away'')\n | map(attribute = ''entity_id'') | list | join('', '') }}'\n - action: alarm_control_panel.alarm_disarm\n target:\n entity_id: '{{ entities }}'\n - action: alarm_control_panel.alarm_arm_away\n target:\n entity_id: '{{ entities }}'\n - action: group.remove\n data:\n object_id: dynamic_group_gateway_alarm_last_state_armed_away\n - action: scene.turn_on\n target:\n entity_id: scene.before_alarm_on",
|
||
"config": [
|
||
{
|
||
"name": "gateway light",
|
||
"room": "hallway",
|
||
"type": "light",
|
||
"id": {
|
||
"entity_id": "light.gateway_light_04cf8cabd77b",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "alarm gateway button",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.alarm_gateway_button",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "alarm gateway sound timer",
|
||
"room": null,
|
||
"type": "timer",
|
||
"id": {
|
||
"entity_id": "timer.alarm_gateway_sound",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "alarm gateway light script",
|
||
"room": null,
|
||
"type": "script",
|
||
"id": {
|
||
"entity_id": "script.alarm_gateway_light",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "alarm gateway sound script",
|
||
"room": null,
|
||
"type": "script",
|
||
"id": {
|
||
"entity_id": "script.alarm_gateway_sound",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "alarm tts yandex stations script",
|
||
"room": null,
|
||
"type": "script",
|
||
"id": {
|
||
"entity_id": "script.alarm_tts_yandex_stations",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "dynamic group gateway alarm last state disarmed",
|
||
"room": null,
|
||
"type": "group",
|
||
"id": {
|
||
"entity_id": "group.dynamic_group_gateway_alarm_last_state_disarmed",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "dynamic group gateway alarm last state armed away",
|
||
"room": null,
|
||
"type": "group",
|
||
"id": {
|
||
"entity_id": "group.dynamic_group_gateway_alarm_last_state_armed_away",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "scene before alarm on",
|
||
"room": null,
|
||
"type": "scene",
|
||
"id": {
|
||
"entity_id": "scene.before_alarm_on",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "alarm_gateway_stop_ringtone_timer",
|
||
"automation": "- alias: alarm_gateway_stop_ringtone_timer\n id: alarm_gateway_stop_ringtone_timer\n initial_state: true\n triggers:\n - trigger: event\n event_type: timer.finished\n event_data:\n entity_id: timer.alarm_gateway_sound\n conditions:\n - condition: state\n entity_id: input_boolean.alarm_gateway_button\n state: 'on'\n actions:\n - parallel:\n - action: script.turn_off\n target:\n entity_id: script.alarm_gateway_sound\n - action: script.turn_off\n target:\n entity_id: script.alarm_tts_yandex_stations\n - action: xiaomi_aqara.stop_ringtone\n data:\n gw_mac: secret gateway1_mac",
|
||
"config": [
|
||
{
|
||
"name": "alarm gateway button",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.alarm_gateway_button",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "alarm gateway sound timer",
|
||
"room": null,
|
||
"type": "timer",
|
||
"id": {
|
||
"entity_id": "timer.alarm_gateway_sound",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "alarm gateway sound script",
|
||
"room": null,
|
||
"type": "script",
|
||
"id": {
|
||
"entity_id": "script.alarm_gateway_sound",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "alarm tts yandex stations script",
|
||
"room": null,
|
||
"type": "script",
|
||
"id": {
|
||
"entity_id": "script.alarm_tts_yandex_stations",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "smoke detector alarm to gateway",
|
||
"automation": "- alias: smoke detector alarm to gateway\n id: smoke detector alarm to gateway\n initial_state: true\n triggers:\n - trigger: state\n entity_id:\n - binary_sensor.0x158d0003943639_smoke\n - binary_sensor.0x158d00039a8358_smoke\n - binary_sensor.0x158d00039d9398_smoke\n - binary_sensor.0x158d00045ca483_smoke\n - binary_sensor.0x00158d00045cd551_smoke\n to: 'on'\n conditions:\n - condition: state\n entity_id: input_boolean.alarm_gateway_button\n state: 'off'\n actions:\n - action: input_boolean.turn_on\n target:\n entity_id: input_boolean.alarm_gateway_button",
|
||
"config": [
|
||
{
|
||
"name": "alarm gateway button",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.alarm_gateway_button",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "smoke sensor 1",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d0003943639_smoke",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "smoke sensor 2",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d00039a8358_smoke",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "smoke sensor 3",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d00039d9398_smoke",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "smoke sensor 4",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d00045ca483_smoke",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "smoke sensor 5",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x00158d00045cd551_smoke",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "smoke detector stop alarm to gateway",
|
||
"automation": "- alias: smoke detector stop alarm to gateway\n id: smoke detector stop alarm to gateway\n initial_state: true\n triggers:\n - trigger: state\n entity_id:\n - binary_sensor.0x158d0003943639_smoke\n - binary_sensor.0x158d00039a8358_smoke\n - binary_sensor.0x158d00039d9398_smoke\n - binary_sensor.0x158d00045ca483_smoke\n - binary_sensor.0x00158d00045cd551_smoke\n from: 'on'\n to: 'off'\n conditions:\n - condition: state\n entity_id: binary_sensor.0x158d0003943639_smoke\n state: 'off'\n - condition: state\n entity_id: binary_sensor.0x158d00039a8358_smoke\n state: 'off'\n - condition: state\n entity_id: binary_sensor.0x158d00039d9398_smoke\n state: 'off'\n - condition: state\n entity_id: binary_sensor.0x158d00045ca483_smoke\n state: 'off'\n - condition: state\n entity_id: binary_sensor.0x00158d00045cd551_smoke\n state: 'off'\n - condition: state\n entity_id: input_boolean.alarm_gateway_button\n state: 'on'\n actions:\n - action: input_boolean.turn_off\n target:\n entity_id: input_boolean.alarm_gateway_button",
|
||
"config": [
|
||
{
|
||
"name": "alarm gateway button",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.alarm_gateway_button",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "smoke sensor 1",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d0003943639_smoke",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "smoke sensor 2",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d00039a8358_smoke",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "smoke sensor 3",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d00039d9398_smoke",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "smoke sensor 4",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d00045ca483_smoke",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "smoke sensor 5",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x00158d00045cd551_smoke",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "door and motion alarm to gateway",
|
||
"automation": "- alias: door and motion alarm to gateway\n id: door and motion alarm to gateway\n max_exceeded: silent\n initial_state: true\n triggers:\n - trigger: state\n entity_id:\n - binary_sensor.0x158d00054b8d72_motion\n - binary_sensor.0x158d000566bde7_motion\n - binary_sensor.0x158d0003953ee9_motion\n - binary_sensor.0x158d000359304c_contact\n - binary_sensor.window_childrens_room_group\n - binary_sensor.window_bed_room_group\n - binary_sensor.window_kitchen_group\n - binary_sensor.window_living_room_group\n to: 'on'\n - trigger: state\n entity_id:\n - sensor.0x158d00054b8d72_illuminance\n - sensor.0x158d000566bde7_illuminance\n conditions:\n - condition: state\n entity_id: alarm_control_panel.signalka_shliuza_alarm\n state: armed_away\n - condition: state\n entity_id: input_boolean.alarm_gateway_button\n state: 'off'\n actions:\n - action: input_boolean.turn_on\n target:\n entity_id: input_boolean.alarm_gateway_button",
|
||
"config": [
|
||
{
|
||
"name": "alarm gateway button",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.alarm_gateway_button",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "shliuza alarm control panel",
|
||
"room": null,
|
||
"type": "alarm_control_panel",
|
||
"id": {
|
||
"entity_id": "alarm_control_panel.signalka_shliuza_alarm",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "motion sensor 1",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d00054b8d72_motion",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "motion sensor 2",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d000566bde7_motion",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "motion sensor 3",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d0003953ee9_motion",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "contact sensor",
|
||
"room": "hallway",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d000359304c_contact",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "window childrens room group",
|
||
"room": "childrens_room",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.window_childrens_room_group",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "window bed room group",
|
||
"room": "bedroom",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.window_bed_room_group",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "window kitchen group",
|
||
"room": "kitchen",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.window_kitchen_group",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "window living room group",
|
||
"room": "living_room",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.window_living_room_group",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "illuminance sensor 1",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x158d00054b8d72_illuminance",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "illuminance sensor 2",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x158d000566bde7_illuminance",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "turn_off_alarm_disarmed_control_panel",
|
||
"automation": "- alias: turn_off_alarm_disarmed_control_panel\n id: turn_off_alarm_disarmed_control_panel\n initial_state: true\n triggers:\n - trigger: state\n entity_id: alarm_control_panel.signalka_shliuza_alarm\n to: disarmed\n - trigger: state\n entity_id: sensor.0x158d0003a360b6_action\n to: hold\n conditions:\n - condition: state\n entity_id: input_boolean.alarm_gateway_button\n state: 'on'\n actions:\n - action: input_boolean.turn_off\n target:\n entity_id: input_boolean.alarm_gateway_button",
|
||
"config": [
|
||
{
|
||
"name": "alarm gateway button",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.alarm_gateway_button",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "shliuza alarm control panel",
|
||
"room": null,
|
||
"type": "alarm_control_panel",
|
||
"id": {
|
||
"entity_id": "alarm_control_panel.signalka_shliuza_alarm",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "wireless switch action",
|
||
"room": "childrens_room",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x158d0003a360b6_action",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "wireless switch many tap alarm to gateway",
|
||
"automation": "- alias: wireless switch many tap alarm to gateway\n id: wireless switch many tap alarm to gateway\n initial_state: true\n triggers:\n - trigger: state\n entity_id: sensor.0x158d0003a360b6_action\n to: many\n conditions:\n - condition: state\n entity_id: input_boolean.alarm_gateway_button\n state: 'off'\n actions:\n - variables:\n sm_g973f_rezhim_ne_bespokoit: '{{ states(''sensor.sm_g973f_do_not_disturb_sensor'')\n }}'\n - choose:\n - conditions: '{{ sm_g973f_rezhim_ne_bespokoit = ''off'' }}'\n sequence:\n - action: notify.mobile_app_sm_g973f\n data:\n message: command_dnd\n data:\n command: 'off'\n - wait_for_trigger:\n - trigger: state\n entity_id: sensor.sm_g973f_do_not_disturb_sensor\n timeout:\n seconds: 5\n - variables:\n sm_g973f_rezhim_zvonka: '{{ states(''sensor.sm_g973f_ringer_mode'') }}'\n - choose:\n - conditions: '{{ sm_g973f_rezhim_zvonka = ''normal'' }}'\n sequence:\n - action: notify.notify\n data:\n message: command_ringer_mode\n data:\n command: normal\n - parallel:\n - action: input_boolean.turn_on\n target:\n entity_id: input_boolean.alarm_gateway_button\n - action: telegram_bot.send_message\n data:\n title: '{{ ''\\U0001f6a8'' }} *Сигнализация*'\n message: Нажатие тревожной кнопки в *детской*\n target: secret telegram_all_chat_id\n - action: notify.notify\n data:\n title: '{{ ''🚨'' }} Сигнализация'\n message: Нажатие тревожной кнопки в детской\n data:\n ttl: 0\n priority: high\n channel: alarm_stream\n actions:\n - action: stop_alarm\n title: Выключить сирену\n - action: notify.huawei_lte\n data:\n message: 🚨 Нажатие тревожной кнопки в детской\n target: secret sms_phone_all\n data:\n url: http://192.168.8.1/\n - choose:\n - conditions: '{{ sm_g973f_rezhim_zvonka = ''normal'' }}'\n sequence:\n - action: notify.mobile_app_sm_g973f\n data:\n message: command_ringer_mode\n data:\n command: '{{ sm_g973f_rezhim_zvonka }}'\n - choose:\n - conditions: '{{ sm_g973f_rezhim_ne_bespokoit = ''off'' }}'\n sequence:\n - action: notify.mobile_app_sm_g973f\n data:\n message: command_dnd\n data:\n command: '{{ sm_g973f_rezhim_ne_bespokoit }}'",
|
||
"config": [
|
||
{
|
||
"name": "alarm gateway button",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.alarm_gateway_button",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "wireless switch action",
|
||
"room": "childrens_room",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x158d0003a360b6_action",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "do not disturb sensor",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.sm_g973f_do_not_disturb_sensor",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "ringer mode",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.sm_g973f_ringer_mode",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "SMS Phone All Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret sms_phone_all",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram All Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_all_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "mobile app telegram notification action turn off alarm",
|
||
"automation": "- alias: mobile app telegram notification action turn off alarm\n id: mobile app telegram notification action turn off alarm\n initial_state: true\n triggers:\n - trigger: event\n event_type: mobile_app_notification_action\n event_data:\n action: stop_alarm\n - trigger: event\n id: telegram_callback_stop_alarm\n event_type: telegram_callback\n event_data:\n data: /stop_alarm\n actions:\n - choose:\n - conditions: '{{ is_state(''input_boolean.alarm_gateway_button'', ''on'') }}'\n sequence:\n - action: input_boolean.turn_off\n target:\n entity_id: input_boolean.alarm_gateway_button\n - choose:\n - conditions: '{{ trigger.id == ''telegram_callback_stop_alarm'' }}'\n sequence:\n - action: telegram_bot.delete_message\n data:\n chat_id: '{{ trigger.event.data.chat_id }}'\n message_id: '{{ trigger.event.data.message.message_id }}'\n - action: telegram_bot.answer_callback_query\n data:\n callback_query_id: '{{ trigger.event.data.id }}'\n message: Выключили сигнализацию",
|
||
"config": [
|
||
{
|
||
"name": "alarm gateway button",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.alarm_gateway_button",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "main gateway arm dissarm to others gw",
|
||
"automation": "- alias: main gateway arm dissarm to others gw\n id: main gateway arm dissarm to others gw\n initial_state: true\n triggers:\n - trigger: state\n id: armed\n entity_id: alarm_control_panel.signalka_shliuza_alarm\n to: armed_away\n - trigger: state\n entity_id: alarm_control_panel.signalka_shliuza_alarm\n to: disarmed\n actions:\n - action: '{{ iif(trigger.id == ''armed'', ''alarm_control_panel.alarm_arm_away'',\n ''alarm_control_panel.alarm_disarm'') }}'\n target:\n entity_id:\n - alarm_control_panel.54ef44315770_alarm\n - alarm_control_panel.54ef44cb80fd_alarm\n - alarm_control_panel.54ef443127b2_alarm",
|
||
"config": [
|
||
{
|
||
"name": "shliuza alarm control panel",
|
||
"room": null,
|
||
"type": "alarm_control_panel",
|
||
"id": {
|
||
"entity_id": "alarm_control_panel.signalka_shliuza_alarm",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "alarm gateway 1",
|
||
"room": null,
|
||
"type": "alarm_control_panel",
|
||
"id": {
|
||
"entity_id": "alarm_control_panel.54ef44315770_alarm",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "alarm gateway 2",
|
||
"room": null,
|
||
"type": "alarm_control_panel",
|
||
"id": {
|
||
"entity_id": "alarm_control_panel.54ef44cb80fd_alarm",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "alarm gateway 3",
|
||
"room": null,
|
||
"type": "alarm_control_panel",
|
||
"id": {
|
||
"entity_id": "alarm_control_panel.54ef443127b2_alarm",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "smoke detector alarm to turn off all",
|
||
"automation": "- alias: smoke detector alarm to turn off all\n id: smoke detector alarm to turn off all\n initial_state: true\n triggers:\n - trigger: state\n entity_id:\n - binary_sensor.0x158d0003943639_smoke\n - binary_sensor.0x158d00039a8358_smoke\n - binary_sensor.0x158d00039d9398_smoke\n - binary_sensor.0x158d00045ca483_smoke\n - binary_sensor.0x00158d00045cd551_smoke\n to: 'on'\n actions:\n - action: homeassistant.turn_off\n target:\n entity_id: '{{ expand(''group.entity_ids_for_turn_off_by_smoke_detector'') |\n map(attribute = ''entity_id'') | join('', '') }}'",
|
||
"config": [
|
||
{
|
||
"name": "smoke sensor 1",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d0003943639_smoke",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "smoke sensor 2",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d00039a8358_smoke",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "smoke sensor 3",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d00039d9398_smoke",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "smoke sensor 4",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d00045ca483_smoke",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "smoke sensor 5",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x00158d00045cd551_smoke",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "entity ids for turn off by smoke detector",
|
||
"room": null,
|
||
"type": "group",
|
||
"id": {
|
||
"entity_id": "group.entity_ids_for_turn_off_by_smoke_detector",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "main gateway arm dissarm from nfc tag hallway",
|
||
"automation": "- alias: main gateway arm dissarm from nfc tag hallway\n id: main gateway arm dissarm from nfc tag hallway\n initial_state: true\n triggers:\n - trigger: tag\n tag_id:\n - 73aef2e2-722b-418d-b20a-24e84eda330e\n device_id:\n - f4de6186902849d0845c4e2552d3531d\n conditions:\n - '{{ state_attr(this.entity_id, ''current'') | int(0) == 0 }}'\n actions:\n - choose:\n - conditions:\n - '{{ is_state(''alarm_control_panel.signalka_shliuza_alarm'', ''disarmed'')\n }}'\n sequence:\n - wait_for_trigger:\n - trigger: tag\n tag_id:\n - 73aef2e2-722b-418d-b20a-24e84eda330e\n timeout: 15\n - if:\n - '{{ wait.trigger = None }}'\n then:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n message: '{{ ''🔇 Отменено включение сигнализации'' }}'\n else:\n - action: alarm_control_panel.alarm_arm_away\n target:\n entity_id: alarm_control_panel.signalka_shliuza_alarm\n default:\n - action: alarm_control_panel.alarm_disarm\n target:\n entity_id: alarm_control_panel.signalka_shliuza_alarm",
|
||
"config": [
|
||
{
|
||
"name": "shliuza alarm control panel",
|
||
"room": null,
|
||
"type": "alarm_control_panel",
|
||
"id": {
|
||
"entity_id": "alarm_control_panel.signalka_shliuza_alarm",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "perenio petra01 kitchen",
|
||
"room": "kitchen",
|
||
"type": "esphome",
|
||
"id": {
|
||
"entity_id": null,
|
||
"device_id": "f4de6186902849d0845c4e2552d3531d"
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "gateway alarm to turn on to all gateways",
|
||
"automation": "- alias: gateway alarm to turn on to all gateways\n id: gateway alarm to turn on to all gateways\n max_exceeded: silent\n initial_state: true\n triggers:\n - trigger: state\n entity_id:\n - alarm_control_panel.54ef44315770_alarm\n - alarm_control_panel.54ef44cb80fd_alarm\n - alarm_control_panel.54ef443127b2_alarm\n to: triggered\n - trigger: state\n entity_id: input_boolean.alarm_gateway_button\n to: 'on'\n conditions:\n - '{{ now() - state_attr(this.entity_id, ''last_triggered'') > timedelta(seconds\n = 5) }}'\n actions:\n - variables:\n entities: '{{ states.alarm_control_panel | selectattr(''state'', ''in'', [''armed_away'',\n ''disarmed'']) | rejectattr(''entity_id'', ''eq'', ''alarm_control_panel.signalka_shliuza_alarm'')\n | map(attribute = ''entity_id'') | list | to_json }}'\n - parallel:\n - choose:\n - conditions:\n - '{{ entities | from_json | count > 0 }}'\n sequence:\n - action: alarm_control_panel.alarm_trigger\n target:\n entity_id: '{{ entities | from_json | join('', '') }}'\n - choose:\n - conditions:\n - condition: state\n entity_id: input_boolean.alarm_gateway_button\n state: 'off'\n sequence:\n - action: input_boolean.turn_on\n target:\n entity_id: input_boolean.alarm_gateway_button",
|
||
"config": [
|
||
{
|
||
"name": "alarm gateway button",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.alarm_gateway_button",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "shliuza alarm control panel",
|
||
"room": null,
|
||
"type": "alarm_control_panel",
|
||
"id": {
|
||
"entity_id": "alarm_control_panel.signalka_shliuza_alarm",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "alarm gateway 1",
|
||
"room": null,
|
||
"type": "alarm_control_panel",
|
||
"id": {
|
||
"entity_id": "alarm_control_panel.54ef44315770_alarm",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "alarm gateway 2",
|
||
"room": null,
|
||
"type": "alarm_control_panel",
|
||
"id": {
|
||
"entity_id": "alarm_control_panel.54ef44cb80fd_alarm",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "alarm gateway 3",
|
||
"room": null,
|
||
"type": "alarm_control_panel",
|
||
"id": {
|
||
"entity_id": "alarm_control_panel.54ef443127b2_alarm",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "input number target humidity cb1 changed",
|
||
"automation": "- alias: input number target humidity cb1 changed\n id: input number target humidity cb1 changed\n initial_state: true\n mode: queued\n max: 25\n triggers:\n - trigger: state\n entity_id: input_number.zhimi_humidifier_cb1_target_humidity\n actions:\n - action: humidifier.set_humidity\n target:\n entity_id: humidifier.zhimi_humidifier_cb1\n data:\n humidity: '{{ states(\"input_number.zhimi_humidifier_cb1_target_humidity\") |\n int(0) }}'",
|
||
"config": [
|
||
{
|
||
"name": "humidifier cb1 target humidity input",
|
||
"room": "bedroom",
|
||
"type": "input_number",
|
||
"id": {
|
||
"entity_id": "input_number.zhimi_humidifier_cb1_target_humidity",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "humidifier cb1",
|
||
"room": "bedroom",
|
||
"type": "humidifier",
|
||
"id": {
|
||
"entity_id": "humidifier.zhimi_humidifier_cb1",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "sensor target humidity cb1 changed state",
|
||
"automation": "- alias: sensor target humidity cb1 changed state\n id: sensor target humidity cb1 changed state\n initial_state: true\n mode: single\n max_exceeded: silent\n trigger_variables:\n not_has_state: '{{ [''unknown'', ''unavailable'', ''none'', none, null] }}'\n triggers:\n - trigger: state\n entity_id: sensor.zhimi_humidifier_cb1_target_humidity\n conditions:\n - condition: template\n value_template: \"{{ trigger.to_state.state is defined and\\n trigger.to_state.state\\\n \\ not in not_has_state and \\n trigger.to_state.state != trigger.from_state.state\\n\\\n }}\\n\"\n actions:\n - action: input_number.set_value\n target:\n entity_id: input_number.zhimi_humidifier_cb1_target_humidity\n data:\n value: \"{% if trigger.to_state.state | int(0) != 0 -%}\\n {{ trigger.to_state.state\\\n \\ | int(0) }}\\n{%- else -%}\\n 40\\n{%- endif %}\"",
|
||
"config": [
|
||
{
|
||
"name": "humidifier cb1 target humidity input",
|
||
"room": "bedroom",
|
||
"type": "input_number",
|
||
"id": {
|
||
"entity_id": "input_number.zhimi_humidifier_cb1_target_humidity",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "humidifier cb1 target humidity sensor",
|
||
"room": "bedroom",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.zhimi_humidifier_cb1_target_humidity",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "input number target humidity ca4 changed",
|
||
"automation": "- alias: input number target humidity ca4 changed\n id: input number target humidity ca4 changed\n initial_state: true\n mode: queued\n max: 25\n triggers:\n - trigger: state\n entity_id: input_number.zhimi_humidifier_ca4_target_humidity\n actions:\n - action: humidifier.set_humidity\n target:\n entity_id: humidifier.zhimi_humidifier_ca4\n data:\n humidity: '{{ states(\"input_number.zhimi_humidifier_ca4_target_humidity\") |\n int(0) }}'",
|
||
"config": [
|
||
{
|
||
"name": "humidifier ca4 target humidity input",
|
||
"room": "childrens_room",
|
||
"type": "input_number",
|
||
"id": {
|
||
"entity_id": "input_number.zhimi_humidifier_ca4_target_humidity",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "humidifier ca4",
|
||
"room": "childrens_room",
|
||
"type": "humidifier",
|
||
"id": {
|
||
"entity_id": "humidifier.zhimi_humidifier_ca4",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "sensor target humidity ca4 changed state",
|
||
"automation": "- alias: sensor target humidity ca4 changed state\n id: sensor target humidity ca4 changed state\n initial_state: true\n mode: single\n max_exceeded: silent\n trigger_variables:\n not_has_state: '{{ [''unknown'', ''unavailable'', ''none'', none, null] }}'\n triggers:\n - trigger: state\n entity_id: sensor.zhimi_humidifier_ca4_target_humidity\n conditions:\n - condition: template\n value_template: \"{{ trigger.to_state.state is defined and\\n trigger.to_state.state\\\n \\ not in not_has_state and \\n trigger.to_state.state != trigger.from_state.state\\n\\\n }}\\n\"\n actions:\n - action: input_number.set_value\n target:\n entity_id: input_number.zhimi_humidifier_ca4_target_humidity\n data:\n value: \"{% if trigger.to_state.state | int(0) != 0 -%}\\n {{ trigger.to_state.state\\\n \\ | int(0) }}\\n{%- else -%}\\n 40\\n{%- endif %}\"",
|
||
"config": [
|
||
{
|
||
"name": "humidifier ca4 target humidity input",
|
||
"room": "childrens_room",
|
||
"type": "input_number",
|
||
"id": {
|
||
"entity_id": "input_number.zhimi_humidifier_ca4_target_humidity",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "humidifier ca4 target humidity sensor",
|
||
"room": "childrens_room",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.zhimi_humidifier_ca4_target_humidity",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "air humidifier day and night speed",
|
||
"automation": "- alias: air humidifier day and night speed\n id: air humidifier day and night speed\n mode: queued\n max: 25\n triggers:\n - trigger: time\n at: '22:00:00'\n - trigger: time\n at: 08:00:00\n actions:\n - parallel:\n - choose:\n - conditions:\n - condition: state\n entity_id: humidifier.zhimi_humidifier_cb1\n state: 'on'\n sequence:\n - action: humidifier.set_mode\n target:\n entity_id: humidifier.zhimi_humidifier_cb1\n data:\n speed: \"{% if '08:00:00' <= as_timestamp(trigger.now, 0) | timestamp_custom('%H:%M:%S',\\\n \\ true, 0) < '22:00:00' %}\\n Auto\\n{% else %} \\n Silent \\n{% endif\\\n \\ %}\"\n - choose:\n - conditions:\n - condition: state\n entity_id: humidifier.zhimi_humidifier_ca4\n state: 'on'\n sequence:\n - action: humidifier.set_mode\n target:\n entity_id: humidifier.zhimi_humidifier_ca4\n data:\n speed: \"{% if '08:00:00' <= as_timestamp(trigger.now, 0) | timestamp_custom('%H:%M:%S',\\\n \\ true, 0) < '22:00:00' %}\\n Auto\\n{% else %} \\n Low \\n{% endif\\\n \\ %}\"",
|
||
"config": [
|
||
{
|
||
"name": "humidifier cb1",
|
||
"room": "bedroom",
|
||
"type": "humidifier",
|
||
"id": {
|
||
"entity_id": "humidifier.zhimi_humidifier_cb1",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "humidifier ca4",
|
||
"room": "childrens_room",
|
||
"type": "humidifier",
|
||
"id": {
|
||
"entity_id": "humidifier.zhimi_humidifier_ca4",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "turn on off climate devices childrens room window open close",
|
||
"automation": "- alias: turn on off climate devices childrens room window open close\n id: turn on off climate devices childrens room window open close\n mode: single\n max_exceeded: silent\n trigger_variables:\n not_has_state: '{{ [''unknown'', ''unavailable''] }}'\n triggers:\n - trigger: state\n entity_id: binary_sensor.window_childrens_room_group\n from: 'off'\n to: 'on'\n for: 00:05:00\n - trigger: state\n entity_id: binary_sensor.window_childrens_room_group\n from: 'on'\n to: 'off'\n for: 00:01:15\n conditions: \"{{ \\n trigger.to_state.state == 'on' or \\n is_state('input_boolean.auto_triggered_fan_window_childrens_room',\\\n \\ 'on') or \\n is_state('input_boolean.auto_triggered_valve_window_childrens_room',\\\n \\ 'on')\\n}}\\n\"\n actions:\n - parallel:\n - sequence:\n - if:\n - '{{ states(''humidifier.zhimi_humidifier_ca4'') in not_has_state }}'\n then:\n - wait_for_trigger:\n - trigger: state\n entity_id: humidifier.zhimi_humidifier_ca4\n from:\n - unknown\n - unavailable\n timeout: 75\n - choose:\n - conditions:\n - condition: template\n value_template: \"{{ \\n trigger.to_state.state == 'on' and is_state('humidifier.zhimi_humidifier_ca4',\\\n \\ 'on') \\n or trigger.to_state.state == 'off' and is_state('humidifier.zhimi_humidifier_ca4',\\\n \\ 'off')\\n and is_state('input_boolean.auto_triggered_fan_window_childrens_room',\\\n \\ 'on')\\n}}\\n\"\n sequence:\n - action: \"{% if trigger.to_state.state == 'on' -%}\\n humidifier.turn_off\\n\\\n {%- else -%}\\n humidifier.turn_on\\n{%- endif %}\\n\"\n target:\n entity_id: humidifier.zhimi_humidifier_ca4\n - action: input_boolean.toggle\n target:\n entity_id: input_boolean.auto_triggered_fan_window_childrens_room\n - conditions:\n - condition: template\n value_template: \"{{ \\n trigger.to_state.state == 'off'\\n and is_state('input_boolean.auto_triggered_fan_window_childrens_room',\\\n \\ 'on')\\n}}\\n\"\n sequence:\n - action: input_boolean.turn_off\n target:\n entity_id: input_boolean.auto_triggered_fan_window_childrens_room\n - choose:\n - conditions:\n - condition: template\n value_template: \"{{ \\n trigger.to_state.state == 'on' and is_state('climate.0x5c0272fffec89454',\\\n \\ 'auto') \\n or trigger.to_state.state == 'off' and is_state('climate.0x5c0272fffec89454',\\\n \\ 'off') \\n and is_state('input_boolean.auto_triggered_valve_window_childrens_room',\\\n \\ 'on')\\n}}\\n\"\n sequence:\n - action: climate.set_hvac_mode\n target:\n entity_id: climate.0x5c0272fffec89454\n data:\n hvac_mode: \"{% if trigger.to_state.state == 'on' -%}\\n off\\n{%- else\\\n \\ -%}\\n auto\\n{%- endif %}\\n\"\n - action: \"{% if trigger.to_state.state == 'off' -%}\\n input_boolean.turn_off\\n\\\n {%- else -%}\\n input_boolean.turn_on\\n{%- endif %}\\n\"\n target:\n entity_id: input_boolean.auto_triggered_valve_window_childrens_room\n - action: climate.set_preset_mode\n target:\n entity_id: climate.0x5c0272fffec89454\n data:\n preset_mode: manual\n - conditions:\n - condition: template\n value_template: \"{{ \\n trigger.to_state.state == 'off' and is_state('climate.0x5c0272fffec89454',\\\n \\ 'auto') \\n and is_state('input_boolean.auto_triggered_valve_window_childrens_room',\\\n \\ 'on')\\n}}\\n\"\n sequence:\n - action: input_boolean.turn_off\n target:\n entity_id: input_boolean.auto_triggered_valve_window_childrens_room",
|
||
"config": [
|
||
{
|
||
"name": "window childrens room group",
|
||
"room": "childrens_room",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.window_childrens_room_group",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "humidifier ca4",
|
||
"room": "childrens_room",
|
||
"type": "humidifier",
|
||
"id": {
|
||
"entity_id": "humidifier.zhimi_humidifier_ca4",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "auto triggered fan window childrens room",
|
||
"room": "childrens_room",
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.auto_triggered_fan_window_childrens_room",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "auto triggered valve window childrens room",
|
||
"room": "childrens_room",
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.auto_triggered_valve_window_childrens_room",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "childrens room valve with thermostat",
|
||
"room": "childrens_room",
|
||
"type": "climate",
|
||
"id": {
|
||
"entity_id": "climate.0x5c0272fffec89454",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "turn on off climate devices bed room window open close",
|
||
"automation": "- alias: turn on off climate devices bed room window open close\n id: turn on off climate devices bed room window open close\n mode: single\n max_exceeded: silent\n trigger_variables:\n not_has_state: '{{ [''unknown'', ''unavailable''] }}'\n triggers:\n - trigger: state\n entity_id: binary_sensor.window_bed_room_group\n from: 'off'\n to: 'on'\n for: 00:05:00\n - trigger: state\n entity_id: binary_sensor.window_bed_room_group\n from: 'on'\n to: 'off'\n for: 00:01:15\n conditions: \"{{ \\n trigger.to_state.state == 'on' or \\n is_state('input_boolean.auto_triggered_fan_window_bed_room',\\\n \\ 'on') or \\n is_state('input_boolean.auto_triggered_valve_window_bed_room',\\\n \\ 'on')\\n}}\\n\"\n actions:\n - parallel:\n - sequence:\n - if:\n - '{{ states(''humidifier.zhimi_humidifier_cb1'') in not_has_state }}'\n then:\n - wait_for_trigger:\n - trigger: state\n entity_id: humidifier.zhimi_humidifier_cb1\n from:\n - unknown\n - unavailable\n timeout: 75\n - choose:\n - conditions:\n - condition: template\n value_template: \"{{ \\n trigger.to_state.state == 'on' and is_state('humidifier.zhimi_humidifier_cb1',\\\n \\ 'on') \\n or trigger.to_state.state == 'off' and is_state('humidifier.zhimi_humidifier_cb1',\\\n \\ 'off')\\n and is_state('input_boolean.auto_triggered_fan_window_bed_room',\\\n \\ 'on')\\n}}\\n\"\n sequence:\n - action: \"{% if trigger.to_state.state == 'on' -%}\\n humidifier.turn_off\\n\\\n {%- else -%}\\n humidifier.turn_on\\n{%- endif %}\\n\"\n target:\n entity_id: humidifier.zhimi_humidifier_cb1\n - action: \"{% if trigger.to_state.state == 'off' -%}\\n input_boolean.turn_off\\n\\\n {%- else -%}\\n input_boolean.turn_on\\n{%- endif %}\\n\"\n target:\n entity_id: input_boolean.auto_triggered_fan_window_bed_room\n - conditions:\n - condition: template\n value_template: \"{{ \\n trigger.to_state.state == 'off'\\n and is_state('input_boolean.auto_triggered_fan_window_bed_room',\\\n \\ 'on')\\n}}\\n\"\n sequence:\n - action: input_boolean.turn_off\n target:\n entity_id: input_boolean.auto_triggered_fan_window_bed_room\n - choose:\n - conditions:\n - condition: template\n value_template: \"{{ \\n trigger.to_state.state == 'on' and is_state('climate.0x60a423fffe968719',\\\n \\ 'auto') \\n or trigger.to_state.state == 'off' and is_state('climate.0x60a423fffe968719',\\\n \\ 'off') \\n and is_state('input_boolean.auto_triggered_valve_window_bed_room',\\\n \\ 'on')\\n}}\\n\"\n sequence:\n - action: climate.set_hvac_mode\n target:\n entity_id: climate.0x60a423fffe968719\n data:\n hvac_mode: \"{% if trigger.to_state.state == 'on' -%}\\n off\\n{%- else\\\n \\ -%}\\n auto\\n{%- endif %}\\n\"\n - action: \"{% if trigger.to_state.state == 'off' -%}\\n input_boolean.turn_off\\n\\\n {%- else -%}\\n input_boolean.turn_on\\n{%- endif %}\\n\"\n target:\n entity_id: input_boolean.auto_triggered_valve_window_bed_room\n - action: climate.set_preset_mode\n target:\n entity_id: climate.0x60a423fffe968719\n data:\n preset_mode: manual\n - conditions:\n - condition: template\n value_template: \"{{ \\n trigger.to_state.state == 'off' and is_state('climate.0x60a423fffe968719',\\\n \\ 'auto') \\n and is_state('input_boolean.auto_triggered_valve_window_bed_room',\\\n \\ 'on')\\n}}\\n\"\n sequence:\n - action: input_boolean.turn_off\n target:\n entity_id: input_boolean.auto_triggered_valve_window_bed_room",
|
||
"config": [
|
||
{
|
||
"name": "window bed room group",
|
||
"room": "bedroom",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.window_bed_room_group",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "humidifier cb1",
|
||
"room": "bedroom",
|
||
"type": "humidifier",
|
||
"id": {
|
||
"entity_id": "humidifier.zhimi_humidifier_cb1",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "auto triggered fan window bed room",
|
||
"room": "bedroom",
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.auto_triggered_fan_window_bed_room",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "auto triggered valve window bed room",
|
||
"room": "bedroom",
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.auto_triggered_valve_window_bed_room",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "bedroom valve with thermostat",
|
||
"room": "bedroom",
|
||
"type": "climate",
|
||
"id": {
|
||
"entity_id": "climate.0x60a423fffe968719",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "turn on off climate devices kitchen window open close",
|
||
"automation": "- alias: turn on off climate devices kitchen window open close\n id: turn on off climate devices kitchen window open close\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: binary_sensor.window_kitchen_group\n from: 'off'\n to: 'on'\n for: 00:05:00\n - trigger: state\n entity_id: binary_sensor.window_kitchen_group\n from: 'on'\n to: 'off'\n for: 00:01:15\n conditions: \"{{ \\n trigger.to_state.state == 'on' or \\n is_state('input_boolean.auto_triggered_valve_window_kitchen',\\\n \\ 'on') or\\n is_state('input_boolean.auto_triggered_heating_floor_window_kitchen',\\\n \\ 'on')\\n}}\\n\"\n actions:\n - parallel:\n - choose:\n - conditions:\n - condition: template\n value_template: \"{{ \\n trigger.to_state.state == 'on' and is_state('climate.0x5c0272fffe8de819',\\\n \\ 'auto') \\n or trigger.to_state.state == 'off' and is_state('climate.0x5c0272fffe8de819',\\\n \\ 'off') \\n and is_state('input_boolean.auto_triggered_valve_window_kitchen',\\\n \\ 'on')\\n}}\\n\"\n sequence:\n - action: climate.set_hvac_mode\n target:\n entity_id: climate.0x5c0272fffe8de819\n data:\n hvac_mode: \"{% if trigger.to_state.state == 'on' -%}\\n off\\n{%- else\\\n \\ -%}\\n auto\\n{%- endif %}\\n\"\n - action: \"{% if trigger.to_state.state == 'off' -%}\\n input_boolean.turn_off\\n\\\n {%- else -%}\\n input_boolean.turn_on\\n{%- endif %}\\n\"\n target:\n entity_id: input_boolean.auto_triggered_valve_window_kitchen\n - action: climate.set_preset_mode\n target:\n entity_id: climate.0x5c0272fffe8de819\n data:\n preset_mode: manual\n - conditions:\n - condition: template\n value_template: \"{{ \\n trigger.to_state.state == 'off' and is_state('climate.0x5c0272fffe8de819',\\\n \\ 'auto') \\n and is_state('input_boolean.auto_triggered_valve_window_kitchen',\\\n \\ 'on')\\n}}\\n\"\n sequence:\n - action: input_boolean.turn_off\n target:\n entity_id: input_boolean.auto_triggered_valve_window_kitchen\n - choose:\n - conditions:\n - condition: template\n value_template: \"{{ \\n trigger.to_state.state == 'on' and is_state('climate.devireg_k',\\\n \\ 'heat') \\n or trigger.to_state.state == 'off' and is_state('climate.devireg_k',\\\n \\ 'off') \\n and is_state('input_boolean.auto_triggered_heating_floor_window_kitchen',\\\n \\ 'on')\\n}}\\n\"\n sequence:\n - action: climate.set_hvac_mode\n target:\n entity_id: climate.devireg_k\n data:\n hvac_mode: '{{ iif(trigger.to_state.state == ''on'', ''off'', ''heat'')\n }}'\n - action: '{{ iif(trigger.to_state.state == ''off'', ''input_boolean.turn_off''\n , ''input_boolean.turn_on'') }}'\n target:\n entity_id: input_boolean.auto_triggered_heating_floor_window_kitchen\n - conditions:\n - condition: template\n value_template: \"{{ \\n trigger.to_state.state == 'off' and is_state('climate.devireg_k',\\\n \\ 'on') \\n and is_state('input_boolean.auto_triggered_heating_floor_window_kitchen',\\\n \\ 'on')\\n}}\\n\"\n sequence:\n - action: input_boolean.turn_off\n target:\n entity_id: input_boolean.auto_triggered_heating_floor_window_kitchen",
|
||
"config": [
|
||
{
|
||
"name": "window kitchen group",
|
||
"room": "kitchen",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.window_kitchen_group",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "auto triggered valve window kitchen",
|
||
"room": "kitchen",
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.auto_triggered_valve_window_kitchen",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "auto triggered heating floor window kitchen",
|
||
"room": "kitchen",
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.auto_triggered_heating_floor_window_kitchen",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "kitchen valve with thermostat",
|
||
"room": "kitchen",
|
||
"type": "climate",
|
||
"id": {
|
||
"entity_id": "climate.0x5c0272fffe8de819",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "devireg k",
|
||
"room": "kitchen",
|
||
"type": "climate",
|
||
"id": {
|
||
"entity_id": "climate.devireg_k",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "turn on off climate devices living room window open close",
|
||
"automation": "- alias: turn on off climate devices living room window open close\n id: turn on off climate devices living room window open close\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: binary_sensor.window_living_room_group\n from: 'off'\n to: 'on'\n for: 00:05:00\n - trigger: state\n entity_id: binary_sensor.window_living_room_group\n from: 'on'\n to: 'off'\n for: 00:01:15\n conditions: \"{{ \\n trigger.to_state.state == 'on' or\\n is_state('input_boolean.auto_triggered_ac_window_living_room',\\\n \\ 'on') or \\n is_state('input_boolean.auto_triggered_valve_window_living_room',\\\n \\ 'on')\\n}}\\n\"\n actions:\n - choose:\n - conditions:\n - condition: template\n value_template: \"{{ \\n trigger.to_state.state == 'on' and states('climate.avatto_living_room_ac')\\\n \\ == 'cool'\\n or trigger.to_state.state == 'off' and is_state('climate.avatto_living_room_ac',\\\n \\ 'off')\\n and is_state('input_boolean.auto_triggered_ac_window_living_room',\\\n \\ 'on')\\n}}\\n\"\n sequence:\n - action: climate.set_hvac_mode\n target:\n entity_id: climate.avatto_living_room_ac\n data:\n hvac_mode: \"{% if trigger.to_state.state == 'on' -%}\\n off\\n{%- else -%}\\n\\\n \\ cool\\n{%- endif %}\\n\"\n - action: \"{% if trigger.to_state.state == 'off' -%}\\n input_boolean.turn_off\\n\\\n {%- else -%}\\n input_boolean.turn_on\\n{%- endif %}\\n\"\n target:\n entity_id: input_boolean.auto_triggered_ac_window_living_room\n - conditions:\n - condition: template\n value_template: \"{{ \\n trigger.to_state.state == 'off' and is_state('climate.avatto_living_room_ac',\\\n \\ 'cool')\\n and is_state('input_boolean.auto_triggered_ac_window_living_room',\\\n \\ 'on')\\n}}\\n\"\n sequence:\n - action: input_boolean.turn_off\n target:\n entity_id: input_boolean.auto_triggered_ac_window_living_room\n - choose:\n - conditions:\n - condition: template\n value_template: \"{{ \\n trigger.to_state.state == 'on' and is_state('climate.0x5c0272fffec9db22',\\\n \\ 'auto') \\n or trigger.to_state.state == 'off' and is_state('climate.0x5c0272fffec9db22',\\\n \\ 'off') \\n and is_state('input_boolean.auto_triggered_valve_window_living_room',\\\n \\ 'on')\\n}}\\n\"\n sequence:\n - action: climate.set_hvac_mode\n target:\n entity_id: climate.0x5c0272fffec9db22\n data:\n hvac_mode: \"{% if trigger.to_state.state == 'on' -%}\\n off\\n{%- else -%}\\n\\\n \\ auto\\n{%- endif %}\\n\"\n - action: \"{% if trigger.to_state.state == 'off' -%}\\n input_boolean.turn_off\\n\\\n {%- else -%}\\n input_boolean.turn_on\\n{%- endif %}\\n\"\n target:\n entity_id: input_boolean.auto_triggered_valve_window_living_room\n - action: climate.set_preset_mode\n target:\n entity_id: climate.0x5c0272fffec9db22\n data:\n preset_mode: manual\n - conditions:\n - condition: template\n value_template: \"{{ \\n trigger.to_state.state == 'off' and is_state('climate.0x5c0272fffec9db22',\\\n \\ 'auto') \\n and is_state('input_boolean.auto_triggered_valve_window_living_room',\\\n \\ 'on')\\n}}\\n\"\n sequence:\n - action: input_boolean.turn_off\n target:\n entity_id: input_boolean.auto_triggered_valve_window_living_room",
|
||
"config": [
|
||
{
|
||
"name": "window living room group",
|
||
"room": "living_room",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.window_living_room_group",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "auto triggered ac window living room",
|
||
"room": "living_room",
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.auto_triggered_ac_window_living_room",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "auto triggered valve window living room",
|
||
"room": "living_room",
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.auto_triggered_valve_window_living_room",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "avatto living room ac",
|
||
"room": "living_room",
|
||
"type": "climate",
|
||
"id": {
|
||
"entity_id": "climate.avatto_living_room_ac",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "living room valve with thermostat",
|
||
"room": "living_room",
|
||
"type": "climate",
|
||
"id": {
|
||
"entity_id": "climate.0x5c0272fffec9db22",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "restart socket 2 for bedroom air humidifier unavailable",
|
||
"automation": "- alias: restart socket 2 for bedroom air humidifier unavailable\n id: restart socket 2 for bedroom air humidifier unavailable\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: humidifier.zhimi_humidifier_cb1\n to: null\n - trigger: homeassistant\n event: start\n conditions:\n - condition: state\n entity_id: input_boolean.instances_stoping\n state: 'off'\n - '{{ not has_value(''humidifier.zhimi_humidifier_cb1'') }}'\n - condition: state\n entity_id: switch.0x60a423fffef8d41a\n state: 'on'\n actions:\n - wait_template: '{{ has_value(''humidifier.zhimi_humidifier_cb1'') }}'\n timeout: 00:05:00\n - choose:\n - conditions: '{{ wait.completed == false and is_state(''binary_sensor.local_network_availability'',\n ''on'') }}'\n sequence:\n - action: switch.turn_off\n target:\n entity_id: switch.0x60a423fffef8d41a\n - delay:\n seconds: 5\n - action: switch.turn_on\n target:\n entity_id: switch.0x60a423fffef8d41a",
|
||
"config": [
|
||
{
|
||
"name": "humidifier cb1",
|
||
"room": "bedroom",
|
||
"type": "humidifier",
|
||
"id": {
|
||
"entity_id": "humidifier.zhimi_humidifier_cb1",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "bedroom socket 2",
|
||
"room": "bedroom",
|
||
"type": "switch",
|
||
"id": {
|
||
"entity_id": "switch.0x60a423fffef8d41a",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "local network availability",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.local_network_availability",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "instances stoping",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.instances_stoping",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notification public ip compare debug",
|
||
"automation": "- alias: notification public ip compare debug\n id: notification public ip compare debug\n trigger_variables:\n not_has_state: '{{ [''unknown'', ''unavailable'', ''none'', None, null, '''']\n }}'\n triggers:\n - trigger: state\n entity_id: sensor.myip_keenetic\n conditions: \"{{ trigger.from_state.state not in not_has_state and\\n trigger.to_state.state\\\n \\ not in not_has_state and\\n trigger.from_state.state = trigger.to_state.state\\\n \\ and\\n trigger.to_state.state = states('sensor.myip')\\n}}\\n\"\n actions:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n title: '{{ ''\\U0001f4f6'' }} *Трекинг устройств*'\n message: Внешний IP-адрес keendns `{{ trigger.to_state.state }}` не равен физическому\n `{{ states('sensor.myip') }}`",
|
||
"config": [
|
||
{
|
||
"name": "myip keenetic",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.myip_keenetic",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "myip",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.myip",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "turn_on_doorbell",
|
||
"automation": "- alias: turn_on_doorbell\n id: turn_on_doorbell\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: sensor.0x158d00045a78af_action\n conditions:\n - condition: state\n entity_id: timer.doorbell_timer_restart_automation\n state: idle\n - condition: state\n entity_id: input_boolean.alarm_gateway_button\n state: 'off'\n - condition: state\n entity_id: alarm_control_panel.signalka_shliuza_alarm\n state: disarmed\n - condition: template\n value_template: '{{ trigger.to_state.state not in [''release'', ''unavailable'',\n ''unknown'', '''', ''None''] }}\n\n '\n actions:\n - action: timer.start\n target:\n entity_id: timer.doorbell_timer_restart_automation\n - parallel:\n - sequence:\n - variables:\n string_now_time: '{{ now().strftime(''%Y%m%d-%H%M%S'') }}'\n - action: camera.snapshot\n target:\n entity_id: camera.hallway_1_fluent\n data:\n filename: /share/DS_Obmen/Doorbeel_Snapshots/snapshot_hallway_1_{{ string_now_time\n }}.jpg\n - action: telegram_bot.send_photo\n data:\n file: /share/DS_Obmen/Doorbeel_Snapshots/snapshot_hallway_1_{{ string_now_time\n }}.jpg\n caption: '{{ ''🔔'' }} *Кто-то звонит в дверь*'\n target: secret telegram_all_chat_id\n - action: telegram_bot.send_video\n data:\n url: http://localhost:1984/api/stream.mp4?src=hallway_1_sub&mp4=flac&duration=5&filename=record.mp4\n caption: '{{ ''🔔'' }} *Кто-то звонит в дверь*'\n target: secret telegram_enzokot_chat_id\n - sequence:\n - condition:\n - condition: time\n after: '8:00:00'\n before: '21:30:00'\n - action: xiaomi_aqara.stop_ringtone\n data:\n gw_mac: secret gateway1_mac\n - action: xiaomi_aqara.play_ringtone\n data:\n gw_mac: secret gateway1_mac\n ringtone_id: 10001\n ringtone_vol: 45\n - sequence:\n - condition:\n - condition: state\n entity_id: automation.light_gateway_toggle\n attribute: current\n state: 0\n - action: scene.create\n data:\n scene_id: before_doorbell_light\n snapshot_entities:\n - light.gateway_light_04cf8cabd77b\n - repeat:\n while:\n - condition: template\n value_template: '{{ repeat.index <= 3 }}'\n sequence:\n - action: light.turn_on\n target:\n entity_id: light.gateway_light_04cf8cabd77b\n data:\n rgb_color:\n - 255\n - 128\n - 0\n brightness: 128\n - delay:\n milliseconds: 150\n - action: light.turn_off\n target:\n entity_id: light.gateway_light_04cf8cabd77b\n - delay:\n milliseconds: 50\n - action: light.turn_on\n target:\n entity_id: light.gateway_light_04cf8cabd77b\n data:\n rgb_color:\n - 255\n - 128\n - 0\n brightness: 128\n - delay:\n milliseconds: 150\n - action: light.turn_off\n target:\n entity_id: light.gateway_light_04cf8cabd77b\n - action: scene.turn_on\n target:\n entity_id: scene.before_doorbell_light\n - sequence:\n - condition:\n - condition: time\n after: '8:00:00'\n before: '21:30:00'\n - parallel:\n - action: script.alice_custom_tts_volume\n data:\n entity: media_player.yandex_station_ff98f029b620413b35e5e278\n text: Кто то звонит в дверь\n vol_level: '0.65'\n - action: script.alice_custom_tts_volume\n data:\n entity: media_player.yandex_station_m00ka4300h99tr\n text: Кто то звонит в дверь\n vol_level: '0.45'",
|
||
"config": [
|
||
{
|
||
"name": "gateway light",
|
||
"room": "hallway",
|
||
"type": "light",
|
||
"id": {
|
||
"entity_id": "light.gateway_light_04cf8cabd77b",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "alarm gateway button",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.alarm_gateway_button",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "shliuza alarm control panel",
|
||
"room": null,
|
||
"type": "alarm_control_panel",
|
||
"id": {
|
||
"entity_id": "alarm_control_panel.signalka_shliuza_alarm",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "doorbell timer restart automation",
|
||
"room": null,
|
||
"type": "timer",
|
||
"id": {
|
||
"entity_id": "timer.doorbell_timer_restart_automation",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "doorbell action sensor",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x158d00045a78af_action",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "hallway 1 camera",
|
||
"room": "hallway",
|
||
"type": "camera",
|
||
"id": {
|
||
"entity_id": "camera.hallway_1_fluent",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "light gateway toggle automation",
|
||
"room": null,
|
||
"type": "automation",
|
||
"id": {
|
||
"entity_id": "automation.light_gateway_toggle",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "scene before doorbell light",
|
||
"room": null,
|
||
"type": "scene",
|
||
"id": {
|
||
"entity_id": "scene.before_doorbell_light",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "yandex station 1",
|
||
"room": null,
|
||
"type": "media_player",
|
||
"id": {
|
||
"entity_id": "media_player.yandex_station_ff98f029b620413b35e5e278",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "yandex station 2",
|
||
"room": null,
|
||
"type": "media_player",
|
||
"id": {
|
||
"entity_id": "media_player.yandex_station_m00ka4300h99tr",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "alice custom tts volume script",
|
||
"room": null,
|
||
"type": "script",
|
||
"id": {
|
||
"entity_id": "script.alice_custom_tts_volume",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram All Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_all_chat_id",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "dynamic group sensor battery",
|
||
"automation": "- alias: dynamic group sensor battery\n id: dynamic group sensor battery\n initial_state: true\n mode: restart\n triggers:\n - trigger: event\n event_type: entity_registry_updated\n - trigger: homeassistant\n event: start\n actions:\n - action: group.set\n data:\n name: dynamic group sensor battery\n object_id: dynamic_group_sensor_battery\n icon: mdi:battery-unknown\n entities: \"{%- set datanames = namespace(entity_name=[]) -%} {%- \\n for state\\\n \\ in states.sensor \\n if is_state_attr(state.entity_id, 'device_class',\\\n \\ 'battery') and\\n (state.entity_id.endswith(\\\"_battery\\\") or state.entity_id.endswith(\\\"\\\n _battery_level\\\"))\\n%}\\n {% set datanames.entity_name = datanames.entity_name\\\n \\ + [state.entity_id] -%}\\n{%- endfor %} {%- \\n for state in states.binary_sensor\\\n \\ \\n if is_state_attr(state.entity_id, 'device_class', 'battery') and\\n\\\n \\ state.entity_id.endswith(\\\"_low_battery\\\")\\n%}\\n {% set datanames.entity_name\\\n \\ = datanames.entity_name + [state.entity_id] -%}\\n{%- endfor %} {{ datanames.entity_name\\\n \\ | list | join(', ')}}\"",
|
||
"config": []
|
||
},
|
||
{
|
||
"id": "dynamic group sensor linkquality",
|
||
"automation": "- alias: dynamic group sensor linkquality\n id: dynamic group sensor linkquality\n initial_state: true\n mode: restart\n triggers:\n - trigger: event\n event_type: entity_registry_updated\n - trigger: homeassistant\n event: start\n conditions:\n - '{{ states.sensor | map(attribute=''entity_id'') | list | regex_findall(find=''(_linkquality|_zigbee)'',\n ignorecase=True) | length > 0 }}'\n actions:\n - action: group.set\n data:\n name: dynamic group sensor linkquality\n object_id: dynamic_group_sensor_linkquality\n icon: mdi:signal\n entities: \"{%- \\n for state in states.sensor \\n if state.entity_id.endswith(\\\"\\\n _linkquality\\\") or state.entity_id.endswith(\\\"_zigbee\\\")\\n%}\\n {{ state.entity_id\\\n \\ }}{%- if not loop.last -%}, {%- endif -%}\\n{%- endfor %}\"",
|
||
"config": []
|
||
},
|
||
{
|
||
"id": "dynamic group sensor last seen",
|
||
"automation": "- alias: dynamic group sensor last seen\n id: dynamic group sensor last seen\n initial_state: true\n mode: restart\n triggers:\n - trigger: event\n event_type: entity_registry_updated\n - trigger: homeassistant\n event: start\n conditions:\n - '{{ states.sensor | map(attribute=''entity_id'') | list | regex_findall(find=''(_last_seen|_zigbee)'',\n ignorecase=True) | length > 0 }}'\n actions:\n - action: group.set\n data:\n name: dynamic group sensor last seen\n object_id: dynamic_group_sensor_last_seen\n icon: mdi:clock\n entities: \"{%- \\n for state in states.sensor \\n if state.entity_id.endswith(\\\"\\\n _last_seen\\\") or state.entity_id.endswith(\\\"_zigbee\\\")\\n%}\\n {{ state.entity_id\\\n \\ }}{%- if not loop.last -%}, {%- endif -%}\\n{%- endfor %}\"",
|
||
"config": []
|
||
},
|
||
{
|
||
"id": "dynamic group gateway alarm last state",
|
||
"automation": "- alias: dynamic group gateway alarm last state\n id: dynamic group gateway alarm last state\n initial_state: true\n mode: queued\n triggers:\n - trigger: state\n entity_id:\n - alarm_control_panel.54ef44315770_alarm\n - alarm_control_panel.54ef44cb80fd_alarm\n - alarm_control_panel.54ef443127b2_alarm\n to: triggered\n - trigger: state\n entity_id: input_boolean.alarm_gateway_button\n to: 'on'\n conditions:\n - condition: or\n conditions:\n - '{{ states.alarm_control_panel | selectattr(''state'', ''in'', [''armed_away'',\n ''disarmed'']) | rejectattr(''entity_id'', ''eq'', ''alarm_control_panel.signalka_shliuza_alarm'')\n | list | count > 0 }}'\n - '{{ trigger.from_state.state in [''armed_away'', ''disarmed''] }}'\n actions:\n - parallel:\n - choose:\n - conditions:\n - \"{{ trigger.from_state.state == 'armed_away'\\n or states.alarm_control_panel\\\n \\ \\n| selectattr('state', 'eq', 'armed_away') | rejectattr('entity_id',\\\n \\ 'eq', 'alarm_control_panel.signalka_shliuza_alarm') | list | count >\\\n \\ 0 }}\"\n sequence:\n - action: group.set\n data:\n name: dynamic group gateway alarm last state armed away\n object_id: dynamic_group_gateway_alarm_last_state_armed_away\n icon: mdi:shield-lock\n entities: \"{% set data = namespace(entities=[]) %} {% set data.entities\\\n \\ = data.entities + \\n states.alarm_control_panel \\n | selectattr('state',\\\n \\ 'eq', 'armed_away') \\n | rejectattr('entity_id', 'eq', 'alarm_control_panel.signalka_shliuza_alarm')\\\n \\ \\n | map(attribute = 'entity_id') | list\\n%} {% if trigger.from_state.state\\\n \\ == 'armed_away' %}\\n {% set data.entities = data.entities + [trigger.entity_id]\\\n \\ %}\\n{% endif %} {% if states.group.dynamic_group_gateway_alarm_last_state_armed_away\\\n \\ is not none %}\\n {% set data.entities = data.entities + expand('group.dynamic_group_gateway_alarm_last_state_armed_away')\\\n \\ | map(attribute = 'entity_id') | list %}\\n{% endif %} {{ data.entities\\\n \\ | unique | join(', ') }}\"\n - choose:\n - conditions:\n - \"{{ trigger.from_state.state == 'disarmed'\\n or states.alarm_control_panel\\\n \\ \\n| selectattr('state', 'eq', 'disarmed') | rejectattr('entity_id', 'eq',\\\n \\ 'alarm_control_panel.signalka_shliuza_alarm') | list | count > 0 }}\"\n sequence:\n - action: group.set\n data:\n name: dynamic group gateway alarm last state disarmed\n object_id: dynamic_group_gateway_alarm_last_state_disarmed\n icon: mdi:shield-lock\n entities: \"{% set data = namespace(entities=[]) %} {% set data.entities\\\n \\ = data.entities + \\n states.alarm_control_panel \\n | selectattr('state',\\\n \\ 'eq', 'disarmed') \\n | rejectattr('entity_id', 'eq', 'alarm_control_panel.signalka_shliuza_alarm')\\\n \\ \\n | map(attribute = 'entity_id') | list\\n%} {% if trigger.from_state.state\\\n \\ == 'disarmed' %}\\n {% set data.entities = data.entities + [trigger.entity_id]\\\n \\ %}\\n{% endif %} {% if states.group.dynamic_group_gateway_alarm_last_state_disarmed\\\n \\ is not none %}\\n {% set data.entities = data.entities + expand('group.dynamic_group_gateway_alarm_last_state_disarmed')\\\n \\ | map(attribute = 'entity_id') | list %}\\n{% endif %} {{ data.entities\\\n \\ | unique | join(', ') }}\"",
|
||
"config": [
|
||
{
|
||
"name": "alarm gateway button",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.alarm_gateway_button",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "shliuza alarm control panel",
|
||
"room": null,
|
||
"type": "alarm_control_panel",
|
||
"id": {
|
||
"entity_id": "alarm_control_panel.signalka_shliuza_alarm",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "dynamic group gateway alarm last state disarmed",
|
||
"room": null,
|
||
"type": "group",
|
||
"id": {
|
||
"entity_id": "group.dynamic_group_gateway_alarm_last_state_disarmed",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "dynamic group gateway alarm last state armed away",
|
||
"room": null,
|
||
"type": "group",
|
||
"id": {
|
||
"entity_id": "group.dynamic_group_gateway_alarm_last_state_armed_away",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "alarm gateway 1",
|
||
"room": null,
|
||
"type": "alarm_control_panel",
|
||
"id": {
|
||
"entity_id": "alarm_control_panel.54ef44315770_alarm",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "alarm gateway 2",
|
||
"room": null,
|
||
"type": "alarm_control_panel",
|
||
"id": {
|
||
"entity_id": "alarm_control_panel.54ef44cb80fd_alarm",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "alarm gateway 3",
|
||
"room": null,
|
||
"type": "alarm_control_panel",
|
||
"id": {
|
||
"entity_id": "alarm_control_panel.54ef443127b2_alarm",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "install update html5 push notifications",
|
||
"automation": "- alias: install update html5 push notifications\n id: install update html5 push notifications\n initial_state: true\n mode: parallel\n triggers:\n - trigger: event\n event_type: html5_notification.clicked\n event_data:\n action: install_update\n conditions:\n - '{{ trigger.event.data[''tag''] | length > 0 }}'\n actions:\n - variables:\n entity: '{{- trigger.event.data[''tag''] | replace(''update_available_notify_'',\n ''update.'') -}}'\n - if:\n - '{{ is_state(entity, ''on'') and is_state_attr(entity, ''in_progress'', false)\n }}'\n then:\n - action: update.install\n target:\n entity_id: '{{- entity -}}'\n data:\n backup: '{{ ''{:0=64b}''.format(state_attr(entity, ''supported_features''))[-4]\n == ''1'' }}'",
|
||
"config": []
|
||
},
|
||
{
|
||
"id": "open shades kitchen on outside light sensor",
|
||
"automation": "- alias: open shades kitchen on outside light sensor\n id: open shades kitchen on outside light sensor\n mode: restart\n trigger_variables:\n not_has_state: '{{ [''unknown'', ''unavailable'', ''none'', ''''] }}'\n triggers:\n - trigger: numeric_state\n entity_id: sensor.0x54ef4410000ebba0_illuminance\n above: 250\n for:\n minutes: 10\n - trigger: numeric_state\n id: sun\n entity_id: sun.sun\n attribute: elevation\n above: 4\n conditions:\n - condition: template\n value_template: \"{{ \\n trigger.id == 'sun' or\\n trigger.from_state.state not\\\n \\ in not_has_state and \\n trigger.from_state.state != trigger.to_state.state\\n\\\n }}\"\n - '{{ is_state_attr(''sun.sun'', ''rising'', true) }}'\n - '{{ expand(''cover.cover_group_kitchen'') | selectattr(''state'', ''eq'', ''open'')\n | map(attribute=''entity_id'') | list | length == 0 }}'\n actions:\n - action: script.auto_cover_open_close_kitchen\n data:\n servicename: cover.open_cover\n groupname: cover.cover_group_kitchen\n statename: open",
|
||
"config": [
|
||
{
|
||
"name": "outside illuminance sensor",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x54ef4410000ebba0_illuminance",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "sun",
|
||
"room": null,
|
||
"type": "sun",
|
||
"id": {
|
||
"entity_id": "sun.sun",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "cover group kitchen",
|
||
"room": "kitchen",
|
||
"type": "cover",
|
||
"id": {
|
||
"entity_id": "cover.cover_group_kitchen",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "auto cover open close kitchen script",
|
||
"room": "kitchen",
|
||
"type": "script",
|
||
"id": {
|
||
"entity_id": "script.auto_cover_open_close_kitchen",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "close shades kitchen on outside light sensor",
|
||
"automation": "- alias: close shades kitchen on outside light sensor\n id: close shades kitchen on outside light sensor\n mode: restart\n trigger_variables:\n not_has_state: '{{ [''unknown'', ''unavailable'', ''none'', ''''] }}'\n triggers:\n - trigger: numeric_state\n entity_id: sensor.0x54ef4410000ebba0_illuminance\n below: 150\n for:\n minutes: 10\n conditions:\n - condition: template\n value_template: \"{{ \\n trigger.from_state.state not in not_has_state and \\n \\\n \\ trigger.from_state.state != trigger.to_state.state\\n}}\"\n - '{{ state_attr(''sun.sun'', ''elevation'') | float(0.0) <= iif(states(''weather.kotletochka_home'')\n in [''rainy'', ''pouring'', ''cloudy'', ''lightning'', ''lightning-rainy'', ''partlycloudy''],\n 15, 7, 7) }}'\n - '{{ is_state_attr(''sun.sun'', ''rising'', false) }}'\n - '{{ expand(''cover.cover_group_kitchen'') | selectattr(''state'', ''eq'', ''closed'')\n | map(attribute=''entity_id'') | list | length == 0 }}'\n actions:\n - action: script.auto_cover_open_close_kitchen\n data:\n servicename: cover.close_cover\n groupname: cover.cover_group_kitchen\n statename: closed",
|
||
"config": [
|
||
{
|
||
"name": "outside illuminance sensor",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x54ef4410000ebba0_illuminance",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "sun",
|
||
"room": null,
|
||
"type": "sun",
|
||
"id": {
|
||
"entity_id": "sun.sun",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "weather",
|
||
"room": null,
|
||
"type": "weather",
|
||
"id": {
|
||
"entity_id": "weather.kotletochka_home",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "cover group kitchen",
|
||
"room": "kitchen",
|
||
"type": "cover",
|
||
"id": {
|
||
"entity_id": "cover.cover_group_kitchen",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "auto cover open close kitchen script",
|
||
"room": "kitchen",
|
||
"type": "script",
|
||
"id": {
|
||
"entity_id": "script.auto_cover_open_close_kitchen",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "close shades kitchen on sun and min outside lux",
|
||
"automation": "- alias: close shades kitchen on sun and min outside lux\n id: close shades kitchen on sun and min outside lux\n mode: restart\n triggers:\n - trigger: numeric_state\n entity_id: sun.sun\n attribute: elevation\n below: 2\n conditions:\n - '{{ states(''sensor.0x54ef4410000ebba0_illuminance'') | int(0) <= 250 }}'\n - '{{ is_state_attr(''sun.sun'', ''rising'', false) }}'\n - '{{ expand(''cover.cover_group_kitchen'') | selectattr(''state'', ''eq'', ''closed'')\n | map(attribute=''entity_id'') | list | length == 0 }}'\n actions:\n - action: script.auto_cover_open_close_kitchen\n data:\n servicename: cover.close_cover\n groupname: cover.cover_group_kitchen\n statename: closed",
|
||
"config": [
|
||
{
|
||
"name": "outside illuminance sensor",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x54ef4410000ebba0_illuminance",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "sun",
|
||
"room": null,
|
||
"type": "sun",
|
||
"id": {
|
||
"entity_id": "sun.sun",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "cover group kitchen",
|
||
"room": "kitchen",
|
||
"type": "cover",
|
||
"id": {
|
||
"entity_id": "cover.cover_group_kitchen",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "auto cover open close kitchen script",
|
||
"room": "kitchen",
|
||
"type": "script",
|
||
"id": {
|
||
"entity_id": "script.auto_cover_open_close_kitchen",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "open shades living room on outside light sensor",
|
||
"automation": "- alias: open shades living room on outside light sensor\n id: open shades living room on outside light sensor\n mode: restart\n trigger_variables:\n not_has_state: '{{ [''unknown'', ''unavailable'', ''none'', ''''] }}'\n triggers:\n - trigger: numeric_state\n entity_id: sensor.0x54ef4410000ebba0_illuminance\n above: 250\n for:\n minutes: 10\n - trigger: numeric_state\n id: sun\n entity_id: sun.sun\n attribute: elevation\n above: 4\n conditions:\n - condition: template\n value_template: \"{{ \\n trigger.id == 'sun' or\\n trigger.from_state.state not\\\n \\ in not_has_state and \\n trigger.from_state.state != trigger.to_state.state\\n\\\n }}\"\n - '{{ is_state_attr(''sun.sun'', ''rising'', true) }}'\n - '{{ expand(''cover.cover_group_living_room'') | selectattr(''state'', ''eq'',\n ''open'') | map(attribute=''entity_id'') | list | length == 0 }}'\n actions:\n - action: script.auto_cover_open_close_living_room\n data:\n servicename: cover.open_cover\n groupname: cover.cover_group_living_room\n statename: open",
|
||
"config": [
|
||
{
|
||
"name": "outside illuminance sensor",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x54ef4410000ebba0_illuminance",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "sun",
|
||
"room": null,
|
||
"type": "sun",
|
||
"id": {
|
||
"entity_id": "sun.sun",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "cover group living room",
|
||
"room": "living_room",
|
||
"type": "cover",
|
||
"id": {
|
||
"entity_id": "cover.cover_group_living_room",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "auto cover open close living room script",
|
||
"room": "living_room",
|
||
"type": "script",
|
||
"id": {
|
||
"entity_id": "script.auto_cover_open_close_living_room",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "close shades living room on outside light sensor",
|
||
"automation": "- alias: close shades living room on outside light sensor\n id: close shades living room on outside light sensor\n mode: restart\n trigger_variables:\n not_has_state: '{{ [''unknown'', ''unavailable'', ''none'', ''''] }}'\n triggers:\n - trigger: numeric_state\n entity_id: sensor.0x54ef4410000ebba0_illuminance\n below: 150\n for:\n minutes: 10\n conditions:\n - condition: template\n value_template: \"{{ \\n trigger.from_state.state not in not_has_state and \\n \\\n \\ trigger.from_state.state != trigger.to_state.state\\n}}\"\n - '{{ state_attr(''sun.sun'', ''elevation'') | float(0.0) <= iif(states(''weather.kotletochka_home'')\n in [''rainy'', ''pouring'', ''cloudy'', ''lightning'', ''lightning-rainy'', ''partlycloudy''],\n 15, 7, 7) }}'\n - '{{ is_state_attr(''sun.sun'', ''rising'', false) }}'\n - '{{ expand(''cover.cover_group_living_room'') | selectattr(''state'', ''eq'',\n ''closed'') | map(attribute=''entity_id'') | list | length == 0 }}'\n actions:\n - action: script.auto_cover_open_close_living_room\n data:\n servicename: cover.close_cover\n groupname: cover.cover_group_living_room\n statename: closed",
|
||
"config": [
|
||
{
|
||
"name": "outside illuminance sensor",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x54ef4410000ebba0_illuminance",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "sun",
|
||
"room": null,
|
||
"type": "sun",
|
||
"id": {
|
||
"entity_id": "sun.sun",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "weather",
|
||
"room": null,
|
||
"type": "weather",
|
||
"id": {
|
||
"entity_id": "weather.kotletochka_home",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "cover group living room",
|
||
"room": "living_room",
|
||
"type": "cover",
|
||
"id": {
|
||
"entity_id": "cover.cover_group_living_room",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "auto cover open close living room script",
|
||
"room": "living_room",
|
||
"type": "script",
|
||
"id": {
|
||
"entity_id": "script.auto_cover_open_close_living_room",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "close shades living room on sun and min outside lux",
|
||
"automation": "- alias: close shades living room on sun and min outside lux\n id: close shades living room on sun and min outside lux\n mode: restart\n triggers:\n - trigger: numeric_state\n entity_id: sun.sun\n attribute: elevation\n below: 2\n conditions:\n - '{{ states(''sensor.0x54ef4410000ebba0_illuminance'') | int(0) <= 250 }}'\n - '{{ is_state_attr(''sun.sun'', ''rising'', false) }}'\n - '{{ expand(''cover.cover_group_living_room'') | selectattr(''state'', ''eq'',\n ''closed'') | map(attribute=''entity_id'') | list | length == 0 }}'\n actions:\n - action: script.auto_cover_open_close_living_room\n data:\n servicename: cover.close_cover\n groupname: cover.cover_group_living_room\n statename: closed",
|
||
"config": [
|
||
{
|
||
"name": "outside illuminance sensor",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x54ef4410000ebba0_illuminance",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "sun",
|
||
"room": null,
|
||
"type": "sun",
|
||
"id": {
|
||
"entity_id": "sun.sun",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "cover group living room",
|
||
"room": "living_room",
|
||
"type": "cover",
|
||
"id": {
|
||
"entity_id": "cover.cover_group_living_room",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "auto cover open close living room script",
|
||
"room": "living_room",
|
||
"type": "script",
|
||
"id": {
|
||
"entity_id": "script.auto_cover_open_close_living_room",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "reply pong to ping",
|
||
"automation": "- alias: reply pong to ping\n id: reply pong to ping\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: telegram_command\n event_data:\n command: /ping\n actions:\n - parallel:\n - action: notify.notify\n data:\n title: ℹ️ Check notification's\n message: pong\n - action: telegram_bot.delete_message\n data:\n chat_id: '{{ trigger.event.data.chat_id }}'\n message_id: '{{ trigger.event.data.id }}'\n - action: telegram_bot.send_message\n data:\n target: '{{ trigger.event.data.chat_id }}'\n message: ℹ️ pong\n - action: notify.huawei_lte\n data:\n message: ℹ️ pong\n target: secret sms_phone_enzokot\n data:\n url: http://192.168.8.1/\n - action: notify.html5\n data:\n title: ℹ️ Check notification's\n message: pong\n - action: notify.email_enzokot_ha\n data:\n title: ℹ️ Check notification's\n message: pong",
|
||
"config": [
|
||
{
|
||
"name": "SMS Phone Enzokot Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret sms_phone_enzokot",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "keyboard tuc tuc gateway",
|
||
"automation": "- alias: keyboard tuc tuc gateway\n id: keyboard tuc tuc gateway\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: telegram_command\n event_data:\n command: /tuctuc\n actions:\n - parallel:\n - action: telegram_bot.delete_message\n data:\n chat_id: '{{ trigger.event.data.chat_id }}'\n message_id: '{{ trigger.event.data.id }}'\n - action: telegram_bot.send_message\n data:\n target: '{{ trigger.event.data.chat_id }}'\n message: '{{ ''\\U0001f4e2'' }} С уровнем громкости:'\n inline_keyboard:\n - Тихо:/minlevelsound\n - Средне:/avrlevelsound, Громко:/maxlevelsound",
|
||
"config": []
|
||
},
|
||
{
|
||
"id": "keyboard alarm home",
|
||
"automation": "- alias: keyboard alarm home\n id: keyboard alarm home\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: telegram_command\n event_data:\n command: /home_alarm\n actions:\n - action: telegram_bot.delete_message\n data:\n chat_id: '{{ trigger.event.data.chat_id }}'\n message_id: '{{ trigger.event.data.id }}'\n - action: telegram_bot.send_message\n data:\n target: '{{ trigger.event.data.chat_id }}'\n message: \"{% if is_state('alarm_control_panel.signalka_shliuza_alarm', 'armed_away')\\\n \\ -%}\\n {{ '\\\\U0001f509' }} Сигнализация *включена*\\n{%- else -%}\\n \\\n \\ {{ '\\\\U0001f507' }} Сигнализация *выключена*\\n{%- endif %}\"\n inline_keyboard: \"{% if is_state('alarm_control_panel.signalka_shliuza_alarm',\\\n \\ 'armed_away') -%}\\n Выключить:/alarm_home_disarm\\n{%- else -%}\\n Включить:/alarm_home_arm\\n\\\n {%- endif %}\"",
|
||
"config": [
|
||
{
|
||
"name": "shliuza alarm control panel",
|
||
"room": null,
|
||
"type": "alarm_control_panel",
|
||
"id": {
|
||
"entity_id": "alarm_control_panel.signalka_shliuza_alarm",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "do alarm change state",
|
||
"automation": "- alias: do alarm change state\n id: do alarm change state\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: telegram_callback\n event_data:\n data: /alarm_home_disarm\n - trigger: event\n event_type: telegram_callback\n event_data:\n data: /alarm_home_arm\n actions:\n - action: telegram_bot.delete_message\n data:\n chat_id: '{{ trigger.event.data.chat_id }}'\n message_id: '{{ trigger.event.data.message.message_id }}'\n - action: \"{% if trigger.event.data.command == '/alarm_home_disarm' -%}\\n alarm_control_panel.alarm_disarm\\n\\\n {%- else -%}\\n alarm_control_panel.alarm_arm_away\\n{%- endif %}\"\n target:\n entity_id: alarm_control_panel.signalka_shliuza_alarm\n - action: telegram_bot.answer_callback_query\n data:\n callback_query_id: '{{ trigger.event.data.id }}'\n message: \"{% if trigger.event.data.command == '/alarm_home_disarm' -%}\\n Выключили\\\n \\ сигнализацию\\n{%- else -%}\\n Включили сигнализацию\\n{%- endif %}\"",
|
||
"config": [
|
||
{
|
||
"name": "shliuza alarm control panel",
|
||
"room": null,
|
||
"type": "alarm_control_panel",
|
||
"id": {
|
||
"entity_id": "alarm_control_panel.signalka_shliuza_alarm",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "do tuc tuc gateway",
|
||
"automation": "- alias: do tuc tuc gateway\n id: do tuc tuc gateway\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: telegram_callback\n event_data:\n data: /minlevelsound\n - trigger: event\n event_type: telegram_callback\n event_data:\n data: /avrlevelsound\n - trigger: event\n event_type: telegram_callback\n event_data:\n data: /maxlevelsound\n actions:\n - parallel:\n - action: telegram_bot.delete_message\n data:\n chat_id: '{{ trigger.event.data.chat_id }}'\n message_id: '{{ trigger.event.data.message.message_id }}'\n - action: xiaomi_aqara.play_ringtone\n data:\n gw_mac: secret gateway1_mac\n ringtone_id: 11\n ringtone_vol: \"{%- if trigger.event.data.data == \\\"/maxlevelsound\\\" -%}\\n\\\n \\ 50\\n{%- elif trigger.event.data.data == \\\"/avrlevelsound\\\" -%}\\n 25\\n\\\n {%- else -%}\\n 3\\n{%- endif -%}\"\n - action: telegram_bot.answer_callback_query\n data:\n callback_query_id: '{{ trigger.event.data.id }}'\n message: Постучали шлюзом",
|
||
"config": []
|
||
},
|
||
{
|
||
"id": "del keyboard sync yeelight ceiling to switch",
|
||
"automation": "- alias: del keyboard sync yeelight ceiling to switch\n id: del keyboard sync yeelight ceiling to switch\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: telegram_callback\n event_data:\n data: /changelight\n - trigger: event\n event_type: telegram_callback\n event_data:\n data: /nochangelight\n - trigger: event\n event_type: telegram_callback\n event_data:\n data: /ignoringchangelight\n actions:\n - action: telegram_bot.delete_message\n data:\n chat_id: '{{ trigger.event.data.chat_id }}'\n message_id: '{{ trigger.event.data.message.message_id }}'",
|
||
"config": []
|
||
},
|
||
{
|
||
"id": "no key sync yeelight ceiling to switch",
|
||
"automation": "- alias: no key sync yeelight ceiling to switch\n id: no key sync yeelight ceiling to switch\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: telegram_callback\n event_data:\n data: /nochangelight\n actions:\n - action: automation.turn_on\n target:\n entity_id: automation.sync_yeelight_ceiling_cr_to_switch\n - action: telegram_bot.answer_callback_query\n data:\n callback_query_id: '{{ trigger.event.data.id }}'\n message: Проверим состояние позже",
|
||
"config": [
|
||
{
|
||
"name": "sync yeelight ceiling cr to switch automation",
|
||
"room": "childrens_room",
|
||
"type": "automation",
|
||
"id": {
|
||
"entity_id": "automation.sync_yeelight_ceiling_cr_to_switch",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "ignor key sync yeelight ceiling to switch",
|
||
"automation": "- alias: ignor key sync yeelight ceiling to switch\n id: ignor key sync yeelight ceiling to switch\n mode: single\n max_exceeded: silent\n initial_state: true\n triggers:\n - trigger: event\n event_type: telegram_callback\n event_data:\n data: /ignoringchangelight\n actions:\n - action: telegram_bot.answer_callback_query\n data:\n callback_query_id: '{{ trigger.event.data.id }}'\n message: Отключили проверку",
|
||
"config": []
|
||
},
|
||
{
|
||
"id": "change keyboard sync yeelight ceiling to switch",
|
||
"automation": "- alias: change keyboard sync yeelight ceiling to switch\n id: change keyboard sync yeelight ceiling to switch\n mode: single\n max_exceeded: silent\n initial_state: true\n triggers:\n - trigger: event\n event_type: telegram_callback\n event_data:\n data: /changelight\n conditions:\n - condition: or\n conditions:\n - condition: and\n conditions:\n - condition: state\n entity_id: binary_sensor.0x158d0003f37a0f_contact\n state: 'on'\n - condition: state\n entity_id: light.yeelight_ceiling_cr\n state: 'off'\n - condition: and\n conditions:\n - condition: state\n entity_id: binary_sensor.0x158d0003f37a0f_contact\n state: 'off'\n - condition: state\n entity_id: light.yeelight_ceiling_cr\n state: 'on'\n actions:\n - parallel:\n - action: light.toggle\n target:\n entity_id: light.yeelight_ceiling_cr\n - action: automation.turn_on\n target:\n entity_id: automation.sync_yeelight_ceiling_cr_to_switch\n - action: telegram_bot.answer_callback_query\n data:\n callback_query_id: '{{ trigger.event.data.id }}'\n message: Изменили состояние",
|
||
"config": [
|
||
{
|
||
"name": "yeelight ceiling cr",
|
||
"room": "childrens_room",
|
||
"type": "light",
|
||
"id": {
|
||
"entity_id": "light.yeelight_ceiling_cr",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "childrens room contact sensor",
|
||
"room": "childrens_room",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d0003f37a0f_contact",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "sync yeelight ceiling cr to switch automation",
|
||
"room": "childrens_room",
|
||
"type": "automation",
|
||
"id": {
|
||
"entity_id": "automation.sync_yeelight_ceiling_cr_to_switch",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "vacuum chita answer key find vacuum",
|
||
"automation": "- alias: vacuum chita answer key find vacuum\n id: vacuum chita answer key find vacuum\n mode: single\n max_exceeded: silent\n initial_state: true\n triggers:\n - trigger: event\n event_type: telegram_callback\n event_data:\n data: /findvacuum\n actions:\n - action: vacuum.locate\n target:\n entity_id: vacuum.xiaomi_vacuum_cleaner\n - action: telegram_bot.delete_message\n data:\n chat_id: '{{ trigger.event.data.chat_id }}'\n message_id: '{{ trigger.event.data.message.message_id }}'\n - action: telegram_bot.answer_callback_query\n data:\n callback_query_id: '{{ trigger.event.data.id }}'\n message: Включили поиск Степы",
|
||
"config": [
|
||
{
|
||
"name": "vacuum xiaomi",
|
||
"room": null,
|
||
"type": "vacuum",
|
||
"id": {
|
||
"entity_id": "vacuum.xiaomi_vacuum_cleaner",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "keyboard vacuum start cleaning",
|
||
"automation": "- alias: keyboard vacuum start cleaning\n id: keyboard vacuum start cleaning\n mode: single\n max_exceeded: silent\n initial_state: true\n triggers:\n - trigger: event\n event_type: telegram_command\n event_data:\n command: /vacuum\n actions:\n - action: telegram_bot.delete_message\n data:\n chat_id: '{{ trigger.event.data.chat_id }}'\n message_id: '{{ trigger.event.data.id }}'\n - action: telegram_bot.send_message\n data:\n target: '{{ trigger.event.data.chat_id }}'\n message: '{{ ''\\U0000231b'' }} Отправить убирать:'\n inline_keyboard:\n - Сейчас:/vacuumnow, Через 10 мин.:/vacuum10, Через 20 мин.:/vacuum20\n - Отменить уборку:/vacuumcancel, Выслать карту:/sendmap",
|
||
"config": []
|
||
},
|
||
{
|
||
"id": "vacuum start cleaning",
|
||
"automation": "- alias: vacuum start cleaning\n id: vacuum start cleaning\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: telegram_callback\n event_data:\n data: /vacuumnow\n actions:\n - action: vacuum.start\n target:\n entity_id: vacuum.xiaomi_vacuum_cleaner\n - action: telegram_bot.delete_message\n data:\n chat_id: '{{ trigger.event.data.chat_id }}'\n message_id: '{{ trigger.event.data.message.message_id }}'\n - action: telegram_bot.answer_callback_query\n data:\n callback_query_id: '{{ trigger.event.data.id }}'\n message: Пылесос отправили на уборку",
|
||
"config": [
|
||
{
|
||
"name": "vacuum xiaomi",
|
||
"room": null,
|
||
"type": "vacuum",
|
||
"id": {
|
||
"entity_id": "vacuum.xiaomi_vacuum_cleaner",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "vacuum later start cleaning",
|
||
"automation": "- alias: vacuum later start cleaning\n id: vacuum later start cleaning\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: telegram_callback\n event_data:\n data: /vacuum10\n - trigger: event\n event_type: telegram_callback\n event_data:\n data: /vacuum20\n actions:\n - action: telegram_bot.delete_message\n data:\n chat_id: '{{ trigger.event.data.chat_id }}'\n message_id: '{{ trigger.event.data.message.message_id }}'\n - action: timer.start\n target:\n entity_id: timer.vacumm_ten_minutes\n data:\n duration: '{{ iif(trigger.event.data.data == ''/vacuum10'', 600, 1200, 1200)\n }}'\n - action: telegram_bot.answer_callback_query\n data:\n callback_query_id: '{{ trigger.event.data.id }}'\n message: '{{ ''Будет отправлен на уборку через '' + iif(trigger.event.data.data\n == ''/vacuum10'', ''10 мин.'', ''20 мин.'', ''20 мин.'') }}'\n - action: input_text.set_value\n target:\n entity_id: input_text.var_chat_id_vacuum_later_start\n data:\n value: '{{ trigger.event.data.chat_id }}'",
|
||
"config": [
|
||
{
|
||
"name": "vacuum ten minutes timer",
|
||
"room": null,
|
||
"type": "timer",
|
||
"id": {
|
||
"entity_id": "timer.vacumm_ten_minutes",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "var chat id vacuum later start",
|
||
"room": null,
|
||
"type": "input_text",
|
||
"id": {
|
||
"entity_id": "input_text.var_chat_id_vacuum_later_start",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "vacuum cancel cleaning",
|
||
"automation": "- alias: vacuum cancel cleaning\n id: vacuum cancel cleaning\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: telegram_callback\n event_data:\n data: /vacuumcancel\n actions:\n - action: telegram_bot.delete_message\n data:\n chat_id: '{{ trigger.event.data.chat_id }}'\n message_id: '{{ trigger.event.data.message.message_id }}'\n - action: timer.cancel\n target:\n entity_id: timer.vacumm_ten_minutes\n - action: vacuum.pause\n target:\n entity_id: vacuum.xiaomi_vacuum_cleaner\n - delay:\n seconds: 3\n - action: vacuum.return_to_base\n target:\n entity_id: vacuum.xiaomi_vacuum_cleaner\n - action: telegram_bot.answer_callback_query\n data:\n callback_query_id: '{{ trigger.event.data.id }}'\n message: Отменили таймеры, отправили на базу\n - action: input_text.set_value\n target:\n entity_id: input_text.var_chat_id_vacuum_later_start\n data:\n value: secret telegram_chita_chat_id",
|
||
"config": [
|
||
{
|
||
"name": "vacuum xiaomi",
|
||
"room": null,
|
||
"type": "vacuum",
|
||
"id": {
|
||
"entity_id": "vacuum.xiaomi_vacuum_cleaner",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "vacuum ten minutes timer",
|
||
"room": null,
|
||
"type": "timer",
|
||
"id": {
|
||
"entity_id": "timer.vacumm_ten_minutes",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "var chat id vacuum later start",
|
||
"room": null,
|
||
"type": "input_text",
|
||
"id": {
|
||
"entity_id": "input_text.var_chat_id_vacuum_later_start",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Chita Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_chita_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "vacuum send map",
|
||
"automation": "- alias: vacuum send map\n id: vacuum send map\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: telegram_callback\n event_data:\n data: /sendmap\n actions:\n - action: telegram_bot.delete_message\n data:\n chat_id: '{{ trigger.event.data.chat_id }}'\n message_id: '{{ trigger.event.data.message.message_id }}'\n - action: telegram_bot.send_photo\n data:\n target: '{{ trigger.event.data.chat_id }}'\n url: '{{- ''http://homeassistant.local.hass.io:8123'' + state_attr(''camera.roborock_vacuum_map'',\n ''entity_picture'') -}}'\n caption: '{{ ''\\U0001F5FA'' }} *Степа* {{- ''\\n'' -}} Текущая карта уборки'",
|
||
"config": [
|
||
{
|
||
"name": "roborock vacuum map camera",
|
||
"room": null,
|
||
"type": "camera",
|
||
"id": {
|
||
"entity_id": "camera.roborock_vacuum_map",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "send climate summary",
|
||
"automation": "- alias: send climate summary\n id: send climate summary\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: telegram_command\n event_data:\n command: /climate_summary\n actions:\n - action: telegram_bot.delete_message\n data:\n chat_id: '{{ trigger.event.data.chat_id }}'\n message_id: '{{ trigger.event.data.id }}'\n - action: telegram_bot.send_message\n data:\n target: '{{ trigger.event.data.chat_id }}'\n title: '{{ ''🌡'' }} *Климатические сенсоры*'\n message: \"{% set temp_array = expand('group.temperature_summary_group_to_bot')\\\n \\ | selectattr('state', 'defined') | selectattr('state', 'ne', None) %} {%-\\\n \\ for state in temp_array -%}\\n {%- if loop.first -%}_Данные температуры_:\\\n \\ {{-'\\\\n'-}}{%- endif -%} {{- state.name -}}: *{{ states(state.entity_id,\\\n \\ rounded=True) -}}*°C {%- if not loop.last -%}{{-'\\\\n'-}} {%- endif -%} \\n\\\n {%- endfor %}\"",
|
||
"config": [
|
||
{
|
||
"name": "temperature summary group to bot",
|
||
"room": null,
|
||
"type": "group",
|
||
"id": {
|
||
"entity_id": "group.temperature_summary_group_to_bot",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "install update telegram bot",
|
||
"automation": "- alias: install update telegram bot\n id: install update telegram bot\n initial_state: true\n mode: parallel\n triggers:\n - trigger: event\n event_type: telegram_callback\n event_data:\n command: /installupdate\n conditions:\n - '{{ trigger.event.data[''args''] | count > 0 }}'\n actions:\n - variables:\n entity: '{{- trigger.event.data[''args''][0] -}}'\n friendlyname: '{{- state_attr(trigger.event.data[''args''][0], ''friendly_name'')\n | replace('' Update'', '''') -}}'\n - choose:\n - conditions: '{{ is_state(entity, ''on'') and is_state_attr(entity, ''in_progress'',\n false) }}'\n sequence:\n - action: telegram_bot.answer_callback_query\n data:\n callback_query_id: '{{ trigger.event.data.id }}'\n message: Обновление на версию {{ state_attr(entity, 'latest_version') }}\n {{ friendlyname }} запущено.\n - action: update.install\n target:\n entity_id: '{{- entity -}}'\n data:\n backup: '{{ ''{:0=64b}''.format(state_attr(entity, ''supported_features''))[-4]\n == ''1'' }}'\n default:\n - action: telegram_bot.answer_callback_query\n data:\n callback_query_id: '{{ trigger.event.data.id }}'\n message: Обновление {{ friendlyname }} уже установлено.",
|
||
"config": []
|
||
},
|
||
{
|
||
"id": "change mute on off alice activation sounds",
|
||
"automation": "- alias: change mute on off alice activation sounds\n id: change mute on off alice activation sounds\n initial_state: true\n max_exceeded: silent\n triggers:\n - trigger: homeassistant\n event: start\n - trigger: time\n at:\n - '8:00:00'\n - '22:00:00'\n actions:\n - variables:\n time_to_on: '{% set time_now = now() %} {{ today_at(''8:00'') <= time_now <\n today_at(''21:59:59'') }}\n\n '\n - action: media_player.play_media\n target:\n entity_id: media_player.yandex_station_ff98f029b620413b35e5e278\n data:\n media_content_id: '{{- ''без лишних слов: '' + iif(time_to_on, ''нет'', ''да'')\n -}}'\n media_content_type: settings\n - delay: 2\n - action: media_player.play_media\n target:\n entity_id: media_player.yandex_station_ff98f029b620413b35e5e278\n data:\n media_content_id: '{{- ''звук активации: '' + iif(time_to_on, ''да'', ''нет'')\n -}}'\n media_content_type: settings",
|
||
"config": [
|
||
{
|
||
"name": "yandex station 1",
|
||
"room": null,
|
||
"type": "media_player",
|
||
"id": {
|
||
"entity_id": "media_player.yandex_station_ff98f029b620413b35e5e278",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "change name activation for voice assistant",
|
||
"automation": "- alias: change name activation for voice assistant\n id: change name activation for voice assistant\n initial_state: true\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: yandex_speaker\n event_data:\n instance: text_action\n value: Ничего не делай?-=\n - trigger: event\n event_type: yandex_speaker\n event_data:\n instance: text_action\n value: 'Ничего не делай?-:'\n actions:\n - action: media_player.play_media\n target:\n entity_id: media_player.yandex_station_ff98f029b620413b35e5e278\n data:\n media_content_id: 'имя: {{ ''алиса'' if ''?-:'' in trigger.event.data.value\n else ''яндекс'' }}'\n media_content_type: settings",
|
||
"config": [
|
||
{
|
||
"name": "yandex station 1",
|
||
"room": null,
|
||
"type": "media_player",
|
||
"id": {
|
||
"entity_id": "media_player.yandex_station_ff98f029b620413b35e5e278",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "clean one room by comand from voice assistant",
|
||
"automation": "- alias: clean one room by comand from voice assistant\n id: clean one room by comand from voice assistant\n initial_state: true\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: yandex_speaker\n event_data:\n instance: phrase_action\n value: уборка спальни\n - trigger: event\n event_type: yandex_speaker\n event_data:\n instance: phrase_action\n value: уборка детской\n - trigger: event\n event_type: yandex_speaker\n event_data:\n instance: phrase_action\n value: уборка гостиной\n - trigger: event\n event_type: yandex_speaker\n event_data:\n instance: phrase_action\n value: уборка ванной\n - trigger: event\n event_type: yandex_speaker\n event_data:\n instance: phrase_action\n value: уборка гардероба\n - trigger: event\n event_type: yandex_speaker\n event_data:\n instance: phrase_action\n value: уборка туалета\n - trigger: event\n event_type: yandex_speaker\n event_data:\n instance: phrase_action\n value: уборка коридора\n - trigger: event\n event_type: yandex_speaker\n event_data:\n instance: phrase_action\n value: уборка кухни\n actions:\n - action: vacuum.send_command\n target:\n entity_id: vacuum.xiaomi_vacuum_cleaner\n data:\n command: app_segment_clean\n params: \"{{ trigger.event.data.value | replace('уборка ', '') \\n | replace('детской',\\\n \\ '16') \\n | replace('спальни', '1') \\n | replace('гостиной', '17')\\\n \\ \\n | replace('кухни', '2') \\n | replace('ванной', '18') \\n | replace('гардероба',\\\n \\ '19') \\n | replace('туалета', '20') \\n | replace('коридора', '21')\\\n \\ \\n | int(0)\\n}}\\n\"",
|
||
"config": [
|
||
{
|
||
"name": "vacuum xiaomi",
|
||
"room": null,
|
||
"type": "vacuum",
|
||
"id": {
|
||
"entity_id": "vacuum.xiaomi_vacuum_cleaner",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "outdoor climate by comand from voice assistant",
|
||
"automation": "- alias: outdoor climate by comand from voice assistant\n id: outdoor climate by comand from voice assistant\n initial_state: true\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: yandex_speaker\n event_data:\n instance: text_action\n value: Ничего не делай-\n actions:\n - action: media_player.play_media\n target:\n entity_id: '{{ trigger.event.data.entity_id }}'\n data:\n media_content_type: text\n media_content_id: 'Температура {{ states(''sensor.0x00158d000542ceaf_temperature'')\n | round(0, ''ceil'', 0) | format(morph=''градус'', as_text=false) }} цельсия. Давление\n {{ states(''sensor.158d000542ceaf_pressure'') | round(0, ''ceil'', 0) | format(morph=''миллиметр'',\n as_text=false) }} ртутного столба Влажность {{ states(''sensor.0x00158d000542ceaf_humidity'')\n | round(0, ''ceil'', 0) | format(morph=''процент'', as_text=false) }}\n\n '",
|
||
"config": [
|
||
{
|
||
"name": "outdoor temperature sensor",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x00158d000542ceaf_temperature",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "outdoor pressure sensor",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.158d000542ceaf_pressure",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "outdoor humidity sensor",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x00158d000542ceaf_humidity",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "vacuum send map from alice command",
|
||
"automation": "- alias: vacuum send map from alice command\n id: vacuum send map from alice command\n initial_state: true\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: yandex_speaker\n event_data:\n instance: text_action\n value: Ничего не делай?-\n actions:\n - action: telegram_bot.send_photo\n data:\n target: secret telegram_all_chat_id\n url: '{{- ''http://homeassistant.local.hass.io:8123'' + state_attr(''camera.roborock_vacuum_map'',\n ''entity_picture'') -}}'\n caption: '{{ ''\\U0001F5FA'' }} *Степа* {{- ''\\n'' -}} Текущая карта уборки'",
|
||
"config": [
|
||
{
|
||
"name": "roborock vacuum map camera",
|
||
"room": null,
|
||
"type": "camera",
|
||
"id": {
|
||
"entity_id": "camera.roborock_vacuum_map",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram All Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_all_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "dishwasher remaining programme running time",
|
||
"automation": "- alias: dishwasher remaining programme running time\n id: dishwasher remaining programme running time\n initial_state: true\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: yandex_speaker\n event_data:\n instance: text_action\n value: Ничего не делай?\n actions:\n - action: media_player.play_media\n target:\n entity_id: '{{ trigger.event.data.entity_id }}'\n data:\n media_content_type: text\n media_content_id: \"{% if is_state('sensor.014020518886002182_bsh_common_status_operationstate',\\\n \\ 'BSH.Common.EnumType.OperationState.Run') %}\\n {% set time_delta = as_timestamp(states('sensor.014020518886002182_bsh_common_option_remainingprogramtime'),\\\n \\ 0) - as_timestamp(now(), 0) | int(0) %}\\n {% set minutes = (( time_delta\\\n \\ % 3600) / 60) | int(0) %}\\n {% set hours = ((time_delta % 86400) / 3600)\\\n \\ | int(0) %}\\n До окончания: {{- ' ' -}}\\n {% if time_delta < 1 -%}\\n\\\n \\ меньше минуты\\n {% else -%}\\n {% if hours > 0 %}\\n \\\n \\ {{- hours | format(morph='час') -}}\\n {% endif %}\\n {%- if\\\n \\ minutes > 0 -%}\\n {% if hours > 0 %}\\n {{- ' ' -}}\\n \\\n \\ {% endif %}\\n {{- minutes | format(morph='минута') }}\\n \\\n \\ {% endif %}\\n {% endif %}\\n{%- else %}\\n Сейчас программа не запущена\\n\\\n {% endif %}\\n\"",
|
||
"config": [
|
||
{
|
||
"name": "dishwasher operation state",
|
||
"room": "kitchen",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.014020518886002182_bsh_common_status_operationstate",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "dishwasher remaining program time",
|
||
"room": "kitchen",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.014020518886002182_bsh_common_option_remainingprogramtime",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "yeelight ceiling cr off",
|
||
"automation": "- alias: yeelight ceiling cr off\n id: yeelight ceiling cr off\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: binary_sensor.0x158d0003f37a0f_contact\n from: 'on'\n to: 'off'\n actions:\n - action: light.turn_off\n target:\n entity_id:\n - light.yeelight_ceiling_cr\n - light.yeelight_ceiling_cr_ambilight\n - light.yeelight_ceiling_cr_nightlight",
|
||
"config": [
|
||
{
|
||
"name": "yeelight ceiling cr",
|
||
"room": "childrens_room",
|
||
"type": "light",
|
||
"id": {
|
||
"entity_id": "light.yeelight_ceiling_cr",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "yeelight ceiling cr ambilight",
|
||
"room": "childrens_room",
|
||
"type": "light",
|
||
"id": {
|
||
"entity_id": "light.yeelight_ceiling_cr_ambilight",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "yeelight ceiling cr nightlight",
|
||
"room": "childrens_room",
|
||
"type": "light",
|
||
"id": {
|
||
"entity_id": "light.yeelight_ceiling_cr_nightlight",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "childrens room contact sensor",
|
||
"room": "childrens_room",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d0003f37a0f_contact",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "yeelight ceiling cr on",
|
||
"automation": "- alias: yeelight ceiling cr on\n id: yeelight ceiling cr on\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: binary_sensor.0x158d0003f37a0f_contact\n from: 'off'\n to: 'on'\n actions:\n - action: light.turn_on\n target:\n entity_id: light.yeelight_ceiling_cr\n data:\n color_temp_kelvin: 3571\n brightness: 255",
|
||
"config": [
|
||
{
|
||
"name": "yeelight ceiling cr",
|
||
"room": "childrens_room",
|
||
"type": "light",
|
||
"id": {
|
||
"entity_id": "light.yeelight_ceiling_cr",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "childrens room contact sensor",
|
||
"room": "childrens_room",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d0003f37a0f_contact",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "yeelight ceiling cr on ambilight night mode",
|
||
"automation": "- alias: yeelight ceiling cr on ambilight night mode\n id: yeelight ceiling cr on ambilight night mode\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: sensor.0x158d0003a360b6_action\n to: single\n conditions:\n - condition: state\n entity_id: light.yeelight_ceiling_cr\n state: 'off'\n actions:\n - action: light.turn_on\n target:\n entity_id: light.yeelight_ceiling_cr_ambilight\n data:\n brightness: 1\n rgb_color:\n - 0\n - 0\n - 255",
|
||
"config": [
|
||
{
|
||
"name": "wireless switch action",
|
||
"room": "childrens_room",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x158d0003a360b6_action",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "yeelight ceiling cr",
|
||
"room": "childrens_room",
|
||
"type": "light",
|
||
"id": {
|
||
"entity_id": "light.yeelight_ceiling_cr",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "yeelight ceiling cr ambilight",
|
||
"room": "childrens_room",
|
||
"type": "light",
|
||
"id": {
|
||
"entity_id": "light.yeelight_ceiling_cr_ambilight",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "yeelight ceiling cr off ambilight night mode",
|
||
"automation": "- alias: yeelight ceiling cr off ambilight night mode\n id: yeelight ceiling cr off ambilight night mode\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: sensor.0x158d0003a360b6_action\n to: single\n conditions:\n - condition: state\n entity_id: light.yeelight_ceiling_cr_ambilight\n state: 'on'\n - condition: state\n entity_id: light.yeelight_ceiling_cr\n state: 'off'\n actions:\n - action: light.turn_off\n target:\n entity_id: light.yeelight_ceiling_cr_ambilight",
|
||
"config": [
|
||
{
|
||
"name": "wireless switch action",
|
||
"room": "childrens_room",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x158d0003a360b6_action",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "yeelight ceiling cr",
|
||
"room": "childrens_room",
|
||
"type": "light",
|
||
"id": {
|
||
"entity_id": "light.yeelight_ceiling_cr",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "yeelight ceiling cr ambilight",
|
||
"room": "childrens_room",
|
||
"type": "light",
|
||
"id": {
|
||
"entity_id": "light.yeelight_ceiling_cr_ambilight",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "sync yeelight ceiling cr to switch",
|
||
"automation": "- alias: sync yeelight ceiling cr to switch\n id: sync yeelight ceiling cr to switch\n initial_state: true\n triggers:\n - trigger: time_pattern\n minutes: /3\n conditions:\n - '{{ (state_attr(''automation.yeelight_ceiling_on'', ''current'') | int(0)) ==\n 0 }}'\n - '{{ (state_attr(''automation.yeelight_ceiling_off'', ''current'') | int(0)) ==\n 0 }}'\n - condition: or\n conditions:\n - condition: and\n conditions:\n - condition: state\n entity_id: binary_sensor.0x158d0003f37a0f_contact\n state: 'on'\n - condition: state\n entity_id: light.yeelight_ceiling_cr\n state: 'off'\n - condition: state\n entity_id: light.yeelight_ceiling_cr_ambilight\n state: 'off'\n - condition: state\n entity_id: light.yeelight_ceiling_cr_nightlight\n state: 'off'\n - condition: and\n conditions:\n - condition: state\n entity_id: binary_sensor.0x158d0003f37a0f_contact\n state: 'off'\n - condition: state\n entity_id: light.yeelight_ceiling_cr\n state: 'on'\n actions:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n message: ⚠️ Обнаружено отклонение светильника и выключателя, исправить?\n inline_keyboard:\n - Да:/changelight, Нет:/nochangelight, Игнорировать:/ignoringchangelight\n - action: automation.turn_off\n target:\n entity_id: '{{ this.entity_id }}'",
|
||
"config": [
|
||
{
|
||
"name": "yeelight ceiling cr",
|
||
"room": "childrens_room",
|
||
"type": "light",
|
||
"id": {
|
||
"entity_id": "light.yeelight_ceiling_cr",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "yeelight ceiling cr ambilight",
|
||
"room": "childrens_room",
|
||
"type": "light",
|
||
"id": {
|
||
"entity_id": "light.yeelight_ceiling_cr_ambilight",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "yeelight ceiling cr nightlight",
|
||
"room": "childrens_room",
|
||
"type": "light",
|
||
"id": {
|
||
"entity_id": "light.yeelight_ceiling_cr_nightlight",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "childrens room contact sensor",
|
||
"room": "childrens_room",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d0003f37a0f_contact",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "yeelight ceiling on automation",
|
||
"room": "childrens_room",
|
||
"type": "automation",
|
||
"id": {
|
||
"entity_id": "automation.yeelight_ceiling_on",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "yeelight ceiling off automation",
|
||
"room": "childrens_room",
|
||
"type": "automation",
|
||
"id": {
|
||
"entity_id": "automation.yeelight_ceiling_off",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "light gateway toggle",
|
||
"automation": "- alias: light gateway toggle\n id: light gateway toggle\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: binary_sensor.0x158d000359304c_contact\n from: 'off'\n to: 'on'\n conditions:\n - condition: state\n entity_id: automation.turn_on_doorbell\n attribute: current\n state: 0\n - condition: state\n entity_id: input_boolean.alarm_gateway_button\n state: 'off'\n actions:\n - action: scene.create\n data:\n scene_id: before_light_door_open\n snapshot_entities:\n - light.gateway_light_04cf8cabd77b\n - action: light.turn_on\n target:\n entity_id: light.gateway_light_04cf8cabd77b\n data:\n rgb_color:\n - 255\n - 0\n - 0\n brightness: 255\n - delay:\n milliseconds: 150\n - action: light.turn_off\n target:\n entity_id: light.gateway_light_04cf8cabd77b\n - delay:\n milliseconds: 50\n - action: light.turn_on\n target:\n entity_id: light.gateway_light_04cf8cabd77b\n data:\n rgb_color:\n - 255\n - 0\n - 0\n brightness: 255\n - delay:\n milliseconds: 150\n - action: light.turn_off\n target:\n entity_id: light.gateway_light_04cf8cabd77b\n - action: scene.turn_on\n target:\n entity_id: scene.before_light_door_open",
|
||
"config": [
|
||
{
|
||
"name": "gateway light",
|
||
"room": "hallway",
|
||
"type": "light",
|
||
"id": {
|
||
"entity_id": "light.gateway_light_04cf8cabd77b",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "alarm gateway button",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.alarm_gateway_button",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "contact sensor",
|
||
"room": "hallway",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d000359304c_contact",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "scene before light door open",
|
||
"room": null,
|
||
"type": "scene",
|
||
"id": {
|
||
"entity_id": "scene.before_light_door_open",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "turn on doorbell automation",
|
||
"room": null,
|
||
"type": "automation",
|
||
"id": {
|
||
"entity_id": "automation.turn_on_doorbell",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "light gateway go to work on",
|
||
"automation": "- alias: light gateway go to work on\n id: light gateway go to work on\n triggers:\n - trigger: time\n at: 07:00:00\n conditions:\n - condition: state\n entity_id: input_boolean.alarm_gateway_button\n state: 'off'\n - condition: time\n weekday:\n - mon\n - tue\n - wed\n - thu\n - fri\n actions:\n - action: scene.create\n data:\n scene_id: before_on_go_to_work\n snapshot_entities:\n - light.gateway_light_04cf8cabd77b\n - action: light.turn_on\n target:\n entity_id: light.gateway_light_04cf8cabd77b\n data:\n rgb_color:\n - 230\n - 255\n - 0\n brightness: 5",
|
||
"config": [
|
||
{
|
||
"name": "gateway light",
|
||
"room": "hallway",
|
||
"type": "light",
|
||
"id": {
|
||
"entity_id": "light.gateway_light_04cf8cabd77b",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "alarm gateway button",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.alarm_gateway_button",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "light gateway go to work off",
|
||
"automation": "- alias: light gateway go to work off\n id: light gateway go to work off\n triggers:\n - trigger: time\n at: 07:20:00\n conditions:\n - condition: state\n entity_id: input_boolean.alarm_gateway_button\n state: 'off'\n - condition: time\n weekday:\n - mon\n - tue\n - wed\n - thu\n - fri\n actions:\n - action: light.turn_off\n target:\n entity_id: light.gateway_light_04cf8cabd77b\n - action: scene.turn_on\n target:\n entity_id: scene.before_on_go_to_work",
|
||
"config": [
|
||
{
|
||
"name": "gateway light",
|
||
"room": "hallway",
|
||
"type": "light",
|
||
"id": {
|
||
"entity_id": "light.gateway_light_04cf8cabd77b",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "alarm gateway button",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.alarm_gateway_button",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "scene before on go to work",
|
||
"room": null,
|
||
"type": "scene",
|
||
"id": {
|
||
"entity_id": "scene.before_on_go_to_work",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "restart integration relay yeelight ceiling unavailable",
|
||
"automation": "- alias: restart integration relay yeelight ceiling unavailable\n id: restart integration relay yeelight ceiling unavailable\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: light.yeelight_ceiling_cr\n to: null\n - trigger: homeassistant\n event: start\n conditions:\n - condition: state\n entity_id: input_boolean.instances_stoping\n state: 'off'\n - '{{ as_timestamp(now()) - as_timestamp(state_attr(this.entity_id, ''last_triggered''))\n > 60 }}'\n - '{{ not has_value(''light.yeelight_ceiling_cr'') }}'\n - '{{ has_value(''switch.0x54ef441000096cbc'') }}'\n actions:\n - wait_template: '{{ has_value(''light.yeelight_ceiling_cr'') or is_state(''input_boolean.instances_stoping'',\n ''on'') }}'\n timeout: 00:02:00\n - choose:\n - conditions: '{{ not wait.completed and is_state(''binary_sensor.local_network_availability'',\n ''on'') }}'\n sequence:\n - action: switch.turn_off\n target:\n entity_id: switch.0x54ef441000096cbc\n - delay:\n seconds: 5\n - action: switch.turn_on\n target:\n entity_id: switch.0x54ef441000096cbc\n - delay:\n seconds: 30\n - action: homeassistant.reload_config_entry\n data:\n entry_id: '{{ config_entry_id(''light.yeelight_ceiling_cr'') }}'",
|
||
"config": [
|
||
{
|
||
"name": "yeelight ceiling cr",
|
||
"room": "childrens_room",
|
||
"type": "light",
|
||
"id": {
|
||
"entity_id": "light.yeelight_ceiling_cr",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "yeelight ceiling relay",
|
||
"room": "childrens_room",
|
||
"type": "switch",
|
||
"id": {
|
||
"entity_id": "switch.0x54ef441000096cbc",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "local network availability",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.local_network_availability",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "instances stoping",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.instances_stoping",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "turn on lg webos tv bedroom",
|
||
"automation": "- alias: turn on lg webos tv bedroom\n id: turn on lg webos tv bedroom\n initial_state: true\n triggers:\n - trigger: webostv.turn_on\n entity_id: media_player.lg_smart_tv\n conditions:\n - '{{ states(''media_player.lg_smart_tv'') in [''off'', ''unknown'', ''unavailable'']\n }}'\n actions:\n - action: remote.send_command\n target:\n entity_id: remote.broadlink_ir_rm4_mini\n data:\n command: b64:JgBYAAABI5URFBEUEjgRFBEUERQRFREUETgSOBEUETkROBE5ETgSOBEUERQRFBI4ERQRFBEUEhQROBI4ETgRFRA5ETkROBI4EQAFJwABJkwRAAxeAAElSxIADQU=",
|
||
"config": [
|
||
{
|
||
"name": "lg smart tv",
|
||
"room": "bedroom",
|
||
"type": "media_player",
|
||
"id": {
|
||
"entity_id": "media_player.lg_smart_tv",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "broadlink ir rm4 mini",
|
||
"room": "bedroom",
|
||
"type": "remote",
|
||
"id": {
|
||
"entity_id": "remote.broadlink_ir_rm4_mini",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "turn on samsung tv kitchen",
|
||
"automation": "- alias: turn on samsung tv kitchen\n id: turn on samsung tv kitchen\n initial_state: true\n triggers:\n - trigger: samsungtv.turn_on\n entity_id: media_player.tv_kotletochka_tv_sam\n conditions:\n - '{{ states(''media_player.tv_kotletochka_tv_sam'') in [''off'', ''unknown'', ''unavailable'']\n }}'\n actions:\n - action: esphome.perenio_petra01_kitchen_send_samsung_command\n data:\n data: '0xE0E040BF'",
|
||
"config": [
|
||
{
|
||
"name": "tv samsung",
|
||
"room": "kitchen",
|
||
"type": "media_player",
|
||
"id": {
|
||
"entity_id": "media_player.tv_kotletochka_tv_sam",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "mqtt_sensors_discovery",
|
||
"automation": "- alias: mqtt_sensors_discovery\n id: mqtt_sensors_discovery\n initial_state: true\n triggers:\n - trigger: homeassistant\n event: start\n - trigger: event\n event_type: automation_reloaded\n actions:\n - parallel:\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/mqtt_broker_uptime/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"MQTT Broker Uptime\\\", \\n \\\"state_topic\\\":\\\"$SYS/broker/uptime\\\"\\\n , \\n \\\"icon\\\":\\\"mdi:timer-outline\\\", \\n \\\"unit_of_measurement\\\":\\\"s\\\"\\\n , \\n \\\"entity_category\\\":\\\"diagnostic\\\", \\n \\\"unique_id\\\":\\\"mqtt_broker_uptime\\\"\\\n ,\\n \\\"value_template\\\":\\\"{{ '{{' }} value | regex_replace('[^\\\\\\\\d]','')\\\n \\ | trim {{ '}}' }}\\\", \\n \\\"json_attributes_topic\\\":\\\"$SYS/broker/version\\\"\\\n , \\n \\\"json_attributes_template\\\":\\\"{\\\\\\\"version\\\\\\\":\\\\\\\"{{ '{{' }} (value\\\n \\ | regex_replace('[\\\\\\\\s\\\\\\\\S]+?\\\\\\\\s(\\\\\\\\d)','\\\\\\\\\\\\\\\\1')) | trim {{ '}}'\\\n \\ }}\\\\\\\"}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"mosquito_broker\\\"],\\\"manufacturer\\\"\\\n :\\\"Eclipse\\\",\\\"model\\\":\\\"Mosquitto\\\",\\\"name\\\":\\\"Eclipse Mosquitto\\\",\\\"sw_version\\\"\\\n :\\\"{{ state_attr('sensor.mqtt_broker_uptime','version') }}\\\",\\\"configuration_url\\\"\\\n :\\\"https://mosquitto.org/\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/permit_join_switch_z2m/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"permit_join_switch_z2m\\\", \\n \\\"state_topic\\\":\\\"\\\n zigbee2mqtt/bridge/info\\\",\\n \\\"command_topic\\\":\\\"zigbee2mqtt/bridge/request/permit_join\\\"\\\n ,\\n \\\"payload_on\\\":\\\"{\\\\\\\"time\\\\\\\":254}\\\",\\n \\\"payload_off\\\":\\\"{\\\\\\\"time\\\\\\\n \\\":0}\\\",\\n \\\"state_off\\\":\\\"false\\\",\\n \\\"state_on\\\":\\\"true\\\",\\n \\\"icon\\\"\\\n :\\\"mdi:cellphone-wireless\\\",\\n \\\"unique_id\\\":\\\"permit_join_switch_z2m\\\"\\\n ,\\n \\\"value_template\\\":\\\"{{ '{{' }} value_json.permit_join | lower {{ '}}'\\\n \\ }}\\\",\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"z2m_info\\\"],\\\"manufacturer\\\":\\\"\\\n Enzokot\\\",\\\"model\\\":\\\"Local polling\\\",\\\"name\\\":\\\"Zigbee2MQTT add-on\\\"}\\n\\\n }\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/permit_join_end_z2m/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"permit join end z2m\\\", \\n \\\"state_topic\\\":\\\"zigbee2mqtt/bridge/info\\\"\\\n ,\\n \\\"value_template\\\":\\\"{{ '{{' }} iif(value_json.permit_join, value_json.permit_join_end,\\\n \\ 0) {{ '}}' }}\\\",\\n \\\"unique_id\\\":\\\"permit_join_end_z2m\\\",\\n \\\"device\\\"\\\n :{\\\"identifiers\\\":[\\\"z2m_info\\\"],\\\"manufacturer\\\":\\\"Enzokot\\\",\\\"model\\\"\\\n :\\\"Local polling\\\",\\\"name\\\":\\\"Zigbee2MQTT add-on\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/router_devices_z2m/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"router devices z2m\\\", \\n \\\"state_topic\\\":\\\"zigbee2mqtt/bridge/devices\\\"\\\n ,\\n \\\"value_template\\\":\\\"{{ '{{' }} value_json | to_json | from_json |\\\n \\ selectattr('type', 'defined') | selectattr('type', 'in', ['Coordinator',\\\n \\ 'Router']) | map(attribute='friendly_name') | list | count {{ '}}' }}\\\"\\\n ,\\n \\\"json_attributes_topic\\\":\\\"zigbee2mqtt/bridge/devices\\\",\\n \\\"json_attributes_template\\\"\\\n :\\\"{{ '{{ {' }}'routers':value_json | to_json | from_json | selectattr('type',\\\n \\ 'defined') | selectattr('type', 'in', ['Coordinator', 'Router']) | map(attribute='friendly_name')\\\n \\ | list{{ '}' }} | tojson {{ '}}' }}\\\",\\n \\\"icon\\\":\\\"mdi:router-wireless\\\"\\\n ,\\n \\\"unique_id\\\":\\\"router_devices_z2m\\\",\\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"z2m_info\\\"],\\\"manufacturer\\\":\\\"Enzokot\\\",\\\"model\\\":\\\"Local polling\\\"\\\n ,\\\"name\\\":\\\"Zigbee2MQTT add-on\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/permit_join_current_device_z2m/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"permit join current device z2m\\\", \\n \\\"state_topic\\\"\\\n :\\\"zigbee2mqtt/bridge/response/permit_join\\\",\\n \\\"value_template\\\":\\\"{{\\\n \\ '{{' }} value_json.data.device if value_json.data is defined and value_json.data.device\\\n \\ is defined else None {{ '}}' }}\\\",\\n \\\"icon\\\":\\\"mdi:router\\\",\\n \\\"unique_id\\\"\\\n :\\\"permit_join_current_device_z2m\\\",\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"\\\n z2m_info\\\"],\\\"manufacturer\\\":\\\"Enzokot\\\",\\\"model\\\":\\\"Local polling\\\",\\\"\\\n name\\\":\\\"Zigbee2MQTT add-on\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/check_keenetic_link_down/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"check keenetic link down\\\", \\n \\\"state_topic\\\"\\\n :\\\"host_data/network_diagnostics/check_keenetic_link_down\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} as_datetime(value_json.status, 0) | as_local() if value_json.status\\\n \\ is defined and as_datetime(value_json.status, 0) != 0 else None {{ '}}'\\\n \\ }}\\\",\\n \\\"icon\\\":\\\"mdi:calendar-clock\\\", \\n \\\"device_class\\\":\\\"timestamp\\\"\\\n ,\\n \\\"unique_id\\\":\\\"check_keenetic_link_down\\\",\\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"network_info\\\"],\\\"manufacturer\\\":\\\"Enzokot\\\",\\\"model\\\":\\\"Local polling\\\"\\\n ,\\\"name\\\":\\\"Network info\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/sostoianie_mosta/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Состояние моста\\\", \\n \\\"state_topic\\\":\\\"zigbee2mqtt/bridge/state\\\"\\\n ,\\n \\\"value_template\\\":\\\"{{ '{{' }} value_json.state {{ '}}' }}\\\",\\n \\\"\\\n icon\\\":\\\"mdi:calendar-clock\\\", \\n \\\"unique_id\\\":\\\"sostoianie_mosta\\\",\\n\\\n \\ \\\"device\\\":{\\\"identifiers\\\":[\\\"z2m_info\\\"],\\\"manufacturer\\\":\\\"Enzokot\\\"\\\n ,\\\"model\\\":\\\"Local polling\\\",\\\"name\\\":\\\"Zigbee2MQTT add-on\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/zigbee2mqtt_coordinator_version/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Zigbee2mqtt Coordinator Version\\\", \\n \\\"state_topic\\\"\\\n :\\\"zigbee2mqtt/bridge/info\\\",\\n \\\"value_template\\\":\\\"{{ '{{' }} value_json.coordinator['ieee_address']\\\n \\ {{ '}}' }}\\\",\\n \\\"json_attributes_topic\\\":\\\"zigbee2mqtt/bridge/info\\\"\\\n ,\\n \\\"json_attributes_template\\\":\\\"{{ '{{ {' }}'revision':value_json.coordinator['meta'].revision,\\\n \\ 'type':value_json.coordinator['type']{{ '}' }} | tojson {{ '}}' }}\\\",\\n\\\n \\ \\\"icon\\\":\\\"mdi:chip\\\",\\n \\\"unique_id\\\":\\\"zigbee2mqtt_coordinator_version\\\"\\\n ,\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"z2m_info\\\"],\\\"manufacturer\\\":\\\"Enzokot\\\"\\\n ,\\\"model\\\":\\\"Local polling\\\",\\\"name\\\":\\\"Zigbee2MQTT add-on\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/0x5c0272fffec89454/local_temperature/config\n retain: true\n payload: \"{ \\n \\\"avty\\\":[{\\\"topic\\\":\\\"zigbee2mqtt/bridge/state\\\",\\\"value_template\\\"\\\n :\\\"{{ '{{' }} value_json.state {{ '}}' }}\\\"},{\\\"topic\\\":\\\"zigbee2mqtt/Childrens\\\n \\ room valve with thermostat/availability\\\",\\\"value_template\\\":\\\"{{ '{{'\\\n \\ }} value_json.state {{ '}}' }}\\\"}],\\n \\\"avty_mode\\\":\\\"all\\\",\\n \\\"name\\\"\\\n :\\\"0x5c0272fffec89454_local_temperature\\\",\\n \\\"state_topic\\\":\\\"zigbee2mqtt/Childrens\\\n \\ room valve with thermostat\\\",\\n \\\"value_template\\\":\\\"{{ '{{' }} value_json.local_temperature\\\n \\ {{ '}}' }}\\\",\\n \\\"unit_of_measurement\\\":\\\"°C\\\",\\n \\\"unique_id\\\":\\\"0x5c0272fffec89454_local_temperature\\\"\\\n ,\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"zigbee2mqtt_0x5c0272fffec89454\\\"],\\\"\\\n manufacturer\\\":\\\"TuYa\\\",\\\"model\\\":\\\"Radiator valve with thermostat (TS0601_thermostat)\\\"\\\n ,\\\"name\\\":\\\"Childrens room valve with thermostat\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/0x5c0272fffec89454/local_temperature_calibration/config\n retain: true\n payload: \"{ \\n \\\"avty\\\":[{\\\"topic\\\":\\\"zigbee2mqtt/bridge/state\\\",\\\"value_template\\\"\\\n :\\\"{{ '{{' }} value_json.state {{ '}}' }}\\\"},{\\\"topic\\\":\\\"zigbee2mqtt/Childrens\\\n \\ room valve with thermostat/availability\\\",\\\"value_template\\\":\\\"{{ '{{'\\\n \\ }} value_json.state {{ '}}' }}\\\"}],\\n \\\"avty_mode\\\":\\\"all\\\",\\n \\\"name\\\"\\\n :\\\"0x5c0272fffec89454_local_temperature_calibration\\\",\\n \\\"state_topic\\\"\\\n :\\\"zigbee2mqtt/Childrens room valve with thermostat\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value_json.local_temperature_calibration {{ '}}' }}\\\",\\n \\\n \\ \\\"unit_of_measurement\\\":\\\"°C\\\",\\n \\\"unique_id\\\":\\\"0x5c0272fffec89454_local_temperature_calibration\\\"\\\n ,\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"zigbee2mqtt_0x5c0272fffec89454\\\"],\\\"\\\n manufacturer\\\":\\\"TuYa\\\",\\\"model\\\":\\\"Radiator valve with thermostat (TS0601_thermostat)\\\"\\\n ,\\\"name\\\":\\\"Childrens room valve with thermostat\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/0x60a423fffe968719/local_temperature/config\n retain: true\n payload: \"{ \\n \\\"avty\\\":[{\\\"topic\\\":\\\"zigbee2mqtt/bridge/state\\\",\\\"value_template\\\"\\\n :\\\"{{ '{{' }} value_json.state {{ '}}' }}\\\"},{\\\"topic\\\":\\\"zigbee2mqtt/Bedroom\\\n \\ valve with thermostat/availability\\\",\\\"value_template\\\":\\\"{{ '{{' }} value_json.state\\\n \\ {{ '}}' }}\\\"}],\\n \\\"avty_mode\\\":\\\"all\\\",\\n \\\"name\\\":\\\"0x60a423fffe968719_local_temperature\\\"\\\n ,\\n \\\"state_topic\\\":\\\"zigbee2mqtt/Bedroom valve with thermostat\\\",\\n \\\"\\\n value_template\\\":\\\"{{ '{{' }} value_json.local_temperature {{ '}}' }}\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"°C\\\",\\n \\\"unique_id\\\":\\\"0x60a423fffe968719_local_temperature\\\"\\\n ,\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"zigbee2mqtt_0x60a423fffe968719\\\"],\\\"\\\n manufacturer\\\":\\\"TuYa\\\",\\\"model\\\":\\\"Radiator valve with thermostat (TS0601_thermostat)\\\"\\\n ,\\\"name\\\":\\\"Bedroom valve with thermostat\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/0x60a423fffe968719/local_temperature_calibration/config\n retain: true\n payload: \"{ \\n \\\"avty\\\":[{\\\"topic\\\":\\\"zigbee2mqtt/bridge/state\\\",\\\"value_template\\\"\\\n :\\\"{{ '{{' }} value_json.state {{ '}}' }}\\\"},{\\\"topic\\\":\\\"zigbee2mqtt/Bedroom\\\n \\ valve with thermostat/availability\\\",\\\"value_template\\\":\\\"{{ '{{' }} value_json.state\\\n \\ {{ '}}' }}\\\"}],\\n \\\"avty_mode\\\":\\\"all\\\",\\n \\\"name\\\":\\\"0x60a423fffe968719_local_temperature_calibration\\\"\\\n ,\\n \\\"state_topic\\\":\\\"zigbee2mqtt/Bedroom valve with thermostat\\\",\\n \\\"\\\n value_template\\\":\\\"{{ '{{' }} value_json.local_temperature_calibration {{\\\n \\ '}}' }}\\\",\\n \\\"unit_of_measurement\\\":\\\"°C\\\",\\n \\\"unique_id\\\":\\\"0x60a423fffe968719_local_temperature_calibration\\\"\\\n ,\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"zigbee2mqtt_0x60a423fffe968719\\\"],\\\"\\\n manufacturer\\\":\\\"TuYa\\\",\\\"model\\\":\\\"Radiator valve with thermostat (TS0601_thermostat)\\\"\\\n ,\\\"name\\\":\\\"Bedroom valve with thermostat\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/0x5c0272fffec9db22/local_temperature/config\n retain: true\n payload: \"{ \\n \\\"avty\\\":[{\\\"topic\\\":\\\"zigbee2mqtt/bridge/state\\\",\\\"value_template\\\"\\\n :\\\"{{ '{{' }} value_json.state {{ '}}' }}\\\"},{\\\"topic\\\":\\\"zigbee2mqtt/Living\\\n \\ room valve with thermostat/availability\\\",\\\"value_template\\\":\\\"{{ '{{'\\\n \\ }} value_json.state {{ '}}' }}\\\"}],\\n \\\"avty_mode\\\":\\\"all\\\",\\n \\\"name\\\"\\\n :\\\"0x5c0272fffec9db22_local_temperature\\\",\\n \\\"state_topic\\\":\\\"zigbee2mqtt/Living\\\n \\ room valve with thermostat\\\",\\n \\\"value_template\\\":\\\"{{ '{{' }} value_json.local_temperature\\\n \\ {{ '}}' }}\\\",\\n \\\"unit_of_measurement\\\":\\\"°C\\\",\\n \\\"unique_id\\\":\\\"0x5c0272fffec9db22_local_temperature\\\"\\\n ,\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"zigbee2mqtt_0x5c0272fffec9db22\\\"],\\\"\\\n manufacturer\\\":\\\"TuYa\\\",\\\"model\\\":\\\"Radiator valve with thermostat (TS0601_thermostat)\\\"\\\n ,\\\"name\\\":\\\"Living room valve with thermostat\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/0x5c0272fffec9db22/local_temperature_calibration/config\n retain: true\n payload: \"{ \\n \\\"avty\\\":[{\\\"topic\\\":\\\"zigbee2mqtt/bridge/state\\\",\\\"value_template\\\"\\\n :\\\"{{ '{{' }} value_json.state {{ '}}' }}\\\"},{\\\"topic\\\":\\\"zigbee2mqtt/Living\\\n \\ room valve with thermostat/availability\\\",\\\"value_template\\\":\\\"{{ '{{'\\\n \\ }} value_json.state {{ '}}' }}\\\"}],\\n \\\"avty_mode\\\":\\\"all\\\",\\n \\\"name\\\"\\\n :\\\"0x5c0272fffec9db22_local_temperature_calibration\\\",\\n \\\"state_topic\\\"\\\n :\\\"zigbee2mqtt/Living room valve with thermostat\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value_json.local_temperature_calibration {{ '}}' }}\\\",\\n \\\n \\ \\\"unit_of_measurement\\\":\\\"°C\\\",\\n \\\"unique_id\\\":\\\"0x5c0272fffec9db22_local_temperature_calibration\\\"\\\n ,\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"zigbee2mqtt_0x5c0272fffec9db22\\\"],\\\"\\\n manufacturer\\\":\\\"TuYa\\\",\\\"model\\\":\\\"Radiator valve with thermostat (TS0601_thermostat)\\\"\\\n ,\\\"name\\\":\\\"Living room valve with thermostat\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/0x5c0272fffe8de819/local_temperature/config\n retain: true\n payload: \"{ \\n \\\"avty\\\":[{\\\"topic\\\":\\\"zigbee2mqtt/bridge/state\\\",\\\"value_template\\\"\\\n :\\\"{{ '{{' }} value_json.state {{ '}}' }}\\\"},{\\\"topic\\\":\\\"zigbee2mqtt/Kitchen\\\n \\ valve with thermostat/availability\\\",\\\"value_template\\\":\\\"{{ '{{' }} value_json.state\\\n \\ {{ '}}' }}\\\"}],\\n \\\"avty_mode\\\":\\\"all\\\",\\n \\\"name\\\":\\\"0x5c0272fffe8de819_local_temperature\\\"\\\n ,\\n \\\"state_topic\\\":\\\"zigbee2mqtt/Kitchen valve with thermostat\\\",\\n \\\"\\\n value_template\\\":\\\"{{ '{{' }} value_json.local_temperature {{ '}}' }}\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"°C\\\",\\n \\\"unique_id\\\":\\\"0x5c0272fffe8de819_local_temperature\\\"\\\n ,\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"zigbee2mqtt_0x5c0272fffe8de819\\\"],\\\"\\\n manufacturer\\\":\\\"TuYa\\\",\\\"model\\\":\\\"Radiator valve with thermostat (TS0601_thermostat)\\\"\\\n ,\\\"name\\\":\\\"Kitchen valve with thermostat\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/0x5c0272fffe8de819/local_temperature_calibration/config\n retain: true\n payload: \"{ \\n \\\"avty\\\":[{\\\"topic\\\":\\\"zigbee2mqtt/bridge/state\\\",\\\"value_template\\\"\\\n :\\\"{{ '{{' }} value_json.state {{ '}}' }}\\\"},{\\\"topic\\\":\\\"zigbee2mqtt/Kitchen\\\n \\ valve with thermostat/availability\\\",\\\"value_template\\\":\\\"{{ '{{' }} value_json.state\\\n \\ {{ '}}' }}\\\"}],\\n \\\"avty_mode\\\":\\\"all\\\",\\n \\\"name\\\":\\\"0x5c0272fffe8de819_local_temperature_calibration\\\"\\\n , \\n \\\"state_topic\\\":\\\"zigbee2mqtt/Kitchen valve with thermostat\\\",\\n \\\n \\ \\\"value_template\\\":\\\"{{ '{{' }} value_json.local_temperature_calibration\\\n \\ {{ '}}' }}\\\",\\n \\\"unit_of_measurement\\\":\\\"°C\\\",\\n \\\"unique_id\\\":\\\"0x5c0272fffe8de819_local_temperature_calibration\\\"\\\n ,\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"zigbee2mqtt_0x5c0272fffe8de819\\\"],\\\"\\\n manufacturer\\\":\\\"TuYa\\\",\\\"model\\\":\\\"Radiator valve with thermostat (TS0601_thermostat)\\\"\\\n ,\\\"name\\\":\\\"Kitchen valve with thermostat\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/login_ssh_kotletochka_dell_srv/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"login ssh kotletochka dell srv\\\", \\n \\\"state_topic\\\"\\\n :\\\"host_data/login_ssh/kotletochka_dell_srv\\\",\\n \\\"value_template\\\":\\\"\\\n {{ '{{' }} value_json.date {{ '}}' }}\\\",\\n \\\"json_attributes_topic\\\":\\\"\\\n host_data/login_ssh/kotletochka_dell_srv\\\",\\n \\\"json_attributes_template\\\"\\\n :\\\"{{ '{{ {' }}'user':value_json.user, 'ruser':value_json.ruser, 'address':value_json.address,\\\n \\ 'service':value_json.service, 'tty':value_json.tty{{ '}' }} | tojson {{\\\n \\ '}}' }}\\\",\\n \\\"force_update\\\":\\\"true\\\",\\n \\\"device_class\\\":\\\"timestamp\\\"\\\n ,\\n \\\"icon\\\":\\\"mdi:ssh\\\", \\n \\\"unique_id\\\":\\\"login_ssh_kotletochka_dell_srv\\\"\\\n ,\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"login_ssh\\\"],\\\"manufacturer\\\":\\\"Enzokot\\\"\\\n ,\\\"model\\\":\\\"Local push\\\",\\\"name\\\":\\\"Login's ssh info\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/binary_sensor/dmesg_ext4_warning/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Kernel_EXT4_warning\\\", \\n \\\"state_topic\\\":\\\"host_data/dmesg_ext4_warning\\\"\\\n ,\\n \\\"icon\\\":\\\"mdi:harddisk\\\",\\n \\\"device_class\\\":\\\"problem\\\",\\n \\\"unique_id\\\"\\\n :\\\"dmesg_ext4_warning\\\",\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"host_kernel_info\\\"\\\n ],\\\"manufacturer\\\":\\\"Enzokot\\\",\\\"model\\\":\\\"Local polling\\\",\\\"name\\\":\\\"Host\\\n \\ kernel info\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/pve_processor_temperature/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"pve processor temperature\\\", \\n \\\"state_topic\\\"\\\n :\\\"host_data/host_sensors/cpu_temp\\\",\\n \\\"icon\\\":\\\"mdi:thermometer\\\", \\n\\\n \\ \\\"unit_of_measurement\\\":\\\"°C\\\",\\n \\\"device_class\\\":\\\"temperature\\\",\\n\\\n \\ \\\"unique_id\\\":\\\"pve_processor_temperature\\\",\\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"pve_sensors\\\"],\\\"manufacturer\\\":\\\"Enzokot\\\",\\\"model\\\":\\\"Local polling\\\"\\\n ,\\\"name\\\":\\\"PVE Sensors\\\"}\\n}\"",
|
||
"config": [
|
||
{
|
||
"name": "mqtt broker uptime",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.mqtt_broker_uptime",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notification front door open long time",
|
||
"automation": "- alias: notification front door open long time\n id: notification front door open long time\n initial_state: true\n triggers:\n trigger: state\n entity_id: binary_sensor.0x158d000359304c_contact\n from: 'off'\n to: 'on'\n for:\n minutes: 2\n actions:\n - parallel:\n - action: notify.telegram_enzokot_to_bot\n data:\n title: ⚠️ *Датчик открытия/закрытия*\n message: 'Входная дверь: открыта более 2 минут'\n - choose:\n - conditions:\n - condition: state\n entity_id: media_player.lg_smart_tv\n state: 'on'\n sequence:\n - action: notify.kotletochka_tv\n data:\n message: 'Входная дверь: открыта более 2 минут'",
|
||
"config": [
|
||
{
|
||
"name": "contact sensor",
|
||
"room": "hallway",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d000359304c_contact",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "lg smart tv",
|
||
"room": "bedroom",
|
||
"type": "media_player",
|
||
"id": {
|
||
"entity_id": "media_player.lg_smart_tv",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notification lobby door open long time",
|
||
"automation": "- alias: notification lobby door open long time\n id: notification lobby door open long time\n initial_state: true\n triggers:\n - trigger: state\n id: door_open\n entity_id: binary_sensor.lobby_door_open_long_time\n from: 'off'\n to: 'on'\n - trigger: state\n id: door_close\n entity_id: binary_sensor.lobby_door_open_long_time\n from: 'on'\n to: 'off'\n actions:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_all_chat_id\n disable_notification: true\n title: '{% if trigger.id == ''door_open'' -%} {{ ''\\U0001F513'' }} {%- else\n -%} {{ ''\\U0001f510'' }} {%- endif %} *Датчик открытия/закрытия*'\n message: 'Тамбурная дверь: {% if trigger.id == ''door_open'' -%} открыта более\n 5 минут {%- else -%} закрыта {% endif -%}'",
|
||
"config": [
|
||
{
|
||
"name": "lobby door open long time",
|
||
"room": "lobby",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.lobby_door_open_long_time",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram All Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_all_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notification sound front door open long time",
|
||
"automation": "- alias: notification sound front door open long time\n id: notification sound front door open long time\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.0x158d000359304c_contact\n from: 'off'\n to: 'on'\n for:\n minutes: 2\n conditions:\n - condition: state\n entity_id: input_boolean.alarm_gateway_button\n state: 'off'\n - condition: state\n entity_id: alarm_control_panel.signalka_shliuza_alarm\n state: disarmed\n - condition: or\n conditions:\n - condition: time\n after: '9:00:00'\n before: '13:30:00'\n - condition: time\n after: '16:30:00'\n before: '21:00:00'\n actions:\n - action: timer.start\n entity_id: timer.front_door_ringtone\n - parallel:\n - action: script.turn_on\n data:\n entity_id: script.alice_custom_tts_volume\n variables:\n entity: media_player.yandex_station_ff98f029b620413b35e5e278\n text: Внимание Входная дверь открыта\n vol_level: '0.65'\n - action: xiaomi_aqara.play_ringtone\n data:\n gw_mac: secret gateway1_mac\n ringtone_id: 10004\n ringtone_vol: 15",
|
||
"config": [
|
||
{
|
||
"name": "alarm gateway button",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.alarm_gateway_button",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "shliuza alarm control panel",
|
||
"room": null,
|
||
"type": "alarm_control_panel",
|
||
"id": {
|
||
"entity_id": "alarm_control_panel.signalka_shliuza_alarm",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "contact sensor",
|
||
"room": "hallway",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d000359304c_contact",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "yandex station 1",
|
||
"room": null,
|
||
"type": "media_player",
|
||
"id": {
|
||
"entity_id": "media_player.yandex_station_ff98f029b620413b35e5e278",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "alice custom tts volume script",
|
||
"room": null,
|
||
"type": "script",
|
||
"id": {
|
||
"entity_id": "script.alice_custom_tts_volume",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "front door ringtone timer",
|
||
"room": null,
|
||
"type": "timer",
|
||
"id": {
|
||
"entity_id": "timer.front_door_ringtone",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notification sound front door open long time repeat",
|
||
"automation": "- alias: notification sound front door open long time repeat\n id: notification sound front door open long time repeat\n initial_state: true\n triggers:\n - trigger: event\n event_type: timer.finished\n event_data:\n entity_id: timer.front_door_ringtone\n conditions:\n - condition: state\n entity_id: binary_sensor.0x158d000359304c_contact\n state: 'on'\n actions:\n - action: timer.start\n entity_id: timer.front_door_ringtone\n - parallel:\n - action: script.alice_custom_tts_volume\n data:\n entity: media_player.yandex_station_ff98f029b620413b35e5e278\n text: Внимание Входная дверь открыта\n vol_level: '0.65'\n - action: xiaomi_aqara.play_ringtone\n data:\n gw_mac: secret gateway1_mac\n ringtone_id: 10004\n ringtone_vol: 15",
|
||
"config": [
|
||
{
|
||
"name": "contact sensor",
|
||
"room": "hallway",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d000359304c_contact",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "yandex station 1",
|
||
"room": null,
|
||
"type": "media_player",
|
||
"id": {
|
||
"entity_id": "media_player.yandex_station_ff98f029b620413b35e5e278",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "alice custom tts volume script",
|
||
"room": null,
|
||
"type": "script",
|
||
"id": {
|
||
"entity_id": "script.alice_custom_tts_volume",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "front door ringtone timer",
|
||
"room": null,
|
||
"type": "timer",
|
||
"id": {
|
||
"entity_id": "timer.front_door_ringtone",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notification sound front door open long time cancel",
|
||
"automation": "- alias: notification sound front door open long time cancel\n id: notification sound front door open long time cancel\n initial_state: true\n triggers:\n - trigger: time\n at: '13:30:00'\n - trigger: time\n at: '21:00:00'\n - trigger: state\n id: binary_sensor_trigger\n entity_id: binary_sensor.0x158d000359304c_contact\n from: 'on'\n to: 'off'\n conditions:\n condition: state\n entity_id: timer.front_door_ringtone\n state: active\n actions:\n - action: timer.cancel\n entity_id: timer.front_door_ringtone\n - choose:\n - conditions: '{{ trigger.id == ''binary_sensor_trigger'' }}'\n sequence:\n - action: xiaomi_aqara.stop_ringtone\n data:\n gw_mac: secret gateway1_mac",
|
||
"config": [
|
||
{
|
||
"name": "contact sensor",
|
||
"room": "hallway",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d000359304c_contact",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "front door ringtone timer",
|
||
"room": null,
|
||
"type": "timer",
|
||
"id": {
|
||
"entity_id": "timer.front_door_ringtone",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notification front door open close",
|
||
"automation": "- alias: notification front door open close\n id: notification front door open close\n mode: queued\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.0x158d000359304c_contact\n from:\n - 'off'\n - 'on'\n to:\n - 'on'\n - 'off'\n actions:\n - variables:\n text_for_message: '{{ iif(trigger.to_state.state == ''on'', ''открыта'', ''закрыта'')\n }}'\n - parallel:\n - action: telegram_bot.send_message\n data:\n title: '{{ iif(trigger.to_state.state == ''on'', ''🚪'', ''🔐'') }} *Датчик\n открытия/закрытия*'\n message: 'Входная дверь: {{ text_for_message }}'\n disable_notification: true\n target: secret telegram_enzokot_chat_id\n - choose:\n - conditions:\n - condition: state\n entity_id: media_player.lg_smart_tv\n state: 'on'\n sequence:\n - action: notify.kotletochka_tv\n data:\n message: 'Входная дверь: {{ text_for_message }}'",
|
||
"config": [
|
||
{
|
||
"name": "contact sensor",
|
||
"room": "hallway",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d000359304c_contact",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "lg smart tv",
|
||
"room": "bedroom",
|
||
"type": "media_player",
|
||
"id": {
|
||
"entity_id": "media_player.lg_smart_tv",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notification front door open armed",
|
||
"automation": "- alias: notification front door open armed\n id: notification front door open armed\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.0x158d000359304c_contact\n to: 'on'\n conditions:\n - condition: state\n entity_id: alarm_control_panel.signalka_shliuza_alarm\n state: armed_away\n actions:\n - variables:\n sm_g973f_rezhim_ne_bespokoit: '{{ states(''sensor.sm_g973f_do_not_disturb_sensor'')\n }}'\n - choose:\n - conditions: '{{ sm_g973f_rezhim_ne_bespokoit = ''off'' }}'\n sequence:\n - action: notify.mobile_app_sm_g973f\n data:\n message: command_dnd\n data:\n command: 'off'\n - wait_for_trigger:\n - trigger: state\n entity_id: sensor.sm_g973f_do_not_disturb_sensor\n timeout:\n seconds: 5\n - variables:\n sm_g973f_rezhim_zvonka: '{{ states(''sensor.sm_g973f_ringer_mode'') }}'\n - choose:\n - conditions: '{{ sm_g973f_rezhim_zvonka = ''normal'' }}'\n sequence:\n - action: notify.notify\n data:\n message: command_ringer_mode\n data:\n command: normal\n - parallel:\n - action: telegram_bot.send_message\n data:\n title: '{{ ''\\U0001f6a8'' }} *Сигнализация*'\n message: Обнаружено вскрытие {{ trigger.to_state.attributes.friendly_name\n }} при включенной сигнализации\n target: secret telegram_all_chat_id\n inline_keyboard:\n - Выключить сирену:/stop_alarm\n - action: notify.notify\n data:\n title: '{{ ''🚨'' }} Сигнализация'\n message: Обнаружено вскрытие {{ trigger.to_state.attributes.friendly_name\n }} при включенной сигнализации\n data:\n ttl: 0\n priority: high\n channel: alarm_stream\n actions:\n - action: stop_alarm\n title: Выключить сирену\n - action: notify.huawei_lte\n data:\n message: 🚨 Обнаружено вскрытие {{ trigger.to_state.attributes.friendly_name\n }} при включенной сигнализации\n target: secret sms_phone_all\n data:\n url: http://192.168.8.1/\n - choose:\n - conditions: '{{ sm_g973f_rezhim_zvonka = ''normal'' }}'\n sequence:\n - action: notify.mobile_app_sm_g973f\n data:\n message: command_ringer_mode\n data:\n command: '{{ sm_g973f_rezhim_zvonka }}'\n - choose:\n - conditions: '{{ sm_g973f_rezhim_ne_bespokoit = ''off'' }}'\n sequence:\n - action: notify.mobile_app_sm_g973f\n data:\n message: command_dnd\n data:\n command: '{{ sm_g973f_rezhim_ne_bespokoit }}'",
|
||
"config": [
|
||
{
|
||
"name": "shliuza alarm control panel",
|
||
"room": null,
|
||
"type": "alarm_control_panel",
|
||
"id": {
|
||
"entity_id": "alarm_control_panel.signalka_shliuza_alarm",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "contact sensor",
|
||
"room": "hallway",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d000359304c_contact",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "do not disturb sensor",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.sm_g973f_do_not_disturb_sensor",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "ringer mode",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.sm_g973f_ringer_mode",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "SMS Phone All Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret sms_phone_all",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram All Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_all_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notification motion detected armed",
|
||
"automation": "- alias: notification motion detected armed\n id: notification motion detected armed\n initial_state: true\n mode: queued\n triggers:\n - trigger: state\n entity_id:\n - binary_sensor.0x158d00054b8d72_motion\n - binary_sensor.0x158d000566bde7_motion\n - binary_sensor.0x158d0003953ee9_motion\n to: 'on'\n conditions:\n - condition: state\n entity_id: alarm_control_panel.signalka_shliuza_alarm\n state: armed_away\n actions:\n - variables:\n sm_g973f_rezhim_ne_bespokoit: '{{ states(''sensor.sm_g973f_do_not_disturb_sensor'')\n }}'\n - choose:\n - conditions: '{{ sm_g973f_rezhim_ne_bespokoit = ''off'' }}'\n sequence:\n - action: notify.mobile_app_sm_g973f\n data:\n message: command_dnd\n data:\n command: 'off'\n - wait_for_trigger:\n - trigger: state\n entity_id: sensor.sm_g973f_do_not_disturb_sensor\n timeout:\n seconds: 5\n - variables:\n sm_g973f_rezhim_zvonka: '{{ states(''sensor.sm_g973f_ringer_mode'') }}'\n - choose:\n - conditions: '{{ sm_g973f_rezhim_zvonka = ''normal'' }}'\n sequence:\n - action: notify.notify\n data:\n message: command_ringer_mode\n data:\n command: normal\n - parallel:\n - action: telegram_bot.send_message\n data:\n title: '{{ ''\\U0001f6a8'' }} *Сигнализация*'\n message: Обнаружено движение _{{ trigger.to_state.attributes.friendly_name\n }}_ при включенной сигнализации\n target: secret telegram_all_chat_id\n inline_keyboard:\n - Выключить сирену:/stop_alarm\n - action: notify.notify\n data:\n title: '{{ ''🚨'' }} Сигнализация'\n message: Обнаружено движение {{ trigger.to_state.attributes.friendly_name\n }} при включенной сигнализации\n data:\n ttl: 0\n priority: high\n channel: alarm_stream\n actions:\n - action: stop_alarm\n title: Выключить сирену\n - action: notify.huawei_lte\n data:\n message: 🚨 Обнаружено движение {{ trigger.to_state.attributes.friendly_name\n }} при включенной сигнализации\n target: secret sms_phone_all\n data:\n url: http://192.168.8.1/\n - choose:\n - conditions: '{{ sm_g973f_rezhim_zvonka = ''normal'' }}'\n sequence:\n - action: notify.mobile_app_sm_g973f\n data:\n message: command_ringer_mode\n data:\n command: '{{ sm_g973f_rezhim_zvonka }}'\n - choose:\n - conditions: '{{ sm_g973f_rezhim_ne_bespokoit = ''off'' }}'\n sequence:\n - action: notify.mobile_app_sm_g973f\n data:\n message: command_dnd\n data:\n command: '{{ sm_g973f_rezhim_ne_bespokoit }}'",
|
||
"config": [
|
||
{
|
||
"name": "shliuza alarm control panel",
|
||
"room": null,
|
||
"type": "alarm_control_panel",
|
||
"id": {
|
||
"entity_id": "alarm_control_panel.signalka_shliuza_alarm",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "motion sensor 1",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d00054b8d72_motion",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "motion sensor 2",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d000566bde7_motion",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "motion sensor 3",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d0003953ee9_motion",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "do not disturb sensor",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.sm_g973f_do_not_disturb_sensor",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "ringer mode",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.sm_g973f_ringer_mode",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "SMS Phone All Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret sms_phone_all",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram All Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_all_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notification open window armed",
|
||
"automation": "- alias: notification open window armed\n id: notification open window armed\n initial_state: true\n mode: queued\n triggers:\n - trigger: state\n entity_id:\n - binary_sensor.window_bed_room_group\n - binary_sensor.window_childrens_room_group\n - binary_sensor.window_living_room_group\n - binary_sensor.window_kitchen_group\n to: 'on'\n conditions:\n - condition: state\n entity_id: alarm_control_panel.signalka_shliuza_alarm\n state: armed_away\n actions:\n - variables:\n sm_g973f_rezhim_ne_bespokoit: '{{ states(''sensor.sm_g973f_do_not_disturb_sensor'')\n }}'\n - choose:\n - conditions: '{{ sm_g973f_rezhim_ne_bespokoit = ''off'' }}'\n sequence:\n - action: notify.mobile_app_sm_g973f\n data:\n message: command_dnd\n data:\n command: 'off'\n - wait_for_trigger:\n - trigger: state\n entity_id: sensor.sm_g973f_do_not_disturb_sensor\n timeout:\n seconds: 5\n - variables:\n sm_g973f_rezhim_zvonka: '{{ states(''sensor.sm_g973f_ringer_mode'') }}'\n - choose:\n - conditions: '{{ sm_g973f_rezhim_zvonka = ''normal'' }}'\n sequence:\n - action: notify.notify\n data:\n message: command_ringer_mode\n data:\n command: normal\n - parallel:\n - action: telegram_bot.send_message\n data:\n title: '{{ ''\\U0001f6a8'' }} *Сигнализация*'\n message: Обнаружено вскрытие окна _{{ trigger.to_state.attributes.friendly_name\n }}_ при включенной сигнализации\n inline_keyboard:\n - Выключить сирену:/stop_alarm\n target: secret telegram_all_chat_id\n - action: notify.notify\n data:\n title: '{{ ''🚨'' }} Сигнализация'\n message: Обнаружено вскрытие окна {{ trigger.to_state.attributes.friendly_name\n }} при включенной сигнализации\n data:\n ttl: 0\n priority: high\n channel: alarm_stream\n actions:\n - action: stop_alarm\n title: Выключить сирену\n - action: notify.huawei_lte\n data:\n message: 🚨 Обнаружено вскрытие окна {{ trigger.to_state.attributes.friendly_name\n }} при включенной сигнализации\n target: secret sms_phone_all\n data:\n url: http://192.168.8.1/\n - choose:\n - conditions: '{{ sm_g973f_rezhim_zvonka = ''normal'' }}'\n sequence:\n - action: notify.mobile_app_sm_g973f\n data:\n message: command_ringer_mode\n data:\n command: '{{ sm_g973f_rezhim_zvonka }}'\n - choose:\n - conditions: '{{ sm_g973f_rezhim_ne_bespokoit = ''off'' }}'\n sequence:\n - action: notify.mobile_app_sm_g973f\n data:\n message: command_dnd\n data:\n command: '{{ sm_g973f_rezhim_ne_bespokoit }}'",
|
||
"config": [
|
||
{
|
||
"name": "shliuza alarm control panel",
|
||
"room": null,
|
||
"type": "alarm_control_panel",
|
||
"id": {
|
||
"entity_id": "alarm_control_panel.signalka_shliuza_alarm",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "window childrens room group",
|
||
"room": "childrens_room",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.window_childrens_room_group",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "window bed room group",
|
||
"room": "bedroom",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.window_bed_room_group",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "window kitchen group",
|
||
"room": "kitchen",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.window_kitchen_group",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "window living room group",
|
||
"room": "living_room",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.window_living_room_group",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "do not disturb sensor",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.sm_g973f_do_not_disturb_sensor",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "ringer mode",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.sm_g973f_ringer_mode",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "SMS Phone All Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret sms_phone_all",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram All Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_all_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notification gateway alarm triggered normal mode",
|
||
"automation": "- alias: notification gateway alarm triggered normal mode\n id: notification gateway alarm triggered normal mode\n mode: queued\n initial_state: true\n triggers:\n - trigger: state\n entity_id:\n - alarm_control_panel.54ef44315770_alarm\n - alarm_control_panel.54ef44cb80fd_alarm\n - alarm_control_panel.54ef443127b2_alarm\n to: triggered\n conditions:\n - condition: state\n entity_id: input_boolean.alarm_gateway_button\n state: 'off'\n - condition: state\n entity_id: alarm_control_panel.signalka_shliuza_alarm\n state: disarmed\n actions:\n - variables:\n sm_g973f_rezhim_ne_bespokoit: '{{ states(''sensor.sm_g973f_do_not_disturb_sensor'')\n }}'\n - choose:\n - conditions: '{{ sm_g973f_rezhim_ne_bespokoit = ''off'' }}'\n sequence:\n - action: notify.mobile_app_sm_g973f\n data:\n message: command_dnd\n data:\n command: 'off'\n - wait_for_trigger:\n - trigger: state\n entity_id: sensor.sm_g973f_do_not_disturb_sensor\n timeout:\n seconds: 5\n - variables:\n sm_g973f_rezhim_zvonka: '{{ states(''sensor.sm_g973f_ringer_mode'') }}'\n - choose:\n - conditions: '{{ sm_g973f_rezhim_zvonka = ''normal'' }}'\n sequence:\n - action: notify.notify\n data:\n message: command_ringer_mode\n data:\n command: normal\n - parallel:\n - action: telegram_bot.send_message\n data:\n title: '{{ ''\\U0001f6a8'' }} *Сигнализация*'\n message: Обнаружено срабатывание шлюза _{{ trigger.to_state.attributes.friendly_name\n }}_\n inline_keyboard:\n - Выключить сирену:/stop_alarm\n target: secret telegram_all_chat_id\n - action: notify.notify\n data:\n title: '{{ ''🚨'' }} Сигнализация'\n message: Обнаружено срабатывание шлюза {{ trigger.to_state.attributes.friendly_name\n }}\n data:\n ttl: 0\n priority: high\n channel: alarm_stream\n actions:\n - action: stop_alarm\n title: Выключить сирену\n - action: notify.huawei_lte\n data:\n message: 🚨 Обнаружено срабатывание шлюза {{ trigger.to_state.attributes.friendly_name\n }}\n target: secret sms_phone_all\n data:\n url: http://192.168.8.1/\n - choose:\n - conditions: '{{ sm_g973f_rezhim_zvonka = ''normal'' }}'\n sequence:\n - action: notify.mobile_app_sm_g973f\n data:\n message: command_ringer_mode\n data:\n command: '{{ sm_g973f_rezhim_zvonka }}'\n - choose:\n - conditions: '{{ sm_g973f_rezhim_ne_bespokoit = ''off'' }}'\n sequence:\n - action: notify.mobile_app_sm_g973f\n data:\n message: command_dnd\n data:\n command: '{{ sm_g973f_rezhim_ne_bespokoit }}'",
|
||
"config": [
|
||
{
|
||
"name": "alarm gateway button",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.alarm_gateway_button",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "shliuza alarm control panel",
|
||
"room": null,
|
||
"type": "alarm_control_panel",
|
||
"id": {
|
||
"entity_id": "alarm_control_panel.signalka_shliuza_alarm",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "do not disturb sensor",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.sm_g973f_do_not_disturb_sensor",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "ringer mode",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.sm_g973f_ringer_mode",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "alarm gateway 1",
|
||
"room": null,
|
||
"type": "alarm_control_panel",
|
||
"id": {
|
||
"entity_id": "alarm_control_panel.54ef44315770_alarm",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "alarm gateway 2",
|
||
"room": null,
|
||
"type": "alarm_control_panel",
|
||
"id": {
|
||
"entity_id": "alarm_control_panel.54ef44cb80fd_alarm",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "alarm gateway 3",
|
||
"room": null,
|
||
"type": "alarm_control_panel",
|
||
"id": {
|
||
"entity_id": "alarm_control_panel.54ef443127b2_alarm",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "SMS Phone All Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret sms_phone_all",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram All Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_all_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "vacuum cleaner error to all",
|
||
"automation": "- alias: vacuum cleaner error to all\n id: vacuum cleaner error to all\n initial_state: true\n triggers:\n - trigger: state\n entity_id: vacuum.xiaomi_vacuum_cleaner\n attribute: status\n to:\n - Error\n - In Error\n - Charging Error\n actions:\n - parallel:\n - action: telegram_bot.send_photo\n data:\n target: secret telegram_all_chat_id\n url: '{{- ''http://homeassistant.local.hass.io:8123'' + state_attr(''camera.roborock_vacuum_map'',\n ''entity_picture'') -}}'\n caption: ⚠️ *Степа* {{- '\\n' -}} Похоже я застрял или какая то другая ошибка\n inline_keyboard:\n - Найти меня (громко):/findvacuum\n - choose:\n - conditions:\n - condition: state\n entity_id: media_player.lg_smart_tv\n state: 'on'\n sequence:\n - action: notify.kotletochka_tv\n data:\n message: 'Степа: мне нужна помощь'",
|
||
"config": [
|
||
{
|
||
"name": "lg smart tv",
|
||
"room": "bedroom",
|
||
"type": "media_player",
|
||
"id": {
|
||
"entity_id": "media_player.lg_smart_tv",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "vacuum xiaomi",
|
||
"room": null,
|
||
"type": "vacuum",
|
||
"id": {
|
||
"entity_id": "vacuum.xiaomi_vacuum_cleaner",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "roborock vacuum map camera",
|
||
"room": null,
|
||
"type": "camera",
|
||
"id": {
|
||
"entity_id": "camera.roborock_vacuum_map",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram All Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_all_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "vacuum cleaner after cleaning chita",
|
||
"automation": "- alias: vacuum cleaner after cleaning chita\n id: vacuum cleaner after cleaning chita\n initial_state: true\n triggers:\n - trigger: state\n entity_id: vacuum.xiaomi_vacuum_cleaner\n from: returning\n to: docked\n conditions:\n condition: template\n value_template: '{{ (states(''sensor.xiaomi_vacuum_cleaner_total_clean_area'')\n | int(0) ) > (states(''input_number.total_cleaned_area_saved'') | int(0) ) +\n 30 }}'\n actions:\n - variables:\n current_clean_area: '{{ states(''sensor.xiaomi_vacuum_cleaner_current_clean_area'')\n | round(0, ''ceil'', 0) | string + state_attr(''sensor.xiaomi_vacuum_cleaner_current_clean_area'',\n ''unit_of_measurement'') }}'\n current_clean_duration: \"{% set uptime = states('sensor.xiaomi_vacuum_cleaner_current_clean_duration')\\\n \\ | int(0) %} {% set minutes = (( uptime % 3600) / 60) | int(0) %} {% set\\\n \\ hours = ((uptime % 86400) / 3600) | int(0) %} {% set days = (uptime / 86400)\\\n \\ | int(0) %}\\n {% if uptime < 1 %}\\n Меньше минуты\\n {%- else %}\\n \\\n \\ {% if days > 0 %}\\n {{ days -}} д.\\n {%- endif %}\\n {%- if\\\n \\ hours > 0 %}\\n {%- if days > 0 %}\\n {{- ' ' -}}\\n {% endif\\\n \\ -%}\\n {{ hours -}} ч.\\n {%- endif %}\\n {%- if minutes > 0 %}\\n\\\n \\ {%- if days > 0 or hours > 0 %}\\n {{- ' ' -}}\\n {% endif\\\n \\ -%}\\n {{ minutes -}} м.\\n {%- endif -%}\\n {% endif %}\"\n - parallel:\n - action: telegram_bot.send_photo\n data:\n target: secret telegram_chita_chat_id\n url: '{{- ''http://homeassistant.local.hass.io:8123'' + state_attr(''camera.roborock_vacuum_map'',\n ''entity_picture'') -}}'\n caption: '{{ ''\\U0001f4af'' }} *Степа* {{- ''\\n'' -}} Вернулся на базу (длительность:\n {{- current_clean_duration -}}, площадь: {{- current_clean_area -}}), нужно\n снять бак с водой и заглянуть в контейнер пылесборника'\n - action: input_number.set_value\n data:\n entity_id: input_number.total_cleaned_area_saved\n value: '{{ (states(''sensor.xiaomi_vacuum_cleaner_total_clean_area'') | int(0)\n ) }}'\n - choose:\n - conditions:\n - condition: state\n entity_id: media_player.lg_smart_tv\n state: 'on'\n sequence:\n - action: notify.kotletochka_tv\n data:\n message: 'Степа: вернулся на базу'",
|
||
"config": [
|
||
{
|
||
"name": "lg smart tv",
|
||
"room": "bedroom",
|
||
"type": "media_player",
|
||
"id": {
|
||
"entity_id": "media_player.lg_smart_tv",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "vacuum xiaomi",
|
||
"room": null,
|
||
"type": "vacuum",
|
||
"id": {
|
||
"entity_id": "vacuum.xiaomi_vacuum_cleaner",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "roborock vacuum map camera",
|
||
"room": null,
|
||
"type": "camera",
|
||
"id": {
|
||
"entity_id": "camera.roborock_vacuum_map",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "xiaomi vacuum total clean area",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.xiaomi_vacuum_cleaner_total_clean_area",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "total cleaned area saved",
|
||
"room": null,
|
||
"type": "input_number",
|
||
"id": {
|
||
"entity_id": "input_number.total_cleaned_area_saved",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "xiaomi vacuum current clean area",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.xiaomi_vacuum_cleaner_current_clean_area",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "xiaomi vacuum current clean duration",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.xiaomi_vacuum_cleaner_current_clean_duration",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Chita Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_chita_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "smoke detector alarm",
|
||
"automation": "- alias: smoke detector alarm\n id: smoke detector alarm\n initial_state: true\n triggers:\n - trigger: state\n entity_id:\n - binary_sensor.0x158d0003943639_smoke\n - binary_sensor.0x158d00039a8358_smoke\n - binary_sensor.0x158d00039d9398_smoke\n - binary_sensor.0x158d00045ca483_smoke\n - binary_sensor.0x00158d00045cd551_smoke\n to: 'on'\n actions:\n - variables:\n sm_g973f_rezhim_ne_bespokoit: '{{ states(''sensor.sm_g973f_do_not_disturb_sensor'')\n }}'\n - choose:\n - conditions: '{{ sm_g973f_rezhim_ne_bespokoit = ''off'' }}'\n sequence:\n - action: notify.mobile_app_sm_g973f\n data:\n message: command_dnd\n data:\n command: 'off'\n - wait_for_trigger:\n - trigger: state\n entity_id: sensor.sm_g973f_do_not_disturb_sensor\n timeout:\n seconds: 5\n - variables:\n sm_g973f_rezhim_zvonka: '{{ states(''sensor.sm_g973f_ringer_mode'') }}'\n areas_list: '{{ states.binary_sensor | selectattr(''entity_id'', ''match'',\n ''.*_smoke'') | selectattr(''state'', ''eq'', ''on'') | map(attribute=''entity_id'')\n | map(''area_name'') | reject(''none'') | unique | join(''\n\n '') }}'\n - choose:\n - conditions: '{{ sm_g973f_rezhim_zvonka = ''normal'' }}'\n sequence:\n - action: notify.notify\n data:\n message: command_ringer_mode\n data:\n command: normal\n - parallel:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_all_chat_id\n title: '{{ ''\\U0001F525'' }} *Датчик дыма*'\n message: 'Сработали датчики:\n\n {{- ''\\n'' -}}\n\n _{{- areas_list -}}_'\n inline_keyboard:\n - Выключить сирену:/stop_alarm\n - action: notify.notify\n data:\n data:\n ttl: 0\n priority: high\n channel: alarm_stream\n actions:\n - action: stop_alarm\n title: Выключить сирену\n title: '{{ ''🔥'' }} Датчик дыма'\n message: 'Сработали датчики:\n\n {{- ''\\n'' -}}\n\n {{- areas_list -}}'\n - action: notify.huawei_lte\n data:\n message: '{{ ''\\U0001F525'' }} Сработали датчики дыма:\n\n {{- ''\\n'' -}}\n\n {{- areas_list -}}'\n target: secret sms_phone_all\n data:\n url: http://192.168.8.1/\n - choose:\n - conditions: '{{ sm_g973f_rezhim_zvonka = ''normal'' }}'\n sequence:\n - action: notify.mobile_app_sm_g973f\n data:\n message: command_ringer_mode\n data:\n command: '{{ sm_g973f_rezhim_zvonka }}'\n - choose:\n - conditions: '{{ sm_g973f_rezhim_ne_bespokoit = ''off'' }}'\n sequence:\n - action: notify.mobile_app_sm_g973f\n data:\n message: command_dnd\n data:\n command: '{{ sm_g973f_rezhim_ne_bespokoit }}'",
|
||
"config": [
|
||
{
|
||
"name": "smoke sensor 1",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d0003943639_smoke",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "smoke sensor 2",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d00039a8358_smoke",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "smoke sensor 3",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d00039d9398_smoke",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "smoke sensor 4",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d00045ca483_smoke",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "smoke sensor 5",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x00158d00045cd551_smoke",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "do not disturb sensor",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.sm_g973f_do_not_disturb_sensor",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "ringer mode",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.sm_g973f_ringer_mode",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "SMS Phone All Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret sms_phone_all",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram All Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_all_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notification cert expired",
|
||
"automation": "- alias: notification cert expired\n id: notification cert expired\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.cert_expired_keenetic_domain\n from: 'off'\n to: 'on'\n - trigger: state\n entity_id: binary_sensor.cert_expired_asuscomm_domain_klg\n from: 'off'\n to: 'on'\n actions:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n title: ⚠️ *Сертификат SSL*\n message: '{%- set entity_name = trigger.entity_id | replace(''binary_'', '''')\n | replace(''_expired_'', ''_expiry_'') -%} Срок действия сертификата для _{{\n trigger.to_state.name -}}_: *{{- states(entity_name) -}}* {{ state_attr(entity_name,\n ''unit_of_measurement'') }}'",
|
||
"config": [
|
||
{
|
||
"name": "cert expired keenetic domain",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.cert_expired_keenetic_domain",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "cert expired asuscomm domain klg",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.cert_expired_asuscomm_domain_klg",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "update available or installed notification",
|
||
"automation": "- alias: update available or installed notification\n initial_state: true\n mode: queued\n trigger_variables:\n not_has_state: '{{ [''unknown'', ''unavailable'', ''none'', None, null, '''']\n }}'\n triggers:\n - trigger: event\n event_type: state_changed\n conditions:\n - '{{ trigger.event.data.entity_id.startswith(''update.'') }}'\n - '{{ trigger.event.data.old_state is not none and trigger.event.data.new_state\n is not none }}'\n - '{{ trigger.event.data.new_state.attributes.latest_version is defined and trigger.event.data.new_state.attributes.installed_version\n is defined }}'\n - '{{ trigger.event.data.old_state.attributes.latest_version is defined and trigger.event.data.old_state.attributes.installed_version\n is defined }}'\n - or:\n - condition: template\n value_template: \"{{ \\n trigger.event.data.new_state.state == 'on' and\\n ((is_state_attr(trigger.event.data.entity_id,\\\n \\ 'device_class', 'firmware')\\n and version(trigger.event.data.new_state.attributes.latest_version)\\\n \\ = version(trigger.event.data.old_state.attributes.latest_version))\\n or\\\n \\ version(trigger.event.data.new_state.attributes.latest_version) > version(trigger.event.data.old_state.attributes.latest_version))\\\n \\ and\\n trigger.event.data.new_state.attributes.latest_version not in not_has_state\\\n \\ and\\n trigger.event.data.new_state.attributes.latest_version is not none\\n\\\n }}\\n\"\n - condition: template\n value_template: \"{{ \\n trigger.event.data.old_state.state == 'on' and trigger.event.data.new_state.state\\\n \\ == 'off' and\\n ((is_state_attr(trigger.event.data.entity_id, 'device_class',\\\n \\ 'firmware')\\n and version(trigger.event.data.new_state.attributes.installed_version)\\\n \\ = version(trigger.event.data.old_state.attributes.installed_version))\\n\\\n \\ or version(trigger.event.data.new_state.attributes.installed_version) >\\\n \\ version(trigger.event.data.old_state.attributes.installed_version)) and\\n\\\n \\ trigger.event.data.new_state.attributes.installed_version not in not_has_state\\\n \\ and\\n trigger.event.data.new_state.attributes.installed_version is not\\\n \\ none\\n}}\\n\"\n actions:\n - variables:\n release_url: \"{% if trigger.event.data.entity_id == 'update.home_assistant_core_update'\\\n \\ -%}\\n {%- if state_attr(trigger.event.data.entity_id, 'latest_version').split('.')[2]\\\n \\ | int(0) == 0 -%}\\n {{- state_attr(trigger.event.data.entity_id, 'release_url')\\\n \\ -}}\\n {%- else -%}\\n https://github.com/home-assistant/core/releases/tag/{{-\\\n \\ trigger.event.data.new_state.attributes.latest_version -}}\\n {%- endif\\\n \\ -%}\\n{%- elif state_attr(trigger.event.data.entity_id, 'release_url') is\\\n \\ not none -%}\\n {{- state_attr(trigger.event.data.entity_id, 'release_url')\\\n \\ -}}\\n{%- elif device_attr(trigger.event.data.entity_id, 'configuration_url')\\\n \\ is match('homeassistant://', ignorecase=True) -%}\\n {{- device_attr(trigger.event.data.entity_id,\\\n \\ 'configuration_url') | replace('homeassistant:/', states('sensor.instance_external_url_config'))\\\n \\ -}}\\n{%- else -%}\\n {{- states('sensor.instance_external_url_config') -}}/config/dashboard\\n\\\n {%- endif %}\"\n latest_version: '{{ trigger.event.data.new_state.attributes.latest_version }}'\n installed_version: '{{ state_attr(trigger.event.data.entity_id, ''installed_version'')\n }}'\n friendlyname: '{{- trigger.event.data.new_state.name | replace('' Update'',\n '''') -}}'\n - choose:\n - conditions: '{{ trigger.event.data.new_state.attributes.installed_version =\n trigger.event.data.old_state.attributes.installed_version }}\n\n '\n sequence:\n - variables:\n old_installed_version: '{{ trigger.event.data.old_state.attributes.installed_version\n }}'\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n title: '{{ ''🎊'' }} *Системное обновление*'\n message: 'Обновлен {{ friendlyname }} с {{ old_installed_version }} на [{{\n latest_version }}]({{- release_url }}) версию.\n\n '\n disable_web_page_preview: true\n default:\n - parallel:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n title: '{{ ''🎉'' }} *Системное обновление*'\n message: 'Доступна [{{ latest_version }}]({{- release_url }}) версия {{\n friendlyname }} для установки, текущая *{{ installed_version }}*.\n\n '\n disable_web_page_preview: true\n inline_keyboard: '{{ iif(state_attr(trigger.event.data.entity_id, ''supported_features'')\n | int(0) > 0, [''Установить:/installupdate '' + trigger.event.data.entity_id],\n []) }}'\n - sequence:\n - condition: '{{ not is_state_attr(trigger.event.data.entity_id, ''device_class'',\n ''firmware'') }}'\n - action: notify.html5\n data:\n title: '{{ ''🎉'' }} *Системное обновление*'\n message: Доступна {{ latest_version }} версия {{ friendlyname }} для установки,\n текущая {{ installed_version }}\n target: n550jk\n data:\n url: '{{- release_url }}'\n actions: '{{ iif(state_attr(trigger.event.data.entity_id, ''supported_features'')\n | int(0) > 0, [{''action'':''install_update'', ''title'':''Обновить''}],\n []) }}'\n tag: 'update_available_notify_ {{- trigger.event.data.entity_id | replace(''update.'',\n '''') }}\n\n '",
|
||
"config": [
|
||
{
|
||
"name": "home assistant core update",
|
||
"room": null,
|
||
"type": "update",
|
||
"id": {
|
||
"entity_id": "update.home_assistant_core_update",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "instance external url config",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.instance_external_url_config",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "N550JK",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "n550jk",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notification low battery zigbee",
|
||
"automation": "- alias: notification low battery zigbee\n id: notification low battery zigbee\n initial_state: true\n triggers:\n - trigger: time\n at: '20:00:00'\n conditions: \"{%- set entities = expand('group.dynamic_group_sensor_battery') -%}\\\n \\ {%- set datanames = namespace(entity_name=[]) -%} {% for x in entities -%}\\n\\\n \\ {% set entity_this_z2m = states.sensor[x.entity_id | replace('sensor.', '')\\\n \\ | replace('_battery', '_last_seen')] is not none -%}\\n {% set entity_this_gw3\\\n \\ = states.sensor[x.entity_id | replace('sensor.', '') | replace('_battery', '_zigbee')]\\\n \\ is not none -%}\\n {% if (not x.entity_id.endswith(\\\"_low_battery\\\") and x.state\\\n \\ | int(101) <= iif(entity_this_z2m or entity_this_gw3, 55, 20)) or (x.entity_id.endswith(\\\"\\\n _low_battery\\\") and x.state | string == 'on') -%}\\n {% set datanames.entity_name\\\n \\ = datanames.entity_name + ['_' + x.name + '_'] -%}\\n {% endif %}\\n{%- endfor\\\n \\ %} {{ datanames.entity_name | list | count > 0 }}\\n\"\n actions:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n title: '{{ ''\\U0001f50b'' -}} *Низкий заряд*'\n message: \"Для устройств: {{- '\\\\n' -}} {%- set entities = expand('group.dynamic_group_sensor_battery')\\\n \\ -%} {%- set datanames = namespace(entity_name=[]) -%} {% for x in entities\\\n \\ -%}\\n {% set entity_this_z2m = states.sensor[x.entity_id | replace('sensor.',\\\n \\ '') | replace('_battery', '_last_seen')] is not none -%}\\n {% set entity_this_gw3\\\n \\ = states.sensor[x.entity_id | replace('sensor.', '') | replace('_battery',\\\n \\ '_zigbee')] is not none -%}\\n {% if (not x.entity_id.endswith(\\\"_low_battery\\\"\\\n ) and x.state | int(101) <= iif(entity_this_z2m or entity_this_gw3, 55, 20))\\\n \\ -%}\\n {% set datanames.entity_name = datanames.entity_name + ['_' + x.name\\\n \\ + '_' + ': *' + x.state + '*%'] -%}\\n {% endif -%}\\n {% if (x.entity_id.endswith(\\\"\\\n _low_battery\\\") and x.state | string == 'on') -%}\\n {% set datanames.entity_name\\\n \\ = datanames.entity_name + ['_' + x.name + '_'] -%}\\n {% endif %}\\n{%- endfor\\\n \\ %} {{- datanames.entity_name | list | join(', \\\\n') }}\"",
|
||
"config": [
|
||
{
|
||
"name": "dynamic group sensor battery",
|
||
"room": null,
|
||
"type": "group",
|
||
"id": {
|
||
"entity_id": "group.dynamic_group_sensor_battery",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notification safety sockets on restart",
|
||
"automation": "- alias: notification safety sockets on restart\n id: notification safety sockets on restart\n initial_state: true\n triggers:\n - trigger: homeassistant\n event: start\n conditions:\n - condition: state\n entity_id: switch.0x842e14fffe5047f5\n state: 'on'\n actions:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n title: '{{ ''\\U0001f50c'' }} *Управляемые розетки*'\n message: После перезапуска НА осталась включена розетка обогревателя.",
|
||
"config": [
|
||
{
|
||
"name": "heater socket",
|
||
"room": "childrens_room",
|
||
"type": "switch",
|
||
"id": {
|
||
"entity_id": "switch.0x842e14fffe5047f5",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notification safety sockets off",
|
||
"automation": "- alias: notification safety sockets off\n id: notification safety sockets off\n initial_state: true\n triggers:\n - trigger: numeric_state\n entity_id:\n - sensor.0x842e14fffe5047f5_power\n - sensor.0x842e14fffe13a854_power\n - sensor.0x588e81fffeff5c4f_power\n - sensor.0x842e14fffe36661f_power\n - sensor.shelly_plug_s_1_power\n - sensor.0x60a423fffef8d41a_power\n - sensor.shelly_plug_s_2_power\n - sensor.shelly_plug_s_nvr_power\n - sensor.shelly_plug_s_keenetic_hw_power\n - sensor.shelly_plug_s_htr_shelly_heated_tr_power\n above: 3000\n actions:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n title: ⚠️ *Управляемые розетки*\n message: 'Сработала защита по превышению потребления для розетки: {{ ''\\n''\n }} _{{ device_attr(trigger.entity_id, ''name'') }}_'",
|
||
"config": [
|
||
{
|
||
"name": "water heater socket power",
|
||
"room": "bathroom",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x842e14fffe13a854_power",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "heater socket power",
|
||
"room": "childrens_room",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x842e14fffe5047f5_power",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "kitchen socket1 power",
|
||
"room": "kitchen",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x842e14fffe36661f_power",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "bedroom socket1 power",
|
||
"room": "bedroom",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x588e81fffeff5c4f_power",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "server ac power",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.shelly_plug_s_1_power",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "shelly plug s 2 power",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.shelly_plug_s_2_power",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "shelly plug s nvr power",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.shelly_plug_s_nvr_power",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "shelly plug s keenetic hw power",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.shelly_plug_s_keenetic_hw_power",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "shelly plug s htr power",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.shelly_plug_s_htr_shelly_heated_tr_power",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Bedroom Socket 2 Power",
|
||
"room": "Bedroom",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x60a423fffef8d41a_power",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notification public ip changed",
|
||
"automation": "- alias: notification public ip changed\n id: notification public ip changed\n initial_state: true\n mode: queued\n triggers:\n - trigger: state\n entity_id: sensor.myip\n actions:\n - parallel:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n title: '{{ ''\\U0001f4f6'' }} *Трекинг устройств*'\n message: \"{%- if trigger.from_state.state in ['unavailable', 'unknown', '']\\\n \\ -%}\\n Внешний IP-адрес определен `{{ trigger.to_state.state }}`\\n{%-\\\n \\ else -%}\\n Внешний IP-адрес изменен с `{{ trigger.from_state.state\\\n \\ }}` на `{{ trigger.to_state.state }}`\\n{%- endif -%}\"\n - action: notify.notify\n data:\n title: '{{ ''\\U0001f4f6'' }} Трекинг устройств'\n message: \"{%- if trigger.from_state.state in ['unavailable', 'unknown', '']\\\n \\ -%}\\n Внешний IP-адрес определен {{ trigger.to_state.state }}\\n{%-\\\n \\ else -%}\\n Внешний IP-адрес изменен с {{ trigger.from_state.state }}\\\n \\ на {{ trigger.to_state.state }}\\n{%- endif -%}\"\n - choose:\n - conditions:\n - condition: state\n entity_id: media_player.lg_smart_tv\n state: 'on'\n sequence:\n - action: notify.kotletochka_tv\n data:\n message: 'Интернет: возможно переключились на LTE'",
|
||
"config": [
|
||
{
|
||
"name": "myip",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.myip",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "lg smart tv",
|
||
"room": "bedroom",
|
||
"type": "media_player",
|
||
"id": {
|
||
"entity_id": "media_player.lg_smart_tv",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notification low level water",
|
||
"automation": "- alias: notification low level water\n id: notification low level water\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.zhimi_humidifier_cb1_low_water_level\n from: 'off'\n to: 'on'\n - trigger: state\n entity_id: binary_sensor.zhimi_humidifier_ca4_low_water_level\n from: 'off'\n to: 'on'\n conditions:\n - '{{ states(trigger.entity_id | replace(''binary_sensor.'', ''sensor.'') | replace(''_low'',\n '''')) | int(0) > 0 }}'\n actions:\n - parallel:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_all_chat_id\n title: '{{ ''\\U0001F6B0'' }} *Увлажнители*'\n message: 'Пора залить воду в увлажнитель: _{{- trigger.to_state.name -}}_'\n - choose:\n - conditions:\n - condition: state\n entity_id: media_player.lg_smart_tv\n state: 'on'\n sequence:\n - action: notify.kotletochka_tv\n data:\n message: 'Нет воды: {{- trigger.to_state.name -}}'",
|
||
"config": [
|
||
{
|
||
"name": "lg smart tv",
|
||
"room": "bedroom",
|
||
"type": "media_player",
|
||
"id": {
|
||
"entity_id": "media_player.lg_smart_tv",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "zhimi humidifier cb1 low water level",
|
||
"room": "bedroom",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.zhimi_humidifier_cb1_low_water_level",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "zhimi humidifier ca4 low water level",
|
||
"room": "childrens_room",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.zhimi_humidifier_ca4_low_water_level",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram All Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_all_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notification vacuum maintenance",
|
||
"automation": "- alias: notification vacuum maintenance\n id: notification vacuum maintenance\n initial_state: true\n mode: queued\n triggers:\n - trigger: state\n entity_id:\n - binary_sensor.vacuum_cleaner_main_brush_maintenance\n - binary_sensor.vacuum_cleaner_side_brush_maintenance\n - binary_sensor.vacuum_cleaner_filter_maintenance\n - binary_sensor.vacuum_cleaner_sensor_dirty_maintenance\n from: 'off'\n to: 'on'\n actions:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_all_chat_id\n title: '{{ ''\\U0001F527'' }} *Степа*'\n message: 'Необходимо провести обслуживание: _{{- trigger.to_state.name -}}_'",
|
||
"config": [
|
||
{
|
||
"name": "vacuum cleaner main brush maintenance",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.vacuum_cleaner_main_brush_maintenance",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "vacuum cleaner side brush maintenance",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.vacuum_cleaner_side_brush_maintenance",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "vacuum cleaner filter maintenance",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.vacuum_cleaner_filter_maintenance",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "vacuum cleaner sensor dirty maintenance",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.vacuum_cleaner_sensor_dirty_maintenance",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram All Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_all_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notifications control voltage",
|
||
"automation": "- alias: notifications control voltage\n id: notifications control voltage\n initial_state: true\n mode: queued\n triggers:\n - trigger: numeric_state\n entity_id: sensor.shelly_em_voltage\n above: 250\n - trigger: numeric_state\n entity_id: sensor.shelly_em_voltage\n below: 180\n - trigger: numeric_state\n entity_id: sensor.shelly_em_voltage\n above: 179.9\n below: 250.1\n conditions:\n - condition: template\n value_template: \"{{ trigger.from_state.state not in ['unavailable', 'unknown',\\\n \\ ''] and\\n (\\n trigger.above == None or trigger.below == None or\\n \\\n \\ (trigger.from_state.state | float(0.0) >= trigger.below\\n or trigger.from_state.state\\\n \\ | float(0.0) <= trigger.above)\\n )\\n and trigger.from_state.state |\\\n \\ float(-1.0) >= 0\\n and trigger.to_state.state | float(-1.0) >= 0\\n}}\"\n actions:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n title: '{% if trigger.above = None and trigger.below = None %} {{ ''\\U00002705''\n }} {% else %} ⚠️ {% endif -%} *Контроль напряжения*'\n message: \"{% if trigger.above = None and trigger.below == None and trigger.to_state.state\\\n \\ | float(0.0) >= trigger.above | float(0.0) %}\\n Обнаружено *повышенное*\\\n \\ напряжение сети {{ trigger.to_state.state }}В\\n{% elif trigger.above ==\\\n \\ None and trigger.below = None and trigger.to_state.state | float(0.0) <=\\\n \\ trigger.below | float(0.0) %}\\n Обнаружено *пониженное* напряжение сети\\\n \\ {{ trigger.to_state.state }}В\\n{% else %}\\n В сети *нормальное* напряжение\\\n \\ {{ trigger.to_state.state }}В\\n{% endif %}\"",
|
||
"config": [
|
||
{
|
||
"name": "shelly em voltage",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.shelly_em_voltage",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notifications backup instance info",
|
||
"automation": "- alias: notifications backup instance info\n id: notifications backup instance info\n mode: queued\n trigger_variables:\n not_has_state: '{{ [''unknown'', ''unavailable'', ''none'', None, null, '''']\n }}'\n triggers:\n - trigger: state\n entity_id: sensor.last_google_backup_train\n conditions:\n - condition: template\n value_template: \"{{\\n trigger.from_state.state is defined and\\n trigger.to_state.state\\\n \\ is defined and\\n trigger.from_state.state not in not_has_state\\n and trigger.to_state.state\\\n \\ not in not_has_state\\n and state_attr('sensor.backup_state', 'backups')\\\n \\ | count > 0\\n}}\"\n actions:\n - action: homeassistant.update_entity\n entity_id: sensor.disk_use_percent\n - wait_for_trigger:\n - trigger: state\n entity_id: sensor.disk_use_percent\n timeout:\n seconds: 10\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n title: '{{ ''\\U0001F4BD'' }} *Резервное копирование*'\n message: Создана резервная копия с именем `{{ state_attr('sensor.backup_state',\n 'backups')[-1].name }}`, системный диск заполнен на *{{ states('sensor.disk_use_percent')\n -}}*%, свободно на Google диске *{{ state_attr('sensor.backup_state', 'free_space_in_google_drive')\n | replace(' ', '') }}*",
|
||
"config": [
|
||
{
|
||
"name": "last google backup train",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.last_google_backup_train",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "backup state",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.backup_state",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "disk use percent",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.disk_use_percent",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notifications failed login or block IP",
|
||
"automation": "- alias: notifications failed login or block IP\n id: notifications failed login or block IP\n mode: parallel\n initial_state: true\n triggers:\n - trigger: persistent_notification\n id: http-login\n update_type:\n - added\n - updated\n notification_id: http-login\n - trigger: persistent_notification\n id: ip-ban\n update_type:\n - added\n - updated\n notification_id: ip-ban\n actions:\n - parallel:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n title: \"{%- if trigger.id == 'http-login' %}\\n {{- '\\\\U0001F6AB' -}}\\n\\\n {% else %}\\n {{- '\\\\U000026D4' -}}\\n{% endif %} *Вход в систему*\"\n message: \"{% set ipadress = trigger.notification.message | replace('\\\\n',\\\n \\ ' ') | regex_replace('.*\\\\((?=\\\\d+\\\\.\\\\d+\\\\.\\\\d+\\\\.\\\\d+)') | regex_replace('\\\\\\\n ).*')\\n | replace('Too many login attempts from ', '') %}\\n\\n{% if trigger.id\\\n \\ == 'http-login' -%}\\n Неудачная попытка входа в систему с адреса [{{\\\n \\ ipadress }}](https://whatismyipaddress.com/ip/{{- ipadress }})\\n{%- else\\\n \\ -%}\\n Заблокирован IP адрес [{{ ipadress }}](https://whatismyipaddress.com/ip/{{-\\\n \\ ipadress }}), 5 попыток входа\\n{%- endif %}, [логи]({{- states('sensor.instance_external_url_config')\\\n \\ -}}/config/logs)\\n\"\n disable_web_page_preview: true\n - action: persistent_notification.dismiss\n data:\n notification_id: '{{ trigger.id }}'",
|
||
"config": [
|
||
{
|
||
"name": "instance external url config",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.instance_external_url_config",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notification start or stop home assistant",
|
||
"automation": "- alias: notification start or stop home assistant\n id: notification start or stop home assistant\n mode: parallel\n initial_state: true\n triggers:\n - trigger: homeassistant\n id: homeassistant_start\n event: start\n - trigger: homeassistant\n event: shutdown\n actions:\n - variables:\n long_start_integrations_name: \"{% if states.sensor.start_time.attributes is\\\n \\ defined and states.sensor.start_time.attributes.setup_time is defined %}\\n\\\n \\ {% set separator = joiner(', ') %}\\n {% set attrs = states.sensor.start_time.attributes.setup_time\\\n \\ %}\\n {% for attr in attrs if attrs[attr] | float(0.0) >= 9 %}\\n {{-\\\n \\ separator() + attr | replace('_', '-') -}}\\n {% endfor %}\\n{% else %}\\n\\\n \\ {{ '' }}\\n{% endif %}\"\n - if:\n - condition: trigger\n id: homeassistant_start\n then:\n - action: homeassistant.update_entity\n data:\n entity_id:\n - sensor.errors_in_system_log_command_line\n - sensor.warnings_in_system_log_command_line\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n disable_notification: true\n disable_web_page_preview: true\n title: \"{%- if trigger.id == 'homeassistant_start' %}\\n {{- '\\\\U00002705'\\\n \\ -}}\\n{% else %}\\n {{- '\\\\U000026d4' -}}\\n{% endif %} *Трекинг устройств*\\n\"\n message: \"{% if trigger.id == 'homeassistant_start' -%}\\n Home Assistant\\\n \\ запущен за {{ states('sensor.start_time') }}сек. (версия Core: [{{ state_attr('update.home_assistant_core_update',\\\n \\ 'installed_version') }}](https://github.com/home-assistant/core/releases/tag/{{-\\\n \\ state_attr('update.home_assistant_core_update', 'installed_version') }}))\\\n \\ {{- '\\\\n' -}}\\n Ошибок: *{{ states('sensor.errors_in_system_log_command_line')\\\n \\ }}*, предупреждений: *{{ states('sensor.warnings_in_system_log_command_line')\\\n \\ }}* {{- '\\\\n' -}}\\n {{ iif(long_start_integrations_name = '', 'Интеграции\\\n \\ (>9c.): _' + long_start_integrations_name + '_', '') }}\\n{% else -%}\\n \\\n \\ Home Assistant *остановлен*, время работы: {{ states('sensor.online_custom')\\\n \\ }}\\n{% endif -%}\\n\"",
|
||
"config": [
|
||
{
|
||
"name": "home assistant core update",
|
||
"room": null,
|
||
"type": "update",
|
||
"id": {
|
||
"entity_id": "update.home_assistant_core_update",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "start time",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.start_time",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "errors in system log command line",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.errors_in_system_log_command_line",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "warnings in system log command line",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.warnings_in_system_log_command_line",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "online custom",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.online_custom",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notifications errors in automations or scripts",
|
||
"automation": "- alias: notifications errors in automations or scripts\n id: notifications errors in automations or scripts\n mode: queued\n triggers:\n - trigger: event\n event_type: system_log_event\n event_data:\n level: ERROR\n conditions:\n - condition: state\n entity_id: binary_sensor.local_network_availability\n state: 'on'\n - '{{ (trigger.event.data.name | string) is not search(this.entity_id | string,\n ignorecase=True) }}'\n - condition: template\n value_template: \"{{ \\n trigger.event.data.message | regex_search('Error while\\\n \\ executing automation') or\\n trigger.event.data.message | regex_search('Error\\\n \\ executing script')\\n}}\"\n - condition: template\n value_template: \"{{ \\n trigger.event.data.message | length < 4000\\n}}\"\n actions:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n parse_mode: html\n disable_web_page_preview: true\n title: '{{ ''⛔'' }} <b>Ошибка выполнения скрипта</b>'\n message: '{{ trigger.event.data.message | string | e -}} <a href=\"{{- states(''sensor.instance_external_url_config'')\n -}}/config/logs\"> Check logs.</a>\n\n '",
|
||
"config": [
|
||
{
|
||
"name": "local network availability",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.local_network_availability",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "instance external url config",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.instance_external_url_config",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notifications objects in unavailable status",
|
||
"automation": "- alias: notifications objects in unavailable status\n initial_state: true\n mode: queued\n max: 70\n trigger_variables:\n not_has_state: '{{ [''unknown'', ''unavailable''] }}'\n triggers:\n - trigger: event\n event_type: state_changed\n conditions:\n - condition: state\n entity_id: input_boolean.instances_stoping\n state: 'off'\n - '{{ trigger.event.data.new_state.state in not_has_state }}'\n - '{{ trigger.event.data.entity_id in expand(''group.important_devices_unavailable'')\n | map(attribute=''entity_id'') | list }}'\n - '{{ trigger.event.data.new_state.state = trigger.event.data.old_state.state }}'\n actions:\n - choose:\n - conditions: '{{ is_state(''input_boolean.instances_stoping'', ''off'') }}'\n sequence:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n disable_notification: true\n parse_mode: html\n title: ⚠️ <b>Трекинг устройств</b>\n message: '<i>{{ state_attr(trigger.event.data.entity_id, ''friendly_name'')\n }}</i> сменил статус на <b>{{ trigger.event.data.new_state.state }}</b>\n\n '",
|
||
"config": [
|
||
{
|
||
"name": "instances stoping",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.instances_stoping",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "important devices unavailable",
|
||
"room": null,
|
||
"type": "group",
|
||
"id": {
|
||
"entity_id": "group.important_devices_unavailable",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notifications on off water heater",
|
||
"automation": "- alias: notifications on off water heater\n id: notifications on off water heater\n mode: parallel\n initial_state: true\n trigger_variables:\n not_has_state: '{{ [''unknown'', ''unavailable'', ''none'', None, null, '''']\n }}'\n triggers:\n - trigger: state\n entity_id: sensor.0x842e14fffe13a854_power\n conditions:\n - condition: state\n entity_id: input_boolean.water_heater_season\n state: 'on'\n - condition: template\n value_template: \"{{ trigger.from_state.state not in not_has_state and\\n trigger.to_state.state\\\n \\ not in not_has_state and\\n trigger.to_state.state = trigger.from_state.state\\n\\\n }}\\n\"\n - condition: template\n value_template: \"{{ \\n (trigger.to_state.state | int(0) >= 850 and trigger.from_state.state\\\n \\ | int(0) <= 30)\\n or\\n (trigger.to_state.state | int(0) < 30 and trigger.from_state.state\\\n \\ | int(0) > 850)\\n}}\\n\"\n actions:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n disable_notification: true\n title: '{{ iif(trigger.to_state.state | int(0) >= 30, ''ℹ️'', ''\\U00002705'')\n }} *Водонагреватель*'\n message: '{{ iif(trigger.to_state.state | int(0) >= 30, ''*Включен*'', ''*Отключен*'')\n }} нагрев воды'",
|
||
"config": [
|
||
{
|
||
"name": "water heater season",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.water_heater_season",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "water heater socket power",
|
||
"room": "bathroom",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x842e14fffe13a854_power",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notifications stale google drive backup",
|
||
"automation": "- alias: notifications stale google drive backup\n id: notifications stale google drive backup\n max_exceeded: silent\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.backups_stale\n from: 'off'\n to: 'on'\n actions:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n disable_web_page_preview: true\n title: '{{ ''⛔'' }} *Резервное копирование БД*'\n message: 'Проблема с бекапом Google Drive, [логи]({{- states(''sensor.instance_external_url_config'')\n -}}/hassio/addon/cebe7a76_hassio_google_drive_backup/logs)\n\n '",
|
||
"config": [
|
||
{
|
||
"name": "instance external url config",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.instance_external_url_config",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "backups stale",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.backups_stale",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notifications entry discovery integrations",
|
||
"automation": "- alias: notifications entry discovery integration\n id: notifications entry discovery integrations\n mode: queued\n initial_state: true\n triggers:\n - trigger: event\n event_type: config_entry_discovered\n actions:\n - parallel:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n disable_notification: true\n title: '{{ ''📟'' }} *Устройства*'\n message: 'Найдено новое устройство в сети, [просмотреть]({{- states(''sensor.instance_external_url_config'')\n -}}/config/integrations)\n\n '",
|
||
"config": [
|
||
{
|
||
"name": "instance external url config",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.instance_external_url_config",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notifications entry discovery",
|
||
"automation": "- alias: notifications entry discovery\n id: notifications entry discovery\n mode: queued\n max: 99\n max_exceeded: silent\n initial_state: true\n triggers:\n - trigger: event\n event_type: entity_registry_updated\n - trigger: event\n id: device_registry\n event_type: device_registry_updated\n conditions:\n - condition: state\n entity_id: input_boolean.instances_stoping\n state: 'off'\n actions:\n - variables:\n name_for_send: \"{% if trigger.id == 'device_registry' -%}\\n {% if device_attr(trigger.event.data.device_id,\\\n \\ 'name_by_user') = none -%}\\n {{- device_attr(trigger.event.data.device_id,\\\n \\ 'name_by_user') -}}\\n {%- else -%}\\n {% set temp_name = device_attr(trigger.event.data.device_id,\\\n \\ 'name') %}\\n {{- iif(temp_name = none, temp_name, trigger.event.data.device_id,\\\n \\ trigger.event.data.device_id) -}}\\n {%- endif -%}\\n{%- else -%}\\n ''\\n\\\n {%- endif %}\"\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n disable_notification: true\n parse_mode: html\n title: '{{ ''📟'' }} <b>Устройства</b>'\n message: \"{% if trigger.id == 'device_registry' %}\\n <b>{{ trigger.event.data.action\\\n \\ | capitalize }}</b>: {{ name_for_send }}\\n{% else %}\\n <b>{{ trigger.event.data.action\\\n \\ | capitalize }}</b>: {{ trigger.event.data.old_entity_id + '->' if trigger.event.data.old_entity_id\\\n \\ is defined }}{{ trigger.event.data.entity_id if trigger.event.data.entity_id\\\n \\ is defined else 'NA' }}\\n{% endif %}\"",
|
||
"config": [
|
||
{
|
||
"name": "instances stoping",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.instances_stoping",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notifications automation already running",
|
||
"automation": "- alias: notifications automation already running\n id: notifications automation already running\n initial_state: true\n mode: queued\n triggers:\n - trigger: event\n event_type: system_log_event\n event_data:\n level: WARNING\n conditions:\n - condition: template\n value_template: '{{ \"Already running\" in (trigger.event.data.message | string)\n }}'\n actions:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n disable_notification: true\n parse_mode: html\n title: ⚠️ <b>Выполнение автоматизаций</b>\n message: 'Повторный запуск автоматизации: {{ trigger.event.data.message | string\n | e }}'",
|
||
"config": [
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "system log critical error notify",
|
||
"automation": "- alias: system log critical error notify\n id: system log critical error notify\n initial_state: true\n mode: queued\n triggers:\n - trigger: event\n event_type: system_log_event\n event_data:\n level: FATAL\n - trigger: event\n event_type: system_log_event\n event_data:\n level: CRITICAL\n actions:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n parse_mode: html\n disable_web_page_preview: true\n title: '{{ ''⛔'' }} <b>Ошибки системного журнала</b>'\n message: '{{ trigger.event.data.message | string | e -}} <a href=\"{{- states(''sensor.instance_external_url_config'')\n -}}/config/logs\"> Check logs.</a>\n\n '",
|
||
"config": [
|
||
{
|
||
"name": "instance external url config",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.instance_external_url_config",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notifications sms unread or full storage",
|
||
"automation": "- alias: notifications sms unread or full storage\n id: notifications sms unread or full storage\n initial_state: true\n max_exceeded: silent\n trigger_variables:\n not_has_state: '{{ [''unknown'', ''unavailable'', ''none'', None, null, '''']\n }}'\n triggers:\n - trigger: state\n entity_id: sensor.huawei_e3372h_320_sms_unread\n - trigger: state\n id: full_storage\n entity_id: binary_sensor.huawei_e3372h_320_sms_storage_full\n from: 'off'\n to: 'on'\n conditions:\n - condition: template\n value_template: \"{{ trigger.id == 'full_storage' or\\n trigger.to_state.state\\\n \\ not in not_has_state and\\n trigger.to_state.state | int(0) > trigger.from_state.state\\\n \\ | int(0)\\n}}\\n\"\n actions:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n disable_notification: true\n title: '{% if trigger.id == ''full_storage'' -%} {{ ''\\U0001F4EE'' }} {%- else\n -%} {{ ''\\U00002709'' }} {%- endif %} *SMS через модем*\n\n '\n message: 'Обнаружено {% if trigger.id == ''full_storage'' -%} заполнение памяти\n {%- else -%} *{{ trigger.to_state.state }}* {{ trigger.to_state.state | int(0)\n | format(morph=''непрочитанное'', as_text=false) | replace(trigger.to_state.state\n + '' '', '''') }} {%- endif %} sms на {{ device_attr(trigger.entity_id, ''name'')\n }}\n\n '",
|
||
"config": [
|
||
{
|
||
"name": "huawei e3372h 320 sms unread",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.huawei_e3372h_320_sms_unread",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "huawei e3372h 320 sms storage full",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.huawei_e3372h_320_sms_storage_full",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notifications link down keenetic",
|
||
"automation": "- alias: notifications link down keenetic\n id: notifications link down keenetic\n initial_state: true\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: binary_sensor.check_keenetic_link_down\n to: 'off'\n - trigger: state\n entity_id: binary_sensor.check_keenetic_link_down\n to: 'on'\n - trigger: homeassistant\n event: start\n - trigger: event\n event_type: event_template_reloaded\n conditions:\n - condition: numeric_state\n entity_id: counter.counter_keenetic_link_down\n above: 0\n actions:\n - parallel:\n - action: notify.huawei_lte\n data:\n message: '{{ ''\\U0000203C'' }} {{ states(''sensor.check_keenetic_link_down'')\n | as_timestamp | timestamp_custom(''%Y-%m-%d %H:%M'') }} Keenetic link is\n down'\n target: secret sms_phone_enzokot\n data:\n url: http://192.168.8.1/\n - action: counter.reset\n entity_id: counter.counter_keenetic_link_down",
|
||
"config": [
|
||
{
|
||
"name": "check keenetic link down",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.check_keenetic_link_down",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "counter keenetic link down",
|
||
"room": null,
|
||
"type": "counter",
|
||
"id": {
|
||
"entity_id": "counter.counter_keenetic_link_down",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "check keenetic link down binary",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.check_keenetic_link_down",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "SMS Phone Enzokot Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret sms_phone_enzokot",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notifications new rss posts",
|
||
"automation": "- alias: notifications new rss posts\n id: notifications new rss posts\n mode: queued\n triggers:\n - trigger: event\n event_type: feedreader\n conditions:\n - condition: state\n entity_id: input_boolean.instances_stoping\n state: 'off'\n actions:\n - variables:\n all_chat_id: secret telegram_all_chat_id\n enzokot_chat_id: secret telegram_enzokot_chat_id\n stormy_notification: '{{ trigger.event.data.feed_url is search(''shtormovye-i-ekstrennye-preduprezhdeniya'',\n ignorecase=True) }}'\n - action: telegram_bot.send_message\n data:\n target: \"{% if stormy_notification %}\\n {{ all_chat_id }}\\n{% else %}\\n \\\n \\ {{ enzokot_chat_id }}\\n{% endif %}\\n\"\n disable_notification: '{{ not stormy_notification }}'\n disable_web_page_preview: true\n parse_mode: html\n title: '{{ ''📰'' }} <b>RSS новости</b>'\n message: '<a href=\"{{- trigger.event.data.link -}}\">{{- trigger.event.data.title\n | e }} ({{ trigger.event.data.link | regex_findall(find=''^(?:\\w+://)?([^/?#]+)'',\n ignorecase=True) | join }})</a>\n\n '",
|
||
"config": [
|
||
{
|
||
"name": "instances stoping",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.instances_stoping",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram All Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_all_chat_id",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notifications warnings or errors in syslog",
|
||
"automation": "- alias: notifications warnings or errors in syslog\n id: notifications warnings or errors in syslog\n initial_state: true\n max_exceeded: silent\n triggers:\n - trigger: time_pattern\n hours: /1\n minutes: 30\n - trigger: numeric_state\n entity_id: counter.system_log_warning_counter\n above: 10\n - trigger: numeric_state\n entity_id: counter.system_log_error_counter\n above: 5\n conditions:\n - '{{ states(''counter.system_log_error_counter'') | int(0) > 0 or states(''counter.system_log_warning_counter'')\n | int(0) > 0 }}'\n - condition: time\n after: '8:30:00'\n before: '23:00:00'\n actions:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n disable_notification: true\n title: '{{ ''📖'' }} *Данные системного журнала*'\n message: \"{% if states('counter.system_log_error_counter') | int(0) > 0 -%}\\n\\\n \\ Ошибок в логе: *{{ states('counter.system_log_error_counter') }}*\\n{%\\\n \\ endif -%}\\n{% if states('counter.system_log_warning_counter') | int(0) >\\\n \\ 0 -%}\\n Предупреждений в логе: *{{ states('counter.system_log_warning_counter')\\\n \\ }}*\\n{% endif -%}\\n[Просмотр логов]({{- states('sensor.instance_external_url_config')\\\n \\ -}}/config/logs)\"",
|
||
"config": [
|
||
{
|
||
"name": "instance external url config",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.instance_external_url_config",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "system log error counter",
|
||
"room": null,
|
||
"type": "counter",
|
||
"id": {
|
||
"entity_id": "counter.system_log_error_counter",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "system log warning counter",
|
||
"room": null,
|
||
"type": "counter",
|
||
"id": {
|
||
"entity_id": "counter.system_log_warning_counter",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "telegram is offline for instance notification",
|
||
"automation": "- alias: telegram is offline for instance notification\n id: telegram is offline for instance notification\n initial_state: true\n triggers:\n - trigger: state\n entity_id:\n - sensor.telegram_status\n from: online\n to: offline\n for: 00:01:20\n actions:\n - choose:\n - conditions:\n - condition: time\n after: '8:00:00'\n before: '23:00:00'\n sequence:\n - action: notify.huawei_lte\n data:\n message: '{{ ''\\U0000203C'' }} Telegram API недоступно'\n target: secret sms_phone_enzokot\n data:\n url: http://192.168.8.1/\n default:\n - action: notify.email_enzokot_ha\n data:\n title: ⚠️ Трекинг устройств\n message: Telegram API недоступно",
|
||
"config": [
|
||
{
|
||
"name": "telegram status",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.telegram_status",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "SMS Phone Enzokot Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret sms_phone_enzokot",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "yandex station to or from local mode notification",
|
||
"automation": "- alias: yandex station to or from local mode notification\n id: yandex station to or from local mode notification\n mode: queued\n initial_state: true\n triggers:\n - trigger: state\n id: non_local\n entity_id:\n - binary_sensor.yandex_station_ff98f029b620413b35e5e278_assumed_state\n - binary_sensor.yandex_station_lr0000000000000252130000de5d13d0_assumed_state\n - binary_sensor.yandex_station_m00ka4300h99tr_assumed_state\n from: 'off'\n to: 'on'\n - trigger: state\n entity_id:\n - binary_sensor.yandex_station_ff98f029b620413b35e5e278_assumed_state\n - binary_sensor.yandex_station_lr0000000000000252130000de5d13d0_assumed_state\n - binary_sensor.yandex_station_m00ka4300h99tr_assumed_state\n from: 'on'\n to: 'off'\n actions:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n disable_notification: true\n parse_mode: html\n title: '{% if trigger.id == ''non_local'' %} ⚠️ {% else %} {{ ''\\U00002705''\n }} {% endif -%} <b>Трекинг устройств</b>\n\n '\n message: 'Станция <b>{{- trigger.to_state.name | e -}}</b> {% if trigger.id\n == ''non_local'' -%} отключила локальный режим управления {%- else -%} перешла\n в локальный режим управления {%- endif %}\n\n '",
|
||
"config": [
|
||
{
|
||
"name": "yandex station assumed state 1",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.yandex_station_ff98f029b620413b35e5e278_assumed_state",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "yandex station assumed state 2",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.yandex_station_lr0000000000000252130000de5d13d0_assumed_state",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "yandex station assumed state 3",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.yandex_station_m00ka4300h99tr_assumed_state",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "hot pipe low or up temperature notification",
|
||
"automation": "- alias: hot pipe low or up temperature notification\n id: hot pipe low or up temperature notification\n mode: queued\n initial_state: true\n triggers:\n - trigger: numeric_state\n id: below\n entity_id:\n - sensor.0x00158d0006c5f21e_temperature\n - sensor.0x158d0006b860cf_temperature\n - sensor.0x00158d0008386b56_temperature\n below: 40\n for:\n minutes: 5\n - trigger: numeric_state\n entity_id:\n - sensor.0x00158d0006c5f21e_temperature\n - sensor.0x158d0006b860cf_temperature\n - sensor.0x00158d0008386b56_temperature\n above: 40\n for:\n minutes: 5\n actions:\n - parallel:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_all_chat_id\n title: '{{ iif(trigger.id == ''below'', ''\\U0001F6B1'' , ''\\U0001F6B0'') }}\n *Горячее водоснабжение*'\n message: '{{ iif(trigger.id == ''below'', ''Остывает'' , ''Нагревается'')\n }} горячая труба *{{ area_name(trigger.entity_id) }}*.'\n - choose:\n - conditions: '{{ trigger.id == ''below'' and trigger.entity_id == ''sensor.0x00158d0006c5f21e_temperature''\n }}'\n sequence:\n - action: notify.huawei_lte\n data:\n message: '{{ ''\\U0000203C'' }} Остывает горячая труба {{ area_name(trigger.entity_id)\n }}.'\n target: secret sms_phone_enzokot\n data:\n url: http://192.168.8.1/",
|
||
"config": [
|
||
{
|
||
"name": "hot pipe temperature sensor 1",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x00158d0006c5f21e_temperature",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "hot pipe temperature sensor 2",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x158d0006b860cf_temperature",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "hot pipe temperature sensor 3",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x00158d0008386b56_temperature",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "SMS Phone Enzokot Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret sms_phone_enzokot",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram All Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_all_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "system down uptime kuma notifications",
|
||
"automation": "- alias: system down uptime kuma notifications\n id: system down uptime kuma notifications\n mode: queued\n triggers:\n - trigger: webhook\n webhook_id: secret webhook_id_system_down_uptime_kuma\n local_only: true\n allowed_methods:\n - POST\n conditions:\n - '{{ trigger.json.monitor is not none }}'\n actions:\n - variables:\n status_from: '{{ iif(trigger.json.heartbeat is not none and trigger.json.heartbeat.status\n | int(0) == 1, ''online'', ''offline'', ''offline'') }}'\n - parallel:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n parse_mode: html\n title: '{{ iif(status_from == ''online'', ''\\U00002705'', ''\\U000026d4'',\n ''\\U000026d4'') }} <b>Трекинг устройств</b>'\n message: '{{ trigger.json.monitor.name }} <b>{{ iif(status_from == ''online'',\n ''в'', ''не в'', ''не в'') }}</b> сети'\n - choose:\n - conditions: '{{ ''tsymbal'' in trigger.json.monitor.name | lower and is_state(''binary_sensor.internet_availability_ping'',\n ''on'') }}'\n sequence:\n - action: notify.huawei_lte\n data:\n message: '{{ iif(status_from == ''online'', ''\\U00002705'', ''\\U000026d4'',\n ''\\U000026d4'') }} Link from Enzokot is {{ iif(status_from == ''online'',\n ''up'', ''down'', ''down'') }}'\n target: secret sms_phone_to4ko\n data:\n url: http://192.168.8.1/",
|
||
"config": [
|
||
{
|
||
"name": "Internet Availability Ping",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.internet_availability_ping",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "SMS Phone To4ko Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret sms_phone_to4ko",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "gw2 alarm turn on off notification",
|
||
"automation": "- alias: gw2 alarm turn on off notification\n id: gw2 alarm turn on off notification\n initial_state: true\n triggers:\n - trigger: state\n entity_id: alarm_control_panel.signalka_shliuza_alarm\n not_from:\n - unknown\n - unavailable\n - ''\n to:\n - armed_away\n - disarmed\n actions:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n message: '{{ iif(is_state(''alarm_control_panel.signalka_shliuza_alarm'', ''disarmed''),\n ''🔇 Сигнализация *выключена*'', ''🔉 Сигнализация *включена*'') }}'",
|
||
"config": [
|
||
{
|
||
"name": "shliuza alarm control panel",
|
||
"room": null,
|
||
"type": "alarm_control_panel",
|
||
"id": {
|
||
"entity_id": "alarm_control_panel.signalka_shliuza_alarm",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "repairs issue registry",
|
||
"automation": "- alias: repairs issue registry\n id: repairs issue registry\n mode: queued\n triggers:\n - trigger: state\n entity_id: sensor.repairs_state\n not_from:\n - unknown\n - unavailable\n - trigger: homeassistant\n id: homeassistant_start\n event: start\n conditions:\n - '{{ trigger.id == ''homeassistant_start'' and states(''sensor.repairs_state'')\n | int(0) > 0 or trigger.id = ''homeassistant_start'' and trigger.from_state.state\n | int(0) < trigger.to_state.state | int(0) }}'\n actions:\n - if:\n - '{{ trigger.id == ''homeassistant_start'' }}'\n then:\n - delay: 2\n - condition: '{{ trigger.id == ''homeassistant_start'' and states(''sensor.repairs_state'')\n | int(0) > 0 or trigger.id = ''homeassistant_start'' and trigger.from_state.state\n | int(0) < trigger.to_state.state | int(0) }}'\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n parse_mode: html\n title: '{{ ''\\U0001F41B'' }} <b>Устранение проблем</b>'\n message: \"{%- set issues = state_attr('sensor.repairs_state', 'issues') -%}\\\n \\ {%- set datanames = namespace(issue=[]) -%} {% for issue in issues %}\\n\\\n \\ {% set datanames.issue = datanames.issue + ['Домен: <b>' + issue.domain\\\n \\ + ', </b>описание: <b>' + issue.issue_id + '</b>'] -%}\\n{% endfor %} Обнаружены\\\n \\ проблемы ({{- states('sensor.repairs_state') -}}шт):{{'\\\\n'-}} {{ datanames.issue\\\n \\ | join(', \\\\n') }}\"",
|
||
"config": [
|
||
{
|
||
"name": "repairs state",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.repairs_state",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "login ssh from servers",
|
||
"automation": "- alias: login ssh from servers\n id: login ssh from servers\n mode: queued\n triggers:\n - trigger: state\n entity_id: sensor.login_ssh_kotletochka_dell_srv\n not_from:\n - unknown\n - unavailable\n not_to:\n - unknown\n - unavailable\n actions:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n parse_mode: html\n title: '{{ ''\\U00002328'' }} <b>Вход по SSH</b>'\n message: '{{- state_attr(''sensor.login_ssh_kotletochka_dell_srv'', ''friendly_name'')\n -}}: <b>{{- as_timestamp(trigger.to_state.state) | timestamp_custom(''%d.%m.%Y\n %H:%M:%S'') -}}</b> Пользователь: <b>{{- trigger.to_state.attributes.user\n -}}</b>, адрес: <b>{{- trigger.to_state.attributes.address -}}</b>, tty: <b>{{-\n trigger.to_state.attributes.tty -}}</b>'",
|
||
"config": [
|
||
{
|
||
"name": "login ssh kotletochka dell srv",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.login_ssh_kotletochka_dell_srv",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "xiaomi mi scale new weight",
|
||
"automation": "- alias: xiaomi mi scale new weight\n id: xiaomi mi scale new weight\n mode: queued\n triggers:\n - trigger: state\n entity_id: sensor.esp_xiaomi_mi_scale_weight\n not_from:\n - unknown\n - unavailable\n not_to:\n - unknown\n - unavailable\n actions:\n - variables:\n first_name_father: secret first_name_father\n first_name_mother: secret first_name_mother\n first_name_daughter: secret first_name_daughter\n - action: telegram_bot.send_message\n data:\n target: secret telegram_all_chat_id\n disable_notification: true\n title: '{{ ''⚖'' }} *Взвешивание*'\n message: '*{%- if trigger.to_state.state | float(0.0) >= 90 %} {{- first_name_father\n -}} {% elif trigger.to_state.state | float(0.0) >= 40 %} {{- first_name_mother\n -}} {% else %} {{- first_name_daughter -}} {% endif -%}* весит `{{- trigger.to_state.state\n -}}` {{ trigger.to_state.attributes.unit_of_measurement -}}'",
|
||
"config": [
|
||
{
|
||
"name": "xiaomi mi scale weight",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.esp_xiaomi_mi_scale_weight",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram All Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_all_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "host kernel ext4 warning",
|
||
"automation": "- alias: host kernel ext4 warning\n id: host kernel ext4 warning\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: binary_sensor.kernel_ext4_warning\n from: 'off'\n to: 'on'\n - trigger: time\n at: '10:30:00'\n conditions:\n - condition: state\n entity_id: binary_sensor.kernel_ext4_warning\n state: 'on'\n actions:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n disable_notification: true\n title: ⚠️ *Host Kernel log*\n message: '{{ state_attr(''binary_sensor.kernel_ext4_warning'', ''friendly_name'')\n }}'",
|
||
"config": [
|
||
{
|
||
"name": "kernel ext4 warning",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.kernel_ext4_warning",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notification wet entrance floor",
|
||
"automation": "- alias: notification wet entrance floor\n id: notification wet entrance floor\n initial_state: true\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: binary_sensor.0x00158d000913dbf1_contact\n from: 'off'\n to: 'on'\n for:\n seconds: 5\n conditions:\n - condition: time\n after: 06:00:00\n before: '16:00:00'\n weekday:\n - mon\n - '{{ now() - state_attr(this.entity_id, ''last_triggered'') > timedelta(hours =\n 1) }}'\n actions:\n - parallel:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n title: '{{ ''🧹'' }} *Влажная уборка*'\n message: Обнаружена уборка в общем коридоре\n - action: notify.huawei_lte\n data:\n message: Обнаружена уборка в общем коридоре\n target: secret sms_phone_users56_59\n data:\n url: http://192.168.8.1/",
|
||
"config": [
|
||
{
|
||
"name": "entrance floor wet sensor",
|
||
"room": "entrance",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x00158d000913dbf1_contact",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "SMS Phone Users 56 59 Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret sms_phone_users56_59",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notification water leak near nvr",
|
||
"automation": "- alias: notification water leak near nvr\n id: notification water leak near nvr\n initial_state: true\n mode: queued\n triggers:\n - trigger: state\n entity_id:\n - binary_sensor.0x00158d0009ea0949_water_leak\n - binary_sensor.0x00158d0009ea1c0e_water_leak\n to: 'on'\n for:\n seconds: 10\n actions:\n - parallel:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n title: '{{ ''💧'' }} *Датчики протечки*'\n message: 'Обнаружена протечка возле NVR/Камер: *{{ state_attr(trigger.entity_id,\n ''friendly_name'') }}*'\n - action: notify.huawei_lte\n data:\n message: 'Обнаружена протечка возле NVR/Камер: {{ state_attr(trigger.entity_id,\n ''friendly_name'') }}'\n target: secret sms_phone_users59_60\n data:\n url: http://192.168.8.1/\n - sequence:\n - variables:\n sm_g973f_rezhim_ne_bespokoit: '{{ states(''sensor.sm_g973f_do_not_disturb_sensor'')\n }}'\n - choose:\n - conditions: '{{ sm_g973f_rezhim_ne_bespokoit = ''off'' }}'\n sequence:\n - action: notify.mobile_app_sm_g973f\n data:\n message: command_dnd\n data:\n command: 'off'\n - wait_for_trigger:\n - trigger: state\n entity_id: sensor.sm_g973f_do_not_disturb_sensor\n timeout:\n seconds: 5\n - variables:\n sm_g973f_rezhim_zvonka: '{{ states(''sensor.sm_g973f_ringer_mode'') }}'\n - choose:\n - conditions: '{{ sm_g973f_rezhim_zvonka = ''normal'' }}'\n sequence:\n - action: notify.notify\n data:\n message: command_ringer_mode\n data:\n command: normal\n - action: notify.notify\n data:\n title: '{{ ''💧'' }} Датчики протечки'\n message: 'Обнаружена протечка возле NVR: {{ state_attr(trigger.entity_id,\n ''friendly_name'') }}'\n data:\n ttl: 0\n priority: high\n channel: alarm_stream\n - choose:\n - conditions: '{{ sm_g973f_rezhim_zvonka = ''normal'' }}'\n sequence:\n - action: notify.mobile_app_sm_g973f\n data:\n message: command_ringer_mode\n data:\n command: '{{ sm_g973f_rezhim_zvonka }}'\n - choose:\n - conditions: '{{ sm_g973f_rezhim_ne_bespokoit = ''off'' }}'\n sequence:\n - action: notify.mobile_app_sm_g973f\n data:\n message: command_dnd\n data:\n command: '{{ sm_g973f_rezhim_ne_bespokoit }}'",
|
||
"config": [
|
||
{
|
||
"name": "do not disturb sensor",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.sm_g973f_do_not_disturb_sensor",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "ringer mode",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.sm_g973f_ringer_mode",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "nvr water leak sensor 1",
|
||
"room": "nvr_box",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x00158d0009ea0949_water_leak",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "nvr water leak sensor 2",
|
||
"room": "nvr_box",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x00158d0009ea1c0e_water_leak",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "SMS Phone Users 59 60 Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret sms_phone_users59_60",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notification open door nvr box",
|
||
"automation": "- alias: notification open door nvr box\n id: notification open door nvr box\n initial_state: true\n mode: queued\n triggers:\n - trigger: state\n entity_id: binary_sensor.0x00158d00093e4111_contact\n from: 'off'\n to: 'on'\n for:\n seconds: 5\n actions:\n - parallel:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n title: '{{ ''🔑'' }} *Датчик открытия/закрытия*'\n message: Обнаружено *открытие* дверцы шкафа с NVR\n - action: notify.huawei_lte\n data:\n message: Обнаружено открытие дверцы шкафа с NVR\n target: secret sms_phone_enzokot\n data:\n url: http://192.168.8.1/\n - sequence:\n - variables:\n sm_g973f_rezhim_ne_bespokoit: '{{ states(''sensor.sm_g973f_do_not_disturb_sensor'')\n }}'\n - choose:\n - conditions: '{{ sm_g973f_rezhim_ne_bespokoit = ''off'' }}'\n sequence:\n - action: notify.mobile_app_sm_g973f\n data:\n message: command_dnd\n data:\n command: 'off'\n - wait_for_trigger:\n - trigger: state\n entity_id: sensor.sm_g973f_do_not_disturb_sensor\n timeout:\n seconds: 5\n - variables:\n sm_g973f_rezhim_zvonka: '{{ states(''sensor.sm_g973f_ringer_mode'') }}'\n - choose:\n - conditions: '{{ sm_g973f_rezhim_zvonka = ''normal'' }}'\n sequence:\n - action: notify.notify\n data:\n message: command_ringer_mode\n data:\n command: normal\n - action: notify.notify\n data:\n title: '{{ ''🔑'' }} Датчик открытия/закрытия'\n message: Обнаружено открытие дверцы шкафа с NVR\n data:\n ttl: 0\n priority: high\n channel: alarm_stream\n - choose:\n - conditions: '{{ sm_g973f_rezhim_zvonka = ''normal'' }}'\n sequence:\n - action: notify.mobile_app_sm_g973f\n data:\n message: command_ringer_mode\n data:\n command: '{{ sm_g973f_rezhim_zvonka }}'\n - choose:\n - conditions: '{{ sm_g973f_rezhim_ne_bespokoit = ''off'' }}'\n sequence:\n - action: notify.mobile_app_sm_g973f\n data:\n message: command_dnd\n data:\n command: '{{ sm_g973f_rezhim_ne_bespokoit }}'",
|
||
"config": [
|
||
{
|
||
"name": "do not disturb sensor",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.sm_g973f_do_not_disturb_sensor",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "ringer mode",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.sm_g973f_ringer_mode",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "nvr box door sensor",
|
||
"room": "nvr_box",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x00158d00093e4111_contact",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "SMS Phone Enzokot Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret sms_phone_enzokot",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notification overheating 1pm fan nvr box",
|
||
"automation": "- alias: notification overheating 1pm fan nvr box\n id: notification overheating 1pm fan nvr box\n initial_state: true\n mode: queued\n triggers:\n - trigger: state\n id: overheating\n entity_id: binary_sensor.shelly_1pm_fan_nvr_box_overheating\n from: 'off'\n to: 'on'\n for:\n seconds: 5\n - trigger: numeric_state\n entity_id: sensor.shelly_1pm_fan_nvr_box_temperature\n above: 35\n for:\n seconds: 5\n actions:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n title: '{{ ''🌡'' }} *Реле кулера шкафа NVR*'\n message: \"{{ \\n iif(trigger.id == 'overheating', \\n 'Обнаружен *перегрев*\\\n \\ реле кулера шкафа NVR (*T=' + states('sensor.shelly_1pm_fan_nvr_box_device_temperature',\\\n \\ true, true) + '*)', \\n 'Обнаружена высокая (*' + trigger.to_state.state\\\n \\ + '*) температура в шкафу NVR')\\n}}\"",
|
||
"config": [
|
||
{
|
||
"name": "shelly 1pm fan nvr box overheating",
|
||
"room": "nvr_box",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.shelly_1pm_fan_nvr_box_overheating",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "shelly 1pm fan nvr box temperature",
|
||
"room": "nvr_box",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.shelly_1pm_fan_nvr_box_temperature",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "shelly 1pm fan nvr box device temperature",
|
||
"room": "nvr_box",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.shelly_1pm_fan_nvr_box_device_temperature",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notification nvr in unavailable status",
|
||
"automation": "- alias: notification nvr in unavailable status\n id: notification nvr in unavailable status\n initial_state: true\n mode: queued\n triggers:\n - trigger: state\n entity_id: button.kotletochka_nvr_hw_restart\n to: null\n for:\n seconds: 10\n conditions:\n - condition: state\n entity_id: input_boolean.instances_stoping\n state: 'off'\n - condition: numeric_state\n entity_id: sensor.shelly_plug_s_nvr_power\n below: 15\n actions:\n - parallel:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n title: '{{ ''📼'' }} *Состояние NVR*'\n message: Обнаружено *отключение* NVR\n - action: notify.huawei_lte\n data:\n message: Обнаружено отключение NVR\n target: secret sms_phone_enzokot\n data:\n url: http://192.168.8.1/\n - sequence:\n - variables:\n sm_g973f_rezhim_ne_bespokoit: '{{ states(''sensor.sm_g973f_do_not_disturb_sensor'')\n }}'\n - choose:\n - conditions: '{{ sm_g973f_rezhim_ne_bespokoit = ''off'' }}'\n sequence:\n - action: notify.mobile_app_sm_g973f\n data:\n message: command_dnd\n data:\n command: 'off'\n - wait_for_trigger:\n - trigger: state\n entity_id: sensor.sm_g973f_do_not_disturb_sensor\n timeout:\n seconds: 5\n - variables:\n sm_g973f_rezhim_zvonka: '{{ states(''sensor.sm_g973f_ringer_mode'') }}'\n - choose:\n - conditions: '{{ sm_g973f_rezhim_zvonka = ''normal'' }}'\n sequence:\n - action: notify.notify\n data:\n message: command_ringer_mode\n data:\n command: normal\n - action: notify.notify\n data:\n title: '{{ ''📼'' }} Состояние NVR'\n message: Обнаружено отключение NVR\n data:\n ttl: 0\n priority: high\n channel: alarm_stream\n - choose:\n - conditions: '{{ sm_g973f_rezhim_zvonka = ''normal'' }}'\n sequence:\n - action: notify.mobile_app_sm_g973f\n data:\n message: command_ringer_mode\n data:\n command: '{{ sm_g973f_rezhim_zvonka }}'\n - choose:\n - conditions: '{{ sm_g973f_rezhim_ne_bespokoit = ''off'' }}'\n sequence:\n - action: notify.mobile_app_sm_g973f\n data:\n message: command_dnd\n data:\n command: '{{ sm_g973f_rezhim_ne_bespokoit }}'",
|
||
"config": [
|
||
{
|
||
"name": "do not disturb sensor",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.sm_g973f_do_not_disturb_sensor",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "ringer mode",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.sm_g973f_ringer_mode",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "instances stoping",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.instances_stoping",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "shelly plug s nvr power",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.shelly_plug_s_nvr_power",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "kotletochka nvr hw restart button",
|
||
"room": null,
|
||
"type": "button",
|
||
"id": {
|
||
"entity_id": "button.kotletochka_nvr_hw_restart",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "SMS Phone Enzokot Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret sms_phone_enzokot",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notification full battery level sm g973f",
|
||
"automation": "- alias: notification full battery level sm g973f\n id: notification full battery level sm g973f\n initial_state: true\n max_exceeded: silent\n triggers:\n - trigger: numeric_state\n entity_id: sensor.sm_g973f_battery_level\n above: 99\n conditions:\n - condition: state\n entity_id: binary_sensor.sm_g973f_is_charging\n state: 'on'\n actions:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n title: '{{ ''🔋'' }} *Состояние телефона*'\n message: Телефон полностью заряжен",
|
||
"config": [
|
||
{
|
||
"name": "sm g973f battery level",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.sm_g973f_battery_level",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "sm g973f is charging",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.sm_g973f_is_charging",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notification tapo c100 cr or hw disconnected",
|
||
"automation": "- alias: notification tapo c100 cr or hw disconnected\n id: notification tapo c100 cr or hw disconnected\n initial_state: true\n mode: parallel\n triggers:\n - trigger: webhook\n id: cr\n webhook_id: secret webhook_id_cctv_cr_off\n local_only: true\n allowed_methods:\n - PUT\n - trigger: webhook\n webhook_id: secret webhook_id_cctv_hw_off\n local_only: true\n allowed_methods:\n - PUT\n actions:\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n title: ⚠️ *Трекинг устройств*\n message: Камера в *{{- iif(trigger.id == 'cr', 'детской', 'коридоре') -}}* отключена",
|
||
"config": [
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "notification forward message from download station to telegram",
|
||
"automation": "- alias: notification forward message from download station to telegram\n id: notification forward message from download station to telegram\n initial_state: true\n mode: parallel\n triggers:\n - trigger: event\n event_type: imap_content\n event_data:\n initial: true\n actions:\n - parallel:\n - action: imap.seen\n data:\n entry: '{{ trigger.event.data[''entry_id''] }}'\n uid: '{{ trigger.event.data[''uid''] }}'\n - sequence:\n - action: imap.fetch\n data:\n entry: '{{ trigger.event.data[''entry_id''] }}'\n uid: '{{ trigger.event.data[''uid''] }}'\n response_variable: message_text\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n title: '{{ ''📂'' }} *Download station*'\n message: '{{ message_text[''text''] }}'\n disable_web_page_preview: true",
|
||
"config": [
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "turn off nvr from water leak",
|
||
"automation": "- alias: turn off nvr from water leak\n id: turn off nvr from water leak\n initial_state: true\n triggers:\n - trigger: state\n entity_id:\n - binary_sensor.0x00158d0009ea0949_water_leak\n - binary_sensor.0x00158d0009ea1c0e_water_leak\n to: 'on'\n for:\n seconds: 7\n actions:\n - parallel:\n - action: switch.turn_off\n target:\n entity_id: switch.shelly_plug_s_nvr\n - if:\n - '{{ trigger.entity_id == ''binary_sensor.0x00158d0009ea0949_water_leak'' }}'\n - condition: state\n entity_id: switch.shelly_1pm_fan_nvr_box\n state: 'on'\n then:\n - action: switch.turn_off\n target:\n entity_id: switch.shelly_1pm_fan_nvr_box",
|
||
"config": [
|
||
{
|
||
"name": "shelly plug s nvr",
|
||
"room": null,
|
||
"type": "switch",
|
||
"id": {
|
||
"entity_id": "switch.shelly_plug_s_nvr",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "shelly 1pm fan nvr box",
|
||
"room": null,
|
||
"type": "switch",
|
||
"id": {
|
||
"entity_id": "switch.shelly_1pm_fan_nvr_box",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "nvr water leak sensor 1",
|
||
"room": "nvr_box",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x00158d0009ea0949_water_leak",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "nvr water leak sensor 2",
|
||
"room": "nvr_box",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x00158d0009ea1c0e_water_leak",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "turn on fan nvr box every hour or above temperature",
|
||
"automation": "- alias: turn on fan nvr box every hour or above temperature\n id: turn on fan nvr box every hour or above temperature\n initial_state: true\n mode: queued\n triggers:\n - trigger: time_pattern\n hours: /1\n minutes: 0\n id: time_trigger\n - trigger: numeric_state\n entity_id:\n - sensor.shelly_1pm_fan_nvr_box_temperature\n above: 34.5\n conditions:\n - condition: state\n entity_id:\n - switch.shelly_1pm_fan_nvr_box\n - binary_sensor.0x00158d00093e4111_contact\n state: 'off'\n - '{{ is_state(''binary_sensor.0x00158d0009ea1c0e_water_leak'', ''off'') or not\n has_value(''binary_sensor.0x00158d0009ea1c0e_water_leak'') }}'\n - '{{ is_state(''binary_sensor.0x00158d0009ea0949_water_leak'', ''off'') or not\n has_value(''binary_sensor.0x00158d0009ea0949_water_leak'') }}'\n - \"{% set time_now = now() %} {{ \\n (today_at('9:00') <= time_now < today_at('21:00:00')\\\n \\ or states('sensor.shelly_1pm_fan_nvr_box_temperature') | float(0.0) > 34.5)\\n\\\n \\ or trigger.id != 'time_trigger' and (time_now >= today_at('21:00:00') or\\\n \\ time_now < today_at('9:00:00')) \\n}}\\n\"\n actions:\n - action: switch.turn_on\n target:\n entity_id: switch.shelly_1pm_fan_nvr_box",
|
||
"config": [
|
||
{
|
||
"name": "shelly 1pm fan nvr box",
|
||
"room": null,
|
||
"type": "switch",
|
||
"id": {
|
||
"entity_id": "switch.shelly_1pm_fan_nvr_box",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "nvr water leak sensor 1",
|
||
"room": "nvr_box",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x00158d0009ea0949_water_leak",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "nvr water leak sensor 2",
|
||
"room": "nvr_box",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x00158d0009ea1c0e_water_leak",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "nvr box door sensor",
|
||
"room": "nvr_box",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x00158d00093e4111_contact",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "shelly 1pm fan nvr box temperature",
|
||
"room": "nvr_box",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.shelly_1pm_fan_nvr_box_temperature",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "turn off fan nvr box when door is open",
|
||
"automation": "- alias: turn off fan nvr box when door is open\n id: turn off fan nvr box when door is open\n initial_state: true\n mode: queued\n triggers:\n - trigger: state\n entity_id: binary_sensor.0x00158d00093e4111_contact\n from: 'off'\n to: 'on'\n for:\n seconds: 3\n conditions:\n - condition: state\n entity_id: switch.shelly_1pm_fan_nvr_box\n state: 'on'\n actions:\n - action: switch.turn_off\n target:\n entity_id: switch.shelly_1pm_fan_nvr_box",
|
||
"config": [
|
||
{
|
||
"name": "shelly 1pm fan nvr box",
|
||
"room": null,
|
||
"type": "switch",
|
||
"id": {
|
||
"entity_id": "switch.shelly_1pm_fan_nvr_box",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "nvr box door sensor",
|
||
"room": "nvr_box",
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x00158d00093e4111_contact",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "night off water heater",
|
||
"automation": "- alias: night on off water heater\n id: night off water heater\n initial_state: true\n triggers:\n - trigger: time\n at: '22:30:00'\n - trigger: time\n at: 06:15:00\n conditions:\n - condition: state\n entity_id: input_boolean.water_heater_season\n state: 'on'\n actions:\n - action: \"{% if trigger.now.hour == 22 %}\\n switch.turn_off\\n{% else %}\\n \\\n \\ switch.turn_on\\n{% endif %}\\n\"\n target:\n entity_id: switch.0x842e14fffe13a854",
|
||
"config": [
|
||
{
|
||
"name": "water heater season",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.water_heater_season",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "water heater socket",
|
||
"room": "bathroom",
|
||
"type": "switch",
|
||
"id": {
|
||
"entity_id": "switch.0x842e14fffe13a854",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "night mode on heater",
|
||
"automation": "- alias: night mode on heater\n id: night mode on heater\n initial_state: true\n triggers:\n - trigger: time\n at: '22:00:00'\n conditions:\n - condition: state\n entity_id: input_boolean.heater_night_mode\n state: 'on'\n actions:\n - action: switch.turn_on\n target:\n entity_id: switch.0x842e14fffe5047f5\n - action: timer.start\n target:\n entity_id: timer.turn_off_heater_night_mode",
|
||
"config": [
|
||
{
|
||
"name": "heater night mode",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.heater_night_mode",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "heater socket",
|
||
"room": "childrens_room",
|
||
"type": "switch",
|
||
"id": {
|
||
"entity_id": "switch.0x842e14fffe5047f5",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "turn off heater night mode timer",
|
||
"room": null,
|
||
"type": "timer",
|
||
"id": {
|
||
"entity_id": "timer.turn_off_heater_night_mode",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "night mode off heater",
|
||
"automation": "- alias: night mode off heater\n id: night mode off heater\n initial_state: true\n triggers:\n - trigger: time\n at: 07:00:00\n conditions:\n - condition: state\n entity_id: input_boolean.heater_night_mode\n state: 'on'\n actions:\n - action: timer.cancel\n target:\n entity_id: timer.turn_on_heater_night_mode\n - action: timer.cancel\n target:\n entity_id: timer.turn_off_heater_night_mode\n - action: switch.turn_off\n target:\n entity_id: switch.0x842e14fffe5047f5",
|
||
"config": [
|
||
{
|
||
"name": "heater night mode",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.heater_night_mode",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "heater socket",
|
||
"room": "childrens_room",
|
||
"type": "switch",
|
||
"id": {
|
||
"entity_id": "switch.0x842e14fffe5047f5",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "turn off heater night mode timer",
|
||
"room": null,
|
||
"type": "timer",
|
||
"id": {
|
||
"entity_id": "timer.turn_off_heater_night_mode",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "turn on heater night mode timer",
|
||
"room": null,
|
||
"type": "timer",
|
||
"id": {
|
||
"entity_id": "timer.turn_on_heater_night_mode",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "night mode timer heater off",
|
||
"automation": "- alias: night mode timer heater off\n id: night mode timer heater off\n initial_state: true\n triggers:\n - trigger: event\n event_type: timer.finished\n event_data:\n entity_id: timer.turn_off_heater_night_mode\n conditions:\n - condition: state\n entity_id: input_boolean.heater_night_mode\n state: 'on'\n - condition: time\n after: '22:00:00'\n before: 07:00:00\n actions:\n - action: switch.turn_off\n target:\n entity_id: switch.0x842e14fffe5047f5\n - action: timer.start\n target:\n entity_id: timer.turn_on_heater_night_mode",
|
||
"config": [
|
||
{
|
||
"name": "heater night mode",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.heater_night_mode",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "heater socket",
|
||
"room": "childrens_room",
|
||
"type": "switch",
|
||
"id": {
|
||
"entity_id": "switch.0x842e14fffe5047f5",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "turn off heater night mode timer",
|
||
"room": null,
|
||
"type": "timer",
|
||
"id": {
|
||
"entity_id": "timer.turn_off_heater_night_mode",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "turn on heater night mode timer",
|
||
"room": null,
|
||
"type": "timer",
|
||
"id": {
|
||
"entity_id": "timer.turn_on_heater_night_mode",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "night mode timer heater on",
|
||
"automation": "- alias: night mode timer heater on\n id: night mode timer heater on\n initial_state: true\n triggers:\n - trigger: event\n event_type: timer.finished\n event_data:\n entity_id: timer.turn_on_heater_night_mode\n conditions:\n - condition: state\n entity_id: input_boolean.heater_night_mode\n state: 'on'\n - condition: time\n after: '22:00:00'\n before: 07:00:00\n actions:\n - action: switch.turn_on\n target:\n entity_id: switch.0x842e14fffe5047f5\n - action: timer.start\n target:\n entity_id: timer.turn_off_heater_night_mode",
|
||
"config": [
|
||
{
|
||
"name": "heater night mode",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.heater_night_mode",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "heater socket",
|
||
"room": "childrens_room",
|
||
"type": "switch",
|
||
"id": {
|
||
"entity_id": "switch.0x842e14fffe5047f5",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "turn off heater night mode timer",
|
||
"room": null,
|
||
"type": "timer",
|
||
"id": {
|
||
"entity_id": "timer.turn_off_heater_night_mode",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "turn on heater night mode timer",
|
||
"room": null,
|
||
"type": "timer",
|
||
"id": {
|
||
"entity_id": "timer.turn_on_heater_night_mode",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "on off night mode heater at action time",
|
||
"automation": "- alias: on off night mode heater at action time\n id: on off night mode heater at action time\n initial_state: true\n triggers:\n - trigger: state\n entity_id: input_boolean.heater_night_mode\n conditions:\n - condition: time\n after: '22:00:00'\n before: 07:00:00\n actions:\n - choose:\n - conditions:\n - condition: state\n entity_id: input_boolean.heater_night_mode\n state: 'off'\n sequence:\n - action: automation.trigger\n target:\n entity_id: automation.night_mode_off_heater\n - conditions:\n - condition: state\n entity_id: input_boolean.heater_night_mode\n state: 'on'\n sequence:\n - action: automation.trigger\n target:\n entity_id: automation.night_mode_on_heater",
|
||
"config": [
|
||
{
|
||
"name": "heater night mode",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.heater_night_mode",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "night mode off heater automation",
|
||
"room": null,
|
||
"type": "automation",
|
||
"id": {
|
||
"entity_id": "automation.night_mode_off_heater",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "night mode on heater automation",
|
||
"room": null,
|
||
"type": "automation",
|
||
"id": {
|
||
"entity_id": "automation.night_mode_on_heater",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "safety power socets off",
|
||
"automation": "- alias: safety power socets off\n id: safety power socets off\n initial_state: true\n triggers:\n - trigger: numeric_state\n entity_id:\n - sensor.0x842e14fffe5047f5_power\n - sensor.0x842e14fffe13a854_power\n - sensor.0x842e14fffe36661f_power\n - sensor.0x588e81fffeff5c4f_power\n - sensor.shelly_plug_s_1_power\n - sensor.0x60a423fffef8d41a_power\n - sensor.shelly_plug_s_2_power\n - sensor.shelly_plug_s_nvr_power\n - sensor.shelly_1pm_fan_nvr_box_power\n - sensor.shelly_plug_s_keenetic_hw_power\n - sensor.shelly_plug_s_htr_shelly_heated_tr_power\n above: 3000\n actions:\n - action: switch.turn_off\n target:\n entity_id: '{{ trigger.entity_id | replace(''sensor'', ''switch'') | replace(''_power'',\n '''') }}'",
|
||
"config": [
|
||
{
|
||
"name": "water heater socket power",
|
||
"room": "bathroom",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x842e14fffe13a854_power",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "heater socket power",
|
||
"room": "childrens_room",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x842e14fffe5047f5_power",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "kitchen socket1 power",
|
||
"room": "kitchen",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x842e14fffe36661f_power",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "bedroom socket1 power",
|
||
"room": "bedroom",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x588e81fffeff5c4f_power",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "server ac power",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.shelly_plug_s_1_power",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "shelly plug s 2 power",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.shelly_plug_s_2_power",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "shelly plug s nvr power",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.shelly_plug_s_nvr_power",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "shelly 1pm fan nvr box power",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.shelly_1pm_fan_nvr_box_power",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "shelly plug s keenetic hw power",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.shelly_plug_s_keenetic_hw_power",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "shelly plug s htr power",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.shelly_plug_s_htr_shelly_heated_tr_power",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Bedroom Socket 2 Power",
|
||
"room": "Bedroom",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x60a423fffef8d41a_power",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "restart night mode heater after reboot",
|
||
"automation": "- alias: restart night mode heater after reboot\n id: restart night mode heater after reboot\n initial_state: true\n triggers:\n - trigger: homeassistant\n event: start\n conditions:\n - condition: state\n entity_id: input_boolean.heater_night_mode\n state: 'on'\n - condition: time\n after: '22:00:00'\n before: 07:00:00\n actions:\n - choose:\n - conditions:\n - condition: state\n entity_id: switch.0x842e14fffe5047f5\n state: 'off'\n sequence:\n - action: automation.trigger\n target:\n entity_id: automation.night_mode_timer_heater_on\n - conditions:\n - condition: state\n entity_id: switch.0x842e14fffe5047f5\n state: 'on'\n sequence:\n - action: automation.trigger\n target:\n entity_id: automation.night_mode_timer_heater_off",
|
||
"config": [
|
||
{
|
||
"name": "heater night mode",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.heater_night_mode",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "heater socket",
|
||
"room": "childrens_room",
|
||
"type": "switch",
|
||
"id": {
|
||
"entity_id": "switch.0x842e14fffe5047f5",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "night mode timer heater off automation",
|
||
"room": null,
|
||
"type": "automation",
|
||
"id": {
|
||
"entity_id": "automation.night_mode_timer_heater_off",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "night mode timer heater on automation",
|
||
"room": null,
|
||
"type": "automation",
|
||
"id": {
|
||
"entity_id": "automation.night_mode_timer_heater_on",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "restart z2m or instance for energy",
|
||
"automation": "- alias: restart z2m or instance for energy\n id: restart z2m or instance for energy\n initial_state: true\n mode: parallel\n max: 100\n trigger_variables:\n not_has_state: '{{ [''unknown'', ''unavailable'', ''none''] }}'\n entity_dict: \"{{\\n {\\\"sensor.0x842e14fffe5047f5_energy\\\": \\\"input_number.total_heater_socket_saved\\\"\\\n ,\\n \\\"sensor.0x842e14fffe13a854_energy\\\": \\\"input_number.total_water_heater_socket_saved\\\"\\\n ,\\n \\\"sensor.0x842e14fffe36661f_energy\\\": \\\"input_number.total_kitchen_socket1_saved\\\"\\\n ,\\n \\\"sensor.0x588e81fffeff5c4f_energy\\\": \\\"input_number.total_bedroom_socket1_saved\\\"\\\n ,\\n \\\"sensor.0x60a423fffef8d41a_energy\\\": \\\"input_number.total_bedroom_socket2_saved\\\"\\\n ,\\n \\\"sensor.0x54ef441000096cbc_energy\\\": \\\"input_number.total_yeelight_ceiling_relay_saved\\\"\\\n ,\\n \\\"sensor.shelly_em_energy\\\": \\\"input_number.total_shelly_em_saved\\\"\\\n ,\\n \\\"sensor.shelly_plug_s_1_energy\\\": \\\"input_number.total_server_ac_saved\\\"\\\n ,\\n \\\"sensor.shelly_plug_s_2_energy\\\": \\\"input_number.total_shelly_plug_s_2_saved\\\"\\\n ,\\n \\\"sensor.0x54ef441000691265_energy\\\": \\\"input_number.total_kitchen_light_switch_working_area_saved\\\"\\\n ,\\n \\\"sensor.shelly_1pm_fan_nvr_box_energy\\\": \\\"input_number.total_shelly_1pm_fan_nvr_box_saved\\\"\\\n ,\\n \\\"sensor.shelly_plug_s_keenetic_hw_energy\\\": \\\"input_number.total_shelly_plug_s_keenetic_hw_saved\\\"\\\n ,\\n \\\"sensor.shelly_plug_s_nvr_energy\\\": \\\"input_number.total_shelly_plug_s_nvr_saved\\\"\\\n ,\\n \\\"sensor.shelly_plug_s_htr_shelly_heated_tr_energy\\\": \\\"input_number.total_shelly_plug_s_htr_saved\\\"\\\n }\\n}}\"\n triggers:\n - trigger: state\n entity_id:\n - sensor.0x842e14fffe5047f5_energy\n - sensor.0x842e14fffe13a854_energy\n - sensor.0x842e14fffe36661f_energy\n - sensor.0x588e81fffeff5c4f_energy\n - sensor.0x60a423fffef8d41a_energy\n - sensor.0x54ef441000096cbc_energy\n - sensor.shelly_em_energy\n - sensor.shelly_plug_s_1_energy\n - sensor.shelly_plug_s_2_energy\n - sensor.0x54ef441000691265_energy\n - sensor.shelly_plug_s_nvr_energy\n - sensor.shelly_1pm_fan_nvr_box_energy\n - sensor.shelly_plug_s_keenetic_hw_energy\n - sensor.shelly_plug_s_htr_shelly_heated_tr_energy\n conditions:\n - condition: template\n value_template: \"{{ trigger.to_state.state not in not_has_state and\\n trigger.from_state.state\\\n \\ not in not_has_state and\\n trigger.to_state.state != trigger.from_state.state\\n\\\n }}\"\n actions:\n - variables:\n entity_id: '{{ entity_dict[trigger.entity_id] }}'\n - action: input_number.set_value\n target:\n entity_id: '{{ entity_id }}'\n data:\n value: '{{ trigger.to_state.state }}'",
|
||
"config": [
|
||
{
|
||
"name": "heater socket energy",
|
||
"room": "childrens_room",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x842e14fffe5047f5_energy",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "total heater socket saved",
|
||
"room": null,
|
||
"type": "input_number",
|
||
"id": {
|
||
"entity_id": "input_number.total_heater_socket_saved",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "water heater socket energy",
|
||
"room": "bathroom",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x842e14fffe13a854_energy",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "total water heater socket saved",
|
||
"room": null,
|
||
"type": "input_number",
|
||
"id": {
|
||
"entity_id": "input_number.total_water_heater_socket_saved",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "kitchen socket1 energy",
|
||
"room": "kitchen",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x842e14fffe36661f_energy",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "total kitchen socket1 saved",
|
||
"room": null,
|
||
"type": "input_number",
|
||
"id": {
|
||
"entity_id": "input_number.total_kitchen_socket1_saved",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "bedroom socket1 energy",
|
||
"room": "bedroom",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x588e81fffeff5c4f_energy",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "total bedroom socket1 saved",
|
||
"room": null,
|
||
"type": "input_number",
|
||
"id": {
|
||
"entity_id": "input_number.total_bedroom_socket1_saved",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "bedroom socket2 energy",
|
||
"room": "bedroom",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x60a423fffef8d41a_energy",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "total bedroom socket2 saved",
|
||
"room": null,
|
||
"type": "input_number",
|
||
"id": {
|
||
"entity_id": "input_number.total_bedroom_socket2_saved",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "yeelight ceiling relay energy",
|
||
"room": "childrens_room",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x54ef441000096cbc_energy",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "total yeelight ceiling relay saved",
|
||
"room": null,
|
||
"type": "input_number",
|
||
"id": {
|
||
"entity_id": "input_number.total_yeelight_ceiling_relay_saved",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "shelly em energy",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.shelly_em_energy",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "total shelly em saved",
|
||
"room": null,
|
||
"type": "input_number",
|
||
"id": {
|
||
"entity_id": "input_number.total_shelly_em_saved",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "server ac energy",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.shelly_plug_s_1_energy",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "total server ac saved",
|
||
"room": null,
|
||
"type": "input_number",
|
||
"id": {
|
||
"entity_id": "input_number.total_server_ac_saved",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "shelly plug s 2 energy",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.shelly_plug_s_2_energy",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "total shelly plug s 2 saved",
|
||
"room": null,
|
||
"type": "input_number",
|
||
"id": {
|
||
"entity_id": "input_number.total_shelly_plug_s_2_saved",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "kitchen light switch working area energy",
|
||
"room": "kitchen",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.0x54ef441000691265_energy",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "total kitchen light switch working area saved",
|
||
"room": null,
|
||
"type": "input_number",
|
||
"id": {
|
||
"entity_id": "input_number.total_kitchen_light_switch_working_area_saved",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "shelly 1pm fan nvr box energy",
|
||
"room": "nvr_box",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.shelly_1pm_fan_nvr_box_energy",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "total shelly 1pm fan nvr box saved",
|
||
"room": null,
|
||
"type": "input_number",
|
||
"id": {
|
||
"entity_id": "input_number.total_shelly_1pm_fan_nvr_box_saved",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "shelly plug s keenetic hw energy",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.shelly_plug_s_keenetic_hw_energy",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "total shelly plug s keenetic hw saved",
|
||
"room": null,
|
||
"type": "input_number",
|
||
"id": {
|
||
"entity_id": "input_number.total_shelly_plug_s_keenetic_hw_saved",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "shelly plug s nvr energy",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.shelly_plug_s_nvr_energy",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "total shelly plug s nvr saved",
|
||
"room": null,
|
||
"type": "input_number",
|
||
"id": {
|
||
"entity_id": "input_number.total_shelly_plug_s_nvr_saved",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "shelly plug s htr energy",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.shelly_plug_s_htr_shelly_heated_tr_energy",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "total shelly plug s htr saved",
|
||
"room": null,
|
||
"type": "input_number",
|
||
"id": {
|
||
"entity_id": "input_number.total_shelly_plug_s_htr_saved",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "on move turn on garland childrens room",
|
||
"automation": "- alias: on move turn on garland childrens room\n id: on move turn on garland childrens room\n triggers:\n - trigger: state\n entity_id: binary_sensor.0x158d00054b8d72_motion\n from: 'off'\n to: 'on'\n conditions:\n - condition: or\n conditions:\n - condition: time\n after: 08:30:00\n before: '12:30:00'\n - condition: time\n after: '16:30:00'\n before: '21:00:00'\n actions:\n - choose:\n - conditions:\n - condition: state\n entity_id: switch.0x842e14fffe5047f5\n state: 'off'\n sequence:\n - action: switch.turn_on\n target:\n entity_id: switch.0x842e14fffe5047f5\n - action: timer.start\n target:\n entity_id: timer.turn_off_garland_childrens_room\n data:\n duration: 300",
|
||
"config": [
|
||
{
|
||
"name": "motion sensor 1",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.0x158d00054b8d72_motion",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "heater socket",
|
||
"room": "childrens_room",
|
||
"type": "switch",
|
||
"id": {
|
||
"entity_id": "switch.0x842e14fffe5047f5",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "turn off garland childrens room timer",
|
||
"room": "childrens_room",
|
||
"type": "timer",
|
||
"id": {
|
||
"entity_id": "timer.turn_off_garland_childrens_room",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "on timer turn off garland childrens room",
|
||
"automation": "- alias: on timer turn off garland childrens room\n id: on timer turn off garland childrens room\n initial_state: true\n triggers:\n - trigger: event\n event_type: timer.finished\n event_data:\n entity_id: timer.turn_off_garland_childrens_room\n conditions:\n - condition: state\n entity_id: switch.0x842e14fffe5047f5\n state: 'on'\n actions:\n - action: switch.turn_off\n target:\n entity_id: switch.0x842e14fffe5047f5",
|
||
"config": [
|
||
{
|
||
"name": "heater socket",
|
||
"room": "childrens_room",
|
||
"type": "switch",
|
||
"id": {
|
||
"entity_id": "switch.0x842e14fffe5047f5",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "turn off garland childrens room timer",
|
||
"room": "childrens_room",
|
||
"type": "timer",
|
||
"id": {
|
||
"entity_id": "timer.turn_off_garland_childrens_room",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "DB purge everyday",
|
||
"automation": "- alias: DB purge everyday\n id: DB purge everyday\n initial_state: true\n triggers:\n - trigger: time\n at: 01:00:00\n actions:\n - action: recorder.purge\n data:\n keep_days: 30\n repack: true",
|
||
"config": []
|
||
},
|
||
{
|
||
"id": "speedtest_integration_restart",
|
||
"automation": "- alias: speedtest_integration_restart\n id: speedtest_integration_restart\n trigger_variables:\n not_has_state: '{{ [''unknown'', ''unavailable'', ''none''] }}'\n triggers:\n - trigger: time_pattern\n minutes: /45\n conditions:\n - condition: state\n entity_id: input_boolean.instances_stoping\n state: 'off'\n - condition: state\n entity_id: binary_sensor.local_network_availability\n state: 'on'\n - condition: template\n value_template: \"{{ states('sensor.speedtest_ping') in not_has_state and\\n states('sensor.speedtest_download')\\\n \\ in not_has_state and\\n states('sensor.speedtest_upload') in not_has_state\\n\\\n }}\\n\"\n actions:\n - action: homeassistant.reload_config_entry\n data:\n entry_id: '{{ config_entry_id(''sensor.speedtest_ping'') }}'",
|
||
"config": [
|
||
{
|
||
"name": "local network availability",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.local_network_availability",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "instances stoping",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.instances_stoping",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "speedtest ping",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.speedtest_ping",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "speedtest download",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.speedtest_download",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "speedtest upload",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.speedtest_upload",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "speedtest_integration_restart_on_event",
|
||
"automation": "- alias: speedtest_integration_restart_on_event\n id: speedtest_integration_restart_on_event\n mode: single\n max_exceeded: silent\n trigger_variables:\n not_has_state: '{{ [''unknown'', ''unavailable'', ''none''] }}'\n triggers:\n - trigger: event\n event_type: state_changed\n event_data:\n entity_id: sensor.speedtest_ping\n - trigger: event\n event_type: state_changed\n event_data:\n entity_id: sensor.speedtest_download\n - trigger: event\n event_type: state_changed\n event_data:\n entity_id: sensor.speedtest_upload\n conditions:\n - condition: state\n entity_id: input_boolean.instances_stoping\n state: 'off'\n - '{{ as_timestamp(now()) - as_timestamp(state_attr(this.entity_id, ''last_triggered''))\n > 60 }}'\n - condition: state\n entity_id: binary_sensor.local_network_availability\n state: 'on'\n - condition: template\n value_template: \"{{ trigger.event.data.new_state.state = trigger.event.data.old_state.state\\\n \\ \\n and trigger.event.data.new_state.state in not_has_state\\n}}\"\n actions:\n - choose:\n - conditions:\n - condition: state\n entity_id: input_boolean.instances_stoping\n state: 'off'\n sequence:\n - delay:\n seconds: 30\n - action: homeassistant.reload_config_entry\n data:\n entry_id: '{{ config_entry_id(''sensor.speedtest_ping'') }}'",
|
||
"config": [
|
||
{
|
||
"name": "local network availability",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.local_network_availability",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "instances stoping",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.instances_stoping",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "speedtest ping",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.speedtest_ping",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "speedtest download",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.speedtest_download",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "speedtest upload",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.speedtest_upload",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "system_event_instances_starting_stoping_set",
|
||
"automation": "- alias: system_event_instances_starting_stoping_set\n id: system_event_instances_starting_stoping_set\n initial_state: true\n triggers:\n - trigger: homeassistant\n event: start\n id: homeassistant_start\n - trigger: homeassistant\n event: shutdown\n actions:\n - parallel:\n - action: \"{% if trigger.id == 'homeassistant_start' -%}\\n input_boolean.turn_off\\n\\\n {% else -%}\\n input_boolean.turn_on\\n{% endif %}\\n\"\n target:\n entity_id: input_boolean.instances_stoping\n - action: \"{% if trigger.id == 'homeassistant_start' -%}\\n automation.turn_on\\n\\\n {% else -%}\\n automation.turn_off\\n{% endif %}\\n\"\n target:\n entity_id: automation.notifications_objects_in_unavailable_status",
|
||
"config": [
|
||
{
|
||
"name": "instances stoping",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.instances_stoping",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "notifications objects in unavailable status automation",
|
||
"room": null,
|
||
"type": "automation",
|
||
"id": {
|
||
"entity_id": "automation.notifications_objects_in_unavailable_status",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "counter increment link down keenetic",
|
||
"automation": "- alias: counter increment link down keenetic\n id: counter increment link down keenetic\n initial_state: true\n mode: single\n max_exceeded: silent\n trigger_variables:\n not_has_state: '{{ [''unknown'', ''unavailable'', ''none'', None, null, '''',\n ''null''] }}'\n triggers:\n - trigger: state\n entity_id: sensor.check_keenetic_link_down\n conditions:\n - condition: template\n value_template: \"{{ \\n trigger.to_state.state not in not_has_state and trigger.from_state.state\\\n \\ = '' and\\n trigger.to_state.state = trigger.from_state.state\\n}}\\n\"\n actions:\n - action: counter.increment\n target:\n entity_id: counter.counter_keenetic_link_down",
|
||
"config": [
|
||
{
|
||
"name": "check keenetic link down",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.check_keenetic_link_down",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "counter keenetic link down",
|
||
"room": null,
|
||
"type": "counter",
|
||
"id": {
|
||
"entity_id": "counter.counter_keenetic_link_down",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "system log home assistant warning and error counter",
|
||
"automation": "- alias: system log home assistant warning and error counter\n id: system log home assistant warning and error counter\n initial_state: true\n mode: queued\n max: 100\n max_exceeded: silent\n trigger_variables:\n this_name: '{{ this.attributes.friendly_name | string }}'\n triggers:\n - trigger: event\n event_type: system_log_event\n event_data:\n level: ERROR\n - trigger: event\n event_type: system_log_event\n event_data:\n level: WARNING\n conditions:\n - condition: template\n value_template: '{{ not this_name in (trigger.event.data.message | string) }}'\n actions:\n - action: counter.increment\n target:\n entity_id: '{{ ''counter.system_log_'' + trigger.event.data.level | lower +\n ''_counter'' }}'",
|
||
"config": []
|
||
},
|
||
{
|
||
"id": "system log clear warning and error reset counter",
|
||
"automation": "- alias: system log clear warning and error reset counter\n id: system log clear warning and error reset counter\n initial_state: true\n mode: queued\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: call_service\n event_data:\n domain: system_log\n service: clear\n actions:\n - action: counter.reset\n target:\n entity_id:\n - counter.system_log_error_counter\n - counter.system_log_warning_counter",
|
||
"config": [
|
||
{
|
||
"name": "system log error counter",
|
||
"room": null,
|
||
"type": "counter",
|
||
"id": {
|
||
"entity_id": "counter.system_log_error_counter",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "system log warning counter",
|
||
"room": null,
|
||
"type": "counter",
|
||
"id": {
|
||
"entity_id": "counter.system_log_warning_counter",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "restart e3372h 320 modem unavailable",
|
||
"automation": "- alias: restart e3372h 320 modem unavailable\n id: restart e3372h 320 modem unavailable\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: sensor.huawei_e3372h_320_sinr\n to: null\n - trigger: homeassistant\n event: start\n conditions:\n - condition: state\n entity_id: input_boolean.instances_stoping\n state: 'off'\n - '{{ not has_value(''sensor.huawei_e3372h_320_sinr'') }}'\n actions:\n - wait_template: '{{ has_value(''sensor.huawei_e3372h_320_sinr'') or is_state(''input_boolean.instances_stoping'',\n ''on'') }}'\n timeout: 00:05:00\n - choose:\n - conditions: '{{ not wait.completed and is_state(''binary_sensor.local_network_availability'',\n ''on'') }}'\n sequence:\n - action: button.press\n target:\n entity_id: button.e3372h_320_restart",
|
||
"config": [
|
||
{
|
||
"name": "local network availability",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.local_network_availability",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "instances stoping",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.instances_stoping",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "huawei e3372h 320 sinr",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.huawei_e3372h_320_sinr",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "e3372h 320 restart button",
|
||
"room": null,
|
||
"type": "button",
|
||
"id": {
|
||
"entity_id": "button.e3372h_320_restart",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "update input text telegram bot api token",
|
||
"automation": "- alias: update input text telegram bot api token\n id: update input text telegram bot api token\n initial_state: true\n mode: queued\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: event_telegram_reloaded\n actions:\n - action: input_text.set_value\n target:\n entity_id: input_text.var_telegram_bot_api_token\n data:\n value: secret telegram_api",
|
||
"config": [
|
||
{
|
||
"name": "var telegram bot api token",
|
||
"room": null,
|
||
"type": "input_text",
|
||
"id": {
|
||
"entity_id": "input_text.var_telegram_bot_api_token",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "cert_expiry_timestamp_asuscomm_unavailable",
|
||
"automation": "- alias: cert_expiry_timestamp_asuscomm_unavailable\n id: cert_expiry_timestamp_asuscomm_unavailable\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: sensor.cert_expiry_timestamp_asuscomm\n to: null\n - trigger: homeassistant\n event: start\n conditions:\n - condition: state\n entity_id: input_boolean.instances_stoping\n state: 'off'\n - '{{ as_timestamp(now()) - as_timestamp(state_attr(this.entity_id, ''last_triggered''))\n > 60 }}'\n - '{{ not has_value(''sensor.cert_expiry_timestamp_asuscomm'') }}'\n actions:\n - wait_template: '{{ has_value(''sensor.cert_expiry_timestamp_asuscomm'') or is_state(''input_boolean.instances_stoping'',\n ''on'') }}'\n timeout: 00:01:00\n - choose:\n - conditions: '{{ not wait.completed and is_state(''binary_sensor.local_network_availability'',\n ''on'') }}'\n sequence:\n - action: homeassistant.reload_config_entry\n data:\n entry_id: '{{ config_entry_id(''sensor.cert_expiry_timestamp_asuscomm'')\n }}'",
|
||
"config": [
|
||
{
|
||
"name": "local network availability",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.local_network_availability",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "instances stoping",
|
||
"room": null,
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.instances_stoping",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "cert expiry timestamp asuscomm",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.cert_expiry_timestamp_asuscomm",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "repairs issue registry sensor update",
|
||
"automation": "- alias: repairs issue registry sensor update\n id: repairs issue registry sensor update\n mode: restart\n triggers:\n - trigger: event\n event_type: repairs_issue_registry_updated\n event_data:\n action: create\n - trigger: homeassistant\n event: start\n actions:\n - action: homeassistant.update_entity\n data:\n entity_id: sensor.repairs_state",
|
||
"config": [
|
||
{
|
||
"name": "repairs state",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.repairs_state",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "entity_update_every_2_minutes",
|
||
"automation": "- alias: entity_update_every_2_minutes\n id: entity_update_every_2_minutes\n max_exceeded: silent\n triggers:\n - trigger: time_pattern\n minutes: /2\n - trigger: homeassistant\n event: start\n actions:\n - action: homeassistant.update_entity\n data:\n entity_id:\n - binary_sensor.internet_availability_nic_ping\n - binary_sensor.internet_availability_yandex_ping",
|
||
"config": [
|
||
{
|
||
"name": "internet availability nic ping",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.internet_availability_nic_ping",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "internet availability yandex ping",
|
||
"room": null,
|
||
"type": "binary_sensor",
|
||
"id": {
|
||
"entity_id": "binary_sensor.internet_availability_yandex_ping",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "vacuum later start cleaning action\"",
|
||
"automation": "- alias: vacuum later start cleaning action\n id: vacuum later start cleaning action\"\n initial_state: true\n triggers:\n - trigger: event\n event_type: timer.finished\n event_data:\n entity_id: timer.vacumm_ten_minutes\n conditions:\n - condition: state\n entity_id: vacuum.xiaomi_vacuum_cleaner\n state: docked\n actions:\n - parallel:\n - action: vacuum.start\n target:\n entity_id: vacuum.xiaomi_vacuum_cleaner\n - action: telegram_bot.send_message\n data:\n target: '{{ states(''input_text.var_chat_id_vacuum_later_start'') }}'\n title: '{{ ''\\U0001f680'' }} *Степа*'\n message: Начал полную уборку\n - action: input_text.set_value\n target:\n entity_id: input_text.var_chat_id_vacuum_later_start\n data:\n value: secret telegram_chita_chat_id",
|
||
"config": [
|
||
{
|
||
"name": "vacuum xiaomi",
|
||
"room": null,
|
||
"type": "vacuum",
|
||
"id": {
|
||
"entity_id": "vacuum.xiaomi_vacuum_cleaner",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "vacuum ten minutes timer",
|
||
"room": null,
|
||
"type": "timer",
|
||
"id": {
|
||
"entity_id": "timer.vacumm_ten_minutes",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "var chat id vacuum later start",
|
||
"room": null,
|
||
"type": "input_text",
|
||
"id": {
|
||
"entity_id": "input_text.var_chat_id_vacuum_later_start",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Chita Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_chita_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "vacuum later start cleaning not docked",
|
||
"automation": "- alias: vacuum later start cleaning not docked\n id: vacuum later start cleaning not docked\n initial_state: true\n triggers:\n - trigger: event\n event_type: timer.finished\n event_data:\n entity_id: timer.vacumm_ten_minutes\n conditions:\n - condition: not\n conditions:\n - condition: state\n entity_id: vacuum.xiaomi_vacuum_cleaner\n state: docked\n actions:\n - parallel:\n - action: telegram_bot.send_message\n data:\n target: '{{ states(''input_text.var_chat_id_vacuum_later_start'') }}'\n title: ⚠️ *Степа*\n message: Не смог начать полную уборку, потому что нахожусь не на базе\n - action: input_text.set_value\n target:\n entity_id: input_text.var_chat_id_vacuum_later_start\n data:\n value: secret telegram_chita_chat_id",
|
||
"config": [
|
||
{
|
||
"name": "vacuum xiaomi",
|
||
"room": null,
|
||
"type": "vacuum",
|
||
"id": {
|
||
"entity_id": "vacuum.xiaomi_vacuum_cleaner",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "vacuum ten minutes timer",
|
||
"room": null,
|
||
"type": "timer",
|
||
"id": {
|
||
"entity_id": "timer.vacumm_ten_minutes",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "var chat id vacuum later start",
|
||
"room": null,
|
||
"type": "input_text",
|
||
"id": {
|
||
"entity_id": "input_text.var_chat_id_vacuum_later_start",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Chita Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_chita_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "vacuum start stop camera map when docked cleaning",
|
||
"automation": "- alias: vacuum start stop camera map when docked cleaning\n id: vacuum start stop camera map when docked cleaning\n initial_state: true\n mode: queued\n triggers:\n - trigger: state\n entity_id: vacuum.xiaomi_vacuum_cleaner\n - trigger: homeassistant\n event: start\n - trigger: event\n event_type: event_xiaomi_cloud_map_extractor_reloaded\n conditions:\n - condition: template\n value_template: \"{{ \\n trigger.platform = 'state'\\n or trigger.to_state.state\\\n \\ = trigger.from_state.state\\n}}\\n\"\n actions:\n - if:\n - '{{ states(''vacuum.xiaomi_vacuum_cleaner'') in [''docked'', ''unknown'', ''unavailable'',\n ''none'', None, null, ''''] }}'\n then:\n - delay:\n seconds: 45\n - action: homeassistant.update_entity\n data:\n entity_id: camera.roborock_vacuum_map\n - action: camera.turn_off\n target:\n entity_id: camera.roborock_vacuum_map\n else:\n - action: camera.turn_on\n target:\n entity_id: camera.roborock_vacuum_map",
|
||
"config": [
|
||
{
|
||
"name": "vacuum xiaomi",
|
||
"room": null,
|
||
"type": "vacuum",
|
||
"id": {
|
||
"entity_id": "vacuum.xiaomi_vacuum_cleaner",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "roborock vacuum map camera",
|
||
"room": null,
|
||
"type": "camera",
|
||
"id": {
|
||
"entity_id": "camera.roborock_vacuum_map",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "zigbee_device_joined_notification",
|
||
"automation": "- alias: zigbee_device_joined_notification\n id: zigbee_device_joined_notification\n mode: queued\n triggers:\n - trigger: mqtt\n topic: zigbee2mqtt/bridge/event\n conditions:\n condition: template\n value_template: '{{trigger.payload_json.type == \"device_interview\" and trigger.payload_json.data.status\n == \"successful\" and trigger.payload_json.data.supported}}'\n actions:\n - action: telegram_bot.send_message\n data:\n title: '{{ ''\\U0001f41d'' }} <b>Добавление устройств Zigbee</b>'\n message: 'Добавлено новое устройство: {{- ''\\n'' -}} Имя: {{trigger.payload_json.data.friendly_name\n | e}}, {{- ''\\n'' -}} Поставщик: {{trigger.payload_json.data.definition.vendor\n | e}}, {{- ''\\n'' -}} Модель: {{trigger.payload_json.data.definition.model\n | e}} {{- ''\\n'' -}} Описание: {{trigger.payload_json.data.definition.description\n | e}}'\n disable_notification: true\n parse_mode: html\n target: secret telegram_enzokot_chat_id",
|
||
"config": [
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "zigbee2mqtt_devices_last_seen",
|
||
"automation": "- alias: zigbee2mqtt_devices_last_seen\n id: zigbee2mqtt_devices_last_seen\n triggers:\n - trigger: time_pattern\n hours: /1\n conditions:\n - condition: template\n value_template: '{%- set time_limit = as_timestamp(now(), 0) - 3*60*60 -%} {%-\n set list_sensors = expand(''group.dynamic_group_sensor_last_seen'') | selectattr(''state'',\n ''ne'', None) | selectattr(''state'', ''ne'', ''None'') | selectattr(''state'',\n ''ne'', ''unknown'') -%} {%- set datanames = namespace(last_seen=[]) -%} {%-\n for state in list_sensors -%} {%- if state.entity_id.endswith(''_last_seen'')\n -%} {%- set time_ms = 1000 -%} {%- set state_ms = state.state -%} {%- else\n -%} {%- set time_ms = 1 -%} {%- set state_ms = as_timestamp(state.state , 0)\n -%} {%- endif -%} {%- if (state_ms | int(time_limit * time_ms, 0)) < (time_limit\n * time_ms) or not has_value(state.entity_id) -%} {%- set datanames.last_seen\n = datanames.last_seen + [state] -%} {%- endif -%} {%- endfor -%} {{ datanames.last_seen\n | length > 0 }}\n\n '\n actions:\n - action: telegram_bot.send_message\n data:\n title: '{%- set time_limit = as_timestamp(now(), 0) - 3*60*60 -%} {%- set list_sensors\n = expand(''group.dynamic_group_sensor_last_seen'') | selectattr(''state'',\n ''ne'', None) | selectattr(''state'', ''ne'', ''None'') | selectattr(''state'',\n ''ne'', ''unknown'') -%} {%- set datanames = namespace(last_seen=[]) -%} {%-\n for state in list_sensors -%} {%- if state.entity_id.endswith(''_last_seen'')\n -%} {%- set time_ms = 1000 -%} {%- set state_ms = state.state -%} {%- else\n -%} {%- set time_ms = 1 -%} {%- set state_ms = as_timestamp(state.state,\n 0) -%} {%- endif -%} {%- if (state_ms | int(time_limit * time_ms)) < (time_limit\n * time_ms) or not has_value(state.entity_id) -%} {%- set datanames.last_seen\n = datanames.last_seen + [state] -%} {%- endif -%} {%- endfor -%}\n\n {%- set missing_count = datanames.last_seen | length -%} {%- if missing_count\n > 0 %} ⚠️ {%- else %} {{ ''\\U00002705'' }} {%- endif %} *Контроль устройств\n Zigbee*'\n disable_notification: true\n target: secret telegram_enzokot_chat_id\n message: \"{%- set time_limit = as_timestamp(now(), 0) - 3*60*60 -%} {%- set\\\n \\ list_sensors = expand('group.dynamic_group_sensor_last_seen') | selectattr('state',\\\n \\ 'ne', None) | selectattr('state', 'ne', 'None') | selectattr('state', 'ne',\\\n \\ 'unknown') -%} {%- set datanames = namespace(device_name=[]) -%} {%- for\\\n \\ state in list_sensors -%} {%- if state.entity_id.endswith('_last_seen')\\\n \\ -%} {%- set time_ms = 1000 -%} {%- set state_ms = state.state -%} {%- else\\\n \\ -%} {%- set time_ms = 1 -%} {%- set state_ms = as_timestamp(state.state,\\\n \\ 0) -%} {%- endif -%} {%- if (state_ms | int(time_limit * time_ms)) < (time_limit\\\n \\ * time_ms) or not has_value(state.entity_id) -%} {% if device_attr(state.entity_id,\\\n \\ 'name_by_user') = none %}\\n {%- set datanames.device_name = datanames.device_name\\\n \\ + [device_attr(state.entity_id, 'name_by_user')] -%}\\n{% else %}\\n {%-\\\n \\ set datanames.device_name = datanames.device_name + [device_attr(state.entity_id,\\\n \\ 'name')] -%}\\n{% endif %} {%- endif -%} {%- endfor -%}\\n{%- set missing\\\n \\ = datanames.device_name | list -%} {% set missing_count = missing | count\\\n \\ %}\\n{% if missing_count > 0 %}Более 3 часов не было данных от: {{ missing\\\n \\ | join(', ') }} {% else %}Все устройства доступны.{% endif %}\\n\"",
|
||
"config": [
|
||
{
|
||
"name": "dynamic group sensor last seen",
|
||
"room": null,
|
||
"type": "group",
|
||
"id": {
|
||
"entity_id": "group.dynamic_group_sensor_last_seen",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "zigbee2mqtt_devices_link_check",
|
||
"automation": "- alias: zigbee2mqtt_devices_link_check\n id: zigbee2mqtt_devices_link_check\n triggers:\n - trigger: time_pattern\n hours: /1\n conditions:\n - condition: template\n value_template: \"{%- set list_sensors = expand('group.dynamic_group_sensor_linkquality')\\\n \\ | selectattr('state', 'ne', None) | selectattr('state', 'ne', 'None') -%}\\\n \\ {%- set datanames = namespace(low_linkquality=[]) -%} {%- for state in list_sensors\\\n \\ -%} {%- if (state.entity_id.endswith('_linkquality') and (state.state | int(15))\\\n \\ < 15) or \\n (state.entity_id.endswith('_zigbee') and (state_attr(state.entity_id\\\n \\ ,'linkquality') | int(15)) < 15)-%}\\n{%- set datanames.low_linkquality = datanames.low_linkquality\\\n \\ + [state] -%} {%- endif -%} {%- endfor -%} {{ datanames.low_linkquality |\\\n \\ length > 0 }}\\n\"\n actions:\n - action: script.zigbee2mqtt_linkuality_check",
|
||
"config": [
|
||
{
|
||
"name": "dynamic group sensor linkquality",
|
||
"room": null,
|
||
"type": "group",
|
||
"id": {
|
||
"entity_id": "group.dynamic_group_sensor_linkquality",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "zigbee2mqtt linkuality check script",
|
||
"room": null,
|
||
"type": "script",
|
||
"id": {
|
||
"entity_id": "script.zigbee2mqtt_linkuality_check",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "auto_local_temperature_calibration_thermostats",
|
||
"automation": "- alias: auto_local_temperature_calibration_thermostats\n id: auto_local_temperature_calibration_thermostats\n triggers:\n - trigger: time_pattern\n minutes: /3\n actions:\n - parallel:\n - action: script.auto_local_temperature_calibration_thermostats\n data:\n namevalve: Bedroom valve with thermostat\n objectvalve: climate.0x60a423fffe968719\n objectvalvewindow: switch.0x60a423fffe968719_window_detection\n objectsensortemperature: sensor.esp_xiaomi_bed_room_temperature\n - action: script.auto_local_temperature_calibration_thermostats\n data:\n namevalve: Living room valve with thermostat\n objectvalve: climate.0x5c0272fffec9db22\n objectvalvewindow: switch.0x5c0272fffec9db22_window_detection\n objectsensortemperature: sensor.esp_xiaomi_living_room_temperature\n - action: script.auto_local_temperature_calibration_thermostats\n data:\n namevalve: Childrens room valve with thermostat\n objectvalve: climate.0x5c0272fffec89454\n objectvalvewindow: switch.0x5c0272fffec89454_window_detection\n objectsensortemperature: sensor.esp_xiaomi_childrens_room_temperature\n - action: script.auto_local_temperature_calibration_thermostats\n data:\n namevalve: Kitchen valve with thermostat\n objectvalve: climate.0x5c0272fffe8de819\n objectvalvewindow: switch.0x5c0272fffe8de819_window_detection\n objectsensortemperature: sensor.esp_xiaomi_kitchen_temperature",
|
||
"config": [
|
||
{
|
||
"name": "childrens room valve with thermostat",
|
||
"room": "childrens_room",
|
||
"type": "climate",
|
||
"id": {
|
||
"entity_id": "climate.0x5c0272fffec89454",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "bedroom valve with thermostat",
|
||
"room": "bedroom",
|
||
"type": "climate",
|
||
"id": {
|
||
"entity_id": "climate.0x60a423fffe968719",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "kitchen valve with thermostat",
|
||
"room": "kitchen",
|
||
"type": "climate",
|
||
"id": {
|
||
"entity_id": "climate.0x5c0272fffe8de819",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "living room valve with thermostat",
|
||
"room": "living_room",
|
||
"type": "climate",
|
||
"id": {
|
||
"entity_id": "climate.0x5c0272fffec9db22",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "bedroom valve window detection",
|
||
"room": "bedroom",
|
||
"type": "switch",
|
||
"id": {
|
||
"entity_id": "switch.0x60a423fffe968719_window_detection",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "esp xiaomi bedroom temperature",
|
||
"room": "bedroom",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.esp_xiaomi_bed_room_temperature",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "living room valve window detection",
|
||
"room": "living_room",
|
||
"type": "switch",
|
||
"id": {
|
||
"entity_id": "switch.0x5c0272fffec9db22_window_detection",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "esp xiaomi living room temperature",
|
||
"room": "living_room",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.esp_xiaomi_living_room_temperature",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "childrens room valve window detection",
|
||
"room": "childrens_room",
|
||
"type": "switch",
|
||
"id": {
|
||
"entity_id": "switch.0x5c0272fffec89454_window_detection",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "esp xiaomi childrens room temperature",
|
||
"room": "childrens_room",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.esp_xiaomi_childrens_room_temperature",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "kitchen valve window detection",
|
||
"room": "kitchen",
|
||
"type": "switch",
|
||
"id": {
|
||
"entity_id": "switch.0x5c0272fffe8de819_window_detection",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "esp xiaomi kitchen temperature",
|
||
"room": "kitchen",
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.esp_xiaomi_kitchen_temperature",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "auto local temperature calibration thermostats script",
|
||
"room": null,
|
||
"type": "script",
|
||
"id": {
|
||
"entity_id": "script.auto_local_temperature_calibration_thermostats",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "auto_boost_mode_thermostats_at_sleeping_time",
|
||
"automation": "- alias: auto_boost_mode_thermostats_at_sleeping_time\n id: auto_boost_mode_thermostats_at_sleeping_time\n triggers:\n - trigger: time\n at:\n - 02:30:00\n - 05:30:00\n actions:\n - parallel:\n - choose:\n - conditions:\n - condition: state\n entity_id: input_boolean.thermostat_bedroom_night_mode\n state: 'on'\n sequence:\n - action: climate.set_preset_mode\n target:\n entity_id: climate.0x60a423fffe968719\n data:\n preset_mode: boost\n - choose:\n - conditions:\n - condition: state\n entity_id: input_boolean.thermostat_childrensroom_night_mode\n state: 'on'\n sequence:\n - action: climate.set_preset_mode\n target:\n entity_id: climate.0x5c0272fffec89454\n data:\n preset_mode: boost",
|
||
"config": [
|
||
{
|
||
"name": "childrens room valve with thermostat",
|
||
"room": "childrens_room",
|
||
"type": "climate",
|
||
"id": {
|
||
"entity_id": "climate.0x5c0272fffec89454",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "bedroom valve with thermostat",
|
||
"room": "bedroom",
|
||
"type": "climate",
|
||
"id": {
|
||
"entity_id": "climate.0x60a423fffe968719",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "thermostat bedroom night mode",
|
||
"room": "bedroom",
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.thermostat_bedroom_night_mode",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "thermostat childrensroom night mode",
|
||
"room": "childrens_room",
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.thermostat_childrensroom_night_mode",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "switching_thermostat_night_mode",
|
||
"automation": "- alias: switching_thermostat_night_mode\n id: switching_thermostat_night_mode\n initial_state: 'true'\n triggers:\n - trigger: state\n entity_id:\n - input_boolean.thermostat_bedroom_night_mode\n - input_boolean.thermostat_childrensroom_night_mode\n - automation.auto_boost_mode_thermostats_at_sleeping_time\n conditions:\n - condition: template\n value_template: \"{{ \\n (is_state('input_boolean.thermostat_bedroom_night_mode',\\\n \\ 'off') and is_state('input_boolean.thermostat_childrensroom_night_mode', 'off')\\\n \\ \\n and is_state('automation.auto_boost_mode_thermostats_at_sleeping_time',\\\n \\ 'on'))\\n or\\n ((is_state('input_boolean.thermostat_bedroom_night_mode',\\\n \\ 'on') or is_state('input_boolean.thermostat_childrensroom_night_mode', 'on'))\\\n \\ \\n and is_state('automation.auto_boost_mode_thermostats_at_sleeping_time',\\\n \\ 'off'))\\n}}\\n\"\n actions:\n - choose:\n - conditions:\n - condition: template\n value_template: '{{ trigger.platform == ''state'' and trigger.to_state.domain\n == ''input_boolean'' }}'\n sequence:\n - action: \"{% if is_state('input_boolean.thermostat_bedroom_night_mode', 'off')\\\n \\ and is_state('input_boolean.thermostat_childrensroom_night_mode', 'off')\\\n \\ %}\\n automation.turn_off\\n{% else %}\\n automation.turn_on\\n{% endif\\\n \\ %}\\n\"\n target:\n entity_id: automation.auto_boost_mode_thermostats_at_sleeping_time\n - conditions:\n - condition: template\n value_template: '{{ trigger.platform == ''state'' and trigger.to_state.domain\n == ''automation'' }}'\n sequence:\n - action: \"{% if is_state('automation.auto_boost_mode_thermostats_at_sleeping_time',\\\n \\ 'off') %}\\n input_boolean.turn_off\\n{% else %}\\n input_boolean.turn_on\\n\\\n {% endif %}\\n\"\n target:\n entity_id:\n - input_boolean.thermostat_bedroom_night_mode\n - input_boolean.thermostat_childrensroom_night_mode",
|
||
"config": [
|
||
{
|
||
"name": "thermostat bedroom night mode",
|
||
"room": "bedroom",
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.thermostat_bedroom_night_mode",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "thermostat childrensroom night mode",
|
||
"room": "childrens_room",
|
||
"type": "input_boolean",
|
||
"id": {
|
||
"entity_id": "input_boolean.thermostat_childrensroom_night_mode",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "auto boost mode thermostats at sleeping time automation",
|
||
"room": null,
|
||
"type": "automation",
|
||
"id": {
|
||
"entity_id": "automation.auto_boost_mode_thermostats_at_sleeping_time",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "auto_scrolling_thermostats_at_month",
|
||
"automation": "- alias: auto_scrolling_thermostats_at_month\n id: auto_scrolling_thermostats_at_month\n triggers:\n - trigger: time\n at: '10:00:00'\n conditions:\n - '{{ now().timestamp() | timestamp_custom(''%d'') | int(0) in [1, 15] }}'\n - condition: state\n entity_id:\n - climate.0x5c0272fffec89454\n - climate.0x60a423fffe968719\n - climate.0x5c0272fffec9db22\n - climate.0x5c0272fffe8de819\n state: heat\n actions:\n - action: climate.set_hvac_mode\n target:\n entity_id:\n - climate.0x5c0272fffec89454\n - climate.0x60a423fffe968719\n - climate.0x5c0272fffec9db22\n - climate.0x5c0272fffe8de819\n data:\n hvac_mode: 'off'\n - delay: 00:02:00\n - action: climate.set_hvac_mode\n target:\n entity_id:\n - climate.0x5c0272fffec89454\n - climate.0x60a423fffe968719\n - climate.0x5c0272fffec9db22\n - climate.0x5c0272fffe8de819\n data:\n hvac_mode: heat\n - delay: 00:01:00\n - action: telegram_bot.send_message\n data:\n target: secret telegram_enzokot_chat_id\n disable_notification: true\n title: '{{ ''🔧'' }} *Обслуживание устройств*'\n message: Выполнено обслуживание TRV, необходимо проверить состояние и физическое\n положение штоков.",
|
||
"config": [
|
||
{
|
||
"name": "childrens room valve with thermostat",
|
||
"room": "childrens_room",
|
||
"type": "climate",
|
||
"id": {
|
||
"entity_id": "climate.0x5c0272fffec89454",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "bedroom valve with thermostat",
|
||
"room": "bedroom",
|
||
"type": "climate",
|
||
"id": {
|
||
"entity_id": "climate.0x60a423fffe968719",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "kitchen valve with thermostat",
|
||
"room": "kitchen",
|
||
"type": "climate",
|
||
"id": {
|
||
"entity_id": "climate.0x5c0272fffe8de819",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "living room valve with thermostat",
|
||
"room": "living_room",
|
||
"type": "climate",
|
||
"id": {
|
||
"entity_id": "climate.0x5c0272fffec9db22",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Telegram Enzokot Chat ID Secret",
|
||
"room": null,
|
||
"type": null,
|
||
"id": {
|
||
"entity_id": "secret telegram_enzokot_chat_id",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "set_options_for_selected_router_for_permit_join_z2m",
|
||
"automation": "- alias: set_options_for_selected_router_for_permit_join_z2m\n id: set_options_for_selected_router_for_permit_join_z2m\n mode: queued\n triggers:\n - trigger: state\n entity_id: sensor.router_devices_z2m\n not_from: null\n - trigger: homeassistant\n event: start\n - trigger: event\n event_type: automation_reloaded\n - trigger: event\n id: input_select_reload\n event_type: call_service\n event_data:\n domain: input_select\n service: reload\n actions:\n - if:\n - condition: trigger\n id: input_select_reload\n then:\n - wait_for_trigger:\n - trigger: state\n entity_id: input_select.selected_router_for_permit_join_z2m\n to: null\n timeout:\n seconds: 2\n - variables:\n new_options: \"{% set select_options = iif(states('sensor.router_devices_z2m')\\\n \\ | int(0) > 0, state_attr('sensor.router_devices_z2m', 'routers'), ['Не выбрано'])\\\n \\ %} {% set data = namespace(entities=[]) %} {% for i in select_options -%}\\n\\\n \\ {% if loop.first %}\\n {% set data.entities = data.entities + ['Не\\\n \\ выбрано'] %}\\n {% endif %}\\n {% set data.entities = data.entities\\\n \\ + [i] %}\\n{% endfor %} {{ data.entities | unique | list }}\\n\"\n old_options_with_new: \"{% set data = namespace(entities=[]) %} {% for i in new_options\\\n \\ -%}\\n {% set data.entities = data.entities + [i] %}\\n {% if loop.last\\\n \\ %}\\n {% set data.entities = data.entities + [states('input_select.selected_router_for_permit_join_z2m')]\\\n \\ %}\\n {% endif %}\\n{% endfor %} {{ data.entities | unique | list }}\\n\"\n - action: input_select.set_options\n target:\n entity_id: input_select.selected_router_for_permit_join_z2m\n data:\n options: '{{ old_options_with_new }}'\n - action: input_select.select_option\n target:\n entity_id: input_select.selected_router_for_permit_join_z2m\n data:\n option: '{{ new_options | first }}'\n - action: input_select.set_options\n target:\n entity_id: input_select.selected_router_for_permit_join_z2m\n data:\n options: '{{ new_options }}'\n - action: input_select.select_first\n target:\n entity_id: input_select.selected_router_for_permit_join_z2m",
|
||
"config": [
|
||
{
|
||
"name": "router devices z2m",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.router_devices_z2m",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "selected router for permit join z2m",
|
||
"room": null,
|
||
"type": "input_select",
|
||
"id": {
|
||
"entity_id": "input_select.selected_router_for_permit_join_z2m",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Select Option",
|
||
"room": null,
|
||
"type": "input_select",
|
||
"id": {
|
||
"entity_id": "input_select.select_option",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "start_selected_router_permit_join_z2m",
|
||
"automation": "- alias: start_selected_router_permit_join_z2m\n id: start_selected_router_permit_join_z2m\n mode: restart\n triggers:\n - trigger: event\n event_type: call_service\n event_data:\n domain: input_select\n service: select_option\n service_data:\n entity_id: input_select.selected_router_for_permit_join_z2m\n conditions:\n - '{{ states.person | selectattr(''attributes.user_id'', ''eq'', trigger.event.context.user_id)\n | list | count > 0 }}'\n actions:\n - action: mqtt.publish\n data:\n topic: zigbee2mqtt/bridge/request/permit_join\n payload: '{{ ''{'' ~ iif(trigger.event.data.service_data.option == ''Не выбрано'',\n ''\"time\":0'', ''\"time\":254, \"device\":\"'' ~ trigger.event.data.service_data.option)\n ~ ''\"}'' }}\n\n '",
|
||
"config": [
|
||
{
|
||
"name": "selected router for permit join z2m",
|
||
"room": null,
|
||
"type": "input_select",
|
||
"id": {
|
||
"entity_id": "input_select.selected_router_for_permit_join_z2m",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "set_option_for_selected_router_from_info_topic_z2m",
|
||
"automation": "- alias: set_option_for_selected_router_from_info_topic_z2m\n id: set_option_for_selected_router_from_info_topic_z2m\n mode: restart\n triggers:\n - trigger: state\n entity_id: switch.permit_join_switch_z2m\n id: switch_permit_join\n to: 'off'\n - trigger: state\n entity_id: sensor.zigbee2mqtt_add_on_permit_join_current_device_z2m\n id: sensor_current_device\n actions:\n - variables:\n permit_join_current_device: '{{ states(''sensor.zigbee2mqtt_add_on_permit_join_current_device_z2m'')\n if is_state(''switch.permit_join_switch_z2m'', ''on'') and has_value(''sensor.zigbee2mqtt_add_on_permit_join_current_device_z2m'')\n else ''Не выбрано'' }}'\n - parallel:\n - if:\n - condition: trigger\n id: switch_permit_join\n - '{{ not is_state(''input_select.select_option'', ''Не выбрано'') }}'\n then:\n - action: input_select.select_option\n target:\n entity_id: input_select.selected_router_for_permit_join_z2m\n data:\n option: Не выбрано\n - if:\n - condition: trigger\n id: sensor_current_device\n - '{{ not is_state(''input_select.selected_router_for_permit_join_z2m'', permit_join_current_device)\n }}'\n then:\n - action: input_select.select_option\n target:\n entity_id: input_select.selected_router_for_permit_join_z2m\n data:\n option: '{{ permit_join_current_device }}'",
|
||
"config": [
|
||
{
|
||
"name": "permit join switch z2m",
|
||
"room": null,
|
||
"type": "switch",
|
||
"id": {
|
||
"entity_id": "switch.permit_join_switch_z2m",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "selected router for permit join z2m",
|
||
"room": null,
|
||
"type": "input_select",
|
||
"id": {
|
||
"entity_id": "input_select.selected_router_for_permit_join_z2m",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "zigbee2mqtt add on permit join current device z2m",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.zigbee2mqtt_add_on_permit_join_current_device_z2m",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "Select Option",
|
||
"room": null,
|
||
"type": "input_select",
|
||
"id": {
|
||
"entity_id": "input_select.select_option",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
},
|
||
{
|
||
"id": "start_timer_permit_join_timeout_z2m",
|
||
"automation": "- alias: start_timer_permit_join_timeout_z2m\n id: start_timer_permit_join_timeout_z2m\n initial_state: true\n mode: restart\n triggers:\n - trigger: state\n entity_id: sensor.zigbee2mqtt_add_on_permit_join_end_z2m\n - trigger: homeassistant\n event: start\n - trigger: event\n event_type: automation_reloaded\n actions:\n - variables:\n time_remaining: '{{ ((states(''sensor.zigbee2mqtt_add_on_permit_join_end_z2m'')\n | int(0)) / 1000 - (as_timestamp(utcnow(), 0) | int(0))) | int(0) }}'\n - if:\n - '{{ time_remaining > 0 }}'\n then:\n - action: timer.start\n target:\n entity_id: timer.permit_join_timeout_z2m\n data:\n duration: '{{ time_remaining }}'\n else:\n - action: timer.cancel\n target:\n entity_id: timer.permit_join_timeout_z2m",
|
||
"config": [
|
||
{
|
||
"name": "permit join timeout z2m timer",
|
||
"room": null,
|
||
"type": "timer",
|
||
"id": {
|
||
"entity_id": "timer.permit_join_timeout_z2m",
|
||
"device_id": null
|
||
}
|
||
},
|
||
{
|
||
"name": "zigbee2mqtt add on permit join end z2m",
|
||
"room": null,
|
||
"type": "sensor",
|
||
"id": {
|
||
"entity_id": "sensor.zigbee2mqtt_add_on_permit_join_end_z2m",
|
||
"device_id": null
|
||
}
|
||
}
|
||
]
|
||
}
|
||
] |