{ "opencollection": "1.0.0", "info": { "name": "Github Update API", "version": "1.1.4" }, "items": [ { "info": { "name": "Update", "type": "folder" }, "items": [ { "info": { "name": "GitHub Updatewebhook Configuration for an App", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/app/hook/config", "body": { "type": "json", "data": "{}" } }, "docs": "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).\"\n\nYou 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." }, { "info": { "name": "GitHub Update an Existing Authorization", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/authorizations/:authorization_id", "params": [ { "name": "authorization_id", "value": "", "type": "path", "description": "The unique identifier of the authorization." } ], "body": { "type": "json", "data": "{}" } }, "docs": "**Deprecation Notice:** GitHub Enterprise Server will discontinue the [OAuth Authorizations API](https://docs.github.com/enterprise-server@3.9/rest/oauth-authorizations/oauth-authorizations/), which is used by integrations to create personal access tokens and OAuth tokens, and you must now create these tokens using our [web application flow](https://docs.github.com/enterprise-server@3.9/developers/apps/authorizing-oauth-apps#web-application-flow). The [OAuth Authorizations API](https://docs.gith" }, { "info": { "name": "GitHub Updategist", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/gists/:gist_id", "params": [ { "name": "gist_id", "value": "", "type": "path", "description": "The unique identifier of the gist." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Allows you to update a gist's description and to update, delete, or rename gist files. Files\nfrom the previous version of the gist that aren't explicitly changed during an edit\nare unchanged.\n\nAt least one of `description` or `files` is required.\n\nThis endpoint supports the following custom media types. For more information, see \"[Media types](https://docs.github.com/enterprise-server@3.9/rest/using-the-rest-api/getting-started-with-the-rest-api#media-types).\"\n\n- **`application/vnd.github.raw+js" }, { "info": { "name": "GitHub Updategist Comment", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/gists/:gist_id/comments/:comment_id", "params": [ { "name": "gist_id", "value": "", "type": "path", "description": "The unique identifier of the gist." }, { "name": "comment_id", "value": "", "type": "path", "description": "The unique identifier of the comment." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Updates a comment on a gist.\n\nThis endpoint supports the following custom media types. For more information, see \"[Media types](https://docs.github.com/enterprise-server@3.9/rest/using-the-rest-api/getting-started-with-the-rest-api#media-types).\"\n\n- **`application/vnd.github.raw+json`**: Returns the raw markdown. This is the default if you do not pass any specific media type.\n- **`application/vnd.github.base64+json`**: Returns the base64-encoded contents. This can be useful if your gist contains" }, { "info": { "name": "GitHub Update an Organization", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/orgs/:org", "params": [ { "name": "org", "value": "", "type": "path", "description": "The organization name. The name is not case sensitive." } ], "body": { "type": "json", "data": "{}" } }, "docs": "**Parameter Deprecation Notice:** GitHub Enterprise Server will replace and discontinue `members_allowed_repository_creation_type` in favor of more granular permissions. The new input parameters are `members_can_create_public_repositories`, `members_can_create_private_repositories` for all organizations and `members_can_create_internal_repositories` for organizations associated with an enterprise account using GitHub Enterprise Cloud or GitHub Enterprise Server 2.20+. For more information, see t" }, { "info": { "name": "GitHub Update Self-hosted Runner Group for an Organization", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/orgs/:org/actions/runner-groups/:runner_group_id", "params": [ { "name": "org", "value": "", "type": "path", "description": "The organization name. The name is not case sensitive." }, { "name": "runner_group_id", "value": "", "type": "path", "description": "Unique identifier of the self-hosted runner group." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Updates the `name` and `visibility` of a self-hosted runner group in an organization.\n\nOAuth app tokens and personal access tokens (classic) need the `admin:org` scope to use this endpoint." }, { "info": { "name": "GitHub Create or Update an Organization Secret", "type": "http" }, "http": { "method": "PUT", "url": "{protocol}://{hostname}/api/v3/orgs/:org/actions/secrets/:secret_name", "params": [ { "name": "org", "value": "", "type": "path", "description": "The organization name. The name is not case sensitive." }, { "name": "secret_name", "value": "", "type": "path", "description": "The name of the secret." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Creates or updates an organization secret with an encrypted value. Encrypt your secret using\n[LibSodium](https://libsodium.gitbook.io/doc/bindings_for_other_languages). For more information, see \"[Encrypting secrets for the REST API](https://docs.github.com/enterprise-server@3.9/rest/guides/encrypting-secrets-for-the-rest-api).\"\n\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.\n\nOAuth tokens and personal access tokens (classic) need the`admin:" }, { "info": { "name": "GitHub Update an Organization Variable", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/orgs/:org/actions/variables/:name", "params": [ { "name": "org", "value": "", "type": "path", "description": "The organization name. The name is not case sensitive." }, { "name": "name", "value": "", "type": "path", "description": "The name of the variable." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Updates an organization variable that you can reference in a GitHub Actions workflow.\n\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.\n\nOAuth app tokens and personal access tokens (classic) need the `admin:org` scope to use this endpoint. If the repository is private, the `repo` scope is also required." }, { "info": { "name": "GitHub Update Custom Repository Role", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/orgs/:org/custom-repository-roles/:role_id", "params": [ { "name": "org", "value": "", "type": "path", "description": "The organization name. The name is not case sensitive." }, { "name": "role_id", "value": "", "type": "path", "description": "The unique identifier of the role." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Updates a custom repository role that can be used by all repositories owned by the organization. For more information about custom repository roles, see \"[About custom repository roles](https://docs.github.com/enterprise-server@3.9/organizations/managing-peoples-access-to-your-organization-with-roles/about-custom-repository-roles).\"\n\nThe authenticated user must be an administrator for the organization to use this endpoint.\n\nOAuth app tokens and personal access tokens (classic) need the `admin:or" }, { "info": { "name": "GitHub Create or Update an Organization Secret", "type": "http" }, "http": { "method": "PUT", "url": "{protocol}://{hostname}/api/v3/orgs/:org/dependabot/secrets/:secret_name", "params": [ { "name": "org", "value": "", "type": "path", "description": "The organization name. The name is not case sensitive." }, { "name": "secret_name", "value": "", "type": "path", "description": "The name of the secret." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Creates or updates an organization secret with an encrypted value. Encrypt your secret using\n[LibSodium](https://libsodium.gitbook.io/doc/bindings_for_other_languages). For more information, see \"[Encrypting secrets for the REST API](https://docs.github.com/enterprise-server@3.9/rest/guides/encrypting-secrets-for-the-rest-api).\"\n\nOAuth app tokens and personal access tokens (classic) need the `admin:org` scope to use this endpoint." }, { "info": { "name": "GitHub Update an Organization Webhook", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/orgs/:org/hooks/:hook_id", "params": [ { "name": "org", "value": "", "type": "path", "description": "The organization name. The name is not case sensitive." }, { "name": "hook_id", "value": "", "type": "path", "description": "The unique identifier of the hook. You can find this value in the `X-GitHub-Hook-ID` header of a webhook delivery." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Updates a webhook configured in an organization. When you update a webhook, the `secret` will be overwritten. If you previously had a `secret` set, you must provide the same `secret` or set a new `secret` or the secret will be removed. If you are only updating individual webhook `config` properties, use \"[Update a webhook configuration for an organization](/rest/orgs/webhooks#update-a-webhook-configuration-for-an-organization).\"" }, { "info": { "name": "GitHub Update Webhook Configuration for an Organization", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/orgs/:org/hooks/:hook_id/config", "params": [ { "name": "org", "value": "", "type": "path", "description": "The organization name. The name is not case sensitive." }, { "name": "hook_id", "value": "", "type": "path", "description": "The unique identifier of the hook. You can find this value in the `X-GitHub-Hook-ID` header of a webhook delivery." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Updates the webhook configuration for an organization. To update more information about the webhook, including the `active` state and `events`, use \"[Update an organization webhook ](/rest/orgs/webhooks#update-an-organization-webhook).\"\n\nOAuth app tokens and personal access tokens (classic) need the `admin:org_hook` scope to use this endpoint." }, { "info": { "name": "GitHub Update Pre-receive Hook Enforcement for an Organization", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/orgs/:org/pre-receive-hooks/:pre_receive_hook_id", "params": [ { "name": "org", "value": "", "type": "path", "description": "The organization name. The name is not case sensitive." }, { "name": "pre_receive_hook_id", "value": "", "type": "path", "description": "The unique identifier of the pre-receive hook." } ], "body": { "type": "json", "data": "{}" } }, "docs": "For pre-receive hooks which are allowed to be configured at the org level, you can set `enforcement` and `allow_downstream_configuration`" }, { "info": { "name": "GitHub Update Team", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/orgs/:org/teams/:team_slug", "params": [ { "name": "org", "value": "", "type": "path", "description": "The organization name. The name is not case sensitive." }, { "name": "team_slug", "value": "", "type": "path", "description": "The slug of the team name." } ], "body": { "type": "json", "data": "{}" } }, "docs": "To edit a team, the authenticated user must either be an organization owner or a team maintainer.\n\n**Note:** You can also specify a team by `org_id` and `team_id` using the route `PATCH /organizations/{org_id}/team/{team_id}`." }, { "info": { "name": "GitHub Update Discussion", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/orgs/:org/teams/:team_slug/discussions/:discussion_number", "params": [ { "name": "org", "value": "", "type": "path", "description": "The organization name. The name is not case sensitive." }, { "name": "team_slug", "value": "", "type": "path", "description": "The slug of the team name." }, { "name": "discussion_number", "value": "", "type": "path", "description": "The number that identifies the discussion." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Edits the title and body text of a discussion post. Only the parameters you provide are updated.\n\n**Note:** You can also specify a team by `org_id` and `team_id` using the route `PATCH /organizations/{org_id}/team/{team_id}/discussions/{discussion_number}`.\n\nOAuth app tokens and personal access tokens (classic) need the `write:discussion` scope to use this endpoint." }, { "info": { "name": "GitHub Update Discussion Comment", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/orgs/:org/teams/:team_slug/discussions/:discussion_number/comments/:comment_number", "params": [ { "name": "org", "value": "", "type": "path", "description": "The organization name. The name is not case sensitive." }, { "name": "team_slug", "value": "", "type": "path", "description": "The slug of the team name." }, { "name": "discussion_number", "value": "", "type": "path", "description": "The number that identifies the discussion." }, { "name": "comment_number", "value": "", "type": "path", "description": "The number that identifies the comment." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Edits the body text of a discussion comment.\n\n**Note:** You can also specify a team by `org_id` and `team_id` using the route `PATCH /organizations/{org_id}/team/{team_id}/discussions/{discussion_number}/comments/{comment_number}`.\n\nOAuth app tokens and personal access tokens (classic) need the `write:discussion` scope to use this endpoint." }, { "info": { "name": "GitHub Update the Connection Between an External Group and Team", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/orgs/:org/teams/:team_slug/external-groups", "params": [ { "name": "org", "value": "", "type": "path", "description": "The organization name. The name is not case sensitive." }, { "name": "team_slug", "value": "", "type": "path", "description": "The slug of the team name." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Creates a connection between a team and an external group. Only one external group can be linked to a team.\n\nYou can manage team membership with your identity provider using Enterprise Managed Users for GitHub Enterprise Cloud. For more information, see \"[GitHub's products](https://docs.github.com/enterprise-server@3.9/github/getting-started-with-github/githubs-products)\" in the GitHub Help documentation." }, { "info": { "name": "GitHub Add or Update Team Membership for User", "type": "http" }, "http": { "method": "PUT", "url": "{protocol}://{hostname}/api/v3/orgs/:org/teams/:team_slug/memberships/:username", "params": [ { "name": "org", "value": "", "type": "path", "description": "The organization name. The name is not case sensitive." }, { "name": "team_slug", "value": "", "type": "path", "description": "The slug of the team name." }, { "name": "username", "value": "", "type": "path", "description": "The handle for the GitHub user account." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Adds an organization member to a team. An authenticated organization owner or team maintainer can add organization members to a team.\n\nTeam synchronization is available for organizations using GitHub Enterprise Cloud. For more information, see [GitHub's products](https://docs.github.com/enterprise-server@3.9/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\n**Note:** When you have team synchronization set up for a team with your organization's identity provi" }, { "info": { "name": "GitHub Add or Update Team Project Permissions", "type": "http" }, "http": { "method": "PUT", "url": "{protocol}://{hostname}/api/v3/orgs/:org/teams/:team_slug/projects/:project_id", "params": [ { "name": "org", "value": "", "type": "path", "description": "The organization name. The name is not case sensitive." }, { "name": "team_slug", "value": "", "type": "path", "description": "The slug of the team name." }, { "name": "project_id", "value": "", "type": "path", "description": "The unique identifier of the project." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Adds an organization project to a team. To add a project to a team or update the team's permission on a project, the authenticated user must have `admin` permissions for the project. The project and team must be part of the same organization.\n\n**Note:** You can also specify a team by `org_id` and `team_id` using the route `PUT /organizations/{org_id}/team/{team_id}/projects/{project_id}`." }, { "info": { "name": "GitHub Add or Update Team Repository Permissions", "type": "http" }, "http": { "method": "PUT", "url": "{protocol}://{hostname}/api/v3/orgs/:org/teams/:team_slug/repos/:owner/:repo", "params": [ { "name": "org", "value": "", "type": "path", "description": "The organization name. The name is not case sensitive." }, { "name": "team_slug", "value": "", "type": "path", "description": "The slug of the team name." }, { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." } ], "body": { "type": "json", "data": "{}" } }, "docs": "To add a repository to a team or update the team's permission on a repository, the authenticated user must have admin access to the repository, and must be able to see the team. The repository must be owned by the organization, or a direct fork of a repository owned by the organization. You will get a `422 Unprocessable Entity` status if you attempt to add a repository to a team that is not owned by the organization. Note that, if you choose not to pass any parameters, you'll need to set `Conten" }, { "info": { "name": "GitHub Update an Existing Project Card", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/projects/columns/cards/:card_id", "params": [ { "name": "card_id", "value": "", "type": "path", "description": "The unique identifier of the card." } ], "body": { "type": "json", "data": "{}" } }, "docs": "The PATCH operation on the `/projects/columns/cards/{card_id}` endpoint allows you to modify an existing project card within a GitHub project board by providing the card's unique identifier. This API call enables you to update card properties such as the note content or archived status, giving you programmatic control over managing cards in your project workflows. You must authenticate with appropriate permissions to modify cards, and the endpoint returns the updated card object upon successful " }, { "info": { "name": "GitHub Update an Existing Project Column", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/projects/columns/:column_id", "params": [ { "name": "column_id", "value": "", "type": "path", "description": "The unique identifier of the column." } ], "body": { "type": "json", "data": "{}" } }, "docs": "The PATCH operation on the /projects/columns/{column_id} endpoint allows developers to modify the properties of an existing project column within GitHub Projects. By sending a PATCH request with the column's unique identifier, users can update attributes such as the column's name. This endpoint is particularly useful for reorganizing project boards, renaming workflow stages, or adjusting column configurations without needing to delete and recreate columns. The operation requires appropriate auth" }, { "info": { "name": "GitHub Update Project", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/projects/:project_id", "params": [ { "name": "project_id", "value": "", "type": "path", "description": "The unique identifier of the project." } ], "body": { "type": "json", "data": "{}" } }, "docs": "The Update Project operation is a PATCH request to the /projects/{project_id} endpoint that allows you to modify an existing GitHub project's properties. By providing the project's unique identifier in the URL path, you can update various attributes such as the project's name, description (body), state (open or closed), organization permission levels, and privacy settings. This endpoint requires appropriate authentication and permissions to modify the project, and it returns the updated project " }, { "info": { "name": "GitHub Add or Update Team Project Permissions (legacy)", "type": "http" }, "http": { "method": "PUT", "url": "{protocol}://{hostname}/api/v3/teams/:team_id/projects/:project_id", "params": [ { "name": "team_id", "value": "", "type": "path", "description": "The unique identifier of the team." }, { "name": "project_id", "value": "", "type": "path", "description": "The unique identifier of the project." } ], "body": { "type": "json", "data": "{}" } }, "docs": "**Deprecation Notice:** This endpoint route is deprecated and will be removed from the Teams API. We recommend migrating your existing code to use the new [Add or update team project permissions](https://docs.github.com/enterprise-server@3.9/rest/teams/teams#add-or-update-team-project-permissions) endpoint.\n\nAdds an organization project to a team. To add a project to a team or update the team's permission on a project, the authenticated user must have `admin` permissions for the project. The pro" }, { "info": { "name": "GitHub Create or Update Repository Secret", "type": "http" }, "http": { "method": "PUT", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/actions/secrets/:secret_name", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "secret_name", "value": "", "type": "path", "description": "The name of the secret." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Creates or updates a repository secret with an encrypted value. Encrypt your secret using\n[LibSodium](https://libsodium.gitbook.io/doc/bindings_for_other_languages). For more information, see \"[Encrypting secrets for the REST API](https://docs.github.com/enterprise-server@3.9/rest/guides/encrypting-secrets-for-the-rest-api).\"\n\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.\n\nOAuth tokens and personal access tokens (classic) need the `repo` sc" }, { "info": { "name": "GitHub Update Repository Variable", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/actions/variables/:name", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "name", "value": "", "type": "path", "description": "The name of the variable." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Updates a repository variable that you can reference in a GitHub Actions workflow.\n\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.\n\nOAuth app tokens and personal access tokens (classic) need the `repo` scope to use this endpoint." }, { "info": { "name": "GitHub Update Branch Protection", "type": "http" }, "http": { "method": "PUT", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/branches/:branch/protection", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "branch", "value": "", "type": "path", "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-server@3.9/graphql)." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-server@3.9/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nProtecting a branch requires admin or owner permissions to the repository.\n\n**Note**: Pa" }, { "info": { "name": "GitHub Update Pull Request Review Protection", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/branches/:branch/protection/required_pull_request_reviews", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "branch", "value": "", "type": "path", "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-server@3.9/graphql)." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-server@3.9/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nUpdating pull request review enforcement requires admin or owner permissions to the repo" }, { "info": { "name": "GitHub Update Status Check Protection", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/branches/:branch/protection/required_status_checks", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "branch", "value": "", "type": "path", "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-server@3.9/graphql)." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-server@3.9/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nUpdating required status checks requires admin or owner permissions to the repository an" }, { "info": { "name": "GitHub Update Code Scanning Alert", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/code-scanning/alerts/:alert_number", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "alert_number", "value": "", "type": "path", "description": "The number that identifies an alert. You can find this at the end of the URL for a code scanning alert within GitHub, and in the `number` field in the response from the `GET /repos/{owner}/{repo}/code-scanning/alerts` operation." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Updates the status of a single code scanning alert.\nOAuth app tokens and personal access tokens (classic) need the `security_events` scope to use this endpoint with private or public repositories, or the `public_repo` scope to use this endpoint with only public repositories." }, { "info": { "name": "GitHub Update Code Scanning Default Setup Configuration", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/code-scanning/default-setup", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Updates a code scanning default setup configuration.\n\nOAuth app tokens and personal access tokens (classic) need the `repo` scope to use this endpoint with private or public repositories, or the `public_repo` scope to use this endpoint with only public repositories." }, { "info": { "name": "GitHub Update Dependabot Alert", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/dependabot/alerts/:alert_number", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "alert_number", "value": "", "type": "path", "description": "The number that identifies a Dependabot alert in its repository.\nYou can find this at the end of the URL for a Dependabot alert within GitHub,\nor in `number` fields in the response from the\n`GET /repos/{owner}/{repo}/dependabot/alerts` operation." } ], "body": { "type": "json", "data": "{}" } }, "docs": "The authenticated user must have access to security alerts for the repository to use this endpoint. For more information, see \"[Granting access to security alerts](https://docs.github.com/enterprise-server@3.9/repositories/managing-your-repositorys-settings-and-features/enabling-features-for-your-repository/managing-security-and-analysis-settings-for-your-repository#granting-access-to-security-alerts).\"\n\nOAuth app tokens and personal access tokens (classic) need the `security_events` scope to us" }, { "info": { "name": "GitHub Create or Update Repository Secret", "type": "http" }, "http": { "method": "PUT", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/dependabot/secrets/:secret_name", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "secret_name", "value": "", "type": "path", "description": "The name of the secret." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Creates or updates a repository secret with an encrypted value. Encrypt your secret using\n[LibSodium](https://libsodium.gitbook.io/doc/bindings_for_other_languages). For more information, see \"[Encrypting secrets for the REST API](https://docs.github.com/enterprise-server@3.9/rest/guides/encrypting-secrets-for-the-rest-api).\"\n\nOAuth app tokens and personal access tokens (classic) need the `repo` scope to use this endpoint." }, { "info": { "name": "GitHub Update Repository Webhook", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/hooks/:hook_id", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "hook_id", "value": "", "type": "path", "description": "The unique identifier of the hook. You can find this value in the `X-GitHub-Hook-ID` header of a webhook delivery." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Updates a webhook configured in a repository. If you previously had a `secret` set, you must provide the same `secret` or set a new `secret` or the secret will be removed. If you are only updating individual webhook `config` properties, use \"[Update a webhook configuration for a repository](/rest/webhooks/repo-config#update-a-webhook-configuration-for-a-repository).\"" }, { "info": { "name": "GitHub Update Webhook Configuration for Repository", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/hooks/:hook_id/config", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "hook_id", "value": "", "type": "path", "description": "The unique identifier of the hook. You can find this value in the `X-GitHub-Hook-ID` header of a webhook delivery." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Updates the webhook configuration for a repository. To update more information about the webhook, including the `active` state and `events`, use \"[Update a repository webhook](/rest/webhooks/repos#update-a-repository-webhook).\"\n\nOAuth app tokens and personal access tokens (classic) need the `write:repo_hook` or `repo` scope to use this endpoint." }, { "info": { "name": "GitHub Update Pre-receive Hook Enforcement for Repository", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/pre-receive-hooks/:pre_receive_hook_id", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "pre_receive_hook_id", "value": "", "type": "path", "description": "The unique identifier of the pre-receive hook." } ], "body": { "type": "json", "data": "{}" } }, "docs": "For pre-receive hooks which are allowed to be configured at the repo level, you can set `enforcement`" }, { "info": { "name": "GitHub Update Repository Invitation", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/invitations/:invitation_id", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "invitation_id", "value": "", "type": "path", "description": "The unique identifier of the invitation." } ], "body": { "type": "json", "data": "{}" } }, "docs": "This API endpoint allows you to update an existing repository invitation by modifying its permissions level. You must authenticate as a repository owner or administrator and provide the invitation ID in the URL path. The PATCH request accepts a JSON body with a 'permissions' field that can be set to 'read', 'write', 'maintain', 'triage', or 'admin' to change the access level being offered to the invited user. Upon successful execution, it returns the updated invitation object containing details " }, { "info": { "name": "GitHub Update an Issue Comment", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/issues/comments/:comment_id", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "comment_id", "value": "", "type": "path", "description": "The unique identifier of the comment." } ], "body": { "type": "json", "data": "{}" } }, "docs": "You can use the REST API to update comments on issues and pull requests. Every pull request is an issue, but not every issue is a pull request.\n\nThis endpoint supports the following custom media types. For more information, see \"[Media types](https://docs.github.com/enterprise-server@3.9/rest/using-the-rest-api/getting-started-with-the-rest-api#media-types).\"\n\n- **`application/vnd.github.raw+json`**: Returns the raw markdown body. Response will include `body`. This is the default if you do not p" }, { "info": { "name": "GitHub Update an Issue", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/issues/:issue_number", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "issue_number", "value": "", "type": "path", "description": "The number that identifies the issue." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Issue owners and users with push access can edit an issue.\n\nThis endpoint supports the following custom media types. For more information, see \"[Media types](https://docs.github.com/enterprise-server@3.9/rest/using-the-rest-api/getting-started-with-the-rest-api#media-types).\"\n\n- **`application/vnd.github.raw+json`**: Returns the raw markdown body. Response will include `body`. This is the default if you do not pass any specific media type.\n- **`application/vnd.github.text+json`**: Returns a text" }, { "info": { "name": "GitHub Update Review Comment for Pull Request", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/pulls/comments/:comment_id", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "comment_id", "value": "", "type": "path", "description": "The unique identifier of the comment." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Edits the content of a specified review comment.\n\nThis endpoint supports the following custom media types. For more information, see \"[Media types](https://docs.github.com/enterprise-server@3.9/rest/using-the-rest-api/getting-started-with-the-rest-api#media-types).\"\n\n- **`application/vnd.github-commitcomment.raw+json`**: Returns the raw markdown body. Response will include `body`. This is the default if you do not pass any specific media type.\n- **`application/vnd.github-commitcomment.text+json`" }, { "info": { "name": "GitHub Update Pull Request", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/pulls/:pull_number", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "pull_number", "value": "", "type": "path", "description": "The number that identifies the pull request." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Draft pull requests are available in public repositories with GitHub Free and GitHub Free for organizations, GitHub Pro, and legacy per-repository billing plans, and in public and private repositories with GitHub Team and GitHub Enterprise Cloud. For more information, see [GitHub's products](https://docs.github.com/enterprise-server@3.9/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nTo open or update a pull request in a public repository, you must have wr" }, { "info": { "name": "GitHub Update Review for Pull Request", "type": "http" }, "http": { "method": "PUT", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/pulls/:pull_number/reviews/:review_id", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "pull_number", "value": "", "type": "path", "description": "The number that identifies the pull request." }, { "name": "review_id", "value": "", "type": "path", "description": "The unique identifier of the review." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Updates the contents of a specified review summary comment.\n\nThis endpoint supports the following custom media types. For more information, see \"[Media types](https://docs.github.com/enterprise-server@3.9/rest/using-the-rest-api/getting-started-with-the-rest-api#media-types).\"\n\n- **`application/vnd.github-commitcomment.raw+json`**: Returns the raw markdown body. Response will include `body`. This is the default if you do not pass any specific media type.\n- **`application/vnd.github-commitcomment" }, { "info": { "name": "GitHub Update Pull Request Branch", "type": "http" }, "http": { "method": "PUT", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/pulls/:pull_number/update-branch", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "pull_number", "value": "", "type": "path", "description": "The number that identifies the pull request." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Updates the pull request branch with the latest upstream changes by merging HEAD from the base branch into the pull request branch." }, { "info": { "name": "GitHub Update Repository", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." } ], "body": { "type": "json", "data": "{}" } }, "docs": "**Note**: To edit a repository's topics, use the [Replace all repository topics](https://docs.github.com/enterprise-server@3.9/rest/repos/repos#replace-all-repository-topics) endpoint." }, { "info": { "name": "GitHub Update Check Run", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/check-runs/:check_run_id", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "check_run_id", "value": "", "type": "path", "description": "The unique identifier of the check run." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Updates a check run for a specific commit in a repository.\n\n**Note:** The endpoints to manage checks only look for pushes in the repository where the check suite or check run were created. Pushes to a branch in a forked repository are not detected and return an empty `pull_requests` array.\n\nOAuth apps and personal access tokens (classic) cannot use this endpoint." }, { "info": { "name": "GitHub Update Repository Preferences for Check Suites", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/check-suites/preferences", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Changes the default automatic flow when creating check suites. By default, a check suite is automatically created each time code is pushed to a repository. When you disable the automatic creation of check suites, you can manually [Create a check suite](https://docs.github.com/enterprise-server@3.9/rest/checks/suites#create-a-check-suite).\nYou must have admin permissions in the repository to set preferences for check suites." }, { "info": { "name": "GitHub Update Commit Comment", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/comments/:comment_id", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "comment_id", "value": "", "type": "path", "description": "The unique identifier of the comment." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Updates the contents of a specified commit comment.\n\nThis endpoint supports the following custom media types. For more information, see \"[Media types](https://docs.github.com/enterprise-server@3.9/rest/using-the-rest-api/getting-started-with-the-rest-api#media-types).\"\n\n- **`application/vnd.github-commitcomment.raw+json`**: Returns the raw markdown body. Response will include `body`. This is the default if you do not pass any specific media type.\n- **`application/vnd.github-commitcomment.text+js" }, { "info": { "name": "GitHub Create or Update File Contents", "type": "http" }, "http": { "method": "PUT", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/contents/:path", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "path", "value": "src/index.js", "type": "path", "description": "path parameter" } ], "body": { "type": "json", "data": "{}" } }, "docs": "Creates a new file or replaces an existing file in a repository.\n\n**Note:** If you use this endpoint and the \"[Delete a file](https://docs.github.com/enterprise-server@3.9/rest/repos/contents/#delete-a-file)\" endpoint in parallel, the concurrent requests will conflict and you will receive errors. You must use these endpoints serially instead.\n\nOAuth app tokens and personal access tokens (classic) need the `repo` scope to use this endpoint. The `workflow` scope is also required in order to modify" }, { "info": { "name": "GitHub Create or Update an Environment", "type": "http" }, "http": { "method": "PUT", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/environments/:environment_name", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "environment_name", "value": "", "type": "path", "description": "The name of the environment. The name must be URL encoded. For example, any slashes in the name must be replaced with `%2F`." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Create or update an environment with protection rules, such as required reviewers. For more information about environment protection rules, see \"[Environments](/actions/reference/environments#environment-protection-rules).\"\n\n**Note:** To create or update name patterns that branches must match in order to deploy to this environment, see \"[Deployment branch policies](/rest/deployments/branch-policies).\"\n\n**Note:** To create or update secrets for an environment, see \"[GitHub Actions secrets](/rest/" }, { "info": { "name": "GitHub Update Deployment Branch Policy", "type": "http" }, "http": { "method": "PUT", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/environments/:environment_name/deployment-branch-policies/:branch_policy_id", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "environment_name", "value": "", "type": "path", "description": "The name of the environment. The name must be URL encoded. For example, any slashes in the name must be replaced with `%2F`." }, { "name": "branch_policy_id", "value": "", "type": "path", "description": "The unique identifier of the branch policy." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Updates a deployment branch policy for an environment.\n\nOAuth app tokens and personal access tokens (classic) need the `repo` scope to use this endpoint." }, { "info": { "name": "GitHub Create or Update an Environment Secret", "type": "http" }, "http": { "method": "PUT", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/environments/:environment_name/secrets/:secret_name", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "environment_name", "value": "", "type": "path", "description": "The name of the environment. The name must be URL encoded. For example, any slashes in the name must be replaced with `%2F`." }, { "name": "secret_name", "value": "", "type": "path", "description": "The name of the secret." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Creates or updates an environment secret with an encrypted value. Encrypt your secret using\n[LibSodium](https://libsodium.gitbook.io/doc/bindings_for_other_languages). For more information, see \"[Encrypting secrets for the REST API](https://docs.github.com/enterprise-server@3.9/rest/guides/encrypting-secrets-for-the-rest-api).\"\n\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.\n\nOAuth tokens and personal access tokens (classic) need the `repo` " }, { "info": { "name": "GitHub Update an Environment Variable", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/environments/:environment_name/variables/:name", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "name", "value": "", "type": "path", "description": "The name of the variable." }, { "name": "environment_name", "value": "", "type": "path", "description": "The name of the environment. The name must be URL encoded. For example, any slashes in the name must be replaced with `%2F`." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Updates an environment variable that you can reference in a GitHub Actions workflow.\n\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.\n\nOAuth app tokens and personal access tokens (classic) need the `repo` scope to use this endpoint." }, { "info": { "name": "GitHub Update Reference", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/git/refs/:ref", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "ref", "value": "heads/feature-a", "type": "path", "description": "The Git reference. For more information, see \"[Git References](https://git-scm.com/book/en/v2/Git-Internals-Git-References)\" in the Git documentation." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Updates the provided reference to point to a new SHA. For more information, see \"[Git References](https://git-scm.com/book/en/v2/Git-Internals-Git-References)\" in the Git documentation." }, { "info": { "name": "GitHub Update Label", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/labels/:name", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "name", "value": "octocat", "type": "path" } ], "body": { "type": "json", "data": "{}" } }, "docs": "Updates a label using the given label name." }, { "info": { "name": "GitHub Update Milestone", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/milestones/:milestone_number", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "milestone_number", "value": "", "type": "path", "description": "The number that identifies the milestone." } ], "body": { "type": "json", "data": "{}" } }, "docs": "The Update Milestone operation in the GitHub Repos API allows you to modify an existing milestone within a repository by sending a PATCH request to /repos/{owner}/{repo}/milestones/{milestone_number}. This endpoint enables you to update various milestone properties such as the title, state (open or closed), description, and due date. You must specify the repository owner, repository name, and milestone number in the URL path, while the fields you wish to update are provided in the request body a" }, { "info": { "name": "GitHub Update Information About Github Enterprise Server Pages Site", "type": "http" }, "http": { "method": "PUT", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/pages", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Updates information for a GitHub Enterprise Server Pages site. For more information, see \"[About GitHub Pages](/github/working-with-github-pages/about-github-pages).\n\nThe authenticated user must be a repository administrator, maintainer, or have the 'manage GitHub Pages settings' permission.\n\nOAuth app tokens and personal access tokens (classic) need the `repo` scope to use this endpoint." }, { "info": { "name": "GitHub Update Release Asset", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/releases/assets/:asset_id", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "asset_id", "value": "", "type": "path", "description": "The unique identifier of the asset." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Users with push access to the repository can edit a release asset." }, { "info": { "name": "GitHub Update Release", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/releases/:release_id", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "release_id", "value": "", "type": "path", "description": "The unique identifier of the release." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Users with push access to the repository can edit a release." }, { "info": { "name": "GitHub Update Secret Scanning Alert", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/repos/:owner/:repo/secret-scanning/alerts/:alert_number", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "alert_number", "value": "", "type": "path", "description": "The number that identifies an alert. You can find this at the end of the URL for a code scanning alert within GitHub, and in the `number` field in the response from the `GET /repos/{owner}/{repo}/code-scanning/alerts` operation." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Updates the status of a secret scanning alert in an eligible repository.\n\nThe authenticated user must be an administrator for the repository or for the organization that owns the repository to use this endpoint.\n\nOAuth 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." }, { "info": { "name": "GitHub Update an Attribute for Scim Enterprise Group", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/scim/v2/Groups/:scim_group_id", "params": [ { "name": "scim_group_id", "value": "", "type": "path", "description": "A unique identifier of the SCIM group." } ], "body": { "type": "json", "data": "{}" } }, "docs": "**Note:** The SCIM API endpoints for enterprise accounts are currently in *private* beta and are subject to change.\n\nUpdate a provisioned group’s individual attributes.\n\nTo change a group’s values, you must provide a specific Operations JSON format that contains at least one of the add, remove, or replace operations. For examples and more information on the SCIM operations format, see the [SCIM specification](https://tools.ietf.org/html/rfc7644#section-3.5.2). Update can also be used to add gro" }, { "info": { "name": "GitHub Update an Attribute for Scim Enterprise User", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/scim/v2/Users/:scim_user_id", "params": [ { "name": "scim_user_id", "value": "", "type": "path", "description": "The unique identifier of the SCIM user." } ], "body": { "type": "json", "data": "{}" } }, "docs": "**Note:** The SCIM API endpoints for enterprise accounts are currently in *private* beta and are subject to change.\n\nUpdate a provisioned user's individual attributes.\n\nTo change a user's values, you must provide a specific `Operations` JSON format that contains at least one of the `add`, `remove`, or `replace` operations. For examples and more information on the SCIM operations format, see the [SCIM specification](https://tools.ietf.org/html/rfc7644#section-3.5.2).\n\n**Note:** Complicated SCIM `" }, { "info": { "name": "GitHub Update Ldap Mapping for Team", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/admin/ldap/teams/:team_id/mapping", "params": [ { "name": "team_id", "value": "", "type": "path", "description": "The unique identifier of the team." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Updates the [distinguished name](https://www.ldap.com/ldap-dns-and-rdns) (DN) of the LDAP entry to map to a team. [LDAP synchronization](https://docs.github.com/enterprise-server@3.9/admin/identity-and-access-management/using-ldap-for-enterprise-iam/using-ldap#enabling-ldap-sync) must be enabled to map LDAP entries to a team. Use the [Create a team](https://docs.github.com/enterprise-server@3.9/rest/teams/teams/#create-a-team) endpoint to create a team with LDAP mapping." }, { "info": { "name": "GitHub Update Team (legacy)", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/teams/:team_id", "params": [ { "name": "team_id", "value": "", "type": "path", "description": "The unique identifier of the team." } ], "body": { "type": "json", "data": "{}" } }, "docs": "**Deprecation Notice:** This endpoint route is deprecated and will be removed from the Teams API. We recommend migrating your existing code to use the new [Update a team](https://docs.github.com/enterprise-server@3.9/rest/teams/teams#update-a-team) endpoint.\n\nTo edit a team, the authenticated user must either be an organization owner or a team maintainer.\n\n**Note:** With nested teams, the `privacy` for parent teams cannot be `secret`." }, { "info": { "name": "GitHub Update Discussion (legacy)", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/teams/:team_id/discussions/:discussion_number", "params": [ { "name": "team_id", "value": "", "type": "path", "description": "The unique identifier of the team." }, { "name": "discussion_number", "value": "", "type": "path", "description": "The number that identifies the discussion." } ], "body": { "type": "json", "data": "{}" } }, "docs": "**Deprecation Notice:** This endpoint route is deprecated and will be removed from the Teams API. We recommend migrating your existing code to use the new [Update a discussion](https://docs.github.com/enterprise-server@3.9/rest/teams/discussions#update-a-discussion) endpoint.\n\nEdits the title and body text of a discussion post. Only the parameters you provide are updated.\n\nOAuth app tokens and personal access tokens (classic) need the `write:discussion` scope to use this endpoint." }, { "info": { "name": "GitHub Update Discussion Comment (legacy)", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/api/v3/teams/:team_id/discussions/:discussion_number/comments/:comment_number", "params": [ { "name": "team_id", "value": "", "type": "path", "description": "The unique identifier of the team." }, { "name": "discussion_number", "value": "", "type": "path", "description": "The number that identifies the discussion." }, { "name": "comment_number", "value": "", "type": "path", "description": "The number that identifies the comment." } ], "body": { "type": "json", "data": "{}" } }, "docs": "**Deprecation Notice:** This endpoint route is deprecated and will be removed from the Teams API. We recommend migrating your existing code to use the new [Update a discussion comment](https://docs.github.com/enterprise-server@3.9/rest/teams/discussion-comments#update-a-discussion-comment) endpoint.\n\nEdits the body text of a discussion comment.\n\nOAuth app tokens and personal access tokens (classic) need the `write:discussion` scope to use this endpoint." }, { "info": { "name": "GitHub Add or Update Team Membership for User (legacy)", "type": "http" }, "http": { "method": "PUT", "url": "{protocol}://{hostname}/api/v3/teams/:team_id/memberships/:username", "params": [ { "name": "team_id", "value": "", "type": "path", "description": "The unique identifier of the team." }, { "name": "username", "value": "", "type": "path", "description": "The handle for the GitHub user account." } ], "body": { "type": "json", "data": "{}" } }, "docs": "**Deprecation Notice:** This endpoint route is deprecated and will be removed from the Teams API. We recommend migrating your existing code to use the new [Add or update team membership for a user](https://docs.github.com/enterprise-server@3.9/rest/teams/members#add-or-update-team-membership-for-a-user) endpoint.\n\nTeam synchronization is available for organizations using GitHub Enterprise Cloud. For more information, see [GitHub's products](https://docs.github.com/enterprise-server@3.9/github/ge" }, { "info": { "name": "GitHub Add or Update Team Repository Permissions (legacy)", "type": "http" }, "http": { "method": "PUT", "url": "{protocol}://{hostname}/api/v3/teams/:team_id/repos/:owner/:repo", "params": [ { "name": "team_id", "value": "", "type": "path", "description": "The unique identifier of the team." }, { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." } ], "body": { "type": "json", "data": "{}" } }, "docs": "**Deprecation Notice:** This endpoint route is deprecated and will be removed from the Teams API. We recommend migrating your existing code to use the new \"[Add or update team repository permissions](https://docs.github.com/enterprise-server@3.9/rest/teams/teams#add-or-update-team-repository-permissions)\" endpoint.\n\nTo add a repository to a team or update the team's permission on a repository, the authenticated user must have admin access to the repository, and must be able to see the team. The " } ] } ], "bundled": true }