Close an issue as a duplicate
Use this once you’ve confirmed an issue is a duplicate of another, already open (or previously filed) issue.
-
Confirm the canonical issue number first — typically the result of a prior search_similar_issues call, or manual review.
-
Call:
close_as_duplicate {owner: "<owner>",repo: "<repo>",issueNumber: <n>,duplicateOfNumber: <canonical-issue-number>} -
This performs two actions in sequence: it closes
issueNumberwithstate_reason: "duplicate"via REST PATCH, then posts a comment on it readingClosing as a duplicate of #<duplicateOfNumber>. -
The response includes
commentUrl— the URL of the comment GitHub just created. Use it to confirm the comment posted as expected.
- This tool does not verify that
duplicateOfNumberactually exists or is related — pass the number you’ve already confirmed yourself (see search-similar-issues.md). - Closing as a duplicate does not touch the triage board’s
SeverityorStatusfields directly; GitHub’s native “Item closed” Projects v2 workflow, if enabled on your board, handles the board-side transition (see ADR-0003).
See also
Section titled “See also”- reference/tools.md — full input/output schema.