Skip to content

Commit 60c017c

Browse files
author
Marc-Andre Giroux
authored
Merge pull request #427 from github/openapi-update-cff23b4d44463aca861a4ab3fc315eb2239eb8fc82d06d8b67f6c3a74d0b17b3
Update OpenAPI Descriptions
2 parents 0ea4083 + aa21690 commit 60c017c

36 files changed

+674
-28
lines changed

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

Lines changed: 25 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17400,12 +17400,22 @@
1740017400
},
1740117401
"security_and_analysis": {
1740217402
"type": "object",
17403-
"description": "Specify which security and analysis features to enable or disable.",
17403+
"description": "Specify which security and analysis features to enable or disable. For example, to enable GitHub Advanced Security, use this data in the body of the PATCH request: `{\"security_and_analysis\": {\"advanced_security\": {\"status\": \"enabled\"}}}`. If you have admin permissions for a private repository covered by an Advanced Security license, you can check which security and analysis features are currently enabled by using a `GET /repos/{owner}/{repo}` request.",
1740417404
"nullable": true,
1740517405
"properties": {
1740617406
"advanced_security": {
1740717407
"type": "object",
17408-
"description": "Use the `status` property to enable or disable GitHub Advanced Security for this repository. For more information, see \"[About GitHub Advanced Security](/github/getting-started-with-github/learning-about-github/about-github-advanced-security).\" If you're an admin user for a repository covered by an Advanced Security license, you can check whether Advanced Security is currently enabled by using a `GET /repos/{owner}/{repo}` request.",
17408+
"description": "Use the `status` property to enable or disable GitHub Advanced Security for this repository. For more information, see \"[About GitHub Advanced Security](/github/getting-started-with-github/learning-about-github/about-github-advanced-security).\"",
17409+
"properties": {
17410+
"status": {
17411+
"type": "string",
17412+
"description": "Can be `enabled` or `disabled`."
17413+
}
17414+
}
17415+
},
17416+
"secret_scanning": {
17417+
"type": "object",
17418+
"description": "Use the `status` property to enable or disable secret scanning for this repository. For more information, see \"[About secret scanning](/code-security/secret-security/about-secret-scanning).\"",
1740917419
"properties": {
1741017420
"status": {
1741117421
"type": "string",
@@ -24310,7 +24320,7 @@
2431024320
"/repos/{owner}/{repo}/code-scanning/analyses/{analysis_id}": {
2431124321
"get": {
2431224322
"summary": "Get a code scanning analysis for a repository",
24313-
"description": "Gets a specified code scanning analysis for a repository.\nYou must use an access token with the `security_events` scope to use this endpoint.\nGitHub Apps must have the `security_events` read permission to use this endpoint.\n\nThe default JSON response contains fields that describe the analysis.\nThis includes the Git reference and commit SHA to which the analysis relates,\nthe datetime of the analysis, the name of the code scanning tool,\nand the number of alerts.\n\nThe `rules_count` field in the default response give the number of rules\nthat were run in the analysis.\nFor very old analyses this data is not available,\nand `0` is returned in this field.\n\nIf you use the Accept header `application/sarif+json`,\nthe response contains the analysis data that was uploaded.\nThis is formatted as\n[SARIF version 2.1.0](https://docs.oasis-open.org/sarif/sarif/v2.1.0/cs01/sarif-v2.1.0-cs01.html).\nFor an example response, see \"[Custom media type for code scanning](#custom-media-type-for-code-scanning).\"\n\n**Deprecation notice**:\nThe `tool_name` field is deprecated and will, in future, not be included in the response for this endpoint. The example response reflects this change. The tool name can now be found inside the `tool` field.",
24323+
"description": "Gets a specified code scanning analysis for a repository.\nYou must use an access token with the `security_events` scope to use this endpoint.\nGitHub Apps must have the `security_events` read permission to use this endpoint.\n\nThe default JSON response contains fields that describe the analysis.\nThis includes the Git reference and commit SHA to which the analysis relates,\nthe datetime of the analysis, the name of the code scanning tool,\nand the number of alerts.\n\nThe `rules_count` field in the default response give the number of rules\nthat were run in the analysis.\nFor very old analyses this data is not available,\nand `0` is returned in this field.\n\nIf you use the Accept header `application/sarif+json`,\nthe response contains the analysis data that was uploaded.\nThis is formatted as\n[SARIF version 2.1.0](https://docs.oasis-open.org/sarif/sarif/v2.1.0/cs01/sarif-v2.1.0-cs01.html).\n\n**Deprecation notice**:\nThe `tool_name` field is deprecated and will, in future, not be included in the response for this endpoint. The example response reflects this change. The tool name can now be found inside the `tool` field.",
2431424324
"operationId": "code-scanning/get-analysis",
2431524325
"tags": [
2431624326
"code-scanning"
@@ -60136,6 +60146,18 @@
6013660146
]
6013760147
}
6013860148
}
60149+
},
60150+
"secret_scanning": {
60151+
"type": "object",
60152+
"properties": {
60153+
"status": {
60154+
"type": "string",
60155+
"enum": [
60156+
"enabled",
60157+
"disabled"
60158+
]
60159+
}
60160+
}
6013960161
}
6014060162
}
6014160163
}

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

Lines changed: 24 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -12439,19 +12439,29 @@ paths:
1243912439
- internal
1244012440
security_and_analysis:
1244112441
type: object
12442-
description: Specify which security and analysis features to enable
12443-
or disable.
12442+
description: 'Specify which security and analysis features to enable
12443+
or disable. For example, to enable GitHub Advanced Security, use
12444+
this data in the body of the PATCH request: `{"security_and_analysis":
12445+
{"advanced_security": {"status": "enabled"}}}`. If you have admin
12446+
permissions for a private repository covered by an Advanced Security
12447+
license, you can check which security and analysis features are
12448+
currently enabled by using a `GET /repos/{owner}/{repo}` request.'
1244412449
nullable: true
1244512450
properties:
1244612451
advanced_security:
1244712452
type: object
1244812453
description: Use the `status` property to enable or disable
1244912454
GitHub Advanced Security for this repository. For more information,
1245012455
see "[About GitHub Advanced Security](/github/getting-started-with-github/learning-about-github/about-github-advanced-security)."
12451-
If you're an admin user for a repository covered by an Advanced
12452-
Security license, you can check whether Advanced Security
12453-
is currently enabled by using a `GET /repos/{owner}/{repo}`
12454-
request.
12456+
properties:
12457+
status:
12458+
type: string
12459+
description: Can be `enabled` or `disabled`.
12460+
secret_scanning:
12461+
type: object
12462+
description: Use the `status` property to enable or disable
12463+
secret scanning for this repository. For more information,
12464+
see "[About secret scanning](/code-security/secret-security/about-secret-scanning)."
1245512465
properties:
1245612466
status:
1245712467
type: string
@@ -17392,7 +17402,6 @@ paths:
1739217402
the response contains the analysis data that was uploaded.
1739317403
This is formatted as
1739417404
[SARIF version 2.1.0](https://docs.oasis-open.org/sarif/sarif/v2.1.0/cs01/sarif-v2.1.0-cs01.html).
17395-
For an example response, see "[Custom media type for code scanning](#custom-media-type-for-code-scanning)."
1739617405

1739717406
**Deprecation notice**:
1739817407
The `tool_name` field is deprecated and will, in future, not be included in the response for this endpoint. The example response reflects this change. The tool name can now be found inside the `tool` field.
@@ -43582,6 +43591,14 @@ components:
4358243591
enum:
4358343592
- enabled
4358443593
- disabled
43594+
secret_scanning:
43595+
type: object
43596+
properties:
43597+
status:
43598+
type: string
43599+
enum:
43600+
- enabled
43601+
- disabled
4358543602
required:
4358643603
- archive_url
4358743604
- assignees_url

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

Lines changed: 49 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -115022,6 +115022,18 @@
115022115022
]
115023115023
}
115024115024
}
115025+
},
115026+
"secret_scanning": {
115027+
"type": "object",
115028+
"properties": {
115029+
"status": {
115030+
"type": "string",
115031+
"enum": [
115032+
"enabled",
115033+
"disabled"
115034+
]
115035+
}
115036+
}
115025115037
}
115026115038
}
115027115039
}
@@ -116289,12 +116301,22 @@
116289116301
},
116290116302
"security_and_analysis": {
116291116303
"type": "object",
116292-
"description": "Specify which security and analysis features to enable or disable.",
116304+
"description": "Specify which security and analysis features to enable or disable. For example, to enable GitHub Advanced Security, use this data in the body of the PATCH request: `{\"security_and_analysis\": {\"advanced_security\": {\"status\": \"enabled\"}}}`. If you have admin permissions for a private repository covered by an Advanced Security license, you can check which security and analysis features are currently enabled by using a `GET /repos/{owner}/{repo}` request.",
116293116305
"nullable": true,
116294116306
"properties": {
116295116307
"advanced_security": {
116296116308
"type": "object",
116297-
"description": "Use the `status` property to enable or disable GitHub Advanced Security for this repository. For more information, see \"[About GitHub Advanced Security](/github/getting-started-with-github/learning-about-github/about-github-advanced-security).\" If you're an admin user for a repository covered by an Advanced Security license, you can check whether Advanced Security is currently enabled by using a `GET /repos/{owner}/{repo}` request.",
116309+
"description": "Use the `status` property to enable or disable GitHub Advanced Security for this repository. For more information, see \"[About GitHub Advanced Security](/github/getting-started-with-github/learning-about-github/about-github-advanced-security).\"",
116310+
"properties": {
116311+
"status": {
116312+
"type": "string",
116313+
"description": "Can be `enabled` or `disabled`."
116314+
}
116315+
}
116316+
},
116317+
"secret_scanning": {
116318+
"type": "object",
116319+
"description": "Use the `status` property to enable or disable secret scanning for this repository. For more information, see \"[About secret scanning](/code-security/secret-security/about-secret-scanning).\"",
116298116320
"properties": {
116299116321
"status": {
116300116322
"type": "string",
@@ -120383,6 +120405,18 @@
120383120405
]
120384120406
}
120385120407
}
120408+
},
120409+
"secret_scanning": {
120410+
"type": "object",
120411+
"properties": {
120412+
"status": {
120413+
"type": "string",
120414+
"enum": [
120415+
"enabled",
120416+
"disabled"
120417+
]
120418+
}
120419+
}
120386120420
}
120387120421
}
120388120422
}
@@ -171893,7 +171927,7 @@
171893171927
"/repos/{owner}/{repo}/code-scanning/analyses/{analysis_id}": {
171894171928
"get": {
171895171929
"summary": "Get a code scanning analysis for a repository",
171896-
"description": "Gets a specified code scanning analysis for a repository.\nYou must use an access token with the `security_events` scope to use this endpoint.\nGitHub Apps must have the `security_events` read permission to use this endpoint.\n\nThe default JSON response contains fields that describe the analysis.\nThis includes the Git reference and commit SHA to which the analysis relates,\nthe datetime of the analysis, the name of the code scanning tool,\nand the number of alerts.\n\nThe `rules_count` field in the default response give the number of rules\nthat were run in the analysis.\nFor very old analyses this data is not available,\nand `0` is returned in this field.\n\nIf you use the Accept header `application/sarif+json`,\nthe response contains the analysis data that was uploaded.\nThis is formatted as\n[SARIF version 2.1.0](https://docs.oasis-open.org/sarif/sarif/v2.1.0/cs01/sarif-v2.1.0-cs01.html).\nFor an example response, see \"[Custom media type for code scanning](#custom-media-type-for-code-scanning).\"\n\n**Deprecation notice**:\nThe `tool_name` field is deprecated and will, in future, not be included in the response for this endpoint. The example response reflects this change. The tool name can now be found inside the `tool` field.",
171930+
"description": "Gets a specified code scanning analysis for a repository.\nYou must use an access token with the `security_events` scope to use this endpoint.\nGitHub Apps must have the `security_events` read permission to use this endpoint.\n\nThe default JSON response contains fields that describe the analysis.\nThis includes the Git reference and commit SHA to which the analysis relates,\nthe datetime of the analysis, the name of the code scanning tool,\nand the number of alerts.\n\nThe `rules_count` field in the default response give the number of rules\nthat were run in the analysis.\nFor very old analyses this data is not available,\nand `0` is returned in this field.\n\nIf you use the Accept header `application/sarif+json`,\nthe response contains the analysis data that was uploaded.\nThis is formatted as\n[SARIF version 2.1.0](https://docs.oasis-open.org/sarif/sarif/v2.1.0/cs01/sarif-v2.1.0-cs01.html).\n\n**Deprecation notice**:\nThe `tool_name` field is deprecated and will, in future, not be included in the response for this endpoint. The example response reflects this change. The tool name can now be found inside the `tool` field.",
171897171931
"operationId": "code-scanning/get-analysis",
171898171932
"tags": [
171899171933
"code-scanning"
@@ -211035,6 +211069,18 @@
211035211069
]
211036211070
}
211037211071
}
211072+
},
211073+
"secret_scanning": {
211074+
"type": "object",
211075+
"properties": {
211076+
"status": {
211077+
"type": "string",
211078+
"enum": [
211079+
"enabled",
211080+
"disabled"
211081+
]
211082+
}
211083+
}
211038211084
}
211039211085
}
211040211086
}

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

