Getting started (local-first)
Validate contract drift on your laptop before you wire hosted watches — same diff semantics in CLI, MCP, and the hosted API.
This path is for developers who want proof in five minutes without signing up. When you need scheduled snapshots and alerts, follow Quick start or Set up your first watch.
1 — Install the OSS client
git clone https://github.com/kioie/driftguard.git
cd driftguard && npm ci && npm run build
Build output includes the MCP server at dist/mcp/server.js and the CLI at dist/cli/check.js.
2 — Run your first diff
Compare two JSON payloads locally — no API key, no network:
npm run check -- diff '{"tools":[{"name":"search"}]}' '{"tools":[{"name":"find"}]}'
Breaking changes (removed tools, required fields dropped) exit with code 1. See Change records for severity rules.
3 — Connect MCP in your IDE
Add DriftGuard to Cursor or Claude Desktop so agents can call compare_json and parse_mcp_config offline. Step-by-step: Connect MCP in Cursor.
Full tool list: MCP tools reference.
4 — Preview watches from mcp.json
Parse your IDE config to see which remote URLs could become watches:
# MCP tool parse_mcp_config with your mcp.json body, or CLI:
npm run check -- parse-mcp path/to/mcp.json
Local preview does not create watches — use hosted suggest_watches or the console after you have an API key.
5 — Add hosted monitoring (optional)
- Free trial — one Pro watch, no credit card
- API key — unlock hosted MCP tools and CI gates
- GitHub Actions — coverage preview then enforce
Orchestrator gate (preflight)
Before an agent run, call POST /api/preflight or MCP get_agent_status to block runs when contracts are drifted. See Preflight guide.
Next steps
- Glossary — watch, snapshot, drift_status, agentAction
- Core concepts — watches, coverage, MCP monitoring
- All how-to guides