Skip to main content
Glama

wait_for_ready

Read-onlyIdempotent

Blocks until a task becomes ready—its last blocking dependency reached a terminal state—then returns the ThreadReady event or null when the timeout lapses.

Instructions

Block until a task becomes ready, meaning its last blocking dependency reached a terminal state (thread_ready), and return the ThreadReady event, or null when the timeout lapses. It answers only that dependency signal: use wait_for_blocked_resolved for an explicit block being cleared, wait_for_claim_expired for a lapsed claim, wait_for_event for several kinds at once, and claim_next_thread to take ready work that already exists. Scoped to channel_id when given, else any thread you may read in the workspace. since_log_id replays a ThreadReady recorded after that log_id before waiting live; without it only readiness signalled after the call counts. To put a deadline on a thread instead, use set_wait. Requires workspace:read.

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_ready"
  }
}

Input Schema

NameRequiredDescriptionDefault
channel_idNoUUID of a channel; only readiness of its tasks counts. Omitted, any thread you may read in the workspace.
timeout_msNoWait window in milliseconds, from 1 to 300000 (default 30000). When it lapses the tool returns null.
since_log_idNoYour high-water log_id. The log is replayed for a matching event with a log_id greater than this before the wait goes live, so an event in the gap between two calls is caught. Omitted, only events after the call count.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changedv479.0.2
    • changedInput schema / properties / channel_id / description
      Previous value: -"optional: scope to one channel's tasks"New value: +"UUID of a channel; only readiness of its tasks counts. Omitted, any thread you may read in the workspace."
    • changedInput schema / properties / since_log_id / description
      Previous value: -"lookback anchor: replay the log for a matching event with log_id greater than this before parking live"New value: +"Your high-water log_id. The log is replayed for a matching event with a log_id greater than this before the wait goes live, so an event in the gap between two calls is caught. Omitted, only events after the call count."
    • changedInput schema / properties / timeout_ms / description
      Previous value: -"long-poll window in milliseconds"New value: +"Wait window in milliseconds, from 1 to 300000 (default 30000). When it lapses the tool returns null."
  2. First observedv479.0.0

TDQS

A4.9/5.0
Behavior5/5

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

Annotations already cover the safety profile (readOnly, idempotent, non-destructive, closed-world), and the description adds real behavior beyond them: the call blocks, returns null when the window lapses, only replay-aware behavior applies when since_log_id is supplied, and it requires the workspace:read scope. The replay/gap caveat is a subtle semantic an agent cannot infer 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.

Conciseness4/5

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

Front-loaded with the core definition, then routing, then scoping, then the replay caveat—a logical order with no filler sentences. It is dense and the packed sibling-routing sentence takes a careful read, but every clause carries routing or behavioral information.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

No output schema exists, and the description compensates by stating the return value (ThreadReady event or null) and the timeout condition. For a blocking, permission-gated wait tool with three optional parameters, it covers scope, auth, return, and alternatives—nothing an agent needs to call it correctly is missing.

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

Parameters5/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 still frames the intent of each parameter rather than restating it: channel_id as a scope limiter, timeout_ms as the null-returning window, and since_log_id as the mechanism that catches events in the gap between calls. That said, much of this overlaps the schema text, so the added value is moderate rather than transformative.

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 ("Block until a task becomes ready") and defines the trigger condition precisely: the last blocking dependency reached a terminal state (thread_ready). It also states the return contract (ThreadReady event or null on timeout), which lets an agent distinguish it from the many wait_* siblings without opening a schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicitly names four alternatives with the condition that selects each: wait_for_blocked_resolved for a cleared explicit block, wait_for_claim_expired for a lapsed claim, wait_for_event for multiple kinds, claim_next_thread for work that already exists, and set_wait for a thread deadline. This is exactly the when-to-use/when-not-to-use routing an agent needs among near-identical wait tools.

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