Input button
The input button helper in Home Assistant is a button to press, from a dashboard or from automations. It has no on or off, only the moment it was last pressed, which makes it a trigger you can put on a dashboard.
Spook adds actions to the input button integration to create and delete these helpers from automations and scripts.
Actions
Spook adds two actions for input buttons. You find them wherever you add an action, marked with a 👻.
Create an input button
Creates a new input button helper, the same as adding one on the helpers page.
Some buttons are only needed for a while. A "the guests have left" button during a party, a "done" button for a chore that only exists this week. Made by hand, it stays on the helpers page forever. Made with this action, the script makes it when it is needed, and deletes it when it is done.
How to use it
- Open the automation or script that should make the button, and select Add action.
- Search for create an input button, and select Input button: Create an input button 👻.
- Fill in Name, like
Doorbell. - Optionally, set Input button entity ID to pick the entity ID yourself, 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 button: Create an input button 👻 |
| Action name | input_button.create |
| Action targets | No targets |
| Action response | Optional, the entity_id of the new input button |
| Spook's influence | Newly added action |
| Tools | Try this action |
| Action data parameters | |||
|---|---|---|---|
| Attribute | Type | Required | Default / Example |
name | string | Yes | Doorbell |
input_button_id | string | No | doorbell |
icon | string | No | mdi:doorbell |
Without an input_button_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_button_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 doorbell button, and keep its entity ID for the steps after it:
action: input_button.create
data:
name: "Doorbell"
input_button_id: doorbell
response_variable: created
The new input button's entity ID is then in {{ created.entity_id }}.
Delete an input button
Deletes one or more input button helpers.
The other half of Create an input button: the script that made a button cleans it up again. It works on any input button 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 button, and select Input button: Delete an input button 👻.
- Under Entity ID, choose the input buttons 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 button: Delete an input button 👻 |
| Action name | input_button.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_button.doorbell |
Remove the doorbell button again:
action: input_button.delete
data:
entity_id: input_button.doorbell
- Input buttons 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.
Use cases
What people use this for:
- Let a script make the button it needs, and clean it up again afterwards, so the helpers page only has buttons 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.
Input boolean
Spook adds actions to create and delete input boolean (toggle) helpers in Home Assistant from your automations and scripts, and to turn them on or off for a while.
Input datetime
Spook adds actions to create and delete input datetime helpers in Home Assistant from your automations and scripts, without a trip to the helper settings.


