Skip to main content
Glama

browser_wait_for

Pauses browser automation until specified text appears or disappears, or a set number of seconds passes, helping synchronize actions with dynamic page content.

Instructions

Wait for text to appear, text to disappear, or a specified number of seconds in the target session.

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": "browser_wait_for"
  }
}

Input Schema

NameRequiredDescriptionDefault
textNoText to wait for to appear on the page.
timeNoTime to wait in seconds.
textGoneNoText to wait for to disappear from the page.
sessionIdNoOptional target browser session ID. If omitted, uses the currently active session (or auto-launches one).
timeoutMsNoTimeout in milliseconds (default: 15000).

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.2.0

TDQS

B3.3/5.0
Behavior2/5

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

No annotations are supplied, so the description carries the full behavioral burden, yet it never states what happens when the condition is not met before timeout (error vs. silent return), whether the call blocks, or what the result looks like. The only behavioral hint, a 15000 ms default timeout, comes from the schema rather than the description.

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?

A single well-formed sentence that front-loads the verb and enumerates the modes in a compact parallel structure. Every clause maps to a real parameter and there is no filler.

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

Completeness3/5

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

With five all-optional parameters, no annotations, and no output schema, the definition is minimally adequate: the schema covers parameter meaning fully, but the description omits timeout-failure semantics and return behavior, which matter for an agent writing reliable wait logic.

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 every parameter including sessionId and timeoutMs is already documented in the schema; the description only restates the three waiting modes. It adds no syntax, precedence, or mutual-exclusivity detail beyond what the schema provides, so the baseline 3 applies.

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 names a specific verb (wait) and enumerates the three supported conditions: text appearing, text disappearing, or a fixed duration, scoped to 'the target session'. It is clear what the tool does, though it does not contrast itself with any sibling such as browser_snapshot or browser_click, which are the natural alternatives for checking page state.

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

Usage Guidelines3/5

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

Usage is implied by the enumerated conditions: an agent can infer it should call this before asserting on text or to pause execution. However, there is no explicit when-not guidance, no mention of the alternatives for page-state checking, and no indication of whether the three modes can be combined in one call.

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