Input boolean
The input boolean helper in Home Assistant is a toggle: on or off, controlled from a dashboard or from automations, and usable as a trigger or condition.
Spook adds actions to the input boolean integration to create and delete these helpers from automations and scripts, and to turn them on or off for a while.
Actions
Spook adds four actions for input booleans. You find them wherever you add an action, marked with a 👻.
Create an input boolean
Creates a new input boolean (toggle) helper, the same as adding one on the helpers page.
Some flags are only needed for a while. A script that runs a party mode, a move, a holiday: it needs a toggle to remember "this is going on", and nothing else ever looks at it. Made by hand, that toggle stays on the helpers page forever. Made with this action, the script makes it when it starts, and deletes it when it is done.
How to use it
- Open the automation or script that should make the toggle, and select Add action.
- Search for create an input boolean, and select Input boolean: Create an input boolean 👻.
- Fill in Name, like
Guest mode. - Optionally, set Input boolean entity ID to pick the entity ID yourself, Initial value, and Icon.
- Select Save.
Just want to see it work? Try this action opens it in your Home Assistant, ready to run once.

| Action properties | |
|---|---|
| Action | Input boolean: Create an input boolean 👻 |
| Action name | input_boolean.create |
| Action targets | No targets |
| Action response | Optional, the entity_id of the new input boolean |
| Spook's influence | Newly added action |
| Tools | Try this action |
| Action data parameters | |||
|---|---|---|---|
| Attribute | Type | Required | Default / Example |
name | string | Yes | Guest mode |
input_boolean_id | string | No | guest_mode |
initial | boolean | No | false |
icon | string | No | mdi:account-multiple |
Without an input_boolean_id, the entity ID follows the name, as it does in the UI, and gets a number at the end if that name is already taken. With an input_boolean_id, you get exactly that entity ID or an error: one that is already taken is refused, and does not get a number at the end.
Make a guest mode toggle, and keep its entity ID for the steps after it:
action: input_boolean.create
data:
name: "Guest mode"
input_boolean_id: guest_mode
initial: false
response_variable: created
The new input boolean's entity ID is then in {{ created.entity_id }}.
Delete an input boolean
Deletes one or more input boolean helpers.
The other half of Create an input boolean: the script that made a toggle cleans it up again. It works on any input boolean made in the UI as well, disabled ones included.
How to use it
- Open the automation or script that should do the cleaning up, and select Add action.
- Search for delete an input boolean, and select Input boolean: Delete an input boolean 👻.
- Under Entity ID, choose the input booleans to delete.
- Select Save.
Just want to see it work? Try this action opens it in your Home Assistant, ready to run once. Mind that it really deletes.

| Action properties | |
|---|---|
| Action | Input boolean: Delete an input boolean 👻 |
| Action name | input_boolean.delete |
| Action targets | No targets |
| Action response | No response |
| Spook's influence | Newly added action |
| Tools | Try this action |
| Action data parameters | |||
|---|---|---|---|
| Attribute | Type | Required | Default / Example |
entity_id | string | list of strings | Yes | input_boolean.guest_mode |
Remove the guest mode toggle again:
action: input_boolean.delete
data:
entity_id: input_boolean.guest_mode
- Input booleans set up in YAML can only be removed from the YAML. Asking for one is an error.
- Everything in the list is checked first: if one of them cannot be deleted, none of them are.
Turn on for
Turns input booleans on for a while, and turns them back off when the time is up. Spook stores when each one is due back, so a restart of Home Assistant in between does not stop that.
It is Turn on for, with the same rules, for input booleans only. Named outright, anything that is not a input boolean is refused with an error. Picked up through an area, a device, a floor, a label or a group, it is passed over.
How to use it
- Open the automation or script that should do this, and select Add action.
- Search for turn on for, and select Input boolean: Turn on for 👻.
- Under Targets, choose the input booleans.
- Set Duration to how long they should stay on, like
00:15:00for fifteen minutes. - Select Save.
Just want to see it work? Try this action opens it in your Home Assistant, ready to run once.
| Action properties | |
|---|---|
| Action | Input boolean: Turn on for 👻 |
| Action name | input_boolean.turn_on_for |
| Action targets | Yes, input_boolean entities |
| Action response | No response |
| Spook's influence | Newly added action |
| Tools | Try this action |
| Action data parameters | |||
|---|---|---|---|
| Attribute | Type | Required | Default / Example |
duration | string | Yes | 00:15:00 |
Guest mode, for the evening:
action: input_boolean.turn_on_for
target:
entity_id: input_boolean.guest_mode
data:
duration: "04:00:00"
- The rules of Turn on for apply: only something plainly
onoroffis held. Something already on is left alone, and turning it off yourself ends the hold.
Turn off for
Turns input booleans off for a while, and turns them back on when the time is up. Spook stores when each one is due back, so a restart of Home Assistant in between does not stop that.
It is Turn off for, with the same rules, for input booleans only. Named outright, anything that is not a input boolean is refused with an error. Picked up through an area, a device, a floor, a label or a group, it is passed over.
How to use it
- Open the automation or script that should do this, and select Add action.
- Search for turn off for, and select Input boolean: Turn off for 👻.
- Under Targets, choose the input booleans.
- Set Duration to how long they should stay off, like
00:30:00for half an hour. - Select Save.
Just want to see it work? Try this action opens it in your Home Assistant, ready to run once.
| Action properties | |
|---|---|
| Action | Input boolean: Turn off for 👻 |
| Action name | input_boolean.turn_off_for |
| Action targets | Yes, input_boolean entities |
| Action response | No response |
| Spook's influence | Newly added action |
| Tools | Try this action |
| Action data parameters | |||
|---|---|---|---|
| Attribute | Type | Required | Default / Example |
duration | string | Yes | 00:30:00 |
Notifications, off for an hour:
action: input_boolean.turn_off_for
target:
entity_id: input_boolean.notifications
data:
duration: "01:00:00"
- The rules of Turn off for apply: only something plainly
onoroffis held. Something already off is left alone, and turning it on yourself ends the hold.
Use cases
What people use this for:
- Let a script make the flag it needs, and clean it up again afterwards, so the helpers page only has toggles you actually use.
Missing something here?
An action, an entity or a repair this integration should have? Say so. Stuck, or found a bug? There is help.
Humidifier
Spook adds actions that turn the target humidity of a humidifier in Home Assistant up or down a step, without working out the new value yourself, and that turn a humidifier on or off for a while.
Input button
Spook adds actions to create and delete input button helpers in Home Assistant from your automations and scripts, without a trip to the helper settings.


