Sarcio MCP server

Review Sarcio bug reports and AI-drafted fixes from Claude or any Model Context Protocol (MCP) client, while approval stays with the people in your dashboard.

The Sarcio MCP server connects your AI assistant to your Sarcio workspace. Signed in as yourself, you can ask it to triage the report inbox, explain what a drafted patch actually changes, open a private preview of the fix on your real site, check what is live in production, and find out why a fix PR never opened. When a fix is right, it gives you the link to approve it. Sarcio only accepts approvals from a signed-in person, so the two-person rule for elevated-risk patches still holds.

  1. Add the server to your client

    The server is the @sarcio/mcp package, run with npx. Your client starts it; there is nothing to install globally. Tell it which workspace to use with SARCIO_WORKSPACE_URL.

    Claude Code

    Shell

    claude mcp add --transport stdio \  --env SARCIO_WORKSPACE_URL=https://acme.sarcio.io \  sarcio -- npx -y @sarcio/mcp

    Claude Desktop

    Add the server to claude_desktop_config.json, then restart Claude Desktop:

    claude_desktop_config.json

    {  "mcpServers": {    "sarcio": {      "command": "npx",      "args": ["-y", "@sarcio/mcp"],      "env": { "SARCIO_WORKSPACE_URL": "https://acme.sarcio.io" }    }  }}

    Any other MCP client

    Run it as a stdio server: the command is npx -y @sarcio/mcp, with SARCIO_WORKSPACE_URL=https://<your-workspace>.sarcio.io in its environment.

    Use your workspace address

    The address is always your workspace host, https://<slug>.sarcio.io, never www.sarcio.io or dashboard.sarcio.io. The server refuses those with a message saying so.
  2. Sign in as yourself

    Recommended: browser sign-in (OAuth 2.0 with PKCE)

    • Sign in to https://<your-workspace>.sarcio.io in your browser as usual.
    • Ask the assistant to sign in to Sarcio. It replies with a link.
    • Open the link in that browser, on the same computer the MCP server runs on (the sign-in finishes on a local address). Review the permissions and approve.

    The sign-in is remembered on this machine and renews itself. After 30 days unused you sign in again, with a warning beforehand.

    Headless: an API token

    For a setup with no browser, an admin creates a pat_ token on the dashboard's API tokens page. Set it as SARCIO_API_TOKEN next to the workspace address:

    JSON

    "env": {  "SARCIO_WORKSPACE_URL": "https://acme.sarcio.io",  "SARCIO_API_TOKEN": "pat_..."}

    A token is not a person, so it reaches less: reports, patches (read, reject, retire, redraft, retry a pull request), sites and the audit log, as its scopes allow. Previews, the live and orphaned patch lists, members, integrations and billing need the browser sign-in. The token is only ever sent to SARCIO_WORKSPACE_URL.

  3. Ask in your own words

    Two ready-made workflows appear in your client's prompt picker: Triage the Sarcio inbox and Review live Sarcio patches. Or ask directly, for example:

    • Triage today's reports on Meridian and tell me which drafted fixes look right.
    • What does the patch on report 3f2c… actually change? Would you rate it low or elevated risk?
    • Give me a preview link for that fix, and the link to approve it as low risk.
    • Which live patches no longer have a fix PR on the way, and what should I do about each?
    • Why didn't the pull request open for the checkout-button patch? Check the integrations too.

    Rejecting, retiring, redrafting and retrying a pull request act on your real workspace, so the assistant is told to confirm with you first.

Tools

Member means any workspace member, Admin or QA. Admin means the Admin role. Your role applies exactly as it does in the dashboard.

Getting connected

ToolWhat it doesRole
sarcio_loginSign in to your workspace as yourself. Returns a link to approve in your browser.Anyone
sarcio_logoutForget the stored sign-in on this machine.Anyone
sarcio_statusWhich workspace, how you are signed in, and when the sign-in needs renewing.Anyone

Triage reports

ToolWhat it doesRole
sarcio_list_reportsThe report inbox, filtered by status (TRIAGING, PATCH_DRAFTED, NOT_A_BUG, APPROVED, REJECTED), a page at a time.Member
sarcio_get_reportOne report with the visitor's captured console and network context, the AI triage reply, every drafted patch, and its dashboard link.Member
sarcio_regenerate_patchRedraft the fix, optionally with a steering note. Uses AI credits.Member

Review a fix

ToolWhat it doesRole
sarcio_get_patchA patch's operations, explanation, risk rating, approvals, expiry and fix PR (status, CI result, diff).Member
sarcio_preview_patchA link that applies the draft for you alone on the real site. Browser sign-in only.Member
sarcio_approve_patchExplains what your risk rating will do and links the report page where you approve. Never approves by itself.Member
sarcio_reject_patchReject a patch that is not live yet.Member

Run production

ToolWhat it doesRole
sarcio_list_live_patchesEverything live right now. Browser sign-in only.Member
sarcio_list_orphaned_patchesLive patches whose permanent fix is no longer on the way (PR closed, failed or never opened). Browser sign-in only.Member
sarcio_retire_patchTake a live patch down for every visitor immediately.Member
sarcio_retry_pull_requestReopen a failed fix PR with an API token, or link to the report page to do it with a browser sign-in. Uses AI credits.Member

Sites

ToolWhat it doesRole
sarcio_sites_summarySites with their repository and how many patches are live on each.Member
sarcio_get_siteOne site's repository, source paths, module and remote-build settings, and allowed origins.Member
sarcio_site_active_patchesThe signed patches one site serves right now.Member
sarcio_get_site_ticketingHow a site mirrors patches into Jira.Admin

Workspace oversight (read-only)

ToolWhat it doesRole
sarcio_list_membersMembers, roles and two-factor status.Admin
sarcio_audit_logThe audit trail, filterable by action or member.Admin
sarcio_workspaceWorkspace name, slug and billing status. Browser sign-in only.Member
sarcio_subscriptionPlan, usage and this month's AI credits.Admin
sarcio_list_integrationsGitHub, GitLab, Bitbucket and Jira connections and their warnings, never their tokens.Admin
sarcio_signing_keyThe public key clients verify patches against.Admin

What it deliberately can't do

Approve a patch

Sarcio accepts an approval only from a person signed in to the dashboard, and refuses one from the assistant's sign-in or an API token. When you approve you rate the risk: low goes live at once; elevated waits for a second, different member to approve too. So sarcio_approve_patch explains that choice and hands you the link to the report page. With a browser sign-in, sarcio_retry_pull_request does the same: it links the report page, where you retry the PR.

Change credentials or access

It cannot create, rotate or revoke API tokens, sidecar keys or signing keys. It cannot connect or remove integrations, add or remove members, change roles, or change sites, writing instructions, billing or workspace settings. Those stay in the dashboard. Bug reports come from anonymous visitors to your site, and an assistant that reads them must not be talkable into changing who has access. It never shows a secret either: integration listings carry no tokens.

Security

  • Least privilege. The browser sign-in asks only for read scopes plus patches:write: audit:read, billing:read, connectors:read, patches:read, reports:read, sites:read, users:read, workspace:read, patches:write. Your role still applies on top, so a QA member cannot read admin-only data.
  • Attributable. Actions taken through the assistant are recorded in the workspace audit log as the signed-in member, the same as dashboard actions.
  • Rate limits and credits apply unchanged. Redrafts are limited to 10 an hour per member and 5 an hour per report, and pull request retries to 3 an hour per patch. Both spend the workspace's AI credits.
  • Tokens stay local. Sign-in tokens are stored on your machine, in ~/.sarcio. Access tokens last 15 minutes, and refresh tokens rotate on every use.
  • Report text is untrusted input. The server tells the model to treat report text as data, and to confirm before rejecting, retiring or redrafting. That is also why no tool changes who has access.

Troubleshooting

  • “Not a Sarcio workspace address”. Use https://<your-workspace>.sarcio.io, not www.sarcio.io or dashboard.sarcio.io.
  • “Sign in first” in the browser. Sign in to the workspace in that browser, then open the link again.
  • 401. The sign-in lapsed, or the API token was revoked or expired. Sign in again or issue a new token.
  • 403. One of:
    • your role does not allow it (admin-only data);
    • the action is dashboard-only, for example approval;
    • the API token lacks a scope;
    • the workspace is locked for an unpaid balance, or canceled. Live patches keep serving, and an admin pays through the emailed link.
  • 402. The month's AI credits are spent, so retrying will not help. An admin can buy a credit pack or change plan in Settings.
  • 429. Rate limited. Wait the time the message gives.

License

@sarcio/mcp is licensed under the Business Source License 1.1. You may use it in production to connect your own applications and assistants to Sarcio under an active subscription or trial. Each version converts to Apache-2.0 on its Change Date. The MCP server is included on every plan.

Model Context Protocol is a trademark of LF Projects, LLC. Claude is a trademark of Anthropic. Sarcio works with MCP clients such as Claude; no endorsement by either is implied.

Ready to try it on your own site?

Create a workspace, add a site, and follow these steps on your own app.

Create a workspace