Company
About Tomosu Our Team
Platform
Platform & Agents Indexes How it works Solutions
Free Tools
Governance Impact
Resources
MCP FAQ Blogs News Book a call →
Model Context Protocol

Tomosu MCP: govern AI-generated code without leaving your editor.

Connect any MCP client — Claude Code, Claude Desktop, Cursor — to the Tomosu governance layer. Your assistant scans the code it just wrote, shows you the fixes, records what you accepted, and returns a Production Reliability Index score with the full report behind it.

Hosted endpointhttps://mcp.tomosu.ai/mcp
Transportsstreamable-http · sse · stdio
AuthOAuth, in-client
Surface7 tools · 3 prompts · 27 contexts
Step one

1. Connect the server

The hosted server needs no install. Point your client at https://mcp.tomosu.ai/mcp and it negotiates the rest. Pick the client you actually use:

Claude Code

claude mcp add --transport http tomosu https://mcp.tomosu.ai/mcp --scope user

Then run /mcp inside Claude Code to sign in. --scope user makes the server available in every project on this machine; drop it to add the server to the current project only.

Claude Desktop

Open Settings → Developer → Edit Config and add the server to claude_desktop_config.json:

{
  "mcpServers": {
    "tomosu": {
      "command": "npx",
      "args": ["-y", "mcp-remote", "https://mcp.tomosu.ai/mcp"]
    }
  }
}

Quit and reopen Claude Desktop. The Tomosu tools appear under the tools icon in the composer.

Cursor and other MCP clients

Any client that speaks streamable HTTP can use the same URL. Where the client asks for a command rather than a URL, use the mcp-remote bridge shown above.

Step two

2. Authenticate

Every tool is scoped to your account, so nothing works until you sign in. In Claude Code, run:

/mcp

Pick the Tomosu server and follow the browser prompt. The server issues your token and your client stores it; other clients run the same OAuth flow on first tool call.

If a tool answers “Not authenticated”, the OAuth flow has not completed or the token has expired. Re-run /mcp and sign in again.
End to end

3. From install to PRI score

This is the whole loop. Steps 3 to 7 are one conversation with your assistant — you are not calling these tools by hand.

01

Point the assistant at the repo

The scan is recorded against your GitHub URL, so the assistant resolves it first. It runs git remote get-url origin, converts an SSH remote (git@github.com:owner/repo.git) to HTTPS, and strips the trailing .git. If there is no git remote, the local directory path is used instead.

02

Ask for the scan

Say what you want checked. The assistant calls suggest_code with every file in a single call — the backend batches internally and merges the streamed chunks, so one call covers the whole set and produces one scan_uuid.

suggest_code(
  files=[{"filepath": "src/checkout.ts", "filecontent": "..."}],
  message="Analyze for reliability issues: crashes, race conditions, "
          "missing error handling, unhandled promise rejections",
  project_name="storefront",
  repo_path="https://github.com/acme/storefront",
  context=["reliability", "error", "data_integrity"]
)
03

Read the recommendations

Each one comes back with a severity, a category, the line range, and complete before/after code blocks. The scan also returns <scan_uuid> — every step after this needs it.

04

Accept or reject, one at a time

This is the part that moves your score. Accepting marks the matching category rules as passed; rejecting only records the decision. Call it once per recommendation.

save_recommendation(
  scan_uuid="…",
  accepted=True,
  filename="src/checkout.ts",
  before_code="…",
  after_code="…",
  project_name="storefront",
  severity="high"
)
05

Get the PRI score

The report is where the score lives. You get a presigned URL, valid one hour, for a PDF carrying the PRI score and every sub-index behind it — Fragility, Governance Compliance, Code Volatility, Deployment Velocity, Drift, Runtime Signals and Escalation — plus category scores and the findings summary.

get_scan_report(
  scan_uuid="…",
  repo_path="https://github.com/acme/storefront"
)
06

Download it

The URL expires after an hour. Call get_scan_report again with the same scan_uuid for a fresh one — the report itself does not change.

curl -L "{returned_url}" -o tomosu-report.pdf
07

Watch it move

Scores are only useful as a trend. get_dashboard_analytics returns what the VisionBoard shows: scans over time, dev and prod request counts, accepts, and the category breakdown — for one project or all of them.

get_dashboard_analytics(project_name="storefront")
One scan, one UUID. Do not split a repository across several suggest_code calls to “help” the backend — you would get several unrelated scans and several partial scores instead of one PRI for the codebase.
Reference

Tool reference

Seven tools, all scoped to the authenticated account.

suggest_code

Scan files and return reliability recommendations

ParameterTypeNotes
fileslist[{filepath, filecontent}]requiredThe files to analyse. Send them all in one call — the backend batches internally and merges the chunks into one response.
messagestringrequiredWhat to focus on, e.g. “Analyze for reliability issues: crashes, race conditions, missing error handling”.
project_namestringoptionalProject or repo name. Used for dashboard tracking.
repo_pathstringoptionalGitHub URL, e.g. https://github.com/owner/repo. Run git remote get-url origin first, normalise SSH to HTTPS, strip .git.
contextlist[string]optional1–3 analysis categories from the table below.
scan_allbooleanoptionalDefaults to false.
workflow_uuidstringoptionalTies the scan to an existing workflow run.

Returns XML-wrapped markdown: a before/after code block per recommendation, with severity, line numbers and category — plus <scan_uuid>, which every later call needs.

save_recommendation

Accept or reject one recommendation

ParameterTypeNotes
scan_uuidstringrequiredThe UUID returned by suggest_code.
acceptedbooleanrequiredtrue accepts, false rejects.
filenamestringrequiredRelative path the recommendation applies to.
before_codestringrequiredThe original block, verbatim from the Before section.
after_codestringrequiredThe recommended replacement, verbatim from the After section.
project_namestringrequiredSame value you passed to suggest_code.
categorieslist[string]optionalCategories this recommendation belongs to.
titlestringoptionalShort label for the dashboard.
severitystringoptionalhigh, medium or low.

Returns A confirmation string. Accepting marks the matching category rules as passed, which moves the scan’s category scores. Rejecting logs the decision without changing scores.

get_scan_report

Get the PDF report, including the PRI score

ParameterTypeNotes
scan_uuidstringrequiredThe scan to report on.
repo_pathstringrequiredGitHub URL of the repo. Appears on the report.

Returns A presigned S3 URL, valid one hour. The PDF carries project meta, the PRI score and every sub-index (FI, GC, CV, DV, DI, RS, EEI), category scores and a findings summary. Call it again with the same UUID for a fresh URL.

get_dashboard_analytics

Read your VisionBoard dashboard

ParameterTypeNotes
project_namestringoptionalFilter to one project. Omit for every project you own.

Returns The same analytics that power the VisionBoard dashboard: total scans, dev/prod request counts, code accepts, category breakdown, recent observability logs and best practices, plus the raw JSON. Scoped to your account by your token.

get_tickets

Read Help Portal tickets

ParameterTypeNotes
ticket_numberstringoptionalA single ticket id such as 001. Omit for all of them.

Returns JSON per ticket: id, ticket_id, title, priority, status, source, file_path, current_code, recommended_fix, reasoning, supportability_impact and telemetry_signal.

get_zendesk_tickets

Read synced Zendesk tickets

ParameterTypeNotes
status_filterstringoptionalopen, pending, solved, closed.
priority_filterstringoptionalurgent, high, normal, low.

Returns Zendesk tickets synced after you connect the account. Connect it first under Settings → Integrations, or this returns nothing.

get_support_agent_data

Read everything on the Support Agent page

No parameters.

Returns One JSON object: Support Agent issues, signal and overall summaries, TomosuScore and extended scores (FI, DI, GC, RS, CV, DV), ticket statistics, accept/reject statistics, server configuration, and a per-issue array with category, severity, component, file, issue, root_cause, suggestion, before_code, after_code, confidence, impact_details and telemetry_signal.

Reference

Analysis contexts

Pass one to three of these in context to steer suggest_code. For the reliability workflow, ["reliability", "error", "data_integrity"] is the useful default.