Lines changed: 24 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -26498,6 +26498,14 @@ paths:
2649826498
enum:
2649926499
- enabled
2650026500
- disabled
26501+
secret_scanning:
26502+
type: object
26503+
properties:
26504+
status:
26505+
type: string
26506+
enum:
26507+
- enabled
26508+
- disabled
2650126509
required: &217
2650226510
- archive_url
2650326511
- assignees_url
@@ -27643,19 +27651,29 @@ paths:
2764327651
- internal
2764427652
security_and_analysis:
2764527653
type: object
27646-
description: Specify which security and analysis features to enable
27647-
or disable.
27654+
description: 'Specify which security and analysis features to enable
27655+
or disable. For example, to enable GitHub Advanced Security, use
27656+
this data in the body of the PATCH request: `{"security_and_analysis":
27657+
{"advanced_security": {"status": "enabled"}}}`. If you have admin
27658+
permissions for a private repository covered by an Advanced Security
27659+
license, you can check which security and analysis features are
27660+
currently enabled by using a `GET /repos/{owner}/{repo}` request.'
2764827661
nullable: true
2764927662
properties:
2765027663
advanced_security:
2765127664
type: object
2765227665
description: Use the `status` property to enable or disable
2765327666
GitHub Advanced Security for this repository. For more information,
2765427667
see "[About GitHub Advanced Security](/github/getting-started-with-github/learning-about-github/about-github-advanced-security)."
27655-
If you're an admin user for a repository covered by an Advanced
27656-
Security license, you can check whether Advanced Security
27657-
is currently enabled by using a `GET /repos/{owner}/{repo}`
27658-
request.
27668+
properties:
27669+
status:
27670+
type: string
27671+
description: Can be `enabled` or `disabled`.
27672+
secret_scanning:
27673+
type: object
27674+
description: Use the `status` property to enable or disable
27675+
secret scanning for this repository. For more information,
27676+
see "[About secret scanning](/code-security/secret-security/about-secret-scanning)."
2765927677
properties:
2766027678
status:
2766127679
type: string
@@ -39006,7 +39024,6 @@ paths:
3900639024
the response contains the analysis data that was uploaded.
3900739025
This is formatted as
3900839026
[SARIF version 2.1.0](https://docs.oasis-open.org/sarif/sarif/v2.1.0/cs01/sarif-v2.1.0-cs01.html).
39009-
For an example response, see "[Custom media type for code scanning](#custom-media-type-for-code-scanning)."
3901039027

3901139028
**Deprecation notice**:
3901239029
The `tool_name` field is deprecated and will, in future, not be included in the response for this endpoint. The example response reflects this change. The tool name can now be found inside the `tool` field.

0 commit comments

Comments
 (0)