Git PR MCP Server
Supports configuration via environment variables through .env files for settings like host, port, and GitHub authentication.
Provides core Git operations including status checks, branch management, diff analysis, commit history retrieval, and branch creation for repository management.
Enables GitHub-specific workflows including repository cloning, branch pushing, and PR creation and summarization using the GitHub API.
Click on "Install 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., "@Git PR MCP Servercreate a PR for the new login feature I just committed"
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.
Git PR MCP Server
A Model Context Protocol (MCP) server for Git and Pull Request operations, providing tools for repository management and PR workflows.
Built with FastMCP and runs in SSE mode by default on 0.0.0.0:8000.
Features
This MCP server provides the following tools and capabilities:
Core Git Operations (on specified repository path):
get_git_status: Get the current git status of a repository.
list_branches: List all branches in the repository (with optional remote branches).
create_pr_summary: Create a summary for a pull request based on git diff.
get_commit_history: Get commit history for a branch.
get_git_diff: Get git diff between commits, branches, or working directory.
Automated PR Workflow (operates on an internally managed "active" repository):
clone_repository: Clones a GitHub repository into a managed temporary directory, making it the "active" repository for subsequent operations. Automatically cleans up any previously active repository's temporary directory.
create_git_branch: Creates a new branch in the active repository.
write_file_in_repo: Creates or overwrites files within the active repository.
git_commit_changes: Stages all changes (
git add .) and commits them in the active repository.git_push_branch: Pushes a specified branch from the active repository to its remote origin.
create_github_pr: Creates a pull request on GitHub for the active repository using the PyGithub library. Requires
GITHUB_TOKEN.
State Management:
The server maintains the state of the currently "active" cloned repository (path, URL, owner, name) in an
active_repo_state.jsonfile. This allows some persistence across server restarts, though the temporary clone directory itself might be OS-managed.
Related MCP server: Git MCP Server
Installation
Clone this repository:
git clone <repository-url>
cd git-pr-mcpInstall using uv:
uv syncUsage
The server runs in SSE mode by default on 0.0.0.0:9999 and is configured via environment variables. Here's a sample .env file:
FASTMCP_HOST=0.0.0.0
FASTMCP_PORT=9999
GITHUB_TOKEN=your_github_tokenQuick Start
# Run with defaults (0.0.0.0:8000)
uv run python main.py
# Or run the server module directly
uv run python -m src.git_pr_mcp.serverYou can then access the MCP server at http://localhost:9999/sse.
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- AlicenseCqualityAmaintenanceA MCP server that bridges LLMs with GitHub repository management, enabling automated analysis of pull requests, issue management, tag creation, and release management through natural language.Last updated246Apache 2.0
- Alicense-qualityDmaintenanceAn MCP server that provides tools for interacting with Git repositories, enabling AI assistants to manage repositories, branches, commits, and files through a standardized interface.Last updated4,6651Apache 2.0
- AlicenseBqualityDmaintenanceAn MCP server that enables managing GitHub repositories, pull requests, issues, and more through natural language in Cursor or Claude Desktop.Last updated39324MIT
- Alicense-qualityDmaintenanceAn MCP server that enables AI agents to directly manage GitHub repositories, including PRs, issues, and code search, using natural language.Last updatedMIT
Related MCP Connectors
A MCP server built for developers enabling Git based project management with project and personal…
An MCP server that gives your AI access to the source code and docs of all public github repos
Driflyte MCP server which lets AI assistants query topic-specific knowledge from web and GitHub.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/peterj/git-pr-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server