github-pr-review-mcp
Provides tools to review, comment, and manage pull requests on GitHub repositories using the GitHub REST 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., "@github-pr-review-mcpReview PR #12 on user/repo"
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.
GitHub PR Review MCP
A Model Context Protocol (MCP) server that provides GitHub PR review capabilities to LLMs in VSCode/Cursor and other compatible AI clients.
Features
π MVP Feature 1: Review PRs in GitHub
Get PR Reviews - Fetch all existing reviews for analysis
Get PR Comments - Retrieve all comments and discussions
Analyze PR Code - AI-powered code analysis with security checks and suggestions
Get PR Files - List all changed files with additions/deletions
Get PR Details - Comprehensive PR information including status, author, metrics
βοΈ MVP Feature 2: Implement Feedback & Reply to Reviews
Submit PR Review - Submit complete reviews with approval/changes/comments
Add Comments - Add general or line-specific comments to PRs
Reply to Reviews - Respond to existing review comments
Update PRs - Modify PR title, description, or state
π― MVP Feature 3: Diff-Aware Inline Comments & Pending Reviews
Get Diff Hunks - Retrieve diff hunks with precise line mapping for inline comments
Validate Comment Targets - Verify if a line/path is valid in the PR diff before commenting
Pending Review Management - Create, retrieve, and manage draft reviews
List Draft Comments - View all pending comments before submitting a review
No HTML Scraping - All operations use GitHub REST APIs for reliability
Related MCP server: Narad GitHub Agent
Quick Start
Prerequisites
Node.js 20.19.0 or higher
GitHub Personal Access Token with
repoandread:userscopes
Installation
Option 1: Global Installation (Recommended)
npm install -g github-pr-review-mcpOption 2: Development Setup
git clone https://github.com/jamesjfoong/github-pr-review-mcp.git
cd github-pr-review-mcp
npm install
npm run buildSetup
Get GitHub Token: Generate a Personal Access Token with scopes:
repo(full repository access)read:user(read user profile data)
Configure Environment:
cp .env.example .env # Edit .env and add your token: GITHUB_TOKEN=your_github_token_hereConfigure in Cursor/VSCode: Add to your MCP settings (usually in
~/Library/Application Support/Cursor/User/globalStorage/rooveterinaryinc.cursor-small/settings/cline_mcp_settings.json):{ "mcpServers": { "github-pr-review": { "command": "npx", "args": ["github-pr-review-mcp"] } } }
Available Tools
Tool | Description | Parameters |
| Get all reviews for a PR |
|
| Get all comments on a PR |
|
| AI code analysis with security/quality checks |
|
| List changed files with stats |
|
| Get comprehensive PR information |
|
| Submit a review (approve/request changes/comment) |
|
| Add general or line-specific comments |
|
| Update PR title, description, or state |
|
| Get diff hunks with line mapping for inline comment placement |
|
| Validate if a comment target exists in the PR diff |
|
| Create or reuse a pending review for draft comments |
|
| Get the current pending review (if any) |
|
| List all draft comments in the pending review |
|
Usage Examples
Example 1: Review a PR
π€: Please review PR #123 in microsoft/vscode
1. Get PR details: get_pr_details(owner: "microsoft", repo: "vscode", prNumber: 123)
2. Get changed files: get_pr_files(owner: "microsoft", repo: "vscode", prNumber: 123)
3. Analyze code: analyze_pr_code(owner: "microsoft", repo: "vscode", prNumber: 123)
4. Submit review: submit_pr_review(owner: "microsoft", repo: "vscode", prNumber: 123, body: "LGTM! Great work on...", event: "APPROVE")Example 2: Implement Feedback
π€: The reviewer asked me to fix the error handling in line 45 of src/utils.ts
1. Add line comment: add_pr_comment(owner: "owner", repo: "repo", prNumber: 123, body: "Fixed error handling as requested", path: "src/utils.ts", line: 45)
2. Update PR description: update_pr(owner: "owner", repo: "repo", prNumber: 123, body: "Updated PR description with changes made...")Example 3: Draft Review with Inline Comments (New!)
π€: Create a draft review with inline comments on PR #123
1. Ensure pending review exists: ensure_pending_review(owner: "owner", repo: "repo", prNumber: 123, body: "Draft review comments")
2. Get diff hunks to find valid lines: get_pr_diff_hunks(owner: "owner", repo: "repo", prNumber: 123)
3. Validate comment target: validate_pr_comment_target(owner: "owner", repo: "repo", prNumber: 123, path: "src/main.ts", line: 45, side: "RIGHT")
4. Add inline comment if valid: add_pr_comment(owner: "owner", repo: "repo", prNumber: 123, body: "Consider refactoring this method", path: "src/main.ts", line: 45)
5. List pending comments to verify: list_pending_review_comments(owner: "owner", repo: "repo", prNumber: 123)
6. Submit the review when ready: submit_pr_review(owner: "owner", repo: "repo", prNumber: 123, body: "Overall looks good!", event: "COMMENT")Example 4: AI-Powered PR Review with Custom Prompt
π€: Review PR #123 using AI with custom guidelines
1. Get review prompt: review_pr_with_prompt(owner: "owner", repo: "repo", prNumber: 123, customPrompt: "Focus on security vulnerabilities and performance issues")
2. Use the returned reviewPrompt with your LLM to generate a review
3. Format the LLM response into review comments
4. Submit review: submit_pr_review(owner: "owner", repo: "repo", prNumber: 123, body: "AI-generated review...", event: "COMMENT")Example 5: Automated Code Analysis
The analyze_pr_code tool automatically detects:
π Security issues: API key exposure, hardcoded passwords, XSS vulnerabilities
π§Ή Code smells: Console statements, debugger statements, TypeScript
anytypesπ Quality metrics: Large file changes, missing tests, complexity analysis
β Suggestions: Breaking large PRs, adding tests, security improvements
Development
AI Code Editors: If you're using Cursor, GitHub Copilot, or other AI code editors, this repository includes automatic configuration files:
.cursor/rules/- Project rules (always applied)
.cursor/agents/- Custom subagents for specialized tasks
.cursor/skills/- Agent skills for procedural workflows
.github/copilot-instructions.md- GitHub Copilot instructions
AGENTS.md- General AI agent instructions
Project Structure
github-pr-review-mcp/
βββ src/
β βββ index.ts # Main MCP server entry point
β βββ github-service.ts # GitHub API integration
β βββ code-analyzer.ts # Code analysis engine
β βββ types.ts # TypeScript type definitions
βββ dist/ # Compiled JavaScript output
βββ scripts/
β βββ setup.sh # Automated setup script
βββ package.jsonScripts
npm run build- Compile TypeScriptnpm run dev- Development mode with auto-reloadnpm start- Run compiled servernpm run prepublishOnly- Build before publishing
Contributing
Fork the repository
Create a feature branch:
git checkout -b feature/amazing-featureMake your changes
Add tests if applicable
Run
npm run buildto ensure it compilesSubmit a pull request
API Requirements
Your GitHub token needs these permissions:
Repository access:
reposcope for private repos, orpublic_repofor public repos onlyUser data:
read:userfor accessing user profile informationOptional:
write:discussionfor advanced discussion features
Troubleshooting
Common Issues
1. "GITHUB_TOKEN environment variable is required"
Solution: Copy
.env.exampleto.envand add your GitHub token
2. "Cannot find module" errors
Solution: Run
npm installto install dependencies
3. Rate limiting
The server includes automatic rate limiting and retry logic
GitHub API has limits: 5,000 requests/hour for authenticated requests
4. Permission errors
Ensure your GitHub token has
reposcope for the repositories you want to accessFor organization repos, you may need additional permissions
Debug Mode
Enable debug logging by setting in your .env:
DEBUG=trueRoadmap
Future Features
π Auto-merge capabilities
π§ͺ Test execution integration
π PR metrics and analytics
π€ Automated code fixes based on review comments
π Advanced search and filtering
π Reporting and dashboards
License
MIT License - see LICENSE file for details.
Support
π Documentation: GitHub Wiki
π¬ Discussions: GitHub Discussions
π Issues: Report bugs
π Security: See SECURITY.md
Author
James Jeremy Foong - @jamesjfoong
β Star this repo if you find it useful!
π Report issues on GitHub Issues
π€ Contributing is welcome! See our contributing guidelines above.
Available Tools
14 toolsadd_pr_commentC
Add a comment to a PR (general or line-specific)
| Name | Required | Description | Default |
|---|---|---|---|
| body | Yes | Comment body | |
| line | No | Line number for line comment | |
| path | No | File path for line comment | |
| repo | Yes | Repository name | |
| owner | Yes | Repository owner/organization | |
| prNumber | Yes | Pull request number | |
| commit_id | No | SHA of the commit to comment on | |
| in_reply_to | No | ID of comment to reply to |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the full burden of behavioral disclosure. It reveals that comments can be general or line-specific, but does not mention side effects, permission requirements, or dependencies like needing path and line together for line comments. The terse wording leaves mutational behavior unqualified.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single sentence with no fluff and is front-loaded with the core action. Every word contributes to meaning, and the key distinction of general or line-specific commenting is included.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The tool has 8 parameters, no annotations, and no output schema, so the description should compensate with operational context. It does not explain required dependencies, such as using path and line only when commenting on a specific line, or how this relates to pending reviews. This is insufficient for an agent to reliably choose parameters.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, so the parameters are already documented. The description adds only a high-level hint about general versus line-specific comments, without detailing when line, path, or commit_id should be provided. Baseline 3 is appropriate because the schema does most of the work.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description uses a specific verb and resource: 'Add a comment to a PR.' It also notes that comments can be general or line-specific, which adds useful scope. However, it does not explicitly differentiate itself from related sibling tools like submit_pr_review or validate_pr_comment_target.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
There is no guidance about when to use this tool versus alternatives such as submit_pr_review or get_pr_comments. The context is only implied by the action 'add,' with no exclusions or decision heuristics.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
analyze_pr_codeC
Analyze code changes in a PR for issues and suggestions
| Name | Required | Description | Default |
|---|---|---|---|
| repo | Yes | Repository name | |
| owner | Yes | Repository owner/organization | |
| prNumber | Yes | Pull request number |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description must disclose behavioral implications. It does not state whether this tool only returns analysis, whether it posts comments, whether it triggers any side effects, or what the agent should expect as a result. The phrase 'analyze code changes' implies a read-like behavior but never confirms or details it.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, tight sentence with no filler or redundancy. It is concise and front-loaded, though it sacrifices behavioral detail for brevity.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the lack of an output schema, absence of annotations, and a crowded sibling set with overlapping review/analysis tools, the description is too thin to fully orient an agent. It does not explain what the tool returns, how it interacts with PR state, or how it slots into the available review workflow.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The schema covers all three parameters with descriptions, so the baseline is 3. The description adds no additional meaning beyond what the schema already documents; it does not clarify relationships between the parameters or any format expectations beyond the schema.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description uses a specific verb ('analyze') and identifies the resource ('code changes in a PR') and the purpose ('issues and suggestions'). It is clear enough on its own, but it does not distinguish this tool from siblings like review_pr_with_prompt, which likely serves a similar analysis purpose.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
No guidance is provided on when to use this tool versus alternatives such as get_pr_diff_hunks, get_pr_files, or review_pr_with_prompt. There is no mention of preconditions, when not to use it, or what distinguishes this analysis flow from the other review-oriented sibling tools.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
ensure_pending_reviewA
Ensure a pending review exists for the PR. Creates a new pending review if none exists, or returns the existing one. Returns reviewId and commitId for adding inline comments.
| Name | Required | Description | Default |
|---|---|---|---|
| body | No | Optional body text for the pending review | |
| repo | Yes | Repository name | |
| owner | Yes | Repository owner/organization | |
| prNumber | Yes | Pull request number |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description carries the behavioral burden. It transparently states the side effect (creates a pending review), the idempotent fallback (returns existing), and the key return values (reviewId and commitId). It does not cover permissions or failure cases, but those are peripheral for this operation.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two sentences with no filler: purpose, behavior, and outcome are each handled once. The most important information is front-loaded.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The description tells an agent why to call, what it will do, and what it returns, which is enough to invoke it despite the lack of an output schema. It could be richer by mentioning the surrounding review/comment workflow, but nothing essential to calling is missing.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, so all four parameters including the optional body are already documented. The description adds no parameter-level nuance, so the baseline 3 applies.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The first sentence names the exact resource (pending review for a PR) and the second clarifies the operation: create if absent, return if present. This get-or-create behavior is specific enough to distinguish it from read-only siblings like get_pending_review even though no sibling is named.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The closing clause 'for adding inline comments' gives a concrete reason to call this tool before commenting. It stops short of explicitly naming alternatives or saying when not to use it, so it earns a 4 rather than a 5.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_pending_reviewA
Get the current pending review for the PR (if any). Returns null if no pending review exists.
| Name | Required | Description | Default |
|---|---|---|---|
| repo | Yes | Repository name | |
| owner | Yes | Repository owner/organization | |
| prNumber | Yes | Pull request number |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the behavioral burden. It usefully discloses the null-return behavior when no pending review exists, which is a real behavioral trait. However, it does not explain what a 'pending review' object contains, whether the operation is read-only, or how it differs behaviorally from fetching all reviews.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is two short sentences with no filler. The primary action is front-loaded, and the null-return clarification earns its place.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The tool is simple, the params are fully documented, and the null behavior is disclosed, which covers a lot. But with no output schema, the return shape is never described, and the notion of 'current pending review' is left undefined relative to related sibling tools like get_pr_reviews and ensure_pending_review.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, with owner, repo, and prNumber all explained in the schema. The description adds no parameter-level meaning beyond the schema, so the baseline 3 applies.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description uses a specific verb and resource: 'Get the current pending review for the PR', which clearly identifies the operation and target. The qualifier 'current pending' distinguishes it from siblings like get_pr_reviews, and the explicit null-return note pins down the exact semantics.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies when to use the tool: when you need the current pending review for a PR, if one exists. However, it does not explicitly contrast this with alternatives such as get_pr_reviews, ensure_pending_review, or list_pending_review_comments, nor does it state when not to use it.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_pr_commentsB
Get all comments on a GitHub pull request
| Name | Required | Description | Default |
|---|---|---|---|
| repo | Yes | Repository name | |
| owner | Yes | Repository owner/organization | |
| prNumber | Yes | Pull request number |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the full burden of behavioral disclosure. 'Get' implies a read operation, but the description does not disclose pagination, whether inline and general comments are both included, authentication requirements, or the response shape.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is one concise sentence with no filler or redundancy. The key action and resource are front-loaded, making it immediately scannable for an agent.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
This is a simple read tool with three clearly documented parameters, so the description is minimally viable. However, with no output schema and no behavioral notes, it leaves important details like return format, pagination, and comment-type scope unstated.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, so all three parameters are already documented with clear meanings. The description adds no extra parameter-level context, but it does not need to because the schema covers owner, repo, and prNumber adequately.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly identifies a specific verb ('Get'), a distinct resource ('all comments'), and a target ('a GitHub pull request'). It is easy to distinguish from sibling tools like get_pr_reviews, get_pr_files, and get_pr_details because it names a unique resource.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description gives no guidance on when to use this tool versus alternatives such as get_pr_reviews or list_pending_review_comments. It does not mention exclusions or related tools, so the agent must infer usage solely from the resource name.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_pr_detailsC
Get detailed information about a pull request
| Name | Required | Description | Default |
|---|---|---|---|
| repo | Yes | Repository name | |
| owner | Yes | Repository owner/organization | |
| prNumber | Yes | Pull request number |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the full burden of behavioral disclosure. 'Get detailed information' implies a read operation, but it does not disclose what fields are returned, whether auth is required, whether the response includes reviews/comments, or any pagination or rate-limit behavior. This is thin for an operation with no annotation safety profile.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single concise sentence with the verb front-loaded and no redundant filler. It is appropriately sized, though it sacrifices specificity for brevity.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
With no output schema and no annotations, the description needs to explain what 'detailed information' actually includes, especially given the rich set of sibling tools. It is incomplete for disambiguating the result scope and does not help an agent decide when this tool is the correct one to call.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema covers all three parameters with straightforward descriptions: repo, owner, and prNumber. The tool description adds no additional meaning beyond the schema, so the baseline of 3 is appropriate because the schema already provides the necessary parameter semantics.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description states the verb 'get' and the resource 'pull request', but 'detailed information' is vague and could apply to any of the PR-related sibling tools. It does not specify what is included, such as title, body, state, or metadata, so it does not clearly distinguish itself from get_pr_reviews, get_pr_files, or get_pr_diff_hunks.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
There is no guidance on when to use this tool versus the many sibling tools. The description does not mention exclusions, alternatives, or the relationship between get_pr_details and get_pr_reviews/get_pr_comments/get_pr_files, leaving the agent to infer the intended scope.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_pr_diff_hunksA
Get diff hunks with line mapping for all changed files in a PR. Returns per-file hunks with oldStart/oldLines, newStart/newLines, and patch content for accurate inline comment placement.
| Name | Required | Description | Default |
|---|---|---|---|
| repo | Yes | Repository name | |
| owner | Yes | Repository owner/organization | |
| prNumber | Yes | Pull request number |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the burden of behavioral disclosure. It clearly states that the tool returns per-file hunks with oldStart/oldLines, newStart/newLines, and patch content, making the read-only nature and output semantics explicit enough for a retrieval tool.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two compact sentences: the first states the action and scope, the second details the return structure. No filler or redundant information.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a simple three-parameter retrieval tool, the description is complete: it names the resource, parameters are fully covered by schema, and the return structure is partially specified. It does not mention edge cases like empty diffs or authentication requirements, but these are minor for this low-complexity tool.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, and each parameter has a basic description like 'Repository name' and 'Pull request number.' The description adds no additional parameter-specific meaning, so the baseline of 3 applies.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description uses a specific verb and resource: 'Get diff hunks with line mapping for all changed files in a PR.' It clearly distinguishes itself from siblings like get_pr_files and get_pr_details by specifying diff hunks, line mapping, and inline comment placement.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The phrase 'for accurate inline comment placement' provides clear usage context, indicating this tool is for retrieving hunk-level data needed to place comments. It does not explicitly name alternatives or state when not to use it, but the intended use case is clear.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_pr_filesB
Get list of files changed in a pull request
| Name | Required | Description | Default |
|---|---|---|---|
| repo | Yes | Repository name | |
| owner | Yes | Repository owner/organization | |
| prNumber | Yes | Pull request number |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the full burden of behavioral disclosure. It only states the basic read operation and does not mention return format, pagination, authentication needs, error behavior, or any side effects. The 'Get' verb implies read-only, but deeper behavioral context is missing.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
A single, focused sentence with no filler. The action and resource are front-loaded, and every word earns its place.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The tool is simple and all inputs are covered by the schema, but there is no output schema and the description does not specify the shape of the returned list (e.g., file paths, statuses, additions/deletions). For a straightforward 'get list' operation the implied return is largely self-evident, making it adequate yet slightly incomplete.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema has 100% description coverage for all three parameters (owner, repo, prNumber), so the baseline is 3. The description adds no extra parameter semantics, but none are needed since the schema fully documents each parameter.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Description uses a specific verb ('Get') and resource ('list of files changed in a pull request'), making the tool's purpose unmistakable. It clearly distinguishes from sibling tools like get_pr_details and get_pr_comments, which handle different aspects of a pull request.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
No explicit guidance on when to use this tool versus alternatives such as get_pr_details or get_pr_diff_hunks. An agent must infer from the resource phrase that this tool is for file lists, but no conditions, exclusions, or alternative routing are provided.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_pr_reviewsA
Get all reviews for a GitHub pull request
| Name | Required | Description | Default |
|---|---|---|---|
| repo | Yes | Repository name | |
| owner | Yes | Repository owner/organization | |
| prNumber | Yes | Pull request number |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the full burden. It states a read operation ('get') but does not disclose what the response contains (e.g., array of review objects, whether it includes review comments), pagination, authentication, or any limitations. The agent cannot infer the exact output format or whether it includes line-level comments. This is a significant gap for a tool with no output schema.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
A single, concise sentence with no fluff. It front-loads the verb and resource. Every word earns its place, and it is immediately scannable.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a simple read operation with fully documented parameters, the description is mostly adequate. However, the absence of an output schema and the lack of clarification on what constitutes a 'review' (vs comments) means the agent may not know if it should expect a list of review summaries or include review comments. Given the sibling get_pr_comments, a clearer distinction would enhance completeness.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, so all three parameters (owner, repo, prNumber) are documented in the schema. The description adds no parameter-specific details beyond what the schema already provides. Baseline 3 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states a specific verb ('Get'), a resource ('reviews'), and context ('GitHub pull request'). It distinguishes itself from siblings like get_pr_comments (comments vs reviews) and analyze_pr_code (code analysis). No ambiguity.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies when to use it: when you need reviews for a PR. It clearly differentiates from get_pr_comments by specifying 'reviews' rather than comments, but it does not explicitly name alternatives or exclusion conditions. The context is clear but not exhaustive.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
list_pending_review_commentsA
List all draft comments in the pending review for the PR. Returns empty array if no pending review exists. Each comment includes path, line, side, body, and metadata.
| Name | Required | Description | Default |
|---|---|---|---|
| repo | Yes | Repository name | |
| owner | Yes | Repository owner/organization | |
| prNumber | Yes | Pull request number |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the full burden of behavioral disclosure. It reveals a key edge-case behavior (returns an empty array if no pending review exists) and lists the fields present in each comment (path, line, side, body, metadata), which is useful operational context beyond just the name.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is compact and front-loaded. The first sentence states the core purpose, the second adds the empty-array behavior and return field summary. Every sentence earns its place with no fluff.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
There is no output schema, so the description reasonably explains the return shape (empty array if no pending review, and comment fields). It is sufficient for an agent to select and invoke the tool correctly, though 'metadata' is left unspecified and pagination/limits are not addressed.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, so the schema already fully documents the three parameters (owner, repo, prNumber). The description adds no additional possible values, constraints, or relationships between parameters, so baseline 3 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description states a specific action (list), the exact resource (draft comments in the pending review for the PR), and distinguishes it from sibling tools like get_pending_review which returns the review object itself. It also specifies the return context: empty array if no pending review exists.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description makes clear it lists draft comments in the pending review, which gives some contextual usage guidance. However, it does not explicitly contrast with closely related siblings like get_pr_comments, get_pending_review, or submit_pr_review, leaving the agent to infer when this tool is the right choice among them.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
review_pr_with_promptA
Get PR context and review prompt for AI-powered code review. Returns formatted PR data and review guidelines that can be used with an LLM to generate a comprehensive review. The LLM can then use submit_pr_review to submit the review.
| Name | Required | Description | Default |
|---|---|---|---|
| repo | Yes | Repository name | |
| owner | Yes | Repository owner/organization | |
| prNumber | Yes | Pull request number | |
| customPrompt | No | Optional custom review prompt. If not provided, uses default PR review guidelines. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description carries the behavioral burden. The verbs 'get' and 'returns' convey a read-only retrieval operation, and the explicit handoff to submit_pr_review indicates that no submission happens in this call. Auth and error behavior are not mentioned, but the core behavior is reasonably transparent.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two focused sentences front-load the tool's purpose, describe what it returns, and name the downstream action. There is no filler or unnecessary repetition.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The description is sufficient for an agent to understand when to call this tool and what to do next. The main gap is the lack of detail about what 'formatted PR data' actually contains, which is more noticeable because there is no output schema.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, so parameters are already well documented in the input schema. The description adds no additional parameter-level meaning, matching the baseline for high schema coverage.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description states a specific verb and resource: get PR context and a review prompt for AI-powered code review. It also distinguishes this tool from submission tooling by explicitly pointing to submit_pr_review as the follow-up step.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
It clearly establishes the intended workflow: retrieve context and review guidelines here, then submit via submit_pr_review. It does not explicitly explain when to choose this over siblings like get_pr_details or analyze_pr_code, so it stops short of a full 5.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
submit_pr_reviewC
Submit a review to a pull request
| Name | Required | Description | Default |
|---|---|---|---|
| body | Yes | Review comment body | |
| repo | Yes | Repository name | |
| event | Yes | Review action | |
| owner | Yes | Repository owner/organization | |
| comments | No | Inline comments on specific lines | |
| prNumber | Yes | Pull request number |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the full burden of behavioral disclosure. It only says 'Submit a review' without explaining side effects, whether the review is final, whether a pending review must exist, or any authorization constraints. For a mutation tool, this is a significant transparency gap.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single concise sentence with no wasted words, and the core action is front-loaded. However, it is so thin that it provides minimal value beyond restating the tool's purpose.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
With no annotations, no output schema, and six parameters, the description is underspecified. It does not mention inline comments, event semantics, or the relationship to pending-review workflow tools like ensure_pending_review and get_pending_review. An agent would need additional context to use it reliably in the intended workflow.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema covers all 100% of parameters and each parameter has its own description, so the schema does the heavy lifting. The description adds no additional meaning above the schema, which matches the baseline for full schema coverage.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description states a clear action and resource: submit a review to a pull request. However, it does not differentiate this from closely related sibling tools like add_pr_comment or review_pr_with_prompt, so it lacks explicit sibling distinction.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
No guidance is given on when to use this tool versus alternatives such as add_pr_comment, ensure_pending_review, or review_pr_with_prompt. There are no exclusions or conditions, leaving the agent to infer the appropriate context.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
update_prB
Update PR title, description, or state
| Name | Required | Description | Default |
|---|---|---|---|
| body | No | New PR description | |
| repo | Yes | Repository name | |
| owner | Yes | Repository owner/organization | |
| state | No | PR state | |
| title | No | New PR title | |
| prNumber | Yes | Pull request number |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the full burden of behavioral disclosure. It conveys that this is a mutating operation but omits important context such as authorization requirements, whether state transitions are restricted, side effects, or what the response contains. This is thin for a write operation.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
A single, front-loaded sentence with no filler: it states the verb, resource, and affected fields immediately. Every word earns its place, and the length is appropriate for the tool's simplicity.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The schema fully documents all six parameters, required fields, and the state enum, so an agent can construct a valid call. The main gaps are behavioral context and the absence of an output schema, but the structured information is rich enough to make the tool usable.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, so the baseline is 3. The description's mention of title, description, and state merely echoes existing parameter descriptions and adds no additional meaning or format details beyond what the schema already provides.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
States a specific verb and resource: update a PR, and enumerates the mutable fields (title, description, state). The sibling tools are all get/review/comment operations, making the mutation purpose unambiguous. However, it does not explicitly differentiate itself from siblings in the text.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The intended use is implied: modify PR metadata fields such as title, description, or state. There is no explicit guidance on when to use this tool versus alternatives or when not to use it. The contrast with non-mutating sibling tools is inferable but not stated.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
validate_pr_comment_targetA
Validate if a comment target (path, line, side) is valid for the PR diff. Returns validation status, reason for invalidity, and nearest valid line suggestion if applicable.
| Name | Required | Description | Default |
|---|---|---|---|
| line | Yes | Line number to validate | |
| path | Yes | File path in the PR | |
| repo | Yes | Repository name | |
| side | No | Side of the diff (LEFT for old, RIGHT for new) | |
| owner | Yes | Repository owner/organization | |
| prNumber | Yes | Pull request number |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the burden of behavioral disclosure. It clearly signals a non-mutating validation operation and describes what the agent should expect back: a status, an invalidity reason, and a nearest valid line suggestion. It does not cover auth or edge cases, but it meaningfully discloses the tool's behavior.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two tightly written sentences with no filler. The primary action is stated first, and the return information is included compactly in the second sentence.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a 6-parameter tool with no output schema, the description covers the core inputs as a comment target and enumerates the key return components. It could be more explicit about exact response shape or error conditions, but it gives enough for an agent to understand when and how to invoke the tool.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, so the baseline is 3. The description adds value by grouping path, line, and side into the concept of a 'comment target' and linking validation to the PR diff, which clarifies how the parameters relate beyond their individual schema descriptions.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Uses a specific verb ('Validate') with a clear resource: a PR comment target composed of path, line, and side. It also states what the tool returns (validation status, invalidity reason, nearest valid line suggestion), making it clearly distinct from sibling tools that get, add, or review comments.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description gives clear context: this tool is for checking whether a comment target is valid for the PR diff, which implies use before placing a comment. It does not explicitly name alternatives or say when not to use it, but the context is strong enough to guide selection.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.
14 tool updates
v1.0.4- First observed
add_pr_comment - First observed
analyze_pr_code - First observed
ensure_pending_review - First observed
get_pending_review - First observed
get_pr_comments - First observed
get_pr_details - First observed
get_pr_diff_hunks - First observed
get_pr_files - First observed
get_pr_reviews - First observed
list_pending_review_comments - First observed
review_pr_with_prompt - First observed
submit_pr_review - First observed
update_pr - First observed
validate_pr_comment_target
TDQS
Each tool has a clear primary targetβPR metadata, files, diff hunks, comments, reviews, pending review state, or submissionβand the specialized helpers like validate_pr_comment_target and ensure_pending_review are distinct. Minor ambiguity remains between get_pr_files and get_pr_diff_hunks, and between get_pr_comments and get_pr_reviews/list_pending_review_comments, but descriptions generally disambiguate granularity.
Tool names follow a consistent verb_noun pattern throughout: get_, add_, submit_, update_, ensure_, list_, analyze_, validate_, and review_. The naming style is uniform and the PR object is always clearly identified, making selection predictable.
14 tools is well within the ideal scope for a PR review server. Each tool covers a distinct step of the workflowβfrom reading PR data and diff hunks to managing pending reviews and submittingβwithout meaningful redundancy.
The tool surface covers the core PR review lifecycle: fetching PR details, files, diff hunks, reviews/comments, analyzing code, creating/managing pending reviews, adding comments, validating targets, and submitting reviews. Notable minor gaps are the absence of explicit editing/deleting for pending review comments and no dismissal or revision-handling tools, but these do not dead-end the primary workflow.
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 Connectors
A Model Context Protocol (MCP) application for automated GitHub PR analysis and issue management.β¦
AI code review for GitHub PRs with an MCP autofix loop for Claude Code and Cursor
Repo intel for AI coding agents: overview, PRs, contributors, hot files, CI, deps. Remote MCP.
AI-native git hosting β repos, PRs, issues, CI gates, and AI code review over MCP (60 tools).
Related MCP Servers
- AlicenseBqualityCmaintenanceEnables code review operations on GitHub and GitLab, including fetching pull/merge requests, viewing diffs, adding comments, analyzing code quality, and creating merge requests directly from your MCP client.1584MIT
- AlicenseNot gradedqualityDmaintenanceEnables AI-powered GitHub interactions including repository analysis, code search, PR reviews, and more through the MCP protocol.4MIT
- AlicenseNot gradedqualityBmaintenanceEnables AI assistants to fetch GitHub pull request diffs and metadata, and post review comments directly through the MCP protocol.1MIT
- FlicenseAqualityCmaintenanceEnables LLM clients to list, read, review, and comment on GitHub pull requests, turning an AI assistant into a fully capable code reviewer.61-
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/jamesjfoong/github-pr-review-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server