pr-mcp-server
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@pr-mcp-server Create a pull request with a review"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
pr-mcp-server
MCP (Model Context Protocol) server to automate Pull Request creation with AI. Analyzes Git branches, generates descriptions, titles, suggests reviewers, and performs code reviews. Designed to speed up reviews and improve PR quality.
β¨ Features
π Unified PR Workflow - Complete PR creation with one command ("Create a PR")
π§ AI-Powered Code Review - Context-aware review integrated into PR description
π Project Context Analysis - Detects TypeScript, i18n, state management, styling, testing frameworks
π PR Generation - Generate PR descriptions (standard, detailed, minimal templates | EN/FR)
π·οΈ Conventional Titles - Generate conventional PR titles (feat, fix, docs, etc.)
π¨ Smart GIFs - Automatically adds relevant GIFs based on work type
π₯ Auto Reviewers - Suggest and add reviewers based on contribution history
π Code Review - Automated code review with actionable feedback
π€ AI-Ready - Works with MCP Inspector, Cursor, and Claude Desktop
Related MCP server: Cursor Auto-Review MCP Server
π Documentation
Configuration Guide - Setup for Cursor, Claude Desktop, and MCP Inspector
Tools Reference - Detailed description of all available tools
GitHub Integration - Creating PRs on GitHub with auto-reviewers
Smart Reviewers - How reviewer detection works and troubleshooting
Smart GIF Selection - Automatic GIF selection and rate limit handling
Examples - Real-world usage examples
Architecture - Project structure and design
π Quick Start
Requirements
Node.js 18+
A Git repository
Installation
Local development:
npm install
npm run buildGlobal installation (recommended):
npm linkThis makes the pr-mcp-server command available globally.
Test with MCP Inspector
After npm link, run:
npx @modelcontextprotocol/inspector pr-mcp-serverThe Inspector will list all available tools. Run it inside a Git repository for full functionality.
Use with Cursor
Add to ~/.cursor/mcp.json:
{
"mcpServers": {
"pr-mcp-server": {
"command": "pr-mcp-server",
"cwd": "{workspaceFolder}"
}
}
}Restart Cursor, then ask:
"Create a PR" - Uses the unified workflow (recommended)
"Génère le titre de ma PR"
"Analyse ma branche et génère la description de la PR"
"CrΓ©e une PR sur GitHub avec des reviewers"
See Configuration Guide for more details.
π― Unified PR Creation Workflow (AI-Powered)
When you say "Create a PR", Claude (the AI) orchestrates an intelligent workflow:
How It Works
Call
reviewtool - Gathers comprehensive project context:Detects language/framework (TypeScript, PHP, Python, Go, Rust, etc.)
Identifies technologies (i18n, state management, styling, testing)
Extracts full diff and commit history
Returns structured prompt with all context
Claude analyzes and generates review - True AI-powered analysis:
Understands project conventions automatically
Identifies issues specific to YOUR tech stack
Provides intelligent, context-aware suggestions
Works for ANY language/framework (not just TypeScript!)
Call
create_pr_completewith review - Creates complete PR:Generates conventional commit-style title
Creates comprehensive description
Includes Claude's intelligent review
Adds smart GIF based on PR type
Creates/updates GitHub PR
Assigns reviewers from Git history
What Makes It Intelligent
Unlike rule-based tools, this uses Claude's intelligence to:
β Adapt to ANY project (PHP Laravel, Python Django, Go, Rust, etc.)
β Understand complex patterns and context
β Provide project-specific recommendations
β Detect violations of YOUR project's conventions
Example: In a PHP Laravel project, it will flag SQL injection vulnerabilities and suggest Eloquent ORM. In a React i18n project, it will catch hardcoded strings. All automatically!
Example Usage
# In Cursor or Claude Desktop, simply say:
"Create a PR"
# Claude will automatically:
# 1. Call 'review' to get project context
# 2. Analyze the context and generate intelligent review
# 3. Call 'create_pr_complete' with the review
# 4. Return the PR URL
# With specific options:
"Create a PR in English with the detailed template"
"Create a draft PR without reviewers"See AI_POWERED_REVIEW.md for technical details on how the AI review works.
π οΈ Available Tools
Tool | Description | Recommended |
| π Unified workflow - Complete PR creation with AI review | β YES |
| Create PR on GitHub with auto-reviewers (no AI review) | |
| Analyze differences between branches | |
| Generate conventional PR title | |
| Generate PR description | |
| Generate both title and description | |
| Suggest reviewers based on Git history | |
| Automated code review (context-aware) |
Recommendation: Use create_pr_complete for the best experience. It combines all features with intelligent, context-aware code review.
See Tools Reference for detailed documentation.
π¦ Useful Scripts
npm run build # Compile TypeScript to dist/
npm start # Start the MCP server
npm test # Run tests
npm run test:watch # Run tests in watch mode
npm run test:ui # Run tests with UI
npm run dev # Run in development modeπ Troubleshooting
"Not a git repository": Run the server inside a Git repo
ESM import issues: Use Node 18+ and build the project (
npm run build)Permission errors: Ensure your shell has access to the repo
"GitHub token is required": Set
GITHUB_TOKENenvironment variable"Branch does not exist on remote": Push your branch first
See GitHub Integration for more troubleshooting.
π License
MIT
Available Tools
8 toolsanalyze_branchA
Analyzes the differences between the current Git branch and a base branch. Automatically detects the main branch (dev/main/master) and current Git repository from the working directory. Use this when the user asks to analyze a branch, check changes, or understand what's in the current branch.
Inputs: detailed, baseBranch.
create_prA
Creates a Pull Request on GitHub WITHOUT AI review. RECOMMENDED WORKFLOW: (1) Call 'generate_pr_title' β get prompt, (2) YOU analyze and generate title, (3) Call 'generate_pr_description' β get prompt, (4) YOU analyze and generate description, (5) Call THIS tool with 'title' and 'description' parameters. If not provided, simple versions are auto-generated from commits/templates. NOTE: This tool does NOT include AI code review. For complete PR WITH AI review, use 'create_pr_complete' instead. This tool: analyzes branch, creates/updates PR, adds reviewers automatically. Requires GITHUB_TOKEN. Use when user asks to create a simple PR without code review.
Inputs: draft, title, language, template, +7 more.
create_pr_completeA
π UNIFIED PR CREATION WORKFLOW - WHEN USER SAYS 'Create a PR', YOU MUST FOLLOW THESE STEPS IN ORDER: (1) Call 'generate_pr_title' β get prompt, (2) YOU analyze and generate intelligent title, (3) Call 'generate_pr_description' β get prompt, (4) YOU analyze and generate intelligent description, (5) Call 'review' β get context/diff prompt, (6) YOU analyze and write code review, (7) Call THIS tool with 'title', 'description', and 'aiReviewText' parameters. IMPORTANT: ALL 3 parameters (title, description, aiReviewText) should be YOUR generated content, NOT the tool outputs (which are prompts). If any are omitted, simple fallbacks are auto-generated. This creates a professional PR with: YOUR intelligent title, YOUR comprehensive description, YOUR AI code review, smart GIF, automatic reviewer assignment. Works for ANY language/framework. Requires GITHUB_TOKEN.
Inputs: draft, title, language, template, +8 more.
generate_pr_completeA
Generates both a conventional commit-style PR title and a complete Pull Request description in one operation. Combines the functionality of generate_pr_title and generate_pr_description. Automatically analyzes the current Git branch from the working directory. Use this when the user wants both title and description generated together.
Inputs: language, template, baseBranch, includeStats, +1 more.
generate_pr_descriptionA
β οΈ CRITICAL: This tool returns an ANALYSIS PROMPT for YOU (Claude) to generate a description, NOT a final description. OUTPUT: You receive comprehensive context (project type, commits, files, diff sample) formatted as a detailed prompt with specific instructions. YOUR JOB: Analyze that context and generate an intelligent, well-structured PR description. The prompt includes format requirements (What/Why/How/Impact sections), language preferences (FR/EN), and style guidelines. YOU must read it, understand the changes, and write a clear description ready for GitHub. DO NOT return the prompt - generate YOUR description. Use when creating PR or when user asks for PR description. The generated description should then be passed to create_pr or create_pr_complete tools.
Inputs: title, language, template, includeStats.
generate_pr_titleA
β οΈ CRITICAL: This tool returns an ANALYSIS PROMPT for YOU (Claude) to generate a title, NOT a final title. OUTPUT: You receive comprehensive context about the code changes (commits, files, diff patterns) formatted as a prompt. YOUR JOB: Analyze that context and generate an intelligent conventional commit-style PR title (e.g., 'feat(auth): add OAuth support'). The prompt provides all the information you need to understand what changed. YOU must read it and create a concise, descriptive title that accurately reflects the changes. DO NOT return the prompt - generate YOUR title. Use when creating PR or when user asks for a PR title. The generated title should then be passed to create_pr or create_pr_complete tools.
Inputs: maxLength.
reviewA
β οΈ CRITICAL: This tool ONLY returns an ANALYSIS PROMPT for YOU (Claude), NOT a final review. OUTPUT: You receive comprehensive context (project type, diff, commits, structure) formatted as a detailed prompt with instructions. YOUR JOB: Analyze that context and generate the actual code review following the exact format specified in the prompt. The prompt includes everything you need: project context, full diff, testing framework, architecture details. YOU must read it, analyze the code changes, and write a concise review (max 10-15 lines) with sections: Summary, Critical Issues, Key Suggestions, Decision (APPROVE/REQUEST_CHANGES). DO NOT return the prompt itself - generate YOUR review. Works for ANY language/framework because context is provided. Use when user asks to review code or when creating PR with review.
Inputs: baseBranch.
suggest_reviewersA
Suggests code reviewers based on Git contribution history of modified files in the current branch. Automatically analyzes the working directory's Git repository. Use this when the user asks who should review the PR or to suggest reviewers.
Inputs: limit.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelogβ¦
TDQS
Scored across 8 tools
The tools have distinct purposes, but the similar names create_pr and create_pr_complete could confuse an agent without careful reading. The generate_* tools are clearly separated as prompt generators, and review is distinct. Detailed descriptions help, but the cognitive load is moderate.
Most tools follow a verb_noun pattern in snake_case, e.g., create_pr, generate_pr_title. However, 'review' is a single verb without a noun, and 'suggest_reviewers' uses plural. The pattern is largely consistent with minor deviations.
With 8 tools, the server covers the essential PR creation workflow (branch analysis, title/description generation, review, creation, reviewer suggestion) without being bloated or sparse. The count feels well-scoped for its purpose.
The server focuses on creating PRs with AI review, but lacks common PR lifecycle operations like listing, updating, merging, or commenting. For a 'pr-mcp-server', the surface is incomplete beyond the creation workflow, leaving notable gaps.
Maintenance
Related MCP Connectors
AI-native git hosting β repos, PRs, issues, CI gates, and AI code review over MCP (60 tools).
GitHub Copilot MCP: code, repo, PR, workflow tools for AI assistants.
A Model Context Protocol (MCP) application for automated GitHub PR analysis and issue management.β¦
A MCP server built for developers enabling Git based project management with project and personalβ¦
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceA MCP server that provides tools for analyzing git changes and suggesting appropriate PR templates, helping automate PR-related workflows.MIT
- AlicenseNot gradedqualityDmaintenanceAn MCP server that automates code reviews through linting, testing, and git diff analysis. It also generates conventional commit messages and detailed pull request descriptions based on file changes and code patterns.ISC
- FlicenseNot gradedqualityDmaintenanceAn MCP server that automates pull request reviews using multiple LLM providers (OpenAI, Claude, Gemini, Groq, Perplexity) and supports GitHub and Bitbucket with real-time webhook integration and interactive AI assistant commands.1-
- AlicenseNot gradedqualityDmaintenanceMCP server for automated code review using AI agents. It analyzes code diffs or file paths for bugs, security issues, and style violations.MIT