Skip to content
reaatechREAATECH

@reaatech/agent-runbook-mcp

npm v0.1.0

Exposes runbook analysis, generation, and validation capabilities as an MCP server that provides 16 tools for AI agents. It offers a `RunbookMCPServer` class and a factory function that communicates via stdio, requiring the `@modelcontextprotocol/sdk` at runtime.

@reaatech/agent-runbook-mcp

npm version License: MIT CI

MCP (Model Context Protocol) server for the Agent Runbook Generator. Exposes runbook analysis, generation, and validation capabilities as MCP tools consumable by AI coding agents like Claude Code, Cursor, and other MCP-compatible clients.

Installation

terminal
npm install @reaatech/agent-runbook-mcp @modelcontextprotocol/sdk
# or
pnpm add @reaatech/agent-runbook-mcp @modelcontextprotocol/sdk

Feature Overview

  • 16 MCP tools across 3 layers — analyze (5), generate (7), validate (4)
  • Stdio transport — connects via standard I/O for seamless agent integration
  • Rate limiting — configurable per-layer rate limits (30 RPM analyze/validate, 10 RPM generate)
  • Timeouts — configurable per-layer timeouts (60s analyze/validate, 300s generate)
  • Tool registry — each layer self-registers its tools with schema validation

Quick Start

As a Library

typescript
import { RunbookMCPServer, createMCPServer } from "@reaatech/agent-runbook-mcp";
 
const server = await createMCPServer({
  name: "agent-runbook-generator",
  version: "1.0.0",
  rateLimitGenerate: 10,
  timeoutGenerate: 300000,
});
 
await server.start();
// Server now listens on stdio — ready for MCP clients

As a CLI

terminal
npx agent-runbook-generator serve --port 3000

API Reference

Server

ExportKindDescription
RunbookMCPServerclassMCP server with tool registration and stdio transport
createMCPServerfunction(config?: Partial<MCPServerConfig>) => Promise<RunbookMCPServer>

MCPServerConfig: { name: string; version: string; rateLimitAnalyze?: number; rateLimitGenerate?: number; rateLimitValidate?: number; timeoutAnalyze?: number; timeoutGenerate?: number; timeoutValidate?: number }

MCP Tools

Layer 1 — Analyze (5 tools)

Tool NameDescription
runbook.analyze.repositoryScan repository structure, detect language, framework, entry points
runbook.analyze.dependenciesMap package dependencies and external services
runbook.analyze.failure_modesIdentify potential failure points and single points of failure
runbook.analyze.alertsExtract existing alert definitions from monitoring configs
runbook.analyze.health_checksAnalyze existing health checks and identify gaps

Layer 2 — Generate (7 tools)

Tool NameDescription
runbook.generate.fullGenerate a complete operator runbook with all sections
runbook.generate.alertsGenerate alert definitions with SLO and resource thresholds
runbook.generate.dashboardGenerate dashboard configuration for Grafana or CloudWatch
runbook.generate.rollbackGenerate rollback procedures with verification steps
runbook.generate.incident_workflowGenerate incident response workflows and escalation matrices
runbook.generate.service_mapGenerate service dependency graph with critical paths
runbook.generate.health_checksGenerate health check definitions with Kubernetes probes

Layer 3 — Validate (4 tools)

Tool NameDescription
runbook.validate.completenessCheck runbook for required sections and content
runbook.validate.accuracyValidate runbook accuracy against the repository
runbook.validate.linksVerify all cross-references and links in the runbook
runbook.validate.ciRun a CI-style validation gate with configurable thresholds

Tool Registration

FunctionReturnsDescription
registerAnalyzeToolsTool[]Registers all 5 Layer 1 analysis tools
registerGenerateToolsTool[]Registers all 7 Layer 2 generation tools
registerValidateToolsTool[]Registers all 4 Layer 3 validation tools

License

MIT