Loading...
Loading...
Manage Harness Code pull requests via MCP. List, create, update, and merge PRs; add reviewers and submit review decisions (approve / request changes); post, update, and delete comments; read the discussion timeline; and check CI status. Use when asked to open a PR, merge a PR, approve a PR, leave a code review comment, request changes, assign reviewers, or inspect PR checks and activity. Trigger phrases: pull request, PR review, merge PR, approve PR, request changes, add reviewer, PR comments, PR checks, PR activity, code review.
npx skill4agent add harness/harness-skills manage-pull-requests| Tool | Resource Type | Purpose |
|---|---|---|
| | List PRs in a repo, filter by state |
| | Get PR details by number |
| | Open a new PR |
| | Update PR title / description / state |
| | Merge a PR (merge/squash/rebase/fast-forward) |
| | List reviewers on a PR |
| | Add a reviewer to a PR |
| | Submit an |
| | Post a top-level or inline code comment |
| | Edit a comment |
| | Delete a comment |
| | Read the discussion timeline — the only way to READ comments |
| | List CI status checks on a PR |
| any of the above | Exact JSON Schema for |
repo_idpr_numberharness_listpull_requestrepo_idorg_idproject_idrepo_idpr_numberurlharness_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 searchCall 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."titlesource_branchtarget_branchdescriptionCall 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 | closedCall MCP tool: harness_create
Parameters:
resource_type: "pr_reviewer"
repo_id: "<repo>"
pr_number: <number>
body:
reviewer_id: <numeric_user_id>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 reviewedCall MCP tool: harness_create
Parameters:
resource_type: "pr_comment"
repo_id: "<repo>"
pr_number: <number>
body:
text: "LGTM with one nit — see inline."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>"line_oldpr_activitypr_commentGET/commentsCall 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 onlytypereview-submitreviewer-addstate-changemergetitle-changeCall 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>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 lockdry_run: true/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_idpr_numberharness_list(pull_request)repo_idpr_numberpr_activitypr_commentkind=commenttype=code-commentdry_run: trueurl="<PR URL>"org_idproject_idrepo_idpr_numberpr_reviewer.submit_reviewharness_create(pr_reviewer)harness_search(query="<text>", resource_types=["pull_request"])harness_list(resource_type="repository")pr_commentlistgetharness_list(resource_type="pr_activity", kind="comment")/commentspr_activitydecision"approved""changereq""approve"d"request_changes"source_shasource_shasource_shasource_commit_shatarget_commit_shaharness_get(pull_request)source_shatarget_shaharness_execute(action=merge)harness_list(resource_type="pr_check")success