Pre-deploy Checks (MCP)
You ship fast and you don't have a test suite. Pre-deploy launch checks let your coding agent (Claude Code, Cursor, Windsurf) make sure your critical flows still work before you hit deploy, so you ship without holding your breath. You connect the Opsis MCP server (opsis-mcp) to your agent; the agent reads your codebase and derives the flows that matter (checkout, signup, your app's primary action) from real routes, forms, and selectors. Opsis then runs each flow in a real Chromium browser on your machine and captures full evidence: video, trace, screenshots, console and network logs.
How a launch check flows
- Your agent calls
opsis_launch_check_guideand derives 2–6 critical flows from the codebase: routes, forms, and the real selectors in your JSX/HTML, not guesses from URLs. - For each flow it calls
opsis_run_flow_check. The MCP server runs the flow locally against your dev or preview server, recording video, trace, screenshots, console, and network evidence. - A flow passes when every step succeeds with no console errors and no failed requests. On failure, the agent gets the evidence paths plus a guard-railed safe-fix prompt; it applies the fix and re-runs the same check.
- When all flows have run, the agent submits the aggregate report with
opsis_submit_launch_report. The Pre-deploy checks stage on your project dashboard updates instantly with the verdict: Launch-ready: PASS or N ISSUES FOUND.
Setup (once per project)
Pre-deploy checks belong to a project, so create the project first by connecting PostHog with OAuth. Then:
- Open your project's Before Ship tab and expand “Run the check on your machine with your coding agent”, then create a named scoped MCP key (
opk_…). Copy it immediately: Opsis stores only its hash and cannot show it again. - Add the server to your coding agent. After creating the key, both snippets are pre-filled with your project's values and one-time plaintext key.
Claude Code (one command):
claude mcp add opsis \ -e OPSIS_APP_URL=https://<your-opsis-domain> \ -e OPSIS_PROJECT_ID=prj_xxxxxxxx \ -e OPSIS_MCP_KEY=opk_xxxxxxxx \ -- npx -y opsis-mcpCursor / Windsurf (
mcp.json):{ "mcpServers": { "opsis": { "command": "npx", "args": ["-y", "opsis-mcp"], "env": { "OPSIS_APP_URL": "https://<your-opsis-domain>", "OPSIS_PROJECT_ID": "prj_xxxxxxxx", "OPSIS_MCP_KEY": "opk_xxxxxxxx" } } } } - Make sure a Chromium browser binary is available on your machine. The MCP server checks this for you on first run and can fetch the binary if it's missing; if you prefer to install it yourself, your coding agent's setup guide shows the one command to run.
- Start your dev or preview server, then ask your agent, e.g.:
Run Opsis launch checks against my dev server on http://localhost:3000.
Evidence is stored locally under .opsis/predeploy/ in the repo your agent runs from. Check the latest result anytime with opsis_launch_status, or on the project dashboard, where the Pre-deploy checks stage shows Passed / Failing / Flaky with flow counts.
The launch-check tools
These four tools drive the launch-check loop above. The same MCP server also exposes a separate Pre-deploy Security Scan (an OWASP Top 10 check), documented on its own page.
| Tool | What it does |
|---|---|
opsis_launch_check_guide | Instructions for the agent: how to derive critical flows from the codebase. |
opsis_run_flow_check | Runs one flow locally in a real browser: full evidence, plus a guard-railed fix prompt on failure. |
opsis_submit_launch_report | Submits all results in one report, updating the dashboard stage and returns the verdict. |
opsis_launch_status | The latest launch-check status for the project. |
What pass and fail mean
- Pass: every step in the flow succeeded, with no console errors and no failed network requests.
- Fail: a step failed, a console error appeared, or a request failed; the agent receives local evidence paths and a safe-fix prompt scoped to what the evidence shows.
- Verdict:
Launch-ready: PASSwhen every flow passes;N ISSUES FOUNDlists how many flows need attention. The dashboard stage mirrors this as Passed, Failing, or Flaky.
Privacy
- The Opsis MCP server never reads your codebase; your coding agent does, on your machine.
- Only redacted flow results are sent to Opsis: title, route, status, a one-line summary, plus redacted console/network/page error lines and a copy-paste fix prompt. The raw video, traces, screenshots, and full logs stay local under
.opsis/predeploy/. fillvalues must be synthetic (the guide enforces this): fake emails liketest@example.com, never real user data.- The
opk_key is scoped to one project's launch-report API. It cannot read PostHog data, findings, or anything else in your dashboard.
Troubleshooting
| Symptom | Fix |
|---|---|
Invalid or missing MCP key | Re-copy the key from the project's Before Ship tab; keys can rotate when the server's encryption key changes. |
| Browser fails to launch | Install the Chromium browser binary on your machine (the coding agent's setup guide has the one-line command), then re-run. |
Flow fails immediately on goto | Your dev server isn't running, or the baseUrl is wrong; start the server and re-run. |
| Dashboard stage doesn't update | The report went to a different OPSIS_APP_URL or project; check the env values in your agent's MCP config against Settings. |