diff --git a/Sources/apps/Client.swift b/Sources/apps/Client.swift index de332360634..104dcdb68f4 100644 --- a/Sources/apps/Client.swift +++ b/Sources/apps/Client.swift @@ -1388,7 +1388,7 @@ public struct Client: APIProtocol { } /// Delete an app authorization /// - /// OAuth and GitHub application owners can revoke a grant for their application and a specific user. You must use [Basic Authentication](https://docs.github.com/rest/authentication/authenticating-to-the-rest-api#using-basic-authentication) when accessing this endpoint, using the OAuth application's `client_id` and `client_secret` as the username and password. You must also provide a valid OAuth `access_token` as an input parameter and the grant for the token's owner will be deleted. + /// OAuth and GitHub application owners can revoke a grant for their application and a specific user. You must provide a valid OAuth `access_token` as an input parameter and the grant for the token's owner will be deleted. /// Deleting an application's grant will also delete all OAuth tokens associated with the application for the user. Once deleted, the application will have no access to the user's account and will no longer be listed on [the application authorizations settings screen within GitHub](https://github.com/settings/applications#authorized). /// /// - Remark: HTTP `DELETE /applications/{client_id}/grant`. @@ -1464,7 +1464,7 @@ public struct Client: APIProtocol { } /// Check a token /// - /// OAuth applications and GitHub applications with OAuth authorizations can use this API method for checking OAuth token validity without exceeding the normal rate limits for failed login attempts. Authentication works differently with this particular endpoint. You must use [Basic Authentication](https://docs.github.com/rest/authentication/authenticating-to-the-rest-api#using-basic-authentication) to use this endpoint, where the username is the application `client_id` and the password is its `client_secret`. Invalid tokens will return `404 NOT FOUND`. + /// OAuth applications and GitHub applications with OAuth authorizations can use this API method for checking OAuth token validity without exceeding the normal rate limits for failed login attempts. Authentication works differently with this particular endpoint. Invalid tokens will return `404 NOT FOUND`. /// /// - Remark: HTTP `POST /applications/{client_id}/token`. /// - Remark: Generated from `#/paths//applications/{client_id}/token/post(apps/check-token)`. @@ -1581,7 +1581,7 @@ public struct Client: APIProtocol { } /// Reset a token /// - /// OAuth applications and GitHub applications with OAuth authorizations can use this API method to reset a valid OAuth token without end-user involvement. Applications must save the "token" property in the response because changes take effect immediately. You must use [Basic Authentication](https://docs.github.com/rest/authentication/authenticating-to-the-rest-api#using-basic-authentication) when accessing this endpoint, using the application's `client_id` and `client_secret` as the username and password. Invalid tokens will return `404 NOT FOUND`. + /// OAuth applications and GitHub applications with OAuth authorizations can use this API method to reset a valid OAuth token without end-user involvement. Applications must save the "token" property in the response because changes take effect immediately. Invalid tokens will return `404 NOT FOUND`. /// /// - Remark: HTTP `PATCH /applications/{client_id}/token`. /// - Remark: Generated from `#/paths//applications/{client_id}/token/patch(apps/reset-token)`. @@ -1676,7 +1676,7 @@ public struct Client: APIProtocol { } /// Delete an app token /// - /// OAuth or GitHub application owners can revoke a single token for an OAuth application or a GitHub application with an OAuth authorization. You must use [Basic Authentication](https://docs.github.com/rest/authentication/authenticating-to-the-rest-api#using-basic-authentication) when accessing this endpoint, using the application's `client_id` and `client_secret` as the username and password. + /// OAuth or GitHub application owners can revoke a single token for an OAuth application or a GitHub application with an OAuth authorization. /// /// - Remark: HTTP `DELETE /applications/{client_id}/token`. /// - Remark: Generated from `#/paths//applications/{client_id}/token/delete(apps/delete-token)`. @@ -1757,10 +1757,6 @@ public struct Client: APIProtocol { /// /// Invalid tokens will return `404 NOT FOUND`. /// - /// You must use [Basic Authentication](https://docs.github.com/rest/authentication/authenticating-to-the-rest-api#using-basic-authentication) - /// when accessing this endpoint, using the `client_id` and `client_secret` of the GitHub App - /// as the username and password. - /// /// - Remark: HTTP `POST /applications/{client_id}/token/scoped`. /// - Remark: Generated from `#/paths//applications/{client_id}/token/scoped/post(apps/scope-token)`. public func apps_sol_scope_hyphen_token(_ input: Operations.apps_sol_scope_hyphen_token.Input) async throws -> Operations.apps_sol_scope_hyphen_token.Output { @@ -3375,7 +3371,9 @@ public struct Client: APIProtocol { } /// Add a repository to an app installation /// - /// Add a single repository to an installation. The authenticated user must have admin access to the repository. + /// Add a single repository to an installation. The authenticated user must have admin access to the repository. + /// + /// This endpoint only works for PATs (classic) with the `repo` scope. /// /// - Remark: HTTP `PUT /user/installations/{installation_id}/repositories/{repository_id}`. /// - Remark: Generated from `#/paths//user/installations/{installation_id}/repositories/{repository_id}/put(apps/add-repo-to-installation-for-authenticated-user)`. @@ -3466,7 +3464,9 @@ public struct Client: APIProtocol { } /// Remove a repository from an app installation /// - /// Remove a single repository from an installation. The authenticated user must have admin access to the repository. The installation must have the `repository_selection` of `selected`. + /// Remove a single repository from an installation. The authenticated user must have admin access to the repository. The installation must have the `repository_selection` of `selected`. + /// + /// This endpoint only works for PATs (classic) with the `repo` scope. /// /// - Remark: HTTP `DELETE /user/installations/{installation_id}/repositories/{repository_id}`. /// - Remark: Generated from `#/paths//user/installations/{installation_id}/repositories/{repository_id}/delete(apps/remove-repo-from-installation-for-authenticated-user)`. diff --git a/Sources/apps/Types.swift b/Sources/apps/Types.swift index 3cf04b1188e..7e4fffed9b5 100644 --- a/Sources/apps/Types.swift +++ b/Sources/apps/Types.swift @@ -141,7 +141,7 @@ public protocol APIProtocol: Sendable { func apps_sol_unsuspend_hyphen_installation(_ input: Operations.apps_sol_unsuspend_hyphen_installation.Input) async throws -> Operations.apps_sol_unsuspend_hyphen_installation.Output /// Delete an app authorization /// - /// OAuth and GitHub application owners can revoke a grant for their application and a specific user. You must use [Basic Authentication](https://docs.github.com/rest/authentication/authenticating-to-the-rest-api#using-basic-authentication) when accessing this endpoint, using the OAuth application's `client_id` and `client_secret` as the username and password. You must also provide a valid OAuth `access_token` as an input parameter and the grant for the token's owner will be deleted. + /// OAuth and GitHub application owners can revoke a grant for their application and a specific user. You must provide a valid OAuth `access_token` as an input parameter and the grant for the token's owner will be deleted. /// Deleting an application's grant will also delete all OAuth tokens associated with the application for the user. Once deleted, the application will have no access to the user's account and will no longer be listed on [the application authorizations settings screen within GitHub](https://github.com/settings/applications#authorized). /// /// - Remark: HTTP `DELETE /applications/{client_id}/grant`. @@ -149,21 +149,21 @@ public protocol APIProtocol: Sendable { func apps_sol_delete_hyphen_authorization(_ input: Operations.apps_sol_delete_hyphen_authorization.Input) async throws -> Operations.apps_sol_delete_hyphen_authorization.Output /// Check a token /// - /// OAuth applications and GitHub applications with OAuth authorizations can use this API method for checking OAuth token validity without exceeding the normal rate limits for failed login attempts. Authentication works differently with this particular endpoint. You must use [Basic Authentication](https://docs.github.com/rest/authentication/authenticating-to-the-rest-api#using-basic-authentication) to use this endpoint, where the username is the application `client_id` and the password is its `client_secret`. Invalid tokens will return `404 NOT FOUND`. + /// OAuth applications and GitHub applications with OAuth authorizations can use this API method for checking OAuth token validity without exceeding the normal rate limits for failed login attempts. Authentication works differently with this particular endpoint. Invalid tokens will return `404 NOT FOUND`. /// /// - Remark: HTTP `POST /applications/{client_id}/token`. /// - Remark: Generated from `#/paths//applications/{client_id}/token/post(apps/check-token)`. func apps_sol_check_hyphen_token(_ input: Operations.apps_sol_check_hyphen_token.Input) async throws -> Operations.apps_sol_check_hyphen_token.Output /// Reset a token /// - /// OAuth applications and GitHub applications with OAuth authorizations can use this API method to reset a valid OAuth token without end-user involvement. Applications must save the "token" property in the response because changes take effect immediately. You must use [Basic Authentication](https://docs.github.com/rest/authentication/authenticating-to-the-rest-api#using-basic-authentication) when accessing this endpoint, using the application's `client_id` and `client_secret` as the username and password. Invalid tokens will return `404 NOT FOUND`. + /// OAuth applications and GitHub applications with OAuth authorizations can use this API method to reset a valid OAuth token without end-user involvement. Applications must save the "token" property in the response because changes take effect immediately. Invalid tokens will return `404 NOT FOUND`. /// /// - Remark: HTTP `PATCH /applications/{client_id}/token`. /// - Remark: Generated from `#/paths//applications/{client_id}/token/patch(apps/reset-token)`. func apps_sol_reset_hyphen_token(_ input: Operations.apps_sol_reset_hyphen_token.Input) async throws -> Operations.apps_sol_reset_hyphen_token.Output /// Delete an app token /// - /// OAuth or GitHub application owners can revoke a single token for an OAuth application or a GitHub application with an OAuth authorization. You must use [Basic Authentication](https://docs.github.com/rest/authentication/authenticating-to-the-rest-api#using-basic-authentication) when accessing this endpoint, using the application's `client_id` and `client_secret` as the username and password. + /// OAuth or GitHub application owners can revoke a single token for an OAuth application or a GitHub application with an OAuth authorization. /// /// - Remark: HTTP `DELETE /applications/{client_id}/token`. /// - Remark: Generated from `#/paths//applications/{client_id}/token/delete(apps/delete-token)`. @@ -176,10 +176,6 @@ public protocol APIProtocol: Sendable { /// /// Invalid tokens will return `404 NOT FOUND`. /// - /// You must use [Basic Authentication](https://docs.github.com/rest/authentication/authenticating-to-the-rest-api#using-basic-authentication) - /// when accessing this endpoint, using the `client_id` and `client_secret` of the GitHub App - /// as the username and password. - /// /// - Remark: HTTP `POST /applications/{client_id}/token/scoped`. /// - Remark: Generated from `#/paths//applications/{client_id}/token/scoped/post(apps/scope-token)`. func apps_sol_scope_hyphen_token(_ input: Operations.apps_sol_scope_hyphen_token.Input) async throws -> Operations.apps_sol_scope_hyphen_token.Output @@ -302,14 +298,18 @@ public protocol APIProtocol: Sendable { func apps_sol_list_hyphen_installation_hyphen_repos_hyphen_for_hyphen_authenticated_hyphen_user(_ input: Operations.apps_sol_list_hyphen_installation_hyphen_repos_hyphen_for_hyphen_authenticated_hyphen_user.Input) async throws -> Operations.apps_sol_list_hyphen_installation_hyphen_repos_hyphen_for_hyphen_authenticated_hyphen_user.Output /// Add a repository to an app installation /// - /// Add a single repository to an installation. The authenticated user must have admin access to the repository. + /// Add a single repository to an installation. The authenticated user must have admin access to the repository. + /// + /// This endpoint only works for PATs (classic) with the `repo` scope. /// /// - Remark: HTTP `PUT /user/installations/{installation_id}/repositories/{repository_id}`. /// - Remark: Generated from `#/paths//user/installations/{installation_id}/repositories/{repository_id}/put(apps/add-repo-to-installation-for-authenticated-user)`. func apps_sol_add_hyphen_repo_hyphen_to_hyphen_installation_hyphen_for_hyphen_authenticated_hyphen_user(_ input: Operations.apps_sol_add_hyphen_repo_hyphen_to_hyphen_installation_hyphen_for_hyphen_authenticated_hyphen_user.Input) async throws -> Operations.apps_sol_add_hyphen_repo_hyphen_to_hyphen_installation_hyphen_for_hyphen_authenticated_hyphen_user.Output /// Remove a repository from an app installation /// - /// Remove a single repository from an installation. The authenticated user must have admin access to the repository. The installation must have the `repository_selection` of `selected`. + /// Remove a single repository from an installation. The authenticated user must have admin access to the repository. The installation must have the `repository_selection` of `selected`. + /// + /// This endpoint only works for PATs (classic) with the `repo` scope. /// /// - Remark: HTTP `DELETE /user/installations/{installation_id}/repositories/{repository_id}`. /// - Remark: Generated from `#/paths//user/installations/{installation_id}/repositories/{repository_id}/delete(apps/remove-repo-from-installation-for-authenticated-user)`. @@ -573,7 +573,7 @@ extension APIProtocol { } /// Delete an app authorization /// - /// OAuth and GitHub application owners can revoke a grant for their application and a specific user. You must use [Basic Authentication](https://docs.github.com/rest/authentication/authenticating-to-the-rest-api#using-basic-authentication) when accessing this endpoint, using the OAuth application's `client_id` and `client_secret` as the username and password. You must also provide a valid OAuth `access_token` as an input parameter and the grant for the token's owner will be deleted. + /// OAuth and GitHub application owners can revoke a grant for their application and a specific user. You must provide a valid OAuth `access_token` as an input parameter and the grant for the token's owner will be deleted. /// Deleting an application's grant will also delete all OAuth tokens associated with the application for the user. Once deleted, the application will have no access to the user's account and will no longer be listed on [the application authorizations settings screen within GitHub](https://github.com/settings/applications#authorized). /// /// - Remark: HTTP `DELETE /applications/{client_id}/grant`. @@ -591,7 +591,7 @@ extension APIProtocol { } /// Check a token /// - /// OAuth applications and GitHub applications with OAuth authorizations can use this API method for checking OAuth token validity without exceeding the normal rate limits for failed login attempts. Authentication works differently with this particular endpoint. You must use [Basic Authentication](https://docs.github.com/rest/authentication/authenticating-to-the-rest-api#using-basic-authentication) to use this endpoint, where the username is the application `client_id` and the password is its `client_secret`. Invalid tokens will return `404 NOT FOUND`. + /// OAuth applications and GitHub applications with OAuth authorizations can use this API method for checking OAuth token validity without exceeding the normal rate limits for failed login attempts. Authentication works differently with this particular endpoint. Invalid tokens will return `404 NOT FOUND`. /// /// - Remark: HTTP `POST /applications/{client_id}/token`. /// - Remark: Generated from `#/paths//applications/{client_id}/token/post(apps/check-token)`. @@ -608,7 +608,7 @@ extension APIProtocol { } /// Reset a token /// - /// OAuth applications and GitHub applications with OAuth authorizations can use this API method to reset a valid OAuth token without end-user involvement. Applications must save the "token" property in the response because changes take effect immediately. You must use [Basic Authentication](https://docs.github.com/rest/authentication/authenticating-to-the-rest-api#using-basic-authentication) when accessing this endpoint, using the application's `client_id` and `client_secret` as the username and password. Invalid tokens will return `404 NOT FOUND`. + /// OAuth applications and GitHub applications with OAuth authorizations can use this API method to reset a valid OAuth token without end-user involvement. Applications must save the "token" property in the response because changes take effect immediately. Invalid tokens will return `404 NOT FOUND`. /// /// - Remark: HTTP `PATCH /applications/{client_id}/token`. /// - Remark: Generated from `#/paths//applications/{client_id}/token/patch(apps/reset-token)`. @@ -625,7 +625,7 @@ extension APIProtocol { } /// Delete an app token /// - /// OAuth or GitHub application owners can revoke a single token for an OAuth application or a GitHub application with an OAuth authorization. You must use [Basic Authentication](https://docs.github.com/rest/authentication/authenticating-to-the-rest-api#using-basic-authentication) when accessing this endpoint, using the application's `client_id` and `client_secret` as the username and password. + /// OAuth or GitHub application owners can revoke a single token for an OAuth application or a GitHub application with an OAuth authorization. /// /// - Remark: HTTP `DELETE /applications/{client_id}/token`. /// - Remark: Generated from `#/paths//applications/{client_id}/token/delete(apps/delete-token)`. @@ -648,10 +648,6 @@ extension APIProtocol { /// /// Invalid tokens will return `404 NOT FOUND`. /// - /// You must use [Basic Authentication](https://docs.github.com/rest/authentication/authenticating-to-the-rest-api#using-basic-authentication) - /// when accessing this endpoint, using the `client_id` and `client_secret` of the GitHub App - /// as the username and password. - /// /// - Remark: HTTP `POST /applications/{client_id}/token/scoped`. /// - Remark: Generated from `#/paths//applications/{client_id}/token/scoped/post(apps/scope-token)`. public func apps_sol_scope_hyphen_token( @@ -888,7 +884,9 @@ extension APIProtocol { } /// Add a repository to an app installation /// - /// Add a single repository to an installation. The authenticated user must have admin access to the repository. + /// Add a single repository to an installation. The authenticated user must have admin access to the repository. + /// + /// This endpoint only works for PATs (classic) with the `repo` scope. /// /// - Remark: HTTP `PUT /user/installations/{installation_id}/repositories/{repository_id}`. /// - Remark: Generated from `#/paths//user/installations/{installation_id}/repositories/{repository_id}/put(apps/add-repo-to-installation-for-authenticated-user)`. @@ -903,7 +901,9 @@ extension APIProtocol { } /// Remove a repository from an app installation /// - /// Remove a single repository from an installation. The authenticated user must have admin access to the repository. The installation must have the `repository_selection` of `selected`. + /// Remove a single repository from an installation. The authenticated user must have admin access to the repository. The installation must have the `repository_selection` of `selected`. + /// + /// This endpoint only works for PATs (classic) with the `repo` scope. /// /// - Remark: HTTP `DELETE /user/installations/{installation_id}/repositories/{repository_id}`. /// - Remark: Generated from `#/paths//user/installations/{installation_id}/repositories/{repository_id}/delete(apps/remove-repo-from-installation-for-authenticated-user)`. @@ -7426,7 +7426,7 @@ public enum Operations { } /// Delete an app authorization /// - /// OAuth and GitHub application owners can revoke a grant for their application and a specific user. You must use [Basic Authentication](https://docs.github.com/rest/authentication/authenticating-to-the-rest-api#using-basic-authentication) when accessing this endpoint, using the OAuth application's `client_id` and `client_secret` as the username and password. You must also provide a valid OAuth `access_token` as an input parameter and the grant for the token's owner will be deleted. + /// OAuth and GitHub application owners can revoke a grant for their application and a specific user. You must provide a valid OAuth `access_token` as an input parameter and the grant for the token's owner will be deleted. /// Deleting an application's grant will also delete all OAuth tokens associated with the application for the user. Once deleted, the application will have no access to the user's account and will no longer be listed on [the application authorizations settings screen within GitHub](https://github.com/settings/applications#authorized). /// /// - Remark: HTTP `DELETE /applications/{client_id}/grant`. @@ -7584,7 +7584,7 @@ public enum Operations { } /// Check a token /// - /// OAuth applications and GitHub applications with OAuth authorizations can use this API method for checking OAuth token validity without exceeding the normal rate limits for failed login attempts. Authentication works differently with this particular endpoint. You must use [Basic Authentication](https://docs.github.com/rest/authentication/authenticating-to-the-rest-api#using-basic-authentication) to use this endpoint, where the username is the application `client_id` and the password is its `client_secret`. Invalid tokens will return `404 NOT FOUND`. + /// OAuth applications and GitHub applications with OAuth authorizations can use this API method for checking OAuth token validity without exceeding the normal rate limits for failed login attempts. Authentication works differently with this particular endpoint. Invalid tokens will return `404 NOT FOUND`. /// /// - Remark: HTTP `POST /applications/{client_id}/token`. /// - Remark: Generated from `#/paths//applications/{client_id}/token/post(apps/check-token)`. @@ -7788,7 +7788,7 @@ public enum Operations { } /// Reset a token /// - /// OAuth applications and GitHub applications with OAuth authorizations can use this API method to reset a valid OAuth token without end-user involvement. Applications must save the "token" property in the response because changes take effect immediately. You must use [Basic Authentication](https://docs.github.com/rest/authentication/authenticating-to-the-rest-api#using-basic-authentication) when accessing this endpoint, using the application's `client_id` and `client_secret` as the username and password. Invalid tokens will return `404 NOT FOUND`. + /// OAuth applications and GitHub applications with OAuth authorizations can use this API method to reset a valid OAuth token without end-user involvement. Applications must save the "token" property in the response because changes take effect immediately. Invalid tokens will return `404 NOT FOUND`. /// /// - Remark: HTTP `PATCH /applications/{client_id}/token`. /// - Remark: Generated from `#/paths//applications/{client_id}/token/patch(apps/reset-token)`. @@ -7969,7 +7969,7 @@ public enum Operations { } /// Delete an app token /// - /// OAuth or GitHub application owners can revoke a single token for an OAuth application or a GitHub application with an OAuth authorization. You must use [Basic Authentication](https://docs.github.com/rest/authentication/authenticating-to-the-rest-api#using-basic-authentication) when accessing this endpoint, using the application's `client_id` and `client_secret` as the username and password. + /// OAuth or GitHub application owners can revoke a single token for an OAuth application or a GitHub application with an OAuth authorization. /// /// - Remark: HTTP `DELETE /applications/{client_id}/token`. /// - Remark: Generated from `#/paths//applications/{client_id}/token/delete(apps/delete-token)`. @@ -8132,10 +8132,6 @@ public enum Operations { /// /// Invalid tokens will return `404 NOT FOUND`. /// - /// You must use [Basic Authentication](https://docs.github.com/rest/authentication/authenticating-to-the-rest-api#using-basic-authentication) - /// when accessing this endpoint, using the `client_id` and `client_secret` of the GitHub App - /// as the username and password. - /// /// - Remark: HTTP `POST /applications/{client_id}/token/scoped`. /// - Remark: Generated from `#/paths//applications/{client_id}/token/scoped/post(apps/scope-token)`. public enum apps_sol_scope_hyphen_token { @@ -11050,7 +11046,9 @@ public enum Operations { } /// Add a repository to an app installation /// - /// Add a single repository to an installation. The authenticated user must have admin access to the repository. + /// Add a single repository to an installation. The authenticated user must have admin access to the repository. + /// + /// This endpoint only works for PATs (classic) with the `repo` scope. /// /// - Remark: HTTP `PUT /user/installations/{installation_id}/repositories/{repository_id}`. /// - Remark: Generated from `#/paths//user/installations/{installation_id}/repositories/{repository_id}/put(apps/add-repo-to-installation-for-authenticated-user)`. @@ -11236,7 +11234,9 @@ public enum Operations { } /// Remove a repository from an app installation /// - /// Remove a single repository from an installation. The authenticated user must have admin access to the repository. The installation must have the `repository_selection` of `selected`. + /// Remove a single repository from an installation. The authenticated user must have admin access to the repository. The installation must have the `repository_selection` of `selected`. + /// + /// This endpoint only works for PATs (classic) with the `repo` scope. /// /// - Remark: HTTP `DELETE /user/installations/{installation_id}/repositories/{repository_id}`. /// - Remark: Generated from `#/paths//user/installations/{installation_id}/repositories/{repository_id}/delete(apps/remove-repo-from-installation-for-authenticated-user)`. diff --git a/Submodule/github/rest-api-description b/Submodule/github/rest-api-description index 4adfd3e5dd6..b29a2c59ea4 160000 --- a/Submodule/github/rest-api-description +++ b/Submodule/github/rest-api-description @@ -1 +1 @@ -Subproject commit 4adfd3e5dd6abe3d8e334ba494079071d78c7fd4 +Subproject commit b29a2c59ea46a74c2ec81e8e2800c6d5a677b187