Archive a GitHub project item
github_project_item_archiveArchives a project board item by node ID or issue/PR reference, removing it from board views without deleting it; unarchive restores it.
Instructions
Archive an item on a project board the viewer may update: it leaves the board's views and github_project_read's item_list unless include_archived, and github_project_item_unarchive brings it back. Nothing is deleted. An item that is already archived is left as it is (changed: false). An item is named by its node ID (PVTI_…), which also tells its board (a project given beside it must be that board), or by an issue or pull request (12, #12, owner/repo#12 or its URL) that is on the board the lookup finds. A draft can only be named by its ID. A board is named by project: its number, owner/number or its URL, used as it is; any other project is a title, and no project is Roadmap: the open board of that whole title is looked up, never guessed, in owner's boards if owner is given, else in the boards linked to repo, then its organization's, then the viewer's. Needs a token with the project scope; if GitHub reports missing scopes, run gh auth refresh -s project.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| item | Yes | The board item: its node ID (PVTI_…), or an issue or pull request as 12, #12, owner/repo#12 or its URL, found on the board that project, owner and repo choose. A draft can only be named by its ID. | |
| repo | No | owner/name; defaults to the working tree's repository (its origin). Where the board lookup starts, the owner of a bare board number, and the repository of a bare issue or pull request number. | |
| owner | No | A user or organization login, or "@me": the owner of a numbered board, else the only owner searched for a title. | |
| project | No | The board, as its number, owner/number or its URL (used as it is; a bare number takes owner, else the owner of repo or of the working tree's repository), or as its title, looked up among open boards (whole title, case-insensitive). Default: the title Roadmap. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| changed | Yes | false when the item was already in the wanted state. | |
| item_id | Yes | ||
| project | Yes | ||
| archived | Yes | Whether the item is archived now. |