Skip to content

Commit 65ac97c

Browse files
Update OpenAPI Descriptions
1 parent 4b08885 commit 65ac97c

File tree

4 files changed

+51
-16
lines changed

4 files changed

+51
-16
lines changed

descriptions/api.github.com/api.github.com.json

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24166,7 +24166,7 @@
2416624166
},
2416724167
"delete": {
2416824168
"summary": "Delete a code scanning analysis from a repository",
24169-
"description": "Deletes a specified code scanning analysis from a repository. For\nprivate repositories, you must use an access token with the `repo` scope. For public repositories,\nyou must use an access token with `public_repo` and `repo:security_events` scopes.\nGitHub Apps must have the `security_events` write permission to use this endpoint.\n\nYou can delete one analysis at a time.\nTo delete a series of analyses, start with the most recent analysis and work backwards.\nConceptually, the process is similar to the undo function in a text editor.\n\nWhen you list the analyses for a repository,\none or more will be identified as deletable in the response:\n\n```\n\"deletable\": true\n```\n\nAn analysis is deletable when it's the most recent in a set of analyses.\nTypically, a repository will have multiple sets of analyses\nfor each enabled code scanning tool,\nwhere a set is determined by a unique combination of analysis values:\n\n* `ref`\n* `tool`\n* `analysis_key`\n* `environment`\n\nIf you attempt to delete an analysis that is not the most recent in a set,\nyou'll get a 400 response with the message:\n\n```\nAnalysis specified is not deletable.\n```\n\nThe response from a successful `DELETE` operation provides you with\ntwo alternative URLs for deleting the next analysis in the set\n(see the example default response below).\nUse the `next_analysis_url` URL if you want to avoid accidentally deleting the final analysis\nin the set. This is a useful option if you want to preserve at least one analysis\nfor the specified tool in your repository.\nUse the `confirm_delete_url` URL if you are content to remove all analyses for a tool.\nWhen you delete the last analysis in a set the value of `next_analysis_url` and `confirm_delete_url`\nin the 200 response is `null`.\n\nAs an example of the deletion process,\nlet's imagine that you added a workflow that configured a particular code scanning tool\nto analyze the code in a repository. This tool has added 15 analyses:\n10 on the default branch, and another 5 on a topic branch.\nYou therefore have two separate sets of analyses for this tool.\nYou've now decided that you want to remove all of the analyses for the tool.\nTo do this you must make 15 separate deletion requests.\nTo start, you must find the deletable analysis for one of the sets,\nstep through deleting the analyses in that set,\nand then repeat the process for the second set.\nThe procedure therefore consists of a nested loop:\n\n**Outer loop**:\n* List the analyses for the repository, filtered by tool.\n* Parse this list to find a deletable analysis. If found:\n\n **Inner loop**:\n * Delete the identified analysis.\n * Parse the response for the value of `confirm_delete_url` and, if found, use this in the next iteration.\n\nThe above process assumes that you want to remove all trace of the tool's analyses from the GitHub user interface, for the specified repository, and it therefore uses the `confirm_delete_url` value. Alternatively, you could use the `next_analysis_url` value, which would leave the last analysis in each set undeleted to avoid removing a tool's analysis entirely.",
24169+
"description": "Deletes a specified code scanning analysis from a repository. For\nprivate repositories, you must use an access token with the `repo` scope. For public repositories,\nyou must use an access token with `public_repo` and `repo:security_events` scopes.\nGitHub Apps must have the `security_events` write permission to use this endpoint.\n\nYou can delete one analysis at a time.\nTo delete a series of analyses, start with the most recent analysis and work backwards.\nConceptually, the process is similar to the undo function in a text editor.\n\nWhen you list the analyses for a repository,\none or more will be identified as deletable in the response:\n\n```\n\"deletable\": true\n```\n\nAn analysis is deletable when it's the most recent in a set of analyses.\nTypically, a repository will have multiple sets of analyses\nfor each enabled code scanning tool,\nwhere a set is determined by a unique combination of analysis values:\n\n* `ref`\n* `tool`\n* `analysis_key`\n* `environment`\n\nIf you attempt to delete an analysis that is not the most recent in a set,\nyou'll get a 400 response with the message:\n\n```\nAnalysis specified is not deletable.\n```\n\nThe response from a successful `DELETE` operation provides you with\ntwo alternative URLs for deleting the next analysis in the set:\n`next_analysis_url` and `confirm_delete_url`.\nUse the `next_analysis_url` URL if you want to avoid accidentally deleting the final analysis\nin a set. This is a useful option if you want to preserve at least one analysis\nfor the specified tool in your repository.\nUse the `confirm_delete_url` URL if you are content to remove all analyses for a tool.\nWhen you delete the last analysis in a set, the value of `next_analysis_url` and `confirm_delete_url`\nin the 200 response is `null`.\n\nAs an example of the deletion process,\nlet's imagine that you added a workflow that configured a particular code scanning tool\nto analyze the code in a repository. This tool has added 15 analyses:\n10 on the default branch, and another 5 on a topic branch.\nYou therefore have two separate sets of analyses for this tool.\nYou've now decided that you want to remove all of the analyses for the tool.\nTo do this you must make 15 separate deletion requests.\nTo start, you must find an analysis that's identified as deletable.\nEach set of analyses always has one that's identified as deletable.\nHaving found the deletable analysis for one of the two sets,\ndelete this analysis and then continue deleting the next analysis in the set until they're all deleted.\nThen repeat the process for the second set.\nThe procedure therefore consists of a nested loop:\n\n**Outer loop**:\n* List the analyses for the repository, filtered by tool.\n* Parse this list to find a deletable analysis. If found:\n\n **Inner loop**:\n * Delete the identified analysis.\n * Parse the response for the value of `confirm_delete_url` and, if found, use this in the next iteration.\n\nThe above process assumes that you want to remove all trace of the tool's analyses from the GitHub user interface, for the specified repository, and it therefore uses the `confirm_delete_url` value. Alternatively, you could use the `next_analysis_url` value, which would leave the last analysis in each set undeleted to avoid removing a tool's analysis entirely.",
2417024170
"operationId": "code-scanning/delete-analysis",
2417124171
"tags": [
2417224172
"code-scanning"
@@ -45763,6 +45763,9 @@
4576345763
},
4576445764
{
4576545765
"$ref": "#/components/parameters/page"
45766+
},
45767+
{
45768+
"$ref": "#/components/parameters/repository-id-in-query"
4576645769
}
4576745770
],
4576845771
"responses": {
@@ -98470,6 +98473,14 @@
9847098473
"type": "integer"
9847198474
}
9847298475
},
98476+
"repository-id-in-query": {
98477+
"name": "repository_id",
98478+
"description": "ID of the Repository to filter on",
98479+
"in": "query",
98480+
"schema": {
98481+
"type": "integer"
98482+
}
98483+
},
9847398484
"codespace-name": {
9847498485
"name": "codespace_name",
9847598486
"in": "path",

descriptions/api.github.com/api.github.com.yaml

Lines changed: 16 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -17369,13 +17369,13 @@ paths:
1736917369
```
1737017370

1737117371
The response from a successful `DELETE` operation provides you with
17372-
two alternative URLs for deleting the next analysis in the set
17373-
(see the example default response below).
17372+
two alternative URLs for deleting the next analysis in the set:
17373+
`next_analysis_url` and `confirm_delete_url`.
1737417374
Use the `next_analysis_url` URL if you want to avoid accidentally deleting the final analysis
17375-
in the set. This is a useful option if you want to preserve at least one analysis
17375+
in a set. This is a useful option if you want to preserve at least one analysis
1737617376
for the specified tool in your repository.
1737717377
Use the `confirm_delete_url` URL if you are content to remove all analyses for a tool.
17378-
When you delete the last analysis in a set the value of `next_analysis_url` and `confirm_delete_url`
17378+
When you delete the last analysis in a set, the value of `next_analysis_url` and `confirm_delete_url`
1737917379
in the 200 response is `null`.
1738017380

1738117381
As an example of the deletion process,
@@ -17385,9 +17385,11 @@ paths:
1738517385
You therefore have two separate sets of analyses for this tool.
1738617386
You've now decided that you want to remove all of the analyses for the tool.
1738717387
To do this you must make 15 separate deletion requests.
17388-
To start, you must find the deletable analysis for one of the sets,
17389-
step through deleting the analyses in that set,
17390-
and then repeat the process for the second set.
17388+
To start, you must find an analysis that's identified as deletable.
17389+
Each set of analyses always has one that's identified as deletable.
17390+
Having found the deletable analysis for one of the two sets,
17391+
delete this analysis and then continue deleting the next analysis in the set until they're all deleted.
17392+
Then repeat the process for the second set.
1739117393
The procedure therefore consists of a nested loop:
1739217394

1739317395
**Outer loop**:
@@ -32871,6 +32873,7 @@ paths:
3287132873
parameters:
3287232874
- "$ref": "#/components/parameters/per-page"
3287332875
- "$ref": "#/components/parameters/page"
32876+
- "$ref": "#/components/parameters/repository-id-in-query"
3287432877
responses:
3287532878
'200':
3287632879
description: Response
@@ -75165,6 +75168,12 @@ components:
7516575168
required: true
7516675169
schema:
7516775170
type: integer
75171+
repository-id-in-query:
75172+
name: repository_id
75173+
description: ID of the Repository to filter on
75174+
in: query
75175+
schema:
75176+
type: integer
7516875177
codespace-name:
7516975178
name: codespace_name
7517075179
in: path

descriptions/api.github.com/dereferenced/api.github.com.deref.json

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -180468,7 +180468,7 @@
180468180468
},
180469180469
"delete": {
180470180470
"summary": "Delete a code scanning analysis from a repository",
180471-
"description": "Deletes a specified code scanning analysis from a repository. For\nprivate repositories, you must use an access token with the `repo` scope. For public repositories,\nyou must use an access token with `public_repo` and `repo:security_events` scopes.\nGitHub Apps must have the `security_events` write permission to use this endpoint.\n\nYou can delete one analysis at a time.\nTo delete a series of analyses, start with the most recent analysis and work backwards.\nConceptually, the process is similar to the undo function in a text editor.\n\nWhen you list the analyses for a repository,\none or more will be identified as deletable in the response:\n\n```\n\"deletable\": true\n```\n\nAn analysis is deletable when it's the most recent in a set of analyses.\nTypically, a repository will have multiple sets of analyses\nfor each enabled code scanning tool,\nwhere a set is determined by a unique combination of analysis values:\n\n* `ref`\n* `tool`\n* `analysis_key`\n* `environment`\n\nIf you attempt to delete an analysis that is not the most recent in a set,\nyou'll get a 400 response with the message:\n\n```\nAnalysis specified is not deletable.\n```\n\nThe response from a successful `DELETE` operation provides you with\ntwo alternative URLs for deleting the next analysis in the set\n(see the example default response below).\nUse the `next_analysis_url` URL if you want to avoid accidentally deleting the final analysis\nin the set. This is a useful option if you want to preserve at least one analysis\nfor the specified tool in your repository.\nUse the `confirm_delete_url` URL if you are content to remove all analyses for a tool.\nWhen you delete the last analysis in a set the value of `next_analysis_url` and `confirm_delete_url`\nin the 200 response is `null`.\n\nAs an example of the deletion process,\nlet's imagine that you added a workflow that configured a particular code scanning tool\nto analyze the code in a repository. This tool has added 15 analyses:\n10 on the default branch, and another 5 on a topic branch.\nYou therefore have two separate sets of analyses for this tool.\nYou've now decided that you want to remove all of the analyses for the tool.\nTo do this you must make 15 separate deletion requests.\nTo start, you must find the deletable analysis for one of the sets,\nstep through deleting the analyses in that set,\nand then repeat the process for the second set.\nThe procedure therefore consists of a nested loop:\n\n**Outer loop**:\n* List the analyses for the repository, filtered by tool.\n* Parse this list to find a deletable analysis. If found:\n\n **Inner loop**:\n * Delete the identified analysis.\n * Parse the response for the value of `confirm_delete_url` and, if found, use this in the next iteration.\n\nThe above process assumes that you want to remove all trace of the tool's analyses from the GitHub user interface, for the specified repository, and it therefore uses the `confirm_delete_url` value. Alternatively, you could use the `next_analysis_url` value, which would leave the last analysis in each set undeleted to avoid removing a tool's analysis entirely.",
180471+
"description": "Deletes a specified code scanning analysis from a repository. For\nprivate repositories, you must use an access token with the `repo` scope. For public repositories,\nyou must use an access token with `public_repo` and `repo:security_events` scopes.\nGitHub Apps must have the `security_events` write permission to use this endpoint.\n\nYou can delete one analysis at a time.\nTo delete a series of analyses, start with the most recent analysis and work backwards.\nConceptually, the process is similar to the undo function in a text editor.\n\nWhen you list the analyses for a repository,\none or more will be identified as deletable in the response:\n\n```\n\"deletable\": true\n```\n\nAn analysis is deletable when it's the most recent in a set of analyses.\nTypically, a repository will have multiple sets of analyses\nfor each enabled code scanning tool,\nwhere a set is determined by a unique combination of analysis values:\n\n* `ref`\n* `tool`\n* `analysis_key`\n* `environment`\n\nIf you attempt to delete an analysis that is not the most recent in a set,\nyou'll get a 400 response with the message:\n\n```\nAnalysis specified is not deletable.\n```\n\nThe response from a successful `DELETE` operation provides you with\ntwo alternative URLs for deleting the next analysis in the set:\n`next_analysis_url` and `confirm_delete_url`.\nUse the `next_analysis_url` URL if you want to avoid accidentally deleting the final analysis\nin a set. This is a useful option if you want to preserve at least one analysis\nfor the specified tool in your repository.\nUse the `confirm_delete_url` URL if you are content to remove all analyses for a tool.\nWhen you delete the last analysis in a set, the value of `next_analysis_url` and `confirm_delete_url`\nin the 200 response is `null`.\n\nAs an example of the deletion process,\nlet's imagine that you added a workflow that configured a particular code scanning tool\nto analyze the code in a repository. This tool has added 15 analyses:\n10 on the default branch, and another 5 on a topic branch.\nYou therefore have two separate sets of analyses for this tool.\nYou've now decided that you want to remove all of the analyses for the tool.\nTo do this you must make 15 separate deletion requests.\nTo start, you must find an analysis that's identified as deletable.\nEach set of analyses always has one that's identified as deletable.\nHaving found the deletable analysis for one of the two sets,\ndelete this analysis and then continue deleting the next analysis in the set until they're all deleted.\nThen repeat the process for the second set.\nThe procedure therefore consists of a nested loop:\n\n**Outer loop**:\n* List the analyses for the repository, filtered by tool.\n* Parse this list to find a deletable analysis. If found:\n\n **Inner loop**:\n * Delete the identified analysis.\n * Parse the response for the value of `confirm_delete_url` and, if found, use this in the next iteration.\n\nThe above process assumes that you want to remove all trace of the tool's analyses from the GitHub user interface, for the specified repository, and it therefore uses the `confirm_delete_url` value. Alternatively, you could use the `next_analysis_url` value, which would leave the last analysis in each set undeleted to avoid removing a tool's analysis entirely.",
180472180472
"operationId": "code-scanning/delete-analysis",
180473180473
"tags": [
180474180474
"code-scanning"
@@ -381256,6 +381256,14 @@
381256381256
"type": "integer",
381257381257
"default": 1
381258381258
}
381259+
},
381260+
{
381261+
"name": "repository_id",
381262+
"description": "ID of the Repository to filter on",
381263+
"in": "query",
381264+
"schema": {
381265+
"type": "integer"
381266+
}
381259381267
}
381260381268
],
381261381269
"responses": {

descriptions/api.github.com/dereferenced/api.github.com.deref.yaml

Lines changed: 14 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -39665,13 +39665,13 @@ paths:
3966539665
```
3966639666

3966739667
The response from a successful `DELETE` operation provides you with
39668-
two alternative URLs for deleting the next analysis in the set
39669-
(see the example default response below).
39668+
two alternative URLs for deleting the next analysis in the set:
39669+
`next_analysis_url` and `confirm_delete_url`.
3967039670
Use the `next_analysis_url` URL if you want to avoid accidentally deleting the final analysis
39671-
in the set. This is a useful option if you want to preserve at least one analysis
39671+
in a set. This is a useful option if you want to preserve at least one analysis
3967239672
for the specified tool in your repository.
3967339673
Use the `confirm_delete_url` URL if you are content to remove all analyses for a tool.
39674-
When you delete the last analysis in a set the value of `next_analysis_url` and `confirm_delete_url`
39674+
When you delete the last analysis in a set, the value of `next_analysis_url` and `confirm_delete_url`
3967539675
in the 200 response is `null`.
3967639676

3967739677
As an example of the deletion process,
@@ -39681,9 +39681,11 @@ paths:
3968139681
You therefore have two separate sets of analyses for this tool.
3968239682
You've now decided that you want to remove all of the analyses for the tool.
3968339683
To do this you must make 15 separate deletion requests.
39684-
To start, you must find the deletable analysis for one of the sets,
39685-
step through deleting the analyses in that set,
39686-
and then repeat the process for the second set.
39684+
To start, you must find an analysis that's identified as deletable.
39685+
Each set of analyses always has one that's identified as deletable.
39686+
Having found the deletable analysis for one of the two sets,
39687+
delete this analysis and then continue deleting the next analysis in the set until they're all deleted.
39688+
Then repeat the process for the second set.
3968739689
The procedure therefore consists of a nested loop:
3968839690

3968939691
**Outer loop**:
@@ -75141,6 +75143,11 @@ paths:
7514175143
description: Page number of the results to fetch.
7514275144
in: query
7514375145
schema: *20
75146+
- name: repository_id
75147+
description: ID of the Repository to filter on
75148+
in: query
75149+
schema:
75150+
type: integer
7514475151
responses:
7514575152
'200':
7514675153
description: Response

0 commit comments

Comments
 (0)