Skip to main content

Lock

synapse.lock is a wrapper around the Home Assistant lock entity, allowing you to build your own virtual lock for a variety of uses

Home Assistant Counterpart

✏️ Usage

minimum properties

synapse.binary_sensor({
context,
name: "My binary sensor entity"
});

Entity specific attributes

By default lock entities have managed: true set, and will automatically set values in response to service calls.

⚙️ Configuration

NameTypeDescription
changed_bystringDescribes what the last change was triggered by.
code_formatstringRegex for code format or None if no code is required.
is_lockedbooleanIndication of whether the lock is currently locked.
is_lockingbooleanIndication of whether the lock is currently locking.
is_unlockingbooleanIndication of whether the lock is currently unlocking.
is_jammedbooleanIndication of whether the lock is currently jammed.
is_openingbooleanIndication of whether the lock is currently opening.
is_openbooleanIndication of whether the lock is currently open.

🌐 Events

  • lock / onLock
  • unlock / onUnlock
  • open / onOpen