Skip to main content
Glama

Get entity state

entities_get_entity
Read-onlyIdempotent

Get the current state and attributes of one Home Assistant entity to inspect its value before or after an action. Use for single-entity checks.

Instructions

Get the full state and attributes of a single entity.

Calls ha.get_state(entity_id), a single HTTP GET to /api/states/<entity_id>; the response includes state, attributes, last_changed and last_updated as reported by Home Assistant.

Use when: inspecting one entity's current value and attributes before or after an action. Not for: many entities at once — use entities_list_entities or snapshot_get_snapshot. Returns: dict with entity_id, state, attributes, last_changed, last_updated, context.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
entity_idYesFull entity ID to read, e.g. 'light.kitchen'.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.25.1
    • addedInput schema / properties / entity_id / description
      Added value: +"Full entity ID to read, e.g. 'light.kitchen'."
  2. First observedv0.3.0

TDQS

A4.4/5.0
Behavior4/5

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

Annotations already declare readOnlyHint, idempotentHint, and non-destructive, so the safety profile is covered. The description adds real value beyond that: the underlying ha.get_state call, the single HTTP GET to /api/states/<entity_id>, and exactly which fields the response reports. It does not cover error behavior for unknown entity IDs, so it is not a full 5.

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

Conciseness4/5

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

Front-loaded purpose, then a compact Use/Not-for/Returns structure that is easy to scan. The implementation sentence about ha.get_state is somewhat redundant with the Returns line but still informative, keeping it just short of a 5.

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?

With annotations covering safety, an output schema covering the return shape, and 100% schema coverage on the sole parameter, the description supplies the remaining context (when to use, alternatives, source endpoint). Nothing an agent needs to call it correctly is missing.

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

Parameters3/5

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

Schema description coverage is 100% and the single entity_id param is already documented with an example ('light.kitchen') in the schema. The description adds no format or validation detail beyond that, so baseline 3 applies.

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?

States a specific verb and resource ('Get the full state and attributes of a single entity') and explicitly scopes to one entity, distinguishing it from list/snapshot siblings in the same sentence block. An agent can select it without opening the schema.

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?

Explicit 'Use when:' (inspecting one entity's value/attributes before or after an action) and 'Not for:' routing to named alternatives (entities_list_entities, snapshot_get_snapshot). Both the positive and negative conditions are stated, leaving nothing to inference.

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

Deploy Server

Other Tools