Quickstart

Clone your first site end to end: capture, refine, wire and deploy, in a single command.

Requirements

One command

Capture, refine, wire and deploy in a single run:

xray https://example.com --site example

Output lands in a durable directory rather than a temp folder, so a reboot does not cost you the capture:

~/clones/example/
  capture/   raw capture — assets, url map, interaction recordings
  site/      the Astro project you edit and deploy

Stage by stage

The same run, one stage at a time. Useful when an origin fights back and you want to iterate on just the capture.

xray capture https://example.com ~/clones/example/capture
xray refine  ~/clones/example/capture ~/clones/example/site
xray wire    ~/clones/example/site --site example
xray deploy  ~/clones/example/site --prod

Run it locally

cd ~/clones/example/site
pnpm install
pnpm dev

The dev server serves the rebuilt site with hot reload. Edit a component and the page updates.

Content is read from the database first. A slot renders its stored value if one exists and falls back to the default written in the component. After you edit component defaults, reseed — otherwise the old stored value keeps winning and your edit appears to do nothing. See Admin and slots.

When the origin is a single-page app

Static capture is faster and scores higher on server-rendered sites. If the origin is an app shell that paints with JavaScript, or sits behind an anti-bot CDN, force the browser engine:

xray https://example.com --site example --engine playwright

Verify before you ship

Every run ends with a verification pass: each route is loaded headless and every failed request is counted. Treat a non-zero count as a failed build, not a warning — it is how a missing webfont or a dead icon reaches production unnoticed.