Skip to main content
Glama

ghost_wait

Wait for UI conditions instead of fixed sleeps: element visibility, value changes, navigation, idle screen, text presence, events, or custom conditions—return immediately when the condition is met.

Instructions

Unified wait - use it instead of sleeping. for=element: an element (name/role) appears or disappears in the target window; returns the moment it does. for=value: an element's VALUE equals/contains/changes (forms, async fields, 'wait until the total updates'). for=navigate: load url in a browser window WITHOUT raising it - sets the address bar over UIA, presses Enter, returns when the window title changes (response: title_before, title_after, title_changed, ms); only a foreground focus policy takes the old focus-and-type path. for=idle: screen stable. for=text: click a target then wait for text. for=event: next foreground change. for=cond: JSONLogic poll. for=ms: a plain sleep - last resort, it costs its full length every run. Target window for element|value|idle|text|navigate = window= or the session anchor.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
msNoMilliseconds (for=ms)
forNoWhat to wait for (default ms)
urlNoURL to navigate to (for=navigate)
nameNoElement name (for=element|value)
roleNoElement role (for=element|value)
textNoText to wait for (for=text) or expected value (for=value)
windowNoWindow scope (for=idle|element|value|navigate); omit to use the anchor
appearsNofor=element|text: true=wait to appear, false=wait to disappear
conditionNoJSONLogic expression (for=cond)
predicateNofor=value: how to compare the element's value to text (default equals)
settle_msNofor=navigate: pause after the title change so the page can paint (0 = return immediately)
since_seqNofor=event
timeout_msNo
stable_framesNofor=idle

Schema Changelog

Changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. First observedv0.23.4

TDQS

A4/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 behavioral burden and does well by disclosing key side effects: navigate loads a URL 'WITHOUT raising it,' 'sets the address bar over UIA, presses Enter,' and 'returns when the window title changes'; ms 'costs its full length every run.' It does not describe timeout or failure behavior, so it is not a perfect 5.

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?

The description is dense but appropriately sized for eight modes, and it is front-loaded with the unified purpose before enumerating the for= variants. It uses a consistent semicolon-separated structure, though bullet formatting would make it easier for an agent to scan.

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 14-parameter tool with no output schema and no annotations, the description explains every mode, specifies the target-window rule, and even gives the navigate response fields. Minor gaps remain around since_seq for event waits and the click-target parameter for text waits, but the overall guidance is sufficient for correct invocation.

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 coverage is already 93%, and the description adds meaningful context beyond the schema: value waits for equals/contains/changes semantics, element waits for appearance or disappearance 'in the target window,' and navigate has a settle_ms pause after the title changes. The for=text mode is slightly ambiguous about how the click target is identified, which prevents a 5.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description opens with 'Unified wait - use it instead of sleeping' and enumerates eight distinct wait modes (element, value, navigate, idle, text, event, cond, ms), so the verb and resource are clear. It does not explicitly contrast itself with the sibling ghost_tab_wait_for, so it stops short of full sibling differentiation.

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 description provides mode-specific selection guidance, explicitly calls for=ms a 'last resort' that 'costs its full length every run,' and notes the condition under which navigate uses the old focus-and-type path. It does not mention when to prefer the sibling ghost_tab_wait_for, but the within-tool routing between modes is strong.

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

Latest Blog Posts

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/NORTHTEKDevs/ghost'

If you have feedback or need assistance with the MCP directory API, please join our Discord server