Ghosty checks — the checks on every PR
Updated 2026-11-21
When an agent writes the code, the usual checks (CI, tests, a human reading the diff) fall short: an agent can make up a package that doesn't exist, edit its own tests to pass them, or ship a route that only crashes behind the real proxy. Ghosty checks cover those gaps. Everything is open source and free; you pay no external service.
What gets checked
Any check that doesn't apply to your repo (no migrations, no OpenAPI) passes with "not applicable".
Where each one runs
-
Smoke and Lighthouse run by Ghosty against the PR preview and show up as «Ghosty · Smoke». To declare which routes to test, add to
.ghosty/dev.md:Without the list,
/is tested. Five routes at most. It also opens with GET the pages and API routes the PR touches (from its diff): one answering 5xx blocks the merge with its message («GET /api/me → 503: …»), and browser errors (exceptions, console, 5xx requests) leave the check neutral with the route and the message.To test the main feature and not just the home page, declare its steps as a list; each one must answer 2xx. With
e2e:Ghosty runs your e2e tests inside the preview box, against the app already running there (BASE_URLandPLAYWRIGHT_BASE_URLpoint to it); if they fail, they block the merge:The smoke never invents a write (POST, PUT, PATCH, DELETE): it only runs the ones you declare, with their body and Content-Type (
{…}goes as JSON;form:a=1&b=2as a form; no body, no body). If the PR changes a write action or handler and there's no declared step, the check is neutral «the PR changes POST /x and there's no smoke step: declare one» with the line ready to paste.The smoke runs signed in if your app adopted (
X-Ghosty-Identity): Ghosty signs a service identity withsub: "ghosty-smoke"andemail: "smoke@ghosty.studio". Without it, an app with login only tests what's public.If something crashes, Ghosty repeats that same step against production (
production: https://…in the frontmatter, the repo's GitHub «Website» or thefly.tomlapp). If it fails there too, it's not from this PR: the check is neutral «Also fails on main (not from this PR)» and it's worth opening a separate task. Only regressions turn it red. -
Dependencies, SAST, migrations, contract, bundle and coverage run in your CI with the reusable workflow from . Public repo: on GitHub (
ubuntu-latest). Private repo: on your space's CI box if it has one; otherwise on GitHub.
Add them to your repo
In Development, open a task → Checks. If your repo doesn't have them, the «Add to repo» card opens a PR with .github/workflows/ghosty-checks.yml. Merge it and they run from the next PR on. By hand it's eight lines:
Via API: GET /api/v2/me/dev-runs/{id}/checks tells whether they're installed and POST opens the PR.
Talk to the agent writing the code
The task lives in its GitHub issue (the log). Whatever you ask the agent, from anywhere, is posted as an issue comment and reaches whoever is writing it, in the cloud or in a terminal:
- In the task's conversation: type, or drop images and files.
- On GitHub: comment
@ghosty …on the issue or the PR. If you have write access to the repo, the comment gets 👀 once it arrives. - Via API:
POST /api/v2/me/dev-runs/:idwith{"op":"tell","note":"…"}. - If an agent is writing it in a terminal (Claude Code, Cursor, Codex with
ghosty-dev):ghosty-dev wait <n> --watchwakes it with your request andghosty-dev asks <n>shows it. In Development that task shows "in their terminal" and opens on GitHub. From the terminal, the agent uses Ghosty's tools with theghostyCLI (ghosty login).
What happens depends on where the task is: if it's working, it picks it up on its next step. If it was waiting for you, it resumes. If the PR was waiting on CI or review, it goes back to "working" on the same branch and the previous commit is not merged. If it's closed, it's not accepted. The agent writes with its own model and skills, but inside the task it only sees the task (not your other chats or memories), and your phone only rings when the stage changes: needs you, ready to merge, merged or failed.
A preview on every PR
Every (non-draft) PR in a repo connected to a room of your workspace gets its own preview automatically, like Vercel or Netlify, no matter who wrote it: a Ghosty agent in the cloud, one in your terminal with ghosty-dev, or a person. Each push rebuilds it on the new commit, and its state shows in the PR's «Ghosty · Preview» check. It takes one of your workspace's slots; if they're all busy it waits in line and starts by itself when one frees up. Closing the PR shuts it down.
A PR opened by hand
A PR opened by hand or from a terminal doesn't need to go through Development: it gets its preview and review on its own (see «A preview on every PR»). If you want a Ghosty agent to keep writing it on its own branch, use POST /api/v2/me/dev-runs with {"repo":"…","pr":73,"writer":"cloud"} (or ghosty dev run <repo> --pr 73 --writer cloud).
When it depends on another PR
If the agent needs something from another PR in the same repo that isn't merged yet, it doesn't ask you: it declares the wait (dev_run_wait_for) and the task shows «Waiting for #N», in gray, asking nothing of you. As soon as that PR is merged, the agent brings main into its branch and carries on by itself. If the PR is closed without merging, then it asks you. If you don't want to wait, tell it what to do and it resumes. The API returns phase: "blocked" with blockedBy: { pr, url }.
The task sheet
Every cloud task has a sheet: status, preview, CI, review, smoke, commit, branch, PR and open requests. Ghosty posts it as a pinned «👻 Ficha del pendiente» comment on the PR and the issue and edits it in place on every change. The preview also shows up as a deployment of the commit, with GitHub's «View deployment» button. The link asks for your Ghosty session, so it never exposes a key.
It's the same sheet the coding agent receives, the one you see in Ghosty and the one the API returns (ficha in GET /api/v2/me/dev-runs/{id}?detail=1). An agent in your terminal reads it with ghosty-dev show.
Where you see them
The task's Checks tab starts with the review of the current commit: its findings with severity and file:line (the source is the PR's «Ghosty Review» check), each with «Fix it» or «Leave it», which reach the agent as one more request. Below it, Lighthouse, one card per merge gate (CI, smoke, review, evidence) and, in two columns, the smoke routes and the CI checks with failures first. If the smoke fails, the agent gets what failed and fixes it on its own.
The box's network
The box where the agent writes should only reach what your repo needs: GitHub, package registries and Node, Prisma and Playwright downloads, plus the hosts already in your variables (your remote database, your APIs). If it uses anything else, declare it in .ghosty/dev.md:
Today it runs in audit: nothing is blocked, it only records which domains the box reached outside the list, and Checks shows them under «Box network». That way a malicious package or a trap instruction can't ship your variables to someone else's server without you seeing it.
After the merge
The task header follows your base branch deploy: «Deploying…» with a link to the run, «In production» with a link to your site (the repo's homepage) or «Deploy failed» with the log.