zigbee2mqtt-mcp
This server lets you administer a Zigbee2MQTT network via MCP:
Read-only monitoring: bridge info, device listing/detail with filtering, health reports, network maps, groups, and logs.
Safe write operations: check OTA updates, permit joining, set device options, rename devices, configure/re-interview, set state, manage groups, bind/unbind, and configure reporting.
Full write operations (require explicit confirmation): remove devices, OTA firmware updates, restart bridge, set bridge options, coordinator check, and Touchlink scan/identify/factory reset.
Write modes (
off,safe,full) gate access to destructive actions.Useful for diagnostics: identifying weak links, low batteries, stale devices, pairing issues, and mesh topology.
Provides tools for administering a Zigbee2MQTT Zigbee bridge, including device management, network health, pairing, binding, reporting, and firmware updates.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@zigbee2mqtt-mcpCheck the health of my Zigbee mesh and list weak links."
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
zigbee2mqtt-mcp
A Model Context Protocol server for administering a Zigbee2MQTT estate.
Most Zigbee integrations already let an assistant turn a light on. This one is for the layer underneath: mesh health, weak links, devices that keep rejoining, stale batteries, firmware updates, pairing, binding, reporting intervals and device options — the things you normally open the Zigbee2MQTT frontend for.
It talks directly to the Zigbee2MQTT MQTT bridge API, so it works regardless of whether you use Home Assistant, Node-RED, openHAB or nothing at all. Tested against Zigbee2MQTT 2.x; several tools depend on bridge endpoints that only exist there, including bridge/health, device/binds/clear and the OTA scheduling topics.
Why this exists
If you already run Home Assistant, your Zigbee devices are exposed there and an assistant can control them. What Home Assistant does not expose is the bridge itself: link quality, mesh topology, interview state, OTA availability, permit_join, device options, bindings and reporting configuration. This server fills exactly that gap.
Related MCP server: music-assistant-mcp-plus
Design
No database. Zigbee2MQTT publishes its bridge topics as retained messages, so a fresh subscription yields a complete picture in a few hundred milliseconds. The server keeps only the latest payload per topic in memory.
No daemon. Pure stdio. It starts and dies with the MCP session.
Correlated requests. Every
bridge/request/*carries atransactionid and is matched to itsbridge/response/*, so concurrent calls cannot cross wires.Tiered writes. Destructive operations are gated behind a write mode and an explicit
confirmargument.
Install
Requires Node.js 22 or newer and network access to the MQTT broker that Zigbee2MQTT uses.
npx zigbee2mqtt-mcpVS Code / GitHub Copilot
Add to your MCP configuration:
{
"servers": {
"zigbee2mqtt": {
"command": "npx",
"args": ["-y", "zigbee2mqtt-mcp"],
"env": {
"Z2M_MQTT_URL": "mqtt://192.168.1.10:1883",
"Z2M_MQTT_USERNAME": "mqtt",
"Z2M_MQTT_PASSWORD": "${input:z2mPassword}"
}
}
}
}Claude Desktop
{
"mcpServers": {
"zigbee2mqtt": {
"command": "npx",
"args": ["-y", "zigbee2mqtt-mcp"],
"env": {
"Z2M_MQTT_URL": "mqtt://192.168.1.10:1883"
}
}
}
}Point
Z2M_MQTT_URLat your MQTT broker, not at the Zigbee2MQTT frontend port. If Zigbee2MQTT'sconfiguration.yamlsaysmqtt.server: mqtt://192.168.1.10:1883, use that value verbatim.
Behind a corporate npm proxy? If
npm config get registryis nothttps://registry.npmjs.org/, your proxy's upstream feed may not carry this package. Add an explicit override to the args rather than changing your global registry:"args": ["-y", "--registry", "https://registry.npmjs.org/", "zigbee2mqtt-mcp"]
Configuration
Variable | Default | Purpose |
| required | Broker URL. |
| – | Broker credentials |
|
| Must match |
|
| Override if your broker requires a fixed client ID |
|
|
|
|
| Diagnostics on stderr |
|
| Link quality below this is flagged |
|
| Battery percentage below this is flagged |
|
| Hours of silence before a device is stale |
|
| Broker connect timeout |
|
| Default bridge request timeout |
|
| Set |
| – | Paths to TLS material |
Write modes
Tools above the active tier are not registered at all, so a model cannot reach for them.
Mode | Exposes |
| Read-only tools |
| Default. Read plus non-destructive writes: pairing, options, rename, configure, interview, binding, reporting, groups, state |
| Everything, including device removal, OTA flashing, Touchlink and bridge restart |
Irreversible tools (z2m_remove_device, z2m_ota_update, z2m_touchlink, z2m_restart_bridge, z2m_set_bridge_options) additionally require confirm: true on every call. Three safe tools reduce state rather than only adding to it, so they are annotated destructive: z2m_rename_device, z2m_manage_group and z2m_bind. Their reducing actions also require confirm: true — z2m_manage_group (remove, remove_all_members) and z2m_bind (clear). z2m_rename_device is annotated destructive because it breaks anything referencing the old name, but stays unconfirmed since renaming back restores it.
Every tool also advertises MCP tool annotations so a client can decide what may run without prompting:
Annotation | Meaning here |
| The nine read tools. They never change the network. |
|
|
| True where repeating the call has no additional effect |
| Always — every tool reaches a live Zigbee network |
Annotations describe the tool, not the tier: a safe tool can still be destructive. The tier decides what is registered, the annotation tells the client what to ask about.
Opt in to the destructive tier only when you want it:
"env": { "Z2M_WRITE_MODE": "full" }Tools
Read
Tool | Purpose |
| Broker reachability, TLS posture and cached message counts — reports instead of throwing, even when nothing is configured yet |
| Version, coordinator, channel, PAN ID, permit_join, restart_required, runtime stats |
| Filter and sort devices by type, availability, link quality, battery, pending update |
| Exposes, settable options, endpoints, bindings, configured reportings, current state |
| Whole-estate audit in one call |
| Mesh topology with parent, depth, link quality, orphan detection |
| Groups, members and scenes |
| Bridge logs and lifecycle events, buffered or watched live |
| Routers missing from the coordinator's memory (Texas Instruments adapters only) |
Safe writes
z2m_check_updates, z2m_permit_join, z2m_set_device_options, z2m_rename_device, z2m_configure_device, z2m_interview_device, z2m_set_state, z2m_manage_group, z2m_bind, z2m_configure_reporting
Full writes
z2m_remove_device, z2m_ota_update, z2m_restart_bridge, z2m_set_bridge_options, z2m_touchlink
Data availability caveats
Some fields depend on your Zigbee2MQTT configuration. The server detects what is available and tells you rather than silently returning nothing.
Field | Requires | If missing |
|
| Staleness checks are skipped and a hint is returned |
|
| Offline detection is skipped and a hint is returned |
| Live device traffic — Zigbee2MQTT does not retain device state topics | Pass |
| An adapter that supports coordinator backups (TI zStack, Silicon Labs EmberZNet; not deCONZ or ZiGate) | Returns an error on unsupported adapters; |
Security notes
The broker URL may carry credentials (
mqtt://user:pass@host). They are redacted everywhere the URL is echoed back to a model or written to a log, and error text from the MQTT client is scrubbed before it leaves the process. Zigbee2MQTT logs its own broker URL at startup, so lines relayed byz2m_get_logsare scrubbed too.safemode can actuate anything on the mesh viaz2m_set_state, including locks, valves and sirens. Useoffif that matters.z2m_permit_joinopens the network to any nearby Zigbee device for the duration of the window. It is insafebecause it is routine and reversible, but it is a security boundary.
Example prompts
"Is my Zigbee network healthy?"
"Which devices have the weakest signal?"
"Which batteries need replacing?"
"Any firmware updates available?"
"Open the network for pairing via the kitchen router for two minutes."
"This sensor stopped reporting temperature — fix it."
"Bind the hallway remote to the hallway light so it works if the bridge is down."
Development
npm install
npm run build
npm run watch
# Unit tests. No broker required; they run on every push across Node 22 and 24.
npm test
# Manual smoke test against a real instance
Z2M_MQTT_URL=mqtt://192.168.1.10:1883 node scripts/smoke.mjs
Z2M_MQTT_URL=mqtt://192.168.1.10:1883 node scripts/smoke.mjs z2m_list_devices '{"only_problems":true}'
# Sequential read-after-write test. Renames a device and creates a group, then
# restores both, including on failure. Set Z2M_TEST_DEVICE to pick the device,
# or ROUNDTRIP_GROUPS_ONLY=1 to skip the rename.
Z2M_MQTT_URL=mqtt://192.168.1.10:1883 node scripts/roundtrip.mjsNote that an MCP server may receive requests concurrently. When testing ordering,
await each response before sending the next, as roundtrip.mjs does — piping
several requests at once will produce misleading results.
The unit tests cover health classification, capability detection, topic routing,
write-mode gating and configuration parsing. They are broker-free by design, so
anything that needs a live mesh belongs in scripts/ instead.
A passing suite only proves the tests ran, so scripts/mutate.mjs breaks the
source one change at a time and checks the suite notices each one:
node scripts/mutate.mjs # every mutant
node scripts/mutate.mjs redact # only mutants whose name matchesA surviving mutant marks behaviour nothing actually tests, and exits non-zero. Add a mutant alongside any fix worth keeping fixed.
Releases are tag-driven: npm version <patch|minor|major> then
git push --follow-tags. CI publishes to npm with provenance, rewrites
server.json's version from the tag and publishes to the MCP Registry, then
creates the GitHub release. The version committed in server.json is therefore
not authoritative — the tag is.
Safety
This server can remove devices from your network and flash firmware. Both are irreversible and OTA failures can brick hardware. Those tools live in the full tier, which is not enabled by default — you must opt in with Z2M_WRITE_MODE=full. Broker credentials are read from the environment and never logged.
Status
Early release. Developed and tested against a 50-device EmberZNet estate on Zigbee2MQTT 2.12.x. Other adapters (Texas Instruments, deCONZ/ConBee, zStack), TLS and WebSocket brokers, and large estates are unverified. Bug reports and pull requests are very welcome — please include your adapter type and Zigbee2MQTT version from z2m_bridge_info.
License
MIT
Available Tools
17 toolsz2m_bindA
Bind or unbind clusters between two devices, or between a device and a group. Binding lets a remote control a light directly over Zigbee without a round trip through the coordinator, so it keeps working even if the bridge is down. Reversible with action='unbind'; action='clear' removes all binds from the source device at once. Append /ENDPOINT to target a specific endpoint, e.g. 'my_remote/left' — check z2m_get_device endpoints first. Both devices must be awake.
| Name | Required | Description | Default |
|---|---|---|---|
| to | No | Target device or group. Not needed for action=clear. | |
| from | Yes | Source device, optionally with /ENDPOINT. | |
| action | Yes | ||
| clusters | No | Clusters to bind, e.g. ['genOnOff','genLevelCtrl']. Omit to bind all supported clusters. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Beyond annotations (readOnlyHint=false, destructiveHint=false), the description discloses critical behavioral traits: the effect of each action (unbind reverses, clear removes all binds at once), the endpoint syntax, and the requirement that both devices must be awake. This gives the agent a solid understanding of side effects and preconditions, exceeding what annotations provide.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is five sentences long, but every sentence carries useful information: purpose, benefit, action semantics, endpoint guidance, and a precondition. It is front-loaded with the core purpose and then adds relevant details. Slightly dense, yet no sentence is wasted, so it earns a 4 rather than 5.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a mutation tool with no output schema, this description is exceptionally complete. It covers all actions, endpoint handling, prerequisites, and the practical impact of binding (works without coordinator). The agent has enough information to invoke the tool correctly and anticipate results, even without output schema details.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
With 75% schema coverage, the description must enrich parameter meaning. It does so by explaining the /ENDPOINT syntax for 'from' with an example, noting that 'to' is unnecessary for clear, and clarifying that action='clear' has a bulk effect. This adds value over the bare schema, though it doesn't elaborate on cluster name formats beyond the schema's example.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description opens with a specific verb-resource pairing: 'Bind or unbind clusters between two devices, or between a device and a group.' This clearly distinguishes the tool from siblings like z2m_manage_group or z2m_configure_reporting, which handle different operations. It also explains the underlying purpose of binding, making the tool's role unmistakable.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides strong usage context: it explains the benefit of binding (works even if the bridge is down), gives a prerequisite ('check z2m_get_device endpoints first'), and notes device wakefulness. However, it does not explicitly name alternative tools or state when not to use binding, so it falls short of a 5. The context is clear enough for an agent to decide when to invoke this tool.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
z2m_bridge_infoARead-onlyIdempotent
Get Zigbee2MQTT bridge status: version, coordinator type and firmware, Zigbee channel and PAN ID, permit_join state, log level, whether a restart is required, and host OS/memory. Read-only. Start here to understand the estate, then use z2m_health_report for problems or z2m_list_devices for individual devices. Returns a JSON object; set include_config only if you need the full Zigbee2MQTT configuration, which is large.
| Name | Required | Description | Default |
|---|---|---|---|
| include_config | No | Include the full Zigbee2MQTT configuration (large). Default false. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already state readOnlyHint=true, idempotentHint=true, and destructiveHint=false. The description reinforces this with 'Read-only' and adds useful context about the return format (JSON object) and the large size of the full configuration when include_config is true. This goes slightly beyond the annotations, though it doesn't disclose any safety-relevant edge cases.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is three sentences, front-loaded with the purpose, then usage guidance, then parameter caution. Every sentence carries necessary information with no redundancy or fluff.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a simple read-only status tool with one optional parameter and no output schema, the description is complete: it lists return fields, provides usage context, differentiates from siblings, and warns about the large config. No important information is missing.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100% for the single parameter, so the schema already fully explains include_config. The description adds the hint to use it 'only if you need' the full config, which is mildly helpful but does not add substantive semantic meaning beyond the schema.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description uses a specific verb ('Get') and resource ('Zigbee2MQTT bridge status'), enumerating the exact attributes returned (version, coordinator, channel, PAN ID, etc.). It clearly distinguishes itself from siblings by positioning itself as the starting point and explicitly naming alternatives for different tasks.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides explicit when-to-use guidance: 'Start here to understand the estate' and tells the agent to use z2m_health_report for problems or z2m_list_devices for individual devices. It also advises to 'set include_config only if you need the full configuration', giving clear conditional usage.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
z2m_check_updatesAIdempotent
Actively query devices for available OTA firmware updates. Changes no configuration, but it does put real traffic on the Zigbee network and can take a minute per device. Without arguments it checks every mains-powered router. Prefer z2m_health_report for a passive answer at no network cost, and use this only when you need a fresh check. Follow with z2m_ota_update to actually flash.
| Name | Required | Description | Default |
|---|---|---|---|
| device | No | Check a single device. Omit to check all mains-powered devices. | |
| timeout_ms | No | Per-device timeout. Default 60000. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Discloses real network traffic, per-device time cost, and default behavior (checks all mains-powered routers when no arguments). This goes beyond the annotations by adding practical side-effect context, without contradicting readOnlyHint/idempotentHint/destructiveHint.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Four sentences, each with clear purpose: main action, side effect caveat, default behavior, and usage/alternative guidance. No wasted words, front-loaded with the core purpose.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The description fully covers when to use, what happens, and what to do next. No output schema is needed for this simple action, and annotations cover safety. The combination of description, schema, and annotations gives the agent everything required for correct invocation.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, with parameter descriptions already explaining the device field and timeout. The description's note about omitting arguments checks all mains-powered devices adds no new semantics beyond what the schema provides, so baseline 3 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description opens with 'Actively query devices for available OTA firmware updates,' which is a specific verb+resource combination. It also distinguishes itself from sibling tools by contrasting with the passive z2m_health_report and by mentioning follow-up with z2m_ota_update.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Explicit guidance: 'Prefer z2m_health_report for a passive answer' and 'use this only when you need a fresh check.' It also tells the agent to follow with z2m_ota_update to actually flash, giving clear alternatives and when-to-use context.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
z2m_configure_deviceAIdempotent
Re-run a device's configuration routine (bindings and attribute reporting). Use when a device stopped reporting values. Battery devices must be woken immediately before calling this, or it fails after a timeout. Use z2m_interview_device instead when Zigbee2MQTT does not know the device's capabilities at all, and z2m_configure_reporting to change one specific attribute rather than re-running everything.
| Name | Required | Description | Default |
|---|---|---|---|
| device | Yes | Device friendly_name or ieee_address. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Adds significant behavioral context beyond annotations: the battery wake requirement and the timeout failure mode. The description aligns with annotations (readOnlyHint=false, idempotentHint=true) without contradiction.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Three sentences, each serving a distinct purpose: defining the action, specifying when to use, and pointing to alternatives. No filler or redundancy.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
With a single parameter and no output schema, the description covers purpose, usage trigger, prerequisites, and alternatives. It is complete for an agent to select and invoke this tool correctly.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100% for the 'device' parameter, with a clear description in the schema. The tool description does not add extra parameter-level detail, so the baseline 3 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool re-runs a device's configuration routine, specifically bindings and attribute reporting. It also distinguishes from sibling tools by naming z2m_interview_device and z2m_configure_reporting as alternatives.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Provides explicit when-to-use guidance: 'Use when a device stopped reporting values.' It also gives exclusions and alternatives, plus a critical prerequisite for battery devices. This leaves no ambiguity about tool selection.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
z2m_configure_reportingAIdempotent
Configure how often a device reports an attribute. Tightening intervals improves responsiveness; loosening them saves battery. Set maximum_report_interval to 65535 to disable reporting. Battery devices must be woken immediately before calling this, and not all devices support the command. Use z2m_get_device to see existing configured_reportings, and z2m_configure_device to re-run the whole default configuration instead of one attribute.
| Name | Required | Description | Default |
|---|---|---|---|
| device | Yes | Device friendly_name or ieee_address. | |
| cluster | Yes | Cluster name, e.g. 'genLevelCtrl'. | |
| endpoint | No | Endpoint ID. Default 1. | |
| attribute | Yes | Attribute name, e.g. 'currentLevel'. | |
| reportable_change | No | Minimum change worth reporting, in the attribute's unit. | |
| maximum_report_interval | Yes | Seconds. 65535 disables reporting. | |
| minimum_report_interval | Yes | Seconds. 0 means report on every change. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Adds significant context beyond annotations: battery devices must be woken immediately, not all devices support the command, and setting maximum_report_interval to 65535 disables reporting. It also explains the trade-off between responsiveness and battery life. No contradiction with annotations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Five sentences, each delivering specific value: purpose, motivation, special value, device caveat, and alternatives. Front-loaded with the core verb and resource, with no wasted words.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Covers key operational constraints (battery wake-up, device support, alternatives) and the schema documents all parameters. With no output schema, the description does not need to explain return values. It is complete for a tool of this complexity.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100% with all parameters described, so baseline is 3. The description does not add meaning beyond the schema—it merely reiterates the 65535 behavior already in the schema's maximum_report_interval description.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's function with a specific verb and resource: 'Configure how often a device reports an attribute.' It also distinguishes itself from sibling tool z2m_configure_device by explicitly mentioning 'one attribute' versus 'whole default configuration'.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Explicitly names alternatives: 'Use z2m_get_device to see existing configured_reportings, and z2m_configure_device to re-run the whole default configuration instead of one attribute.' Also provides practical when-to-use guidance with battery wake-up and device support caveats.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
z2m_get_deviceARead-onlyIdempotent
Get full detail for one device: current state, exposed properties, configurable device options with their schema, endpoints, bindings and configured reportings. Read-only. Call this before z2m_set_device_options, z2m_bind or z2m_configure_reporting to discover valid values. Use z2m_list_devices instead when you want many devices or do not know the exact name.
| Name | Required | Description | Default |
|---|---|---|---|
| device | Yes | Device friendly_name or ieee_address. | |
| include_raw | No | Include the raw exposes/options definitions (verbose). Default false. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint and idempotentHint, so the 'Read-only.' addition is somewhat redundant. However, the description adds value by listing the internal detail categories returned, which is behavioral context beyond the annotations. No contradiction.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Four sentences, all densely informative with no fluff. Each sentence serves a purpose: what it does, safety, prerequisites, and when to use an alternative. 'Read-only' is brief but not padding.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Even without an output schema, the description lists the key return categories and clarifies the tool's role as a discovery step before write operations. This is sufficient for an agent to decide when to call it and what to expect.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100% for both parameters, and the schema clearly describes 'device' (friendly_name or ieee_address) and 'include_raw'. The description adds no additional parameter semantics beyond what the schema provides, so baseline 3 applies.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description uses a specific verb and resource ('Get full detail for one device') and enumerates exactly what is returned (state, properties, options, endpoints, bindings, reportings). It distinguishes from siblings by explicitly contrasting with z2m_list_devices and stating this is for a single device with exact name.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Provides explicit when-to-use and when-not-to-use guidance: 'Call this before z2m_set_device_options, z2m_bind or z2m_configure_reporting' and 'Use z2m_list_devices instead when you want many devices or do not know the exact name.' No ambiguity.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
z2m_get_logsARead-onlyIdempotent
Read Zigbee2MQTT bridge logs and lifecycle events (device_joined, device_interview, device_leave, device_announce). Read-only. Returns buffered history by default; watch_seconds instead blocks for that many seconds collecting new lines. Logs are only captured while this server is connected, so history may be empty on a fresh start — use watch_seconds then. Use to diagnose pairing failures and rejoin loops; prefer z2m_health_report to find which devices are affected in the first place.
| Name | Required | Description | Default |
|---|---|---|---|
| level | No | Minimum severity. Note: Zigbee2MQTT never publishes debug lines to MQTT. | |
| limit | No | Maximum lines to return. Default 100. | |
| contains | No | Only lines containing this substring (case-insensitive). | |
| watch_seconds | No | Collect new lines live for this many seconds instead of returning buffered history. Max 120. | |
| include_events | No | Include bridge lifecycle events. Default true. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Beyond the annotations (readOnlyHint etc.), the description reveals that logs are only captured while the server is connected, meaning history may be empty on fresh start. It also explains the default buffered behavior and how watch_seconds changes collection mode. No contradiction with annotations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Three sentences, each serving a purpose: definition, behavior explanation, and usage guidance. It is front-loaded with the core action and efficiently packs essential context without redundancy.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The description is complete for a read-only log tool: it explains behavior, edge cases (fresh start), and recommended use cases. Sibling tools and annotations provide additional context, and the absence of an output schema is acceptable here since the tool's return values are self-explanatory log lines.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, so parameters are already well-documented. The description adds value by clarifying the default mode (buffered history) and the relationship between watch_seconds and the default behavior, enhancing understanding beyond the schema. It also hints at the level parameter's limitation (no debug lines) which is echoed in the schema.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool reads Zigbee2MQTT bridge logs and lifecycle events, listing specific event types. It distinguishes itself from siblings like z2m_health_report by focusing on log retrieval rather than device status. The verb 'Read' and resource 'bridge logs' are specific and unambiguous.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Explicitly says to use for diagnosing pairing failures and rejoin loops, and recommends an alternative (z2m_health_report) for finding affected devices. This provides clear when-to-use and when-not-to-use guidance, plus an alternative tool suggestion.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
z2m_health_reportARead-onlyIdempotent
Audit the whole Zigbee estate in one call and return everything that needs attention: offline devices, weak links, stale devices, low batteries, failed or pending interviews, unsupported devices, disabled devices, pending OTA updates, and devices that keep rejoining or changing network address. Read-only and generates no Zigbee traffic, so prefer it over z2m_check_updates and z2m_network_map for routine checks. Use this to answer 'is my Zigbee network healthy?'. Returns {bridge, totals, capabilities, issues, hints}; an empty issues object means nothing is wrong. Note that collect_seconds makes the call wait for that many seconds before answering.
| Name | Required | Description | Default |
|---|---|---|---|
| collect_seconds | No | Listen for live device traffic for this many seconds before answering, to populate linkquality, battery and OTA fields that Zigbee2MQTT does not publish as retained messages. Max 120. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Beyond the readOnlyHint and idempotentHint annotations, the description adds valuable behavioral context: it generates no Zigbee traffic, returns a structured object with specific keys, and explains that an empty issues object means nothing is wrong. It also notes that collect_seconds causes the call to wait, which is a non-obvious behavior.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is information-dense and well-organized, but slightly longer than necessary. The note about collect_seconds duplicates the schema, and the list of issue types, while helpful, could be more compact. Still, every section serves a purpose.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool's complexity and absence of an output schema, the description provides a solid high-level overview: return keys, empty issues semantics, and parameter behavior. However, it does not explain the structure of sub-objects like bridge, totals, capabilities, or hints, leaving some ambiguity for an agent interpreting the result.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, so the baseline is 3. The description mentions collect_seconds but merely restates the schema's explanation about waiting; it adds no new semantic information. Thus it does not elevate the score.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's purpose: audit the entire Zigbee estate and return all attention-worthy issues, enumerating specific categories. It also differentiates from siblings by explicitly recommending this tool over z2m_check_updates and z2m_network_map for routine checks.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description gives explicit use cases (routine checks, answering 'is my Zigbee network healthy?') and names alternatives, but it does not fully clarify when those alternatives should be preferred. This is strong guidance but lacks explicit when-not conditions.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
z2m_interview_deviceAIdempotent
Re-interview a device so Zigbee2MQTT re-reads its endpoints, clusters and basic attributes. The device may be briefly unavailable while this runs, and battery devices must be awake. Useful after a firmware upgrade adds functionality, or to recover a device stuck in a failed interview — check interview_state via z2m_get_device first. Use z2m_configure_device instead when the interview succeeded but reporting stopped working.
| Name | Required | Description | Default |
|---|---|---|---|
| device | Yes | Device friendly_name or ieee_address. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Beyond the annotations (readOnlyHint=false, openWorldHint=true, idempotentHint=true, destructiveHint=false), the description discloses that the device may be briefly unavailable and that battery devices must be awake. It also details what internally happens (re-reads endpoints, clusters, basic attributes), adding valuable behavioral context not present in structured data.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is three sentences, front-loaded with the core purpose, then caveats, then use cases. Every sentence earns its place with no redundancy or filler, making it highly efficient.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a single-parameter tool with no output schema, the description covers purpose, behavioral effects, prerequisites, alternatives, and a recovery scenario. Combined with the annotations, it gives an agent everything necessary to decide when and how to invoke the tool correctly.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The schema fully describes the single parameter 'device' with a clear description ('Device friendly_name or ieee_address.'), so schema coverage is 100%. The description does not add parameter-specific semantics beyond what the schema provides, but the usage guidance (check interview_state) is helpful context.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description uses a specific verb 're-interview' with a clear resource 'device', explains the action (re-reads endpoints, clusters, basic attributes), and explicitly distinguishes from sibling tool z2m_configure_device. It is unmistakable what this tool does.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
It provides explicit when-to-use scenarios (firmware upgrade, stuck interview), a prerequisite (check interview_state via z2m_get_device), and an alternative (z2m_configure_device when reporting stopped). This is clear guidance on selection and context.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
z2m_list_devicesARead-onlyIdempotent
List Zigbee devices with administrative detail: type, model, vendor, power source, link quality, battery, availability, last_seen, interview state and pending OTA updates. Read-only, though collect_seconds will wait before answering. Use this to answer 'which devices are offline' or 'which have the weakest signal'. Prefer z2m_health_report for a prioritised summary of everything wrong at once, and z2m_get_device when you need one device's exposes, options or bindings. Returns {total, returned, capabilities, devices[]}.
| Name | Required | Description | Default |
|---|---|---|---|
| type | No | Filter by Zigbee device type. | |
| limit | No | Maximum number of devices to return. | |
| search | No | Case-insensitive substring match on name, model, vendor or description. | |
| sort_by | No | Default friendly_name. Numeric sorts are ascending, so weakest/lowest first. | |
| has_update | No | Only devices with a pending OTA firmware update. | |
| availability | No | ||
| only_problems | No | Only devices that are offline, disabled, unsupported, mid-interview, weak-signal or low-battery. | |
| collect_seconds | No | Listen for live device traffic for this many seconds before answering, to populate linkquality, battery and OTA fields that Zigbee2MQTT does not publish as retained messages. Max 120. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint=true and destructiveHint=false. The description adds the behavioral nuance that collect_seconds will wait before answering, and notes the tool is read-only despite the waiting. This goes beyond the annotations by explaining the side effect of a parameter, but it doesn't delve into other behaviors like pagination or failure modes. Given annotations cover safety, this is adequate.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is concise and front-loaded, starting with the core action and resource. Each sentence serves a purpose: the field list, the read-only note, the use cases, the alternative guidance, and the return format. No filler words; every sentence earns its place.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The description includes the return structure '{total, returned, capabilities, devices[]}', which is essential given no output schema exists. It also covers common user intents (offline devices, weak signal) and distinguishes from sibling tools. While it doesn't explain every parameter, the schema handles that. This is reasonably complete for a list tool.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is high (88%) with descriptions for most parameters. The description adds value by explaining that collect_seconds waits to populate live fields like linkquality, battery, and OTA, and hints at the 'weakest signal' use case which aligns with sort_by and only_problems. It doesn't repeat each schema description but enriches the meaning of key parameters.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description immediately states the tool lists Zigbee devices with administrative detail and enumerates the specific fields (type, model, vendor, power source, link quality, battery, availability, last_seen, interview state, OTA updates). It also distinguishes itself from siblings by naming z2m_health_report and z2m_get_device as alternatives, making its unique purpose clear.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description gives explicit use cases: 'Use this to answer which devices are offline or which have the weakest signal'. It also provides clear alternatives with specific conditions: 'Prefer z2m_health_report for a prioritised summary of everything wrong at once, and z2m_get_device when you need one device's exposes, options or bindings.' This is excellent 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.
z2m_list_groupsARead-onlyIdempotent
List Zigbee groups with their members and scenes. Read-only. Use z2m_manage_group to change groups, and z2m_list_devices for individual devices. Returns {total, groups[]}; an empty list means no groups are defined.
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint, idempotentHint, and destructiveHint: false. The description adds context by stating the return format ('Returns {total, groups[]}') and the meaning of an empty list, which enriches the agent's understanding beyond the annotations. No contradictions found.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is three sentences, each with a distinct purpose: what it does, when to use alternatives, and what it returns. It is front-loaded with the primary function and contains no fluff.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given zero parameters, no output schema, and rich annotations, the description fully covers the tool's behavior. It explains the return structure and the 'empty list' case, and provides clear sibling differentiation, making it complete for an agent to select and invoke correctly.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The tool has zero parameters, and schema coverage is 100% (vacuously). Baseline for 0 params is 4. The description adds no parameter-specific details, but none are needed; it appropriately focuses on output semantics.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's function: 'List Zigbee groups with their members and scenes.' It uses a specific verb and resource, and distinguishes itself from siblings by directing to z2m_manage_group for group changes and z2m_list_devices for individual devices.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Explicit usage guidance is provided: 'Use z2m_manage_group to change groups, and z2m_list_devices for individual devices.' This clearly indicates when to use this tool versus the alternatives, covering both modification and device-level queries.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
z2m_manage_groupA
Create or remove groups, rename them, and add or remove device members. Groups let a single Zigbee multicast control many devices, which is far more responsive than commanding each device in turn. Removing a group does not affect the devices themselves, but fails if a member is unreachable unless force is set — with force the device keeps the group membership internally. Use z2m_list_groups to inspect groups first, and z2m_set_state to control a group once created.
| Name | Required | Description | Default |
|---|---|---|---|
| id | No | Optional numeric ID for action=add. | |
| force | No | Force removal even if a member device is unreachable. | |
| group | Yes | Group friendly_name or numeric ID. | |
| action | Yes | ||
| device | No | Device for member actions. Append /ENDPOINT to target an endpoint. | |
| new_name | No | Required for action=rename. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations indicate mutability (readOnlyHint=false) and non-destructive (destructiveHint=false). The description adds valuable behavioral context: removing a group does not affect devices, removal fails if a member is unreachable unless force is set, and with force the device retains membership internally. This goes beyond annotation basics, though it doesn't cover every action's side effects.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is three sentences, front-loaded with the primary actions. Each sentence adds value: the group benefit, the removal caveat, and the workflow. No wasted words, and the structure guides the agent from understanding to action.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The tool has multiple actions and no output schema, but the description provides the core purpose, the critical force-removal edge case, and workflow tips. It omits details like 'new_name is required for rename' and 'device is needed for member actions', but the schema covers those. Given the complexity, the description is sufficiently complete for safe operation.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is high (83%), with descriptions for most parameters. The description adds context for 'force' (removal behavior) and implies the need for 'new_name' (rename) and 'device' (member actions). However, it doesn't systematically explain each parameter, so it meets the baseline but doesn't greatly exceed it.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's function: 'Create or remove groups, rename them, and add or remove device members.' It uses specific verbs and identifies the resource (Zigbee groups), distinguishing it from sibling tools like z2m_list_groups and z2m_set_state by explicitly referencing them.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides direct guidance on when to use this tool versus alternatives: 'Use z2m_list_groups to inspect groups first, and z2m_set_state to control a group once created.' It also explains the benefit of groups (multicast responsiveness), which helps the agent decide when group management is appropriate.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
z2m_network_mapARead-onlyIdempotent
Scan the Zigbee mesh topology and return per-device parent, depth, link quality and route count, plus orphaned or weakly-attached devices. WARNING: the scan makes the network less responsive and can take 10 seconds to several minutes depending on estate size. Run it deliberately, not routinely, and prefer z2m_health_report or z2m_list_devices when you only need per-device link quality. Returns {node_count, link_count, orphans, weak, nodes[]} unless raw is set.
| Name | Required | Description | Default |
|---|---|---|---|
| raw | No | Return the unsummarised graph. Default false. | |
| timeout_ms | No | Scan timeout. Default 180000. | |
| include_routes | No | Include active routes. Slower. Default false. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Beyond the read-only and idempotent annotations, the description discloses non-obvious behavioral traits: the scan reduces network responsiveness and can take 10 seconds to several minutes. It also clarifies the return shape, which is not in the annotations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Three sentences: purpose, performance warning, and usage guidance. Front-loaded with the core action, each sentence adds distinct value, and the structure is easy to scan.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Despite no output schema, the description outlines the return structure and performance characteristics. It covers the main usage caveats and alternatives, making it comprehensive for a complex scanning tool.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, so baseline is 3. The description adds only a minor reference to 'unless raw is set,' which duplicates the schema's raw parameter description. No significant new parameter semantics are provided.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the action (scan mesh topology) and the specific outputs (per-device parent, depth, link quality, route count, orphaned/weak devices). It distinguishes itself from siblings by naming z2m_health_report and z2m_list_devices as alternatives for link quality.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Explicitly states when to use (deliberately, not routinely) and what to prefer instead (z2m_health_report or z2m_list_devices for per-device link quality). Also includes a warning about performance impact, providing clear context for usage.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
z2m_permit_joinAIdempotent
Open or close the network for new devices to join. While open, any nearby Zigbee device may join, so keep the window short and close it with time=0 when finished. Optionally scope joining to a single router, which is the recommended way to pair a device into a specific part of the mesh. Use z2m_bridge_info to see whether joining is currently open.
| Name | Required | Description | Default |
|---|---|---|---|
| time | Yes | Seconds to allow joining. 0 closes the network. Maximum 254. | |
| device | No | Restrict joining to this router's friendly_name, or 'coordinator'. Omit to allow via any router. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
The description discloses an important side effect beyond the annotations: 'While open, any nearby Zigbee device may join, so keep the window short.' This adds behavioral context not captured by readOnlyHint or destructiveHint. It also explains how to close the network and the purpose of router scoping, plus the idempotent nature of the time parameter.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is three sentences long, front-loaded with the core action, followed by a safety warning and a pointer to an alternative. Every sentence earns its place with no redundancy. It is concise and well-structured.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The description is complete for the tool's complexity: it covers what it does, when to use it, safety considerations, how to close it, optional scoping, and how to check current state. With no output schema, the description compensates by providing all necessary context. The schema fills in parameter specifics.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema already provides full descriptions for both parameters (time and device). The description elaborates further by advising to use 0 to close, and by recommending router scoping as 'the recommended way to pair a device into a specific part of the mesh.' This adds contextual meaning beyond the schema, though the schema already covers the basics.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's purpose: 'Open or close the network for new devices to join.' It uses a specific verb and resource, and distinguishes itself from sibling tools like z2m_bridge_info (which checks status) and device-specific tools. The mention of scoping to a single router adds clarity.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description explicitly tells when to use the tool ('Open or close the network'), gives best practices ('keep the window short and close it with time=0 when finished'), and names an alternative for checking state ('Use z2m_bridge_info to see whether joining is currently open'). This provides clear guidance on both usage and alternatives.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
z2m_rename_deviceA
Rename a device's friendly_name. Renaming changes its MQTT topic, so anything referencing the old name (automations, dashboards, scripts) breaks until updated — this is reversible only by renaming back. Set homeassistant_rename to also rename the Home Assistant entity. Use z2m_set_device_options for behaviour changes that do not affect the topic.
| Name | Required | Description | Default |
|---|---|---|---|
| device | Yes | Device friendly_name or ieee_address. | |
| new_name | Yes | New friendly_name. '/' creates folder structure in MQTT. | |
| homeassistant_rename | No | Also update the Home Assistant entity ID. Default false. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Discloses that renaming changes the MQTT topic, breaks automations/dashboards/scripts until updated, and is reversible only by renaming back. This adds significant context beyond the readOnlyHint=false annotation, which only signals a write operation without specifying side effects.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Three sentences: purpose, side effects/reversibility, and alternative tool. Every sentence earns its place with no repetition of annotations or fluff.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a mutation tool with no output schema, the description covers the action, consequences, reversibility, and parameter behavior. Combined with comprehensive schema and annotations, the agent has enough information to invoke it correctly without ambiguity.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100% (device, new_name, homeassistant_rename all documented). The description reinforces the folder-structure behavior already in the schema and adds MQTT-topic impact context, but it does not provide new parameter-level detail beyond the schema.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Description opens with 'Rename a device's friendly_name' – a specific verb and resource. It clearly distinguishes itself from z2m_set_device_options by noting that this tool affects the MQTT topic, while the alternative handles behavior changes.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Explicitly states 'Use z2m_set_device_options for behaviour changes that do not affect the topic,' giving a direct alternative and exclusion. Also warns about breaking references, helping the agent decide when renaming is appropriate.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
z2m_set_device_optionsAIdempotent
Change Zigbee2MQTT device options such as transition, retain, debounce, temperature_precision or calibration offsets. Options are merged, not replaced, and persist in the Zigbee2MQTT configuration. Call z2m_get_device first to see settable_options for that device. Use z2m_set_state to change what a device is doing, and z2m_set_bridge_options for bridge-wide settings. The response reports whether a bridge restart is required.
| Name | Required | Description | Default |
|---|---|---|---|
| device | Yes | Device friendly_name or ieee_address. | |
| options | Yes | Options to merge, e.g. {"transition": 1, "retain": true}. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already indicate mutation and idempotence, but the description adds crucial behavioral detail: options are merged (not replaced), persist in the Zigbee2MQTT configuration, and the response reports whether a bridge restart is required. This goes well beyond annotation hints and provides meaningful operational transparency.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Four sentences, each carrying essential information: purpose, merge/persistence behavior, prerequisite lookup, and alternative tool guidance. No fluff, perfectly front-loaded, and easy to parse.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Despite lacking an output schema, the description covers all necessary context: prerequisites, alternative tools, merge semantics, persistence, and return-value meaning (restart required). For a mutation tool with two parameters, this is thorough and self-sufficient.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema already covers both parameters (device and options) with 100% coverage. The description enriches this by providing a concrete JSON example for the options object and explicitly clarifying the merge semantics, which adds practical meaning beyond the schema's field descriptions.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description opens with 'Change Zigbee2MQTT device options' and lists example option names (transition, retain, debounce, etc.), clearly defining a specific verb+resource. It also distinguishes itself from z2m_set_state and z2m_set_bridge_options, making the unique purpose immediately apparent.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description explicitly instructs users to call z2m_get_device first to inspect settable_options, and explains when to use z2m_set_state (change what a device is doing) and z2m_set_bridge_options (bridge-wide settings). This provides clear, actionable usage guidance and differentiates the tool from its siblings.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
z2m_set_stateA
Send a state command to a device or group, e.g. {"state":"ON"} or {"brightness":128}. Physically changes what the device is doing, and is reversible by sending the opposite command. mode='get' instead requests a value without changing anything. The command is published without waiting for the device, so success here means the message was sent, not that the device acted — read z2m_get_device afterwards to confirm. Consult z2m_get_device exposes for valid properties.
| Name | Required | Description | Default |
|---|---|---|---|
| mode | No | Default 'set'. | |
| device | Yes | Device or group friendly_name, or ieee_address. | |
| payload | Yes | Command payload, e.g. {"state": "ON"}. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Beyond annotations, the description discloses critical behaviors: the command is fire-and-forget (publication without waiting), success does not mean the device acted, and reversibility. It also clarifies that mode='get' does not change anything. This adds significant context absent from annotations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a bit dense but every sentence adds relevant information. It is front-loaded with the primary action and contains no fluff, though it could potentially be tightened while retaining the essential caveats.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a tool with no output schema, it effectively explains the outcome semantics (message sent vs device acted) and directs to z2m_get_device for confirmation. It covers all parameters and key behavioral nuances, making it sufficiently complete for an agent to use correctly.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, so baseline is 3. The description adds value by explaining the effect of mode='get' (no change) and providing additional payload examples, enriching the schema's basic descriptions.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly identifies the tool as sending a state command to a device or group, with concrete payload examples. It distinguishes from sibling read tools by noting mode='get' only requests a value, and from z2m_get_device which is for reading state.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
It provides explicit guidance on when to use mode='get' vs 'set', and directs users to z2m_get_device to confirm device action and consult valid properties, naming the sibling tool as the alternative for reading.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.
6 tool updates
v0.3.1- Removed
z2m_coordinator_check - Removed
z2m_ota_update - Removed
z2m_remove_device - Removed
z2m_restart_bridge - Removed
z2m_set_bridge_options - Removed
z2m_touchlink
23 tool updates
v0.1.0- First observed
z2m_bind - First observed
z2m_bridge_info - First observed
z2m_check_updates - First observed
z2m_configure_device - First observed
z2m_configure_reporting - First observed
z2m_coordinator_check - First observed
z2m_get_device - First observed
z2m_get_logs - First observed
z2m_health_report - First observed
z2m_interview_device - First observed
z2m_list_devices - First observed
z2m_list_groups - First observed
z2m_manage_group - First observed
z2m_network_map - First observed
z2m_ota_update - First observed
z2m_permit_join - First observed
z2m_remove_device - First observed
z2m_rename_device - First observed
z2m_restart_bridge - First observed
z2m_set_bridge_options - First observed
z2m_set_device_options - First observed
z2m_set_state - First observed
z2m_touchlink
TDQS
Each tool targets a distinct resource and action, with cross-references clarifying when to use similar tools like configure_device vs configure_reporting vs interview_device. The read-only tools (list_devices, get_device, health_report, network_map) have clearly differentiated scopes.
All tools share the z2m_ prefix and use clear descriptive names, but a few read-only tools (z2m_bridge_info, z2m_health_report, z2m_network_map) use noun phrases rather than the verb_noun pattern seen in most other tools (list, get, set, rename, configure). This is a minor deviation from an otherwise predictable convention.
At 17 tools, the set is slightly above the typical 3-15 range, but the Zigbee domain is complex and each tool covers a genuinely distinct operation. No tool feels redundant, and the count is justified by the breadth of device, group, binding, and network management tasks.
The tool set covers the major lifecycle operations: pairing via permit_join, listing and inspecting devices, changing state and options, configuring reporting, managing groups and bindings, OTA updates, health checks, and logs. The most notable gap is the lack of a device removal/delete tool, and there is no bridge restart or firmware update tool, but these are minor for typical automation scenarios.
Maintenance
Related MCP Connectors
Personal assistant MCP server with search, execute, packages, jobs, secrets, and integrations.
Nifty's MCP server — exposes tasks, projects, messages, and files as tools for AI agents.
MCP server wrapping the Tesla Fleet API and TeslaMate API
Related MCP Servers
- AlicenseAqualityCmaintenanceMCP server for full Home Assistant control, enabling AI agents to manage dashboards, automations, files, apps, entities, and more via REST API, WebSocket, and SSH.6692MIT
- AlicenseNot gradedqualityCmaintenanceA comprehensive MCP server that enables AI assistants to control music playback, manage users and access, configure providers, and administer a Music Assistant setup through natural language commands.MIT
- AlicenseAqualityAmaintenanceAn MCP server that connects to Z-Wave JS UI's WebSocket to expose controller, node, and configuration information as tools for AI assistants to manage Z-Wave networks.24MIT
- AlicenseNot gradedqualityBmaintenanceAn MCP server that enables LLMs to list, inspect, and control Zigbee devices via the Zigbee2MQTT frontend websocket API, eliminating the need for direct MQTT broker access.4MIT
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
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/alexpfau/zigbee2mqtt-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server