Skip to main content
Glama

screenshot

Captures the current page or a specific element, saves the image to disk, and returns the file path for later use.

Instructions

Captures a screenshot of the current page or a specific element. Saves to disk and returns the file path.

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": {
      "session": "<session>"
    },
    "name": "screenshot"
  }
}

Input Schema

NameRequiredDescriptionDefault
sessionYesThe session name
fullPageNoCapture full scrollable page instead of viewport only. Ignored if selector is provided. Default: false
savePathNoCustom file path to save the PNG. If omitted, saves to a temp directory.
selectorNoCSS selector for a specific element to capture. If omitted, captures the full page/viewport.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.6/5.0
Behavior3/5

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

With no annotations, the description carries the full burden, and it does disclose two important behaviors: the capture is persisted to disk and the return value is a file path. It omits failure behavior (unknown selector, session not open), whether it blocks, and what the PNG contains beyond the page/element distinction.

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 short sentences, zero waste, with the core action front-loaded and the side effect plus return value immediately after. Nothing in it is redundant filler.

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 four-parameter tool with full schema coverage and no output schema, the description covers what the tool does, that it writes a file, and what it returns. The main residual gap is error/prerequisite behavior for a tool that depends on an existing session.

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%, so all four parameters, including the interaction between fullPage and selector and the savePath default, are already documented in the schema. The description adds only a restatement of the page-vs-element distinction, which the schema already covers.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

"Captures a screenshot of the current page or a specific element" names a specific verb (captures) and resource (screenshot) and states the two capture scopes. It does not explicitly differentiate itself from siblings like query, elements, or describe, which an agent might also consider when it wants page information, so it stops short of a 5.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Usage is only implied: an agent can infer this is the visual-inspection tool, and the mention of 'current page or a specific element' hints at the two modes. There is no explicit statement of when to prefer this over query/elements/describe, and no prerequisites (e.g. an open session) are spelled out.

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