Skip to main content
Glama
RomanovVIII

ST67 Home Assistant MCP

by RomanovVIII

Apply a reviewed Lovelace card edit

ha_lovelace_apply
Destructive

Apply approved preview to update a Home Assistant Lovelace dashboard after verifying version and preview hash. Re-check the whole dashboard before saving to avoid concurrent edit overwrites.

Instructions

WRITE: apply the exact operations from a fresh, separately approved preview. Requires expectedVersion, expectedPreviewHash and acknowledgeNonAtomicSave=true. Rechecks the WHOLE dashboard before saving and verifies full readback. Home Assistant saves the ENTIRE dashboard and has NO atomic CAS: another editor can race between check and write. Pause other editors. No automatic retry or rollback. Never use to evade an approval rejection; this new write requires its own review.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
cardPathYes
dashboardYes
operationsYes
expectedVersionYes
expectedPreviewHashYes
acknowledgeNonAtomicSaveYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.2.0

TDQS

A4.9/5.0
Behavior5/5

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

Annotations only say readOnly=false and destructiveHint=true, but the description goes far beyond that: it discloses non-atomic save behavior, whole-dashboard rechecking, full readback verification, lack of retry/rollback, and the race risk with other editors. This is exemplary behavioral disclosure for a destructive write tool.

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?

Every sentence carries operational weight: action type, prerequisites, verification behavior, concurrency hazard, pause instruction, and anti-abuse rule. The critical 'WRITE' signal is front-loaded, and there is no filler or repetition of schema details.

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

Completeness5/5

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

For a destructive, non-idempotent tool with no output schema and minimal annotations, the description fully covers the essential context: what it does, what it requires, what can go wrong, how to mitigate risk, and when not to call it. Nothing needed for safe invocation is missing.

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

Parameters4/5

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

Schema description coverage is 0%, so the description must compensate for missing parameter explanations. It explains the meaning and purpose of expectedVersion, expectedPreviewHash, and acknowledgeNonAtomicSave=true, and why they matter for safety. It does not elaborate on cardPath, dashboard, or operations, but those are reasonably clear from the schema structure itself.

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 begins with 'WRITE: apply the exact operations from a fresh, separately approved preview,' naming a specific verb, resource, and workflow stage. It clearly distinguishes this tool from ha_lovelace_preview by focusing on applying, not creating, a reviewed edit.

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

Usage Guidelines5/5

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

It explicitly states the prerequisites (expectedVersion, expectedPreviewHash, acknowledgeNonAtomicSave=true), warns to pause other editors due to race conditions, and instructs never to use it to evade an approval rejection. This gives the agent both when-to-use and when-not-to-use guidance.

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