A comprehensive Model Context Protocol (MCP) server that provides advanced GitHub project management capabilities with AI-powered task management and complete requirements traceability. Transform your project ideas into actionable tasks with a full end-to-end pipeline from project ideas to GitHub issues, sprints, and milestones.
This server implements the Model Context Protocol to provide comprehensive GitHub project management with advanced AI capabilities. Beyond traditional project management, it offers AI-powered task generation, requirements traceability, and intelligent project planning through GitHub's GraphQL API while maintaining state and handling errors according to MCP specifications.
- 16 Compound Tools (152 actions): Progressive-disclosure API — AI agents see 16 tools instead of 131, with
discover_toolsfor runtime exploration - AI-Powered: Transform project ideas into comprehensive PRDs and actionable tasks using multiple AI providers
- Agent Orchestration: Autonomous AI agent task assignment, heartbeat monitoring, budget enforcement, and work product tracking
- PRD-to-Issues Pipeline: Materialize AI-generated tasks into GitHub milestones, sprints, and issues with dependency-driven sequencing
- Complete Traceability: Full end-to-end tracking from business requirements → features → use cases → tasks
- Intelligent Analysis: AI-powered complexity analysis, effort estimation, and task recommendations
- Professional Standards: IEEE 830 compliant requirements documentation with enterprise-grade change management
- Overview
- Quick Start
- Key Features
- Installation
- Configuration
- Usage
- Agent Orchestration
- Architecture
- Contributing
- License
- References
- Current Status
# Install the package globally
npm install -g mcp-github-project-manager
# Set up your environment variables
export GITHUB_TOKEN="your_github_token"
export GITHUB_OWNER="your_github_username_or_organization"
export GITHUB_REPO="your_repository_name"
# Run the MCP server
mcp-github-project-manager# Build the Docker image
docker build -t mcp-github-project-manager .
# Run with environment variables
docker run -it \
-e GITHUB_TOKEN=your_github_token \
-e GITHUB_OWNER=your_github_username_or_organization \
-e GITHUB_REPO=your_repository_name \
mcp-github-project-manager- PRD Generation (
generate_prd): Transform project ideas into comprehensive Product Requirements Documents - Intelligent Task Breakdown (
parse_prd): AI-powered parsing of PRDs into actionable development tasks - Smart Feature Addition (
add_feature): Add new features with automatic impact analysis and task generation - Task Complexity Analysis (
analyze_task_complexity): Detailed AI analysis of task complexity, effort estimation, and risk assessment - Next Task Recommendations (
get_next_task): AI-powered recommendations for optimal task prioritization - Task Expansion (
expand_task): Break down complex tasks into manageable subtasks automatically - PRD Enhancement (
enhance_prd): Improve existing PRDs with AI-powered gap analysis and improvements - Task Materialization (
materialize_tasks): Convert generated tasks into real GitHub issues grouped into milestones and sprints with dependency-driven phase ordering
- Traceability-Based Context (Default): Rich context from requirements traceability without AI dependency
- AI-Enhanced Context (Optional): Comprehensive business, technical, and implementation context using AI
- Configurable Context Levels: Choose between minimal, standard, and full context depth
- Business Context: Extract business objectives, user impact, and success metrics
- Technical Context: Analyze technical constraints, architecture decisions, and integration points
- Implementation Guidance: AI-generated step-by-step implementation recommendations
- Contextual References: Links to relevant PRD sections, features, and technical specifications
- Enhanced Acceptance Criteria: Detailed, testable criteria with verification methods
- Graceful Degradation: Works perfectly without AI keys, falls back to traceability-based context
- End-to-End Tracking (
create_traceability_matrix): Full traceability from PRD business requirements → features → use cases → tasks - Bidirectional Links: Complete bidirectional traceability with impact analysis
- Use Case Management: Professional actor-goal-scenario use case generation and tracking
- Coverage Analysis: Comprehensive coverage metrics with gap identification
- Orphaned Task Detection: Identify tasks without requirements links
- Change Impact Analysis: Track requirement changes and their impact across all levels
- Anthropic Claude: Primary AI provider for complex reasoning
- OpenAI GPT: Alternative provider with fallback support
- Google Gemini: Additional AI capabilities
- Perplexity: Research and analysis tasks
- Automatic Fallback: Seamless switching between providers
- Project Management: Create and manage GitHub Projects (v2)
- Issues and Milestones: Full CRUD operations with advanced filtering
- Sprint Planning: Plan and manage development sprints with AI assistance
- Custom Fields and Views: Create different views (board, table, timeline, roadmap)
- Resource Versioning: Intelligent caching and optimistic locking
- MCP Implementation: Full MCP specification compliance with Zod validation
- GitHub Integration: GraphQL API integration with intelligent rate limiting
- Real-time Sync: Bidirectional synchronization with GitHub
- Webhook Integration: Real-time updates via GitHub webhooks
- Progress Tracking: Comprehensive metrics and progress reporting
- Event System: Track and replay project events
- Compound Tool API: 16 tools with
actionrouting replace 152 individual actions — simpler for AI agents - Agent Registry: Register, list, and deregister autonomous AI agents
- Task Checkout: Claim tasks with configurable selection strategies (priority, age, skills, deadline)
- Heartbeat Monitoring: Periodic liveness and progress reporting with stale-agent detection
- Work Product Tracking: Submit code changes, PRs, test results, and review artifacts
- Work Product Validation: Reviewers inspect work against acceptance criteria — not rubber stamps
- Budget Enforcement: Per-agent token budgets with warning thresholds and hard stops
- Activity Dashboard: Real-time view of all agent statuses, tasks, and budget consumption
- Subagent Hierarchy: Parent-child agent relationships with cascade deregistration
- Runtime Discovery:
discover_toolsmeta-tool for exploring available actions and schemas - PM Coordination: Project managers can assign specific tasks, monitor swarm status, and rebalance workloads
- Failure Recovery: PM decomposes rejected tasks into subtasks, re-assigns to agents
- Smart Task Routing: Capability-matched, budget-aware assignment (
smart_assign) - Project Convergence: Auto-approve/reject/decompose in one call (
converge_project) - Registry Cleanup: Remove stale agents automatically
- Task Materialization: Bridge from PRD tasks to GitHub issues with milestones, sprints, and project assignment
# Install the package globally
npm install -g mcp-github-project-manager
# Or install in your project
npm install mcp-github-project-manager# Clone the repository
git clone https://github.com/kunwarVivek/mcp-github-project-manager.git
cd mcp-github-project-manager
# Install dependencies
npm install
# or
pnpm install
# Build the project
npm run build# Copy the example environment file
cp .env.example .env
# Edit .env with your GitHub token and detailsGITHUB_TOKEN=your_github_token
GITHUB_OWNER=repository_owner
GITHUB_REPO=repository_nameThe GitHub token requires these permissions:
repo(Full repository access)project(Project access)write:org(Organization access)
AI keys are optional — without them, non-AI tools (project management, issues, sprints, agents) work fine. AI-powered features (ai_generate, ai_analyze, ai_plan) need at least one key.
# Global AI provider keys (set the ones you have)
ANTHROPIC_API_KEY=your_anthropic_api_key_here
OPENAI_API_KEY=your_openai_api_key_here
GOOGLE_API_KEY=your_google_api_key_here
PERPLEXITY_API_KEY=your_perplexity_api_key_here
# AI Model Configuration (no defaults — configure what you want to use)
AI_MAIN_MODEL=claude-sonnet-4-20250514 # general tasks
AI_PRD_MODEL=claude-opus-5 # PRD generation
AI_RESEARCH_MODEL=sonar-pro # research
AI_FALLBACK_MODEL=gpt-4o-mini # fallbackEach model role can independently use a different provider, API key, and endpoint.
Use openai-compatible for OpenRouter, Together, Groq, Ollama, or any OpenAI-protocol endpoint:
# OpenRouter for cheap daily tasks
AI_MAIN_PROVIDER=openai-compatible
AI_MAIN_BASE_URL=https://openrouter.ai/api/v1
AI_MAIN_API_KEY=sk-or-v1-your-key
AI_MAIN_MODEL=deepseek/deepseek-chat
# Direct Anthropic for PRD generation
AI_PRD_PROVIDER=anthropic
AI_PRD_API_KEY=sk-ant-your-key
AI_PRD_MODEL=claude-opus-5
# Local Ollama as fallback
AI_FALLBACK_PROVIDER=openai-compatible
AI_FALLBACK_BASE_URL=http://localhost:11434/v1
AI_FALLBACK_API_KEY=ollama
AI_FALLBACK_MODEL=llama3.1See the Configuration Guide for full per-role documentation.
- Sign up at Anthropic Console
- Create an API key
- Set
ANTHROPIC_API_KEYin your environment
- Sign up at OpenAI Platform
- Create an API key
- Set
OPENAI_API_KEYin your environment
- Sign up at Google AI Studio
- Create an API key
- Set
GOOGLE_API_KEYin your environment
- Sign up at Perplexity API
- Create an API key
- Set
PERPLEXITY_API_KEYin your environment
If installed globally:
# Start the MCP server using stdio transport
mcp-github-project-manager
# Start with environment variables
GITHUB_TOKEN=your_token mcp-github-project-manager
# Start with command line arguments
mcp-github-project-manager --token=your_token --owner=your_username --repo=your_repo
# Use a specific .env file
mcp-github-project-manager --env-file=.env.production
# Show verbose output
mcp-github-project-manager --verbose
# Display help information
mcp-github-project-manager --helpIf you're developing or running from source:
# Run directly with ts-node
node --loader ts-node/esm src/index.ts
# Run with command line arguments
node --loader ts-node/esm src/index.ts --token=your_token --owner=your_username --repo=your_repo
# Use the npm dev script (watches for changes)
npm run dev
# Display help information
node --loader ts-node/esm src/index.ts --help| Option | Short | Description |
|---|---|---|
--token <token> |
-t |
GitHub personal access token |
--owner <owner> |
-o |
GitHub repository owner (username or organization) |
--repo <repo> |
-r |
GitHub repository name |
--env-file <path> |
-e |
Path to .env file (default: .env in project root) |
--verbose |
-v |
Enable verbose logging |
--help |
-h |
Display help information |
--version |
Display version information |
Command line arguments take precedence over environment variables.
import { Server } from "mcp-github-project-manager";
// Create and start an MCP server instance
const server = new Server({
transport: "stdio", // or "http" for HTTP server
config: {
githubToken: process.env.GITHUB_TOKEN,
githubOwner: process.env.GITHUB_OWNER,
githubRepo: process.env.GITHUB_REPO
}
});
server.start();// Example using an MCP client library
import { McpClient } from "@modelcontextprotocol/client";
import { spawn } from "child_process";
// Create a child process running the MCP server
const serverProcess = spawn("mcp-github-project-manager", [], {
env: { ...process.env, GITHUB_TOKEN: "your_token" }
});
// Connect the MCP client to the server
const client = new McpClient({
transport: {
type: "process",
process: serverProcess
}
});
// Call MCP tools (compound API)
const result = await client.callTool("manage_project", {
action: "create",
title: "My Project",
owner: "myorg"
});For more examples, see the User Guide and the examples/ directory.
The MCP server exposes 16 compound tools (134 actions). Each tool accepts an action parameter that routes to the underlying operation. Use discover_tools to explore capabilities at runtime.
// 1. Create a project
{"tool": "manage_project", "arguments": {"action": "create", "title": "My Project", "owner": "myorg"}}
// 2. Create an issue
{"tool": "manage_issues", "arguments": {"action": "create", "title": "First Issue", "body": "Description here"}}
// 3. Register an AI agent
{"tool": "agent_work", "arguments": {"action": "register", "name": "claude-eng-1", "role": "engineer"}}
// 4. Agent checks out a task
{"tool": "agent_work", "arguments": {"action": "checkout_task", "agentId": "agent-abc123", "strategy": "highest_priority"}}
// 5. Discover available tools at runtime
{"tool": "discover_tools", "arguments": {}}
{"tool": "discover_tools", "arguments": {"group": "manage_issues", "action": "create", "includeSchemas": true}}// 1. Generate PRD from project idea
{"tool": "ai_generate", "arguments": {"action": "generate_prd", "projectIdea": "AI-powered task management with real-time collaboration", "projectName": "TaskAI Pro", "complexity": "high"}}
// 2. Parse PRD into tasks with traceability
{"tool": "ai_generate", "arguments": {"action": "parse_prd", "prdContent": "<generated PRD>", "maxTasks": 30, "createTraceabilityMatrix": true}}
// 3. Get next task recommendations
{"tool": "ai_generate", "arguments": {"action": "get_next_task", "sprintCapacity": 40, "teamSkills": ["react", "node.js", "typescript"]}}
// 4. Analyze task complexity
{"tool": "ai_generate", "arguments": {"action": "analyze_complexity", "taskTitle": "Implement real-time collaboration", "includeRisks": true}}
// 5. Break down complex tasks
{"tool": "ai_generate", "arguments": {"action": "expand_task", "taskTitle": "Build analytics dashboard", "currentComplexity": 8, "targetComplexity": 3}}// Add new feature with complete lifecycle
{"tool": "ai_generate", "arguments": {"action": "add_feature", "featureIdea": "Advanced Analytics Dashboard", "description": "Real-time analytics with AI insights", "expandToTasks": true}}
// Automatically creates: business requirements, use cases, tasks with traceability, lifecycle tracking
// Create traceability matrix
{"tool": "ai_generate", "arguments": {"action": "create_traceability_matrix", "projectId": "task-ai-pro", "validateCompleteness": true}}// List all 16 compound tools
{"tool": "discover_tools", "arguments": {}}
// Explore a specific tool's actions
{"tool": "discover_tools", "arguments": {"group": "ai_generate"}}
// Get full schema for a specific action
{"tool": "discover_tools", "arguments": {"group": "ai_generate", "action": "generate_prd", "includeSchemas": true}}Control which compound tools are exposed to MCP clients:
# Default: all tools exposed
MCP_TOOL_GROUPS=all
# Expose only project management tools
MCP_TOOL_GROUPS=core
# Add AI tools
MCP_TOOL_GROUPS=core,aidiscover_tools is always available regardless of this setting.
Context Generation Levels:
- Minimal: Basic traceability context only (fastest)
- Standard: Traceability + basic business context (default)
- Full: Complete AI-enhanced context with implementation guidance
The enhanced context generation functionality includes comprehensive test coverage:
src/__tests__/TaskContextGenerationService.test.ts- Core context generation service testssrc/__tests__/TaskGenerationService.enhanced.test.ts- Enhanced task generation integration testssrc/__tests__/ParsePRDTool.enhanced.test.ts- Tool-level context generation tests
- Traceability-based context generation (default behavior)
- AI-enhanced context generation (when AI is available)
- Graceful fallback when AI services are unavailable
- Configuration validation and environment variable handling
- Error handling and resilience testing
- Integration testing with existing task generation pipeline
# Run all AI-related tests (includes context generation)
npm run test:ai
# Run specific context generation tests
npm test -- --testPathPattern="TaskContextGeneration"
npm test -- --testPathPattern="enhanced"
# Run all tests
npm testThe MCP GitHub Project Manager includes a comprehensive end-to-end testing suite that tests all MCP tools through the actual MCP interface with both mocked and real API calls.
- ✅ 40+ GitHub Project Management Tools - Complete CRUD operations for projects, milestones, issues, sprints, labels, and more
- ✅ 8 AI Task Management Tools - PRD generation, task parsing, complexity analysis, feature management, and traceability
- ✅ Complex Workflow Integration - Multi-tool workflows and real-world project management scenarios
- ✅ Real API Testing - Optional testing with actual GitHub and AI APIs
- ✅ Schema Validation - Comprehensive argument validation for all tools
- ✅ Error Handling - Graceful error handling and recovery testing
# Run comprehensive E2E tests (mocked APIs)
npm run test:e2e:tools
# Run with real APIs (requires credentials)
npm run test:e2e:tools:real
# Use the interactive test runner
npm run test:e2e:runner
# Run specific test categories
npm run test:e2e:tools:github # GitHub tools only
npm run test:e2e:tools:ai # AI tools only
npm run test:e2e:tools:workflows # Integration workflows# Interactive test runner with options
node scripts/run-e2e-tests.js --help
# Examples:
node scripts/run-e2e-tests.js --real-api --github-only
node scripts/run-e2e-tests.js --build --verbose --timeout 120
node scripts/run-e2e-tests.js --ai-only --real-apiGitHub API (Required for GitHub tools):
GITHUB_TOKEN=ghp_your_github_token
GITHUB_OWNER=your-github-username
GITHUB_REPO=your-test-repositoryAI APIs (Required for AI tools):
# At least one AI API key required
ANTHROPIC_API_KEY=sk-ant-your-anthropic-key
OPENAI_API_KEY=sk-your-openai-key
GOOGLE_API_KEY=your-google-ai-key
PERPLEXITY_API_KEY=pplx-your-perplexity-keyEnable Real API Testing:
E2E_REAL_API=true npm run test:e2e:tools:real- Tool Registration Validation - Verify all tools are properly registered with correct schemas
- MCP Protocol Compliance - Ensure all tools follow MCP specification
- Response Format Validation - Validate tool responses match expected formats
- Workflow Integration Testing - Test complex multi-tool workflows
- Credential Management - Graceful handling of missing credentials
- Performance Monitoring - Track tool execution performance
- Comprehensive Error Testing - Validate error handling and recovery
- 📖 Comprehensive E2E Testing Guide - Detailed testing documentation
- 🔧 Test Configuration - Jest configuration for E2E tests
- 🛠️ Test Utilities - Reusable test utilities
The E2E test suite ensures that all MCP tools work correctly both individually and in complex workflows, providing confidence in the reliability and integration of the entire system.
- ✅ Default traceability-based context (no AI required)
- ✅ AI-enhanced business context generation
- ✅ AI-enhanced technical context generation
- ✅ Implementation guidance generation
- ✅ Context merging and conflict resolution
- ✅ Error handling and graceful degradation
- ✅ Configuration validation and defaults
- ✅ Tool-level parameter validation
- ✅ Integration with existing traceability system
To install the MCP server in Claude Desktop:
{
"mcpServers": {
"github-project-manager": {
"command": "npx",
"args": ["-y", "mcp-github-project-manager"],
"env": {
"GITHUB_TOKEN": "your_github_token",
"GITHUB_OWNER": "your_username",
"GITHUB_REPO": "your_repo",
"AI_MAIN_PROVIDER": "openai-compatible",
"AI_MAIN_BASE_URL": "https://openrouter.ai/api/v1",
"AI_MAIN_API_KEY": "sk-or-v1-your-key",
"AI_MAIN_MODEL": "deepseek/deepseek-chat"
}
}
}
}Or with a direct provider key (simpler):
{
"mcpServers": {
"github-project-manager": {
"command": "npx",
"args": ["-y", "mcp-github-project-manager"],
"env": {
"GITHUB_TOKEN": "your_github_token",
"GITHUB_OWNER": "your_username",
"GITHUB_REPO": "your_repo",
"ANTHROPIC_API_KEY": "your_anthropic_api_key"
}
}
}
}For Claude Code CLI, run:
claude mcp add github-project-manager -- npx -y mcp-github-project-managerAdd this to your Roocode configuration:
{
"mcpServers": {
"github-project-manager": {
"command": "npx",
"args": ["-y", "mcp-github-project-manager"],
"env": {
"GITHUB_TOKEN": "your_github_token",
"GITHUB_OWNER": "your_username",
"GITHUB_REPO": "your_repo"
}
}
}
}Add this to your Windsurf MCP config file:
{
"mcpServers": {
"github-project-manager": {
"command": "npx",
"args": ["-y", "mcp-github-project-manager"],
"env": {
"GITHUB_TOKEN": "your_github_token",
"GITHUB_OWNER": "your_username",
"GITHUB_REPO": "your_repo"
}
}
}
}See Windsurf MCP docs for more information.
Add this to your VS Code MCP config file:
{
"servers": {
"github-project-manager": {
"type": "stdio",
"command": "npx",
"args": ["-y", "mcp-github-project-manager"],
"env": {
"GITHUB_TOKEN": "your_github_token",
"GITHUB_OWNER": "your_username",
"GITHUB_REPO": "your_repo"
}
}
}
}See VS Code MCP docs for more information.
Add this to your Cursor MCP config file:
{
"mcpServers": {
"github-project-manager": {
"command": "npx",
"args": ["-y", "mcp-github-project-manager"],
"env": {
"GITHUB_TOKEN": "your_github_token",
"GITHUB_OWNER": "your_username",
"GITHUB_REPO": "your_repo"
}
}
}
}See Cursor MCP docs for more information.
If you prefer to run the MCP server in a Docker container:
- Build the Docker Image:
docker build -t mcp-gh-project .- Run the container:
docker run -d \
-e GITHUB_TOKEN=your_github_token \
-e GITHUB_OWNER=your_github_owner \
-e GITHUB_REPO=your_repository_name \
mcp-gh-project:latestOr with CLI arguments:
docker run -d mcp-gh-project:latest \
--github_token your_github_token \
--github_owner your_owner \
--github_repo your_repo- Configure Your MCP Client:
{
"mcpServers": {
"github-project-manager": {
"command": "docker",
"args": ["run", "-i", "--rm", "-e", "GITHUB_TOKEN", "-e", "GITHUB_OWNER", "-e", "GITHUB_REPO", "mcp-gh-project:latest"],
"env": {
"GITHUB_TOKEN": "your_token",
"GITHUB_OWNER": "your_owner",
"GITHUB_REPO": "your_repo"
}
}
}
} "env": {
"GITHUB_TOKEN": "your_github_token",
"GITHUB_OWNER": "your_username",
"GITHUB_REPO": "your_repo"
}
}
}
}
### Troubleshooting
#### Common Issues
1. **Module Not Found Errors**
If you encounter module resolution issues, try using `bunx` instead of `npx`:
```json
{
"mcpServers": {
"github-project-manager": {
"command": "bunx",
"args": ["-y", "mcp-github-project-manager"]
}
}
}
-
Windows-Specific Configuration
On Windows, you may need to use
cmdto run the command:{ "mcpServers": { "github-project-manager": { "command": "cmd", "args": [ "/c", "npx", "-y", "mcp-github-project-manager" ] } } } -
Permission Issues
If you encounter permission issues, make sure your GitHub token has the required permissions listed in the Configuration section.
The agent orchestration layer enables autonomous AI agents (Claude Code, Codex, Cursor, etc.) to self-assign tasks, report progress, submit work products, and operate within token budgets — all backed by GitHub-native storage.
Agents interact with the orchestration layer through two compound tools — agent_work (task lifecycle) and agent_manage (administration):
┌─────────────────────────────────────────────────────────────────────┐
│ Agent Orchestration Layer │
│ │
│ ┌───────────┐ ┌──────────────┐ ┌─────────────┐ ┌────────────┐ │
│ │ Agent │ │ Task │ │ Work │ │ Budget │ │
│ │ Registry │ │ Checkout │ │ Products │ │ Manager │ │
│ └───────────┘ └──────────────┘ └─────────────┘ └────────────┘ │
│ │ │ │ │ │
│ ▼ ▼ ▼ ▼ │
│ ┌─────────────────────────────────────────────────────────────┐ │
│ │ GitHub-Native Storage (Issues + Projects) │ │
│ │ • Agent registry → pinned issue (label: agent-registry) │ │
│ │ • Task claims → project custom fields │ │
│ │ • Work products → structured issue comments │ │
│ │ • Budgets → agent registry metadata │ │
│ └─────────────────────────────────────────────────────────────┘ │
│ │
└─────────────────────────────────────────────────────────────────────┘
| Tool | Action | Purpose |
|---|---|---|
agent_work |
register |
Register an AI agent with role, runtime, and capabilities |
agent_work |
checkout_task |
Claim the next available task using a selection strategy |
agent_work |
release_task |
Return a task to the pool (blocked, wrong skills, etc.) |
agent_work |
complete_task |
Mark a task as completed with a summary |
agent_work |
heartbeat |
Report liveness, progress %, branch, and blockers |
agent_work |
check_work_status |
Check the review/merge status of submitted work |
agent_work |
get_task_context |
Get enriched context for a task |
agent_manage |
list |
List registered agents, filter by role or status |
agent_manage |
deregister |
Remove an agent from the registry |
agent_manage |
get_activity |
Dashboard of all agents: tasks, progress, heartbeat, budget |
agent_manage |
submit_work_product |
Submit code changes with branch, PR, files, and test results |
agent_manage |
get_budget |
Check an agent's token budget (used, remaining, warnings) |
agent_manage |
set_budget |
Configure token budget, warning threshold, hard stop, reset period |
// 1. Register the agent
{"tool": "agent_work", "arguments": {"action": "register", "name": "claude-eng-1", "role": "engineer", "runtime": "claude-code", "capabilities": ["typescript", "react", "testing"]}}
// → { id: "agent-abc123", status: "idle", ... }
// 2. Check out a task
{"tool": "agent_work", "arguments": {"action": "checkout_task", "agentId": "agent-abc123", "strategy": "highest_priority"}}
// → { success: true, issueNumber: 42, issueTitle: "Add login form", branchSuggestion: "feat/42-add-login-form" }
// 3. Get full context
{"tool": "agent_work", "arguments": {"action": "get_task_context", "issueNumber": 42}}
// → { issue: {...}, milestone: {...}, acceptanceCriteria: [...], codingStandards: "..." }
// 4. Work on the task, sending heartbeats periodically
{"tool": "agent_work", "arguments": {"action": "heartbeat", "agentId": "agent-abc123", "status": "working", "taskId": "issue-42", "progress": 60, "progressSummary": "Tests passing, working on edge cases", "currentBranch": "feat/42-add-login-form"}}
// 5. Submit the work product
{"tool": "agent_manage", "arguments": {"action": "submit_work_product", "agentId": "agent-abc123", "taskId": "issue-42", "issueNumber": 42, "branch": "feat/42-add-login-form", "prNumber": 99, "summary": "Added login form with email/password validation"}}
// 6. Complete the task
{"tool": "agent_work", "arguments": {"action": "complete_task", "agentId": "agent-abc123", "taskId": "issue-42", "summary": "Implemented login form with validation and tests"}}
// 7. Repeat: checkout next task
{"tool": "agent_work", "arguments": {"action": "checkout_task", "agentId": "agent-abc123", "strategy": "highest_priority"}}Agents can register child agents using parentAgentId. This enables multi-agent architectures:
// Parent agent registers itself
{"tool": "agent_work", "arguments": {"action": "register", "name": "lead-agent", "role": "pm", "runtime": "claude-code"}}
// → { id: "agent-lead" }
// Parent spawns a sub-agent
{"tool": "agent_work", "arguments": {"action": "register", "name": "worker-1", "role": "engineer", "runtime": "claude-code", "parentAgentId": "agent-lead", "capabilities": ["typescript", "testing"]}}
// Deregistering the parent cascades to all children
{"tool": "agent_manage", "arguments": {"action": "deregister", "agentId": "agent-lead"}}
// → Removes lead-agent and worker-1Token budgets prevent runaway AI costs:
// Set a daily budget with 80% warning
{"tool": "agent_manage", "arguments": {"action": "set_budget", "agentId": "agent-abc123", "totalTokens": 500000, "warningThreshold": 0.8, "hardStop": true, "resetPeriod": "daily"}}
// Check budget status before expensive operations
{"tool": "agent_manage", "arguments": {"action": "get_budget", "agentId": "agent-abc123"}}
// → { usedTokens: 350000, remainingTokens: 150000, usagePercent: 70, isWarning: false, isExhausted: false }All orchestration state lives in your GitHub repository — no external database required:
| Data | Storage | Details |
|---|---|---|
| Agent registry | Pinned issue | JSON body on an issue labeled agent-registry |
| Task claims | Project custom fields | agent_claimed_by, agent_claimed_at, agent_status, agent_work_branch, agent_pr_number |
| Work products | Issue comments | Structured comments with <!-- agent-work-product: --> markers |
| Budgets | Agent metadata | Stored in the agent registry alongside each agent record |
| Heartbeats | Agent metadata | lastHeartbeat timestamp on the agent record |
| Constant | Default | Description |
|---|---|---|
| Heartbeat timeout | 30 minutes | Agent is considered stale after this period |
| Default budget | 500,000 tokens | Initial token budget per agent |
| Registry label | agent-registry |
GitHub issue label for the agent registry |
See the Tool Reference for detailed parameter documentation.
The server follows Clean Architecture principles with distinct layers:
- Domain Layer: Core entities, repository interfaces, and Zod schemas
- Infrastructure Layer: GitHub API integration and implementations
- Service Layer: Business logic coordination
- MCP Layer: Tool definitions and request handling
Contributions are welcome! Please see CONTRIBUTING.md for guidelines.
- Fork the repository
- Create a feature branch:
git checkout -b feature/amazing-feature - Commit your changes:
git commit -m 'Add some amazing feature' - Push to the branch:
git push origin feature/amazing-feature - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
| Feature | Status | Notes |
|---|---|---|
| Project Creation | ✅ Complete | Full support for v2 projects |
| Milestone Management | ✅ Complete | CRUD operations implemented |
| Sprint Planning | ✅ Complete | Including metrics tracking |
| Issue Management | ✅ Complete | With custom fields support |
| Resource Versioning | ✅ Complete | With optimistic locking and schema validation |
| Webhook Integration | ✅ Complete | Real-time updates; fail-closed HMAC signature validation + SSE streaming |
| Feature | Status | Notes |
|---|---|---|
| PRD Generation | ✅ Complete | Multi-provider AI support with comprehensive PRD creation |
| Task Generation | ✅ Complete | AI-powered parsing of PRDs into actionable tasks |
| Feature Addition | ✅ Complete | Smart feature addition with impact analysis |
| Task Complexity Analysis | ✅ Complete | Detailed AI analysis with risk assessment |
| Task Recommendations | ✅ Complete | AI-powered next task recommendations |
| Task Expansion | ✅ Complete | Break down complex tasks into subtasks |
| PRD Enhancement | ✅ Complete | AI-powered PRD improvement and gap analysis |
| Requirements Traceability | ✅ Complete | End-to-end traceability matrix with coverage analysis |
| Feature | Status | Notes |
|---|---|---|
| Business Requirements Extraction | ✅ Complete | Extract from PRD objectives and success metrics |
| Use Case Generation | ✅ Complete | Actor-goal-scenario structure with alternatives |
| Traceability Links | ✅ Complete | Bidirectional links with impact analysis |
| Coverage Analysis | ✅ Complete | Gap identification and orphaned task detection |
| Change Tracking | ✅ Complete | Requirement change impact analysis |
| Verification Tracking | ✅ Complete | Test case mapping and verification status |
| Component | Status | Notes |
|---|---|---|
| Tool Definitions | ✅ Complete | All core tools implemented with Zod validation |
| Resource Management | ✅ Complete | Full CRUD operations with versioning |
| Security | ✅ Complete | Token validation, fail-closed webhook signatures, file-mounted secrets (SECRETS_DIR) |
| Error Handling | ✅ Complete | According to MCP specifications |
| Transport | ✅ Complete | Stdio and HTTP support |
See .planning/STATUS.md for detailed implementation status. | Resource Management | ✅ Complete | With optimistic locking and relationship tracking | | Response Handling | ✅ Complete | Rich content formatting with multiple content types | | Error Handling | ✅ Complete | Comprehensive error mapping to MCP error codes | | State Management | ✅ Complete | With conflict resolution and rate limiting |
-
Dependency & SDK modernization (2026-07-15):
- Migrated to Vercel AI SDK v5 and Zod v4 (coupled upgrade; MCP SDK 1.29 accepts Zod 4)
- Aligned Octokit type packages with
@octokit/rest22 - Cleared the critical Handlebars vulnerability and all high-severity advisories
-
Architecture & reliability (2026-07-15):
- Decomposed the
ProjectManagementServicefacade (extractedIssueService,RoadmapService; automation delegates toProjectAutomationService) - Broke a circular dependency; health check now performs a real GitHub rate-limit probe
- Fail-closed webhook signature validation; file-mounted secrets (
SECRETS_DIR) with rotation - Size-bounded cache eviction (
MAX_CACHE_ENTRIES) and a namespace-index cleanup fix
- Decomposed the
-
Enhanced Resource System:
- Added Zod schema validation for all resource types
- Implemented resource relationship tracking
- Created a centralized ResourceFactory for consistent resource access
-
Improved GitHub API Integration:
- Added intelligent rate limiting with automatic throttling
- Implemented pagination support for REST and GraphQL APIs
- Enhanced error handling with specific error types
-
Advanced Tool System:
- Created tool definition registry with Zod validation
- Implemented standardized tool response formatting
- Added example-based documentation for all tools
-
Rich Response Formatting:
- Added support for multiple content types (JSON, Markdown, HTML, Text)
- Implemented progress updates for long-running operations
- Added pagination support for large result sets
Remaining gaps prioritized for future development (updated 2026-07-15). The live,
code-verified status is in docs/remediation/GAP-TRACKER.md.
-
Distributed Caching:
- ResourceCache now has persistence (
CachePersistence) and size-bounded oldest-first eviction (MAX_CACHE_ENTRIES). Still single-instance only — no distributed/shared cache for multi-instance deployments.
- ResourceCache now has persistence (
-
Performance Optimization:
- No query batching for related resources
- Missing background refresh for frequently accessed resources
- Incomplete prefetching for related resources
-
Data Visualization and Reporting (roadmap phase 11, not yet built):
- No built-in visualization generators for metrics
- Missing report generation capabilities
- Limited time-series data analysis
Resolved since earlier snapshots: real-time webhook integration + SSE streaming, automation-rule management, cache persistence + eviction, and a fail-closed webhook signature check.
- Deployment Guide - Installation, Docker, and MCP client setup
- Configuration Guide - All configuration options
- Troubleshooting Guide - Common issues and solutions
- Tool Reference - 16 compound tools (134 actions) documented
- Architecture - System design and patterns
- API Reference - Service and infrastructure APIs
- Tutorials - Step-by-step guides
- User Guide - Detailed usage instructions
- Testing Guide - Test suite documentation
- Contributing - Development guidelines
- MCP Integration - MCP-specific details
For an interactive exploration of the API, open the API Explorer in your browser.
# Unit tests
npm test
# AI service/tool tests
npm run test:ai
# End-to-end tests
npm run test:e2e
# E2E MCP tool suite (mocked GitHub/AI)
npm run test:e2e:tools# Lint code
npm run lint
# Type check
npx tsc --noEmit
# Format code
npm run formatWe welcome contributions to the GitHub Project Manager MCP Server! Please see our Contributing Guide for details on: