Sponsored by Deepsite.site

Code Reviewer MCP Server

Created By
joaomj8 months ago
A code reviewer MCP powered by AI.
Content

Code Reviewer MCP Server

A GitHub Pull Request Code Review server using Model Context Protocol

This MCP server provides automated code review capabilities for GitHub pull requests by integrating with OpenRouter's AI models.

Features

  • Automated code reviews for GitHub pull requests
  • Detailed feedback on code quality, style and potential issues
  • Integration with OpenRouter's AI models (currently using Gemini 2.5 Pro)
  • Comprehensive logging for debugging

Requirements

  • A GitHub Personal Access Token (PAT) with repo scope for private repositories or public_repo scope for public repositories. This PAT is required to fetch pull request data.
  • An OpenRouter API Key.

Current Limitations

⚠️ Important: Currently this server only works with:

  • Open pull requests (not draft PRs)

Installation

  1. Clone this repository:
git clone https://github.com/joaomj/code-reviewer-mcp.git
cd code-reviewer-mcp
  1. Install dependencies:
npm install
  1. Set required environment variables:
export GITHUB_PAT=your_github_personal_access_token
export OPENROUTER_API_KEY=your_openrouter_api_key
  1. Build the server:
npm run build

Usage

To start the MCP server:

node build/index.js

The server will be available to any MCP-compatible client (like Claude Desktop).

Configuration

Add to your MCP client configuration:

{
  "mcpServers": {
    "code-reviewer-mcp": {
      "command": "node",
      "args": ["/path/to/code-reviewer-mcp/build/index.js"],
      "env": {
        "GITHUB_PAT": "your_github_token",
        "OPENROUTER_API_KEY": "your_openrouter_key"
      }
    }
  }
}

Development

For development with auto-rebuild:

npm run watch

To run tests:

npm test

Debugging

Use the built-in logging which outputs to stderr with detailed information about:

  • GitHub API requests
  • OpenRouter API calls
  • Processing steps
  • Any errors encountered

For more advanced debugging, use the MCP Inspector:

npm run inspector

Next Steps

Planned improvements and features:

  • Draft pull request analysis
  • Customizable review templates
  • Support for multiple AI models (OpenAI, Claude, etc.)
  • File-specific feedback
  • Rate limiting and caching

Contributing

Suggestions are welcome. Please open an issue first to discuss what you would like to change.

Recommend Servers
TraeBuild with Free GPT-4.1 & Claude 3.7. Fully MCP-Ready.
AiimagemultistyleA Model Context Protocol (MCP) server for image generation and manipulation using fal.ai's Stable Diffusion model.
WindsurfThe new purpose-built IDE to harness magic
Amap Maps高德地图官方 MCP Server
ChatWiseThe second fastest AI chatbot™
Tavily Mcp
Zhipu Web SearchZhipu Web Search MCP Server is a search engine specifically designed for large models. It integrates four search engines, allowing users to flexibly compare and switch between them. Building upon the web crawling and ranking capabilities of traditional search engines, it enhances intent recognition capabilities, returning results more suitable for large model processing (such as webpage titles, URLs, summaries, site names, site icons, etc.). This helps AI applications achieve "dynamic knowledge acquisition" and "precise scenario adaptation" capabilities.
TimeA Model Context Protocol server that provides time and timezone conversion capabilities. This server enables LLMs to get current time information and perform timezone conversions using IANA timezone names, with automatic system timezone detection.
Context7Context7 MCP Server -- Up-to-date code documentation for LLMs and AI code editors
Playwright McpPlaywright MCP server
BlenderBlenderMCP connects Blender to Claude AI through the Model Context Protocol (MCP), allowing Claude to directly interact with and control Blender. This integration enables prompt assisted 3D modeling, scene creation, and manipulation.
CursorThe AI Code Editor
EdgeOne Pages MCPAn MCP service designed for deploying HTML content to EdgeOne Pages and obtaining an accessible public URL.
Jina AI MCP ToolsA Model Context Protocol (MCP) server that integrates with Jina AI Search Foundation APIs.
Visual Studio Code - Open Source ("Code - OSS")Visual Studio Code
MCP AdvisorMCP Advisor & Installation - Use the right MCP server for your needs
DeepChatYour AI Partner on Desktop
Baidu Map百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Howtocook Mcp基于Anduin2017 / HowToCook (程序员在家做饭指南)的mcp server,帮你推荐菜谱、规划膳食,解决“今天吃什么“的世纪难题; Based on Anduin2017/HowToCook (Programmer's Guide to Cooking at Home), MCP Server helps you recommend recipes, plan meals, and solve the century old problem of "what to eat today"
MiniMax MCPOfficial MiniMax Model Context Protocol (MCP) server that enables interaction with powerful Text to Speech, image generation and video generation APIs.
Serper MCP ServerA Serper MCP Server