Skip to main content
Glama

Capture a page screenshot

websitePreview_capture
Read-onlyIdempotent

Renders one page of the site in a real browser and returns the image, so you can check layout, spacing, and responsive behaviour that source-level checks cannot see. path is site-relative and may include a query string, so dynamic routes are captured with real values rather than placeholders. Focus the capture with selector (plus optional padding for surrounding context) or a clip rectangle in CSS pixels from the top-left of the page; the region is scrolled into view and captured within the configured viewport, so it must fit inside it, and these options exclude each other and fullPage. Fonts, images, and (for fullPage) lazy content are awaited before the capture, and CSS animations are fast-forwarded to their end state by default. Fails with 409 when the draft build is still in progress or has failed; poll websiteSourceCode.deployment.status and retry.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "websiteId": "<websiteId>"
    },
    "name": "websitePreview_capture"
  }
}

Input Schema

NameRequiredDescriptionDefault
clipNoCrop to this rectangle, in CSS pixels from the top-left of the rendered page at the chosen viewport; it is scrolled into view and must fit within the viewport. Only for regions no selector frames.
pathNoSite-relative path to render, including any query string, e.g. `/blog/my-post`./
targetNo`head` renders the current draft; `published` renders the live site.head
delayMsNoExtra settle time before capturing, in milliseconds.
paddingNoCSS pixels of surrounding page to include on every side of the `selector` match.
fullPageNoCapture the whole scrollable page instead of just the viewport. Excludes `selector` and `clip`.
scrollToNoScroll to a CSS selector or an absolute Y offset before capturing.
selectorNoCrop to the first element matching this CSS selector, scrolled into view. Preferred: it follows the layout at every viewport.
viewportNoDevice class to render at.desktop
websiteIdYes
colorSchemeNoBrowser color preference to emulate. Omit it to use the renderer default.
waitForSelectorNoWait for this CSS selector to match before capturing.
freezeAnimationsNoFast-forward CSS animations and transitions to their end state so captures are deterministic.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.5/5.0
Behavior5/5

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

Annotations already cover the safety profile (readOnly, idempotent, non-destructive), and the description adds substantial behavior beyond them: fonts/images/lazy content are awaited, CSS animations are fast-forwarded by default, selector/clip regions are scrolled into view and must fit the viewport, and a 409 failure mode with the exact sibling to poll for recovery.

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?

Purpose is front-loaded, then parameter behavior, then the failure/retry case, which is sensible ordering. The middle sentence is a long compound clause covering selector, padding, clip, viewport fit, and mutual exclusion, which is dense and slightly harder to parse than necessary, but essentially no sentence is wasted.

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

Completeness4/5

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

For a 13-parameter, no-output-schema tool, the description covers rendering semantics, cropping modes, determinism (animation freezing, delay), and error recovery — enough to call it correctly. The main gap is that it says only 'returns the image' without hinting at response form or size, though the output schema's absence makes this a minor omission.

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 already 92%, yet the description still adds value: it clarifies that `path` may carry a query string for dynamic routes, describes `clip` coordinates relative to the rendered page, and states that `selector`, `clip`, and `fullPage` mutually exclude each other — a constraint not fully spelled out in the schema for the selector/clip pair.

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?

States a specific verb and resource ('Renders one page of the site in a real browser and returns the image') and frames the outcome ('check layout, spacing, and responsive behaviour'). It also implicitly distinguishes itself from source-level tools by noting what those 'cannot see', so an agent can tell what class of tool this is.

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?

Gives a clear situation for use ('check layout, spacing, and responsive behaviour that source-level checks cannot see') and explains the 409 build-in-progress case with an explicit polling-and-retry path. It does not, however, name the obvious alternative (webResearch_screenshot) or state when not to use this tool.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources