Capture responsive screenshots
screenshot.captureRenders HTML files or URLs in a sandboxed Chromium browser, saving PNG screenshots to a specified directory for visual validation.
Instructions
Renders a local HTML file or HTTP(S) URL in a sandboxed local Chromium browser and writes PNG screenshots to the requested directory. Downloads the pinned headless browser on first use if it is not already cached. Existing matching files may be replaced.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| outputDir | No | Directory where PNG screenshots will be written. | .mcp-validator/screenshots |
| viewports | No | Optional viewport definitions; defaults to desktop, tablet, and mobile sizes. | |
| targetPath | Yes | Local HTML path or HTTP(S) URL to render. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| error | No | ||
| screenshots | Yes | ||
| outputDirectory | Yes |