Skip to main content
Glama

screenshot_diff

Idempotent

Save a named baseline of a viewport or element, then compare subsequent captures against it. Returns changed-pixel percentage and a red-highlighted diff image to identify visual regressions.

Instructions

Visual regression: save a named baseline (viewport or element), compare later — returns changed-pixel % and red-highlighted diff image. Baselines are in-memory (lost on service worker restart).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameNoBaseline id: reuse the same one to compare across runsdefault
actionYesbaseline stores, compare measures against it, clear drops baselines
tab_idNoTarget tab; omitted = last tab navigated in this session, else the active one
selectorNoCapture one element (default viewport)
thresholdNoPer-channel tolerance 0-255
Behavior4/5

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

Annotations declare idempotentHint=true and destructiveHint=false, but the description adds critical behavior: baselines are in-memory and lost on service worker restart. This goes beyond annotations and helps the agent understand state persistence.

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?

Two sentences efficiently convey purpose, return values, and a key caveat (in-memory baselines). No redundant or filler content; every phrase adds value.

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?

For a visual regression tool with 5 parameters and no output schema, the description covers purpose, return format (changed-pixel % and diff image), and critical limitations. It is sufficiently complete for an agent to decide when and how to use it.

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?

Input schema covers all 5 parameters with descriptions, and the description enriches them with additional context (e.g., action enum meanings, default tab_id behavior, threshold range). Schema coverage is 100%, so baseline is 3; the extra context justifies 4.

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?

Description clearly states the tool performs visual regression: saving a named baseline and comparing later, returning changed-pixel percentage and a diff image. It distinguishes from sibling tools like 'screenshot' and 'full_page_screenshot' by specifying visual comparison.

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 implies usage for visual regression testing and mentions the ephemeral nature of baselines (lost on service worker restart). However, it lacks explicit when-not-to-use guidance or direct comparisons with alternative tools, so it's clear but not fully prescriptive.

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/frsorrentino/chrome-bridge'

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