gsd-browser screenshot
Capture a screenshot of the current page and return it as a base64-encoded image. When you pass --output, the raw image bytes are written directly to a file on disk instead.
File path where the image should be saved (e.g.
./screenshots/page.png). When set, the command writes raw bytes to disk and prints a confirmation line instead of returning base64 data.CSS selector of a single element to capture. The screenshot crops to that element’s bounding box and always produces a PNG, ignoring the
--format flag.Capture the entire scrollable page height, not just the current viewport.
JPEG compression quality from
1 (lowest) to 100 (highest). Defaults to 80. Has no effect when the format is png.Image format:
jpeg (default) or png. Element screenshots (--selector) are always PNG regardless of this setting.gsd-browser save-pdf
Export the current page as a PDF file. The PDF is rendered using the browser’s built-in print engine, which honours CSS print stylesheets.
Full file path for the saved PDF (e.g.
./exports/report.pdf). When omitted, the file is saved to the session directory and the path is printed.Output filename (used when you want the file saved to the default session directory with a specific name).
Page size:
A4 (default), Letter, Legal, or Tabloid.Include background graphics and colours in the PDF output. Enabled by default; pass
--print-background false to disable.gsd-browser page-source
Return the HTML source of the current page or a scoped element.
CSS selector to scope the source output to a specific element. Omit to retrieve the full page source.
gsd-browser eval
Evaluate a JavaScript expression in the context of the current page and return its result. Use --json to parse the return value as structured JSON rather than a plain string.
Any valid JavaScript expression. The expression runs in the page’s global scope and has access to
window, document, and all page globals.gsd-browser har-export
Export all captured network traffic for the current session as a HAR 1.2 JSON file. The network buffer accumulates requests continuously; call this command at any point to flush the buffer to disk.
Output file path for the HAR file (e.g.
./session.har). When omitted, the file is saved to the session directory and the path is printed.The network buffer accumulates across the entire session. Call
gsd-browser network --clear if you want to start a fresh capture window before running a specific flow.gsd-browser record-start / gsd-browser record-stop
Record a named flow session that captures actions, screenshots, and network activity into an evidence bundle. Start the recording before performing actions; stop it when the flow is complete.
A human-readable name for this recording (e.g.
checkout-flow-2026-06). The name is used as part of the bundle filename and is shown in the recordings list.| Command | Description |
|---|---|
gsd-browser record-pause | Pause an active recording without stopping it |
gsd-browser record-resume | Resume a paused recording |
gsd-browser recordings | List all saved recordings |
gsd-browser recording-get <id> | Get the manifest for a specific recording |
gsd-browser recording-export <id> --output <dir> | Export a recording bundle to a directory |
gsd-browser recording-discard <id> | Delete a recording |
gsd-browser debug-bundle
Capture a complete debug bundle — screenshot, console log, network log, timeline, and accessibility tree — in a single command. Use this to collect all diagnostic evidence at a point in time.
Optional suffix to append to the bundle directory name, making it easier to identify in the file system.
