github-mcp

alokverma18/github-mcp Checked 2 hours ago

GitHub MCP Server

A Spring Boot-based custom MCP (Model Context Protocol) server that provides GitHub API integration for any MCP-compatible IDE or AI agent. 1. Configure Your IDE/Agent Add to your MCP configuration: 2. GitHub Token Create token at GitHub Settings > Developer settings > Personal access tokens with scopes: repo, read:user

Summary extracted from the README.

GitHub MCP Server

A Spring Boot-based custom MCP (Model Context Protocol) server that provides GitHub API integration for any MCP-compatible IDE or AI agent.

πŸš€ Quick Start

1. Configure Your IDE/Agent

Add to your MCP configuration:

{
  "github": {
    "serverUrl": "https://github-mcp.up.railway.app/mcp",
    "headers": { 
      "GITHUB_TOKEN": "ghp_your_token_here" 
    }
  }
}

2. GitHub Token

Create token at GitHub Settings > Developer settings > Personal access tokens with scopes: repo, read:user

πŸ› οΈ Available Tools

  • githubListRepositories - List repositories
  • githubGetAuthenticatedUser - Get user profile
  • githubGetUser - Get user by username
  • githubGetRepository - Get repository details
  • githubListBranches - List repository branches
  • githubListCommits - List repository commits
  • githubSearchRepositories - Search repositories
  • githubSearchCode - Search code in repository
  • githubAnalyzePullRequest - Analyze PR details

πŸ“Š Available Resources

  • mcp://github - GitHub overview
  • mcp://github/user - User profile
  • mcp://github/repositories - Repository list
  • mcp://github/stats - Account statistics
  • mcp://github/dashboard - Complete dashboard

πŸ—οΈ Architecture

IDE/Agent β†’ HTTP POST /mcp β†’ Spring Security β†’ Spring AI MCP β†’ GitHubTools β†’ GitHub API

🐳 Docker Deployment

Multi-stage Dockerfile for production:

  • Build stage: Maven compilation
  • Runtime stage: Lightweight JDK with JAR

πŸ”§ Development

  • Java 21 + Spring Boot 3.5.11
  • Spring AI MCP Framework
  • Railway-ready deployment
  • CORS enabled for web IDEs

πŸ“š Learn More

See LEARN.md for detailed architecture, MCP protocol, and development guide.

πŸ“„ License

MIT License