MCP Protocol Architecture
How Bootspring implements the Model Context Protocol.
Overview
The Model Context Protocol (MCP) is a standard for AI assistants to interact with external tools and resources. Bootspring implements an MCP server that exposes its functionality to AI clients like Claude.
Protocol Basics
Communication Flow
┌─────────────────┐ ┌─────────────────┐
│ AI Client │◄────────────▶│ MCP Server │
│ (Claude, etc.) │ Messages │ (Bootspring) │
└─────────────────┘ └─────────────────┘
Message Types
| Type | Direction | Purpose |
|---|---|---|
initialize | Client → Server | Establish connection |
tools/list | Client → Server | List available tools |
tools/call | Client → Server | Invoke a tool |
resources/list | Client → Server | List available resources |
resources/read | Client → Server | Read a resource |
Bootspring MCP Server
Server Implementation
Loading code block...
Tool System
Tool Definition
Loading code block...
Registered Tools
| Tool | Description |
|---|---|
bootspring_assist | Natural language assistant |
bootspring_context | Get project context |
bootspring_agent | Invoke expert agents |
bootspring_skill | Discover and apply skills |
bootspring_todo | Manage todos |
bootspring_generate | Regenerate context |
bootspring_workflow | Workflow operations |
bootspring_quality | Quality gates |
bootspring_prd | PRD management |
bootspring_loop | Development loops |
bootspring_seed | Seed operations |
bootspring_mvp | MVP generation |
bootspring_memory | Access memory |
bootspring_dashboard | Dashboard control |
bootspring_config | Configuration |
bootspring_analyze | Code analysis |
bootspring_feedback | Send feedback |
bootspring_status | Check status |
bootspring_orchestrator | Orchestrate workflows |
Tool Implementation Example
Loading code block...
Resource System
Resource Definition
Loading code block...
Registered Resources
| URI | Description |
|---|---|
project://context | Project context (CLAUDE.md) |
project://config | Bootspring configuration |
project://prd | Product Requirements |
project://todos | Todo list |
Resource Implementation
Loading code block...
Transport Layer
Stdio Transport
For Claude Desktop integration:
Loading code block...
Communication via stdin/stdout with JSON-RPC messages.
HTTP Transport
For web integrations:
Loading code block...
RESTful API with WebSocket support for streaming.
Message Format
JSON-RPC 2.0
All MCP messages use JSON-RPC 2.0:
Loading code block...
Streaming Responses
For long operations:
Loading code block...
Authentication
Session Authentication
Loading code block...
API Key Validation
Tools validate API keys for cloud operations:
Loading code block...
Error Handling
MCP Error Codes
| Code | Meaning |
|---|---|
| -32700 | Parse error |
| -32600 | Invalid request |
| -32601 | Method not found |
| -32602 | Invalid params |
| -32603 | Internal error |
Bootspring Errors
| Code | Meaning |
|---|---|
| 1001 | Agent not found |
| 1002 | Skill not found |
| 1003 | Authentication required |
| 1004 | Rate limit exceeded |
| 1005 | Entitlement required |
Client Configuration
Claude Desktop
Loading code block...
VS Code
Loading code block...
Debugging
Enable Debug Logging
Loading code block...
Log Output
mcp:server Received: tools/list
mcp:server Responding with 19 tools
mcp:server Received: tools/call bootspring_agent
mcp:tools Invoking agent: frontend-expert
mcp:tools Agent completed in 2340ms
mcp:server Responding with result
Performance
Connection Pooling
MCP server maintains connection pools:
Loading code block...
Response Caching
Cacheable responses are stored:
Loading code block...
Security
Input Validation
All tool inputs validated against schemas:
Loading code block...
Sandboxing
Tool execution is sandboxed:
- File access limited to project directory
- Network access controlled
- Resource limits enforced
Related
- MCP Tools - Tool documentation
- MCP Integration - Concepts
- CLI mcp - CLI commands