ContextFocus
reliabilityCrashes, null refs, race conditions
errorError handling, missing try/catch
performanceLatency, memory, CPU efficiency
securityAuth, injection, data exposure
maintainabilityCode clarity, complexity
logsLogging gaps, unstructured logs
complianceRegulatory, data handling
testingTest coverage, flaky tests
api_observabilityAPI tracing, response monitoring
service_resilienceRetry logic, circuit breakers
data_integrityDB consistency, transaction safety
traffic_managementRate limiting, load handling
asynchronous_messagingQueue reliability, message loss
infrastructure_efficiencyResource utilisation
security_supportabilityAuth audit trails
knowledge_opsDocumentation quality
configuration_hygieneConfig drift, hardcoded values
database_performanceQuery optimisation, N+1
observabilityMetrics, tracing, alerting
dataops_integrityPipeline reliability
knowledgeops_maintainabilityKnowledge base quality
iac_finopsInfrastructure cost and drift
user_facing_diagnosticsUser-visible error messages
drift_resistanceConfig/state drift prevention
state_volatilityState mutation safety
architectural_governanceStructural compliance
support_agent_readinessSupport workflow quality
Reference

Prompt templates

The server also ships three prompts. They take code and an optional filepath, and drive suggest_code with the right contexts already chosen.

code_review

A full review across every quality category, returned as a summary table, before/after diffs per recommendation, and a score card with the top three actions.

security_audit

Security only: vulnerabilities, hardcoded secrets, PII exposure, injection risk, and authentication or authorisation gaps.

performance_review

Bottlenecks and optimisation: performance, database queries, caching, resource efficiency and infrastructure.

Enterprise

Run it yourself

The hosted endpoint suits most teams. Run your own when code must not leave your network.

With Docker Compose

The server sits alongside the python, node and agent backends and listens on 8080:

docker compose up -d

Then point Claude Desktop at your instance:

{
  "mcpServers": {
    "tomosu": {
      "command": "npx",
      "args": ["-y", "mcp-remote", "http://localhost:8080/sse"]
    }
  }
}

From source, over stdio

Requires Python 3.10+ and uv.

cd ai-dev/mcp-server
uv sync
uv run server.py

Exposing a local server to a remote client

To reach a local instance from a client that needs a public URL, tunnel port 8080 and set MCP_ISSUER_URL to the generated address — OAuth breaks if the issuer does not match what the client connected to. Then point the client at <your-url>/mcp.

brew install cloudflared
cloudflared tunnel --url http://localhost:8080

Environment

VariableDefaultPurpose
NODE_BACKEND_URLhttp://localhost:8001Node backend the tools call for scans, tickets and analytics.
AGENT_BACKEND_URLhttp://localhost:8002Agent backend for Support Agent data.
MCP_TRANSPORTstdiostdio, sse or streamable-http.
MCP_HOST0.0.0.0Bind address for the HTTP transports.
MCP_PORT8080Port for the HTTP transports.
MCP_ENABLE_AUTHtrueSet false only for local development without OAuth.
MCP_ISSUER_URLhttp://localhost:8080Public URL of this server. Must match what clients connect to.
GOOGLE_CLIENT_IDGoogle OAuth client, shared with the node backend.
GOOGLE_CLIENT_SECRETGoogle OAuth secret.
GOOGLE_CALLBACK_URLhttp://localhost:8080/google/callbackOAuth redirect target.

Testing the tools directly

npx @modelcontextprotocol/inspector uv run server.py
Support

Troubleshooting

A tool replies “Not authenticated”

The OAuth flow did not finish, or the token expired. Run /mcp again and sign in.

The report URL returns an error

Presigned URLs last one hour. Call get_scan_report again with the same scan_uuid.

get_zendesk_tickets returns nothing

Zendesk has to be connected first, under Settings → Integrations in the VisionBoard. Tickets sync at connection time.

A large scan takes a long time

It should. suggest_code runs real model calls and allows up to 30 minutes; the client, not the server, is usually what gives up first. Keep sending all files in one call — splitting them is slower and fragments the score.

The score did not move after fixes

Applying a fix in your editor changes nothing on its own. Scores move when save_recommendation records the decision with accepted=true.

Self-hosted OAuth loops

MCP_ISSUER_URL must exactly match the URL the client connects to, tunnel address included.

Wire the governance layer into the editor your team already uses.

The MCP server is included with Tomosu. If you are running AI-assisted development at scale and want the merge gate inside the loop, we are opening a small design partner cohort.

Book a call