apicheats.dev Cheat sheet Raw .md
PATCH

Try PATCH /repos/{owner}/{repo}/code-scanning/alerts/{alert_number} — GitHub API

GitHub playground

Update a code scanning alert

Credentials

Kept in this tab only. Requests go through apicheats.dev's same-origin proxy straight to api.github.com; the proxy stores and logs nothing about them.

Headers

Path

Body application/json

5 body fields
  • state · required · string — Sets the state of the code scanning alert. You must provide `dismissed_reason` when you set the state to `dismissed`.
  • dismissed_reason · optional · string — **Required when the state is dismissed.** The reason for dismissing or closing the alert.
  • dismissed_comment · optional · string — The dismissal comment associated with the dismissal of the alert.
  • create_request · optional · boolean — If `true`, attempt to create an alert dismissal request.
  • assignees · optional · string[] — The list of users to assign to the code scanning alert. An empty array unassigns all previous assignees from the alert.