Skip to content

Commit 1f70a85

Browse files
Commit via running ake Sources/secret-scanning
1 parent 55d9423 commit 1f70a85

File tree

2 files changed

+84
-64
lines changed

2 files changed

+84
-64
lines changed

Sources/secret-scanning/Client.swift

Lines changed: 21 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,12 @@ public struct Client: APIProtocol {
4141
/// List secret scanning alerts for an enterprise
4242
///
4343
/// Lists secret scanning alerts for eligible repositories in an enterprise, from newest to oldest.
44-
/// To use this endpoint, you must be a member of the enterprise, and you must use an access token with the `repo` scope or `security_events` scope. Alerts are only returned for organizations in the enterprise for which you are an organization owner or a [security manager](https://docs.github.com/organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization).
44+
///
45+
/// Alerts are only returned for organizations in the enterprise for which the authenticated user is an organization owner or a [security manager](https://docs.github.com/organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization).
46+
///
47+
/// The authenticated user must be a member of the enterprise in order to use this endpoint.
48+
///
49+
/// OAuth app tokens and personal access tokens (classic) need the `repo` scope or `security_events` scope to use this endpoint.
4550
///
4651
/// - Remark: HTTP `GET /enterprises/{enterprise}/secret-scanning/alerts`.
4752
/// - Remark: Generated from `#/paths//enterprises/{enterprise}/secret-scanning/alerts/get(secret-scanning/list-alerts-for-enterprise)`.
@@ -221,10 +226,10 @@ public struct Client: APIProtocol {
221226
/// List secret scanning alerts for an organization
222227
///
223228
/// Lists secret scanning alerts for eligible repositories in an organization, from newest to oldest.
224-
/// To use this endpoint, you must be an administrator or security manager for the organization, and you must use an access token with the `repo` scope or `security_events` scope.
225-
/// For public repositories, you may instead use the `public_repo` scope.
226229
///
227-
/// GitHub Apps must have the `secret_scanning_alerts` read permission to use this endpoint.
230+
/// The authenticated user must be an administrator or security manager for the organization to use this endpoint.
231+
///
232+
/// OAuth app tokens and personal access tokens (classic) need the `repo` or `security_events` scope to use this endpoint. If this endpoint is only used with public repositories, the token can use the `public_repo` scope instead.
228233
///
229234
/// - Remark: HTTP `GET /orgs/{org}/secret-scanning/alerts`.
230235
/// - Remark: Generated from `#/paths//orgs/{org}/secret-scanning/alerts/get(secret-scanning/list-alerts-for-org)`.
@@ -411,10 +416,10 @@ public struct Client: APIProtocol {
411416
/// List secret scanning alerts for a repository
412417
///
413418
/// Lists secret scanning alerts for an eligible repository, from newest to oldest.
414-
/// To use this endpoint, you must be an administrator for the repository or for the organization that owns the repository, and you must use a personal access token with the `repo` scope or `security_events` scope.
415-
/// For public repositories, you may instead use the `public_repo` scope.
416419
///
417-
/// GitHub Apps must have the `secret_scanning_alerts` read permission to use this endpoint.
420+
/// The authenticated user must be an administrator for the repository or for the organization that owns the repository to use this endpoint.
421+
///
422+
/// OAuth app tokens and personal access tokens (classic) need the `repo` or `security_events` scope to use this endpoint. If this endpoint is only used with public repositories, the token can use the `public_repo` scope instead.
418423
///
419424
/// - Remark: HTTP `GET /repos/{owner}/{repo}/secret-scanning/alerts`.
420425
/// - Remark: Generated from `#/paths//repos/{owner}/{repo}/secret-scanning/alerts/get(secret-scanning/list-alerts-for-repo)`.
@@ -574,10 +579,10 @@ public struct Client: APIProtocol {
574579
/// Get a secret scanning alert
575580
///
576581
/// Gets a single secret scanning alert detected in an eligible repository.
577-
/// To use this endpoint, you must be an administrator for the repository or for the organization that owns the repository, and you must use a personal access token with the `repo` scope or `security_events` scope.
578-
/// For public repositories, you may instead use the `public_repo` scope.
579582
///
580-
/// GitHub Apps must have the `secret_scanning_alerts` read permission to use this endpoint.
583+
/// The authenticated user must be an administrator for the repository or for the organization that owns the repository to use this endpoint.
584+
///
585+
/// OAuth app tokens and personal access tokens (classic) need the `repo` or `security_events` scope to use this endpoint. If this endpoint is only used with public repositories, the token can use the `public_repo` scope instead.
581586
///
582587
/// - Remark: HTTP `GET /repos/{owner}/{repo}/secret-scanning/alerts/{alert_number}`.
583588
/// - Remark: Generated from `#/paths//repos/{owner}/{repo}/secret-scanning/alerts/{alert_number}/get(secret-scanning/get-alert)`.
@@ -670,10 +675,10 @@ public struct Client: APIProtocol {
670675
/// Update a secret scanning alert
671676
///
672677
/// Updates the status of a secret scanning alert in an eligible repository.
673-
/// To use this endpoint, you must be an administrator for the repository or for the organization that owns the repository, and you must use a personal access token with the `repo` scope or `security_events` scope.
674-
/// For public repositories, you may instead use the `public_repo` scope.
675678
///
676-
/// GitHub Apps must have the `secret_scanning_alerts` write permission to use this endpoint.
679+
/// The authenticated user must be an administrator for the repository or for the organization that owns the repository to use this endpoint.
680+
///
681+
/// OAuth app tokens and personal access tokens (classic) need the `repo` or `security_events` scope to use this endpoint. If this endpoint is only used with public repositories, the token can use the `public_repo` scope instead.
677682
///
678683
/// - Remark: HTTP `PATCH /repos/{owner}/{repo}/secret-scanning/alerts/{alert_number}`.
679684
/// - Remark: Generated from `#/paths//repos/{owner}/{repo}/secret-scanning/alerts/{alert_number}/patch(secret-scanning/update-alert)`.
@@ -777,10 +782,10 @@ public struct Client: APIProtocol {
777782
/// List locations for a secret scanning alert
778783
///
779784
/// Lists all locations for a given secret scanning alert for an eligible repository.
780-
/// To use this endpoint, you must be an administrator for the repository or for the organization that owns the repository, and you must use a personal access token with the `repo` scope or `security_events` scope.
781-
/// For public repositories, you may instead use the `public_repo` scope.
782785
///
783-
/// GitHub Apps must have the `secret_scanning_alerts` read permission to use this endpoint.
786+
/// The authenticated user must be an administrator for the repository or for the organization that owns the repository to use this endpoint.
787+
///
788+
/// OAuth app tokens and personal access tokens (classic) need the `repo` or `security_events` scope to use this endpoint. If this endpoint is only used with public repositories, the token can use the `public_repo` scope instead.
784789
///
785790
/// - Remark: HTTP `GET /repos/{owner}/{repo}/secret-scanning/alerts/{alert_number}/locations`.
786791
/// - Remark: Generated from `#/paths//repos/{owner}/{repo}/secret-scanning/alerts/{alert_number}/locations/get(secret-scanning/list-locations-for-alert)`.

0 commit comments

Comments
 (0)