Skip to main content
Glama

wait_for_agents

Blocks until specified agents finish their current turn or the timeout expires, reporting which ones completed. Returns immediately when no agents are busy; call again after a timeout.

Instructions

Block until one of the agents finishes its turn (idle / exited / closed), or timeout.

names: agents to report on (default: all). Those that are starting or working when the call begins are waited for; finished lists the ones whose turn ended during the call. Returns immediately if none is busy. Call again after a timeout.

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": "wait_for_agents"
  }
}

Input Schema

NameRequiredDescriptionDefault
namesNo
timeout_sNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.2/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and mostly succeeds: it discloses that the call blocks, which agents it waits on, that it returns immediately when nothing is busy, and that 'finished' reports agents whose turn ended during the call. It omits how long blocking can last beyond the timeout and whether calls are expensive to repeat in a loop.

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

Conciseness5/5

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

The blocking behavior and scope are front-loaded in the first sentence, followed by tightly packed clarifications about the wait set, the fast-return case, and retry-after-timeout. No filler sentences; the only flaw is a mid-sentence line break that fragments one clause.

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?

No output schema exists, so the description has to explain returns, and it does name 'finished' as a returned field. It falls short of fully documenting the response shape (e.g., what is returned for timed-out agents) and the timeout parameter's default/units, which matters for a long-blocking tool.

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 0%, so the description must compensate. It explains 'names' (default: all) and clarifies the semantics of the wait set, but 'timeout_s' is only referenced obliquely ('or timeout', 'Call again after a timeout') without units, default behavior, or valid range beyond what the schema name and default imply.

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 with scope: 'Block until one of the agents finishes its turn (idle / exited / closed), or timeout.' The terminal states and the blocking nature make it clearly distinct from polling siblings like list_agents or get_agent.

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?

Gives concrete usage context: only agents starting or working when the call begins are waited for, it returns immediately if none is busy, and 'Call again after a timeout' tells the agent what to do next. It stops short of naming a sibling alternative for the case where the agent would rather poll, so it is not a full when/when-not statement.

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