UNPKG

@octokit/openapi-types-ghec

Version:

Generated TypeScript definitions based on GitHub's OpenAPI spec for ghec

857 lines (854 loc) 5.32 MB
/** * This file was auto-generated by openapi-typescript. * Do not make direct changes to the file. */ /** OneOf type helpers */ type Without<T, U> = { [P in Exclude<keyof T, keyof U>]?: never }; type XOR<T, U> = T | U extends object ? (Without<T, U> & U) | (Without<U, T> & T) : T | U; type OneOf<T extends any[]> = T extends [infer Only] ? Only : T extends [infer A, infer B, ...infer Rest] ? OneOf<[XOR<A, B>, ...Rest]> : never; export interface paths { "/": { /** * GitHub API Root * @description Get Hypermedia links to resources accessible in GitHub's REST API */ get: operations["meta/root"]; }; "/advisories": { /** * List global security advisories * @description Lists all global security advisories that match the specified parameters. If no other parameters are defined, the request will return only GitHub-reviewed advisories that are not malware. * * By default, all responses will exclude advisories for malware, because malware are not standard vulnerabilities. To list advisories for malware, you must include the `type` parameter in your request, with the value `malware`. For more information about the different types of security advisories, see "[About the GitHub Advisory database](https://docs.github.com/enterprise-cloud@latest//code-security/security-advisories/global-security-advisories/about-the-github-advisory-database#about-types-of-security-advisories)." */ get: operations["security-advisories/list-global-advisories"]; }; "/advisories/{ghsa_id}": { /** * Get a global security advisory * @description Gets a global security advisory using its GitHub Security Advisory (GHSA) identifier. */ get: operations["security-advisories/get-global-advisory"]; }; "/app": { /** * Get the authenticated app * @description Returns the GitHub App associated with the authentication credentials used. To see how many app installations are associated with this GitHub App, see the `installations_count` in the response. For more details about your app's installations, see the "[List installations for the authenticated app](https://docs.github.com/enterprise-cloud@latest//rest/apps/apps#list-installations-for-the-authenticated-app)" endpoint. * * You must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint. */ get: operations["apps/get-authenticated"]; }; "/app-manifests/{code}/conversions": { /** * Create a GitHub App from a manifest * @description Use this endpoint to complete the handshake necessary when implementing the [GitHub App Manifest flow](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/creating-github-apps-from-a-manifest/). When you create a GitHub App with the manifest flow, you receive a temporary `code` used to retrieve the GitHub App's `id`, `pem` (private key), and `webhook_secret`. */ post: operations["apps/create-from-manifest"]; }; "/app/hook/config": { /** * Get a webhook configuration for an app * @description Returns the webhook configuration for a GitHub App. For more information about configuring a webhook for your app, see "[Creating a GitHub App](/developers/apps/creating-a-github-app)." * * You must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint. */ get: operations["apps/get-webhook-config-for-app"]; /** * Update a webhook configuration for an app * @description Updates the webhook configuration for a GitHub App. For more information about configuring a webhook for your app, see "[Creating a GitHub App](/developers/apps/creating-a-github-app)." * * You must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint. */ patch: operations["apps/update-webhook-config-for-app"]; }; "/app/hook/deliveries": { /** * List deliveries for an app webhook * @description Returns a list of webhook deliveries for the webhook configured for a GitHub App. * * You must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint. */ get: operations["apps/list-webhook-deliveries"]; }; "/app/hook/deliveries/{delivery_id}": { /** * Get a delivery for an app webhook * @description Returns a delivery for the webhook configured for a GitHub App. * * You must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint. */ get: operations["apps/get-webhook-delivery"]; }; "/app/hook/deliveries/{delivery_id}/attempts": { /** * Redeliver a delivery for an app webhook * @description Redeliver a delivery for the webhook configured for a GitHub App. * * You must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint. */ post: operations["apps/redeliver-webhook-delivery"]; }; "/app/installation-requests": { /** * List installation requests for the authenticated app * @description Lists all the pending installation requests for the authenticated GitHub App. */ get: operations["apps/list-installation-requests-for-authenticated-app"]; }; "/app/installations": { /** * List installations for the authenticated app * @description You must use a [JWT](https://docs.github.com/enterprise-server@3.9/apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint. * * The permissions the installation has are included under the `permissions` key. */ get: operations["apps/list-installations"]; }; "/app/installations/{installation_id}": { /** * Get an installation for the authenticated app * @description Enables an authenticated GitHub App to find an installation's information using the installation id. * * You must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint. */ get: operations["apps/get-installation"]; /** * Delete an installation for the authenticated app * @description Uninstalls a GitHub App on a user, organization, or enterprise account. If you prefer to temporarily suspend an app's access to your account's resources, then we recommend the "[Suspend an app installation](https://docs.github.com/enterprise-cloud@latest//rest/apps/apps#suspend-an-app-installation)" endpoint. * * You must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint. */ delete: operations["apps/delete-installation"]; }; "/app/installations/{installation_id}/access_tokens": { /** * Create an installation access token for an app * @description Creates an installation access token that enables a GitHub App to make authenticated API requests for the app's installation on an enterprise, organization, or individual account. Installation tokens expire one hour from the time you create them. Using an expired token produces a status code of `401 - Unauthorized`, and requires creating a new installation token. By default the installation token has access to all repositories that the installation can access. * * Optionally, you can use the `repositories` or `repository_ids` body parameters to specify individual repositories that the installation access token can access. If you don't use `repositories` or `repository_ids` to grant access to specific repositories, the installation access token will have access to all repositories that the installation was granted access to. The installation access token cannot be granted access to repositories that the installation was not granted access to. Up to 500 repositories can be listed in this manner. * * Optionally, use the `permissions` body parameter to specify the permissions that the installation access token should have. If `permissions` is not specified, the installation access token will have all of the permissions that were granted to the app. The installation access token cannot be granted permissions that the app was not granted. * * Enterprise account installations do not have access to repositories and cannot be scoped down using the `permissions` parameter. * * You must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint. */ post: operations["apps/create-installation-access-token"]; }; "/app/installations/{installation_id}/suspended": { /** * Suspend an app installation * @description Suspends a GitHub App on a user, organization, or enterprise account, which blocks the app from accessing the account's resources. When a GitHub App is suspended, the app's access to the GitHub Enterprise Cloud API or webhook events is blocked for that account. * * You must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint. */ put: operations["apps/suspend-installation"]; /** * Unsuspend an app installation * @description Removes a GitHub App installation suspension. * * You must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint. */ delete: operations["apps/unsuspend-installation"]; }; "/applications/{client_id}/grant": { /** * Delete an app authorization * @description 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). */ delete: operations["apps/delete-authorization"]; }; "/applications/{client_id}/token": { /** * Check a token * @description 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`. */ post: operations["apps/check-token"]; /** * Delete an app token * @description OAuth or GitHub application owners can revoke a single token for an OAuth application or a GitHub application with an OAuth authorization. */ delete: operations["apps/delete-token"]; /** * Reset a token * @description 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`. */ patch: operations["apps/reset-token"]; }; "/applications/{client_id}/token/scoped": { /** * Create a scoped access token * @description Use a non-scoped user access token to create a repository-scoped and/or permission-scoped user access token. You can specify * which repositories the token can access and which permissions are granted to the * token. * * Invalid tokens will return `404 NOT FOUND`. */ post: operations["apps/scope-token"]; }; "/apps/{app_slug}": { /** * Get an app * @description > [!NOTE] * > The `:app_slug` is just the URL-friendly name of your GitHub App. You can find this on the settings page for your GitHub App (e.g., `https://github.com/settings/apps/:app_slug`). */ get: operations["apps/get-by-slug"]; }; "/assignments/{assignment_id}": { /** * Get an assignment * @description Gets a GitHub Classroom assignment. Assignment will only be returned if the current user is an administrator of the GitHub Classroom for the assignment. */ get: operations["classroom/get-an-assignment"]; }; "/assignments/{assignment_id}/accepted_assignments": { /** * List accepted assignments for an assignment * @description Lists any assignment repositories that have been created by students accepting a GitHub Classroom assignment. Accepted assignments will only be returned if the current user is an administrator of the GitHub Classroom for the assignment. */ get: operations["classroom/list-accepted-assignments-for-an-assignment"]; }; "/assignments/{assignment_id}/grades": { /** * Get assignment grades * @description Gets grades for a GitHub Classroom assignment. Grades will only be returned if the current user is an administrator of the GitHub Classroom for the assignment. */ get: operations["classroom/get-assignment-grades"]; }; "/classrooms": { /** * List classrooms * @description Lists GitHub Classroom classrooms for the current user. Classrooms will only be returned if the current user is an administrator of one or more GitHub Classrooms. */ get: operations["classroom/list-classrooms"]; }; "/classrooms/{classroom_id}": { /** * Get a classroom * @description Gets a GitHub Classroom classroom for the current user. Classroom will only be returned if the current user is an administrator of the GitHub Classroom. */ get: operations["classroom/get-a-classroom"]; }; "/classrooms/{classroom_id}/assignments": { /** * List assignments for a classroom * @description Lists GitHub Classroom assignments for a classroom. Assignments will only be returned if the current user is an administrator of the GitHub Classroom. */ get: operations["classroom/list-assignments-for-a-classroom"]; }; "/codes_of_conduct": { /** * Get all codes of conduct * @description Returns array of all GitHub's codes of conduct. */ get: operations["codes-of-conduct/get-all-codes-of-conduct"]; }; "/codes_of_conduct/{key}": { /** * Get a code of conduct * @description Returns information about the specified GitHub code of conduct. */ get: operations["codes-of-conduct/get-conduct-code"]; }; "/credentials/revoke": { /** * Revoke a list of credentials * @description Submit a list of credentials to be revoked. This endpoint is intended to revoke credentials the caller does not own and may have found exposed on GitHub.com or elsewhere. It can also be used for credentials associated with an old user account that you no longer have access to. Credential owners will be notified of the revocation. * * This endpoint currently accepts the following credential types: * - Personal access tokens (classic) * - Fine-grained personal access tokens * * Revoked credentials may impact users on GitHub Free, Pro, & Team and GitHub Enterprise Cloud, and GitHub Enterprise Cloud with Enterprise Managed Users. * GitHub cannot reactivate any credentials that have been revoked; new credentials will need to be generated. * * To prevent abuse, this API is limited to only 60 unauthenticated requests per hour and a max of 1000 tokens per API request. * * > [!NOTE] * > Any authenticated requests will return a 403. */ post: operations["credentials/revoke"]; }; "/emojis": { /** * Get emojis * @description Lists all the emojis available to use on GitHub Enterprise Cloud. */ get: operations["emojis/get"]; }; "/enterprise-installation/{enterprise_or_org}/server-statistics": { /** * Get GitHub Enterprise Server statistics * @description Returns aggregate usage metrics for your GitHub Enterprise Server 3.5+ instance for a specified time period up to 365 days. * * To use this endpoint, your GitHub Enterprise Server instance must be connected to GitHub Enterprise Cloud using GitHub Connect. You must enable Server Statistics, and for the API request provide your enterprise account name or organization name connected to the GitHub Enterprise Server. For more information, see "[Enabling Server Statistics for your enterprise](/admin/configuration/configuring-github-connect/enabling-server-statistics-for-your-enterprise)" in the GitHub Enterprise Server documentation. * * OAuth app tokens and personal access tokens (classic) need: * - the `read:enterprise` scope if you connected your GitHub Enterprise Server to an enterprise account and enabled Server Statistics * - the `read:org` scope if you connected your GitHub Enterprise Server to an organization account and enabled Server Statistics */ get: operations["enterprise-admin/get-server-statistics"]; }; "/enterprises/{enterprise}/access-restrictions/disable": { /** * Disable access restrictions for an enterprise * @description Disable access restriction by proxy header using the network proxy owned by the enterprise. */ post: operations["enterprise-admin/disable-access-restrictions"]; }; "/enterprises/{enterprise}/access-restrictions/enable": { /** * Enable access restrictions for an enterprise * @description Enable access restriction by proxy header using the network proxy owned by the enterprise. */ post: operations["enterprise-admin/enable-access-restrictions"]; }; "/enterprises/{enterprise}/actions/cache/usage": { /** * Get GitHub Actions cache usage for an enterprise * @description Gets the total GitHub Actions cache usage for an enterprise. * The data fetched using this API is refreshed approximately every 5 minutes, so values returned from this endpoint may take at least 5 minutes to get updated. * * OAuth tokens and personal access tokens (classic) need the `admin:enterprise` scope to use this endpoint. */ get: operations["actions/get-actions-cache-usage-for-enterprise"]; }; "/enterprises/{enterprise}/actions/hosted-runners": { /** * List GitHub-hosted runners for an enterprise * @description Lists all GitHub-hosted runners configured in an enterprise. * * OAuth app tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ get: operations["actions/list-hosted-runners-for-enterprise"]; /** * Create a GitHub-hosted runner for an enterprise * @description Creates a GitHub-hosted runner for an enterprise. * OAuth tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ post: operations["actions/create-hosted-runner-for-enterprise"]; }; "/enterprises/{enterprise}/actions/hosted-runners/images/custom": { /** * List custom images for an enterprise * @description List custom images for an enterprise. * * OAuth tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ get: operations["actions/list-custom-images-for-enterprise"]; }; "/enterprises/{enterprise}/actions/hosted-runners/images/custom/{image_definition_id}": { /** * Get an enterprise custom image definition for GitHub Actions Hosted Runners * @description Get an enterprise custom image definition for GitHub Actions Hosted Runners. * * OAuth tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ get: operations["actions/get-custom-image-for-enterprise"]; /** * Delete a custom image from the enterprise * @description Delete a custom image from the enterprise. * * OAuth tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ delete: operations["actions/delete-custom-image-from-enterprise"]; }; "/enterprises/{enterprise}/actions/hosted-runners/images/custom/{image_definition_id}/versions": { /** * List image versions of a custom image for an enterprise * @description List image versions of a custom image for an enterprise. * * OAuth tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ get: operations["actions/list-custom-image-versions-for-enterprise"]; }; "/enterprises/{enterprise}/actions/hosted-runners/images/custom/{image_definition_id}/versions/{version}": { /** * Get an image version of an enterprise custom image for GitHub Actions Hosted Runners * @description Get an image version of an enterprise custom image for GitHub Actions Hosted Runners. * * OAuth tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ get: operations["actions/get-custom-image-version-for-enterprise"]; /** * Delete an image version of custom image from the enterprise * @description Delete an image version of custom image from the enterprise. * * OAuth tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ delete: operations["actions/delete-custom-image-version-from-enterprise"]; }; "/enterprises/{enterprise}/actions/hosted-runners/images/github-owned": { /** * Get GitHub-owned images for GitHub-hosted runners in an enterprise * @description Get the list of GitHub-owned images available for GitHub-hosted runners for an enterprise. */ get: operations["actions/get-hosted-runners-github-owned-images-for-enterprise"]; }; "/enterprises/{enterprise}/actions/hosted-runners/images/partner": { /** * Get partner images for GitHub-hosted runners in an enterprise * @description Get the list of partner images available for GitHub-hosted runners for an enterprise. */ get: operations["actions/get-hosted-runners-partner-images-for-enterprise"]; }; "/enterprises/{enterprise}/actions/hosted-runners/limits": { /** * Get limits on GitHub-hosted runners for an enterprise * @description Get the GitHub-hosted runners limits for an enterprise. */ get: operations["actions/get-hosted-runners-limits-for-enterprise"]; }; "/enterprises/{enterprise}/actions/hosted-runners/machine-sizes": { /** * Get GitHub-hosted runners machine specs for an enterprise * @description Get the list of machine specs available for GitHub-hosted runners for an enterprise. */ get: operations["actions/get-hosted-runners-machine-specs-for-enterprise"]; }; "/enterprises/{enterprise}/actions/hosted-runners/platforms": { /** * Get platforms for GitHub-hosted runners in an enterprise * @description Get the list of platforms available for GitHub-hosted runners for an enterprise. */ get: operations["actions/get-hosted-runners-platforms-for-enterprise"]; }; "/enterprises/{enterprise}/actions/hosted-runners/{hosted_runner_id}": { /** * Get a GitHub-hosted runner for an enterprise * @description Gets a GitHub-hosted runner configured in an enterprise. * * OAuth app tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ get: operations["actions/get-hosted-runner-for-enterprise"]; /** * Delete a GitHub-hosted runner for an enterprise * @description Deletes a GitHub-hosted runner for an enterprise. */ delete: operations["actions/delete-hosted-runner-for-enterprise"]; /** * Update a GitHub-hosted runner for an enterprise * @description Updates a GitHub-hosted runner for an enterprise. * OAuth app tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ patch: operations["actions/update-hosted-runner-for-enterprise"]; }; "/enterprises/{enterprise}/actions/oidc/customization/issuer": { /** * Set the GitHub Actions OIDC custom issuer policy for an enterprise * @description Sets the GitHub Actions OpenID Connect (OIDC) custom issuer policy for an enterprise. * * OAuth app tokens and personal access tokens (classic) need the `admin:enterprise` scope to use this endpoint. */ put: operations["actions/set-actions-oidc-custom-issuer-policy-for-enterprise"]; }; "/enterprises/{enterprise}/actions/permissions": { /** * Get GitHub Actions permissions for an enterprise * @description Gets the GitHub Actions permissions policy for organizations and allowed actions and reusable workflows in an enterprise. * * OAuth app tokens and personal access tokens (classic) need the `admin:enterprise` scope to use this endpoint. */ get: operations["enterprise-admin/get-github-actions-permissions-enterprise"]; /** * Set GitHub Actions permissions for an enterprise * @description Sets the GitHub Actions permissions policy for organizations and allowed actions and reusable workflows in an enterprise. * * OAuth app tokens and personal access tokens (classic) need the `admin:enterprise` scope to use this endpoint. */ put: operations["enterprise-admin/set-github-actions-permissions-enterprise"]; }; "/enterprises/{enterprise}/actions/permissions/artifact-and-log-retention": { /** * Get artifact and log retention settings for an enterprise * @description Gets artifact and log retention settings for an enterprise. */ get: operations["enterprise-admin/get-artifact-and-log-retention-settings"]; /** * Set artifact and log retention settings for an enterprise * @description Sets artifact and log retention settings for an enterprise. */ put: operations["enterprise-admin/set-artifact-and-log-retention-settings"]; }; "/enterprises/{enterprise}/actions/permissions/fork-pr-contributor-approval": { /** * Get fork PR contributor approval permissions for an enterprise * @description Gets the fork PR contributor approval policy for an enterprise. */ get: operations["enterprise-admin/get-fork-pr-contributor-approval-permissions"]; /** * Set fork PR contributor approval permissions for an enterprise * @description Sets the fork PR contributor approval policy for an enterprise. */ put: operations["enterprise-admin/set-fork-pr-contributor-approval-permissions"]; }; "/enterprises/{enterprise}/actions/permissions/fork-pr-workflows-private-repos": { /** * Get private repo fork PR workflow settings for an enterprise * @description Gets the settings for whether workflows from fork pull requests can run on private repositories in an enterprise. */ get: operations["enterprise-admin/get-private-repo-fork-pr-workflows-settings"]; /** * Set private repo fork PR workflow settings for an enterprise * @description Sets the settings for whether workflows from fork pull requests can run on private repositories in an enterprise. */ put: operations["enterprise-admin/set-private-repo-fork-pr-workflows-settings"]; }; "/enterprises/{enterprise}/actions/permissions/organizations": { /** * List selected organizations enabled for GitHub Actions in an enterprise * @description Lists the organizations that are selected to have GitHub Actions enabled in an enterprise. To use this endpoint, the enterprise permission policy for `enabled_organizations` must be configured to `selected`. For more information, see "[Set GitHub Actions permissions for an enterprise](#set-github-actions-permissions-for-an-enterprise)." * * OAuth app tokens and personal access tokens (classic) need the `admin:enterprise` scope to use this endpoint. */ get: operations["enterprise-admin/list-selected-organizations-enabled-github-actions-enterprise"]; /** * Set selected organizations enabled for GitHub Actions in an enterprise * @description Replaces the list of selected organizations that are enabled for GitHub Actions in an enterprise. To use this endpoint, the enterprise permission policy for `enabled_organizations` must be configured to `selected`. For more information, see "[Set GitHub Actions permissions for an enterprise](#set-github-actions-permissions-for-an-enterprise)." * * OAuth app tokens and personal access tokens (classic) need the `admin:enterprise` scope to use this endpoint. */ put: operations["enterprise-admin/set-selected-organizations-enabled-github-actions-enterprise"]; }; "/enterprises/{enterprise}/actions/permissions/organizations/{org_id}": { /** * Enable a selected organization for GitHub Actions in an enterprise * @description Adds an organization to the list of selected organizations that are enabled for GitHub Actions in an enterprise. To use this endpoint, the enterprise permission policy for `enabled_organizations` must be configured to `selected`. For more information, see "[Set GitHub Actions permissions for an enterprise](#set-github-actions-permissions-for-an-enterprise)." * * OAuth app tokens and personal access tokens (classic) need the `admin:enterprise` scope to use this endpoint. */ put: operations["enterprise-admin/enable-selected-organization-github-actions-enterprise"]; /** * Disable a selected organization for GitHub Actions in an enterprise * @description Removes an organization from the list of selected organizations that are enabled for GitHub Actions in an enterprise. To use this endpoint, the enterprise permission policy for `enabled_organizations` must be configured to `selected`. For more information, see "[Set GitHub Actions permissions for an enterprise](#set-github-actions-permissions-for-an-enterprise)." * * OAuth app tokens and personal access tokens (classic) need the `admin:enterprise` scope to use this endpoint. */ delete: operations["enterprise-admin/disable-selected-organization-github-actions-enterprise"]; }; "/enterprises/{enterprise}/actions/permissions/selected-actions": { /** * Get allowed actions and reusable workflows for an enterprise * @description Gets the selected actions and reusable workflows that are allowed in an enterprise. To use this endpoint, the enterprise permission policy for `allowed_actions` must be configured to `selected`. For more information, see "[Set GitHub Actions permissions for an enterprise](#set-github-actions-permissions-for-an-enterprise)." * * OAuth app tokens and personal access tokens (classic) need the `admin:enterprise` scope to use this endpoint. */ get: operations["enterprise-admin/get-allowed-actions-enterprise"]; /** * Set allowed actions and reusable workflows for an enterprise * @description Sets the actions and reusable workflows that are allowed in an enterprise. To use this endpoint, the enterprise permission policy for `allowed_actions` must be configured to `selected`. For more information, see "[Set GitHub Actions permissions for an enterprise](#set-github-actions-permissions-for-an-enterprise)." * * OAuth app tokens and personal access tokens (classic) need the `admin:enterprise` scope to use this endpoint. */ put: operations["enterprise-admin/set-allowed-actions-enterprise"]; }; "/enterprises/{enterprise}/actions/permissions/self-hosted-runners": { /** * Get self-hosted runners permissions for an enterprise * @description Gets the settings for whether organizations in the enterprise are allowed to manage self-hosted runners at the repository level. */ get: operations["enterprise-admin/get-self-hosted-runners-permissions"]; /** * Set self-hosted runners permissions for an enterprise * @description Sets the settings for whether organizations in the enterprise are allowed to manage self-hosted runners at the repository level. */ put: operations["enterprise-admin/set-self-hosted-runners-permissions"]; }; "/enterprises/{enterprise}/actions/permissions/workflow": { /** * Get default workflow permissions for an enterprise * @description Gets the default workflow permissions granted to the `GITHUB_TOKEN` when running workflows in an enterprise, * as well as whether GitHub Actions can submit approving pull request reviews. For more information, see * "[Enforcing a policy for workflow permissions in your enterprise](https://docs.github.com/enterprise-cloud@latest//admin/policies/enforcing-policies-for-your-enterprise/enforcing-policies-for-github-actions-in-your-enterprise#enforcing-a-policy-for-workflow-permissions-in-your-enterprise)." * * OAuth tokens and personal access tokens (classic) need the `admin:enterprise` scope to use this endpoint. */ get: operations["actions/get-github-actions-default-workflow-permissions-enterprise"]; /** * Set default workflow permissions for an enterprise * @description Sets the default workflow permissions granted to the `GITHUB_TOKEN` when running workflows in an enterprise, and sets * whether GitHub Actions can submit approving pull request reviews. For more information, see * "[Enforcing a policy for workflow permissions in your enterprise](https://docs.github.com/enterprise-cloud@latest//admin/policies/enforcing-policies-for-your-enterprise/enforcing-policies-for-github-actions-in-your-enterprise#enforcing-a-policy-for-workflow-permissions-in-your-enterprise)." * * OAuth app tokens and personal access tokens (classic) need the `admin:enterprise` scope to use this endpoint. */ put: operations["actions/set-github-actions-default-workflow-permissions-enterprise"]; }; "/enterprises/{enterprise}/actions/runner-groups": { /** * List self-hosted runner groups for an enterprise * @description Lists all self-hosted runner groups for an enterprise. * * OAuth app tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ get: operations["enterprise-admin/list-self-hosted-runner-groups-for-enterprise"]; /** * Create a self-hosted runner group for an enterprise * @description Creates a new self-hosted runner group for an enterprise. * * OAuth app tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ post: operations["enterprise-admin/create-self-hosted-runner-group-for-enterprise"]; }; "/enterprises/{enterprise}/actions/runner-groups/{runner_group_id}": { /** * Get a self-hosted runner group for an enterprise * @description Gets a specific self-hosted runner group for an enterprise. * * OAuth app tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ get: operations["enterprise-admin/get-self-hosted-runner-group-for-enterprise"]; /** * Delete a self-hosted runner group from an enterprise * @description Deletes a self-hosted runner group for an enterprise. * * OAuth app tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ delete: operations["enterprise-admin/delete-self-hosted-runner-group-from-enterprise"]; /** * Update a self-hosted runner group for an enterprise * @description Updates the `name` and `visibility` of a self-hosted runner group in an enterprise. * * OAuth app tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ patch: operations["enterprise-admin/update-self-hosted-runner-group-for-enterprise"]; }; "/enterprises/{enterprise}/actions/runner-groups/{runner_group_id}/organizations": { /** * List organization access to a self-hosted runner group in an enterprise * @description Lists the organizations with access to a self-hosted runner group. * * OAuth app tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ get: operations["enterprise-admin/list-org-access-to-self-hosted-runner-group-in-enterprise"]; /** * Set organization access for a self-hosted runner group in an enterprise * @description Replaces the list of organizations that have access to a self-hosted runner configured in an enterprise. * * OAuth app tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ put: operations["enterprise-admin/set-org-access-to-self-hosted-runner-group-in-enterprise"]; }; "/enterprises/{enterprise}/actions/runner-groups/{runner_group_id}/organizations/{org_id}": { /** * Add organization access to a self-hosted runner group in an enterprise * @description Adds an organization to the list of selected organizations that can access a self-hosted runner group. The runner group must have `visibility` set to `selected`. For more information, see "[Create a self-hosted runner group for an enterprise](#create-a-self-hosted-runner-group-for-an-enterprise)." * * OAuth app tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ put: operations["enterprise-admin/add-org-access-to-self-hosted-runner-group-in-enterprise"]; /** * Remove organization access to a self-hosted runner group in an enterprise * @description Removes an organization from the list of selected organizations that can access a self-hosted runner group. The runner group must have `visibility` set to `selected`. For more information, see "[Create a self-hosted runner group for an enterprise](#create-a-self-hosted-runner-group-for-an-enterprise)." * * OAuth app tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ delete: operations["enterprise-admin/remove-org-access-to-self-hosted-runner-group-in-enterprise"]; }; "/enterprises/{enterprise}/actions/runner-groups/{runner_group_id}/runners": { /** * List self-hosted runners in a group for an enterprise * @description Lists the self-hosted runners that are in a specific enterprise group. * * OAuth app tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ get: operations["enterprise-admin/list-self-hosted-runners-in-group-for-enterprise"]; /** * Set self-hosted runners in a group for an enterprise * @description Replaces the list of self-hosted runners that are part of an enterprise runner group. * * OAuth app tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ put: operations["enterprise-admin/set-self-hosted-runners-in-group-for-enterprise"]; }; "/enterprises/{enterprise}/actions/runner-groups/{runner_group_id}/runners/{runner_id}": { /** * Add a self-hosted runner to a group for an enterprise * @description Adds a self-hosted runner to a runner group configured in an enterprise. * * OAuth app tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ put: operations["enterprise-admin/add-self-hosted-runner-to-group-for-enterprise"]; /** * Remove a self-hosted runner from a group for an enterprise * @description Removes a self-hosted runner from a group configured in an enterprise. The runner is then returned to the default group. * * OAuth app tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ delete: operations["enterprise-admin/remove-self-hosted-runner-from-group-for-enterprise"]; }; "/enterprises/{enterprise}/actions/runners": { /** * List self-hosted runners for an enterprise * @description Lists all self-hosted runners configured for an enterprise. * * OAuth app tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ get: operations["enterprise-admin/list-self-hosted-runners-for-enterprise"]; }; "/enterprises/{enterprise}/actions/runners/downloads": { /** * List runner applications for an enterprise * @description Lists binaries for the runner application that you can download and run. * * OAuth app tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ get: operations["enterprise-admin/list-runner-applications-for-enterprise"]; }; "/enterprises/{enterprise}/actions/runners/generate-jitconfig": { /** * Create configuration for a just-in-time runner for an Enterprise * @description Generates a configuration that can be passed to the runner application at startup. * * OAuth tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ post: operations["actions/generate-runner-jitconfig-for-enterprise"]; }; "/enterprises/{enterprise}/actions/runners/registration-token": { /** * Create a registration token for an enterprise * @description Returns a token that you can pass to the `config` script. The token expires after one hour. * * Example using registration token: * * Configure your self-hosted runner, replacing `TOKEN` with the registration token provided by this endpoint. * * ``` * ./config.sh --url https://github.com/enterprises/octo-enterprise --token TOKEN * ``` * * OAuth app tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ post: operations["enterprise-admin/create-registration-token-for-enterprise"]; }; "/enterprises/{enterprise}/actions/runners/remove-token": { /** * Create a remove token for an enterprise * @description Returns a token that you can pass to the `config` script to remove a self-hosted runner from an enterprise. The token expires after one hour. * * Example using remove token: * * To remove your self-hosted runner from an enterprise, replace `TOKEN` with the remove token provided by this * endpoint. * * ``` * ./config.sh remove --token TOKEN * ``` * * OAuth app tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ post: operations["enterprise-admin/create-remove-token-for-enterprise"]; }; "/enterprises/{enterprise}/actions/runners/{runner_id}": { /** * Get a self-hosted runner for an enterprise * @description Gets a specific self-hosted runner configured in an enterprise. * * OAuth app tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ get: operations["enterprise-admin/get-self-hosted-runner-for-enterprise"]; /** * Delete a self-hosted runner from an enterprise * @description Forces the removal of a self-hosted runner from an enterprise. You can use this endpoint to completely remove the runner when the machine you were using no longer exists. * * OAuth app tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ delete: operations["enterprise-admin/delete-self-hosted-runner-from-enterprise"]; }; "/enterprises/{enterprise}/actions/runners/{runner_id}/labels": { /** * List labels for a self-hosted runner for an enterprise * @description Lists all labels for a self-hosted runner configured in an enterprise. * * OAuth app tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ get: operations["enterprise-admin/list-labels-for-self-hosted-runner-for-enterprise"]; /** * Set custom labels for a self-hosted runner for an enterprise * @description Remove all previous custom labels and set the new custom labels for a specific * self-hosted runner configured in an enterprise. * * OAuth app tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ put: operations["enterprise-admin/set-custom-labels-for-self-hosted-runner-for-enterprise"]; /** * Add custom labels to a self-hosted runner for an enterprise * @description Add custom labels to a self-hosted runner configured in an enterprise. * * OAuth app tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ post: operations["enterprise-admin/add-custom-labels-to-self-hosted-runner-for-enterprise"]; /** * Remove all custom labels from a self-hosted runner for an enterprise * @description Remove all custom labels from a self-hosted runner configured in an * enterprise. Returns the remaining read-only labels from the runner. * * OAuth app tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ delete: operations["enterprise-admin/remove-all-custom-labels-from-self-hosted-runner-for-enterprise"]; }; "/enterprises/{enterprise}/actions/runners/{runner_id}/labels/{name}": { /** * Remove a custom label from a self-hosted runner for an enterprise * @description Remove a custom label from a self-hosted runner configured * in an enterprise. Returns the remaining labels from the runner. * * This endpoint returns a `404 Not Found` status if the custom label is not * present on the runner. * * OAuth app tokens and personal access tokens (classic) need the `manage_runners:enterprise` scope to use this endpoint. */ delete: operations["enterprise-admin/remove-custom-label-from-self-hosted-runner-for-enterprise"]; }; "/enterprises/{enterprise}/announcement": { /** * Get announcement banner for enterprise * @description Gets the announcement banner currently set for the enterprise. */ get: operations["announcement-banners/get-announcement-banner-for-enterprise"]; /** * Remove announcement banner from enterprise * @description Removes the announcement banner currently set for the enterprise. */ delete: operations["announcement-banners/remove-announcement-banner-for-enterprise"]; /** * Set announcement banner for enterprise * @description Sets the announcement banner to display for the enterprise. */ patch: operations["announcement-banners/set-announcement-banner-for-enterprise"]; }; "/enterprises/{enterprise}/apps/installable_organizations": { /** * Get enterprise-owned organizations that can have GitHub Apps installed * @description List the organizations owned by the enterprise, intended for use by GitHub Apps that are managing applications across the enterprise. * * This API can only be called by a GitHub App installed on the enterprise that owns the organization. */ get: operations["enterprise-apps/installable-organizations"]; }; "/enterprises/{enterprise}/apps/installable_organizations/{org}/accessible_repositories": { /** * Get repositories belonging to an enterprise-owned organization * @description List the repositories belonging to an enterprise-owned organization that can be made accessible to a GitHub App installed on that organization. This API provides a shallow list of repositories in the organization, allowing the caller to then add or remove those repositories to an installation in that organization. * * This API can only be called by a GitHub App installed on the enterprise that owns the organization. */ get: operations["enterprise-apps/installable-organization-accessible-repositories"]; }; "/enterprises/{enterprise}/apps/organizations/{org}/installations": { /** * List GitHub Apps installed on an enterprise-owned organization * @description Lists the GitHub App installations associated with the given enterprise-owned organization. This lists all GitHub Apps that have been installed on the organization, regardless of who owns the application. * * This API can only be called by a GitHub App installed on the enterprise that owns the organization. */ get: operations["enterprise-apps/organization-installations"]; /**