Skip to main content
Glama

List topics

list_topics
Read-only

Discover MQTT topics seen on the broker, including last payload, last-seen time, and message counts. Filter with MQTT wildcards such as home/+/temperature or home/kitchen/#.

Instructions

List MQTT topics the server has seen on the broker, with the last payload, when it was last seen and how many messages arrived. Use this first to discover which devices exist. Supports MQTT wildcards, e.g. 'home/+/temperature' or 'home/kitchen/#'.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "list_topics"
  }
}

Input Schema

NameRequiredDescriptionDefault
limitNoMaximum number of topics to return
filterNoMQTT topic filter, wildcards + and # allowed#

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.4/5.0
Behavior4/5

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

Annotations only declare readOnlyHint=true, and the description adds meaningful context beyond that: it discloses the shape of each returned row (last payload, last-seen time, message count) despite there being no output schema. It does not cover retention or staleness of the topic list, or whether results are truncated by the default limit, which keeps it from a 5.

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?

Three short sentences with no filler: purpose and return contents first, then the discovery guidance, then wildcard syntax. Every sentence carries distinct information.

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?

With no output schema, the description correctly spends words on return values, and it explains the filter syntax. Gaps are minor for a two-parameter read tool: nothing about result ordering, truncation at the default limit of 100, or how long the server retains topic history.

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 100%, so the baseline is 3, but the description adds concrete wildcard syntax examples ('home/+/temperature', 'home/kitchen/#') that make the filter parameter's MQTT semantics clearer than the schema's terse 'wildcards + and # allowed'. The limit parameter is left entirely to 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 gives a specific verb and resource ('List MQTT topics the server has seen on the broker') and enumerates what each entry contains: last payload, last-seen time, and message count. That is enough for an agent to distinguish it from the publish/subscribe siblings, which perform actions on the broker rather than enumerate observed topics.

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?

It states an explicit usage rule: 'Use this first to discover which devices exist', which tells the agent this is the entry point for discovery. It does not name an alternative tool or say when not to use this one, but the sibling set (publish/subscribe) makes the boundary largely self-evident.

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