Model Context Protocol

Connect AI Agents to
API Contract Governance

CodeRifts exposes 8 tools via the Model Context Protocol. Any MCP-compatible client — Claude Desktop, Cursor, Windsurf, or your own agent — can run preflight checks, diff schemas, and assess agent readiness before deploying API changes.

What is the Model Context Protocol?

MCP is an open standard that lets AI agents discover and call tools from external services. Instead of hardcoding API calls, agents read a manifest file (mcp.json) that describes available tools, their input schemas, and endpoints. The agent then calls whichever tools it needs to complete a task.

Discover

Agent reads mcp.json to learn what tools are available and what inputs they accept.

Call

Agent constructs a JSON request matching the tool's input_schema and sends it to the endpoint.

Act

Agent receives structured results and uses them to make decisions — block a deploy, warn a developer, or approve a merge.

8 Tools — Inputs & Outputs

Every tool is callable via any MCP-compatible client. Pass your API key in the x-api-key header.

Tool Schemas

Tool Input Output
coderifts.preflight_check Free repo, base_ref, head_ref, spec_path, workflow_type governance_risk, confidence_score, decision, top_factors
coderifts.explain_decision Pro analysis_id why_blocked, affected_consumers, patterns
coderifts.how_to_unblock Pro analysis_id compat_shim, rollback_path, migration_note
coderifts.estimate_incident_cost Pro analysis_id ECI, business_impact_summary
coderifts.agent_tool_check Pro tool_schema_before, tool_schema_after TOOL_RESULT_SHAPE_DRIFT, break_risk
coderifts.workflow_path_risk Pro workflow_tool_chain S_propagation, coupling_scores
coderifts.runtime_guard Pro endpoint_id S_resilience, instability_signal
coderifts.create_governance_note Pro analysis_id PR comment-ready + agent-readable summary

REST Endpoints

For direct API calls without an MCP client.

Tool(s) REST Endpoint
preflight_check / agent_tool_check / explain_decision / estimate_incident_cost / create_governance_note POST /api/v1/diff
agent_readiness_score POST /api/v1/agent-readiness-score
workflow_path_risk / agent_preflight POST /api/v1/agent/preflight
registry_validate POST /api/v1/registry-validate
traffic_analyze / runtime_guard POST /api/v1/traffic-analyze
mcp_diff POST /api/v1/mcp-diff

Test Your MCP Manifest

Paste your mcp.json URL or content below and get an instant agent readiness score.

Free Tier Limits

Start building with the free tier. Upgrade when you need higher limits or advanced tools.

Tier Requests / month Requests / minute Price
Free 50 10 $0
Pro Unlimited 60 $49 / repo / mo
Team Unlimited 120 $79 / repo / mo
Enterprise Unlimited Custom $999–3,000 / org / mo

Free tier is permanent. No credit card required. Pro and Team are per-repository.

Quickstart

Add CodeRifts to your MCP client in under 60 seconds. Choose your client below.

Claude Desktop

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

claude_desktop_config.json
{
  "mcpServers": {
    "coderifts": {
      "url": "https://coderifts.com/mcp.json",
      "headers": {
        "x-api-key": "YOUR_API_KEY"
      }
    }
  }
}

Restart Claude Desktop. You will see CodeRifts tools in the tool picker.

Cursor

Open Settings → MCP and add a new server:

.cursor/mcp.json
{
  "mcpServers": {
    "coderifts": {
      "url": "https://coderifts.com/mcp.json",
      "headers": {
        "x-api-key": "YOUR_API_KEY"
      }
    }
  }
}

Cursor will auto-discover all 8 tools. Use them in chat with @coderifts.

Windsurf

Open Settings → Cascade → MCP and add:

~/.windsurf/mcp.json
{
  "mcpServers": {
    "coderifts": {
      "url": "https://coderifts.com/mcp.json",
      "headers": {
        "x-api-key": "YOUR_API_KEY"
      }
    }
  }
}

Restart Windsurf. CodeRifts tools will appear in Cascade's tool list.

Custom Agent / curl

Fetch the manifest, then call any tool endpoint directly:

Step 1: Discover tools
curl -s https://coderifts.com/mcp.json | jq '.tools[].name'
Step 2: Call a tool
curl -X POST https://app.coderifts.com/api/v1/agent/preflight \
  -H "Content-Type: application/json" \
  -H "x-api-key: YOUR_API_KEY" \
  -d '{
    "tools_before": [{"name": "get_order", "inputSchema": {"type": "object", "properties": {"id": {"type": "string"}}}}],
    "tools_after": [{"name": "get_order", "inputSchema": {"type": "object", "properties": {"id": {"type": "integer"}}}}]
  }'

Compatible Clients

CodeRifts works with any client that supports the Model Context Protocol.

💬

Claude Desktop

Anthropic's desktop client with native MCP support

Supported
⌨️

Cursor

AI-first code editor with MCP tool integration

Supported
🌊

Windsurf

Codeium's IDE with Cascade MCP support

Supported
🤖

Custom Agents

Any agent that reads mcp.json and calls HTTP endpoints

Supported

How It Works

The MCP integration adds a discovery layer on top of the existing CodeRifts API. No new infrastructure required.

1

Agent discovers tools

The agent fetches https://coderifts.com/mcp.json and reads the list of 8 tools with their input schemas and endpoint URLs.

2

Agent calls a tool

The agent constructs a JSON payload matching the tool's input_schema and sends a POST request to the endpoint with your API key.

3

CodeRifts runs the analysis

The full analysis pipeline runs: dual-engine diff, behavioral drift detection, agent pattern scoring, and the V3 scoring engine with 11 components and reflex rules.

4

Agent receives structured results

The agent gets a JSON response with the decision (BLOCK / REQUIRE_APPROVAL / WARN / ALLOW), risk score, breaking changes, detected patterns, and mitigation templates. It can then act: block a deploy, request approval, or approve the merge.

Coming Q2 2026

Agent Governance SDK

A typed JavaScript/TypeScript SDK for programmatic access to every CodeRifts tool. Run preflight checks, explain decisions, and get unblock guidance — all from your agent code.

@coderifts/sdk
import { CodeRifts } from '@coderifts/sdk'

const cr = new CodeRifts({ apiKey: 'cr_live_...' })

const result = await cr.preflightCheck({
  repo: 'org/api-repo',
  baseRef: 'main',
  headRef: 'feature/payment-v2',
  workflowType: 'agent_tool'
})

if (result.decision === 'BLOCK') {
  const fix = await cr.howToUnblock({ analysisId: result.analysisId })
  // fix.compatShim, fix.migrationNote, fix.approvalNeeded
}

Join the waitlist — get notified when the SDK launches

Get Your API Key

Install the CodeRifts GitHub App to get started. Free tier includes the core diff engine. Pro tier unlocks all 8 MCP tools, agent-aware analysis, and the V3 scoring engine.

Already have an API key? Jump to the quickstart above.