Skip to main content
Glama

host.runs.wait

Long-poll one run until it finalizes, until: {counter, gte} is reached, or timeout_s elapses (max 25s), returning its current status either way -- for a client with no polling loop of its own.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
untilNo{counter: <name>, gte: <n>} -- return as soon as that counter reaches n, even while the run is still running.
run_idYesThe run id to wait on.
timeout_sNoMax seconds to wait, capped at 25; default 20.
tenant_keyNoThe key `signup` returned. Required only when this connection carries no Authorization: Bearer header -- when both are present, the header wins.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedInput schema / properties / until
      Added value: +{
      +  "description": "{counter: <name>, gte: <n>} -- return as soon as that counter reaches n, even while the run is still running.",
      +  "type": "object"
      +}
  2. Added

TDQS

A4.2/5.0
Behavior4/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It discloses that the call blocks via long-polling, returns early when a counter threshold is reached, returns after a timeout, and returns the current status regardless. This is solid behavioral transparency for a wait operation, though it does not mention auth, rate limits, or error behavior.

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 description is a single dense sentence with every clause earning its place. It front-loads the core behavior ('Long-poll one run until it finalizes') and then packs the termination conditions and intended audience without waste.

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?

For a tool with a rich schema covering all parameters, the description adequately explains the wait semantics, timeout cap, and return behavior. It could be more complete by describing what 'finalizes' means or what the returned status looks like, but those are minor gaps given the schema already specifies the inputs.

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%, so the schema already documents all four parameters. The description adds useful context about the max 25s timeout and the early-return counter condition, but it does not substantially enrich parameter meaning beyond what the schema provides. Baseline 3 is appropriate.

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 names a specific verb ('Long-poll'), a specific resource ('one run'), and precise termination conditions. It clearly distinguishes this from sibling run tools like host.runs.get or host.runs.list by emphasizing the blocking, wait-until-finalized behavior.

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?

The phrase 'for a client with no polling loop of its own' gives clear context on when this tool is appropriate, implying that clients with their own polling should use a different read-style tool. It stops short of explicitly naming an alternative tool or stating when-not-to-use, but the context is strong.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources