Batch-resolve all unresolved PR review threads via GitHub GraphQL API
Batch-resolves all unresolved PR review threads via GitHub GraphQL API.
/plugin marketplace add athola/claude-night-market/plugin install pensive@claude-night-marketQuickly resolve all unresolved review threads on a PR after fixes have been addressed.
/fix-pr (Phase 7)/fix-pr# If no PR specified, use current branch
gh pr view --json number,url -q '.number'
# Replace OWNER, REPO, PR_NUMBER with actual values
gh api graphql -f query='
query {
repository(owner: "OWNER", name: "REPO") {
pullRequest(number: PR_NUMBER) {
reviewThreads(first: 100) {
nodes {
id
isResolved
path
line
comments(first: 1) {
nodes { body }
}
}
}
}
}
}'
For each unresolved thread:
gh api graphql -f query='
mutation {
resolveReviewThread(input: {threadId: "PRRT_xxx"}) {
thread { isResolved }
}
}'
# Should return 0
gh api graphql -f query='...' \
--jq '[.data.repository.pullRequest.reviewThreads.nodes[] | select(.isResolved == false)] | length'
### Thread Resolution Summary
| Status | Count |
|--------|-------|
| Resolved | 15 |
| Already resolved | 3 |
| Failed | 0 |
All 18 review threads are now resolved.
/fix-pr for reply + resolve/fix-pr - Full workflow for addressing PR comments (reply + resolve)/pr-review - Review a PR and post findings as GitHub comments