Skip to content

Instantly share code, notes, and snippets.

@hobbe
Last active February 23, 2023 18:54
Show Gist options
  • Save hobbe/beafad19e74ee7935f19fb5c182c3914 to your computer and use it in GitHub Desktop.
Save hobbe/beafad19e74ee7935f19fb5c182c3914 to your computer and use it in GitHub Desktop.
Home Assistant blueprint: open/close covers based on a schedule's state
blueprint:
name: "[ob] Schedule covers"
description: "Open/close covers based on a schedule's state."
domain: automation
source_url: https://gist.github.com/hobbe/beafad19e74ee7935f19fb5c182c3914
homeassistant:
min_version: 2022.10.0
input:
schedule_entity:
name: Schedule
description: "This schedule will open/close the target cover entities."
selector:
entity:
domain: schedule
target_entity:
name: Target entities
description: "These covers will open and close based on the schedule."
selector:
target:
entity:
domain:
- cover
trigger:
- platform: state
entity_id: !input schedule_entity
action:
- service: >
{% if trigger.to_state.state == "on" %}
cover.open_cover
{% else %}
cover.close_cover
{% endif %}
target: !input target_entity
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment