Skip to main content
Glama

browser_wait

Pauses automation until a CSS selector appears or page text contains a target string, helping agents synchronize actions with dynamic page content.

Instructions

Wait until a CSS selector exists or the page text contains something.

Input Schema

NameRequiredDescriptionDefault
tabYestab id returned by browser_open
timeoutNo
wait_cssNo
wait_textNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

C2.7/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 does not disclose what happens on timeout (error vs. silent return), what the default timeout is, whether it blocks the tab, or whether the two wait conditions are ANDed or ORed. 'or the page text contains something' hints at OR semantics but leaves it ambiguous.

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?

A single front-loaded sentence with no filler, but 'something' is imprecise and wastes the one clause that could have clarified the text-matching semantics.

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?

A polling/wait primitive with no output schema, no annotations, and three of four parameters undocumented in both schema and description leaves critical gaps: timeout behavior, return value, and condition-combination semantics. An agent cannot reliably call this without guessing.

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?

Schema coverage is only 25% (just 'tab' is documented), so the description must compensate and largely does not. It implies wait_css and wait_text map to CSS/text conditions but never states that at least one condition is required, the timeout unit or default, or whether combining wait_css and wait_text means OR rather than AND.

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?

Names a specific verb (wait) and the two wait conditions (CSS selector existence, page text containment), which clearly distinguishes it from browser_read or browser_screenshot. It is not vague, but it stops short of naming sibling alternatives.

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?

No guidance on when to call this versus browser_read, browser_screenshot, or browser_click, and no guidance on choosing wait_css versus wait_text or when to use neither. The agent must infer the polling use case entirely from the name.

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