Skip to main content
Glama
LoganInTX

hass-mcp-extensions

by LoganInTX

create_or_update_automation

Create a new automation or update an existing one by providing a unique ID and full configuration including alias, trigger, action, and mode.

Instructions

Create or overwrite a stored automation config via the HA REST API.

Args: automation_id: Unique string ID for the automation (e.g. a timestamp like "1716300000000"). Use a new value to create; pass the existing ID to update in place. config: Full automation config dict. Must include at least alias, trigger, action, and mode. Do NOT include "id" — it is injected automatically from automation_id.

Returns the raw HA response (usually {"result": "ok"}).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
automation_idYes
configYes
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries full burden. It discloses the tool is write-oriented ('overwrite') and returns a raw response. However, it lacks details on side effects (e.g., no backup before overwrite), error cases, or authentication needs, which are important for safe usage.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is exceptionally concise: a one-line purpose statement, followed by clear Arg definitions, and a return note. Every sentence adds value, no filler.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool has two parameters, no output schema, and no annotations, the description covers the essential aspects: purpose, param semantics, and return type. It lacks error handling or rate limit details, but for a CRUD-like operation this is acceptable.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema has 0% description coverage, so the description fully compensates. For automation_id, it explains the purpose and provides an example. For the config object, it lists required keys ('alias', 'trigger', 'action', 'mode') and explicitly states that 'id' must not be included, adding critical constraints beyond the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description explicitly states the tool creates or overwrites automation configs via the HA REST API. It clearly distinguishes between creating (new automation_id) and updating (existing automation_id), setting it apart from read-only sibling tools like list_automations.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides clear usage guidance: use a new automation_id to create, pass an existing one to update. It also specifies required fields in the config and warns not to include an 'id' field. However, it does not explicitly mention when not to use the tool or compare to alternatives for related operations (e.g., deleting automations).

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/LoganInTX/home-assistant-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server