Hello, sorry if this isn’t in the right place. I have spent all days watching videos, trying different blueprints and reading other people posts. My problem might be that I’m still struggling with the actions and building blocks. I know this is probably so simple.
My Objective: I have a door lock that I want to turn the light on when I unlock it. all this I can set up fine. but I want the light to turn off after 1 minute and this is where I’m struggling. the blueprints I tried don’t work for "lock’ or “unlock” just “on/off” or motion. I feel as though what I’ve done is correct but the light won’t turn off. a little guidance would be really appreciated! here’s what the yaml file says.
alias: Front Lock Light On
description: “”
triggers:
- trigger: state
entity_id:- lock.front_door
from: locked
to: unlocked
conditions:
- lock.front_door
- condition: sun
before: sunrise
after: sunset
actions: - action: light.turn_on
metadata: {}
data: {}
target:
entity_id: light.entryway - choose:
- conditions:
- condition: state
entity_id: light.entryway
state: “on”
for:
hours: 0
minutes: 1
seconds: 0
sequence: - action: light.turn_off
metadata: {}
data: {}
target:
entity_id: light.entryway
mode: single
- condition: state
- conditions:
again any help would be appreciated.i would like to know what I did wrong in the ui too so I can learn from my mistake… thanks!!