From 5f6f56bed691c3e5c587ccd1b6f26bd4f3ebe3da Mon Sep 17 00:00:00 2001 From: Hana Harencarova Date: Wed, 18 Dec 2024 08:04:22 +0100 Subject: [PATCH] Add info about Autofix API (#53664) Co-authored-by: Hana Harencarova <7911294+hharen@users.noreply.github.com> Co-authored-by: Sophie <29382425+sophietheking@users.noreply.github.com> --- .../resolving-code-scanning-alerts.md | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/content/code-security/code-scanning/managing-code-scanning-alerts/resolving-code-scanning-alerts.md b/content/code-security/code-scanning/managing-code-scanning-alerts/resolving-code-scanning-alerts.md index 7961a6ea927c..2810e689900b 100644 --- a/content/code-security/code-scanning/managing-code-scanning-alerts/resolving-code-scanning-alerts.md +++ b/content/code-security/code-scanning/managing-code-scanning-alerts/resolving-code-scanning-alerts.md @@ -48,7 +48,13 @@ With a {% data variables.product.prodname_copilot_enterprise %} license, you can 1. Once the suggested fix has been generated, at the bottom of the page, you can click **Create PR with fix** to automatically generate a pull request with the suggested fix. A new branch is created from the default branch, the generated fix is committed and a draft pull request is created. You can test and edit the suggested fix as you would with any other fix. -For information about the limitations of automatically generated fixes, see "[Limitations of suggestions](/code-security/code-scanning/managing-code-scanning-alerts/about-autofix-for-codeql-code-scanning#limitations-of-suggestions) +You can also use the Autofix API for historical alerts endpoints to generate, get, and commit suggested fixes. + +* [Create an autofix for a code scanning alert](/rest/code-scanning/code-scanning#create-an-autofix-for-a-code-scanning-alert) +* [Get the status of an autofix for a code scanning alert](/rest/code-scanning/code-scanning#get-the-status-of-an-autofix-for-a-code-scanning-alert) +* [Commit an autofix for a code scanning alert](/rest/code-scanning/code-scanning#commit-an-autofix-for-a-code-scanning-alert) + +For information about the limitations of automatically generated fixes, see [Limitations of suggestions](/code-security/code-scanning/managing-code-scanning-alerts/about-autofix-for-codeql-code-scanning#limitations-of-suggestions). {% endif %}