Github Pr Automation logo

Github Pr Automation

Automates GitHub PR checks, review resolution, stacked PRs, conflict detection, and merge-readiness workflows through MCP or a CLI.

Install Github Pr Automation

Run the project’s own setup commands, in order.

Setup steps from the project

github-pr-automation installs with its own commands rather than a config we can generate, so these are copied as-is. Run them in order in a terminal. Source: github.com

  1. 1. Install
    git clone https://github.com/jmalicki/github-pr-automation-mcp.git
    
  2. 2. Install
    cd github-pr-automation-mcp
    
  3. 3. Install
    npm install && npm run build
    
  4. 4. Install
    npm run install:cli:npm-link
    
  5. 5. Install
    npm install
    
  6. 6. Run
    npm run build
    

Overview

github-pr-automation MCP server connects AI clients and command-line workflows to GitHub pull requests through a stdio-based MCP process. It analyzes failing checks, extracts unresolved review feedback, manages stacked PR dependencies, detects conflicts, checks merge requirements, and resolves review threads. The CLI exposes the same operations for scripts and CI jobs, with JSON output for automation. Reach for it when PR maintenance involves repeated CI analysis, review cleanup, rebasing, or readiness checks.

Use cases

  • Analyze failing checks on a pull request and generate fix guidance
  • Collect unresolved human and bot review comments
  • Validate dependencies and rebase instructions for stacked pull requests
  • Check merge requirements and detect conflicts before merging
  • Resolve review threads from an automation script

Key features

  • GitHub PR CI failure analysis
  • Unresolved review and bot comment extraction
  • Stacked PR dependency management
  • Merge conflict and readiness checks
  • Squash-merge-aware rebasing
  • MCP and CLI interfaces

Security & health

What it can reach and how reliably it runs — from our own checks, not the maintainer’s claims.

ActiveLast checked Today

Recent health check succeeded.

4/4 checks healthy over the last 13d

How Github Pr Automation works

What github-pr-automation MCP server does

github-pr-automation coordinates common GitHub pull request maintenance tasks through MCP tools and a companion CLI. It works with PR identifiers in the owner/repository#number format and uses a GitHub token to access repository and pull request data.

Its main workflows include inspecting failed CI tests, finding unresolved review conversations, managing dependencies between stacked pull requests, checking merge conflicts, validating merge readiness, rebasing after an upstream squash merge, and resolving individual review threads. Review analysis can extract actionable suggestions from review bodies, including comments produced by tools such as CodeRabbit.

How it works

The MCP implementation communicates over stdio rather than HTTP. An MCP client starts the compiled Node.js process as a subprocess and exchanges JSON-RPC messages through standard input and output. It does not open a port or run as a persistent daemon.

The server uses GitHub API clients for pull request and review operations. Git is required for stacked PR workflows and related rebase operations. The CLI provides direct access to the same operations and can emit JSON for scripts, CI/CD pipelines, or other analysis tools.

Setup and configuration

Node.js 20 or newer is required, and the project is configured around Node.js 22 LTS. Git must also be available for operations that manipulate local history or stacked pull requests.

Build the project from its repository with:

Terminal
npm install
npm run build

Set GITHUB_TOKEN in the environment. The documented token permissions include repo for private repository control and read:org for organization membership access. The server can also read this value from a .env file when used through the CLI.

For MCP use, configure the client to launch node with the path to dist/index.js, and pass GITHUB_TOKEN in the process environment. The CLI can be installed with the project's npm-link, global, or interactive installer commands.

Tools and capabilities

  • get_failing_tests reads failed PR checks and returns targeted fix guidance. It can wait for CI, stop at the first failure, and paginate large result sets.
  • find_unresolved_comments locates unresolved review comments and conversations, optionally includes bot comments, extracts suggestions, and produces response commands. Results support pagination and sorting.
  • manage_stacked_prs checks dependency chains, identifies changes that need propagation, creates rebase or automation commands, and can connect test failures to automated fix loops.
  • detect_merge_conflicts checks for conflicts before merging, reports affected files, and suggests resolution approaches.
  • check_merge_readiness evaluates CI, approvals, branch protection, and other merge requirements, then reports missing conditions.
  • rebase_after_squash_merge uses a git rebase --onto strategy to skip commits represented by an upstream squash merge and rebase only the dependent work.
  • resolve_review_thread resolves a review thread or comment using its GraphQL node ID, with support for choosing a preferred target when both are supplied.

Limitations and notes

The server is designed for GitHub pull request workflows and requires a token with suitable repository permissions. MCP operation depends on a client that can launch stdio servers. Stacked PR and rebase features additionally depend on Git being installed and on the local repository state being suitable for the requested operation. Tool inputs include pagination and behavior options, so large check or review result sets may need multiple requests.

Reviews

No reviews yet — be the first to share how it worked for you.

Frequently Asked Questions about Github Pr Automation

github-pr-automation is an MCP server that connects AI clients to GitHub pull requests through stdio. Its main tools analyze failing tests, find unresolved review comments, manage stacked PRs, detect merge conflicts, check merge readiness, rebase after squash merges, and resolve review threads. A companion CLI exposes the same workflows for scripts.

Install dependencies with `npm install` and build it with `npm run build`, then configure an MCP client to launch `node` with the resulting `dist/index.js` path. Set `GITHUB_TOKEN` in the process environment. The CLI also supports npm-link, global, and interactive installation methods.

The server requires `GITHUB_TOKEN` for GitHub API access. The token should include `repo` access for private repository control and `read:org` for organization membership reads. The CLI can also load the variable from a `.env` file.

Yes, github-pr-automation works with Claude Desktop through its stdio MCP configuration. Add a server entry that runs Node.js against the built `dist/index.js` file and provide `GITHUB_TOKEN` in the entry's `env` object.

Related MCP servers

Add a badge to your READMEShow it’s listed — live SVG, Markdown or HTML.

AllMCPs Directory Badge

Full Badge Customizer

Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.

Badge Style:
Live Dynamic SVG PreviewGithub Pr Automation AllMCPs Directory Badge
Markdown (GitHub README)
[![AllMCPs](https://allmcps.com/api/badge/github-pr-automation?style=directory)](https://allmcps.com/mcp/github-pr-automation)
HTML Embed
<a href="https://allmcps.com/mcp/github-pr-automation"><img src="https://allmcps.com/api/badge/github-pr-automation?style=directory" alt="Github Pr Automation on AllMCPs" /></a>