GitHub Connector can create issues but cannot permanently delete them
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 125k
- Forks
- 19.4k
- PR merge metrics
- PR metrics pending
Description
Summary
The GitHub App Connector available to ChatGPT/Codex can create issues and update/close them, but it does not expose an operation to permanently delete an issue even when the connected user has sufficient repository permissions.
This creates the same lifecycle asymmetry described for branches in #41863: the connector can create repository state that it cannot fully clean up afterward.
Concrete example
During a normal repository workflow, the agent accidentally created GitHub issues when the repository's canonical Codex implementation queue was actually notes/ files.
The connector could then:
- rename the accidental issues;
- set them
not_planned; - close them;
but could not restore the repository to its previous state by permanently deleting those accidental issues.
The user can delete them manually through GitHub's Web UI because GitHub supports issue deletion for users with sufficient repository permissions. The missing capability is therefore in the connector tool surface, not in GitHub itself.
Current connector capability
Available operations include actions equivalent to:
create issue
update / close issue
add / remove labels and assignees
create / update / delete repository files
create commits
create branches
create / manage pull requests
There is no operation equivalent to:
delete_issue(repository_full_name, issue_number)
So the connector can create an issue by mistake but cannot undo that exact mutation.
Requested capability
Please add a narrowly scoped first-class action such as:
delete_issue(
repository_full_name,
issue_number,
)
Suggested behavior:
- require explicit user intent for permanent deletion;
- use the permissions of the connected GitHub App/user;
- permanently delete only the exact specified issue;
- surface permission / repository-policy failures clearly;
- do not silently substitute
close/not_plannedwhen permanent deletion was requested.
A generic authenticated GitHub REST escape hatch could also address this class of missing lifecycle operations, but a dedicated delete_issue action would be simpler and safer to audit.
Why this matters
This is more than cosmetic cleanup. For an agent that performs repository mutations, reversibility matters:
create issue -> delete accidental issue
create branch -> delete merged/accidental branch
create file -> delete file
The connector already supports destructive operations such as deleting tracked repository files and creating commits, so permanent issue deletion after explicit user authorization would fit the existing capability model.
Related issue
#41863 reports the analogous branch/ref lifecycle gap. This request is specifically for permanent issue deletion.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the GitHub App Connector operation surface and compare its lifecycle handling with the branch gap in #41863. Done means a narrowly scoped delete_issue action exists, requires explicit intent, respects connected-user permissions, reports failures clearly, and does not substitute closing or marking the issue not planned.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- github
- Domain
- api, backend, security
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100