Quickstart
Clone your first site end to end: capture, refine, wire and deploy, in a single command.
Requirements
- Node 22 or newer — Astro 5 refuses to build on Node 20.
- A package manager. The generated project uses pnpm.
- A Postgres database if you want the admin panel. One database can hold every clone you build.
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.
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.