Skip to content

Getting Started

WebSketch CLI consumes WebSketch IR captures — structured JSON representations of web page layouts — and lets you render, diff, fingerprint, and bundle them from the terminal.

Terminal window
pnpm add -g @mcptoolshop/websketch

Or run without installing:

Terminal window
npx @mcptoolshop/websketch render-ascii capture.json

WebSketch is a system for creating structured, machine-readable representations of web page layouts. Instead of working with screenshots (pixel grids), WebSketch produces an Intermediate Representation (IR) that describes what elements exist on the page, where they are positioned, what role they serve, and what text they contain.

The CLI can:

  • Render a capture as ASCII art that fits in a terminal or LLM context window
  • Fingerprint a page’s structure into a short hash for change detection
  • Diff two captures to produce a ranked list of layout and content changes
  • Bundle captures into a single portable file for sharing

WebSketch CLI works with capture files created by:

Terminal window
# Validate a capture file
websketch validate capture.json
# Render as ASCII art
websketch render-ascii capture.json
# Get a structural fingerprint
websketch fingerprint capture.json
# Compare two captures
websketch diff before.json after.json