automation-control
Automation-control cap.
Automation-control cap. Models HA automation.* entities on DeviceType.Automation. An automation is a trigger+condition+ action rule that can be enabled / disabled and manually fired via the trigger method.
trigger accepts an optional skipCondition flag — when true, the automation's action block runs WITHOUT evaluating its condition block. Pair with DeviceFeature.AutomationSkipCondition to gate the UI checkbox for the manual-trigger dialog.
At a glance
| Capability | automation-control |
| Provided by | The device's own driver provides it: each device registers its own provider. |
| Active providers per device | one |
| Device types | automation |
| Source | packages/types/src/capabilities/automation-control.cap.ts |
Methods
Every method takes the device id (deviceId) to address the device; the input tables below list the other fields.
| Method | Kind | Required of a provider | Access |
|---|---|---|---|
enable | mutation | yes | admin |
disable | mutation | yes | admin |
trigger | mutation | yes | admin |
enable
mutation
Input
No fields besides deviceId.
Output
Nothing.
Actions (offered in automations and on device cards)
| Action | Label | Sets |
|---|---|---|
haAutomation.enable | Enable automation | enabled = true |
disable
mutation
Input
No fields besides deviceId.
Output
Nothing.
Actions (offered in automations and on device cards)
| Action | Label | Sets |
|---|---|---|
haAutomation.disable | Disable automation | enabled = false |
trigger
mutation
Input
| Field | Type | Required | Description |
|---|---|---|---|
skipCondition | boolean | no | When true, fires the action block while bypassing the automation's condition evaluation. Gated by DeviceFeature.AutomationSkipCondition. |
Output
Nothing.
Actions (offered in automations and on device cards)
| Action | Label | Sets |
|---|---|---|
haAutomation.trigger | Trigger automation |
Runtime state
The state Dominevo keeps for each device with this capability, readable without calling the provider.
Runtime-state slice — mirrored by the kernel. UI automation tile reads enabled (toggle) + isRunning (spinner) + lastError (badge) directly.
| Field | Type | Required | Description |
|---|---|---|---|
enabled | boolean | yes | Whether the automation is currently enabled. Disabled automations ignore their trigger block — manual trigger still works. |
isRunning | boolean | yes | Whether the automation is currently executing its action block. |
lastTriggeredAt | number | yes | Ms epoch of the last successful run. 0 when never run. |
lastError | string | null | yes | Failure description from the last completed run. Null on success or when never run. |
lastChangedAt | number | yes | Ms epoch when the slice was last updated. |