diff --git a/assets/images/help/code-quality/invoke-cloud-agent.png b/assets/images/help/code-quality/invoke-cloud-agent.png new file mode 100644 index 000000000000..c88e3582d188 Binary files /dev/null and b/assets/images/help/code-quality/invoke-cloud-agent.png differ diff --git a/content/actions/reference/workflows-and-actions/events-that-trigger-workflows.md b/content/actions/reference/workflows-and-actions/events-that-trigger-workflows.md index 18ea075b2636..186211d44b84 100644 --- a/content/actions/reference/workflows-and-actions/events-that-trigger-workflows.md +++ b/content/actions/reference/workflows-and-actions/events-that-trigger-workflows.md @@ -515,7 +515,16 @@ on: Runs your workflow when activity on a pull request in the workflow's repository occurs. For example, if no activity types are specified, the workflow runs when a pull request is opened or reopened or when the head branch of the pull request is updated. For activity related to pull request reviews, pull request review comments, or pull request comments, use the [`pull_request_review`](#pull_request_review), [`pull_request_review_comment`](#pull_request_review_comment), or [`issue_comment`](#issue_comment) events instead. For information about the pull request APIs, see [AUTOTITLE](/graphql/reference/objects#pullrequest) in the GraphQL API documentation or [AUTOTITLE](/rest/pulls). -Note that `GITHUB_SHA` for this event is the last merge commit of the pull request merge branch. If you want to get the commit ID for the last commit to the head branch of the pull request, use `github.event.pull_request.head.sha` instead. +Note that `GITHUB_SHA` for this event is the last merge commit of the pull request merge branch. If you want to get the commit ID for the last commit to the head branch of the pull request, use `github.event.pull_request.head.sha` instead. For more information about merge branches, see [AUTOTITLE](/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/about-pull-requests#pull-request-refs-and-merge-branches). + +### How the merge branch affects your workflow + +For open, mergeable pull requests, workflows triggered by the `pull_request` event set `GITHUB_REF` to the merge branch. Because `actions/checkout` uses `GITHUB_REF` by default, it checks out the merge branch. Your CI tests run against the merged result, not just the head branch alone: + +* `GITHUB_REF` is set to `refs/pull/PULL_REQUEST_NUMBER/merge` +* `GITHUB_SHA` is the SHA of the merge commit on the merge branch + +To test only the head branch commits without simulating a merge, check out the head branch using `github.event.pull_request.head.sha` in your workflow. For example, you can run a workflow when a pull request has been opened or reopened. diff --git a/content/admin/overview/setting-up-a-trial-of-github-enterprise-cloud.md b/content/admin/overview/setting-up-a-trial-of-github-enterprise-cloud.md index 1eb8a19c10fb..e103798de800 100644 --- a/content/admin/overview/setting-up-a-trial-of-github-enterprise-cloud.md +++ b/content/admin/overview/setting-up-a-trial-of-github-enterprise-cloud.md @@ -44,7 +44,6 @@ Your trial **won't** include access to {% data variables.product.prodname_ghe_se * {% data variables.product.prodname_github_codespaces %} * {% data variables.copilot.copilot_enterprise %} * {% data variables.copilot.copilot_for_business %} - * Contact {% data variables.contact.github_support %} to enable {% data variables.copilot.copilot_for_business %} during your trial. * {% data variables.product.prodname_sponsors %} * Paid {% data variables.product.prodname_marketplace %} apps * {% data variables.product.prodname_github_connect %} diff --git a/content/billing/reference/supported-payment-methods.md b/content/billing/reference/supported-payment-methods.md index 5d1f842933c9..26896a58ddb5 100644 --- a/content/billing/reference/supported-payment-methods.md +++ b/content/billing/reference/supported-payment-methods.md @@ -13,6 +13,9 @@ category: ## Metered or usage-based billing options +> [!NOTE] +> Prepaid credit/debit cards are not accepted as a valid form of payment. + The supported payment methods for metered billing: * Invoice – Managed accounts only diff --git a/content/communities/using-templates-to-encourage-useful-issues-and-pull-requests/configuring-issue-templates-for-your-repository.md b/content/communities/using-templates-to-encourage-useful-issues-and-pull-requests/configuring-issue-templates-for-your-repository.md index 0766db748373..e152f82c1eb1 100644 --- a/content/communities/using-templates-to-encourage-useful-issues-and-pull-requests/configuring-issue-templates-for-your-repository.md +++ b/content/communities/using-templates-to-encourage-useful-issues-and-pull-requests/configuring-issue-templates-for-your-repository.md @@ -31,6 +31,9 @@ category: ![Screenshot of the preview of an issue template. To the right of the template name, a pencil icon is outlined in dark orange.](/assets/images/help/repository/issue-template-edit-button.png) 1. To automatically set a default issue title, assign the issue to people with read access to the repository, or apply labels to issues raised from the template, use the fields under "Optional additional information." You can also add these details in the issue template with `title`, `labels`, `type`, or `assignees` in a YAML frontmatter format. + > [!NOTE] + > The template name must be more than 3 characters. + 1. When you're finished editing and previewing your template, click **Propose changes** in the upper right corner of the page. 1. In the "Commit message" field, type a commit message describing your changes. 1. Below the commit message fields, select whether to commit your template directly to the default branch, or to create a new branch and open a pull request. For more information about pull requests, see [AUTOTITLE](/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/about-pull-requests). @@ -50,6 +53,9 @@ Here is an example of an issue form configuration file. {% data reusables.community.issue-forms-sample %} +> [!NOTE] +> The `name` field must be more than 3 characters. If it's not, the template won't be shown when creating an issue. + Here is the rendered version of the issue form. ![Screenshot of a rendered issue form, with a mix of text fields and dropdown menus.](/assets/images/help/repository/sample-issue-form.png) diff --git a/content/copilot/concepts/agents/about-agent-skills.md b/content/copilot/concepts/agents/about-agent-skills.md index 7dc1137803f6..15a42529b311 100644 --- a/content/copilot/concepts/agents/about-agent-skills.md +++ b/content/copilot/concepts/agents/about-agent-skills.md @@ -29,8 +29,8 @@ Support for organization-level and enterprise-level skills is coming soon. ## Next steps -To create an agent skill, see: +To create or add agent skills, see: -* [AUTOTITLE](/copilot/how-tos/use-copilot-agents/cloud-agent/create-skills) -* [AUTOTITLE](/copilot/how-tos/copilot-cli/customize-copilot/create-skills) +* [AUTOTITLE](/copilot/how-tos/use-copilot-agents/cloud-agent/add-skills) +* [AUTOTITLE](/copilot/how-tos/copilot-cli/customize-copilot/add-skills) * [AUTOTITLE](/copilot/reference/customization-cheat-sheet) diff --git a/content/copilot/concepts/agents/code-review.md b/content/copilot/concepts/agents/code-review.md index 15d9cbcf3116..c2f4d94eb787 100644 --- a/content/copilot/concepts/agents/code-review.md +++ b/content/copilot/concepts/agents/code-review.md @@ -26,6 +26,7 @@ This article provides an overview of {% data variables.copilot.copilot_code-revi {% data variables.copilot.copilot_code-review_short %} is supported in: * {% data variables.product.prodname_dotcom_the_website %} +* {% data variables.product.prodname_cli %} * {% data variables.product.prodname_mobile %} * {% data variables.product.prodname_vscode_shortname %} * {% data variables.product.prodname_vs %} diff --git a/content/copilot/concepts/agents/copilot-cli/index.md b/content/copilot/concepts/agents/copilot-cli/index.md index bd99c879e093..a78a8fa3a4be 100644 --- a/content/copilot/concepts/agents/copilot-cli/index.md +++ b/content/copilot/concepts/agents/copilot-cli/index.md @@ -15,6 +15,7 @@ children: - /fleet - /research - /chronicle + - /lsp-servers - /context-management contentType: concepts docsTeamMetrics: diff --git a/content/copilot/concepts/agents/copilot-cli/lsp-servers.md b/content/copilot/concepts/agents/copilot-cli/lsp-servers.md new file mode 100644 index 000000000000..9c7a6ced4c2e --- /dev/null +++ b/content/copilot/concepts/agents/copilot-cli/lsp-servers.md @@ -0,0 +1,74 @@ +--- +title: Using LSP servers with {% data variables.copilot.copilot_cli %} +shortTitle: LSP servers +allowTitleToDifferFromFilename: true +intro: 'LSP servers give {% data variables.copilot.copilot_cli_short %} precise code intelligence, enabling it to navigate definitions, find references, and rename symbols accurately across your project.' +versions: + feature: copilot +contentType: concepts +docsTeamMetrics: + - copilot-cli +category: + - Learn about Copilot # Copilot discovery page + - Learn about Copilot CLI # Copilot CLI bespoke page +--- + +## Introduction + +The Language Server Protocol (LSP) is an open standard used for communication between a code editor and a language server. A language server is a process that provides language-specific features like go-to-definition and renaming a code symbol across your codebase. An "LSP server" is any language server that supports the Language Server Protocol. + +{% data variables.copilot.copilot_cli %} can use LSP servers to understand the structure of your code more precisely. By adding and configuring an LSP server for each programming language in your project, you'll give {% data variables.copilot.copilot_cli_short %} a better understanding of your code. + +## Benefits of LSP servers + +* **Accuracy**: Results come from the language's own compiler/analyzer, providing an understanding of the structure of your code. This improves {% data variables.product.prodname_copilot_short %}'s precision when it works with your code. For example, when {% data variables.product.prodname_copilot_short %} can use "go to definition" it will find the actual definition, not a text match that looks similar. +* **Token efficiency**: Operations like "list all symbols" or "find references" return compact structured results instead of requiring the agent to read entire files into the conversation. +* **Safe refactoring**: When you rename a symbol, the LSP server reliably updates every reference across the project. +* **Speed**: Language servers index your project in the background, allowing near-instant responses. + +## What LSP servers allow {% data variables.copilot.copilot_cli_short %} to do + +When LSP servers are available, {% data variables.copilot.copilot_cli_short %} uses them automatically. You don't need to explicitly request it. {% data variables.copilot.copilot_cli_short %} will use an LSP server rather than text-based search whenever it can access an LSP server for the programming language you're using. + +The following language server operations are supported: + +| Operation | What it does | +|-----------|-------------| +| Go to definition | Jumps to where a symbol (function, class, variable) is defined. | +| Find references | Finds every location where a symbol is used. | +| Hover | Retrieves type information and documentation for a symbol. | +| Rename | Renames a symbol across the entire project, updating all references. | +| Document symbols | Lists all symbols defined in a file. | +| Workspace symbol search | Searches for symbols by name across the project. | +| Go to implementation | Finds implementations of an interface or abstract method. | +| Incoming calls | Shows which functions call a given function. | +| Outgoing calls | Shows which functions a given function calls. | + +{% data variables.product.prodname_copilot_short %} selects the most appropriate LSP operation based on your prompt. For example, if you ask "where is `handlePayment` defined?", {% data variables.product.prodname_copilot_short %} will use the go-to-definition operation. + +## How to add an LSP server + +For {% data variables.copilot.copilot_cli_short %} to be able to use an LSP server, you must first install the server software on your local machine and then configure it in one of the configuration files that {% data variables.copilot.copilot_cli_short %} reads on startup. See [AUTOTITLE](/copilot/how-tos/copilot-cli/set-up-copilot-cli/add-lsp-servers). + +An LSP server may also be added as part of a CLI plugin that you choose to install. A plugin might include an LSP server if, for example, it's designed to work with an uncommon programming language or a framework-specific file type. LSP servers included as part of a plugin are automatically available when you install the plugin—no additional configuration is needed. If you uninstall the plugin, the LSP server is removed. For more information, see [AUTOTITLE](/copilot/concepts/agents/copilot-cli/about-cli-plugins). + +## How LSP servers are loaded + +When {% data variables.copilot.copilot_cli %} starts, it loads LSP server configurations from multiple sources with the following priority (highest to lowest): + +1. **Project config**: `.github/lsp.json` in the current repository. +1. **Plugin configs**: language servers provided by installed plugins. +1. **User config**: `~/.copilot/lsp-config.json`. + +Higher-priority configurations override lower-priority ones with the same server name. This means a project can customize or disable language servers for all contributors. + +Once the working directory is trusted, {% data variables.copilot.copilot_cli_short %} automatically starts any LSP servers that are relevant to your project, in the background, so they are ready to respond immediately when needed. + +## Next steps + +* [AUTOTITLE](/copilot/how-tos/copilot-cli/set-up-copilot-cli/add-lsp-servers) + +## Further reading + +* [Language Server Protocol](https://microsoft.github.io/language-server-protocol/) on the Microsoft website +* [AUTOTITLE](/copilot/reference/cli-command-reference) diff --git a/content/copilot/how-tos/copilot-cli/customize-copilot/create-skills.md b/content/copilot/how-tos/copilot-cli/customize-copilot/add-skills.md similarity index 83% rename from content/copilot/how-tos/copilot-cli/customize-copilot/create-skills.md rename to content/copilot/how-tos/copilot-cli/customize-copilot/add-skills.md index cd7f5d17a897..a51a76fbdb1b 100644 --- a/content/copilot/how-tos/copilot-cli/customize-copilot/create-skills.md +++ b/content/copilot/how-tos/copilot-cli/customize-copilot/add-skills.md @@ -1,11 +1,13 @@ --- -title: Creating agent skills for {% data variables.copilot.copilot_cli %} -shortTitle: Create agent skills +title: Adding agent skills for {% data variables.copilot.copilot_cli %} +shortTitle: Add agent skills allowTitleToDifferFromFilename: true intro: 'Modify {% data variables.product.prodname_copilot_short %}''s behavior and abilities when it works on particular tasks.' versions: feature: copilot contentType: how-tos +redirect_from: + - /copilot/how-tos/copilot-cli/customize-copilot/create-skills category: - Configure Copilot # Copilot discovery page - Author and optimize with Copilot # Copilot discovery page @@ -18,6 +20,12 @@ Agent skills are folders of instructions, scripts, and resources that {% data va {% data reusables.copilot.creating-adding-skills %} +1. Start a CLI session, or if you are currently in a CLI session enter `/skills reload`. +1. Enter `/skills info SKILL-NAME` to check that the skill has reloaded. + + SKILL-NAME is defined in the SKILL.md file and is typically the same as the name of the skill directory. + + ## Using agent skills {% data reusables.copilot.skills-using %} diff --git a/content/copilot/how-tos/copilot-cli/customize-copilot/index.md b/content/copilot/how-tos/copilot-cli/customize-copilot/index.md index ae4869df3634..f989232db78e 100644 --- a/content/copilot/how-tos/copilot-cli/customize-copilot/index.md +++ b/content/copilot/how-tos/copilot-cli/customize-copilot/index.md @@ -9,7 +9,7 @@ children: - /overview - /add-custom-instructions - /use-hooks - - /create-skills + - /add-skills - /add-mcp-servers - /create-custom-agents-for-cli - /use-byok-models diff --git a/content/copilot/how-tos/copilot-cli/customize-copilot/overview.md b/content/copilot/how-tos/copilot-cli/customize-copilot/overview.md index 8695c8fa99d9..6089975adb0c 100644 --- a/content/copilot/how-tos/copilot-cli/customize-copilot/overview.md +++ b/content/copilot/how-tos/copilot-cli/customize-copilot/overview.md @@ -35,7 +35,7 @@ For more information, see [AUTOTITLE](/copilot/how-tos/copilot-cli/customize-cop Skills are folders of instructions, scripts, and resources that {% data variables.product.prodname_copilot_short %} can load to improve its performance on specialized tasks. By adding skills to your project, you can give {% data variables.product.prodname_copilot_short %} extra knowledge or tools for particular workflows, technologies, or domains. -For more information, see [AUTOTITLE](/copilot/how-tos/copilot-cli/customize-copilot/create-skills). +For more information, see [AUTOTITLE](/copilot/how-tos/copilot-cli/customize-copilot/add-skills). ## Custom agents diff --git a/content/copilot/how-tos/copilot-cli/index.md b/content/copilot/how-tos/copilot-cli/index.md index 28e60dab6bac..101102e16629 100644 --- a/content/copilot/how-tos/copilot-cli/index.md +++ b/content/copilot/how-tos/copilot-cli/index.md @@ -34,16 +34,18 @@ children: - /content/copilot/concepts/agents/copilot-cli/about-remote-access - /content/copilot/concepts/agents/copilot-cli/fleet - /content/copilot/concepts/agents/copilot-cli/research + - /content/copilot/concepts/agents/copilot-cli/lsp-servers - /content/copilot/concepts/agents/copilot-cli/chronicle - /content/copilot/concepts/agents/copilot-cli/context-management - /set-up-copilot-cli/install-copilot-cli - /set-up-copilot-cli/configure-copilot-cli + - /set-up-copilot-cli/add-lsp-servers - /automate-copilot-cli/quickstart - /automate-copilot-cli/automate-with-actions - /automate-copilot-cli/run-cli-programmatically - /customize-copilot/add-custom-instructions - /customize-copilot/create-custom-agents-for-cli - - /customize-copilot/create-skills + - /customize-copilot/add-skills - /customize-copilot/plugins-creating - /customize-copilot/plugins-finding-installing - /customize-copilot/plugins-marketplace diff --git a/content/copilot/how-tos/copilot-cli/set-up-copilot-cli/add-lsp-servers.md b/content/copilot/how-tos/copilot-cli/set-up-copilot-cli/add-lsp-servers.md new file mode 100644 index 000000000000..0eff54cce2f8 --- /dev/null +++ b/content/copilot/how-tos/copilot-cli/set-up-copilot-cli/add-lsp-servers.md @@ -0,0 +1,295 @@ +--- +title: Adding LSP servers for {% data variables.copilot.copilot_cli %} +shortTitle: Add LSP servers +intro: 'You can add LSP servers to give {% data variables.copilot.copilot_cli_short %} precise code intelligence, improving its ability to navigate definitions, find references, and rename symbols.' +versions: + feature: copilot +contentType: how-tos +docsTeamMetrics: + - copilot-cli +category: + - Configure Copilot # Copilot discovery page + - Configure Copilot CLI # Copilot CLI bespoke page +--- + +## Introduction + +This article explains how to add LSP servers for {% data variables.copilot.copilot_cli_short %}. For conceptual information about LSP servers, see [AUTOTITLE](/copilot/concepts/agents/copilot-cli/lsp-servers). + +Adding an LSP server for {% data variables.copilot.copilot_cli_short %} is a two-step process: + +1. Install the LSP server software on your local machine. +1. Configure the server in a configuration file. + +These steps are described in detail in this article. + +## Installing and configuring an LSP server + +You can add an LSP server for a specific language by either: +* Using the `lsp-setup` skill, which automates the process. +* Manually installing the server software and then configuring {% data variables.copilot.copilot_cli_short %} to use the server. + +These two approaches are described in the sections below. + +## Using the `lsp-setup` skill to add a language server + +The `lsp-setup` skill from the "Awesome {% data variables.product.prodname_copilot %}" repository automates the installation and configuration of a selection of popular languages. + +1. Go to the "Awesome {% data variables.product.prodname_copilot %}" download site and search for "lsp": + + https://awesome-copilot.github.com/skills/?q=lsp. + +1. Download the `lsp-setup` skill. +1. Unzip the downloaded `.zip` file to create a directory called `lsp-setup`. +1. Move the `lsp-setup` directory into either: + + * Your personal skills directory: `~/.copilot/skills/`. + * A project skills directory: `.github/skills/` in a Git repository. + +1. Start {% data variables.copilot.copilot_cli_short %}, or if you are currently in a CLI session enter `/skills reload`. +1. Enter the prompt: + + ```copilot copy + setup lsp + ``` + +1. Follow the on-screen instructions to select the language for the server you want to set up, then complete the additional steps. +1. When the process is complete, enter `/lsp reload` to load the new LSP server. +1. Check that the server has been added and is working correctly. See [Confirming that an LSP server is available](#confirming-that-an-lsp-server-is-available) later in this article. + +## Manually installing and configuring an LSP server + +Installing an LSP server for a specific language typically involves installing a package via a package manager such as `npm`, `gem`, or `pip`. + +To manually install an LSP server, refer to the documentation for the specific language server you want to install. Listed below are some example commands for installing popular LSP servers. + +> [!NOTE] +> Useful resources for finding LSP servers for different languages include: +> * [Implementations](https://microsoft.github.io/language-server-protocol/implementors/servers/) on Microsoft's Language Server Protocol website. +> * [Language Server Protocol](https://wiki.archlinux.org/title/Language_Server_Protocol) on the Arch Linux website. + +> [!CAUTION] +> Only install LSP servers from sources you trust. + +### Example installation command: TypeScript and JavaScript + +If you have Node.js installed, you can install the `typescript-language-server` LSP server with the following command: + +```bash copy +npm install -g typescript typescript-language-server +``` + +The `typescript-language-server` LSP server supports both TypeScript and JavaScript. + +### Example installation command: Ruby + +If you have gem installed, you can install the `ruby-lsp` LSP server with the following command: + +```bash copy +gem install ruby-lsp +``` + +Alternatively, you can install the `solargraph` LSP server for Ruby with: + +```bash copy +gem install solargraph +``` + +### Example installation command: Python + +If you have Node.js installed, you can install the `pyright` LSP server with the following command: + +```bash copy +npm install -g pyright +``` + +Alternatively, if you have pip installed, you can install the `python-lsp-server` LSP server with: + +```bash copy +pip install python-lsp-server +``` + +## Configuring the language server + +1. To configure the LSP server, add a server definition to either of the two configuration files: + + * **User configuration**: `~/.copilot/lsp-config.json` applies to all your projects. + * **Project configuration**: `.github/lsp.json`, in your repository, applies to everyone working on that project. + + Both files use the same JSON syntax: + + ```json + { + "lspServers": { + "SERVER-NAME": { + "command": "COMMAND", + "args": ["ARG1", "ARG2"], + "fileExtensions": { + ".EXT": "LANGUAGE-ID" + } + }, + "ANOTHER-SERVER": { + ... + } + } + } + ``` + + Some examples of server definitions for specific LSP servers are provided later in this article. + +1. After installing and configuring the server, confirm that {% data variables.copilot.copilot_cli_short %} can use it. See [Confirming that an LSP server is available](#confirming-that-an-lsp-server-is-available) below. + +### Configuration fields + +Each server definition in the configuration file must have a unique name and contain only alphanumeric characters, underscores, and hyphens. + +Within each server definition, the following fields are available/required: + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FieldRequiredDescription
commandYesThe command used to start the LSP server.
argsNoArguments to pass to the command.
fileExtensionsYesA JSON map of file extensions and their corresponding language ID (for example, { ".rs": "rust" }).
envNoEnvironment variables to set when starting the server. Supports ${VAR} and ${VAR:-default} expansion syntax.
rootUriNoThe root directory for the LSP server, relative to the Git root. Defaults to ".". Useful for monorepos. If your project lives in a subdirectory of the Git repository rather than the repository root, set rootUri to that subdirectory path.
initializationOptionsNoCustom options sent to the server during startup.
requestTimeoutMsNoThe timeout for server requests in milliseconds (default: 90 seconds).
+ +### Example server definition: `typescript-language-server` LSP server + +```json copy +{ + "lspServers": { + "typescript": { + "command": "typescript-language-server", + "args": ["--stdio"], + "fileExtensions": { + ".ts": "typescript", + ".tsx": "typescriptreact", + ".js": "javascript", + ".jsx": "javascriptreact", + ".mjs": "javascript", + ".cjs": "javascript", + ".mts": "typescript", + ".cts": "typescript" + } + } + } +} +``` + +### Example server definition: `ruby-lsp` LSP server + +```json copy +{ + "lspServers": { + "ruby": { + "command": "ruby-lsp", + "args": [], + "fileExtensions": { + ".rb": "ruby", + ".rbw": "ruby", + ".rake": "ruby", + ".gemspec": "ruby" + } + } + } +} +``` + +### Example server definition: `pyright` LSP server for Python + +```json copy +{ + "lspServers": { + "python": { + "command": "pyright-langserver", + "args": ["--stdio"], + "fileExtensions": { + ".py": "python", + ".pyw": "python", + ".pyi": "python" + } + } + } +} +``` + +## Managing language servers with the `/lsp` command + +You can list and manage your LSP servers in an interactive CLI session using the `/lsp` slash command: + +| Slash command | Description | +|---------------------------|-------------| +| `/lsp` or `/lsp show` | Show the status of all configured LSP servers. | +| `/lsp test SERVER-NAME` | Test whether a server starts correctly. | +| `/lsp reload` | Reload LSP configurations from disk. | +| `/lsp help` | Show `/lsp` command information. | + +### Listing available LSP servers + +1. In {% data variables.copilot.copilot_cli_short %}, confirm that the LSP server you chose is available by using the `/lsp` slash command. You will see output such as: + + ```text + ● LSP Server Status: + + User-configured servers: + • ruby: ruby-lsp (.rb, .rbw, .rake, .gemspec) + • omnisharp: omnisharp (.cs) + + User config: /Users/username/.copilot/lsp-config.json + ``` + +### Confirming that an LSP server is available + +1. After adding and configuring an LSP server, start (or restart) {% data variables.copilot.copilot_cli_short %}. +1. Use the slash command: `/lsp test SERVER-NAME` to check that the LSP server is working correctly. + + {% data variables.copilot.copilot_cli_short %} attempts to start a temporary, standalone instance of the server and reports whether it was successful or if there were any errors. It then kills the temporary server process. + +## Further reading + +* [AUTOTITLE](/copilot/how-tos/copilot-cli) +* [AUTOTITLE](/copilot/how-tos/use-copilot-agents/use-copilot-cli) diff --git a/content/copilot/how-tos/copilot-cli/set-up-copilot-cli/configure-copilot-cli.md b/content/copilot/how-tos/copilot-cli/set-up-copilot-cli/configure-copilot-cli.md index d748fcb8fd49..eb886380c7fb 100644 --- a/content/copilot/how-tos/copilot-cli/set-up-copilot-cli/configure-copilot-cli.md +++ b/content/copilot/how-tos/copilot-cli/set-up-copilot-cli/configure-copilot-cli.md @@ -1,5 +1,5 @@ --- -title: Configure GitHub Copilot CLI +title: Configuring GitHub Copilot CLI shortTitle: Configure Copilot CLI intro: Configure trusted directories, tool access, and path and URL permissions for {% data variables.copilot.copilot_cli_short %} versions: diff --git a/content/copilot/how-tos/copilot-cli/set-up-copilot-cli/index.md b/content/copilot/how-tos/copilot-cli/set-up-copilot-cli/index.md index 4298bbb5d0b9..ab40084e1547 100644 --- a/content/copilot/how-tos/copilot-cli/set-up-copilot-cli/index.md +++ b/content/copilot/how-tos/copilot-cli/set-up-copilot-cli/index.md @@ -8,6 +8,7 @@ children: - /install-copilot-cli - /authenticate-copilot-cli - /configure-copilot-cli + - /add-lsp-servers - /troubleshoot-copilot-cli-auth contentType: how-tos docsTeamMetrics: diff --git a/content/copilot/how-tos/copilot-cli/use-copilot-cli-agents/invoke-custom-agents.md b/content/copilot/how-tos/copilot-cli/use-copilot-cli-agents/invoke-custom-agents.md index c9b517744911..237755abbaf3 100644 --- a/content/copilot/how-tos/copilot-cli/use-copilot-cli-agents/invoke-custom-agents.md +++ b/content/copilot/how-tos/copilot-cli/use-copilot-cli-agents/invoke-custom-agents.md @@ -87,7 +87,7 @@ For more information, see [AUTOTITLE](/copilot/how-tos/use-copilot-agents/cloud- You can create skills to enhance the ability of {% data variables.product.prodname_copilot_short %} to perform specialized tasks with instructions, scripts, and resources. -For more information, see [AUTOTITLE](/copilot/how-tos/copilot-cli/customize-copilot/create-skills). +For more information, see [AUTOTITLE](/copilot/how-tos/copilot-cli/customize-copilot/add-skills). ## Add an MCP server diff --git a/content/copilot/how-tos/copilot-cli/use-copilot-cli-agents/overview.md b/content/copilot/how-tos/copilot-cli/use-copilot-cli-agents/overview.md index 2ea76ca4de4d..1b5fe2634093 100644 --- a/content/copilot/how-tos/copilot-cli/use-copilot-cli-agents/overview.md +++ b/content/copilot/how-tos/copilot-cli/use-copilot-cli-agents/overview.md @@ -216,7 +216,7 @@ For more information, see [AUTOTITLE](/copilot/how-tos/use-copilot-agents/cloud- You can create skills to enhance the ability of {% data variables.product.prodname_copilot_short %} to perform specialized tasks with instructions, scripts, and resources. -For more information, see [AUTOTITLE](/copilot/how-tos/copilot-cli/customize-copilot/create-skills). +For more information, see [AUTOTITLE](/copilot/how-tos/copilot-cli/customize-copilot/add-skills). ### Add an MCP server diff --git a/content/copilot/how-tos/use-copilot-agents/cloud-agent/create-skills.md b/content/copilot/how-tos/use-copilot-agents/cloud-agent/add-skills.md similarity index 86% rename from content/copilot/how-tos/use-copilot-agents/cloud-agent/create-skills.md rename to content/copilot/how-tos/use-copilot-agents/cloud-agent/add-skills.md index e54f03ba5de4..7417748a1112 100644 --- a/content/copilot/how-tos/use-copilot-agents/cloud-agent/create-skills.md +++ b/content/copilot/how-tos/use-copilot-agents/cloud-agent/add-skills.md @@ -1,6 +1,6 @@ --- -title: Creating agent skills for {% data variables.product.prodname_copilot %} -shortTitle: Create agent skills +title: Adding agent skills for {% data variables.product.prodname_copilot %} +shortTitle: Add agent skills allowTitleToDifferFromFilename: true intro: 'You can modify {% data variables.product.prodname_copilot_short %}''s behavior and abilities when it works on particular tasks.' versions: @@ -11,6 +11,7 @@ category: - Author and optimize with Copilot redirect_from: - /copilot/how-tos/use-copilot-agents/coding-agent/create-skills + - /copilot/how-tos/use-copilot-agents/cloud-agent/create-skills --- > [!NOTE] diff --git a/content/copilot/how-tos/use-copilot-agents/cloud-agent/index.md b/content/copilot/how-tos/use-copilot-agents/cloud-agent/index.md index e4d68c308282..ac80c665de96 100644 --- a/content/copilot/how-tos/use-copilot-agents/cloud-agent/index.md +++ b/content/copilot/how-tos/use-copilot-agents/cloud-agent/index.md @@ -14,7 +14,7 @@ children: - /review-copilot-prs - /create-custom-agents - /test-custom-agents - - /create-skills + - /add-skills - /extend-cloud-agent-with-mcp - /integrate-cloud-agent-with-jira - /integrate-cloud-agent-with-slack diff --git a/content/copilot/how-tos/use-copilot-agents/request-a-code-review/use-code-review.md b/content/copilot/how-tos/use-copilot-agents/request-a-code-review/use-code-review.md index af4667d86ae9..467fa8a47db1 100644 --- a/content/copilot/how-tos/use-copilot-agents/request-a-code-review/use-code-review.md +++ b/content/copilot/how-tos/use-copilot-agents/request-a-code-review/use-code-review.md @@ -235,3 +235,43 @@ These instructions explain how to use {% data variables.copilot.copilot_code-rev 1. If there is more than one comment, use the up and down arrows, at the top right of the popup, to navigate between comments. {% endjetbrains %} + +{% cli %} + +## Prerequisites + +* **Access to {% data variables.product.prodname_copilot_short %}**. {% data reusables.copilot.subscription-prerequisite %} +* **{% data variables.product.prodname_cli %}**. You must have the {% data variables.product.prodname_cli %} installed and authenticated. See [AUTOTITLE](/github-cli/github-cli/quickstart). + +## Using {% data variables.copilot.copilot_code-review_short %} + +These instructions explain how to use {% data variables.copilot.copilot_code-review_short %} with the {% data variables.product.prodname_cli %}. To see instructions for other popular coding environments, click the appropriate tab at the top of the page. + +### Requesting a review when creating a pull request + +You can request a review from {% data variables.product.prodname_copilot_short %} when creating a new pull request using `gh pr create`: + +```shell copy +gh pr create --reviewer @copilot +``` + +You can also select {% data variables.product.prodname_copilot_short %} interactively from the searchable reviewer prompt during `gh pr create`. + +```text +? Reviewers [Use arrows to move, space to select, to all, to none, type to filter] + [ ] Search (7472 more) + [x] monalisa (Mona Lisa) +> [x] Copilot (AI) +``` + +### Requesting a review on an existing pull request + +To request a review from {% data variables.product.prodname_copilot_short %} on an existing pull request, use `gh pr edit`. If you are not on the pull request's branch, specify the pull request number: + +```shell copy +gh pr edit PR-NUMBER --add-reviewer @copilot +``` + +Replace `PR-NUMBER` with the number of the pull request you want reviewed. If you have the pull request's branch checked out, you can omit the number. + +{% endcli %} diff --git a/content/copilot/reference/copilot-cli-reference/cli-config-dir-reference.md b/content/copilot/reference/copilot-cli-reference/cli-config-dir-reference.md index 8cf199f38fae..ca501b9c5a83 100644 --- a/content/copilot/reference/copilot-cli-reference/cli-config-dir-reference.md +++ b/content/copilot/reference/copilot-cli-reference/cli-config-dir-reference.md @@ -89,7 +89,7 @@ For more information, see [AUTOTITLE](/copilot/how-tos/copilot-cli/customize-cop Store personal custom skill definitions here. Each skill lives in a subdirectory containing a `SKILL.md` file—for example, `~/.copilot/skills/my-skill/SKILL.md`. Personal skills are available in all your sessions. Project-level skills take precedence over personal skills if they share the same name. -For more information, see [AUTOTITLE](/copilot/how-tos/copilot-cli/customize-copilot/create-skills). +For more information, see [AUTOTITLE](/copilot/how-tos/copilot-cli/customize-copilot/add-skills). ### `hooks/` diff --git a/content/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/about-pull-requests.md b/content/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/about-pull-requests.md index ddceef8f136e..d354a7e47883 100644 --- a/content/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/about-pull-requests.md +++ b/content/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/about-pull-requests.md @@ -35,6 +35,26 @@ When you create a pull request, you can choose to make it a draft pull request. {% data reusables.pull_requests.mark-ready-review %} You can convert a pull request to a draft at any time. See [AUTOTITLE](/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/changing-the-stage-of-a-pull-request). +## Pull request refs and merge branches + +When you open a pull request, {% data variables.product.github %} creates up to two temporary, read-only Git references for it: + +| Ref | Description | +| --- | --- | +| `refs/pull/PULL_REQUEST_NUMBER/head` | Points to the latest commit on the pull request's head branch. | +| `refs/pull/PULL_REQUEST_NUMBER/merge` | A merge branch—a simulated merge commit that represents what the repository would look like if the pull request were merged right now. This ref is only available when the pull request has no merge conflicts. | + +The merge branch automatically updates when the head branch or base branch changes. To fetch it locally: + +```shell +git fetch origin refs/pull/PULL_REQUEST_NUMBER/merge +git checkout FETCH_HEAD +``` + +Replace `PULL_REQUEST_NUMBER` with the number of your pull request. + +For information about how {% data variables.product.prodname_actions %} uses the merge branch, see [AUTOTITLE](/actions/reference/workflows-and-actions/events-that-trigger-workflows#how-the-merge-branch-affects-your-workflow). + ## Differences between commits on compare and pull request pages The compare and pull request pages use different methods to calculate the diff for changed files: diff --git a/data/reusables/actions/ref-description.md b/data/reusables/actions/ref-description.md index 55364ac1c021..193cbb2718b4 100644 --- a/data/reusables/actions/ref-description.md +++ b/data/reusables/actions/ref-description.md @@ -1 +1 @@ -The fully-formed ref of the branch or tag that triggered the workflow run. For workflows triggered by `push`, this is the branch or tag ref that was pushed. For workflows triggered by `pull_request` that were not merged, this is the pull request merge branch. If the pull request was merged, this is the head branch. For workflows triggered by `release`, this is the release tag created. For other triggers, this is the branch or tag ref that triggered the workflow run. This is only set if a branch or tag is available for the event type. The ref given is fully-formed, meaning that for branches the format is `refs/heads/`. For pull requests events except `pull_request_target` that were not merged, it is `refs/pull//merge`. `pull_request_target` events have the `ref` from the base branch. For tags it is `refs/tags/`. For example, `refs/heads/feature-branch-1`. +The fully-formed ref of the branch or tag that triggered the workflow run. For workflows triggered by `push`, this is the branch or tag ref that was pushed. For workflows triggered by `pull_request` that were not merged, this is the pull request merge branch. If the pull request was merged, this is the branch it was merged into. For workflows triggered by `release`, this is the release tag created. For other triggers, this is the branch or tag ref that triggered the workflow run. This is only set if a branch or tag is available for the event type. The ref given is fully-formed, meaning that for branches the format is `refs/heads/`. For pull request events except `pull_request_target` that were not merged, it is `refs/pull//merge`. `pull_request_target` events have the `ref` from the base branch. For tags it is `refs/tags/`. For example, `refs/heads/feature-branch-1`. For more information about pull request merge branches, see [AUTOTITLE](/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/about-pull-requests#pull-request-refs-and-merge-branches). diff --git a/data/reusables/copilot/creating-adding-skills.md b/data/reusables/copilot/creating-adding-skills.md index 7981a47a712b..ab31184fd8f6 100644 --- a/data/reusables/copilot/creating-adding-skills.md +++ b/data/reusables/copilot/creating-adding-skills.md @@ -1,16 +1,14 @@ ## Creating and adding a skill -To create an agent skill you write a `SKILL.md` file and, optionally, other resources, such as supplementary Markdown files, or scripts, which you reference in the `SKILL.md` instructions. +To create an agent skill, you write a `SKILL.md` file and, optionally, other resources, such as supplementary Markdown files, or scripts, which you reference in the `SKILL.md` instructions. -To add a skill, you save the `SKILL.md` file, and any subsidiary resources, to a location where {% data variables.product.prodname_copilot_short %} knows to look for skills. This can be within a repository, or within your home directory. +1. If you haven't already done so, create a `skills` directory in one of the following locations. This is where you will locate your skill, and any others you may want to create in the future. -1. Create a `skills` directory in one of the supported locations to store your skill and any others you may want to create in the future. + For **project skills**, specific to a single repository, create a `.github/skills`, `.claude/skills`, or `.agents/skills` directory in your repository. - For **project skills**, specific to a single repository, create and use a `.github/skills`, `.claude/skills`, or `.agents/skills` directory in your repository. + For **personal skills**, shared across projects, create a `~/.copilot/skills`, `~/.claude/skills`, or `~/.agents/skills` directory in your local home directory. - For **personal skills**, shared across projects, create and use a `~/.copilot/skills`, `~/.claude/skills`, or `~/.agents/skills` directory in your home directory. - -1. Create a subdirectory for your new skill. Each skill should have its own directory (for example, `.github/skills/webapp-testing`). +1. Within the `skills` directory, create a subdirectory for your new skill. Each skill should have its own directory (for example, `.github/skills/webapp-testing`). Skill subdirectory names should be lowercase and use hyphens for spaces. @@ -86,3 +84,18 @@ To create a skill that runs a script: from this skill's base directory, passing the input SVG file path as the first argument. ``` + +## Adding a skill that someone else has created + +In addition to creating your own skills, you can also add skills that other people have created. + +1. Download a skill directory (that is, a directory containing a SKILL.md file and, optionally, other files and subdirectories). + + For example, download a skill from the Awesome {% data variables.product.prodname_copilot %} repository: https://awesome-copilot.github.com/skills/. + +1. If you downloaded a `.zip` file, unzip this. +1. Move the skill directory to the required location: + + * For **project skills**, specific to a single repository: `.github/skills`, `.claude/skills`, or `.agents/skills` in your repository. + + * For **personal skills**, shared across projects: `~/.copilot/skills`, `~/.claude/skills`, or `~/.agents/skills` in your local home directory. diff --git a/data/reusables/enterprise-migration-tool/data-not-migrated.md b/data/reusables/enterprise-migration-tool/data-not-migrated.md index d3fd27bb12c3..be545598ef15 100644 --- a/data/reusables/enterprise-migration-tool/data-not-migrated.md +++ b/data/reusables/enterprise-migration-tool/data-not-migrated.md @@ -19,7 +19,7 @@ * Remediation states of {% data variables.product.prodname_secret_scanning %} results * Repositories owned by user accounts * Repository activity feed -* Repository properties +* Repository properties and custom properties (see [AUTOTITLE](/admin/managing-accounts-and-repositories/managing-organizations-in-your-enterprise/custom-properties)) * Repository stars * Repository watchers * Rulesets diff --git a/src/content-render/index.ts b/src/content-render/index.ts index 8cfd7771b05d..6591d079c024 100644 --- a/src/content-render/index.ts +++ b/src/content-render/index.ts @@ -38,9 +38,12 @@ export async function renderContent( try { template = await renderLiquid(template, context) if (context.markdownRequested) { - const md = await renderMarkdown(template, context) - - return md + // Skip the remark pipeline when there are no internal links to rewrite, + // since link rewriting is the only transformation the pipeline performs. + if (!/\]\(\s* p.pageVersion === version) @@ -178,18 +190,12 @@ async function checkVersion( totalPagesChecked++ - // Create context for rendering - const context: Context = { - currentVersion: version, - currentLanguage: language, - currentVersionObj: versionObj, - page, - pages: pageMap, - redirects, - } as Context + // Mutate the page property in place — safe because the loop is sequential (each iteration + // awaits before the next begins), so there is no concurrent access to baseContext. + baseContext.page = page // Get links from rendered page - const links = await getLinksFromRenderedPage(page, permalink, context) + const links = await getLinksFromRenderedPage(page, permalink, baseContext) totalLinksChecked += links.length // Check each link @@ -233,7 +239,7 @@ async function checkVersion( // Check anchors if enabled if (options.checkAnchors) { - const anchorFlaws = await checkAnchorsOnPage(page, permalink, context) + const anchorFlaws = await checkAnchorsOnPage(page, permalink, baseContext) brokenLinks.push(...anchorFlaws) } diff --git a/src/rest/data/fpt-2022-11-28/copilot.json b/src/rest/data/fpt-2022-11-28/copilot.json index 485597d66da5..d382cf3c7647 100644 --- a/src/rest/data/fpt-2022-11-28/copilot.json +++ b/src/rest/data/fpt-2022-11-28/copilot.json @@ -1,5 +1,263 @@ { "copilot-coding-agent-management": [ + { + "serverUrl": "https://api.github.com", + "verb": "put", + "requestPath": "/enterprises/{enterprise}/copilot/policies/coding_agent", + "title": "Set the coding agent policy for an enterprise", + "category": "copilot", + "subcategory": "copilot-coding-agent-management", + "parameters": [ + { + "name": "enterprise", + "description": "

The slug version of the enterprise name.

", + "in": "path", + "required": true, + "schema": { + "type": "string" + } + } + ], + "bodyParameters": [ + { + "type": "string", + "name": "policy_state", + "description": "

The policy state for Copilot coding agent in the enterprise. Can be one of enabled_for_all_orgs, disabled_for_all_orgs, enabled_for_selected_orgs, or configured_by_org_admins.

", + "isRequired": true, + "enum": [ + "enabled_for_all_orgs", + "disabled_for_all_orgs", + "enabled_for_selected_orgs", + "configured_by_org_admins" + ] + } + ], + "descriptionHTML": "

Sets the policy for Copilot coding agent usage across an enterprise.

\n

Enterprise owners can configure whether Copilot coding agent is enabled for all\norganizations, disabled for all organizations, configured by individual organization\nadmins, or enabled for selected organizations only.

\n

Only enterprise owners can set the coding agent policy for their enterprise.

\n

OAuth app tokens and personal access tokens (classic) need either the manage_billing:copilot or admin:enterprise scopes to use this endpoint.

", + "codeExamples": [ + { + "request": { + "contentType": "application/json", + "description": "Enable coding agent for all organizations", + "acceptHeader": "application/vnd.github.v3+json", + "bodyParameters": { + "policy_state": "enabled_for_all_orgs" + }, + "parameters": { + "enterprise": "ENTERPRISE" + } + }, + "response": { + "statusCode": "204", + "description": "

A header with no content is returned.

" + } + } + ], + "statusCodes": [ + { + "httpStatusCode": "204", + "description": "

A header with no content is returned.

" + }, + { + "httpStatusCode": "400", + "description": "

Bad Request

" + } + ], + "previews": [], + "progAccess": { + "userToServerRest": false, + "serverToServer": false, + "fineGrainedPat": false, + "permissions": [] + } + }, + { + "serverUrl": "https://api.github.com", + "verb": "post", + "requestPath": "/enterprises/{enterprise}/copilot/policies/coding_agent/organizations", + "title": "Add organizations to the enterprise coding agent policy", + "category": "copilot", + "subcategory": "copilot-coding-agent-management", + "parameters": [ + { + "name": "enterprise", + "description": "

The slug version of the enterprise name.

", + "in": "path", + "required": true, + "schema": { + "type": "string" + } + } + ], + "bodyParameters": [ + { + "type": "array of strings", + "name": "organizations", + "description": "

List of organization logins within the enterprise to enable Copilot coding agent for.

" + }, + { + "type": "array of objects", + "name": "custom_properties", + "description": "

List of custom property filters to match organizations. Organizations matching any of the specified property name/value pairs will be included. This is a one-time operation, setting the property on an organization in the future will not automatically update its coding agent policy.

", + "childParamsGroups": [ + { + "type": "string", + "name": "property_name", + "description": "

The name of the custom property to filter by.

", + "isRequired": true + }, + { + "type": "array of strings", + "name": "values", + "description": "

The values of the custom property to match.

", + "isRequired": true + } + ] + } + ], + "descriptionHTML": "

Enables Copilot coding agent for the specified organizations within the enterprise.

\n

The enterprise's coding agent policy must be set to enabled_for_selected_orgs before\nusing this endpoint. Organizations can be specified by login or matched via custom properties.

\n

Only organizations that have Copilot enabled and belong to the enterprise will be affected.

\n

Only enterprise owners can add organizations to the coding agent policy.

\n

OAuth app tokens and personal access tokens (classic) need either the manage_billing:copilot or admin:enterprise scopes to use this endpoint.

", + "codeExamples": [ + { + "request": { + "contentType": "application/json", + "description": "Add organizations that match a login or have a custom property", + "acceptHeader": "application/vnd.github.v3+json", + "bodyParameters": { + "organizations": [ + "my-org-1", + "my-org-2" + ], + "custom_properties": [ + { + "property_name": "department", + "values": [ + "engineering", + "security" + ] + } + ] + }, + "parameters": { + "enterprise": "ENTERPRISE" + } + }, + "response": { + "statusCode": "204", + "description": "

A header with no content is returned.

" + } + } + ], + "statusCodes": [ + { + "httpStatusCode": "204", + "description": "

A header with no content is returned.

" + }, + { + "httpStatusCode": "400", + "description": "

Bad Request

" + } + ], + "previews": [], + "progAccess": { + "userToServerRest": false, + "serverToServer": false, + "fineGrainedPat": false, + "permissions": [] + } + }, + { + "serverUrl": "https://api.github.com", + "verb": "delete", + "requestPath": "/enterprises/{enterprise}/copilot/policies/coding_agent/organizations", + "title": "Remove organizations from the enterprise coding agent policy", + "category": "copilot", + "subcategory": "copilot-coding-agent-management", + "parameters": [ + { + "name": "enterprise", + "description": "

The slug version of the enterprise name.

", + "in": "path", + "required": true, + "schema": { + "type": "string" + } + } + ], + "bodyParameters": [ + { + "type": "array of strings", + "name": "organizations", + "description": "

List of organization logins within the enterprise to disable Copilot coding agent for.

" + }, + { + "type": "array of objects", + "name": "custom_properties", + "description": "

List of custom property filters to match organizations. Organizations matching any of the specified property name/value pairs will be included. This is a one-time operation, setting the property on an organization in the future will not automatically update its coding agent policy.

", + "childParamsGroups": [ + { + "type": "string", + "name": "property_name", + "description": "

The name of the custom property to filter by.

", + "isRequired": true + }, + { + "type": "array of strings", + "name": "values", + "description": "

The values of the custom property to match.

", + "isRequired": true + } + ] + } + ], + "descriptionHTML": "

Disables Copilot coding agent for the specified organizations within the enterprise.

\n

The enterprise's coding agent policy must be set to enabled_for_selected_orgs before\nusing this endpoint. Organizations can be specified by login or matched via custom properties.

\n

Only organizations that have Copilot enabled and belong to the enterprise will be affected.

\n

Only enterprise owners can remove organizations from the coding agent policy.

\n

OAuth app tokens and personal access tokens (classic) need either the manage_billing:copilot or admin:enterprise scopes to use this endpoint.

", + "codeExamples": [ + { + "request": { + "contentType": "application/json", + "description": "Remove organizations that match a login or have a custom property", + "acceptHeader": "application/vnd.github.v3+json", + "bodyParameters": { + "organizations": [ + "my-org-1", + "my-org-2" + ], + "custom_properties": [ + { + "property_name": "department", + "values": [ + "engineering", + "security" + ] + } + ] + }, + "parameters": { + "enterprise": "ENTERPRISE" + } + }, + "response": { + "statusCode": "204", + "description": "

A header with no content is returned.

" + } + } + ], + "statusCodes": [ + { + "httpStatusCode": "204", + "description": "

A header with no content is returned.

" + }, + { + "httpStatusCode": "400", + "description": "

Bad Request

" + } + ], + "previews": [], + "progAccess": { + "userToServerRest": false, + "serverToServer": false, + "fineGrainedPat": false, + "permissions": [] + } + }, { "serverUrl": "https://api.github.com", "verb": "get", diff --git a/src/rest/data/fpt-2022-11-28/dependabot.json b/src/rest/data/fpt-2022-11-28/dependabot.json index 7664388036e1..4630ed28c98d 100644 --- a/src/rest/data/fpt-2022-11-28/dependabot.json +++ b/src/rest/data/fpt-2022-11-28/dependabot.json @@ -7464,7 +7464,7 @@ { "serverUrl": "https://api.github.com", "verb": "get", - "requestPath": "/organizations/{org}/dependabot/repository-access", + "requestPath": "/orgs/{org}/dependabot/repository-access", "title": "Lists the repositories Dependabot can access in an organization", "category": "dependabot", "subcategory": "repository-access", @@ -8020,7 +8020,7 @@ { "serverUrl": "https://api.github.com", "verb": "patch", - "requestPath": "/organizations/{org}/dependabot/repository-access", + "requestPath": "/orgs/{org}/dependabot/repository-access", "title": "Updates Dependabot's repository access list for an organization", "category": "dependabot", "subcategory": "repository-access", @@ -8093,7 +8093,7 @@ { "serverUrl": "https://api.github.com", "verb": "put", - "requestPath": "/organizations/{org}/dependabot/repository-access/default-level", + "requestPath": "/orgs/{org}/dependabot/repository-access/default-level", "title": "Set the default repository access level for Dependabot", "category": "dependabot", "subcategory": "repository-access", diff --git a/src/rest/data/fpt-2022-11-28/dependency-graph.json b/src/rest/data/fpt-2022-11-28/dependency-graph.json index 70fb8a8018b7..90607a62640a 100644 --- a/src/rest/data/fpt-2022-11-28/dependency-graph.json +++ b/src/rest/data/fpt-2022-11-28/dependency-graph.json @@ -836,6 +836,177 @@ ], "allowsPublicRead": true } + }, + { + "serverUrl": "https://api.github.com", + "verb": "get", + "requestPath": "/repos/{owner}/{repo}/dependency-graph/sbom/fetch-report/{sbom_uuid}", + "title": "Fetch a software bill of materials (SBOM) for a repository.", + "category": "dependency-graph", + "subcategory": "sboms", + "parameters": [ + { + "name": "owner", + "description": "

The account owner of the repository. The name is not case sensitive.

", + "in": "path", + "required": true, + "schema": { + "type": "string" + } + }, + { + "name": "repo", + "description": "

The name of the repository without the .git extension. The name is not case sensitive.

", + "in": "path", + "required": true, + "schema": { + "type": "string" + } + }, + { + "name": "sbom_uuid", + "in": "path", + "required": true, + "description": "

The unique identifier of the SBOM export.

", + "schema": { + "type": "string" + } + } + ], + "bodyParameters": [], + "descriptionHTML": "

Fetches a previously generated software bill of materials (SBOM) for a repository.\nWhen the SBOM is ready, the response is a 302 redirect to a temporary download URL for the SBOM in SPDX JSON format.\nThe generated SBOM report may be retained for up to one week from the original request.\nThe temporary download URL returned by this endpoint expires separately, and its expiry is set when the fetch request is made.

", + "codeExamples": [ + { + "request": { + "description": "Example", + "acceptHeader": "application/vnd.github.v3+json", + "parameters": { + "owner": "OWNER", + "repo": "REPO", + "sbom_uuid": "SBOM_UUID" + } + }, + "response": { + "statusCode": "202", + "description": "

SBOM is still being processed, no content is returned.

" + } + } + ], + "statusCodes": [ + { + "httpStatusCode": "202", + "description": "

SBOM is still being processed, no content is returned.

" + }, + { + "httpStatusCode": "302", + "description": "

Redirects to a temporary download URL for the completed SBOM.

" + }, + { + "httpStatusCode": "403", + "description": "

Forbidden

" + }, + { + "httpStatusCode": "404", + "description": "

Resource not found

" + } + ], + "previews": [], + "progAccess": { + "userToServerRest": true, + "serverToServer": true, + "fineGrainedPat": true, + "permissions": [ + { + "\"Contents\" repository permissions": "read" + } + ], + "allowsPublicRead": true + } + }, + { + "serverUrl": "https://api.github.com", + "verb": "get", + "requestPath": "/repos/{owner}/{repo}/dependency-graph/sbom/generate-report", + "title": "Request generation of a software bill of materials (SBOM) for a repository.", + "category": "dependency-graph", + "subcategory": "sboms", + "parameters": [ + { + "name": "owner", + "description": "

The account owner of the repository. The name is not case sensitive.

", + "in": "path", + "required": true, + "schema": { + "type": "string" + } + }, + { + "name": "repo", + "description": "

The name of the repository without the .git extension. The name is not case sensitive.

", + "in": "path", + "required": true, + "schema": { + "type": "string" + } + } + ], + "bodyParameters": [], + "descriptionHTML": "

Triggers a job to generate a software bill of materials (SBOM) for a repository in SPDX JSON format.

", + "codeExamples": [ + { + "request": { + "description": "Example", + "acceptHeader": "application/vnd.github.v3+json", + "parameters": { + "owner": "OWNER", + "repo": "REPO" + } + }, + "response": { + "statusCode": "201", + "contentType": "application/json", + "description": "

Response

", + "example": { + "sbom_url": "https://api.github.com/repos/github/example/dependency-graph/sbom/fetch-report/4bab1a7e-da63-4828-9488-44e0e01a7c1b" + }, + "schema": { + "type": "object", + "properties": { + "sbom_url": { + "type": "string", + "description": "URL to poll for the SBOM export result." + } + } + } + } + } + ], + "statusCodes": [ + { + "httpStatusCode": "201", + "description": "

Created

" + }, + { + "httpStatusCode": "403", + "description": "

Forbidden

" + }, + { + "httpStatusCode": "404", + "description": "

Resource not found

" + } + ], + "previews": [], + "progAccess": { + "userToServerRest": true, + "serverToServer": true, + "fineGrainedPat": true, + "permissions": [ + { + "\"Contents\" repository permissions": "read" + } + ], + "allowsPublicRead": true + } } ] } \ No newline at end of file diff --git a/src/rest/data/fpt-2026-03-10/copilot.json b/src/rest/data/fpt-2026-03-10/copilot.json index 3e7db53b16c8..799f4dc71cdd 100644 --- a/src/rest/data/fpt-2026-03-10/copilot.json +++ b/src/rest/data/fpt-2026-03-10/copilot.json @@ -1,5 +1,263 @@ { "copilot-coding-agent-management": [ + { + "serverUrl": "https://api.github.com", + "verb": "put", + "requestPath": "/enterprises/{enterprise}/copilot/policies/coding_agent", + "title": "Set the coding agent policy for an enterprise", + "category": "copilot", + "subcategory": "copilot-coding-agent-management", + "parameters": [ + { + "name": "enterprise", + "description": "

The slug version of the enterprise name.

", + "in": "path", + "required": true, + "schema": { + "type": "string" + } + } + ], + "bodyParameters": [ + { + "type": "string", + "name": "policy_state", + "description": "

The policy state for Copilot coding agent in the enterprise. Can be one of enabled_for_all_orgs, disabled_for_all_orgs, enabled_for_selected_orgs, or configured_by_org_admins.

", + "isRequired": true, + "enum": [ + "enabled_for_all_orgs", + "disabled_for_all_orgs", + "enabled_for_selected_orgs", + "configured_by_org_admins" + ] + } + ], + "descriptionHTML": "

Sets the policy for Copilot coding agent usage across an enterprise.

\n

Enterprise owners can configure whether Copilot coding agent is enabled for all\norganizations, disabled for all organizations, configured by individual organization\nadmins, or enabled for selected organizations only.

\n

Only enterprise owners can set the coding agent policy for their enterprise.

\n

OAuth app tokens and personal access tokens (classic) need either the manage_billing:copilot or admin:enterprise scopes to use this endpoint.

", + "codeExamples": [ + { + "request": { + "contentType": "application/json", + "description": "Enable coding agent for all organizations", + "acceptHeader": "application/vnd.github.v3+json", + "bodyParameters": { + "policy_state": "enabled_for_all_orgs" + }, + "parameters": { + "enterprise": "ENTERPRISE" + } + }, + "response": { + "statusCode": "204", + "description": "

A header with no content is returned.

" + } + } + ], + "statusCodes": [ + { + "httpStatusCode": "204", + "description": "

A header with no content is returned.

" + }, + { + "httpStatusCode": "400", + "description": "

Bad Request

" + } + ], + "previews": [], + "progAccess": { + "userToServerRest": false, + "serverToServer": false, + "fineGrainedPat": false, + "permissions": [] + } + }, + { + "serverUrl": "https://api.github.com", + "verb": "post", + "requestPath": "/enterprises/{enterprise}/copilot/policies/coding_agent/organizations", + "title": "Add organizations to the enterprise coding agent policy", + "category": "copilot", + "subcategory": "copilot-coding-agent-management", + "parameters": [ + { + "name": "enterprise", + "description": "

The slug version of the enterprise name.

", + "in": "path", + "required": true, + "schema": { + "type": "string" + } + } + ], + "bodyParameters": [ + { + "type": "array of strings", + "name": "organizations", + "description": "

List of organization logins within the enterprise to enable Copilot coding agent for.

" + }, + { + "type": "array of objects", + "name": "custom_properties", + "description": "

List of custom property filters to match organizations. Organizations matching any of the specified property name/value pairs will be included. This is a one-time operation, setting the property on an organization in the future will not automatically update its coding agent policy.

", + "childParamsGroups": [ + { + "type": "string", + "name": "property_name", + "description": "

The name of the custom property to filter by.

", + "isRequired": true + }, + { + "type": "array of strings", + "name": "values", + "description": "

The values of the custom property to match.

", + "isRequired": true + } + ] + } + ], + "descriptionHTML": "

Enables Copilot coding agent for the specified organizations within the enterprise.

\n

The enterprise's coding agent policy must be set to enabled_for_selected_orgs before\nusing this endpoint. Organizations can be specified by login or matched via custom properties.

\n

Only organizations that have Copilot enabled and belong to the enterprise will be affected.

\n

Only enterprise owners can add organizations to the coding agent policy.

\n

OAuth app tokens and personal access tokens (classic) need either the manage_billing:copilot or admin:enterprise scopes to use this endpoint.

", + "codeExamples": [ + { + "request": { + "contentType": "application/json", + "description": "Add organizations that match a login or have a custom property", + "acceptHeader": "application/vnd.github.v3+json", + "bodyParameters": { + "organizations": [ + "my-org-1", + "my-org-2" + ], + "custom_properties": [ + { + "property_name": "department", + "values": [ + "engineering", + "security" + ] + } + ] + }, + "parameters": { + "enterprise": "ENTERPRISE" + } + }, + "response": { + "statusCode": "204", + "description": "

A header with no content is returned.

" + } + } + ], + "statusCodes": [ + { + "httpStatusCode": "204", + "description": "

A header with no content is returned.

" + }, + { + "httpStatusCode": "400", + "description": "

Bad Request

" + } + ], + "previews": [], + "progAccess": { + "userToServerRest": false, + "serverToServer": false, + "fineGrainedPat": false, + "permissions": [] + } + }, + { + "serverUrl": "https://api.github.com", + "verb": "delete", + "requestPath": "/enterprises/{enterprise}/copilot/policies/coding_agent/organizations", + "title": "Remove organizations from the enterprise coding agent policy", + "category": "copilot", + "subcategory": "copilot-coding-agent-management", + "parameters": [ + { + "name": "enterprise", + "description": "

The slug version of the enterprise name.

", + "in": "path", + "required": true, + "schema": { + "type": "string" + } + } + ], + "bodyParameters": [ + { + "type": "array of strings", + "name": "organizations", + "description": "

List of organization logins within the enterprise to disable Copilot coding agent for.

" + }, + { + "type": "array of objects", + "name": "custom_properties", + "description": "

List of custom property filters to match organizations. Organizations matching any of the specified property name/value pairs will be included. This is a one-time operation, setting the property on an organization in the future will not automatically update its coding agent policy.

", + "childParamsGroups": [ + { + "type": "string", + "name": "property_name", + "description": "

The name of the custom property to filter by.

", + "isRequired": true + }, + { + "type": "array of strings", + "name": "values", + "description": "

The values of the custom property to match.

", + "isRequired": true + } + ] + } + ], + "descriptionHTML": "

Disables Copilot coding agent for the specified organizations within the enterprise.

\n

The enterprise's coding agent policy must be set to enabled_for_selected_orgs before\nusing this endpoint. Organizations can be specified by login or matched via custom properties.

\n

Only organizations that have Copilot enabled and belong to the enterprise will be affected.

\n

Only enterprise owners can remove organizations from the coding agent policy.

\n

OAuth app tokens and personal access tokens (classic) need either the manage_billing:copilot or admin:enterprise scopes to use this endpoint.

", + "codeExamples": [ + { + "request": { + "contentType": "application/json", + "description": "Remove organizations that match a login or have a custom property", + "acceptHeader": "application/vnd.github.v3+json", + "bodyParameters": { + "organizations": [ + "my-org-1", + "my-org-2" + ], + "custom_properties": [ + { + "property_name": "department", + "values": [ + "engineering", + "security" + ] + } + ] + }, + "parameters": { + "enterprise": "ENTERPRISE" + } + }, + "response": { + "statusCode": "204", + "description": "

A header with no content is returned.

" + } + } + ], + "statusCodes": [ + { + "httpStatusCode": "204", + "description": "

A header with no content is returned.

" + }, + { + "httpStatusCode": "400", + "description": "

Bad Request

" + } + ], + "previews": [], + "progAccess": { + "userToServerRest": false, + "serverToServer": false, + "fineGrainedPat": false, + "permissions": [] + } + }, { "serverUrl": "https://api.github.com", "verb": "get", diff --git a/src/rest/data/fpt-2026-03-10/dependabot.json b/src/rest/data/fpt-2026-03-10/dependabot.json index 17e23bc2700c..cfed61fe0528 100644 --- a/src/rest/data/fpt-2026-03-10/dependabot.json +++ b/src/rest/data/fpt-2026-03-10/dependabot.json @@ -7324,7 +7324,7 @@ { "serverUrl": "https://api.github.com", "verb": "get", - "requestPath": "/organizations/{org}/dependabot/repository-access", + "requestPath": "/orgs/{org}/dependabot/repository-access", "title": "Lists the repositories Dependabot can access in an organization", "category": "dependabot", "subcategory": "repository-access", @@ -7880,7 +7880,7 @@ { "serverUrl": "https://api.github.com", "verb": "patch", - "requestPath": "/organizations/{org}/dependabot/repository-access", + "requestPath": "/orgs/{org}/dependabot/repository-access", "title": "Updates Dependabot's repository access list for an organization", "category": "dependabot", "subcategory": "repository-access", @@ -7953,7 +7953,7 @@ { "serverUrl": "https://api.github.com", "verb": "put", - "requestPath": "/organizations/{org}/dependabot/repository-access/default-level", + "requestPath": "/orgs/{org}/dependabot/repository-access/default-level", "title": "Set the default repository access level for Dependabot", "category": "dependabot", "subcategory": "repository-access", diff --git a/src/rest/data/fpt-2026-03-10/dependency-graph.json b/src/rest/data/fpt-2026-03-10/dependency-graph.json index 70fb8a8018b7..90607a62640a 100644 --- a/src/rest/data/fpt-2026-03-10/dependency-graph.json +++ b/src/rest/data/fpt-2026-03-10/dependency-graph.json @@ -836,6 +836,177 @@ ], "allowsPublicRead": true } + }, + { + "serverUrl": "https://api.github.com", + "verb": "get", + "requestPath": "/repos/{owner}/{repo}/dependency-graph/sbom/fetch-report/{sbom_uuid}", + "title": "Fetch a software bill of materials (SBOM) for a repository.", + "category": "dependency-graph", + "subcategory": "sboms", + "parameters": [ + { + "name": "owner", + "description": "

The account owner of the repository. The name is not case sensitive.

", + "in": "path", + "required": true, + "schema": { + "type": "string" + } + }, + { + "name": "repo", + "description": "

The name of the repository without the .git extension. The name is not case sensitive.

", + "in": "path", + "required": true, + "schema": { + "type": "string" + } + }, + { + "name": "sbom_uuid", + "in": "path", + "required": true, + "description": "

The unique identifier of the SBOM export.

", + "schema": { + "type": "string" + } + } + ], + "bodyParameters": [], + "descriptionHTML": "

Fetches a previously generated software bill of materials (SBOM) for a repository.\nWhen the SBOM is ready, the response is a 302 redirect to a temporary download URL for the SBOM in SPDX JSON format.\nThe generated SBOM report may be retained for up to one week from the original request.\nThe temporary download URL returned by this endpoint expires separately, and its expiry is set when the fetch request is made.

", + "codeExamples": [ + { + "request": { + "description": "Example", + "acceptHeader": "application/vnd.github.v3+json", + "parameters": { + "owner": "OWNER", + "repo": "REPO", + "sbom_uuid": "SBOM_UUID" + } + }, + "response": { + "statusCode": "202", + "description": "

SBOM is still being processed, no content is returned.

" + } + } + ], + "statusCodes": [ + { + "httpStatusCode": "202", + "description": "

SBOM is still being processed, no content is returned.

" + }, + { + "httpStatusCode": "302", + "description": "

Redirects to a temporary download URL for the completed SBOM.

" + }, + { + "httpStatusCode": "403", + "description": "

Forbidden

" + }, + { + "httpStatusCode": "404", + "description": "

Resource not found

" + } + ], + "previews": [], + "progAccess": { + "userToServerRest": true, + "serverToServer": true, + "fineGrainedPat": true, + "permissions": [ + { + "\"Contents\" repository permissions": "read" + } + ], + "allowsPublicRead": true + } + }, + { + "serverUrl": "https://api.github.com", + "verb": "get", + "requestPath": "/repos/{owner}/{repo}/dependency-graph/sbom/generate-report", + "title": "Request generation of a software bill of materials (SBOM) for a repository.", + "category": "dependency-graph", + "subcategory": "sboms", + "parameters": [ + { + "name": "owner", + "description": "

The account owner of the repository. The name is not case sensitive.

", + "in": "path", + "required": true, + "schema": { + "type": "string" + } + }, + { + "name": "repo", + "description": "

The name of the repository without the .git extension. The name is not case sensitive.

", + "in": "path", + "required": true, + "schema": { + "type": "string" + } + } + ], + "bodyParameters": [], + "descriptionHTML": "

Triggers a job to generate a software bill of materials (SBOM) for a repository in SPDX JSON format.

", + "codeExamples": [ + { + "request": { + "description": "Example", + "acceptHeader": "application/vnd.github.v3+json", + "parameters": { + "owner": "OWNER", + "repo": "REPO" + } + }, + "response": { + "statusCode": "201", + "contentType": "application/json", + "description": "

Response

", + "example": { + "sbom_url": "https://api.github.com/repos/github/example/dependency-graph/sbom/fetch-report/4bab1a7e-da63-4828-9488-44e0e01a7c1b" + }, + "schema": { + "type": "object", + "properties": { + "sbom_url": { + "type": "string", + "description": "URL to poll for the SBOM export result." + } + } + } + } + } + ], + "statusCodes": [ + { + "httpStatusCode": "201", + "description": "

Created

" + }, + { + "httpStatusCode": "403", + "description": "

Forbidden

" + }, + { + "httpStatusCode": "404", + "description": "

Resource not found

" + } + ], + "previews": [], + "progAccess": { + "userToServerRest": true, + "serverToServer": true, + "fineGrainedPat": true, + "permissions": [ + { + "\"Contents\" repository permissions": "read" + } + ], + "allowsPublicRead": true + } } ] } \ No newline at end of file diff --git a/src/rest/data/ghec-2022-11-28/copilot.json b/src/rest/data/ghec-2022-11-28/copilot.json index 6c13b55e3702..8c52e2c72b85 100644 --- a/src/rest/data/ghec-2022-11-28/copilot.json +++ b/src/rest/data/ghec-2022-11-28/copilot.json @@ -1,5 +1,263 @@ { "copilot-coding-agent-management": [ + { + "serverUrl": "https://api.github.com", + "verb": "put", + "requestPath": "/enterprises/{enterprise}/copilot/policies/coding_agent", + "title": "Set the coding agent policy for an enterprise", + "category": "copilot", + "subcategory": "copilot-coding-agent-management", + "parameters": [ + { + "name": "enterprise", + "description": "

The slug version of the enterprise name.

", + "in": "path", + "required": true, + "schema": { + "type": "string" + } + } + ], + "bodyParameters": [ + { + "type": "string", + "name": "policy_state", + "description": "

The policy state for Copilot coding agent in the enterprise. Can be one of enabled_for_all_orgs, disabled_for_all_orgs, enabled_for_selected_orgs, or configured_by_org_admins.

", + "isRequired": true, + "enum": [ + "enabled_for_all_orgs", + "disabled_for_all_orgs", + "enabled_for_selected_orgs", + "configured_by_org_admins" + ] + } + ], + "descriptionHTML": "

Sets the policy for Copilot coding agent usage across an enterprise.

\n

Enterprise owners can configure whether Copilot coding agent is enabled for all\norganizations, disabled for all organizations, configured by individual organization\nadmins, or enabled for selected organizations only.

\n

Only enterprise owners can set the coding agent policy for their enterprise.

\n

OAuth app tokens and personal access tokens (classic) need either the manage_billing:copilot or admin:enterprise scopes to use this endpoint.

", + "codeExamples": [ + { + "request": { + "contentType": "application/json", + "description": "Enable coding agent for all organizations", + "acceptHeader": "application/vnd.github.v3+json", + "bodyParameters": { + "policy_state": "enabled_for_all_orgs" + }, + "parameters": { + "enterprise": "ENTERPRISE" + } + }, + "response": { + "statusCode": "204", + "description": "

A header with no content is returned.

" + } + } + ], + "statusCodes": [ + { + "httpStatusCode": "204", + "description": "

A header with no content is returned.

" + }, + { + "httpStatusCode": "400", + "description": "

Bad Request

" + } + ], + "previews": [], + "progAccess": { + "userToServerRest": false, + "serverToServer": false, + "fineGrainedPat": false, + "permissions": [] + } + }, + { + "serverUrl": "https://api.github.com", + "verb": "post", + "requestPath": "/enterprises/{enterprise}/copilot/policies/coding_agent/organizations", + "title": "Add organizations to the enterprise coding agent policy", + "category": "copilot", + "subcategory": "copilot-coding-agent-management", + "parameters": [ + { + "name": "enterprise", + "description": "

The slug version of the enterprise name.

", + "in": "path", + "required": true, + "schema": { + "type": "string" + } + } + ], + "bodyParameters": [ + { + "type": "array of strings", + "name": "organizations", + "description": "

List of organization logins within the enterprise to enable Copilot coding agent for.

" + }, + { + "type": "array of objects", + "name": "custom_properties", + "description": "

List of custom property filters to match organizations. Organizations matching any of the specified property name/value pairs will be included. This is a one-time operation, setting the property on an organization in the future will not automatically update its coding agent policy.

", + "childParamsGroups": [ + { + "type": "string", + "name": "property_name", + "description": "

The name of the custom property to filter by.

", + "isRequired": true + }, + { + "type": "array of strings", + "name": "values", + "description": "

The values of the custom property to match.

", + "isRequired": true + } + ] + } + ], + "descriptionHTML": "

Enables Copilot coding agent for the specified organizations within the enterprise.

\n

The enterprise's coding agent policy must be set to enabled_for_selected_orgs before\nusing this endpoint. Organizations can be specified by login or matched via custom properties.

\n

Only organizations that have Copilot enabled and belong to the enterprise will be affected.

\n

Only enterprise owners can add organizations to the coding agent policy.

\n

OAuth app tokens and personal access tokens (classic) need either the manage_billing:copilot or admin:enterprise scopes to use this endpoint.

", + "codeExamples": [ + { + "request": { + "contentType": "application/json", + "description": "Add organizations that match a login or have a custom property", + "acceptHeader": "application/vnd.github.v3+json", + "bodyParameters": { + "organizations": [ + "my-org-1", + "my-org-2" + ], + "custom_properties": [ + { + "property_name": "department", + "values": [ + "engineering", + "security" + ] + } + ] + }, + "parameters": { + "enterprise": "ENTERPRISE" + } + }, + "response": { + "statusCode": "204", + "description": "

A header with no content is returned.

" + } + } + ], + "statusCodes": [ + { + "httpStatusCode": "204", + "description": "

A header with no content is returned.

" + }, + { + "httpStatusCode": "400", + "description": "

Bad Request

" + } + ], + "previews": [], + "progAccess": { + "userToServerRest": false, + "serverToServer": false, + "fineGrainedPat": false, + "permissions": [] + } + }, + { + "serverUrl": "https://api.github.com", + "verb": "delete", + "requestPath": "/enterprises/{enterprise}/copilot/policies/coding_agent/organizations", + "title": "Remove organizations from the enterprise coding agent policy", + "category": "copilot", + "subcategory": "copilot-coding-agent-management", + "parameters": [ + { + "name": "enterprise", + "description": "

The slug version of the enterprise name.

", + "in": "path", + "required": true, + "schema": { + "type": "string" + } + } + ], + "bodyParameters": [ + { + "type": "array of strings", + "name": "organizations", + "description": "

List of organization logins within the enterprise to disable Copilot coding agent for.

" + }, + { + "type": "array of objects", + "name": "custom_properties", + "description": "

List of custom property filters to match organizations. Organizations matching any of the specified property name/value pairs will be included. This is a one-time operation, setting the property on an organization in the future will not automatically update its coding agent policy.

", + "childParamsGroups": [ + { + "type": "string", + "name": "property_name", + "description": "

The name of the custom property to filter by.

", + "isRequired": true + }, + { + "type": "array of strings", + "name": "values", + "description": "

The values of the custom property to match.

", + "isRequired": true + } + ] + } + ], + "descriptionHTML": "

Disables Copilot coding agent for the specified organizations within the enterprise.

\n

The enterprise's coding agent policy must be set to enabled_for_selected_orgs before\nusing this endpoint. Organizations can be specified by login or matched via custom properties.

\n

Only organizations that have Copilot enabled and belong to the enterprise will be affected.

\n

Only enterprise owners can remove organizations from the coding agent policy.

\n

OAuth app tokens and personal access tokens (classic) need either the manage_billing:copilot or admin:enterprise scopes to use this endpoint.

", + "codeExamples": [ + { + "request": { + "contentType": "application/json", + "description": "Remove organizations that match a login or have a custom property", + "acceptHeader": "application/vnd.github.v3+json", + "bodyParameters": { + "organizations": [ + "my-org-1", + "my-org-2" + ], + "custom_properties": [ + { + "property_name": "department", + "values": [ + "engineering", + "security" + ] + } + ] + }, + "parameters": { + "enterprise": "ENTERPRISE" + } + }, + "response": { + "statusCode": "204", + "description": "

A header with no content is returned.

" + } + } + ], + "statusCodes": [ + { + "httpStatusCode": "204", + "description": "

A header with no content is returned.

" + }, + { + "httpStatusCode": "400", + "description": "

Bad Request

" + } + ], + "previews": [], + "progAccess": { + "userToServerRest": false, + "serverToServer": false, + "fineGrainedPat": false, + "permissions": [] + } + }, { "serverUrl": "https://api.github.com", "verb": "get", diff --git a/src/rest/data/ghec-2022-11-28/dependabot.json b/src/rest/data/ghec-2022-11-28/dependabot.json index 7c21f50edad3..ec969b68e554 100644 --- a/src/rest/data/ghec-2022-11-28/dependabot.json +++ b/src/rest/data/ghec-2022-11-28/dependabot.json @@ -9170,7 +9170,7 @@ { "serverUrl": "https://api.github.com", "verb": "get", - "requestPath": "/organizations/{org}/dependabot/repository-access", + "requestPath": "/orgs/{org}/dependabot/repository-access", "title": "Lists the repositories Dependabot can access in an organization", "category": "dependabot", "subcategory": "repository-access", @@ -9726,7 +9726,7 @@ { "serverUrl": "https://api.github.com", "verb": "patch", - "requestPath": "/organizations/{org}/dependabot/repository-access", + "requestPath": "/orgs/{org}/dependabot/repository-access", "title": "Updates Dependabot's repository access list for an organization", "category": "dependabot", "subcategory": "repository-access", @@ -9799,7 +9799,7 @@ { "serverUrl": "https://api.github.com", "verb": "put", - "requestPath": "/organizations/{org}/dependabot/repository-access/default-level", + "requestPath": "/orgs/{org}/dependabot/repository-access/default-level", "title": "Set the default repository access level for Dependabot", "category": "dependabot", "subcategory": "repository-access", diff --git a/src/rest/data/ghec-2022-11-28/dependency-graph.json b/src/rest/data/ghec-2022-11-28/dependency-graph.json index 70fb8a8018b7..90607a62640a 100644 --- a/src/rest/data/ghec-2022-11-28/dependency-graph.json +++ b/src/rest/data/ghec-2022-11-28/dependency-graph.json @@ -836,6 +836,177 @@ ], "allowsPublicRead": true } + }, + { + "serverUrl": "https://api.github.com", + "verb": "get", + "requestPath": "/repos/{owner}/{repo}/dependency-graph/sbom/fetch-report/{sbom_uuid}", + "title": "Fetch a software bill of materials (SBOM) for a repository.", + "category": "dependency-graph", + "subcategory": "sboms", + "parameters": [ + { + "name": "owner", + "description": "

The account owner of the repository. The name is not case sensitive.

", + "in": "path", + "required": true, + "schema": { + "type": "string" + } + }, + { + "name": "repo", + "description": "

The name of the repository without the .git extension. The name is not case sensitive.

", + "in": "path", + "required": true, + "schema": { + "type": "string" + } + }, + { + "name": "sbom_uuid", + "in": "path", + "required": true, + "description": "

The unique identifier of the SBOM export.

", + "schema": { + "type": "string" + } + } + ], + "bodyParameters": [], + "descriptionHTML": "

Fetches a previously generated software bill of materials (SBOM) for a repository.\nWhen the SBOM is ready, the response is a 302 redirect to a temporary download URL for the SBOM in SPDX JSON format.\nThe generated SBOM report may be retained for up to one week from the original request.\nThe temporary download URL returned by this endpoint expires separately, and its expiry is set when the fetch request is made.

", + "codeExamples": [ + { + "request": { + "description": "Example", + "acceptHeader": "application/vnd.github.v3+json", + "parameters": { + "owner": "OWNER", + "repo": "REPO", + "sbom_uuid": "SBOM_UUID" + } + }, + "response": { + "statusCode": "202", + "description": "

SBOM is still being processed, no content is returned.

" + } + } + ], + "statusCodes": [ + { + "httpStatusCode": "202", + "description": "

SBOM is still being processed, no content is returned.

" + }, + { + "httpStatusCode": "302", + "description": "

Redirects to a temporary download URL for the completed SBOM.

" + }, + { + "httpStatusCode": "403", + "description": "

Forbidden

" + }, + { + "httpStatusCode": "404", + "description": "

Resource not found

" + } + ], + "previews": [], + "progAccess": { + "userToServerRest": true, + "serverToServer": true, + "fineGrainedPat": true, + "permissions": [ + { + "\"Contents\" repository permissions": "read" + } + ], + "allowsPublicRead": true + } + }, + { + "serverUrl": "https://api.github.com", + "verb": "get", + "requestPath": "/repos/{owner}/{repo}/dependency-graph/sbom/generate-report", + "title": "Request generation of a software bill of materials (SBOM) for a repository.", + "category": "dependency-graph", + "subcategory": "sboms", + "parameters": [ + { + "name": "owner", + "description": "

The account owner of the repository. The name is not case sensitive.

", + "in": "path", + "required": true, + "schema": { + "type": "string" + } + }, + { + "name": "repo", + "description": "

The name of the repository without the .git extension. The name is not case sensitive.

", + "in": "path", + "required": true, + "schema": { + "type": "string" + } + } + ], + "bodyParameters": [], + "descriptionHTML": "

Triggers a job to generate a software bill of materials (SBOM) for a repository in SPDX JSON format.

", + "codeExamples": [ + { + "request": { + "description": "Example", + "acceptHeader": "application/vnd.github.v3+json", + "parameters": { + "owner": "OWNER", + "repo": "REPO" + } + }, + "response": { + "statusCode": "201", + "contentType": "application/json", + "description": "

Response

", + "example": { + "sbom_url": "https://api.github.com/repos/github/example/dependency-graph/sbom/fetch-report/4bab1a7e-da63-4828-9488-44e0e01a7c1b" + }, + "schema": { + "type": "object", + "properties": { + "sbom_url": { + "type": "string", + "description": "URL to poll for the SBOM export result." + } + } + } + } + } + ], + "statusCodes": [ + { + "httpStatusCode": "201", + "description": "

Created

" + }, + { + "httpStatusCode": "403", + "description": "

Forbidden

" + }, + { + "httpStatusCode": "404", + "description": "

Resource not found

" + } + ], + "previews": [], + "progAccess": { + "userToServerRest": true, + "serverToServer": true, + "fineGrainedPat": true, + "permissions": [ + { + "\"Contents\" repository permissions": "read" + } + ], + "allowsPublicRead": true + } } ] } \ No newline at end of file diff --git a/src/rest/data/ghec-2026-03-10/copilot.json b/src/rest/data/ghec-2026-03-10/copilot.json index c9e1f507ac02..0683ef2ed3e2 100644 --- a/src/rest/data/ghec-2026-03-10/copilot.json +++ b/src/rest/data/ghec-2026-03-10/copilot.json @@ -1,5 +1,263 @@ { "copilot-coding-agent-management": [ + { + "serverUrl": "https://api.github.com", + "verb": "put", + "requestPath": "/enterprises/{enterprise}/copilot/policies/coding_agent", + "title": "Set the coding agent policy for an enterprise", + "category": "copilot", + "subcategory": "copilot-coding-agent-management", + "parameters": [ + { + "name": "enterprise", + "description": "

The slug version of the enterprise name.

", + "in": "path", + "required": true, + "schema": { + "type": "string" + } + } + ], + "bodyParameters": [ + { + "type": "string", + "name": "policy_state", + "description": "

The policy state for Copilot coding agent in the enterprise. Can be one of enabled_for_all_orgs, disabled_for_all_orgs, enabled_for_selected_orgs, or configured_by_org_admins.

", + "isRequired": true, + "enum": [ + "enabled_for_all_orgs", + "disabled_for_all_orgs", + "enabled_for_selected_orgs", + "configured_by_org_admins" + ] + } + ], + "descriptionHTML": "

Sets the policy for Copilot coding agent usage across an enterprise.

\n

Enterprise owners can configure whether Copilot coding agent is enabled for all\norganizations, disabled for all organizations, configured by individual organization\nadmins, or enabled for selected organizations only.

\n

Only enterprise owners can set the coding agent policy for their enterprise.

\n

OAuth app tokens and personal access tokens (classic) need either the manage_billing:copilot or admin:enterprise scopes to use this endpoint.

", + "codeExamples": [ + { + "request": { + "contentType": "application/json", + "description": "Enable coding agent for all organizations", + "acceptHeader": "application/vnd.github.v3+json", + "bodyParameters": { + "policy_state": "enabled_for_all_orgs" + }, + "parameters": { + "enterprise": "ENTERPRISE" + } + }, + "response": { + "statusCode": "204", + "description": "

A header with no content is returned.

" + } + } + ], + "statusCodes": [ + { + "httpStatusCode": "204", + "description": "

A header with no content is returned.

" + }, + { + "httpStatusCode": "400", + "description": "

Bad Request

" + } + ], + "previews": [], + "progAccess": { + "userToServerRest": false, + "serverToServer": false, + "fineGrainedPat": false, + "permissions": [] + } + }, + { + "serverUrl": "https://api.github.com", + "verb": "post", + "requestPath": "/enterprises/{enterprise}/copilot/policies/coding_agent/organizations", + "title": "Add organizations to the enterprise coding agent policy", + "category": "copilot", + "subcategory": "copilot-coding-agent-management", + "parameters": [ + { + "name": "enterprise", + "description": "

The slug version of the enterprise name.

", + "in": "path", + "required": true, + "schema": { + "type": "string" + } + } + ], + "bodyParameters": [ + { + "type": "array of strings", + "name": "organizations", + "description": "

List of organization logins within the enterprise to enable Copilot coding agent for.

" + }, + { + "type": "array of objects", + "name": "custom_properties", + "description": "

List of custom property filters to match organizations. Organizations matching any of the specified property name/value pairs will be included. This is a one-time operation, setting the property on an organization in the future will not automatically update its coding agent policy.

", + "childParamsGroups": [ + { + "type": "string", + "name": "property_name", + "description": "

The name of the custom property to filter by.

", + "isRequired": true + }, + { + "type": "array of strings", + "name": "values", + "description": "

The values of the custom property to match.

", + "isRequired": true + } + ] + } + ], + "descriptionHTML": "

Enables Copilot coding agent for the specified organizations within the enterprise.

\n

The enterprise's coding agent policy must be set to enabled_for_selected_orgs before\nusing this endpoint. Organizations can be specified by login or matched via custom properties.

\n

Only organizations that have Copilot enabled and belong to the enterprise will be affected.

\n

Only enterprise owners can add organizations to the coding agent policy.

\n

OAuth app tokens and personal access tokens (classic) need either the manage_billing:copilot or admin:enterprise scopes to use this endpoint.

", + "codeExamples": [ + { + "request": { + "contentType": "application/json", + "description": "Add organizations that match a login or have a custom property", + "acceptHeader": "application/vnd.github.v3+json", + "bodyParameters": { + "organizations": [ + "my-org-1", + "my-org-2" + ], + "custom_properties": [ + { + "property_name": "department", + "values": [ + "engineering", + "security" + ] + } + ] + }, + "parameters": { + "enterprise": "ENTERPRISE" + } + }, + "response": { + "statusCode": "204", + "description": "

A header with no content is returned.

" + } + } + ], + "statusCodes": [ + { + "httpStatusCode": "204", + "description": "

A header with no content is returned.

" + }, + { + "httpStatusCode": "400", + "description": "

Bad Request

" + } + ], + "previews": [], + "progAccess": { + "userToServerRest": false, + "serverToServer": false, + "fineGrainedPat": false, + "permissions": [] + } + }, + { + "serverUrl": "https://api.github.com", + "verb": "delete", + "requestPath": "/enterprises/{enterprise}/copilot/policies/coding_agent/organizations", + "title": "Remove organizations from the enterprise coding agent policy", + "category": "copilot", + "subcategory": "copilot-coding-agent-management", + "parameters": [ + { + "name": "enterprise", + "description": "

The slug version of the enterprise name.

", + "in": "path", + "required": true, + "schema": { + "type": "string" + } + } + ], + "bodyParameters": [ + { + "type": "array of strings", + "name": "organizations", + "description": "

List of organization logins within the enterprise to disable Copilot coding agent for.

" + }, + { + "type": "array of objects", + "name": "custom_properties", + "description": "

List of custom property filters to match organizations. Organizations matching any of the specified property name/value pairs will be included. This is a one-time operation, setting the property on an organization in the future will not automatically update its coding agent policy.

", + "childParamsGroups": [ + { + "type": "string", + "name": "property_name", + "description": "

The name of the custom property to filter by.

", + "isRequired": true + }, + { + "type": "array of strings", + "name": "values", + "description": "

The values of the custom property to match.

", + "isRequired": true + } + ] + } + ], + "descriptionHTML": "

Disables Copilot coding agent for the specified organizations within the enterprise.

\n

The enterprise's coding agent policy must be set to enabled_for_selected_orgs before\nusing this endpoint. Organizations can be specified by login or matched via custom properties.

\n

Only organizations that have Copilot enabled and belong to the enterprise will be affected.

\n

Only enterprise owners can remove organizations from the coding agent policy.

\n

OAuth app tokens and personal access tokens (classic) need either the manage_billing:copilot or admin:enterprise scopes to use this endpoint.

", + "codeExamples": [ + { + "request": { + "contentType": "application/json", + "description": "Remove organizations that match a login or have a custom property", + "acceptHeader": "application/vnd.github.v3+json", + "bodyParameters": { + "organizations": [ + "my-org-1", + "my-org-2" + ], + "custom_properties": [ + { + "property_name": "department", + "values": [ + "engineering", + "security" + ] + } + ] + }, + "parameters": { + "enterprise": "ENTERPRISE" + } + }, + "response": { + "statusCode": "204", + "description": "

A header with no content is returned.

" + } + } + ], + "statusCodes": [ + { + "httpStatusCode": "204", + "description": "

A header with no content is returned.

" + }, + { + "httpStatusCode": "400", + "description": "

Bad Request

" + } + ], + "previews": [], + "progAccess": { + "userToServerRest": false, + "serverToServer": false, + "fineGrainedPat": false, + "permissions": [] + } + }, { "serverUrl": "https://api.github.com", "verb": "get", diff --git a/src/rest/data/ghec-2026-03-10/dependabot.json b/src/rest/data/ghec-2026-03-10/dependabot.json index d260ed13bf74..725299dba9cc 100644 --- a/src/rest/data/ghec-2026-03-10/dependabot.json +++ b/src/rest/data/ghec-2026-03-10/dependabot.json @@ -9030,7 +9030,7 @@ { "serverUrl": "https://api.github.com", "verb": "get", - "requestPath": "/organizations/{org}/dependabot/repository-access", + "requestPath": "/orgs/{org}/dependabot/repository-access", "title": "Lists the repositories Dependabot can access in an organization", "category": "dependabot", "subcategory": "repository-access", @@ -9586,7 +9586,7 @@ { "serverUrl": "https://api.github.com", "verb": "patch", - "requestPath": "/organizations/{org}/dependabot/repository-access", + "requestPath": "/orgs/{org}/dependabot/repository-access", "title": "Updates Dependabot's repository access list for an organization", "category": "dependabot", "subcategory": "repository-access", @@ -9659,7 +9659,7 @@ { "serverUrl": "https://api.github.com", "verb": "put", - "requestPath": "/organizations/{org}/dependabot/repository-access/default-level", + "requestPath": "/orgs/{org}/dependabot/repository-access/default-level", "title": "Set the default repository access level for Dependabot", "category": "dependabot", "subcategory": "repository-access", diff --git a/src/rest/data/ghec-2026-03-10/dependency-graph.json b/src/rest/data/ghec-2026-03-10/dependency-graph.json index 70fb8a8018b7..90607a62640a 100644 --- a/src/rest/data/ghec-2026-03-10/dependency-graph.json +++ b/src/rest/data/ghec-2026-03-10/dependency-graph.json @@ -836,6 +836,177 @@ ], "allowsPublicRead": true } + }, + { + "serverUrl": "https://api.github.com", + "verb": "get", + "requestPath": "/repos/{owner}/{repo}/dependency-graph/sbom/fetch-report/{sbom_uuid}", + "title": "Fetch a software bill of materials (SBOM) for a repository.", + "category": "dependency-graph", + "subcategory": "sboms", + "parameters": [ + { + "name": "owner", + "description": "

The account owner of the repository. The name is not case sensitive.

", + "in": "path", + "required": true, + "schema": { + "type": "string" + } + }, + { + "name": "repo", + "description": "

The name of the repository without the .git extension. The name is not case sensitive.

", + "in": "path", + "required": true, + "schema": { + "type": "string" + } + }, + { + "name": "sbom_uuid", + "in": "path", + "required": true, + "description": "

The unique identifier of the SBOM export.

", + "schema": { + "type": "string" + } + } + ], + "bodyParameters": [], + "descriptionHTML": "

Fetches a previously generated software bill of materials (SBOM) for a repository.\nWhen the SBOM is ready, the response is a 302 redirect to a temporary download URL for the SBOM in SPDX JSON format.\nThe generated SBOM report may be retained for up to one week from the original request.\nThe temporary download URL returned by this endpoint expires separately, and its expiry is set when the fetch request is made.

", + "codeExamples": [ + { + "request": { + "description": "Example", + "acceptHeader": "application/vnd.github.v3+json", + "parameters": { + "owner": "OWNER", + "repo": "REPO", + "sbom_uuid": "SBOM_UUID" + } + }, + "response": { + "statusCode": "202", + "description": "

SBOM is still being processed, no content is returned.

" + } + } + ], + "statusCodes": [ + { + "httpStatusCode": "202", + "description": "

SBOM is still being processed, no content is returned.

" + }, + { + "httpStatusCode": "302", + "description": "

Redirects to a temporary download URL for the completed SBOM.

" + }, + { + "httpStatusCode": "403", + "description": "

Forbidden

" + }, + { + "httpStatusCode": "404", + "description": "

Resource not found

" + } + ], + "previews": [], + "progAccess": { + "userToServerRest": true, + "serverToServer": true, + "fineGrainedPat": true, + "permissions": [ + { + "\"Contents\" repository permissions": "read" + } + ], + "allowsPublicRead": true + } + }, + { + "serverUrl": "https://api.github.com", + "verb": "get", + "requestPath": "/repos/{owner}/{repo}/dependency-graph/sbom/generate-report", + "title": "Request generation of a software bill of materials (SBOM) for a repository.", + "category": "dependency-graph", + "subcategory": "sboms", + "parameters": [ + { + "name": "owner", + "description": "

The account owner of the repository. The name is not case sensitive.

", + "in": "path", + "required": true, + "schema": { + "type": "string" + } + }, + { + "name": "repo", + "description": "

The name of the repository without the .git extension. The name is not case sensitive.

", + "in": "path", + "required": true, + "schema": { + "type": "string" + } + } + ], + "bodyParameters": [], + "descriptionHTML": "

Triggers a job to generate a software bill of materials (SBOM) for a repository in SPDX JSON format.

", + "codeExamples": [ + { + "request": { + "description": "Example", + "acceptHeader": "application/vnd.github.v3+json", + "parameters": { + "owner": "OWNER", + "repo": "REPO" + } + }, + "response": { + "statusCode": "201", + "contentType": "application/json", + "description": "

Response

", + "example": { + "sbom_url": "https://api.github.com/repos/github/example/dependency-graph/sbom/fetch-report/4bab1a7e-da63-4828-9488-44e0e01a7c1b" + }, + "schema": { + "type": "object", + "properties": { + "sbom_url": { + "type": "string", + "description": "URL to poll for the SBOM export result." + } + } + } + } + } + ], + "statusCodes": [ + { + "httpStatusCode": "201", + "description": "

Created

" + }, + { + "httpStatusCode": "403", + "description": "

Forbidden

" + }, + { + "httpStatusCode": "404", + "description": "

Resource not found

" + } + ], + "previews": [], + "progAccess": { + "userToServerRest": true, + "serverToServer": true, + "fineGrainedPat": true, + "permissions": [ + { + "\"Contents\" repository permissions": "read" + } + ], + "allowsPublicRead": true + } } ] } \ No newline at end of file diff --git a/src/rest/data/ghes-3.18-2022-11-28/dependabot.json b/src/rest/data/ghes-3.18-2022-11-28/dependabot.json index 77702381f82f..dcbdf6d3ddd2 100644 --- a/src/rest/data/ghes-3.18-2022-11-28/dependabot.json +++ b/src/rest/data/ghes-3.18-2022-11-28/dependabot.json @@ -6696,7 +6696,7 @@ { "serverUrl": "http(s)://HOSTNAME/api/v3", "verb": "get", - "requestPath": "/organizations/{org}/dependabot/repository-access", + "requestPath": "/orgs/{org}/dependabot/repository-access", "title": "Lists the repositories Dependabot can access in an organization", "category": "dependabot", "subcategory": "repository-access", @@ -7252,7 +7252,7 @@ { "serverUrl": "http(s)://HOSTNAME/api/v3", "verb": "patch", - "requestPath": "/organizations/{org}/dependabot/repository-access", + "requestPath": "/orgs/{org}/dependabot/repository-access", "title": "Updates Dependabot's repository access list for an organization", "category": "dependabot", "subcategory": "repository-access", @@ -7325,7 +7325,7 @@ { "serverUrl": "http(s)://HOSTNAME/api/v3", "verb": "put", - "requestPath": "/organizations/{org}/dependabot/repository-access/default-level", + "requestPath": "/orgs/{org}/dependabot/repository-access/default-level", "title": "Set the default repository access level for Dependabot", "category": "dependabot", "subcategory": "repository-access", diff --git a/src/rest/data/ghes-3.19-2022-11-28/dependabot.json b/src/rest/data/ghes-3.19-2022-11-28/dependabot.json index f639eff618ad..f25d783e037c 100644 --- a/src/rest/data/ghes-3.19-2022-11-28/dependabot.json +++ b/src/rest/data/ghes-3.19-2022-11-28/dependabot.json @@ -7981,7 +7981,7 @@ { "serverUrl": "http(s)://HOSTNAME/api/v3", "verb": "get", - "requestPath": "/organizations/{org}/dependabot/repository-access", + "requestPath": "/orgs/{org}/dependabot/repository-access", "title": "Lists the repositories Dependabot can access in an organization", "category": "dependabot", "subcategory": "repository-access", @@ -8537,7 +8537,7 @@ { "serverUrl": "http(s)://HOSTNAME/api/v3", "verb": "patch", - "requestPath": "/organizations/{org}/dependabot/repository-access", + "requestPath": "/orgs/{org}/dependabot/repository-access", "title": "Updates Dependabot's repository access list for an organization", "category": "dependabot", "subcategory": "repository-access", @@ -8610,7 +8610,7 @@ { "serverUrl": "http(s)://HOSTNAME/api/v3", "verb": "put", - "requestPath": "/organizations/{org}/dependabot/repository-access/default-level", + "requestPath": "/orgs/{org}/dependabot/repository-access/default-level", "title": "Set the default repository access level for Dependabot", "category": "dependabot", "subcategory": "repository-access", diff --git a/src/rest/data/ghes-3.20-2022-11-28/dependabot.json b/src/rest/data/ghes-3.20-2022-11-28/dependabot.json index fa42df4b6b8f..4933ea6f1ce7 100644 --- a/src/rest/data/ghes-3.20-2022-11-28/dependabot.json +++ b/src/rest/data/ghes-3.20-2022-11-28/dependabot.json @@ -8324,7 +8324,7 @@ { "serverUrl": "http(s)://HOSTNAME/api/v3", "verb": "get", - "requestPath": "/organizations/{org}/dependabot/repository-access", + "requestPath": "/orgs/{org}/dependabot/repository-access", "title": "Lists the repositories Dependabot can access in an organization", "category": "dependabot", "subcategory": "repository-access", @@ -8880,7 +8880,7 @@ { "serverUrl": "http(s)://HOSTNAME/api/v3", "verb": "patch", - "requestPath": "/organizations/{org}/dependabot/repository-access", + "requestPath": "/orgs/{org}/dependabot/repository-access", "title": "Updates Dependabot's repository access list for an organization", "category": "dependabot", "subcategory": "repository-access", @@ -8953,7 +8953,7 @@ { "serverUrl": "http(s)://HOSTNAME/api/v3", "verb": "put", - "requestPath": "/organizations/{org}/dependabot/repository-access/default-level", + "requestPath": "/orgs/{org}/dependabot/repository-access/default-level", "title": "Set the default repository access level for Dependabot", "category": "dependabot", "subcategory": "repository-access", diff --git a/src/rest/lib/config.json b/src/rest/lib/config.json index b43b3c705a5e..019cea1ec2f2 100644 --- a/src/rest/lib/config.json +++ b/src/rest/lib/config.json @@ -55,5 +55,5 @@ ] } }, - "sha": "e6a345665a64530821d4ebcd07e7805a0cdeff09" + "sha": "2b6e93c2823a6f5dc1f6a3727b6b53eafa407fb2" } \ No newline at end of file diff --git a/src/secret-scanning/data/pattern-docs/fpt/public-docs.yml b/src/secret-scanning/data/pattern-docs/fpt/public-docs.yml index 16a917c84ce2..0381e0fb12fb 100644 --- a/src/secret-scanning/data/pattern-docs/fpt/public-docs.yml +++ b/src/secret-scanning/data/pattern-docs/fpt/public-docs.yml @@ -1457,7 +1457,7 @@ secretType: cloudflare_account_api_token isPublic: true isPrivateWithGhas: true - hasPushProtection: false + hasPushProtection: true hasValidityCheck: false hasExtendedMetadata: false base64Supported: false @@ -1467,7 +1467,7 @@ secretType: cloudflare_global_user_api_key isPublic: true isPrivateWithGhas: true - hasPushProtection: false + hasPushProtection: true hasValidityCheck: false hasExtendedMetadata: false base64Supported: false @@ -1477,7 +1477,7 @@ secretType: cloudflare_user_api_token isPublic: true isPrivateWithGhas: true - hasPushProtection: false + hasPushProtection: true hasValidityCheck: false hasExtendedMetadata: false base64Supported: false diff --git a/src/secret-scanning/data/pattern-docs/ghec/public-docs.yml b/src/secret-scanning/data/pattern-docs/ghec/public-docs.yml index 16a917c84ce2..0381e0fb12fb 100644 --- a/src/secret-scanning/data/pattern-docs/ghec/public-docs.yml +++ b/src/secret-scanning/data/pattern-docs/ghec/public-docs.yml @@ -1457,7 +1457,7 @@ secretType: cloudflare_account_api_token isPublic: true isPrivateWithGhas: true - hasPushProtection: false + hasPushProtection: true hasValidityCheck: false hasExtendedMetadata: false base64Supported: false @@ -1467,7 +1467,7 @@ secretType: cloudflare_global_user_api_key isPublic: true isPrivateWithGhas: true - hasPushProtection: false + hasPushProtection: true hasValidityCheck: false hasExtendedMetadata: false base64Supported: false @@ -1477,7 +1477,7 @@ secretType: cloudflare_user_api_token isPublic: true isPrivateWithGhas: true - hasPushProtection: false + hasPushProtection: true hasValidityCheck: false hasExtendedMetadata: false base64Supported: false diff --git a/src/versions/middleware/features.ts b/src/versions/middleware/features.ts index 7467a847d313..5870e701477e 100644 --- a/src/versions/middleware/features.ts +++ b/src/versions/middleware/features.ts @@ -26,8 +26,8 @@ type FeatureVersions = { let allFeatures: Record -const cache = new Map() -function getFeaturesByVersion(currentVersion: string): Record { +const cache = new Map>() +export function getFeaturesByVersion(currentVersion: string): Record { if (!cache.has(currentVersion)) { if (!allFeatures) { // As of Oct 2022, the `data/features/**` reading is *not* JIT. @@ -55,5 +55,5 @@ function getFeaturesByVersion(currentVersion: string): Record { cache.set(currentVersion, featureFlags) } - return cache.get(currentVersion) + return cache.get(currentVersion) as Record } diff --git a/src/webhooks/lib/config.json b/src/webhooks/lib/config.json index 2180c6b1b980..5346911eb94b 100644 --- a/src/webhooks/lib/config.json +++ b/src/webhooks/lib/config.json @@ -1,3 +1,3 @@ { - "sha": "e6a345665a64530821d4ebcd07e7805a0cdeff09" + "sha": "2b6e93c2823a6f5dc1f6a3727b6b53eafa407fb2" } \ No newline at end of file