Skip to main content
Glama
Mehmoodqureshi

MCP Browser Extension

wait_for

Pause Chrome automation until a selector or text appears or disappears, using timeouts and frame options to continue only when content is ready.

Instructions

Wait for a selector or text to appear/disappear.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
goneNo
tabIdNoTab id (default: agent's tab)
frameIdNoFrame id from frames_list
selectorNo
allFramesNoAct on the first match in ANY frame (the element may be in an iframe)
timeoutMsNo
textContainsNo
failOnAuthWallNoError with [AUTH_REQUIRED] if this lands on a sign-in wall (expired session)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.9.24
    • changedInput schema / properties / tabId / description
      Previous value: -"Tab id (default: active tab)"New value: +"Tab id (default: agent's tab)"
  2. Changed4 schema fields changedv0.9.5
    • changedInput schema / properties / allFrames / description
      Previous value: -"Search every frame of the tab and act on the first that matches - use when a selector should match but does not (the element is in an iframe)"New value: +"Act on the first match in ANY frame (the element may be in an iframe)"
    • changedInput schema / properties / failOnAuthWall / description
      Previous value: -"Fail with [AUTH_REQUIRED] when the page this call lands on is a high-confidence sign-in wall (session expired). Off by default unless the server runs with --fail-on-auth-wall; snapshot still reports the verdict as `authWall` either way."New value: +"Error with [AUTH_REQUIRED] if this lands on a sign-in wall (expired session)"
    • changedInput schema / properties / frameId / description
      Previous value: -"Act inside this frame (ids come from frames_list)"New value: +"Frame id from frames_list"
    • changedInput schema / properties / tabId / description
      Previous value: -"Target tab id (defaults to the active tab)"New value: +"Tab id (default: active tab)"
  3. Changed1 schema field changedv0.9.3
    • addedInput schema / properties / failOnAuthWall
      Added value: +{
      +  "description": "Fail with [AUTH_REQUIRED] when the page this call lands on is a high-confidence sign-in wall (session expired). Off by default unless the server runs with --fail-on-auth-wall; snapshot still reports the verdict as `authWall` either way.",
      +  "type": "boolean"
      +}
  4. Changed2 schema fields changedv0.7.0
    • addedInput schema / properties / allFrames
      Added value: +{
      +  "description": "Search every frame of the tab and act on the first that matches - use when a selector should match but does not (the element is in an iframe)",
      +  "type": "boolean"
      +}
    • addedInput schema / properties / frameId
      Added value: +{
      +  "description": "Act inside this frame (ids come from frames_list)",
      +  "type": "number"
      +}
  5. First observedv0.6.2

TDQS

C2.4/5.0
Behavior2/5

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

With no annotations, the description carries the full behavioral burden and mostly fails: it does not say what the default timeout is, what happens on timeout (error vs. empty return), whether the call blocks, or how failOnAuthWall/[AUTH_REQUIRED] surfaces. The appear/disappear toggle is mentioned but not tied to any parameter.

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

Conciseness3/5

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

A single short sentence front-loads the core action and wastes no words. However, its brevity reflects under-specification rather than disciplined concision — key qualifiers were omitted rather than compressed.

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

Completeness2/5

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

For an 8-parameter, zero-required tool with no annotations, no output schema, and half its parameters undocumented, one sentence is far too thin. Nothing tells the agent about blocking behavior, default timeouts, or the interaction between selector, textContains, and gone.

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

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Only 50% of the 8 parameters are described in the schema (tabId, frameId, allFrames, failOnAuthWall); selector, textContains, gone, and timeoutMs are undocumented. The description gestures at 'selector or text' and 'appear/disappear' but never states that `gone` inverts the check or that selector/textContains are alternatives, so it does not compensate for the coverage gap.

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

Purpose3/5

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

The description states a recognizable verb and object (wait for a selector or text), so the general intent is clear. But it never explains how the appear-vs-disappear behavior is selected, nor distinguishes this from siblings like snapshot or get_text that also inspect page state. Adequate but with real gaps.

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

Usage Guidelines2/5

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

There is no when-to-use guidance, no prerequisites, and no mention of alternatives such as snapshot/get_text/frames_list. An agent must infer entirely from the name that this is for blocking on page readiness.

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