Skip to main content
Glama

page_batch

Run a sequence of browser actions in one call, returning a single combined network/console/URL delta instead of one result per step. Includes an optional final page look with screenshot and legend.

Instructions

Run a SEQUENCE of actions in one call. Each step is an object with an action field, e.g. { "action": "tap_at", "x": 195, "y": 615 } or { "action": "wait_for", "networkIdleMs": 800 } — NOT { "tap_at": ... }. Actions: click / type / fill / select / key / hover / scroll / click_at / tap_at (touch, for Cocos/canvas games) / goto / wait / wait_for. Steps settle briefly between each, and it reports ONE combined network/console/url delta at the end — far faster than one tool call per step. Target steps by selector, by text ("the button that says Login"), or by ref (refs stay valid inside a batch — text targeting does not renumber them — but any step that changes the DOM invalidates them, so prefer selector/text after such a step). Stops at the first failing step unless stopOnError:false. Set look:true to get a page_look (badged 1:1 screenshot + legend) of the final state in the same reply, so you can pick the next target immediately.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
lookNoappend a page_look of the final state (badged screenshot + legend)
stepsYes
waitMsNofinal settle cap before reporting the delta (default 700ms)
lookLimitNomax badges for the final look (default 80)
sessionIdNo
stopOnErrorNostop at the first failing step (default true)
stepSettleMsNoquiet-wait cap between steps (default 300ms)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.6.0

TDQS

A4.5/5.0
Behavior4/5

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

With no annotations, the description carries the full burden. It discloses key behaviors: steps settle briefly, one combined delta is reported, it stops on first failing step unless disabled, and the look option provides a final page_look. It also warns about ref invalidation, which is critical operational behavior. It doesn't mention potential side effects like navigation, but those are inherent to the actions.

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?

The description is long but every sentence earns its place: example, action list, behavioral notes, and options. It front-loads the core concept and example, then adds necessary details. For a tool this complex, the length is justified and well-structured.

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?

Given the tool's complexity (12 actions, multiple targeting methods, and options), the description is thorough. It covers usage, examples, edge cases (ref invalidation), error handling (stopOnError), and output (combined delta). No output schema exists, but the description states what the tool reports, so an agent has enough context to invoke it correctly.

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?

The schema already describes most parameters (71% coverage), but the description adds significant meaning: it explains the action object structure, gives a concrete example, clarifies ref lifetime, and describes the look option's purpose. It goes beyond a mere parameter list and helps the agent construct correct steps.

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 clearly states the tool's purpose: running a sequence of actions in one call, with a concrete example and a list of supported actions. It distinguishes itself from individual page_* tools by emphasizing speed ('far faster than one tool call per step'), making its purpose unmistakable.

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?

It provides strong usage guidance: when to use it (batching steps for speed), how to target steps (selector, text, ref), and important caveats (ref invalidation after DOM changes). It implies individual tools are for single actions but doesn't explicitly state that exclusion. The stopOnError and look options are also explained.

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