Skip to main content
Glama

Interact with the page, then screenshot + audit

interact_and_audit

Perform one interaction on the current page, then get a screenshot and text layout audit to reveal breakage from menus, tabs, or modals.

Instructions

Perform ONE interaction on the currently open page, then return a webp screenshot AND a fresh text layout audit of the resulting state, so breakage from an expanded menu, an active tab, or an opened modal shows up immediately. Gestures, blocking waits, and pointer gestures on viewport pixel coordinates are all available — see action for what each one needs. An ambiguous selector acts on the first match and says so. Pass viewport to switch breakpoints before the selector resolves, ignoreSelector to mute known layout noise. Open a page with capture_page_screenshot first.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
xNoX in viewport pixels, off a screenshot.
yNoY in viewport pixels, off a screenshot.
keyNoKey or chord for "press", e.g. "Enter", "Tab", "Control+a".
endXNoDrag release X, viewport pixels.
endYNoDrag release Y, viewport pixels.
textNoText payload: the value to fill for "type" (the field is cleared first), or the substring to match for "wait_for_text"/"expect_text".
stateNoState for "wait_for" to block on. Default visible.
stepsNoIntermediate mouse-moves for "pointer_drag" (default 10). More steps registers with pickier drag-and-drop libraries.
valueNoOption for "select", matched on <option> value first, then its label.
actionYesWhat to do. Extra args in parens: type(text), select(value), press(key), wait_for(state, default visible), wait_for_text(text), wait_for_url(urlContains), wait_for_response(urlContains — fails the call on status >= 400, or != expectStatus), pointer_click(x,y), pointer_hover(x,y), pointer_drag(startX,startY,endX,endY). Waits block until true or time out. pointer_* take viewport pixel coordinates read off a screenshot, so they hit canvas, shadow DOM, and drag-and-drop targets that have no selector.
buttonNoButton for "pointer_click". Default left.
startXNoDrag press-down X, viewport pixels.
startYNoDrag press-down Y, viewport pixels.
selectorNoCSS (or Playwright text=/role=) selector. Omit for page-level steps such as wait_for_network, wait_for_url, or a page-wide expect_text.
sizeModeNoWhat goes over the wire: "full-res" (default), or "thumb" for a 480px webp. Disk always gets the full-resolution image.full-res
viewportNoSwitch to this breakpoint first. Default: keep the current one.
timeoutMsNoTimeout for a wait_for_*/expect_* step (default 5000ms).
urlContainsNoURL substring to match — the page URL for "wait_for_url", the request URL for "wait_for_response".
expectStatusNoRequire this exact status for "wait_for_response". Omit to accept 2xx/3xx and fail on >= 400.
ignoreSelectorNoSelector(s) to exclude from the audit, string or array. Matches and their descendants are suppressed and counted — silences known noise like a cookie banner.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.29.0

TDQS

A4/5.0
Behavior3/5

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

No annotations are provided, so the description carries the full burden. It discloses ambiguous selector behavior ('acts on the first match and says so'), mentions blocking waits, and notes the prerequisite page opening. However, it does not disclose side effects of interactions (page state changes), failure behavior, or audit content specifics, leaving notable gaps.

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?

The description is five sentences, front-loaded with the main purpose, and every sentence adds substantive guidance (prerequisite, selector behavior, parameter hints). It is slightly dense but appropriate for a tool with 20 parameters; no redundant wording beyond acceptable summarization.

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?

Given 20 parameters and no output schema, the description is moderately complete. It explains the output generally (screenshot + text audit) and the prerequisite, but does not describe the audit content, error handling, or interaction side effects. An agent would still need schema details and possibly runtime feedback to fully understand expected behavior.

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?

Schema coverage is 100%, so the baseline is 3. The description adds value beyond the schema by clarifying ordering ('Pass viewport to switch breakpoints before the selector resolves') and giving purpose to ignoreSelector ('mute known layout noise'). These contextual hints help an agent choose and sequence parameters correctly.

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 verb and resource: 'Perform ONE interaction on the currently open page, then return a webp screenshot AND a fresh text layout audit'. It also differentiates from siblings by emphasizing 'ONE' interaction, distinguishing it from run_interaction_sequence, and includes the audit output which is unique to this tool.

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?

The description provides clear context: used after opening a page ('Open a page with capture_page_screenshot first') and for single-interaction verification. It implies the alternative (sequence tool) by stressing 'ONE', but does not explicitly name when-not conditions or alternative tool names. This is clear context without exclusions.

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