/harness:manage-pull-requestsfrom Harness DevOps
Manages Harness Code pull requests via MCP: list, create, update, merge, add reviewers, submit reviews, post/edit/delete comments, read discussion timeline, and check CI status.
Ships in Harness DevOps. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Manage Harness Code pull requests, reviewers, comments, checks, and activity via MCP.
| Tool | Resource Type | Purpose |
|---|---|---|
harness_list | pull_request | List PRs in a repo, filter by state |
harness_get | pull_request | Get PR details by number |
harness_create | pull_request | Open a new PR |
harness_update | pull_request | Update PR title / description / state |
harness_execute (action: merge) | pull_request | Merge a PR (merge/squash/rebase/fast-forward) |
harness_list | pr_reviewer | List reviewers on a PR |
harness_create | pr_reviewer | Add a reviewer to a PR |
harness_execute (action: submit_review) | pr_reviewer | Submit an approved or changereq review |
harness_create | pr_comment | Post a top-level or inline code comment |
harness_update | pr_comment | Edit a comment |
harness_delete | pr_comment | Delete a comment |
harness_list | pr_activity | Read the discussion timeline — the only way to READ comments |
harness_list | pr_check | List CI status checks on a PR |
harness_schema | any of the above | Exact JSON Schema for create / update body fields |
All pull-request resources are repo-scoped. Every call needs repo_id and pr_number (except harness_list for pull_request, which only needs repo_id). org_id / project_id are optional (the server infers them from the repo).
URL shortcut: the MCP server auto-extracts repo_id and pr_number if you pass a Harness PR URL via the url parameter — e.g. harness_get(resource_type="pull_request", url="https://app.harness.io/ng/account/.../pulls/42").
Call MCP tool: harness_list
Parameters:
resource_type: "pull_request"
repo_id: "<repository_identifier>"
state: "open" # optional: open | closed | merged
query: "<keyword>" # optional: full-text search
Or fetch a specific PR:
Call MCP tool: harness_get
Parameters:
resource_type: "pull_request"
repo_id: "<repository_identifier>"
pr_number: <number>
Call MCP tool: harness_create
Parameters:
resource_type: "pull_request"
repo_id: "<repository_identifier>"
body:
title: "Fix race condition in scheduler"
source_branch: "fix/scheduler-race"
target_branch: "main"
description: "Resolves HAR-1234. Adds mutex around queue access."
title, source_branch, target_branch are required. description supports markdown.
Call MCP tool: harness_update
Parameters:
resource_type: "pull_request"
repo_id: "<repo>"
pr_number: <number>
body:
title: "Updated title"
description: "Updated description"
state: "closed" # optional: open | closed
All body fields are optional — only include what you want to change.
Call MCP tool: harness_create
Parameters:
resource_type: "pr_reviewer"
repo_id: "<repo>"
pr_number: <number>
body:
reviewer_id: <numeric_user_id>
List current reviewers with harness_list(resource_type="pr_reviewer", repo_id, pr_number).
Call MCP tool: harness_execute
Parameters:
resource_type: "pr_reviewer"
action: "submit_review"
repo_id: "<repo>"
pr_number: <number>
body:
decision: "approved" # approved | changereq
commit_sha: "<sha>" # optional — the commit you reviewed
Top-level comment:
Call MCP tool: harness_create
Parameters:
resource_type: "pr_comment"
repo_id: "<repo>"
pr_number: <number>
body:
text: "LGTM with one nit — see inline."
Inline code comment:
Call MCP tool: harness_create
Parameters:
resource_type: "pr_comment"
repo_id: "<repo>"
pr_number: <number>
body:
text: "This loop can leak if the context is cancelled."
path: "scheduler/queue.go"
line_new: 142
source_commit_sha: "<source_sha>"
target_commit_sha: "<target_sha>"
Use line_old for comments on removed lines.
pr_activity, not pr_commentThe Harness Code API does not expose GET on /comments. To read the discussion, list PR activity filtered by kind:
Call MCP tool: harness_list
Parameters:
resource_type: "pr_activity"
repo_id: "<repo>"
pr_number: <number>
kind: "comment" # just comments (general + code)
# or type: "code-comment" for inline code review comments only
Other useful type filters: review-submit, reviewer-add, state-change, merge, title-change.
Call MCP tool: harness_update
Parameters:
resource_type: "pr_comment"
repo_id: "<repo>"
pr_number: <number>
comment_id: <numeric_comment_id>
body:
text: "Updated comment body"
Call MCP tool: harness_delete
Parameters:
resource_type: "pr_comment"
repo_id: "<repo>"
pr_number: <number>
comment_id: <numeric_comment_id>
Call MCP tool: harness_list
Parameters:
resource_type: "pr_check"
repo_id: "<repo>"
pr_number: <number>
Returns the status of each status check (pipeline, test run, external check) associated with the PR head commit. Use this before merging to confirm required checks are green.
Call MCP tool: harness_execute
Parameters:
resource_type: "pull_request"
action: "merge"
repo_id: "<repo>"
pr_number: <number>
body:
method: "squash" # merge | squash | rebase | fast-forward
delete_source_branch: true
dry_run: false
source_sha: "<expected_sha>" # optional optimistic lock
Set dry_run: true first to preview the merge without executing — useful before destructive merges.
/manage-pull-requests
Open a PR from feat/new-auth into main titled "Add OAuth device flow" on repo platformUI,
and add user 12345 as a reviewer.
/manage-pull-requests
Show me every inline code comment on PR 182 in repo harness-core so I can address them.
/manage-pull-requests
Approve PR 47 in repo mcp-server with a "LGTM" comment, then squash-merge it and delete the branch.
/manage-pull-requests
List the checks on PR 99 in repo harness-cli. If they're all green, merge it with a squash.
/manage-pull-requests
Close PR 22 in repo harness-skills with a comment explaining we're going in a different direction.
repo_id + pr_number together except for harness_list(pull_request) which only needs repo_id. Missing pr_number on per-PR calls returns a helpful 400 from the server.pr_activity, never pr_comment. The comments endpoint is POST-only. Use kind=comment for all discussion, type=code-comment for inline only.dry_run: true on merge before destructive squash/rebase merges — especially on main branches with required checks.url="<PR URL>" auto-extracts org_id, project_id, repo_id, and pr_number — fewer args to get wrong.pr_reviewer.submit_review records a review independently of the reviewer list. You don't need to call harness_create(pr_reviewer) first to submit a review — any user with access can review.harness_search(query="<text>", resource_types=["pull_request"]) finds PRs across repos when you don't know which repo contains it.All PR operations are repo-scoped. Pass the repo identifier (not the repo name) — list repos first with harness_list(resource_type="repository") if you're unsure.
pr_comment has no list/get operations. Use harness_list(resource_type="pr_activity", kind="comment") to read the discussion timeline.
Same cause as above — the Harness Code API is POST-only for /comments. Read via pr_activity.
Check the decision value — it must be exactly "approved" or "changereq". The API does not accept "approve" (no d) or "request_changes".
You passed source_sha and it no longer matches the branch head (someone pushed after you computed it). Drop source_sha or re-fetch the PR to get the current source_sha.
Inline code comments need both source_commit_sha and target_commit_sha in the body — without them the comment appears as a top-level comment. Get the SHAs from harness_get(pull_request) → source_sha / target_sha.
harness_execute(action=merge) bypasses branch protection if the caller has admin rights. Use harness_list(resource_type="pr_check") first and fail fast in automation if any check is not success.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
harness-code, pull-request-management, code-review, mcp-server
npx claudepluginhub harness/harness-ai --plugin harness73 skills in this plugin
/ai-operationsConfigure Harness AI-powered operations (AIDA) via MCP. Set up predictive failure analysis with ML models for memory leaks, disk exhaustion, connection pool saturation, and latency degradation. Configure intelligent alert correlation and noise reduction to reduce alert volume. Use when asked to set up predictive failure analysis, configure AI-powered alerting, reduce alert noise, or enable ML-based anomaly detection. Do NOT use for pipeline debugging (use debug-pipeline instead) or SLO management (use manage-slos instead). Trigger phrases: AIDA, predictive failure, alert correlation, noise reduction, anomaly detection, AI ops, predictive analysis, alert fatigue, ML alerting, intelligent alerting./analyze-costsAnalyze cloud costs, find optimization opportunities, and track anomalies using Harness CCM via MCP. Use when user says "cloud costs", "analyze costs", "cost optimization", "reduce spending", "cost report", or asks about cloud bills./approve-exemptApprove pending Harness STO security exemptions (waivers) at their current scope or elevate them to Project, Org, or Account scope. Users say "approve" for both in-scope approval and higher-scope elevation — do not require the word "promote". Supports approving one exemption or a mixed list where each row has a different approval scope. Default workflow lists pending exemptions in chat (paginated preview) so the user picks by row number — no copying from the Harness UI. Use when a user wants to approve, sign off on, or clear pending exemptions, waive approvals, org-wide approval, or account-wide approval. Trigger phrases: approve exempt, approve exemption, approve waiver, sign off exemption, clear pending exemption, approve for org, approve for account, org-wide approval, account-wide approval, pending exemptions.Other plugins' skills for the same job