Remove Script
ha_config_remove_scriptDelete a Home Assistant script created via the UI. Scripts defined in YAML files cannot be removed through the API; edit those configuration files directly.
Instructions
Delete a Home Assistant script.
EXAMPLE: ha_config_remove_script("old_script")
Only scripts created via the Home Assistant UI can be deleted. Scripts defined in YAML configuration files (scripts.yaml or configuration.yaml) cannot be deleted through the API and return a 405 Method Not Allowed error; edit the configuration file directly instead.
WARNING: Deleting a script that is used by automations may cause those automations to fail.
If a Claude Desktop user gets a 4-minute timeout with no result on this call, read the target back before repeating it, and tell them to wait a few seconds before clicking the manual-approve button, as clicking it too quickly is known to cause hangs in Claude Desktop. This workaround is specific to Claude Desktop.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| wait | No | Wait for script to be fully removed before returning. | |
| script_id | Yes | Script identifier to delete — bare storage key ('old_script') or entity_id form ('script.old_script'); a leading 'script.' prefix is stripped before lookup. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||