Production readiness scanner for MCP servers and agentic AI tools
Note: For security scanning, see Cisco's MCP Scanner. This tool focuses on operational readiness β whether your MCP tools will behave reliably in production.
MCP Readiness Scanner analyzes MCP tool definitions and configurations for operational issues like:
- Missing timeout guards β Will operations hang indefinitely?
- Unsafe retry loops β Could retries cause resource exhaustion?
- Silent failure paths β Are errors properly surfaced?
- Overloaded tool scope β Is the tool trying to do too much?
- Missing error schemas β Can agents handle failures programmatically?
# Install
pip install mcp-readiness-scanner
# Scan a single tool definition
mcp-readiness scan-tool --tool my_tool.json
# Scan multiple tool definitions
mcp-readiness scan-tools tool1.json tool2.json --aggregate
# Scan with glob patterns
mcp-readiness scan-tools "tools/**/*.json" --glob --format markdown
# Scan an MCP config
mcp-readiness scan-config --config-file ~/.config/mcp/config.json
# List available providers
mcp-readiness list-providersNo API keys required. Works out of the box with zero external dependencies.
Enable tab completion for your shell:
# Bash
_MCP_READINESS_COMPLETE=bash_source mcp-readiness > ~/.mcp-readiness-complete.bash
echo 'source ~/.mcp-readiness-complete.bash' >> ~/.bashrc
# Zsh
_MCP_READINESS_COMPLETE=zsh_source mcp-readiness > ~/.mcp-readiness-complete.zsh
echo 'source ~/.mcp-readiness-complete.zsh' >> ~/.zshrc
# Fish
_MCP_READINESS_COMPLETE=fish_source mcp-readiness > ~/.config/fish/completions/mcp-readiness.fish$ mcp-readiness scan-tool --tool examples/sample_tool_definitions/bad_tool.json --format markdown
# MCP Readiness Scan Report
## Summary
**Target:** `examples/sample_tool_definitions/bad_tool.json`
**Readiness Score:** **25/100** (Critical)
**Production Ready:** No β
### Findings Overview
| Severity | Count |
|----------|-------|
| π΄ Critical | 0 |
| π High | 1 |
| π‘ Medium | 4 |
| π΅ Low | 2 |
| βͺ Info | 0 |
## Findings
### π High (1)
#### 1. No timeout configuration
- **Category:** Missing Timeout Guard
- **Location:** `tool.do_everything`
Tool 'do_everything' does not specify a timeout. Operations may hang indefinitely...
Suppress false positives or intentional deviations:
# Suppress specific rules via CLI
mcp-readiness scan-tool --tool my_tool.json --ignore-rules HEUR-001,YARA-002
# Use an ignore file
mcp-readiness scan-tool --tool my_tool.json --ignore-file .mcp-readiness-ignore
# Show what was suppressed
mcp-readiness scan-tool --tool my_tool.json --ignore-rules HEUR-001 --show-suppressedOr add inline suppression to your tool definition:
{
"name": "my_tool",
"description": "Does something useful",
"mcp-readiness-ignore": ["HEUR-001", "HEUR-003"]
}| Provider | Status | Dependencies | Description |
|---|---|---|---|
| Heuristic | β Always Available | None | Static analysis for common issues |
| YARA | Optional | yara-python |
Pattern matching on metadata |
| OPA | Optional | opa binary |
Policy-based checks with Rego |
| LLM Judge | Disabled by default | LiteLLM + model | Semantic analysis |
- JSON β For CI pipelines and programmatic consumption
- Markdown β For PR comments and human review
- SARIF β For GitHub Code Scanning integration
- HTML β Self-contained interactive report (no external dependencies)
# Generate an HTML report
mcp-readiness scan-tool --tool my_tool.json --format html --output report.htmlHTML reports include:
- Interactive filtering by severity
- Collapsible finding details
- Dark/light theme support via CSS media queries
- Single-file format (no external CSS/JS)
| Category | Description |
|---|---|
silent_failure_path |
Tool may fail without surfacing errors |
non_deterministic_response |
Response format varies unpredictably |
missing_timeout_guard |
Operations may hang indefinitely |
no_observability_hooks |
Lacks logging, metrics, or tracing |
unsafe_retry_loop |
Retry logic may cause resource exhaustion |
overloaded_tool_scope |
Too many capabilities in one tool |
no_fallback_contract |
No graceful degradation defined |
missing_error_schema |
Error responses lack structure |
# Basic installation
pip install mcp-readiness-scanner
# With YARA support
pip install mcp-readiness-scanner[yara]
# With all optional dependencies
pip install mcp-readiness-scanner[all]# For YARA pattern matching
pip install yara-python
# For OPA policy checks
brew install opa # macOS
# or download from https://www.openpolicyagent.org/
# For LLM semantic analysis
pip install litellm
export MCP_READINESS_LLM_MODEL=ollama/llama2 # or gpt-4, claude-3-sonnet, etc.Add to your .pre-commit-config.yaml:
repos:
- repo: https://github.com/nik-kale/mcp-readiness-scanner
rev: v0.1.0 # Use the latest version
hooks:
- id: mcp-readiness-scan-tool
# Scans files matching *tool*.json
- id: mcp-readiness-scan-config
# Scans files matching mcp*config*.json
- id: mcp-readiness-scan-all
# Scans all .json filesThen run:
pre-commit install
pre-commit run --all-filesname: MCP Readiness Check
on: [push, pull_request]
jobs:
scan:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: '3.11'
- run: pip install mcp-readiness-scanner
- run: mcp-readiness scan-tool --tool tool.json --format sarif -o results.sarif
- uses: github/codeql-action/upload-sarif@v3
with:
sarif_file: results.sarif| Code | Meaning |
|---|---|
| 0 | Success (no critical/high findings) |
| 1 | High severity findings found |
| 2 | Critical findings found |
Create .mcp-readiness.toml in your project:
[scan]
fail_on_critical = true
fail_on_high = false
min_score = 70
max_concurrent_providers = 4 # Limit concurrent provider execution
provider_timeout = 30 # Timeout per provider in seconds
[heuristic]
max_capabilities = 10
[yara]
enabled = true
[llm]
enabled = false # Disabled by default
model = "ollama/llama2"Or use environment variables:
export MCP_READINESS_SCAN_FAIL_ON_CRITICAL=true
export MCP_READINESS_SCAN_MIN_SCORE=70import asyncio
from mcpreadiness import ScanOrchestrator
from mcpreadiness.providers import HeuristicProvider
async def main():
orchestrator = ScanOrchestrator()
orchestrator.register_provider(HeuristicProvider())
result = await orchestrator.scan_tool({
"name": "my_tool",
"description": "Does something useful",
"timeout": 30000,
})
print(f"Score: {result.readiness_score}/100")
print(f"Ready: {result.is_production_ready}")
asyncio.run(main())- Architecture β System design and components
- Taxonomy β Operational risk categories explained
- Providers β How to use and create providers
- Usage β Detailed CLI and configuration guide
Contributions are welcome! Please see our contributing guidelines.
# Development setup
git clone https://github.com/mcp-readiness/scanner
cd scanner
pip install -e ".[dev]"
# Run tests
pytest
# Run linting
ruff check mcpreadiness testsApache-2.0 β See LICENSE for details.
MCP Readiness Scanner β Because production reliability matters.
