|
11282 | 11282 | "description": "Response",
|
11283 | 11283 | "examples": [
|
11284 | 11284 | {
|
11285 |
| - "data": "{\"ref\":\"refs/heads/main\",\"commit_sha\":\"c18c69115654ff0166991962832dc2bd7756e655\",\"analysis_key\":\".github/workflows/codeql-analysis.yml:analyze\",\"environment\":\"{\\\"language\\\":\\\"javascript\\\"}\",\"error\":\"\",\"created_at\":\"2021-01-13T11:55:49Z\",\"results_count\":3,\"rules_count\":67,\"id\":3602840,\"url\":\"https://api.github.com/repos/octocat/hello-world/code-scanning/analyses/201\",\"sarif_id\":\"47177e22-5596-11eb-80a1-c1e54ef945c6\",\"tool\":{\"name\":\"CodeQL\",\"guid\":null,\"version\":\"2.4.0\"},\"deletable\":true}" |
| 11285 | + "data": "{\"ref\":\"refs/heads/main\",\"commit_sha\":\"c18c69115654ff0166991962832dc2bd7756e655\",\"analysis_key\":\".github/workflows/codeql-analysis.yml:analyze\",\"environment\":\"{\\\"language\\\":\\\"javascript\\\"}\",\"error\":\"\",\"created_at\":\"2021-01-13T11:55:49Z\",\"results_count\":3,\"rules_count\":67,\"id\":3602840,\"url\":\"https://api.github.com/repos/octocat/hello-world/code-scanning/analyses/201\",\"sarif_id\":\"47177e22-5596-11eb-80a1-c1e54ef945c6\",\"tool\":{\"name\":\"CodeQL\",\"guid\":null,\"version\":\"2.4.0\"},\"deletable\":true,\"warning\":\"\"}" |
11286 | 11286 | }
|
11287 | 11287 | ]
|
11288 | 11288 | },
|
|
11747 | 11747 | "description": "Response",
|
11748 | 11748 | "examples": [
|
11749 | 11749 | {
|
11750 |
| - "data": "[{\"ref\":\"refs/heads/main\",\"commit_sha\":\"d99612c3e1f2970085cfbaeadf8f010ef69bad83\",\"analysis_key\":\".github/workflows/codeql-analysis.yml:analyze\",\"environment\":\"{\\\"language\\\":\\\"python\\\"}\",\"error\":\"\",\"created_at\":\"2020-08-27T15:05:21Z\",\"results_count\":17,\"rules_count\":49,\"id\":201,\"url\":\"https://api.github.com/repos/octocat/hello-world/code-scanning/analyses/201\",\"sarif_id\":\"6c81cd8e-b078-4ac3-a3be-1dad7dbd0b53\",\"tool\":{\"name\":\"CodeQL\",\"guid\":null,\"version\":\"2.4.0\"},\"deletable\":true},{\"ref\":\"refs/heads/my-branch\",\"commit_sha\":\"c8cff6510d4d084fb1b4aa13b64b97ca12b07321\",\"analysis_key\":\".github/workflows/shiftleft.yml:build\",\"environment\":\"{}\",\"error\":\"\",\"created_at\":\"2020-08-31T22:46:44Z\",\"results_count\":17,\"rules_count\":32,\"id\":200,\"url\":\"https://api.github.com/repos/octocat/hello-world/code-scanning/analyses/200\",\"sarif_id\":\"8981cd8e-b078-4ac3-a3be-1dad7dbd0b582\",\"tool\":{\"name\":\"Python Security Analysis\",\"guid\":null,\"version\":\"1.2.0\"},\"deletable\":true}]" |
| 11750 | + "data": "[{\"ref\":\"refs/heads/main\",\"commit_sha\":\"d99612c3e1f2970085cfbaeadf8f010ef69bad83\",\"analysis_key\":\".github/workflows/codeql-analysis.yml:analyze\",\"environment\":\"{\\\"language\\\":\\\"python\\\"}\",\"error\":\"\",\"created_at\":\"2020-08-27T15:05:21Z\",\"results_count\":17,\"rules_count\":49,\"id\":201,\"url\":\"https://api.github.com/repos/octocat/hello-world/code-scanning/analyses/201\",\"sarif_id\":\"6c81cd8e-b078-4ac3-a3be-1dad7dbd0b53\",\"tool\":{\"name\":\"CodeQL\",\"guid\":null,\"version\":\"2.4.0\"},\"deletable\":true,\"warning\":\"\"},{\"ref\":\"refs/heads/my-branch\",\"commit_sha\":\"c8cff6510d4d084fb1b4aa13b64b97ca12b07321\",\"analysis_key\":\".github/workflows/shiftleft.yml:build\",\"environment\":\"{}\",\"error\":\"\",\"created_at\":\"2020-08-31T22:46:44Z\",\"results_count\":17,\"rules_count\":32,\"id\":200,\"url\":\"https://api.github.com/repos/octocat/hello-world/code-scanning/analyses/200\",\"sarif_id\":\"8981cd8e-b078-4ac3-a3be-1dad7dbd0b582\",\"tool\":{\"name\":\"Python Security Analysis\",\"guid\":null,\"version\":\"1.2.0\"},\"deletable\":true,\"warning\":\"\"}]" |
11751 | 11751 | }
|
11752 | 11752 | ]
|
11753 | 11753 | },
|
|
11868 | 11868 | "url": "/repos/{owner}/{repo}/code-scanning/sarifs",
|
11869 | 11869 | "isDeprecated": false,
|
11870 | 11870 | "deprecationDate": null,
|
11871 |
| - "description": "Uploads SARIF data containing the results of a code scanning analysis to make the results available in a repository. You must use an access token with the `security_events` scope to use this endpoint. GitHub Apps must have the `security_events` write permission to use this endpoint.\n\nThere are two places where you can upload code scanning results.\n - If you upload to a pull request, for example `--ref refs/pull/42/merge` or `--ref refs/pull/42/head`, then the results appear as alerts in a pull request check. For more information, see \"[Triaging code scanning alerts in pull requests](/github/finding-security-vulnerabilities-and-errors-in-your-code/triaging-code-scanning-alerts-in-pull-requests).\"\n - If you upload to a branch, for example `--ref refs/heads/my-branch`, then the results appear in the **Security** tab for your repository. For more information, see \"[Managing code scanning alerts for your repository](/github/finding-security-vulnerabilities-and-errors-in-your-code/managing-code-scanning-alerts-for-your-repository#viewing-the-alerts-for-a-repository).\"\n\nYou must compress the SARIF-formatted analysis data that you want to upload, using `gzip`, and then encode it as a Base64 format string. For example:\n\n```\ngzip -c analysis-data.sarif | base64\n```\n\nSARIF upload supports a maximum of 1000 results per analysis run. Any results over this limit are ignored. Typically, but not necessarily, a SARIF file contains a single run of a single tool. If a code scanning tool generates too many results, you should update the analysis configuration to run only the most important rules or queries.\n\nThe `202 Accepted`, response includes an `id` value.\nYou can use this ID to check the status of the upload by using this for the `/sarifs/{sarif_id}` endpoint.\nFor more information, see \"[Get information about a SARIF upload](/rest/reference/code-scanning#get-information-about-a-sarif-upload).\"", |
| 11871 | + "description": "Uploads SARIF data containing the results of a code scanning analysis to make the results available in a repository. You must use an access token with the `security_events` scope to use this endpoint. GitHub Apps must have the `security_events` write permission to use this endpoint.\n\nThere are two places where you can upload code scanning results.\n - If you upload to a pull request, for example `--ref refs/pull/42/merge` or `--ref refs/pull/42/head`, then the results appear as alerts in a pull request check. For more information, see \"[Triaging code scanning alerts in pull requests](/github/finding-security-vulnerabilities-and-errors-in-your-code/triaging-code-scanning-alerts-in-pull-requests).\"\n - If you upload to a branch, for example `--ref refs/heads/my-branch`, then the results appear in the **Security** tab for your repository. For more information, see \"[Managing code scanning alerts for your repository](/github/finding-security-vulnerabilities-and-errors-in-your-code/managing-code-scanning-alerts-for-your-repository#viewing-the-alerts-for-a-repository).\"\n\nYou must compress the SARIF-formatted analysis data that you want to upload, using `gzip`, and then encode it as a Base64 format string. For example:\n\n```\ngzip -c analysis-data.sarif | base64 -w0\n```\n\nSARIF upload supports a maximum of 5000 results per analysis run. Any results over this limit are ignored and any SARIF uploads with more than 25,000 results are rejected. Typically, but not necessarily, a SARIF file contains a single run of a single tool. If a code scanning tool generates too many results, you should update the analysis configuration to run only the most important rules or queries.\n\nThe `202 Accepted`, response includes an `id` value.\nYou can use this ID to check the status of the upload by using this for the `/sarifs/{sarif_id}` endpoint.\nFor more information, see \"[Get information about a SARIF upload](/rest/reference/code-scanning#get-information-about-a-sarif-upload).\"", |
11872 | 11872 | "documentationUrl": "https://docs.github.com/rest/reference/code-scanning#upload-an-analysis-as-sarif-data",
|
11873 | 11873 | "previews": [],
|
11874 | 11874 | "headers": [],
|
|
11979 | 11979 | }
|
11980 | 11980 | ],
|
11981 | 11981 | "responses": [
|
11982 |
| - { "code": 200, "description": "Response", "examples": null }, |
11983 | 11982 | {
|
11984 | 11983 | "code": 202,
|
11985 | 11984 | "description": "Response",
|
|
0 commit comments