Skip to main content
Glama
andresolbach

nodriver-mcp-server

Wait for text

wait_for
Read-only

Wait until one of several texts appears on the page, then capture a snapshot. Polls visible text twice per second, returning immediately when a match is found, with the snapshot included.

Instructions

Wait until one of several texts appears on the page, then snapshot it.

The right way to wait after an action that starts loading — far more reliable than guessing a delay, and it returns the moment the text shows up instead of always burning the whole timeout.

On success the page snapshot is included in the response, so no separate take_snapshot call is needed.

Polls the visible text twice a second. To wait for an element rather than for wording, use wait_for_selector.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
textYesTexts to wait for — the wait ends as soon as any one of them appears. Passing both outcomes, e.g. ["Welcome back", "Login failed"], lets one call tell you which happened. Matching is a case-sensitive substring test against the page's visible text.
timeoutNoMaximum wait in milliseconds before giving up.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior5/5

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

Annotations already declare readOnly and non-destructive, but the description adds valuable behavioral context: it polls visible text twice a second, returns as soon as text appears rather than burning full timeout, and includes a page snapshot on success. No contradiction with annotations.

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?

Four tight sentences front-load the core purpose, then add reliability context, snapshot benefit, polling cadence, and alternative tool. Every sentence earns its place with no fluff.

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?

The description covers what the tool does, when to use it, how it behaves (polling, early return, snapshot), and points to the alternative. With an output schema present, nothing about return values is missing. This is complete for a moderate-complexity wait tool.

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 coverage is 100% and the schema's text description already explains the 'any one' matching and case-sensitive substring behavior. The tool description reinforces the 'several texts' semantic but adds no new parameter detail beyond what the schema provides, so baseline 3 is appropriate.

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?

The description states a specific action (wait until text appears) on a specific resource (visible page text) and clearly distinguishes from sibling wait_for_selector by contrasting text vs element. It also mentions snapshotting as part of the purpose.

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 says this is the right way to wait after an action that starts loading, recommends it over guessing delays, and names the alternative wait_for_selector for element-based waits. This gives clear when-to-use and when-not-to-use guidance.

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

Install Server

Other Tools

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/andresolbach/nodriver-mcp-server'

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