From 7a0cd902aeb07f078c78982f0c89f7ed25e049d4 Mon Sep 17 00:00:00 2001 From: Logan MacLaren Date: Wed, 26 Jul 2023 05:20:14 -0400 Subject: [PATCH 01/14] Updating release notes to include CVE-2023-23764 (#39255) Co-authored-by: Laura Coursen --- .../release-notes/enterprise-server/3-7/9.yml | 19 ++-- .../release-notes/enterprise-server/3-8/2.yml | 29 +++--- .../release-notes/enterprise-server/3-9/1.yml | 88 ++++++++++--------- 3 files changed, 72 insertions(+), 64 deletions(-) diff --git a/data/release-notes/enterprise-server/3-7/9.yml b/data/release-notes/enterprise-server/3-7/9.yml index e7628cf722..4b72c23739 100644 --- a/data/release-notes/enterprise-server/3-7/9.yml +++ b/data/release-notes/enterprise-server/3-7/9.yml @@ -1,19 +1,22 @@ date: '2023-04-18' sections: + security_fixes: + - | + **MEDIUM**: An attacker with write access to a repository could craft a pull request that would hide commits made in its source branch. This vulnerability was reported via the [GitHub Bug Bounty Program](https://bounty.github.com/) and has been assigned [CVE-2023-23764](https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2023-23764). [Updated: 2023-07-26] bugs: - | - On an instance with GitHub Actions enabled, nested calls to reusable workflows within a reusable workflow job with a matrix correctly evaluate contexts within expressions, like `strategy: {% raw %}${{ inputs.strategies }}{% endraw %}`. - - Download requests for Git LFS objects did not complete until reporting the final download size, which affected the latency of these requests, particularly on an instance with nodes functioning as repository caches. - - For instances with both GitHub Connect and automatic access to GitHub.com actions enabled, Dependabot would fail to update actions hosted on GitHub.com. - - In some cases on an instance with a GitHub Advanced Security license, users could not load the security analysis page and saw a `500` error. - - On an instance with GitHub Connect enabled, if "Users can search GitHub.com" was enabled, issues in private and internal repositories were not included in users search results for GitHub.com. - - After restoration of a deleted organization, the organization did not appear in the instance's list of organizations. + On an instance with GitHub Actions enabled, nested calls to reusable workflows within a reusable workflow job with a matrix correctly evaluate contexts within expressions, like `strategy: {% raw %}${{ inputs.strategies }}{% endraw %}`. + - Download requests for Git LFS objects did not complete until reporting the final download size, which affected the latency of these requests, particularly on an instance with nodes functioning as repository caches. + - For instances with both GitHub Connect and automatic access to GitHub.com actions enabled, Dependabot would fail to update actions hosted on GitHub.com. + - In some cases on an instance with a GitHub Advanced Security license, users could not load the security analysis page and saw a `500` error. + - On an instance with GitHub Connect enabled, if "Users can search GitHub.com" was enabled, issues in private and internal repositories were not included in users search results for GitHub.com. + - After restoration of a deleted organization, the organization did not appear in the instance's list of organizations. - | - Collectd logs could grow rapidly in size due to the inclusion of `kredz.*` metrics, which can't be parsed by StatsD and resulted in error messages. + Collectd logs could grow rapidly in size due to the inclusion of `kredz.*` metrics, which can't be parsed by StatsD and resulted in error messages. - | Dropped `launch.*` metrics that can't be parsed by statsd, as the resulting statsd errors caused collectd logs to grow rapidly in size. changes: - - If a site administrator provides an invalid configuration for blob storage for GitHub Actions or GitHub Packages on an instance, the preflight checks page displays details and troubleshooting information. + - If a site administrator provides an invalid configuration for blob storage for GitHub Actions or GitHub Packages on an instance, the preflight checks page displays details and troubleshooting information. known_issues: - | {% data reusables.release-notes.enterprise-backup-utils-encryption-keys %} diff --git a/data/release-notes/enterprise-server/3-8/2.yml b/data/release-notes/enterprise-server/3-8/2.yml index 41b39f77d1..1e91516929 100644 --- a/data/release-notes/enterprise-server/3-8/2.yml +++ b/data/release-notes/enterprise-server/3-8/2.yml @@ -1,27 +1,30 @@ date: '2023-04-18' sections: + security_fixes: + - | + **MEDIUM**: An attacker with write access to a repository could craft a pull request that would hide commits made in its source branch. This vulnerability was reported via the [GitHub Bug Bounty Program](https://bounty.github.com/) and has been assigned [CVE-2023-23764](https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2023-23764). [Updated: 2023-07-26] bugs: - | On an instance with GitHub Actions enabled, nested calls to reusable workflows within a reusable workflow job with a matrix correctly evaluate contexts within expressions, like `strategy: {% raw %}${{ inputs.strategies }}{% endraw %}`. - - Download requests for Git LFS objects did not complete until reporting the final download size, which affected the latency of these requests, particularly on an instance with nodes functioning as repository caches. - - On an instance in a high availability configuration, a `git push` operation could fail if GitHub Enterprise Server was simultaneously creating the repository on a replica node. + - Download requests for Git LFS objects did not complete until reporting the final download size, which affected the latency of these requests, particularly on an instance with nodes functioning as repository caches. + - On an instance in a high availability configuration, a `git push` operation could fail if GitHub Enterprise Server was simultaneously creating the repository on a replica node. - | - When a site administrator ran `ghe-btop` via SSH, the command did not run and a `/usr/bin/env: python3: No such file or directory` error occurred. - - Site administrators who prepared to enable GitHub Actions could not run the `ghe-actions-precheck` utility because the scripts file was not executable. - - In some cases on an instance with a GitHub Advanced Security license, users could not load the security analysis page and saw a `500` error. - - On an instance with GitHub Connect enabled, if "Users can search GitHub.com" was enabled, issues in private and internal repositories were not included in users search results for GitHub.com. - - After restoration of a deleted organization, the organization did not appear in the instance's list of organizations. + When a site administrator ran `ghe-btop` via SSH, the command did not run and a `/usr/bin/env: python3: No such file or directory` error occurred. + - Site administrators who prepared to enable GitHub Actions could not run the `ghe-actions-precheck` utility because the scripts file was not executable. + - In some cases on an instance with a GitHub Advanced Security license, users could not load the security analysis page and saw a `500` error. + - On an instance with GitHub Connect enabled, if "Users can search GitHub.com" was enabled, issues in private and internal repositories were not included in users search results for GitHub.com. + - After restoration of a deleted organization, the organization did not appear in the instance's list of organizations. - | - After a site administrator exported a migration archive to AWS S3 using GitHub Enterprise Importer's `gh-migrator` utility, the URL for the archive was inaccessible. + After a site administrator exported a migration archive to AWS S3 using GitHub Enterprise Importer's `gh-migrator` utility, the URL for the archive was inaccessible. - | - If a site administrator exported a migration archive to a bucket in AWS S3s us-east-1 region using GitHub Enterprise Importer's `gh-migrator` utility, the archive was inaccessible. + If a site administrator exported a migration archive to a bucket in AWS S3s us-east-1 region using GitHub Enterprise Importer's `gh-migrator` utility, the archive was inaccessible. - | - Collectd logs could grow rapidly in size due to the inclusion of `kredz.*` metrics, which can't be parsed by StatsD and resulted in error messages. + Collectd logs could grow rapidly in size due to the inclusion of `kredz.*` metrics, which can't be parsed by StatsD and resulted in error messages. changes: - - If a site administrator provides an invalid configuration for blob storage for GitHub Actions or GitHub Packages on an instance, the preflight checks page displays details and troubleshooting information. + - If a site administrator provides an invalid configuration for blob storage for GitHub Actions or GitHub Packages on an instance, the preflight checks page displays details and troubleshooting information. - | - After a site administrator exports a migration archive using GitHub Enterprise Importer's `gh-migrator` utility, the link to the archive remains accessible for 48 hours instead of one hour. - - On an instance with a GitHub Advanced Security license, users who author custom patterns for secret scanning can provide expressions that must or must not match that are up to 2,000 characters. This limit is an increase from 1,000 characters. + After a site administrator exports a migration archive using GitHub Enterprise Importer's `gh-migrator` utility, the link to the archive remains accessible for 48 hours instead of one hour. + - On an instance with a GitHub Advanced Security license, users who author custom patterns for secret scanning can provide expressions that must or must not match that are up to 2,000 characters. This limit is an increase from 1,000 characters. known_issues: - | {% data reusables.release-notes.enterprise-backup-utils-encryption-keys %} diff --git a/data/release-notes/enterprise-server/3-9/1.yml b/data/release-notes/enterprise-server/3-9/1.yml index 81338271c1..b4f16b101c 100644 --- a/data/release-notes/enterprise-server/3-9/1.yml +++ b/data/release-notes/enterprise-server/3-9/1.yml @@ -2,93 +2,95 @@ date: '2023-07-18' sections: security_fixes: - | - An attacker with access to the password hash of the root site administrator user for the instance's Management Console could make requests to the password API endpoint from outside of the instance. + **MEDIUM**: An attacker with write access to a repository could craft a pull request that would hide commits made in its source branch. This vulnerability was reported via the [GitHub Bug Bounty Program](https://bounty.github.com/) and has been assigned [CVE-2023-23764](https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2023-23764). [Updated: 2023-07-26] - | - Packages have been updated to the latest security versions. + An attacker with access to the password hash of the root site administrator user for the instance's Management Console could make requests to the password API endpoint from outside of the instance. + - | + Packages have been updated to the latest security versions. bugs: - | - In some cases, users could reopen a pull request that should not have been able to be reopened. + In some cases, users could reopen a pull request that should not have been able to be reopened. - | - If MinIO was configured for external blob storage on an instance with GitHub Actions enabled and MinIO was configured for bucket replication, the instance's credential validation with MinIO would occasionally fail. + If MinIO was configured for external blob storage on an instance with GitHub Actions enabled and MinIO was configured for bucket replication, the instance's credential validation with MinIO would occasionally fail. - | - Customers who use Azure Blob store as the remote blob provider to back GitHub Packages would have validation errors if the `EndpointSuffix` part of their Connection string was anything other than `core.windows.net`. Now all valid `EndpointSuffix` are accepted. + Customers who use Azure Blob store as the remote blob provider to back GitHub Packages would have validation errors if the `EndpointSuffix` part of their Connection string was anything other than `core.windows.net`. Now all valid `EndpointSuffix` are accepted. - | - When a user viewed a Jupyter notebook, GitHub Enterprise Server returned a `500` error code if the instance was configured with a self-signed TLS certificate. + When a user viewed a Jupyter notebook, GitHub Enterprise Server returned a `500` error code if the instance was configured with a self-signed TLS certificate. - | - After creation of a blob object from the web UI, pre-receive hook events were missing from the instance's audit log. + After creation of a blob object from the web UI, pre-receive hook events were missing from the instance's audit log. - | - On an instance with an outbound web proxy server configured, the proxy interfered with internal operations that used `nomad alloc exec`. + On an instance with an outbound web proxy server configured, the proxy interfered with internal operations that used `nomad alloc exec`. - | - On an instance in a cluster configuration, the `ghe-cluster-balance` behaved inconsistently when displaying status or managing jobs with more than one task group. + On an instance in a cluster configuration, the `ghe-cluster-balance` behaved inconsistently when displaying status or managing jobs with more than one task group. - | - `.topojson` files would not render correctly, but files that conformed to the TopoJSON spec that used a `.geojson` extension would render correctly. + `.topojson` files would not render correctly, but files that conformed to the TopoJSON spec that used a `.geojson` extension would render correctly. - | - On an instance configured for LDAP authentication, if the LDAP server sent an empty string for the `sshPublicKey` attribute, LDAP user sync would fail. + On an instance configured for LDAP authentication, if the LDAP server sent an empty string for the `sshPublicKey` attribute, LDAP user sync would fail. - | - REST API endpoints for managing GitHub Enterprise Server are now functional. For more information, see "[Manage GitHub Enterprise Server](/rest/enterprise-admin/manage-ghes?apiVersion=2022-11-28)" in the REST API documentation. + REST API endpoints for managing GitHub Enterprise Server are now functional. For more information, see "[Manage GitHub Enterprise Server](/rest/enterprise-admin/manage-ghes?apiVersion=2022-11-28)" in the REST API documentation. - | - After creation of a new Management Console user, the Management Console did not display the button to copy the new users invitation. + After creation of a new Management Console user, the Management Console did not display the button to copy the new users invitation. - | - On an instance with Dependabot enabled, in some situations, Dependabot alerts were not updated when a user pushed to a repository. + On an instance with Dependabot enabled, in some situations, Dependabot alerts were not updated when a user pushed to a repository. - | - In some cases, pull requests with more than 25 rich-diff renderable files required that users toggle the diff type to correctly render the files over the 25-file limit. + In some cases, pull requests with more than 25 rich-diff renderable files required that users toggle the diff type to correctly render the files over the 25-file limit. - | - In rare circumstances, Git commits signed with SSH keys using the RSA algorithm would incorrectly indicate the signature was invalid. + In rare circumstances, Git commits signed with SSH keys using the RSA algorithm would incorrectly indicate the signature was invalid. - | - After a migration using GitHub Enterprise Importer, some repository autolink references were created with an incorrect format. + After a migration using GitHub Enterprise Importer, some repository autolink references were created with an incorrect format. - | - In some cases on an instance without a GitHub Advanced Security license, Redis exceeded the maximum default memory allocation, causing `500` errors for the instance's users. + In some cases on an instance without a GitHub Advanced Security license, Redis exceeded the maximum default memory allocation, causing `500` errors for the instance's users. - | - On an instance with many organizations, the enterprise security overview page returned a `500` error. + On an instance with many organizations, the enterprise security overview page returned a `500` error. - | - On an instance that was not configured to deliver email notifications using SMTP, background jobs to deliver email were enqueued unnecessarily. + On an instance that was not configured to deliver email notifications using SMTP, background jobs to deliver email were enqueued unnecessarily. - | - Users were unable to configure a SSH certificate authority for an organization. + Users were unable to configure a SSH certificate authority for an organization. - | - An erroneous "Blocked Copilot Repositories" link was visible in site admin pages for organizations. + An erroneous "Blocked Copilot Repositories" link was visible in site admin pages for organizations. - | - On an instance with GitHub Actions enabled and a GitHub Advanced Security license, repository-level runner scale sets were not accounted for when determining whether default setup for code scanning could be used. + On an instance with GitHub Actions enabled and a GitHub Advanced Security license, repository-level runner scale sets were not accounted for when determining whether default setup for code scanning could be used. - | - Events related to repository notifications did not appear in the audit log. + Events related to repository notifications did not appear in the audit log. - | - On an instance with a GitHub Advanced Security license and secret scanning enabled, in some cases, a committer would not receive an email notification for a secret scanning alert where push protections were bypassed. + On an instance with a GitHub Advanced Security license and secret scanning enabled, in some cases, a committer would not receive an email notification for a secret scanning alert where push protections were bypassed. - | - On an instance with a GitHub Advanced Security license, if a user filtered by a custom pattern on an organizations "Code & security analysis" page using an invalid query, the entire GitHub Advanced Security disappeared and an error reading "Sorry, something went wrong loading GitHub Advanced Security settings" appeared. + On an instance with a GitHub Advanced Security license, if a user filtered by a custom pattern on an organizations "Code & security analysis" page using an invalid query, the entire GitHub Advanced Security disappeared and an error reading "Sorry, something went wrong loading GitHub Advanced Security settings" appeared. - | - On an instance with a GitHub Advanced Security license, if a user browsed to the alerts page for secret scanning without signing in, the instance responded with a `500` error. + On an instance with a GitHub Advanced Security license, if a user browsed to the alerts page for secret scanning without signing in, the instance responded with a `500` error. - | - On an instance with a GitHub Advanced Security license and secret scanning enabled, output from Git for a push blocked by push protection always included an `http://` link. + On an instance with a GitHub Advanced Security license and secret scanning enabled, output from Git for a push blocked by push protection always included an `http://` link. - | - On an instance with GitHub Actions enabled, links to `http(s)://HOSTNAME/features/actions` from the web UI returned a `500` error. + On an instance with GitHub Actions enabled, links to `http(s)://HOSTNAME/features/actions` from the web UI returned a `500` error. - | - If a user added a new item to a projects roadmap view, and the item was outside of the viewport, the view would crash and display "This project failed to load". + If a user added a new item to a projects roadmap view, and the item was outside of the viewport, the view would crash and display "This project failed to load". - | - The audit log reported the incorrect target repository for pre-receive hook failures. + The audit log reported the incorrect target repository for pre-receive hook failures. - | - Users can add issues and pull requests from any organization to a project, and are no longer limited to the user or organization of the project. + Users can add issues and pull requests from any organization to a project, and are no longer limited to the user or organization of the project. - | - On an instance with GitHub Actions enabled and a GitHub Advanced Security license, enterprise-level runner scale sets with the `code-scanning` label were not sufficient to allow default setup for code scanning. + On an instance with GitHub Actions enabled and a GitHub Advanced Security license, enterprise-level runner scale sets with the `code-scanning` label were not sufficient to allow default setup for code scanning. - | - On an instance in a high availability configuration, existing nodes with out-of-sync repositories prevented new nodes from replicating those repositories. + On an instance in a high availability configuration, existing nodes with out-of-sync repositories prevented new nodes from replicating those repositories. - | - On an instance with multiple nodes, `ERROR`-level "resolver failed" errors no longer appear in system logs when the instance is unable to resolve an offline fileserver. The messages are now `DEBUG`-level. + On an instance with multiple nodes, `ERROR`-level "resolver failed" errors no longer appear in system logs when the instance is unable to resolve an offline fileserver. The messages are now `DEBUG`-level. - | - On an instance with a GitHub Advanced Security license that was also configured for a timezone greater than UTC, the list of secret scanning alerts displayed a "Loading secrets failed" error if a user sorted secrets by date in descending order. + On an instance with a GitHub Advanced Security license that was also configured for a timezone greater than UTC, the list of secret scanning alerts displayed a "Loading secrets failed" error if a user sorted secrets by date in descending order. - | - Code Scanning workflow runs now only request the `code-scanning` label so that they can be used with runner scale sets. + Code Scanning workflow runs now only request the `code-scanning` label so that they can be used with runner scale sets. - | - On an instance with subdomain isolation disabled, Mermaid diagrams in the web UI displayed an "Unable to render rich display" error and failed to render. + On an instance with subdomain isolation disabled, Mermaid diagrams in the web UI displayed an "Unable to render rich display" error and failed to render. changes: - | - On an instance in a cluster configuration, the `ghe-cluster-config-check` command-line utility will return an affirmative message when no warnings or errors are detected. The affirmative message is "Configuration validation complete. No errors found." + On an instance in a cluster configuration, the `ghe-cluster-config-check` command-line utility will return an affirmative message when no warnings or errors are detected. The affirmative message is "Configuration validation complete. No errors found." - | - During initialization of a cluster configuration, output from the `ghe-cluster-config-init` command-line utility is improved and simplified. + During initialization of a cluster configuration, output from the `ghe-cluster-config-init` command-line utility is improved and simplified. - | - The API endpoint for management of the GitHub Enterprise Server instance was unavailable prior to initial configuration of the instance. + The API endpoint for management of the GitHub Enterprise Server instance was unavailable prior to initial configuration of the instance. - | - The Management Console displays a warning about unexpected consequences that may result from modification of the instance's hostname after initial configuration. + The Management Console displays a warning about unexpected consequences that may result from modification of the instance's hostname after initial configuration. - | - On an instance with multiple nodes, internal tooling to repair repositories now attempts to resolve problems within the entire repository network. + On an instance with multiple nodes, internal tooling to repair repositories now attempts to resolve problems within the entire repository network. known_issues: - | The `mbind: Operation not permitted` error in the `/var/log/mysql/mysql.err` file can be ignored. MySQL 8 does not gracefully handle when the `CAP_SYS_NICE` capability isn't required, and outputs an error instead of a warning. From 44c6dde0c3ed816f8528122b7be98710c7daec9b Mon Sep 17 00:00:00 2001 From: Tim Rogers Date: Wed, 26 Jul 2023 14:59:59 +0100 Subject: [PATCH 02/14] Document that rulesets can disrupt GEI migrations (#39720) Co-authored-by: Laura Coursen --- .../migration-support-for-github-enterprise-importer.md | 1 + 1 file changed, 1 insertion(+) diff --git a/content/migrations/using-github-enterprise-importer/understanding-github-enterprise-importer/migration-support-for-github-enterprise-importer.md b/content/migrations/using-github-enterprise-importer/understanding-github-enterprise-importer/migration-support-for-github-enterprise-importer.md index 37a7db92eb..ddae9661ba 100644 --- a/content/migrations/using-github-enterprise-importer/understanding-github-enterprise-importer/migration-support-for-github-enterprise-importer.md +++ b/content/migrations/using-github-enterprise-importer/understanding-github-enterprise-importer/migration-support-for-github-enterprise-importer.md @@ -179,3 +179,4 @@ There are limits to what {% data variables.product.prodname_importer_proper_name - **Follow-up tasks required:** When migrating between {% data variables.product.prodname_dotcom %} products, certain settings are not migrated and must be reconfigured in the new repository. For a list of follow-up tasks you'll need to complete after each migration, see "[AUTOTITLE](/migrations/using-github-enterprise-importer/understanding-github-enterprise-importer/migrating-between-github-products-with-github-enterprise-importer#completing-follow-up-tasks)." - **Delayed code search functionality:** Re-indexing the search index can take a few hours after a repository is migrated, and code searches may return unexpected results until re-indexing is complete. - **Scheduled workflows for {% data variables.product.prodname_actions %} are not enabled post-migration**: After a migration, scheduled workflows will not run. They can be re-activated by pushing a change to the repository. For more information about scheduled workflows, see "[AUTOTITLE](/actions/using-workflows/events-that-trigger-workflows#schedule)." +- **Rulesets configured for your organization can cause migrations to fail**: For example, if you configured a rule that requires email addresses for commit authors to end with `@monalisa.cat`, and the repository you're migrating contains commits that don't comply with this rule, your migration will fail. For more information about rulesets, see "[AUTOTITLE](/enterprise-cloud@latest/repositories/configuring-branches-and-merges-in-your-repository/managing-rulesets/about-rulesets)." \ No newline at end of file From ec60ae713bbe5f17bca289cf2a1433263deb32db Mon Sep 17 00:00:00 2001 From: Jim Eagan <84857865+hibler13@users.noreply.github.com> Date: Wed, 26 Jul 2023 08:00:54 -0700 Subject: [PATCH 03/14] Minor typo fix - extra period (#27067) --- .../managing-protected-branches/about-protected-branches.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/content/repositories/configuring-branches-and-merges-in-your-repository/managing-protected-branches/about-protected-branches.md b/content/repositories/configuring-branches-and-merges-in-your-repository/managing-protected-branches/about-protected-branches.md index e1cc1a9221..97903bcdf9 100644 --- a/content/repositories/configuring-branches-and-merges-in-your-repository/managing-protected-branches/about-protected-branches.md +++ b/content/repositories/configuring-branches-and-merges-in-your-repository/managing-protected-branches/about-protected-branches.md @@ -110,7 +110,7 @@ For complex pull requests that require many reviews, requiring an approval from Required status checks ensure that all required CI tests are passing before collaborators can make changes to a protected branch. Required status checks can be checks or statuses. For more information, see "[AUTOTITLE](/pull-requests/collaborating-with-pull-requests/collaborating-on-repositories-with-code-quality-features/about-status-checks)." -You can use the commit status API to allow external services to mark commits with an appropriate status.. For more information, see "[AUTOTITLE](/rest/commits/statuses)" in the REST API documentation. +You can use the commit status API to allow external services to mark commits with an appropriate status. For more information, see "[AUTOTITLE](/rest/commits/statuses)" in the REST API documentation. After enabling required status checks, all required status checks must pass before collaborators can merge changes into the protected branch. After all required status checks pass, any commits must either be pushed to another branch and then merged or pushed directly to the protected branch. From 26584e2f9fac47a92369158a6536a946d0ffefa9 Mon Sep 17 00:00:00 2001 From: Sarah Edwards Date: Wed, 26 Jul 2023 09:14:13 -0700 Subject: [PATCH 04/14] Move content about encrypting secrets into docs-internal and out of the OpenAPI schema (#39613) --- .../encrypting-secrets-for-the-rest-api.md | 102 ++++++++++++++++++ content/rest/guides/index.md | 1 + 2 files changed, 103 insertions(+) create mode 100644 content/rest/guides/encrypting-secrets-for-the-rest-api.md diff --git a/content/rest/guides/encrypting-secrets-for-the-rest-api.md b/content/rest/guides/encrypting-secrets-for-the-rest-api.md new file mode 100644 index 0000000000..5590b5b363 --- /dev/null +++ b/content/rest/guides/encrypting-secrets-for-the-rest-api.md @@ -0,0 +1,102 @@ +--- +title: Encrypting secrets for the REST API +intro: In order to create or update a secret with the REST API, you must encrypt the value of the secret. +versions: + fpt: '*' + ghes: '*' + ghae: '*' + ghec: '*' +topics: + - API +shortTitle: Encrypt secrets +--- + +## About encrypting secrets + +Several REST API endpoints let you create secrets on {% data variables.product.company_short %}. To use these endpoints, you must encrypt the secret value using libsodium. For more information, see the [libsodium documentation](https://libsodium.gitbook.io/doc/bindings_for_other_languages). + +In order to encrypt a secret, you need a Base64 encoded public key. You can get a public key from the REST API. To determine which endpoint to use to get the public key, look at the documentation for the `encrypted_value` parameter in the endpoint that you will use to create a secret . + +## Example encrypting a secret using Node.js + +If you are using Node.js, you can encrypt your secret using the libsodium-wrappers library. For more information, see [libsodium-wrappers](https://www.npmjs.com/package/libsodium-wrappers). + +In the following example, replace `YOUR_SECRET` with the plain text value that you want to encrypt. Replace `YOUR_BASE64_KEY` with your Base64 encoded public key. The documentation for the endpoint that you will use to create a secret will tell you which endpoint you can use to get the public key. `ORIGINAL` is not a placeholder; it is a parameter for the libsodium-wrappers library. + +```javascript copy +const sodium = require('libsodium-wrappers') + +const secret = 'YOUR_SECRET' +const key = 'YOUR_BASE64_KEY' + +//Check if libsodium is ready and then proceed. +sodium.ready.then(() => { + // Convert the secret and key to a Uint8Array. + let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL) + let binsec = sodium.from_string(secret) + + // Encrypt the secret using libsodium + let encBytes = sodium.crypto_box_seal(binsec, binkey) + + // Convert the encrypted Uint8Array to Base64 + let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL) + + // Print the output + console.log(output) +}); +``` + +## Example encrypting a secret using Python + +If you are using Python 3, you can encrypt your secret using the PyNaCl library. For more information, see [PyNaCl](https://pynacl.readthedocs.io/en/latest/public/#nacl-public-sealedbox). + +In the following example, replace `YOUR_SECRET` with the plain text value that you want to encrypt. Replace `YOUR_BASE64_KEY` with your Base64 encoded public key. The documentation for the endpoint that you will use to create a secret will tell you which endpoint you can use to get the public key. + +```python copy +from base64 import b64encode +from nacl import encoding, public + +def encrypt(public_key: str, secret_value: str) -> str: + """Encrypt a Unicode string using the public key.""" + public_key = public.PublicKey(public_key.encode("utf-8"), encoding.Base64Encoder()) + sealed_box = public.SealedBox(public_key) + encrypted = sealed_box.encrypt(secret_value.encode("utf-8")) + return b64encode(encrypted).decode("utf-8") + +encrypt("YOUR_BASE64_KEY", "YOUR_SECRET") +``` + +## Example encrypting a secret using C# + +If you are using C#, you can encrypt your secret using the Sodium.Core package. For more information, see [Sodium.Core](https://www.nuget.org/packages/Sodium.Core/). + +In the following example, replace `YOUR_SECRET` with the plain text value that you want to encrypt. Replace `YOUR_BASE64_KEY` with your Base64 encoded public key. The documentation for the endpoint that you will use to create a secret will tell you which endpoint you can use to get the public key. + +```C# copy +var secretValue = System.Text.Encoding.UTF8.GetBytes("YOUR_SECRET"); +var publicKey = Convert.FromBase64String("YOUR_BASE64_KEY"); + +var sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey); + +Console.WriteLine(Convert.ToBase64String(sealedPublicKeyBox)); +``` + +## Example encrypting a secret using Ruby + +If you are using Ruby, you can encrypt your secret using the RbNaCl gem. For more information, see [RbNaCl](https://github.com/RubyCrypto/rbnacl). + +In the following example, replace `YOUR_SECRET` with the plain text value that you want to encrypt. Replace `YOUR_BASE64_KEY` with your Base64 encoded public key. The documentation for the endpoint that you will use to create a secret will tell you which endpoint you can use to get the public key. + +```ruby copy +require "rbnacl" +require "base64" + +key = Base64.decode64("YOUR_BASE64_KEY") +public_key = RbNaCl::PublicKey.new(key) + +box = RbNaCl::Boxes::Sealed.from_public_key(public_key) +encrypted_secret = box.encrypt("YOUR_SECRET") + +# Print the base64 encoded secret +puts Base64.strict_encode64(encrypted_secret) +``` diff --git a/content/rest/guides/index.md b/content/rest/guides/index.md index a8334bd4c1..63b8819439 100644 --- a/content/rest/guides/index.md +++ b/content/rest/guides/index.md @@ -23,6 +23,7 @@ children: - /best-practices-for-integrators - /using-the-rest-api-to-interact-with-your-git-database - /using-the-rest-api-to-interact-with-checks + - /encrypting-secrets-for-the-rest-api --- This section of the documentation is intended to get you up-and-running with real-world {% ifversion fpt or ghec %}{% data variables.product.prodname_dotcom %}{% else %}{% data variables.product.product_name %}{% endif %} API applications. We'll go over everything you need to know, from authentication to results manipulation to integrating results with other apps. From b46bc125c33a3e1ed7b5d51513fa060e0e5f25d6 Mon Sep 17 00:00:00 2001 From: Kevin Heis Date: Wed, 26 Jul 2023 09:22:13 -0700 Subject: [PATCH 05/14] A11y: scroll top all the things (#39736) --- components/release-notes/GHAEReleaseNotePatch.tsx | 5 +---- components/release-notes/GHESReleaseNotePatch.tsx | 5 +---- components/release-notes/PatchNotes.module.scss | 8 -------- components/release-notes/PatchNotes.tsx | 4 +--- .../components/guides/LearningTrack.module.scss | 7 ------- src/learning-track/components/guides/LearningTrack.tsx | 5 +---- stylesheets/headings.scss | 5 ----- stylesheets/index.scss | 1 + stylesheets/scroll-top.scss | 10 ++++++++++ 9 files changed, 15 insertions(+), 35 deletions(-) create mode 100644 stylesheets/scroll-top.scss diff --git a/components/release-notes/GHAEReleaseNotePatch.tsx b/components/release-notes/GHAEReleaseNotePatch.tsx index 21fba9f26b..e0167c5d90 100644 --- a/components/release-notes/GHAEReleaseNotePatch.tsx +++ b/components/release-notes/GHAEReleaseNotePatch.tsx @@ -1,13 +1,10 @@ import { useRef } from 'react' import dayjs from 'dayjs' -import cx from 'classnames' import { useTranslation } from 'components/hooks/useTranslation' import { PatchNotes } from './PatchNotes' import { CurrentVersion, ReleaseNotePatch } from './types' -import styles from './PatchNotes.module.scss' - type Props = { patch: ReleaseNotePatch; currentVersion: CurrentVersion } export function GHAEReleaseNotePatch({ patch, currentVersion }: Props) { const { t } = useTranslation('release_notes') @@ -15,7 +12,7 @@ export function GHAEReleaseNotePatch({ patch, currentVersion }: Props) { const bannerText = t('banner_text') return ( -
+
(null) return ( -
+
= { features: 'Features', bugs: 'Bug fixes', @@ -40,7 +38,7 @@ export function PatchNotes({ patch }: Props) { const headingSlug = item.heading ? slug(item.heading) : `heading${i}` return (
  • -

    +

    {item.heading}

      diff --git a/src/learning-track/components/guides/LearningTrack.module.scss b/src/learning-track/components/guides/LearningTrack.module.scss index 9aa8ef1c26..9a798b42d0 100644 --- a/src/learning-track/components/guides/LearningTrack.module.scss +++ b/src/learning-track/components/guides/LearningTrack.module.scss @@ -5,10 +5,3 @@ .removeHoverEvents { pointer-events: none; } - -/* Because of the sticky header */ -.hashAnchor { - &:target { - scroll-margin-top: 75px; - } -} diff --git a/src/learning-track/components/guides/LearningTrack.tsx b/src/learning-track/components/guides/LearningTrack.tsx index b86e7d5bcb..d2b834e40b 100644 --- a/src/learning-track/components/guides/LearningTrack.tsx +++ b/src/learning-track/components/guides/LearningTrack.tsx @@ -28,10 +28,7 @@ export const LearningTrack = ({ track }: Props) => {
      -

      +

      {track?.title} diff --git a/stylesheets/headings.scss b/stylesheets/headings.scss index a92078740f..eaded13773 100644 --- a/stylesheets/headings.scss +++ b/stylesheets/headings.scss @@ -8,9 +8,4 @@ h6 { color: unset; text-decoration: none; } - - // Lower because of the sticky header - &:target { - scroll-margin-top: 75px; - } } diff --git a/stylesheets/index.scss b/stylesheets/index.scss index 925cb7d98c..4b941124d3 100644 --- a/stylesheets/index.scss +++ b/stylesheets/index.scss @@ -14,6 +14,7 @@ @import "headings.scss"; @import "markdown-overrides.scss"; @import "images.scss"; +@import "scroll-top.scss"; // Components @import "heading-links.scss"; diff --git a/stylesheets/scroll-top.scss b/stylesheets/scroll-top.scss new file mode 100644 index 0000000000..5e6b70bf08 --- /dev/null +++ b/stylesheets/scroll-top.scss @@ -0,0 +1,10 @@ +// https://tetralogical.com/blog/2023/06/08/focus-in-view/ + +html, +body { + scroll-padding-top: 105px !important; // 88 + 8 + 8 + 1 + + @include breakpoint(xl) { + scroll-padding-top: 65px !important; // 48 + 8 + 8 + 1 + } +} From 232c6e178df448b0743d0635c659e74f9e9ec4b3 Mon Sep 17 00:00:00 2001 From: Matyas Sandor <53257021+sandormatyas@users.noreply.github.com> Date: Wed, 26 Jul 2023 18:31:10 +0200 Subject: [PATCH 06/14] Update release_properties.md (#27059) --- data/reusables/webhooks/release_properties.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/data/reusables/webhooks/release_properties.md b/data/reusables/webhooks/release_properties.md index 5232b3ea8d..8b6f8e511a 100644 --- a/data/reusables/webhooks/release_properties.md +++ b/data/reusables/webhooks/release_properties.md @@ -1,3 +1,3 @@ `changes[body][from]` |`string` | The previous version of the body if the action was `edited`. `changes[name][from]` |`string` | The previous version of the name if the action was `edited`. -`release`|`object` | The [release](/rest/repos#get-a-release) object. +`release`|`object` | The [release](/rest/releases/releases#get-a-release) object. From fe04d3619a83c7d6d3b146c67d5d4333e0d49c77 Mon Sep 17 00:00:00 2001 From: Peter Bengtsson Date: Wed, 26 Jul 2023 12:33:16 -0400 Subject: [PATCH 07/14] Remove hand-picked no-dupe-IDs on rest pages (#39733) --- src/rest/tests/rendering.js | 30 ------------------------------ 1 file changed, 30 deletions(-) diff --git a/src/rest/tests/rendering.js b/src/rest/tests/rendering.js index 4e47c84448..da79c77e87 100644 --- a/src/rest/tests/rendering.js +++ b/src/rest/tests/rendering.js @@ -118,36 +118,6 @@ describe('REST references docs', () => { } } }) - - describe('headings', () => { - test('rest pages do not render any headings with duplicate text', async () => { - const $ = await getDOM('/en/rest/actions/artifacts') - const headingText = $('body') - .find('h2, h3, h4, h5, h6') - .map((i, el) => $(el).text()) - .get() - .sort() - - const dupes = headingText.filter((item, index) => headingText.indexOf(item) !== index) - - const message = `The following duplicate heading texts were found: ${dupes.join(', ')}` - expect(dupes.length, message).toBe(0) - }) - - test('rest pages do not render any headings with duplicate ids', async () => { - const $ = await getDOM('/en/rest/actions/artifacts') - const headingIDs = $('body') - .find('h2, h3, h4, h5, h6') - .map((i, el) => $(el).attr('id')) - .get() - .sort() - - const dupes = headingIDs.filter((item, index) => headingIDs.indexOf(item) !== index) - - const message = `The following duplicate heading IDs were found: ${dupes.join(', ')}` - expect(dupes.length, message).toBe(0) - }) - }) }) function formatErrors(differences) { From 012beafe1b17fd687bf58e9dfbeed0f316191235 Mon Sep 17 00:00:00 2001 From: docs-bot <77750099+docs-bot@users.noreply.github.com> Date: Wed, 26 Jul 2023 09:42:25 -0700 Subject: [PATCH 08/14] Update OpenAPI Description (#39737) --- .../fine-grained-pat-permissions.json | 9 + .../data/fpt-2022-11-28/fine-grained-pat.json | 6 + .../server-to-server-permissions.json | 11 + .../fpt-2022-11-28/server-to-server-rest.json | 6 + .../fpt-2022-11-28/user-to-server-rest.json | 6 + .../fine-grained-pat-permissions.json | 9 + .../ghec-2022-11-28/fine-grained-pat.json | 6 + .../server-to-server-permissions.json | 11 + .../server-to-server-rest.json | 6 + .../ghec-2022-11-28/user-to-server-rest.json | 6 + src/github-apps/lib/config.json | 2 +- src/rest/data/fpt-2022-11-28/schema.json | 567 ++++++++++++++--- src/rest/data/ghae/schema.json | 60 +- src/rest/data/ghec-2022-11-28/schema.json | 569 +++++++++++++++--- src/rest/data/ghes-3.6/schema.json | 92 +-- src/rest/data/ghes-3.7/schema.json | 92 +-- src/rest/data/ghes-3.8/schema.json | 130 ++-- src/rest/data/ghes-3.9-2022-11-28/schema.json | 134 ++--- src/rest/lib/config.json | 2 +- src/webhooks/lib/config.json | 2 +- 20 files changed, 1328 insertions(+), 398 deletions(-) diff --git a/src/github-apps/data/fpt-2022-11-28/fine-grained-pat-permissions.json b/src/github-apps/data/fpt-2022-11-28/fine-grained-pat-permissions.json index fa4e992dec..6da1fcdbf7 100644 --- a/src/github-apps/data/fpt-2022-11-28/fine-grained-pat-permissions.json +++ b/src/github-apps/data/fpt-2022-11-28/fine-grained-pat-permissions.json @@ -3472,6 +3472,15 @@ "title": "Contents", "displayTitle": "Repository permissions for \"Contents\"", "permissions": [ + { + "category": "repos", + "slug": "list-repository-activities", + "subcategory": "repos", + "verb": "get", + "requestPath": "/repos/{owner}/{repo}/activity", + "additional-permissions": [], + "access": "read" + }, { "category": "branches", "slug": "list-branches", diff --git a/src/github-apps/data/fpt-2022-11-28/fine-grained-pat.json b/src/github-apps/data/fpt-2022-11-28/fine-grained-pat.json index 41886981fc..3023ece748 100644 --- a/src/github-apps/data/fpt-2022-11-28/fine-grained-pat.json +++ b/src/github-apps/data/fpt-2022-11-28/fine-grained-pat.json @@ -3746,6 +3746,12 @@ "verb": "delete", "requestPath": "/repos/{owner}/{repo}" }, + { + "slug": "list-repository-activities", + "subcategory": "repos", + "verb": "get", + "requestPath": "/repos/{owner}/{repo}/activity" + }, { "slug": "list-all-autolinks-of-a-repository", "subcategory": "autolinks", diff --git a/src/github-apps/data/fpt-2022-11-28/server-to-server-permissions.json b/src/github-apps/data/fpt-2022-11-28/server-to-server-permissions.json index e85aecc227..03da3f7e38 100644 --- a/src/github-apps/data/fpt-2022-11-28/server-to-server-permissions.json +++ b/src/github-apps/data/fpt-2022-11-28/server-to-server-permissions.json @@ -4290,6 +4290,17 @@ "title": "Contents", "displayTitle": "Repository permissions for \"Contents\"", "permissions": [ + { + "category": "repos", + "slug": "list-repository-activities", + "subcategory": "repos", + "verb": "get", + "requestPath": "/repos/{owner}/{repo}/activity", + "access": "read", + "user-to-server": true, + "server-to-server": true, + "additional-permissions": [] + }, { "category": "branches", "slug": "list-branches", diff --git a/src/github-apps/data/fpt-2022-11-28/server-to-server-rest.json b/src/github-apps/data/fpt-2022-11-28/server-to-server-rest.json index c32622a6bb..4bfc9853a1 100644 --- a/src/github-apps/data/fpt-2022-11-28/server-to-server-rest.json +++ b/src/github-apps/data/fpt-2022-11-28/server-to-server-rest.json @@ -3382,6 +3382,12 @@ "verb": "delete", "requestPath": "/repos/{owner}/{repo}" }, + { + "slug": "list-repository-activities", + "subcategory": "repos", + "verb": "get", + "requestPath": "/repos/{owner}/{repo}/activity" + }, { "slug": "list-all-autolinks-of-a-repository", "subcategory": "autolinks", diff --git a/src/github-apps/data/fpt-2022-11-28/user-to-server-rest.json b/src/github-apps/data/fpt-2022-11-28/user-to-server-rest.json index 0f1efc67ff..58462b7e22 100644 --- a/src/github-apps/data/fpt-2022-11-28/user-to-server-rest.json +++ b/src/github-apps/data/fpt-2022-11-28/user-to-server-rest.json @@ -3812,6 +3812,12 @@ "verb": "delete", "requestPath": "/repos/{owner}/{repo}" }, + { + "slug": "list-repository-activities", + "subcategory": "repos", + "verb": "get", + "requestPath": "/repos/{owner}/{repo}/activity" + }, { "slug": "list-all-autolinks-of-a-repository", "subcategory": "autolinks", diff --git a/src/github-apps/data/ghec-2022-11-28/fine-grained-pat-permissions.json b/src/github-apps/data/ghec-2022-11-28/fine-grained-pat-permissions.json index 650e8b0513..093e5ee252 100644 --- a/src/github-apps/data/ghec-2022-11-28/fine-grained-pat-permissions.json +++ b/src/github-apps/data/ghec-2022-11-28/fine-grained-pat-permissions.json @@ -4031,6 +4031,15 @@ "title": "Contents", "displayTitle": "Repository permissions for \"Contents\"", "permissions": [ + { + "category": "repos", + "slug": "list-repository-activities", + "subcategory": "repos", + "verb": "get", + "requestPath": "/repos/{owner}/{repo}/activity", + "additional-permissions": [], + "access": "read" + }, { "category": "branches", "slug": "list-branches", diff --git a/src/github-apps/data/ghec-2022-11-28/fine-grained-pat.json b/src/github-apps/data/ghec-2022-11-28/fine-grained-pat.json index 199c7efbb1..32c337f821 100644 --- a/src/github-apps/data/ghec-2022-11-28/fine-grained-pat.json +++ b/src/github-apps/data/ghec-2022-11-28/fine-grained-pat.json @@ -3996,6 +3996,12 @@ "verb": "delete", "requestPath": "/repos/{owner}/{repo}" }, + { + "slug": "list-repository-activities", + "subcategory": "repos", + "verb": "get", + "requestPath": "/repos/{owner}/{repo}/activity" + }, { "slug": "list-all-autolinks-of-a-repository", "subcategory": "autolinks", diff --git a/src/github-apps/data/ghec-2022-11-28/server-to-server-permissions.json b/src/github-apps/data/ghec-2022-11-28/server-to-server-permissions.json index cbcc649795..da4c5c3869 100644 --- a/src/github-apps/data/ghec-2022-11-28/server-to-server-permissions.json +++ b/src/github-apps/data/ghec-2022-11-28/server-to-server-permissions.json @@ -4980,6 +4980,17 @@ "title": "Contents", "displayTitle": "Repository permissions for \"Contents\"", "permissions": [ + { + "category": "repos", + "slug": "list-repository-activities", + "subcategory": "repos", + "verb": "get", + "requestPath": "/repos/{owner}/{repo}/activity", + "access": "read", + "user-to-server": true, + "server-to-server": true, + "additional-permissions": [] + }, { "category": "branches", "slug": "list-branches", diff --git a/src/github-apps/data/ghec-2022-11-28/server-to-server-rest.json b/src/github-apps/data/ghec-2022-11-28/server-to-server-rest.json index db7732cbcc..3d3f9576a2 100644 --- a/src/github-apps/data/ghec-2022-11-28/server-to-server-rest.json +++ b/src/github-apps/data/ghec-2022-11-28/server-to-server-rest.json @@ -3632,6 +3632,12 @@ "verb": "delete", "requestPath": "/repos/{owner}/{repo}" }, + { + "slug": "list-repository-activities", + "subcategory": "repos", + "verb": "get", + "requestPath": "/repos/{owner}/{repo}/activity" + }, { "slug": "list-all-autolinks-of-a-repository", "subcategory": "autolinks", diff --git a/src/github-apps/data/ghec-2022-11-28/user-to-server-rest.json b/src/github-apps/data/ghec-2022-11-28/user-to-server-rest.json index d3de62f4c0..2396c7dd3a 100644 --- a/src/github-apps/data/ghec-2022-11-28/user-to-server-rest.json +++ b/src/github-apps/data/ghec-2022-11-28/user-to-server-rest.json @@ -4062,6 +4062,12 @@ "verb": "delete", "requestPath": "/repos/{owner}/{repo}" }, + { + "slug": "list-repository-activities", + "subcategory": "repos", + "verb": "get", + "requestPath": "/repos/{owner}/{repo}/activity" + }, { "slug": "list-all-autolinks-of-a-repository", "subcategory": "autolinks", diff --git a/src/github-apps/lib/config.json b/src/github-apps/lib/config.json index c1cd70592d..3362153ca3 100644 --- a/src/github-apps/lib/config.json +++ b/src/github-apps/lib/config.json @@ -60,5 +60,5 @@ "2022-11-28" ] }, - "sha": "a57e233e49ce02b9c7445b38c8d8c920c95dddfd" + "sha": "8482a8d60da584a11eb150f7849ad78b2f58aadd" } \ No newline at end of file diff --git a/src/rest/data/fpt-2022-11-28/schema.json b/src/rest/data/fpt-2022-11-28/schema.json index a761630f9b..b4100997b8 100644 --- a/src/rest/data/fpt-2022-11-28/schema.json +++ b/src/rest/data/fpt-2022-11-28/schema.json @@ -599,7 +599,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a redirect URL to download an archive for a repository. This URL expires after 1 minute. Look for Location: in\nthe response header to find the URL for the download. The :archive_format must be zip. Anyone with read access to\nthe repository can use this endpoint. If the repository is private you must use an access token with the repo scope.\nGitHub Apps must have the actions:read permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a redirect URL to download an archive for a repository. This URL expires after 1 minute. Look for Location: in\nthe response header to find the URL for the download. The :archive_format must be zip.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the actions:read permission to use this endpoint.

      ", "statusCodes": [ { "httpStatusCode": "302", @@ -5006,7 +5006,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all secrets available in an organization without revealing their encrypted values. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all secrets available in an organization without revealing their\nencrypted values.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -5105,7 +5105,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets your public key, which you need to encrypt secrets. You need to encrypt a secret before you can create or update secrets. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets your public key, which you need to encrypt secrets. You need to\nencrypt a secret before you can create or update secrets.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -5212,7 +5212,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a single organization secret without revealing its encrypted value. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a single organization secret without revealing its encrypted value.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -5342,7 +5342,7 @@ } ], "previews": [], - "descriptionHTML": "

      Creates or updates an organization secret with an encrypted value. Encrypt your secret using\nLibSodium. You must authenticate using an access\ntoken with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to\nuse this endpoint.

      \n

      *Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", + "descriptionHTML": "

      Creates or updates an organization secret with an encrypted value. Encrypt your secret using\nLibSodium.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      \n

      *Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -5401,7 +5401,7 @@ } ], "previews": [], - "descriptionHTML": "

      Deletes a secret in an organization using the secret name. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Deletes a secret in an organization using the secret name.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -6368,7 +6368,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all repositories that have been selected when the visibility for repository access to a secret is set to selected. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all repositories that have been selected when the visibility\nfor repository access to a secret is set to selected.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -6437,7 +6437,7 @@ } ], "previews": [], - "descriptionHTML": "

      Replaces all repositories for an organization secret when the visibility for repository access is set to selected. The visibility is set when you Create or update an organization secret. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Replaces all repositories for an organization secret when the visibility\nfor repository access is set to selected. The visibility is set when you Create\nor update an organization secret.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -6502,7 +6502,7 @@ } ], "previews": [], - "descriptionHTML": "

      Adds a repository to an organization secret when the visibility for repository access is set to selected. The visibility is set when you Create or update an organization secret. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Adds a repository to an organization secret when the visibility for\nrepository access is set to selected. The visibility is set when you Create or\nupdate an organization secret.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -6571,7 +6571,7 @@ } ], "previews": [], - "descriptionHTML": "

      Removes a repository from an organization secret when the visibility for repository access is set to selected. The visibility is set when you Create or update an organization secret. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Removes a repository from an organization secret when the visibility\nfor repository access is set to selected. The visibility is set when you Create\nor update an organization secret.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -6706,7 +6706,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all organization secrets shared with a repository without revealing their encrypted values. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all organization secrets shared with a repository without revealing their encrypted\nvalues.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -6837,7 +6837,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all secrets available in a repository without revealing their encrypted values. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all secrets available in a repository without revealing their encrypted\nvalues.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -6946,7 +6946,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets your public key, which you need to encrypt secrets. You need to encrypt a secret before you can create or update secrets. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the repo scope. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets your public key, which you need to encrypt secrets. You need to\nencrypt a secret before you can create or update secrets.

      \n

      Anyone with read access to the repository can use this endpoint.\nIf the repository is private you must use an access token with the repo scope.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -7044,7 +7044,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a single repository secret without revealing its encrypted value. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a single repository secret without revealing its encrypted value.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -7157,7 +7157,7 @@ } ], "previews": [], - "descriptionHTML": "

      Creates or updates a repository secret with an encrypted value. Encrypt your secret using\nLibSodium. You must authenticate using an access\ntoken with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use\nthis endpoint.

      \n

      Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", + "descriptionHTML": "

      Creates or updates a repository secret with an encrypted value. Encrypt your secret using\nLibSodium.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      \n

      Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -7226,7 +7226,7 @@ } ], "previews": [], - "descriptionHTML": "

      Deletes a secret in a repository using the secret name. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Deletes a secret in a repository using the secret name.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -7357,7 +7357,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all secrets available in an environment without revealing their encrypted values. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all secrets available in an environment without revealing their\nencrypted values.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -7466,7 +7466,7 @@ } ], "previews": [], - "descriptionHTML": "

      Get the public key for an environment, which you need to encrypt environment secrets. You need to encrypt a secret before you can create or update secrets. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the repo scope. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Get the public key for an environment, which you need to encrypt environment\nsecrets. You need to encrypt a secret before you can create or update secrets.

      \n

      Anyone with read access to the repository can use this endpoint.\nIf the repository is private you must use an access token with the repo scope.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -7564,7 +7564,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a single environment secret without revealing its encrypted value. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a single environment secret without revealing its encrypted value.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -7679,7 +7679,7 @@ } ], "previews": [], - "descriptionHTML": "

      Creates or updates an environment secret with an encrypted value. Encrypt your secret using\nLibSodium. You must authenticate using an access\ntoken with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use\nthis endpoint.

      \n

      Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", + "descriptionHTML": "

      Creates or updates an environment secret with an encrypted value. Encrypt your secret using\nLibSodium.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      \n

      Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -7748,7 +7748,7 @@ } ], "previews": [], - "descriptionHTML": "

      Deletes a secret in an environment using the secret name. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Deletes a secret in an environment using the secret name.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -7969,7 +7969,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all self-hosted runners configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists all self-hosted runners configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -8082,7 +8082,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists binaries for the runner application that you can download and run.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists binaries for the runner application that you can download and run.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -8296,7 +8296,7 @@ } ], "previews": [], - "descriptionHTML": "

      Generates a configuration that can be passed to the runner application at startup.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Generates a configuration that can be passed to the runner application at startup.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -9879,7 +9879,7 @@ } ], "previews": [], - "descriptionHTML": "

      Returns a token that you can pass to the config script. The token expires after one hour.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      \n

      Example using registration token:

      \n

      Configure your self-hosted runner, replacing TOKEN with the registration token provided by this endpoint.

      \n
      ./config.sh --url https://github.com/octo-org --token TOKEN\n
      ", + "descriptionHTML": "

      Returns a token that you can pass to the config script. The token expires after one hour.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      \n

      Example using registration token:

      \n

      Configure your self-hosted runner, replacing TOKEN with the registration token provided by this endpoint.

      \n
      ./config.sh --url https://github.com/octo-org --token TOKEN\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -11454,7 +11454,7 @@ } ], "previews": [], - "descriptionHTML": "

      Returns a token that you can pass to the config script to remove a self-hosted runner from an organization. The token expires after one hour.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      \n

      Example using remove token:

      \n

      To remove your self-hosted runner from an organization, replace TOKEN with the remove token provided by this\nendpoint.

      \n
      ./config.sh remove --token TOKEN\n
      ", + "descriptionHTML": "

      Returns a token that you can pass to the config script to remove a self-hosted runner from an organization. The token expires after one hour.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      \n

      Example using remove token:

      \n

      To remove your self-hosted runner from an organization, replace TOKEN with the remove token provided by this\nendpoint.

      \n
      ./config.sh remove --token TOKEN\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -11621,7 +11621,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a specific self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Gets a specific self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -11676,7 +11676,7 @@ } ], "previews": [], - "descriptionHTML": "

      Forces the removal of a self-hosted runner from an organization. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Forces the removal of a self-hosted runner from an organization. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -11798,7 +11798,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all labels for a self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists all labels for a self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -11939,7 +11939,7 @@ } ], "previews": [], - "descriptionHTML": "

      Add custom labels to a self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Add custom labels to a self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -12084,7 +12084,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove all previous custom labels and set the new custom labels for a specific\nself-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Remove all previous custom labels and set the new custom labels for a specific\nself-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -12209,7 +12209,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove all custom labels from a self-hosted runner configured in an\norganization. Returns the remaining read-only labels from the runner.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Remove all custom labels from a self-hosted runner configured in an\norganization. Returns the remaining read-only labels from the runner.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -12345,7 +12345,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove a custom label from a self-hosted runner configured\nin an organization. Returns the remaining labels from the runner.

      \n

      This endpoint returns a 404 Not Found status if the custom label is not\npresent on the runner.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Remove a custom label from a self-hosted runner configured\nin an organization. Returns the remaining labels from the runner.

      \n

      This endpoint returns a 404 Not Found status if the custom label is not\npresent on the runner.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -12582,7 +12582,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all self-hosted runners configured in a repository. You must authenticate using an access token with the repo scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists all self-hosted runners configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -12705,7 +12705,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists binaries for the runner application that you can download and run.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists binaries for the runner application that you can download and run.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -12929,7 +12929,7 @@ } ], "previews": [], - "descriptionHTML": "

      Generates a configuration that can be passed to the runner application at startup.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.

      ", + "descriptionHTML": "

      Generates a configuration that can be passed to the runner application at startup.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -14522,7 +14522,7 @@ } ], "previews": [], - "descriptionHTML": "

      Returns a token that you can pass to the config script. The token expires after one hour. You must authenticate using an access token with the repo scope to use this endpoint.

      \n

      Example using registration token:

      \n

      Configure your self-hosted runner, replacing TOKEN with the registration token provided by this endpoint.

      \n
      ./config.sh --url https://github.com/octo-org/octo-repo-artifacts --token TOKEN\n
      ", + "descriptionHTML": "

      Returns a token that you can pass to the config script. The token\nexpires after one hour.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      \n

      Example using registration token:

      \n

      Configure your self-hosted runner, replacing TOKEN with the registration token provided\nby this endpoint.

      \n

      config.sh --url https://github.com/octo-org/octo-repo-artifacts --token TOKEN

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -16107,7 +16107,7 @@ } ], "previews": [], - "descriptionHTML": "

      Returns a token that you can pass to remove a self-hosted runner from a repository. The token expires after one hour.\nYou must authenticate using an access token with the repo scope to use this endpoint.

      \n

      Example using remove token:

      \n

      To remove your self-hosted runner from a repository, replace TOKEN with the remove token provided by this endpoint.

      \n
      ./config.sh remove --token TOKEN\n
      ", + "descriptionHTML": "

      Returns a token that you can pass to remove a self-hosted runner from\na repository. The token expires after one hour.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      \n

      Example using remove token:

      \n

      To remove your self-hosted runner from a repository, replace TOKEN with\nthe remove token provided by this endpoint.

      \n

      config.sh remove --token TOKEN

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -16284,7 +16284,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a specific self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Gets a specific self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -16349,7 +16349,7 @@ } ], "previews": [], - "descriptionHTML": "

      Forces the removal of a self-hosted runner from a repository. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.

      \n

      You must authenticate using an access token with the repo\nscope to use this endpoint.

      ", + "descriptionHTML": "

      Forces the removal of a self-hosted runner from a repository. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -16481,7 +16481,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all labels for a self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Lists all labels for a self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -16632,7 +16632,7 @@ } ], "previews": [], - "descriptionHTML": "

      Add custom labels to a self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Add custom labels to a self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -16787,7 +16787,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove all previous custom labels and set the new custom labels for a specific\nself-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Remove all previous custom labels and set the new custom labels for a specific\nself-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -16922,7 +16922,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove all custom labels from a self-hosted runner configured in a\nrepository. Returns the remaining read-only labels from the runner.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Remove all custom labels from a self-hosted runner configured in a\nrepository. Returns the remaining read-only labels from the runner.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -17068,7 +17068,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove a custom label from a self-hosted runner configured\nin a repository. Returns the remaining labels from the runner.

      \n

      This endpoint returns a 404 Not Found status if the custom label is not\npresent on the runner.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Remove a custom label from a self-hosted runner configured\nin a repository. Returns the remaining labels from the runner.

      \n

      This endpoint returns a 404 Not Found status if the custom label is not\npresent on the runner.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -17244,7 +17244,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all organization variables. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the organization_actions_variables:read organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all organization variables.\nYou must authenticate using an access token with the admin:org scope to use this endpoint. If the repository is private, you must use an access token with the repo scope. GitHub Apps must have the organization_actions_variables:read organization permission to use this endpoint. Authenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -17341,7 +17341,7 @@ } ], "previews": [], - "descriptionHTML": "

      Creates an organization variable that you can reference in a GitHub Actions workflow.\nYou must authenticate using an access token with the admin:org scope to use this endpoint.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Creates an organization variable that you can reference in a GitHub Actions workflow.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -17465,7 +17465,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a specific variable in an organization. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the organization_actions_variables:read organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a specific variable in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the organization_actions_variables:read organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -17560,7 +17560,7 @@ } ], "previews": [], - "descriptionHTML": "

      Updates an organization variable that you can reference in a GitHub Actions workflow.\nYou must authenticate using an access token with the admin:org scope to use this endpoint.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Updates an organization variable that you can reference in a GitHub Actions workflow.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -17615,7 +17615,7 @@ } ], "previews": [], - "descriptionHTML": "

      Deletes an organization variable using the variable name.\nYou must authenticate using an access token with the admin:org scope to use this endpoint.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Deletes an organization variable using the variable name.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -18582,7 +18582,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all repositories that can access an organization variable that is available to selected repositories. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the organization_actions_variables:read organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all repositories that can access an organization variable\nthat is available to selected repositories.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the organization_actions_variables:read organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -18655,7 +18655,7 @@ } ], "previews": [], - "descriptionHTML": "

      Replaces all repositories for an organization variable that is available to selected repositories. Organization variables that are available to selected repositories have their visibility field set to selected. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Replaces all repositories for an organization variable that is available\nto selected repositories. Organization variables that are available to selected\nrepositories have their visibility field set to selected.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this\nendpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -18724,7 +18724,7 @@ } ], "previews": [], - "descriptionHTML": "

      Adds a repository to an organization variable that is available to selected repositories. Organization variables that are available to selected repositories have their visibility field set to selected. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Adds a repository to an organization variable that is available to selected repositories.\nOrganization variables that are available to selected repositories have their visibility field set to selected.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -18793,7 +18793,7 @@ } ], "previews": [], - "descriptionHTML": "

      Removes a repository from an organization variable that is available to selected repositories. Organization variables that are available to selected repositories have their visibility field set to selected. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Removes a repository from an organization variable that is\navailable to selected repositories. Organization variables that are available to\nselected repositories have their visibility field set to selected.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -18945,7 +18945,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all organiation variables shared with a repository. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the actions_variables:read repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all organiation variables shared with a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions_variables:read repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -19093,7 +19093,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all repository variables. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the actions_variables:read repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all repository variables.\nYou must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions_variables:read repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -19177,7 +19177,7 @@ } ], "previews": [], - "descriptionHTML": "

      Creates a repository variable that you can reference in a GitHub Actions workflow.\nYou must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the actions_variables:write repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Creates a repository variable that you can reference in a GitHub Actions workflow.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions_variables:write repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -19291,7 +19291,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a specific variable in a repository. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the actions_variables:read repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a specific variable in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions_variables:read repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -19374,7 +19374,7 @@ } ], "previews": [], - "descriptionHTML": "

      Updates a repository variable that you can reference in a GitHub Actions workflow.\nYou must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the actions_variables:write repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Updates a repository variable that you can reference in a GitHub Actions workflow.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions_variables:write repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -19439,7 +19439,7 @@ } ], "previews": [], - "descriptionHTML": "

      Deletes a repository variable using the variable name.\nYou must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the actions_variables:write repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Deletes a repository variable using the variable name.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions_variables:write repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -19587,7 +19587,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all environment variables. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the environments:read repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all environment variables.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the environments:read repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -19671,7 +19671,7 @@ } ], "previews": [], - "descriptionHTML": "

      Create an environment variable that you can reference in a GitHub Actions workflow.\nYou must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the environment:write repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Create an environment variable that you can reference in a GitHub Actions workflow.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the environment:write repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -19785,7 +19785,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a specific variable in an environment. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the environments:read repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a specific variable in an environment.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the environments:read repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -19868,7 +19868,7 @@ } ], "previews": [], - "descriptionHTML": "

      Updates an environment variable that you can reference in a GitHub Actions workflow.\nYou must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the environment:write repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Updates an environment variable that you can reference in a GitHub Actions workflow.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the environment:write repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -19933,7 +19933,7 @@ } ], "previews": [], - "descriptionHTML": "

      Deletes an environment variable using the variable name.\nYou must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the environment:write repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Deletes an environment variable using the variable name.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the environment:write repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -21615,7 +21615,7 @@ } ], "previews": [], - "descriptionHTML": "

      Re-run a job and its dependent jobs in a workflow run. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the actions:write permission to use this endpoint.

      ", + "descriptionHTML": "

      Re-run a job and its dependent jobs in a workflow run.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions:write permission to use this endpoint.

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -30500,7 +30500,7 @@ } ], "previews": [], - "descriptionHTML": "

      Cancels a workflow run using its id. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the actions:write permission to use this endpoint.

      ", + "descriptionHTML": "

      Cancels a workflow run using its id.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions:write permission to use this endpoint.

      ", "statusCodes": [ { "httpStatusCode": "202", @@ -30575,7 +30575,7 @@ } ], "previews": [], - "descriptionHTML": "

      Approve or reject custom deployment protection rules provided by a GitHub App for a workflow run. For more information, see \"Using environments for deployment.\"

      \n

      Note: GitHub Apps can only review their own custom deployment protection rules.\nTo approve or reject pending deployments that are waiting for review from a specific person or team, see POST /repos/{owner}/{repo}/actions/runs/{run_id}/pending_deployments.

      \n

      GitHub Apps must have read and write permission for Deployments to use this endpoint.

      ", + "descriptionHTML": "

      Approve or reject custom deployment protection rules provided by a GitHub App for a workflow run. For more information, see \"Using environments for deployment.\"

      \n

      Note: GitHub Apps can only review their own custom deployment protection rules.\nTo approve or reject pending deployments that are waiting for review from a specific person or team, see POST /repos/{owner}/{repo}/actions/runs/{run_id}/pending_deployments.

      \n

      If the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have read and write permission for Deployments to use this endpoint.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -224999,7 +224999,7 @@ }, { "httpStatusCode": "403", - "description": "

      Forbidden

      " + "description": "

      Response if GitHub Advanced Security is not enabled for this repository

      " }, { "httpStatusCode": "404", @@ -458784,6 +458784,433 @@ } ] }, + { + "serverUrl": "https://api.github.com", + "verb": "get", + "requestPath": "/repos/{owner}/{repo}/activity", + "title": "List repository activities", + "category": "repos", + "subcategory": "repos", + "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": "direction", + "description": "

      The direction to sort the results by.

      ", + "in": "query", + "required": false, + "schema": { + "type": "string", + "enum": [ + "asc", + "desc" + ], + "default": "desc" + } + }, + { + "name": "per_page", + "description": "

      The number of results per page (max 100).

      ", + "in": "query", + "schema": { + "type": "integer", + "default": 30 + } + }, + { + "name": "before", + "description": "

      A cursor, as given in the Link header. If specified, the query only searches for results before this cursor.

      ", + "in": "query", + "required": false, + "schema": { + "type": "string" + } + }, + { + "name": "after", + "description": "

      A cursor, as given in the Link header. If specified, the query only searches for results after this cursor.

      ", + "in": "query", + "required": false, + "schema": { + "type": "string" + } + }, + { + "name": "ref", + "description": "

      The Git reference for the activities you want to list.

      \n

      The ref for a branch can be formatted either as refs/heads/BRANCH_NAME or BRANCH_NAME, where BRANCH_NAME is the name of your branch.

      ", + "in": "query", + "required": false, + "schema": { + "type": "string" + } + }, + { + "name": "actor", + "description": "

      The GitHub username to use to filter by the actor who performed the activity.

      ", + "in": "query", + "required": false, + "schema": { + "type": "string" + } + }, + { + "name": "time_period", + "description": "

      The time period to filter by.

      \n

      For example, day will filter for activity that occurred in the past 24 hours, and week will filter for activity that occurred in the past 7 days (168 hours).

      ", + "in": "query", + "required": false, + "schema": { + "type": "string", + "enum": [ + "day", + "week", + "month", + "quarter", + "year" + ] + } + }, + { + "name": "activity_type", + "description": "

      The activity type to filter by.

      \n

      For example, you can choose to filter by \"force_push\", to see all force pushes to the repository.

      ", + "in": "query", + "required": false, + "schema": { + "type": "string", + "enum": [ + "push", + "force_push", + "branch_creation", + "branch_deletion", + "pr_merge", + "merge_queue_merge" + ] + } + } + ], + "bodyParameters": [], + "enabledForGitHubApps": true, + "codeExamples": [ + { + "key": "default", + "request": { + "description": "Example", + "acceptHeader": "application/vnd.github.v3+json", + "parameters": { + "owner": "OWNER", + "repo": "REPO" + } + }, + "response": { + "statusCode": "200", + "contentType": "application/json", + "description": "

      Response

      ", + "example": [ + { + "id": 1296269, + "node_id": "MDEwOlJlcG9zaXRvcnkxMjk2MjY5", + "before": "6dcb09b5b57875f334f61aebed695e2e4193db5e", + "after": "827efc6d56897b048c772eb4087f854f46256132", + "ref": "refs/heads/main", + "pushed_at": "2011-01-26T19:06:43Z", + "push_type": "normal", + "pusher": { + "login": "octocat", + "id": 1, + "node_id": "MDQ6VXNlcjE=", + "avatar_url": "https://github.com/images/error/octocat_happy.gif", + "gravatar_id": "", + "url": "https://api.github.com/users/octocat", + "html_url": "https://github.com/octocat", + "followers_url": "https://api.github.com/users/octocat/followers", + "following_url": "https://api.github.com/users/octocat/following{/other_user}", + "gists_url": "https://api.github.com/users/octocat/gists{/gist_id}", + "starred_url": "https://api.github.com/users/octocat/starred{/owner}{/repo}", + "subscriptions_url": "https://api.github.com/users/octocat/subscriptions", + "organizations_url": "https://api.github.com/users/octocat/orgs", + "repos_url": "https://api.github.com/users/octocat/repos", + "events_url": "https://api.github.com/users/octocat/events{/privacy}", + "received_events_url": "https://api.github.com/users/octocat/received_events", + "type": "User", + "site_admin": false + } + } + ], + "schema": { + "type": "array", + "items": { + "title": "Activity", + "description": "Activity", + "type": "object", + "properties": { + "id": { + "type": "integer", + "examples": [ + 1296269 + ] + }, + "node_id": { + "type": "string", + "examples": [ + "MDEwOlJlcG9zaXRvcnkxMjk2MjY5" + ] + }, + "before": { + "type": "string", + "description": "The SHA of the commit before the activity.", + "examples": [ + "6dcb09b5b57875f334f61aebed695e2e4193db5e" + ] + }, + "after": { + "type": "string", + "description": "The SHA of the commit after the activity.", + "examples": [ + "827efc6d56897b048c772eb4087f854f46256132" + ] + }, + "ref": { + "type": "string", + "description": "The full Git reference, formatted as `refs/heads/`.", + "examples": [ + "refs/heads/main" + ] + }, + "timestamp": { + "type": "string", + "format": "date-time", + "description": "The time when the activity occurred.", + "examples": [ + "2011-01-26T19:06:43Z" + ] + }, + "activity_type": { + "type": "string", + "enum": [ + "push", + "force_push", + "branch_deletion", + "branch_creation", + "pr_merge", + "merge_queue_merge" + ], + "description": "The type of the activity that was performed.", + "examples": [ + "force_push" + ] + }, + "actor": { + "anyOf": [ + { + "type": "null" + }, + { + "title": "Simple User", + "description": "A GitHub user.", + "type": "object", + "properties": { + "name": { + "type": [ + "string", + "null" + ] + }, + "email": { + "type": [ + "string", + "null" + ] + }, + "login": { + "type": "string", + "examples": [ + "octocat" + ] + }, + "id": { + "type": "integer", + "examples": [ + 1 + ] + }, + "node_id": { + "type": "string", + "examples": [ + "MDQ6VXNlcjE=" + ] + }, + "avatar_url": { + "type": "string", + "format": "uri", + "examples": [ + "https://github.com/images/error/octocat_happy.gif" + ] + }, + "gravatar_id": { + "type": [ + "string", + "null" + ], + "examples": [ + "41d064eb2195891e12d0413f63227ea7" + ] + }, + "url": { + "type": "string", + "format": "uri", + "examples": [ + "https://api.github.com/users/octocat" + ] + }, + "html_url": { + "type": "string", + "format": "uri", + "examples": [ + "https://github.com/octocat" + ] + }, + "followers_url": { + "type": "string", + "format": "uri", + "examples": [ + "https://api.github.com/users/octocat/followers" + ] + }, + "following_url": { + "type": "string", + "examples": [ + "https://api.github.com/users/octocat/following{/other_user}" + ] + }, + "gists_url": { + "type": "string", + "examples": [ + "https://api.github.com/users/octocat/gists{/gist_id}" + ] + }, + "starred_url": { + "type": "string", + "examples": [ + "https://api.github.com/users/octocat/starred{/owner}{/repo}" + ] + }, + "subscriptions_url": { + "type": "string", + "format": "uri", + "examples": [ + "https://api.github.com/users/octocat/subscriptions" + ] + }, + "organizations_url": { + "type": "string", + "format": "uri", + "examples": [ + "https://api.github.com/users/octocat/orgs" + ] + }, + "repos_url": { + "type": "string", + "format": "uri", + "examples": [ + "https://api.github.com/users/octocat/repos" + ] + }, + "events_url": { + "type": "string", + "examples": [ + "https://api.github.com/users/octocat/events{/privacy}" + ] + }, + "received_events_url": { + "type": "string", + "format": "uri", + "examples": [ + "https://api.github.com/users/octocat/received_events" + ] + }, + "type": { + "type": "string", + "examples": [ + "User" + ] + }, + "site_admin": { + "type": "boolean" + }, + "starred_at": { + "type": "string", + "examples": [ + "\"2020-07-09T00:17:55Z\"" + ] + } + }, + "required": [ + "avatar_url", + "events_url", + "followers_url", + "following_url", + "gists_url", + "gravatar_id", + "html_url", + "id", + "node_id", + "login", + "organizations_url", + "received_events_url", + "repos_url", + "site_admin", + "starred_url", + "subscriptions_url", + "type", + "url" + ] + } + ] + } + }, + "required": [ + "id", + "node_id", + "before", + "after", + "ref", + "timestamp", + "activity_type", + "actor" + ] + } + } + } + } + ], + "previews": [], + "descriptionHTML": "

      Lists a detailed history of changes to a repository, such as pushes, merges, force pushes, and branch changes, and associates these changes with commits and users.

      \n

      For more information about viewing repository activity,\nsee \"Viewing repository activity.\"

      ", + "statusCodes": [ + { + "httpStatusCode": "200", + "description": "

      OK

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

      Validation failed, or the endpoint has been spammed.

      " + } + ] + }, { "serverUrl": "https://api.github.com", "verb": "get", @@ -537045,7 +537472,7 @@ } ], "previews": [], - "descriptionHTML": "

      Team members will include the members of child teams.

      \n

      To get a user's membership with a team, the team must be visible to the authenticated user.

      \n

      Note: You can also specify a team by org_id and team_id using the route GET /organizations/{org_id}/team/{team_id}/memberships/{username}.

      \n

      Note:\nThe response contains the state of the membership and the member's role.

      \n

      The role for organization owners is set to maintainer. For more information about maintainer roles, see see Create a team.

      ", + "descriptionHTML": "

      Team members will include the members of child teams.

      \n

      To get a user's membership with a team, the team must be visible to the authenticated user.

      \n

      Note: You can also specify a team by org_id and team_id using the route GET /organizations/{org_id}/team/{team_id}/memberships/{username}.

      \n

      Note:\nThe response contains the state of the membership and the member's role.

      \n

      The role for organization owners is set to maintainer. For more information about maintainer roles, see Create a team.

      ", "statusCodes": [ { "httpStatusCode": "200", diff --git a/src/rest/data/ghae/schema.json b/src/rest/data/ghae/schema.json index 6cf9a15d08..0198177164 100644 --- a/src/rest/data/ghae/schema.json +++ b/src/rest/data/ghae/schema.json @@ -590,7 +590,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a redirect URL to download an archive for a repository. This URL expires after 1 minute. Look for Location: in\nthe response header to find the URL for the download. The :archive_format must be zip. Anyone with read access to\nthe repository can use this endpoint. If the repository is private you must use an access token with the repo scope.\nGitHub Apps must have the actions:read permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a redirect URL to download an archive for a repository. This URL expires after 1 minute. Look for Location: in\nthe response header to find the URL for the download. The :archive_format must be zip.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the actions:read permission to use this endpoint.

      ", "statusCodes": [ { "httpStatusCode": "302", @@ -4217,7 +4217,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all secrets available in an organization without revealing their encrypted values. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all secrets available in an organization without revealing their\nencrypted values.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -4316,7 +4316,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets your public key, which you need to encrypt secrets. You need to encrypt a secret before you can create or update secrets. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets your public key, which you need to encrypt secrets. You need to\nencrypt a secret before you can create or update secrets.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -4423,7 +4423,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a single organization secret without revealing its encrypted value. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a single organization secret without revealing its encrypted value.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -4553,7 +4553,7 @@ } ], "previews": [], - "descriptionHTML": "

      Creates or updates an organization secret with an encrypted value. Encrypt your secret using\nLibSodium. You must authenticate using an access\ntoken with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to\nuse this endpoint.

      \n

      *Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", + "descriptionHTML": "

      Creates or updates an organization secret with an encrypted value. Encrypt your secret using\nLibSodium.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      \n

      *Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -4612,7 +4612,7 @@ } ], "previews": [], - "descriptionHTML": "

      Deletes a secret in an organization using the secret name. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Deletes a secret in an organization using the secret name.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -5579,7 +5579,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all repositories that have been selected when the visibility for repository access to a secret is set to selected. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all repositories that have been selected when the visibility\nfor repository access to a secret is set to selected.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -5648,7 +5648,7 @@ } ], "previews": [], - "descriptionHTML": "

      Replaces all repositories for an organization secret when the visibility for repository access is set to selected. The visibility is set when you Create or update an organization secret. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Replaces all repositories for an organization secret when the visibility\nfor repository access is set to selected. The visibility is set when you Create\nor update an organization secret.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -5713,7 +5713,7 @@ } ], "previews": [], - "descriptionHTML": "

      Adds a repository to an organization secret when the visibility for repository access is set to selected. The visibility is set when you Create or update an organization secret. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Adds a repository to an organization secret when the visibility for\nrepository access is set to selected. The visibility is set when you Create or\nupdate an organization secret.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -5782,7 +5782,7 @@ } ], "previews": [], - "descriptionHTML": "

      Removes a repository from an organization secret when the visibility for repository access is set to selected. The visibility is set when you Create or update an organization secret. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Removes a repository from an organization secret when the visibility\nfor repository access is set to selected. The visibility is set when you Create\nor update an organization secret.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -5917,7 +5917,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all organization secrets shared with a repository without revealing their encrypted values. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all organization secrets shared with a repository without revealing their encrypted\nvalues.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -6048,7 +6048,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all secrets available in a repository without revealing their encrypted values. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all secrets available in a repository without revealing their encrypted\nvalues.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -6157,7 +6157,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets your public key, which you need to encrypt secrets. You need to encrypt a secret before you can create or update secrets. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the repo scope. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets your public key, which you need to encrypt secrets. You need to\nencrypt a secret before you can create or update secrets.

      \n

      Anyone with read access to the repository can use this endpoint.\nIf the repository is private you must use an access token with the repo scope.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -6255,7 +6255,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a single repository secret without revealing its encrypted value. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a single repository secret without revealing its encrypted value.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -6368,7 +6368,7 @@ } ], "previews": [], - "descriptionHTML": "

      Creates or updates a repository secret with an encrypted value. Encrypt your secret using\nLibSodium. You must authenticate using an access\ntoken with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use\nthis endpoint.

      \n

      Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", + "descriptionHTML": "

      Creates or updates a repository secret with an encrypted value. Encrypt your secret using\nLibSodium.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      \n

      Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -6437,7 +6437,7 @@ } ], "previews": [], - "descriptionHTML": "

      Deletes a secret in a repository using the secret name. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Deletes a secret in a repository using the secret name.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -12114,7 +12114,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all self-hosted runners configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists all self-hosted runners configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -12227,7 +12227,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists binaries for the runner application that you can download and run.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists binaries for the runner application that you can download and run.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -13717,7 +13717,7 @@ } ], "previews": [], - "descriptionHTML": "

      Returns a token that you can pass to the config script. The token expires after one hour.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      \n

      Example using registration token:

      \n

      Configure your self-hosted runner, replacing TOKEN with the registration token provided by this endpoint.

      \n
      ./config.sh --url https://github.com/octo-org --token TOKEN\n
      ", + "descriptionHTML": "

      Returns a token that you can pass to the config script. The token expires after one hour.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      \n

      Example using registration token:

      \n

      Configure your self-hosted runner, replacing TOKEN with the registration token provided by this endpoint.

      \n
      ./config.sh --url https://github.com/octo-org --token TOKEN\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -15207,7 +15207,7 @@ } ], "previews": [], - "descriptionHTML": "

      Returns a token that you can pass to the config script to remove a self-hosted runner from an organization. The token expires after one hour.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      \n

      Example using remove token:

      \n

      To remove your self-hosted runner from an organization, replace TOKEN with the remove token provided by this\nendpoint.

      \n
      ./config.sh remove --token TOKEN\n
      ", + "descriptionHTML": "

      Returns a token that you can pass to the config script to remove a self-hosted runner from an organization. The token expires after one hour.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      \n

      Example using remove token:

      \n

      To remove your self-hosted runner from an organization, replace TOKEN with the remove token provided by this\nendpoint.

      \n
      ./config.sh remove --token TOKEN\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -15374,7 +15374,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a specific self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Gets a specific self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -15429,7 +15429,7 @@ } ], "previews": [], - "descriptionHTML": "

      Forces the removal of a self-hosted runner from an organization. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Forces the removal of a self-hosted runner from an organization. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -15658,7 +15658,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all self-hosted runners configured in a repository. You must authenticate using an access token with the repo scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists all self-hosted runners configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -15781,7 +15781,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists binaries for the runner application that you can download and run.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists binaries for the runner application that you can download and run.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -17281,7 +17281,7 @@ } ], "previews": [], - "descriptionHTML": "

      Returns a token that you can pass to the config script. The token expires after one hour. You must authenticate using an access token with the repo scope to use this endpoint.

      \n

      Example using registration token:

      \n

      Configure your self-hosted runner, replacing TOKEN with the registration token provided by this endpoint.

      \n
      ./config.sh --url https://github.com/octo-org/octo-repo-artifacts --token TOKEN\n
      ", + "descriptionHTML": "

      Returns a token that you can pass to the config script. The token\nexpires after one hour.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      \n

      Example using registration token:

      \n

      Configure your self-hosted runner, replacing TOKEN with the registration token provided\nby this endpoint.

      \n

      config.sh --url https://github.com/octo-org/octo-repo-artifacts --token TOKEN

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -18781,7 +18781,7 @@ } ], "previews": [], - "descriptionHTML": "

      Returns a token that you can pass to remove a self-hosted runner from a repository. The token expires after one hour.\nYou must authenticate using an access token with the repo scope to use this endpoint.

      \n

      Example using remove token:

      \n

      To remove your self-hosted runner from a repository, replace TOKEN with the remove token provided by this endpoint.

      \n
      ./config.sh remove --token TOKEN\n
      ", + "descriptionHTML": "

      Returns a token that you can pass to remove a self-hosted runner from\na repository. The token expires after one hour.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      \n

      Example using remove token:

      \n

      To remove your self-hosted runner from a repository, replace TOKEN with\nthe remove token provided by this endpoint.

      \n

      config.sh remove --token TOKEN

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -18958,7 +18958,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a specific self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Gets a specific self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -19023,7 +19023,7 @@ } ], "previews": [], - "descriptionHTML": "

      Forces the removal of a self-hosted runner from a repository. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.

      \n

      You must authenticate using an access token with the repo\nscope to use this endpoint.

      ", + "descriptionHTML": "

      Forces the removal of a self-hosted runner from a repository. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -29037,7 +29037,7 @@ } ], "previews": [], - "descriptionHTML": "

      Cancels a workflow run using its id. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the actions:write permission to use this endpoint.

      ", + "descriptionHTML": "

      Cancels a workflow run using its id.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions:write permission to use this endpoint.

      ", "statusCodes": [ { "httpStatusCode": "202", @@ -396268,7 +396268,7 @@ } ], "previews": [], - "descriptionHTML": "

      Team members will include the members of child teams.

      \n

      To get a user's membership with a team, the team must be visible to the authenticated user.

      \n

      Note: You can also specify a team by org_id and team_id using the route GET /organizations/{org_id}/team/{team_id}/memberships/{username}.

      \n

      Note:\nThe response contains the state of the membership and the member's role.

      \n

      The role for organization owners is set to maintainer. For more information about maintainer roles, see see Create a team.

      ", + "descriptionHTML": "

      Team members will include the members of child teams.

      \n

      To get a user's membership with a team, the team must be visible to the authenticated user.

      \n

      Note: You can also specify a team by org_id and team_id using the route GET /organizations/{org_id}/team/{team_id}/memberships/{username}.

      \n

      Note:\nThe response contains the state of the membership and the member's role.

      \n

      The role for organization owners is set to maintainer. For more information about maintainer roles, see Create a team.

      ", "statusCodes": [ { "httpStatusCode": "200", diff --git a/src/rest/data/ghec-2022-11-28/schema.json b/src/rest/data/ghec-2022-11-28/schema.json index 162eebbbdd..4158879d46 100644 --- a/src/rest/data/ghec-2022-11-28/schema.json +++ b/src/rest/data/ghec-2022-11-28/schema.json @@ -599,7 +599,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a redirect URL to download an archive for a repository. This URL expires after 1 minute. Look for Location: in\nthe response header to find the URL for the download. The :archive_format must be zip. Anyone with read access to\nthe repository can use this endpoint. If the repository is private you must use an access token with the repo scope.\nGitHub Apps must have the actions:read permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a redirect URL to download an archive for a repository. This URL expires after 1 minute. Look for Location: in\nthe response header to find the URL for the download. The :archive_format must be zip.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the actions:read permission to use this endpoint.

      ", "statusCodes": [ { "httpStatusCode": "302", @@ -5946,7 +5946,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all secrets available in an organization without revealing their encrypted values. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all secrets available in an organization without revealing their\nencrypted values.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -6045,7 +6045,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets your public key, which you need to encrypt secrets. You need to encrypt a secret before you can create or update secrets. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets your public key, which you need to encrypt secrets. You need to\nencrypt a secret before you can create or update secrets.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -6152,7 +6152,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a single organization secret without revealing its encrypted value. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a single organization secret without revealing its encrypted value.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -6282,7 +6282,7 @@ } ], "previews": [], - "descriptionHTML": "

      Creates or updates an organization secret with an encrypted value. Encrypt your secret using\nLibSodium. You must authenticate using an access\ntoken with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to\nuse this endpoint.

      \n

      *Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", + "descriptionHTML": "

      Creates or updates an organization secret with an encrypted value. Encrypt your secret using\nLibSodium.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      \n

      *Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -6341,7 +6341,7 @@ } ], "previews": [], - "descriptionHTML": "

      Deletes a secret in an organization using the secret name. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Deletes a secret in an organization using the secret name.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -7308,7 +7308,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all repositories that have been selected when the visibility for repository access to a secret is set to selected. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all repositories that have been selected when the visibility\nfor repository access to a secret is set to selected.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -7377,7 +7377,7 @@ } ], "previews": [], - "descriptionHTML": "

      Replaces all repositories for an organization secret when the visibility for repository access is set to selected. The visibility is set when you Create or update an organization secret. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Replaces all repositories for an organization secret when the visibility\nfor repository access is set to selected. The visibility is set when you Create\nor update an organization secret.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -7442,7 +7442,7 @@ } ], "previews": [], - "descriptionHTML": "

      Adds a repository to an organization secret when the visibility for repository access is set to selected. The visibility is set when you Create or update an organization secret. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Adds a repository to an organization secret when the visibility for\nrepository access is set to selected. The visibility is set when you Create or\nupdate an organization secret.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -7511,7 +7511,7 @@ } ], "previews": [], - "descriptionHTML": "

      Removes a repository from an organization secret when the visibility for repository access is set to selected. The visibility is set when you Create or update an organization secret. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Removes a repository from an organization secret when the visibility\nfor repository access is set to selected. The visibility is set when you Create\nor update an organization secret.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -7646,7 +7646,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all organization secrets shared with a repository without revealing their encrypted values. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all organization secrets shared with a repository without revealing their encrypted\nvalues.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -7777,7 +7777,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all secrets available in a repository without revealing their encrypted values. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all secrets available in a repository without revealing their encrypted\nvalues.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -7886,7 +7886,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets your public key, which you need to encrypt secrets. You need to encrypt a secret before you can create or update secrets. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the repo scope. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets your public key, which you need to encrypt secrets. You need to\nencrypt a secret before you can create or update secrets.

      \n

      Anyone with read access to the repository can use this endpoint.\nIf the repository is private you must use an access token with the repo scope.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -7984,7 +7984,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a single repository secret without revealing its encrypted value. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a single repository secret without revealing its encrypted value.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -8097,7 +8097,7 @@ } ], "previews": [], - "descriptionHTML": "

      Creates or updates a repository secret with an encrypted value. Encrypt your secret using\nLibSodium. You must authenticate using an access\ntoken with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use\nthis endpoint.

      \n

      Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", + "descriptionHTML": "

      Creates or updates a repository secret with an encrypted value. Encrypt your secret using\nLibSodium.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      \n

      Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -8166,7 +8166,7 @@ } ], "previews": [], - "descriptionHTML": "

      Deletes a secret in a repository using the secret name. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Deletes a secret in a repository using the secret name.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -8297,7 +8297,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all secrets available in an environment without revealing their encrypted values. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all secrets available in an environment without revealing their\nencrypted values.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -8406,7 +8406,7 @@ } ], "previews": [], - "descriptionHTML": "

      Get the public key for an environment, which you need to encrypt environment secrets. You need to encrypt a secret before you can create or update secrets. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the repo scope. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Get the public key for an environment, which you need to encrypt environment\nsecrets. You need to encrypt a secret before you can create or update secrets.

      \n

      Anyone with read access to the repository can use this endpoint.\nIf the repository is private you must use an access token with the repo scope.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -8504,7 +8504,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a single environment secret without revealing its encrypted value. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a single environment secret without revealing its encrypted value.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -8619,7 +8619,7 @@ } ], "previews": [], - "descriptionHTML": "

      Creates or updates an environment secret with an encrypted value. Encrypt your secret using\nLibSodium. You must authenticate using an access\ntoken with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use\nthis endpoint.

      \n

      Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", + "descriptionHTML": "

      Creates or updates an environment secret with an encrypted value. Encrypt your secret using\nLibSodium.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      \n

      Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -8688,7 +8688,7 @@ } ], "previews": [], - "descriptionHTML": "

      Deletes a secret in an environment using the secret name. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Deletes a secret in an environment using the secret name.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -17583,7 +17583,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all self-hosted runners configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists all self-hosted runners configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -17696,7 +17696,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists binaries for the runner application that you can download and run.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists binaries for the runner application that you can download and run.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -17910,7 +17910,7 @@ } ], "previews": [], - "descriptionHTML": "

      Generates a configuration that can be passed to the runner application at startup.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Generates a configuration that can be passed to the runner application at startup.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -19493,7 +19493,7 @@ } ], "previews": [], - "descriptionHTML": "

      Returns a token that you can pass to the config script. The token expires after one hour.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      \n

      Example using registration token:

      \n

      Configure your self-hosted runner, replacing TOKEN with the registration token provided by this endpoint.

      \n
      ./config.sh --url https://github.com/octo-org --token TOKEN\n
      ", + "descriptionHTML": "

      Returns a token that you can pass to the config script. The token expires after one hour.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      \n

      Example using registration token:

      \n

      Configure your self-hosted runner, replacing TOKEN with the registration token provided by this endpoint.

      \n
      ./config.sh --url https://github.com/octo-org --token TOKEN\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -21068,7 +21068,7 @@ } ], "previews": [], - "descriptionHTML": "

      Returns a token that you can pass to the config script to remove a self-hosted runner from an organization. The token expires after one hour.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      \n

      Example using remove token:

      \n

      To remove your self-hosted runner from an organization, replace TOKEN with the remove token provided by this\nendpoint.

      \n
      ./config.sh remove --token TOKEN\n
      ", + "descriptionHTML": "

      Returns a token that you can pass to the config script to remove a self-hosted runner from an organization. The token expires after one hour.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      \n

      Example using remove token:

      \n

      To remove your self-hosted runner from an organization, replace TOKEN with the remove token provided by this\nendpoint.

      \n
      ./config.sh remove --token TOKEN\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -21235,7 +21235,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a specific self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Gets a specific self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -21290,7 +21290,7 @@ } ], "previews": [], - "descriptionHTML": "

      Forces the removal of a self-hosted runner from an organization. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Forces the removal of a self-hosted runner from an organization. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -21412,7 +21412,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all labels for a self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists all labels for a self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -21553,7 +21553,7 @@ } ], "previews": [], - "descriptionHTML": "

      Add custom labels to a self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Add custom labels to a self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -21698,7 +21698,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove all previous custom labels and set the new custom labels for a specific\nself-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Remove all previous custom labels and set the new custom labels for a specific\nself-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -21823,7 +21823,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove all custom labels from a self-hosted runner configured in an\norganization. Returns the remaining read-only labels from the runner.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Remove all custom labels from a self-hosted runner configured in an\norganization. Returns the remaining read-only labels from the runner.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -21959,7 +21959,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove a custom label from a self-hosted runner configured\nin an organization. Returns the remaining labels from the runner.

      \n

      This endpoint returns a 404 Not Found status if the custom label is not\npresent on the runner.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Remove a custom label from a self-hosted runner configured\nin an organization. Returns the remaining labels from the runner.

      \n

      This endpoint returns a 404 Not Found status if the custom label is not\npresent on the runner.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -22196,7 +22196,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all self-hosted runners configured in a repository. You must authenticate using an access token with the repo scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists all self-hosted runners configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -22319,7 +22319,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists binaries for the runner application that you can download and run.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists binaries for the runner application that you can download and run.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -22543,7 +22543,7 @@ } ], "previews": [], - "descriptionHTML": "

      Generates a configuration that can be passed to the runner application at startup.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.

      ", + "descriptionHTML": "

      Generates a configuration that can be passed to the runner application at startup.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -24136,7 +24136,7 @@ } ], "previews": [], - "descriptionHTML": "

      Returns a token that you can pass to the config script. The token expires after one hour. You must authenticate using an access token with the repo scope to use this endpoint.

      \n

      Example using registration token:

      \n

      Configure your self-hosted runner, replacing TOKEN with the registration token provided by this endpoint.

      \n
      ./config.sh --url https://github.com/octo-org/octo-repo-artifacts --token TOKEN\n
      ", + "descriptionHTML": "

      Returns a token that you can pass to the config script. The token\nexpires after one hour.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      \n

      Example using registration token:

      \n

      Configure your self-hosted runner, replacing TOKEN with the registration token provided\nby this endpoint.

      \n

      config.sh --url https://github.com/octo-org/octo-repo-artifacts --token TOKEN

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -25721,7 +25721,7 @@ } ], "previews": [], - "descriptionHTML": "

      Returns a token that you can pass to remove a self-hosted runner from a repository. The token expires after one hour.\nYou must authenticate using an access token with the repo scope to use this endpoint.

      \n

      Example using remove token:

      \n

      To remove your self-hosted runner from a repository, replace TOKEN with the remove token provided by this endpoint.

      \n
      ./config.sh remove --token TOKEN\n
      ", + "descriptionHTML": "

      Returns a token that you can pass to remove a self-hosted runner from\na repository. The token expires after one hour.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      \n

      Example using remove token:

      \n

      To remove your self-hosted runner from a repository, replace TOKEN with\nthe remove token provided by this endpoint.

      \n

      config.sh remove --token TOKEN

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -25898,7 +25898,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a specific self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Gets a specific self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -25963,7 +25963,7 @@ } ], "previews": [], - "descriptionHTML": "

      Forces the removal of a self-hosted runner from a repository. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.

      \n

      You must authenticate using an access token with the repo\nscope to use this endpoint.

      ", + "descriptionHTML": "

      Forces the removal of a self-hosted runner from a repository. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -26095,7 +26095,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all labels for a self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Lists all labels for a self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -26246,7 +26246,7 @@ } ], "previews": [], - "descriptionHTML": "

      Add custom labels to a self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Add custom labels to a self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -26401,7 +26401,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove all previous custom labels and set the new custom labels for a specific\nself-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Remove all previous custom labels and set the new custom labels for a specific\nself-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -26536,7 +26536,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove all custom labels from a self-hosted runner configured in a\nrepository. Returns the remaining read-only labels from the runner.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Remove all custom labels from a self-hosted runner configured in a\nrepository. Returns the remaining read-only labels from the runner.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -26682,7 +26682,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove a custom label from a self-hosted runner configured\nin a repository. Returns the remaining labels from the runner.

      \n

      This endpoint returns a 404 Not Found status if the custom label is not\npresent on the runner.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Remove a custom label from a self-hosted runner configured\nin a repository. Returns the remaining labels from the runner.

      \n

      This endpoint returns a 404 Not Found status if the custom label is not\npresent on the runner.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -26858,7 +26858,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all organization variables. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the organization_actions_variables:read organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all organization variables.\nYou must authenticate using an access token with the admin:org scope to use this endpoint. If the repository is private, you must use an access token with the repo scope. GitHub Apps must have the organization_actions_variables:read organization permission to use this endpoint. Authenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -26955,7 +26955,7 @@ } ], "previews": [], - "descriptionHTML": "

      Creates an organization variable that you can reference in a GitHub Actions workflow.\nYou must authenticate using an access token with the admin:org scope to use this endpoint.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Creates an organization variable that you can reference in a GitHub Actions workflow.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -27079,7 +27079,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a specific variable in an organization. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the organization_actions_variables:read organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a specific variable in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the organization_actions_variables:read organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -27174,7 +27174,7 @@ } ], "previews": [], - "descriptionHTML": "

      Updates an organization variable that you can reference in a GitHub Actions workflow.\nYou must authenticate using an access token with the admin:org scope to use this endpoint.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Updates an organization variable that you can reference in a GitHub Actions workflow.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -27229,7 +27229,7 @@ } ], "previews": [], - "descriptionHTML": "

      Deletes an organization variable using the variable name.\nYou must authenticate using an access token with the admin:org scope to use this endpoint.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Deletes an organization variable using the variable name.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -28196,7 +28196,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all repositories that can access an organization variable that is available to selected repositories. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the organization_actions_variables:read organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all repositories that can access an organization variable\nthat is available to selected repositories.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the organization_actions_variables:read organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -28269,7 +28269,7 @@ } ], "previews": [], - "descriptionHTML": "

      Replaces all repositories for an organization variable that is available to selected repositories. Organization variables that are available to selected repositories have their visibility field set to selected. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Replaces all repositories for an organization variable that is available\nto selected repositories. Organization variables that are available to selected\nrepositories have their visibility field set to selected.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this\nendpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -28338,7 +28338,7 @@ } ], "previews": [], - "descriptionHTML": "

      Adds a repository to an organization variable that is available to selected repositories. Organization variables that are available to selected repositories have their visibility field set to selected. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Adds a repository to an organization variable that is available to selected repositories.\nOrganization variables that are available to selected repositories have their visibility field set to selected.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -28407,7 +28407,7 @@ } ], "previews": [], - "descriptionHTML": "

      Removes a repository from an organization variable that is available to selected repositories. Organization variables that are available to selected repositories have their visibility field set to selected. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Removes a repository from an organization variable that is\navailable to selected repositories. Organization variables that are available to\nselected repositories have their visibility field set to selected.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -28559,7 +28559,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all organiation variables shared with a repository. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the actions_variables:read repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all organiation variables shared with a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions_variables:read repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -28707,7 +28707,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all repository variables. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the actions_variables:read repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all repository variables.\nYou must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions_variables:read repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -28791,7 +28791,7 @@ } ], "previews": [], - "descriptionHTML": "

      Creates a repository variable that you can reference in a GitHub Actions workflow.\nYou must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the actions_variables:write repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Creates a repository variable that you can reference in a GitHub Actions workflow.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions_variables:write repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -28905,7 +28905,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a specific variable in a repository. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the actions_variables:read repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a specific variable in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions_variables:read repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -28988,7 +28988,7 @@ } ], "previews": [], - "descriptionHTML": "

      Updates a repository variable that you can reference in a GitHub Actions workflow.\nYou must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the actions_variables:write repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Updates a repository variable that you can reference in a GitHub Actions workflow.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions_variables:write repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -29053,7 +29053,7 @@ } ], "previews": [], - "descriptionHTML": "

      Deletes a repository variable using the variable name.\nYou must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the actions_variables:write repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Deletes a repository variable using the variable name.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions_variables:write repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -29201,7 +29201,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all environment variables. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the environments:read repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all environment variables.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the environments:read repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -29285,7 +29285,7 @@ } ], "previews": [], - "descriptionHTML": "

      Create an environment variable that you can reference in a GitHub Actions workflow.\nYou must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the environment:write repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Create an environment variable that you can reference in a GitHub Actions workflow.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the environment:write repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -29399,7 +29399,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a specific variable in an environment. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the environments:read repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a specific variable in an environment.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the environments:read repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -29482,7 +29482,7 @@ } ], "previews": [], - "descriptionHTML": "

      Updates an environment variable that you can reference in a GitHub Actions workflow.\nYou must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the environment:write repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Updates an environment variable that you can reference in a GitHub Actions workflow.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the environment:write repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -29547,7 +29547,7 @@ } ], "previews": [], - "descriptionHTML": "

      Deletes an environment variable using the variable name.\nYou must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the environment:write repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Deletes an environment variable using the variable name.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the environment:write repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -31229,7 +31229,7 @@ } ], "previews": [], - "descriptionHTML": "

      Re-run a job and its dependent jobs in a workflow run. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the actions:write permission to use this endpoint.

      ", + "descriptionHTML": "

      Re-run a job and its dependent jobs in a workflow run.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions:write permission to use this endpoint.

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -40114,7 +40114,7 @@ } ], "previews": [], - "descriptionHTML": "

      Cancels a workflow run using its id. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the actions:write permission to use this endpoint.

      ", + "descriptionHTML": "

      Cancels a workflow run using its id.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions:write permission to use this endpoint.

      ", "statusCodes": [ { "httpStatusCode": "202", @@ -40189,7 +40189,7 @@ } ], "previews": [], - "descriptionHTML": "

      Approve or reject custom deployment protection rules provided by a GitHub App for a workflow run. For more information, see \"Using environments for deployment.\"

      \n

      Note: GitHub Apps can only review their own custom deployment protection rules.\nTo approve or reject pending deployments that are waiting for review from a specific person or team, see POST /repos/{owner}/{repo}/actions/runs/{run_id}/pending_deployments.

      \n

      GitHub Apps must have read and write permission for Deployments to use this endpoint.

      ", + "descriptionHTML": "

      Approve or reject custom deployment protection rules provided by a GitHub App for a workflow run. For more information, see \"Using environments for deployment.\"

      \n

      Note: GitHub Apps can only review their own custom deployment protection rules.\nTo approve or reject pending deployments that are waiting for review from a specific person or team, see POST /repos/{owner}/{repo}/actions/runs/{run_id}/pending_deployments.

      \n

      If the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have read and write permission for Deployments to use this endpoint.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -236698,7 +236698,7 @@ }, { "httpStatusCode": "403", - "description": "

      Forbidden

      " + "description": "

      Response if GitHub Advanced Security is not enabled for this repository

      " }, { "httpStatusCode": "404", @@ -475831,6 +475831,433 @@ } ] }, + { + "serverUrl": "https://api.github.com", + "verb": "get", + "requestPath": "/repos/{owner}/{repo}/activity", + "title": "List repository activities", + "category": "repos", + "subcategory": "repos", + "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": "direction", + "description": "

      The direction to sort the results by.

      ", + "in": "query", + "required": false, + "schema": { + "type": "string", + "enum": [ + "asc", + "desc" + ], + "default": "desc" + } + }, + { + "name": "per_page", + "description": "

      The number of results per page (max 100).

      ", + "in": "query", + "schema": { + "type": "integer", + "default": 30 + } + }, + { + "name": "before", + "description": "

      A cursor, as given in the Link header. If specified, the query only searches for results before this cursor.

      ", + "in": "query", + "required": false, + "schema": { + "type": "string" + } + }, + { + "name": "after", + "description": "

      A cursor, as given in the Link header. If specified, the query only searches for results after this cursor.

      ", + "in": "query", + "required": false, + "schema": { + "type": "string" + } + }, + { + "name": "ref", + "description": "

      The Git reference for the activities you want to list.

      \n

      The ref for a branch can be formatted either as refs/heads/BRANCH_NAME or BRANCH_NAME, where BRANCH_NAME is the name of your branch.

      ", + "in": "query", + "required": false, + "schema": { + "type": "string" + } + }, + { + "name": "actor", + "description": "

      The GitHub username to use to filter by the actor who performed the activity.

      ", + "in": "query", + "required": false, + "schema": { + "type": "string" + } + }, + { + "name": "time_period", + "description": "

      The time period to filter by.

      \n

      For example, day will filter for activity that occurred in the past 24 hours, and week will filter for activity that occurred in the past 7 days (168 hours).

      ", + "in": "query", + "required": false, + "schema": { + "type": "string", + "enum": [ + "day", + "week", + "month", + "quarter", + "year" + ] + } + }, + { + "name": "activity_type", + "description": "

      The activity type to filter by.

      \n

      For example, you can choose to filter by \"force_push\", to see all force pushes to the repository.

      ", + "in": "query", + "required": false, + "schema": { + "type": "string", + "enum": [ + "push", + "force_push", + "branch_creation", + "branch_deletion", + "pr_merge", + "merge_queue_merge" + ] + } + } + ], + "bodyParameters": [], + "enabledForGitHubApps": true, + "codeExamples": [ + { + "key": "default", + "request": { + "description": "Example", + "acceptHeader": "application/vnd.github.v3+json", + "parameters": { + "owner": "OWNER", + "repo": "REPO" + } + }, + "response": { + "statusCode": "200", + "contentType": "application/json", + "description": "

      Response

      ", + "example": [ + { + "id": 1296269, + "node_id": "MDEwOlJlcG9zaXRvcnkxMjk2MjY5", + "before": "6dcb09b5b57875f334f61aebed695e2e4193db5e", + "after": "827efc6d56897b048c772eb4087f854f46256132", + "ref": "refs/heads/main", + "pushed_at": "2011-01-26T19:06:43Z", + "push_type": "normal", + "pusher": { + "login": "octocat", + "id": 1, + "node_id": "MDQ6VXNlcjE=", + "avatar_url": "https://github.com/images/error/octocat_happy.gif", + "gravatar_id": "", + "url": "https://api.github.com/users/octocat", + "html_url": "https://github.com/octocat", + "followers_url": "https://api.github.com/users/octocat/followers", + "following_url": "https://api.github.com/users/octocat/following{/other_user}", + "gists_url": "https://api.github.com/users/octocat/gists{/gist_id}", + "starred_url": "https://api.github.com/users/octocat/starred{/owner}{/repo}", + "subscriptions_url": "https://api.github.com/users/octocat/subscriptions", + "organizations_url": "https://api.github.com/users/octocat/orgs", + "repos_url": "https://api.github.com/users/octocat/repos", + "events_url": "https://api.github.com/users/octocat/events{/privacy}", + "received_events_url": "https://api.github.com/users/octocat/received_events", + "type": "User", + "site_admin": false + } + } + ], + "schema": { + "type": "array", + "items": { + "title": "Activity", + "description": "Activity", + "type": "object", + "properties": { + "id": { + "type": "integer", + "examples": [ + 1296269 + ] + }, + "node_id": { + "type": "string", + "examples": [ + "MDEwOlJlcG9zaXRvcnkxMjk2MjY5" + ] + }, + "before": { + "type": "string", + "description": "The SHA of the commit before the activity.", + "examples": [ + "6dcb09b5b57875f334f61aebed695e2e4193db5e" + ] + }, + "after": { + "type": "string", + "description": "The SHA of the commit after the activity.", + "examples": [ + "827efc6d56897b048c772eb4087f854f46256132" + ] + }, + "ref": { + "type": "string", + "description": "The full Git reference, formatted as `refs/heads/`.", + "examples": [ + "refs/heads/main" + ] + }, + "timestamp": { + "type": "string", + "format": "date-time", + "description": "The time when the activity occurred.", + "examples": [ + "2011-01-26T19:06:43Z" + ] + }, + "activity_type": { + "type": "string", + "enum": [ + "push", + "force_push", + "branch_deletion", + "branch_creation", + "pr_merge", + "merge_queue_merge" + ], + "description": "The type of the activity that was performed.", + "examples": [ + "force_push" + ] + }, + "actor": { + "anyOf": [ + { + "type": "null" + }, + { + "title": "Simple User", + "description": "A GitHub user.", + "type": "object", + "properties": { + "name": { + "type": [ + "string", + "null" + ] + }, + "email": { + "type": [ + "string", + "null" + ] + }, + "login": { + "type": "string", + "examples": [ + "octocat" + ] + }, + "id": { + "type": "integer", + "examples": [ + 1 + ] + }, + "node_id": { + "type": "string", + "examples": [ + "MDQ6VXNlcjE=" + ] + }, + "avatar_url": { + "type": "string", + "format": "uri", + "examples": [ + "https://github.com/images/error/octocat_happy.gif" + ] + }, + "gravatar_id": { + "type": [ + "string", + "null" + ], + "examples": [ + "41d064eb2195891e12d0413f63227ea7" + ] + }, + "url": { + "type": "string", + "format": "uri", + "examples": [ + "https://api.github.com/users/octocat" + ] + }, + "html_url": { + "type": "string", + "format": "uri", + "examples": [ + "https://github.com/octocat" + ] + }, + "followers_url": { + "type": "string", + "format": "uri", + "examples": [ + "https://api.github.com/users/octocat/followers" + ] + }, + "following_url": { + "type": "string", + "examples": [ + "https://api.github.com/users/octocat/following{/other_user}" + ] + }, + "gists_url": { + "type": "string", + "examples": [ + "https://api.github.com/users/octocat/gists{/gist_id}" + ] + }, + "starred_url": { + "type": "string", + "examples": [ + "https://api.github.com/users/octocat/starred{/owner}{/repo}" + ] + }, + "subscriptions_url": { + "type": "string", + "format": "uri", + "examples": [ + "https://api.github.com/users/octocat/subscriptions" + ] + }, + "organizations_url": { + "type": "string", + "format": "uri", + "examples": [ + "https://api.github.com/users/octocat/orgs" + ] + }, + "repos_url": { + "type": "string", + "format": "uri", + "examples": [ + "https://api.github.com/users/octocat/repos" + ] + }, + "events_url": { + "type": "string", + "examples": [ + "https://api.github.com/users/octocat/events{/privacy}" + ] + }, + "received_events_url": { + "type": "string", + "format": "uri", + "examples": [ + "https://api.github.com/users/octocat/received_events" + ] + }, + "type": { + "type": "string", + "examples": [ + "User" + ] + }, + "site_admin": { + "type": "boolean" + }, + "starred_at": { + "type": "string", + "examples": [ + "\"2020-07-09T00:17:55Z\"" + ] + } + }, + "required": [ + "avatar_url", + "events_url", + "followers_url", + "following_url", + "gists_url", + "gravatar_id", + "html_url", + "id", + "node_id", + "login", + "organizations_url", + "received_events_url", + "repos_url", + "site_admin", + "starred_url", + "subscriptions_url", + "type", + "url" + ] + } + ] + } + }, + "required": [ + "id", + "node_id", + "before", + "after", + "ref", + "timestamp", + "activity_type", + "actor" + ] + } + } + } + } + ], + "previews": [], + "descriptionHTML": "

      Lists a detailed history of changes to a repository, such as pushes, merges, force pushes, and branch changes, and associates these changes with commits and users.

      \n

      For more information about viewing repository activity,\nsee \"Viewing repository activity.\"

      ", + "statusCodes": [ + { + "httpStatusCode": "200", + "description": "

      OK

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

      Validation failed, or the endpoint has been spammed.

      " + } + ] + }, { "serverUrl": "https://api.github.com", "verb": "get", @@ -503622,7 +504049,7 @@ }, { "name": "filter", - "description": "

      Filters results using the equals query parameter operator (eq). You can filter results that are equal to id, userName, emails, and external_id. For example, to search for an identity with the userName Octocat, you would use this query:

      \n

      ?filter=userName%20eq%20\\\"Octocat\\\".

      \n

      To filter results for the identity with the email octocat@github.com, you would use this query:

      \n

      ?filter=emails%20eq%20\\\"octocat@github.com\\\".

      ", + "description": "

      Filters results using the equals query parameter operator (eq). You can filter results that are equal to id, userName, emails, and externalId. For example, to search for an identity with the userName Octocat, you would use this query:

      \n

      ?filter=userName%20eq%20\\\"Octocat\\\".

      \n

      To filter results for the identity with the email octocat@github.com, you would use this query:

      \n

      ?filter=emails%20eq%20\\\"octocat@github.com\\\".

      ", "in": "query", "required": false, "schema": { @@ -557336,7 +557763,7 @@ } ], "previews": [], - "descriptionHTML": "

      Team members will include the members of child teams.

      \n

      To get a user's membership with a team, the team must be visible to the authenticated user.

      \n

      Note: You can also specify a team by org_id and team_id using the route GET /organizations/{org_id}/team/{team_id}/memberships/{username}.

      \n

      Note:\nThe response contains the state of the membership and the member's role.

      \n

      The role for organization owners is set to maintainer. For more information about maintainer roles, see see Create a team.

      ", + "descriptionHTML": "

      Team members will include the members of child teams.

      \n

      To get a user's membership with a team, the team must be visible to the authenticated user.

      \n

      Note: You can also specify a team by org_id and team_id using the route GET /organizations/{org_id}/team/{team_id}/memberships/{username}.

      \n

      Note:\nThe response contains the state of the membership and the member's role.

      \n

      The role for organization owners is set to maintainer. For more information about maintainer roles, see Create a team.

      ", "statusCodes": [ { "httpStatusCode": "200", diff --git a/src/rest/data/ghes-3.6/schema.json b/src/rest/data/ghes-3.6/schema.json index 24587280b2..1763b1a595 100644 --- a/src/rest/data/ghes-3.6/schema.json +++ b/src/rest/data/ghes-3.6/schema.json @@ -590,7 +590,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a redirect URL to download an archive for a repository. This URL expires after 1 minute. Look for Location: in\nthe response header to find the URL for the download. The :archive_format must be zip. Anyone with read access to\nthe repository can use this endpoint. If the repository is private you must use an access token with the repo scope.\nGitHub Apps must have the actions:read permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a redirect URL to download an archive for a repository. This URL expires after 1 minute. Look for Location: in\nthe response header to find the URL for the download. The :archive_format must be zip.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the actions:read permission to use this endpoint.

      ", "statusCodes": [ { "httpStatusCode": "302", @@ -5368,7 +5368,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all secrets available in an organization without revealing their encrypted values. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all secrets available in an organization without revealing their\nencrypted values.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -5467,7 +5467,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets your public key, which you need to encrypt secrets. You need to encrypt a secret before you can create or update secrets. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets your public key, which you need to encrypt secrets. You need to\nencrypt a secret before you can create or update secrets.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -5574,7 +5574,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a single organization secret without revealing its encrypted value. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a single organization secret without revealing its encrypted value.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -5704,7 +5704,7 @@ } ], "previews": [], - "descriptionHTML": "

      Creates or updates an organization secret with an encrypted value. Encrypt your secret using\nLibSodium. You must authenticate using an access\ntoken with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to\nuse this endpoint.

      \n

      *Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", + "descriptionHTML": "

      Creates or updates an organization secret with an encrypted value. Encrypt your secret using\nLibSodium.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      \n

      *Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -5763,7 +5763,7 @@ } ], "previews": [], - "descriptionHTML": "

      Deletes a secret in an organization using the secret name. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Deletes a secret in an organization using the secret name.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -6669,7 +6669,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all repositories that have been selected when the visibility for repository access to a secret is set to selected. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all repositories that have been selected when the visibility\nfor repository access to a secret is set to selected.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -6738,7 +6738,7 @@ } ], "previews": [], - "descriptionHTML": "

      Replaces all repositories for an organization secret when the visibility for repository access is set to selected. The visibility is set when you Create or update an organization secret. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Replaces all repositories for an organization secret when the visibility\nfor repository access is set to selected. The visibility is set when you Create\nor update an organization secret.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -6803,7 +6803,7 @@ } ], "previews": [], - "descriptionHTML": "

      Adds a repository to an organization secret when the visibility for repository access is set to selected. The visibility is set when you Create or update an organization secret. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Adds a repository to an organization secret when the visibility for\nrepository access is set to selected. The visibility is set when you Create or\nupdate an organization secret.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -6872,7 +6872,7 @@ } ], "previews": [], - "descriptionHTML": "

      Removes a repository from an organization secret when the visibility for repository access is set to selected. The visibility is set when you Create or update an organization secret. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Removes a repository from an organization secret when the visibility\nfor repository access is set to selected. The visibility is set when you Create\nor update an organization secret.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -7007,7 +7007,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all secrets available in a repository without revealing their encrypted values. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all secrets available in a repository without revealing their encrypted\nvalues.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -7116,7 +7116,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets your public key, which you need to encrypt secrets. You need to encrypt a secret before you can create or update secrets. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the repo scope. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets your public key, which you need to encrypt secrets. You need to\nencrypt a secret before you can create or update secrets.

      \n

      Anyone with read access to the repository can use this endpoint.\nIf the repository is private you must use an access token with the repo scope.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -7214,7 +7214,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a single repository secret without revealing its encrypted value. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a single repository secret without revealing its encrypted value.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -7327,7 +7327,7 @@ } ], "previews": [], - "descriptionHTML": "

      Creates or updates a repository secret with an encrypted value. Encrypt your secret using\nLibSodium. You must authenticate using an access\ntoken with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use\nthis endpoint.

      \n

      Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", + "descriptionHTML": "

      Creates or updates a repository secret with an encrypted value. Encrypt your secret using\nLibSodium.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      \n

      Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -7396,7 +7396,7 @@ } ], "previews": [], - "descriptionHTML": "

      Deletes a secret in a repository using the secret name. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Deletes a secret in a repository using the secret name.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -7527,7 +7527,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all secrets available in an environment without revealing their encrypted values. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all secrets available in an environment without revealing their\nencrypted values.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -7636,7 +7636,7 @@ } ], "previews": [], - "descriptionHTML": "

      Get the public key for an environment, which you need to encrypt environment secrets. You need to encrypt a secret before you can create or update secrets. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the repo scope. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Get the public key for an environment, which you need to encrypt environment\nsecrets. You need to encrypt a secret before you can create or update secrets.

      \n

      Anyone with read access to the repository can use this endpoint.\nIf the repository is private you must use an access token with the repo scope.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -7734,7 +7734,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a single environment secret without revealing its encrypted value. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a single environment secret without revealing its encrypted value.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -7849,7 +7849,7 @@ } ], "previews": [], - "descriptionHTML": "

      Creates or updates an environment secret with an encrypted value. Encrypt your secret using\nLibSodium. You must authenticate using an access\ntoken with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use\nthis endpoint.

      \n

      Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", + "descriptionHTML": "

      Creates or updates an environment secret with an encrypted value. Encrypt your secret using\nLibSodium.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      \n

      Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -7918,7 +7918,7 @@ } ], "previews": [], - "descriptionHTML": "

      Deletes a secret in an environment using the secret name. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Deletes a secret in an environment using the secret name.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -16524,7 +16524,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all self-hosted runners configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists all self-hosted runners configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -16647,7 +16647,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists binaries for the runner application that you can download and run.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists binaries for the runner application that you can download and run.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -18214,7 +18214,7 @@ } ], "previews": [], - "descriptionHTML": "

      Returns a token that you can pass to the config script. The token expires after one hour.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      \n

      Example using registration token:

      \n

      Configure your self-hosted runner, replacing TOKEN with the registration token provided by this endpoint.

      \n
      ./config.sh --url https://github.com/octo-org --token TOKEN\n
      ", + "descriptionHTML": "

      Returns a token that you can pass to the config script. The token expires after one hour.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      \n

      Example using registration token:

      \n

      Configure your self-hosted runner, replacing TOKEN with the registration token provided by this endpoint.

      \n
      ./config.sh --url https://github.com/octo-org --token TOKEN\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -19781,7 +19781,7 @@ } ], "previews": [], - "descriptionHTML": "

      Returns a token that you can pass to the config script to remove a self-hosted runner from an organization. The token expires after one hour.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      \n

      Example using remove token:

      \n

      To remove your self-hosted runner from an organization, replace TOKEN with the remove token provided by this\nendpoint.

      \n
      ./config.sh remove --token TOKEN\n
      ", + "descriptionHTML": "

      Returns a token that you can pass to the config script to remove a self-hosted runner from an organization. The token expires after one hour.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      \n

      Example using remove token:

      \n

      To remove your self-hosted runner from an organization, replace TOKEN with the remove token provided by this\nendpoint.

      \n
      ./config.sh remove --token TOKEN\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -19948,7 +19948,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a specific self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Gets a specific self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -20003,7 +20003,7 @@ } ], "previews": [], - "descriptionHTML": "

      Forces the removal of a self-hosted runner from an organization. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Forces the removal of a self-hosted runner from an organization. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -20125,7 +20125,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all labels for a self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists all labels for a self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -20266,7 +20266,7 @@ } ], "previews": [], - "descriptionHTML": "

      Add custom labels to a self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Add custom labels to a self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -20411,7 +20411,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove all previous custom labels and set the new custom labels for a specific\nself-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Remove all previous custom labels and set the new custom labels for a specific\nself-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -20536,7 +20536,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove all custom labels from a self-hosted runner configured in an\norganization. Returns the remaining read-only labels from the runner.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Remove all custom labels from a self-hosted runner configured in an\norganization. Returns the remaining read-only labels from the runner.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -20672,7 +20672,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove a custom label from a self-hosted runner configured\nin an organization. Returns the remaining labels from the runner.

      \n

      This endpoint returns a 404 Not Found status if the custom label is not\npresent on the runner.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Remove a custom label from a self-hosted runner configured\nin an organization. Returns the remaining labels from the runner.

      \n

      This endpoint returns a 404 Not Found status if the custom label is not\npresent on the runner.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -20909,7 +20909,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all self-hosted runners configured in a repository. You must authenticate using an access token with the repo scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists all self-hosted runners configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -21042,7 +21042,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists binaries for the runner application that you can download and run.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists binaries for the runner application that you can download and run.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -22619,7 +22619,7 @@ } ], "previews": [], - "descriptionHTML": "

      Returns a token that you can pass to the config script. The token expires after one hour. You must authenticate using an access token with the repo scope to use this endpoint.

      \n

      Example using registration token:

      \n

      Configure your self-hosted runner, replacing TOKEN with the registration token provided by this endpoint.

      \n
      ./config.sh --url https://github.com/octo-org/octo-repo-artifacts --token TOKEN\n
      ", + "descriptionHTML": "

      Returns a token that you can pass to the config script. The token\nexpires after one hour.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      \n

      Example using registration token:

      \n

      Configure your self-hosted runner, replacing TOKEN with the registration token provided\nby this endpoint.

      \n

      config.sh --url https://github.com/octo-org/octo-repo-artifacts --token TOKEN

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -24196,7 +24196,7 @@ } ], "previews": [], - "descriptionHTML": "

      Returns a token that you can pass to remove a self-hosted runner from a repository. The token expires after one hour.\nYou must authenticate using an access token with the repo scope to use this endpoint.

      \n

      Example using remove token:

      \n

      To remove your self-hosted runner from a repository, replace TOKEN with the remove token provided by this endpoint.

      \n
      ./config.sh remove --token TOKEN\n
      ", + "descriptionHTML": "

      Returns a token that you can pass to remove a self-hosted runner from\na repository. The token expires after one hour.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      \n

      Example using remove token:

      \n

      To remove your self-hosted runner from a repository, replace TOKEN with\nthe remove token provided by this endpoint.

      \n

      config.sh remove --token TOKEN

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -24373,7 +24373,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a specific self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Gets a specific self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -24438,7 +24438,7 @@ } ], "previews": [], - "descriptionHTML": "

      Forces the removal of a self-hosted runner from a repository. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.

      \n

      You must authenticate using an access token with the repo\nscope to use this endpoint.

      ", + "descriptionHTML": "

      Forces the removal of a self-hosted runner from a repository. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -24570,7 +24570,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all labels for a self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Lists all labels for a self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -24721,7 +24721,7 @@ } ], "previews": [], - "descriptionHTML": "

      Add custom labels to a self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Add custom labels to a self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -24876,7 +24876,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove all previous custom labels and set the new custom labels for a specific\nself-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Remove all previous custom labels and set the new custom labels for a specific\nself-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -25011,7 +25011,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove all custom labels from a self-hosted runner configured in a\nrepository. Returns the remaining read-only labels from the runner.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Remove all custom labels from a self-hosted runner configured in a\nrepository. Returns the remaining read-only labels from the runner.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -25157,7 +25157,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove a custom label from a self-hosted runner configured\nin a repository. Returns the remaining labels from the runner.

      \n

      This endpoint returns a 404 Not Found status if the custom label is not\npresent on the runner.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Remove a custom label from a self-hosted runner configured\nin a repository. Returns the remaining labels from the runner.

      \n

      This endpoint returns a 404 Not Found status if the custom label is not\npresent on the runner.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -26754,7 +26754,7 @@ } ], "previews": [], - "descriptionHTML": "

      Re-run a job and its dependent jobs in a workflow run. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the actions:write permission to use this endpoint.

      ", + "descriptionHTML": "

      Re-run a job and its dependent jobs in a workflow run.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions:write permission to use this endpoint.

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -35156,7 +35156,7 @@ } ], "previews": [], - "descriptionHTML": "

      Cancels a workflow run using its id. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the actions:write permission to use this endpoint.

      ", + "descriptionHTML": "

      Cancels a workflow run using its id.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions:write permission to use this endpoint.

      ", "statusCodes": [ { "httpStatusCode": "202", @@ -174433,7 +174433,7 @@ }, { "httpStatusCode": "403", - "description": "

      Forbidden

      " + "description": "

      Response if GitHub Advanced Security is not enabled for this repository

      " }, { "httpStatusCode": "404", @@ -457319,7 +457319,7 @@ } ], "previews": [], - "descriptionHTML": "

      Team members will include the members of child teams.

      \n

      To get a user's membership with a team, the team must be visible to the authenticated user.

      \n

      Note: You can also specify a team by org_id and team_id using the route GET /organizations/{org_id}/team/{team_id}/memberships/{username}.

      \n

      Note:\nThe response contains the state of the membership and the member's role.

      \n

      The role for organization owners is set to maintainer. For more information about maintainer roles, see see Create a team.

      ", + "descriptionHTML": "

      Team members will include the members of child teams.

      \n

      To get a user's membership with a team, the team must be visible to the authenticated user.

      \n

      Note: You can also specify a team by org_id and team_id using the route GET /organizations/{org_id}/team/{team_id}/memberships/{username}.

      \n

      Note:\nThe response contains the state of the membership and the member's role.

      \n

      The role for organization owners is set to maintainer. For more information about maintainer roles, see Create a team.

      ", "statusCodes": [ { "httpStatusCode": "200", diff --git a/src/rest/data/ghes-3.7/schema.json b/src/rest/data/ghes-3.7/schema.json index b9fb593cbc..b5cd72b7cc 100644 --- a/src/rest/data/ghes-3.7/schema.json +++ b/src/rest/data/ghes-3.7/schema.json @@ -590,7 +590,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a redirect URL to download an archive for a repository. This URL expires after 1 minute. Look for Location: in\nthe response header to find the URL for the download. The :archive_format must be zip. Anyone with read access to\nthe repository can use this endpoint. If the repository is private you must use an access token with the repo scope.\nGitHub Apps must have the actions:read permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a redirect URL to download an archive for a repository. This URL expires after 1 minute. Look for Location: in\nthe response header to find the URL for the download. The :archive_format must be zip.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the actions:read permission to use this endpoint.

      ", "statusCodes": [ { "httpStatusCode": "302", @@ -6134,7 +6134,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all secrets available in an organization without revealing their encrypted values. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all secrets available in an organization without revealing their\nencrypted values.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -6233,7 +6233,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets your public key, which you need to encrypt secrets. You need to encrypt a secret before you can create or update secrets. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets your public key, which you need to encrypt secrets. You need to\nencrypt a secret before you can create or update secrets.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -6340,7 +6340,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a single organization secret without revealing its encrypted value. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a single organization secret without revealing its encrypted value.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -6470,7 +6470,7 @@ } ], "previews": [], - "descriptionHTML": "

      Creates or updates an organization secret with an encrypted value. Encrypt your secret using\nLibSodium. You must authenticate using an access\ntoken with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to\nuse this endpoint.

      \n

      *Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", + "descriptionHTML": "

      Creates or updates an organization secret with an encrypted value. Encrypt your secret using\nLibSodium.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      \n

      *Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -6529,7 +6529,7 @@ } ], "previews": [], - "descriptionHTML": "

      Deletes a secret in an organization using the secret name. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Deletes a secret in an organization using the secret name.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -7438,7 +7438,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all repositories that have been selected when the visibility for repository access to a secret is set to selected. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all repositories that have been selected when the visibility\nfor repository access to a secret is set to selected.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -7507,7 +7507,7 @@ } ], "previews": [], - "descriptionHTML": "

      Replaces all repositories for an organization secret when the visibility for repository access is set to selected. The visibility is set when you Create or update an organization secret. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Replaces all repositories for an organization secret when the visibility\nfor repository access is set to selected. The visibility is set when you Create\nor update an organization secret.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -7572,7 +7572,7 @@ } ], "previews": [], - "descriptionHTML": "

      Adds a repository to an organization secret when the visibility for repository access is set to selected. The visibility is set when you Create or update an organization secret. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Adds a repository to an organization secret when the visibility for\nrepository access is set to selected. The visibility is set when you Create or\nupdate an organization secret.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -7641,7 +7641,7 @@ } ], "previews": [], - "descriptionHTML": "

      Removes a repository from an organization secret when the visibility for repository access is set to selected. The visibility is set when you Create or update an organization secret. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Removes a repository from an organization secret when the visibility\nfor repository access is set to selected. The visibility is set when you Create\nor update an organization secret.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -7776,7 +7776,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all secrets available in a repository without revealing their encrypted values. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all secrets available in a repository without revealing their encrypted\nvalues.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -7885,7 +7885,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets your public key, which you need to encrypt secrets. You need to encrypt a secret before you can create or update secrets. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the repo scope. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets your public key, which you need to encrypt secrets. You need to\nencrypt a secret before you can create or update secrets.

      \n

      Anyone with read access to the repository can use this endpoint.\nIf the repository is private you must use an access token with the repo scope.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -7983,7 +7983,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a single repository secret without revealing its encrypted value. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a single repository secret without revealing its encrypted value.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -8096,7 +8096,7 @@ } ], "previews": [], - "descriptionHTML": "

      Creates or updates a repository secret with an encrypted value. Encrypt your secret using\nLibSodium. You must authenticate using an access\ntoken with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use\nthis endpoint.

      \n

      Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", + "descriptionHTML": "

      Creates or updates a repository secret with an encrypted value. Encrypt your secret using\nLibSodium.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      \n

      Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -8165,7 +8165,7 @@ } ], "previews": [], - "descriptionHTML": "

      Deletes a secret in a repository using the secret name. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Deletes a secret in a repository using the secret name.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -8296,7 +8296,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all secrets available in an environment without revealing their encrypted values. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all secrets available in an environment without revealing their\nencrypted values.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -8405,7 +8405,7 @@ } ], "previews": [], - "descriptionHTML": "

      Get the public key for an environment, which you need to encrypt environment secrets. You need to encrypt a secret before you can create or update secrets. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the repo scope. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Get the public key for an environment, which you need to encrypt environment\nsecrets. You need to encrypt a secret before you can create or update secrets.

      \n

      Anyone with read access to the repository can use this endpoint.\nIf the repository is private you must use an access token with the repo scope.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -8503,7 +8503,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a single environment secret without revealing its encrypted value. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a single environment secret without revealing its encrypted value.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -8618,7 +8618,7 @@ } ], "previews": [], - "descriptionHTML": "

      Creates or updates an environment secret with an encrypted value. Encrypt your secret using\nLibSodium. You must authenticate using an access\ntoken with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use\nthis endpoint.

      \n

      Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", + "descriptionHTML": "

      Creates or updates an environment secret with an encrypted value. Encrypt your secret using\nLibSodium.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      \n

      Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -8687,7 +8687,7 @@ } ], "previews": [], - "descriptionHTML": "

      Deletes a secret in an environment using the secret name. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Deletes a secret in an environment using the secret name.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -17312,7 +17312,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all self-hosted runners configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists all self-hosted runners configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -17435,7 +17435,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists binaries for the runner application that you can download and run.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists binaries for the runner application that you can download and run.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -19010,7 +19010,7 @@ } ], "previews": [], - "descriptionHTML": "

      Returns a token that you can pass to the config script. The token expires after one hour.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      \n

      Example using registration token:

      \n

      Configure your self-hosted runner, replacing TOKEN with the registration token provided by this endpoint.

      \n
      ./config.sh --url https://github.com/octo-org --token TOKEN\n
      ", + "descriptionHTML": "

      Returns a token that you can pass to the config script. The token expires after one hour.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      \n

      Example using registration token:

      \n

      Configure your self-hosted runner, replacing TOKEN with the registration token provided by this endpoint.

      \n
      ./config.sh --url https://github.com/octo-org --token TOKEN\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -20585,7 +20585,7 @@ } ], "previews": [], - "descriptionHTML": "

      Returns a token that you can pass to the config script to remove a self-hosted runner from an organization. The token expires after one hour.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      \n

      Example using remove token:

      \n

      To remove your self-hosted runner from an organization, replace TOKEN with the remove token provided by this\nendpoint.

      \n
      ./config.sh remove --token TOKEN\n
      ", + "descriptionHTML": "

      Returns a token that you can pass to the config script to remove a self-hosted runner from an organization. The token expires after one hour.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      \n

      Example using remove token:

      \n

      To remove your self-hosted runner from an organization, replace TOKEN with the remove token provided by this\nendpoint.

      \n
      ./config.sh remove --token TOKEN\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -20752,7 +20752,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a specific self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Gets a specific self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -20807,7 +20807,7 @@ } ], "previews": [], - "descriptionHTML": "

      Forces the removal of a self-hosted runner from an organization. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Forces the removal of a self-hosted runner from an organization. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -20929,7 +20929,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all labels for a self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists all labels for a self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -21070,7 +21070,7 @@ } ], "previews": [], - "descriptionHTML": "

      Add custom labels to a self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Add custom labels to a self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -21215,7 +21215,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove all previous custom labels and set the new custom labels for a specific\nself-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Remove all previous custom labels and set the new custom labels for a specific\nself-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -21340,7 +21340,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove all custom labels from a self-hosted runner configured in an\norganization. Returns the remaining read-only labels from the runner.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Remove all custom labels from a self-hosted runner configured in an\norganization. Returns the remaining read-only labels from the runner.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -21476,7 +21476,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove a custom label from a self-hosted runner configured\nin an organization. Returns the remaining labels from the runner.

      \n

      This endpoint returns a 404 Not Found status if the custom label is not\npresent on the runner.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Remove a custom label from a self-hosted runner configured\nin an organization. Returns the remaining labels from the runner.

      \n

      This endpoint returns a 404 Not Found status if the custom label is not\npresent on the runner.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -21713,7 +21713,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all self-hosted runners configured in a repository. You must authenticate using an access token with the repo scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists all self-hosted runners configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -21846,7 +21846,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists binaries for the runner application that you can download and run.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists binaries for the runner application that you can download and run.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -23431,7 +23431,7 @@ } ], "previews": [], - "descriptionHTML": "

      Returns a token that you can pass to the config script. The token expires after one hour. You must authenticate using an access token with the repo scope to use this endpoint.

      \n

      Example using registration token:

      \n

      Configure your self-hosted runner, replacing TOKEN with the registration token provided by this endpoint.

      \n
      ./config.sh --url https://github.com/octo-org/octo-repo-artifacts --token TOKEN\n
      ", + "descriptionHTML": "

      Returns a token that you can pass to the config script. The token\nexpires after one hour.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      \n

      Example using registration token:

      \n

      Configure your self-hosted runner, replacing TOKEN with the registration token provided\nby this endpoint.

      \n

      config.sh --url https://github.com/octo-org/octo-repo-artifacts --token TOKEN

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -25016,7 +25016,7 @@ } ], "previews": [], - "descriptionHTML": "

      Returns a token that you can pass to remove a self-hosted runner from a repository. The token expires after one hour.\nYou must authenticate using an access token with the repo scope to use this endpoint.

      \n

      Example using remove token:

      \n

      To remove your self-hosted runner from a repository, replace TOKEN with the remove token provided by this endpoint.

      \n
      ./config.sh remove --token TOKEN\n
      ", + "descriptionHTML": "

      Returns a token that you can pass to remove a self-hosted runner from\na repository. The token expires after one hour.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      \n

      Example using remove token:

      \n

      To remove your self-hosted runner from a repository, replace TOKEN with\nthe remove token provided by this endpoint.

      \n

      config.sh remove --token TOKEN

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -25193,7 +25193,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a specific self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Gets a specific self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -25258,7 +25258,7 @@ } ], "previews": [], - "descriptionHTML": "

      Forces the removal of a self-hosted runner from a repository. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.

      \n

      You must authenticate using an access token with the repo\nscope to use this endpoint.

      ", + "descriptionHTML": "

      Forces the removal of a self-hosted runner from a repository. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -25390,7 +25390,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all labels for a self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Lists all labels for a self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -25541,7 +25541,7 @@ } ], "previews": [], - "descriptionHTML": "

      Add custom labels to a self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Add custom labels to a self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -25696,7 +25696,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove all previous custom labels and set the new custom labels for a specific\nself-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Remove all previous custom labels and set the new custom labels for a specific\nself-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -25831,7 +25831,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove all custom labels from a self-hosted runner configured in a\nrepository. Returns the remaining read-only labels from the runner.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Remove all custom labels from a self-hosted runner configured in a\nrepository. Returns the remaining read-only labels from the runner.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -25977,7 +25977,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove a custom label from a self-hosted runner configured\nin a repository. Returns the remaining labels from the runner.

      \n

      This endpoint returns a 404 Not Found status if the custom label is not\npresent on the runner.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Remove a custom label from a self-hosted runner configured\nin a repository. Returns the remaining labels from the runner.

      \n

      This endpoint returns a 404 Not Found status if the custom label is not\npresent on the runner.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -27574,7 +27574,7 @@ } ], "previews": [], - "descriptionHTML": "

      Re-run a job and its dependent jobs in a workflow run. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the actions:write permission to use this endpoint.

      ", + "descriptionHTML": "

      Re-run a job and its dependent jobs in a workflow run.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions:write permission to use this endpoint.

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -36003,7 +36003,7 @@ } ], "previews": [], - "descriptionHTML": "

      Cancels a workflow run using its id. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the actions:write permission to use this endpoint.

      ", + "descriptionHTML": "

      Cancels a workflow run using its id.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions:write permission to use this endpoint.

      ", "statusCodes": [ { "httpStatusCode": "202", @@ -176885,7 +176885,7 @@ }, { "httpStatusCode": "403", - "description": "

      Forbidden

      " + "description": "

      Response if GitHub Advanced Security is not enabled for this repository

      " }, { "httpStatusCode": "404", @@ -461239,7 +461239,7 @@ } ], "previews": [], - "descriptionHTML": "

      Team members will include the members of child teams.

      \n

      To get a user's membership with a team, the team must be visible to the authenticated user.

      \n

      Note: You can also specify a team by org_id and team_id using the route GET /organizations/{org_id}/team/{team_id}/memberships/{username}.

      \n

      Note:\nThe response contains the state of the membership and the member's role.

      \n

      The role for organization owners is set to maintainer. For more information about maintainer roles, see see Create a team.

      ", + "descriptionHTML": "

      Team members will include the members of child teams.

      \n

      To get a user's membership with a team, the team must be visible to the authenticated user.

      \n

      Note: You can also specify a team by org_id and team_id using the route GET /organizations/{org_id}/team/{team_id}/memberships/{username}.

      \n

      Note:\nThe response contains the state of the membership and the member's role.

      \n

      The role for organization owners is set to maintainer. For more information about maintainer roles, see Create a team.

      ", "statusCodes": [ { "httpStatusCode": "200", diff --git a/src/rest/data/ghes-3.8/schema.json b/src/rest/data/ghes-3.8/schema.json index 90017bd0c9..63237f5808 100644 --- a/src/rest/data/ghes-3.8/schema.json +++ b/src/rest/data/ghes-3.8/schema.json @@ -599,7 +599,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a redirect URL to download an archive for a repository. This URL expires after 1 minute. Look for Location: in\nthe response header to find the URL for the download. The :archive_format must be zip. Anyone with read access to\nthe repository can use this endpoint. If the repository is private you must use an access token with the repo scope.\nGitHub Apps must have the actions:read permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a redirect URL to download an archive for a repository. This URL expires after 1 minute. Look for Location: in\nthe response header to find the URL for the download. The :archive_format must be zip.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the actions:read permission to use this endpoint.

      ", "statusCodes": [ { "httpStatusCode": "302", @@ -6155,7 +6155,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all secrets available in an organization without revealing their encrypted values. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all secrets available in an organization without revealing their\nencrypted values.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -6254,7 +6254,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets your public key, which you need to encrypt secrets. You need to encrypt a secret before you can create or update secrets. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets your public key, which you need to encrypt secrets. You need to\nencrypt a secret before you can create or update secrets.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -6361,7 +6361,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a single organization secret without revealing its encrypted value. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a single organization secret without revealing its encrypted value.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -6491,7 +6491,7 @@ } ], "previews": [], - "descriptionHTML": "

      Creates or updates an organization secret with an encrypted value. Encrypt your secret using\nLibSodium. You must authenticate using an access\ntoken with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to\nuse this endpoint.

      \n

      *Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", + "descriptionHTML": "

      Creates or updates an organization secret with an encrypted value. Encrypt your secret using\nLibSodium.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      \n

      *Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -6550,7 +6550,7 @@ } ], "previews": [], - "descriptionHTML": "

      Deletes a secret in an organization using the secret name. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Deletes a secret in an organization using the secret name.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -7459,7 +7459,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all repositories that have been selected when the visibility for repository access to a secret is set to selected. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all repositories that have been selected when the visibility\nfor repository access to a secret is set to selected.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -7528,7 +7528,7 @@ } ], "previews": [], - "descriptionHTML": "

      Replaces all repositories for an organization secret when the visibility for repository access is set to selected. The visibility is set when you Create or update an organization secret. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Replaces all repositories for an organization secret when the visibility\nfor repository access is set to selected. The visibility is set when you Create\nor update an organization secret.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -7593,7 +7593,7 @@ } ], "previews": [], - "descriptionHTML": "

      Adds a repository to an organization secret when the visibility for repository access is set to selected. The visibility is set when you Create or update an organization secret. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Adds a repository to an organization secret when the visibility for\nrepository access is set to selected. The visibility is set when you Create or\nupdate an organization secret.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -7662,7 +7662,7 @@ } ], "previews": [], - "descriptionHTML": "

      Removes a repository from an organization secret when the visibility for repository access is set to selected. The visibility is set when you Create or update an organization secret. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Removes a repository from an organization secret when the visibility\nfor repository access is set to selected. The visibility is set when you Create\nor update an organization secret.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -7797,7 +7797,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all secrets available in a repository without revealing their encrypted values. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all secrets available in a repository without revealing their encrypted\nvalues.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -7906,7 +7906,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets your public key, which you need to encrypt secrets. You need to encrypt a secret before you can create or update secrets. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the repo scope. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets your public key, which you need to encrypt secrets. You need to\nencrypt a secret before you can create or update secrets.

      \n

      Anyone with read access to the repository can use this endpoint.\nIf the repository is private you must use an access token with the repo scope.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -8004,7 +8004,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a single repository secret without revealing its encrypted value. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a single repository secret without revealing its encrypted value.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -8117,7 +8117,7 @@ } ], "previews": [], - "descriptionHTML": "

      Creates or updates a repository secret with an encrypted value. Encrypt your secret using\nLibSodium. You must authenticate using an access\ntoken with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use\nthis endpoint.

      \n

      Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", + "descriptionHTML": "

      Creates or updates a repository secret with an encrypted value. Encrypt your secret using\nLibSodium.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      \n

      Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -8186,7 +8186,7 @@ } ], "previews": [], - "descriptionHTML": "

      Deletes a secret in a repository using the secret name. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Deletes a secret in a repository using the secret name.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -8317,7 +8317,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all secrets available in an environment without revealing their encrypted values. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all secrets available in an environment without revealing their\nencrypted values.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -8426,7 +8426,7 @@ } ], "previews": [], - "descriptionHTML": "

      Get the public key for an environment, which you need to encrypt environment secrets. You need to encrypt a secret before you can create or update secrets. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the repo scope. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Get the public key for an environment, which you need to encrypt environment\nsecrets. You need to encrypt a secret before you can create or update secrets.

      \n

      Anyone with read access to the repository can use this endpoint.\nIf the repository is private you must use an access token with the repo scope.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -8524,7 +8524,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a single environment secret without revealing its encrypted value. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a single environment secret without revealing its encrypted value.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -8639,7 +8639,7 @@ } ], "previews": [], - "descriptionHTML": "

      Creates or updates an environment secret with an encrypted value. Encrypt your secret using\nLibSodium. You must authenticate using an access\ntoken with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use\nthis endpoint.

      \n

      Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", + "descriptionHTML": "

      Creates or updates an environment secret with an encrypted value. Encrypt your secret using\nLibSodium.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      \n

      Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -8708,7 +8708,7 @@ } ], "previews": [], - "descriptionHTML": "

      Deletes a secret in an environment using the secret name. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Deletes a secret in an environment using the secret name.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -17333,7 +17333,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all self-hosted runners configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists all self-hosted runners configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -17456,7 +17456,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists binaries for the runner application that you can download and run.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists binaries for the runner application that you can download and run.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -19031,7 +19031,7 @@ } ], "previews": [], - "descriptionHTML": "

      Returns a token that you can pass to the config script. The token expires after one hour.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      \n

      Example using registration token:

      \n

      Configure your self-hosted runner, replacing TOKEN with the registration token provided by this endpoint.

      \n
      ./config.sh --url https://github.com/octo-org --token TOKEN\n
      ", + "descriptionHTML": "

      Returns a token that you can pass to the config script. The token expires after one hour.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      \n

      Example using registration token:

      \n

      Configure your self-hosted runner, replacing TOKEN with the registration token provided by this endpoint.

      \n
      ./config.sh --url https://github.com/octo-org --token TOKEN\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -20606,7 +20606,7 @@ } ], "previews": [], - "descriptionHTML": "

      Returns a token that you can pass to the config script to remove a self-hosted runner from an organization. The token expires after one hour.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      \n

      Example using remove token:

      \n

      To remove your self-hosted runner from an organization, replace TOKEN with the remove token provided by this\nendpoint.

      \n
      ./config.sh remove --token TOKEN\n
      ", + "descriptionHTML": "

      Returns a token that you can pass to the config script to remove a self-hosted runner from an organization. The token expires after one hour.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      \n

      Example using remove token:

      \n

      To remove your self-hosted runner from an organization, replace TOKEN with the remove token provided by this\nendpoint.

      \n
      ./config.sh remove --token TOKEN\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -20773,7 +20773,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a specific self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Gets a specific self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -20828,7 +20828,7 @@ } ], "previews": [], - "descriptionHTML": "

      Forces the removal of a self-hosted runner from an organization. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Forces the removal of a self-hosted runner from an organization. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -20950,7 +20950,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all labels for a self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists all labels for a self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -21091,7 +21091,7 @@ } ], "previews": [], - "descriptionHTML": "

      Add custom labels to a self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Add custom labels to a self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -21236,7 +21236,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove all previous custom labels and set the new custom labels for a specific\nself-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Remove all previous custom labels and set the new custom labels for a specific\nself-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -21361,7 +21361,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove all custom labels from a self-hosted runner configured in an\norganization. Returns the remaining read-only labels from the runner.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Remove all custom labels from a self-hosted runner configured in an\norganization. Returns the remaining read-only labels from the runner.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -21497,7 +21497,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove a custom label from a self-hosted runner configured\nin an organization. Returns the remaining labels from the runner.

      \n

      This endpoint returns a 404 Not Found status if the custom label is not\npresent on the runner.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Remove a custom label from a self-hosted runner configured\nin an organization. Returns the remaining labels from the runner.

      \n

      This endpoint returns a 404 Not Found status if the custom label is not\npresent on the runner.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -21734,7 +21734,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all self-hosted runners configured in a repository. You must authenticate using an access token with the repo scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists all self-hosted runners configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -21867,7 +21867,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists binaries for the runner application that you can download and run.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists binaries for the runner application that you can download and run.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -23452,7 +23452,7 @@ } ], "previews": [], - "descriptionHTML": "

      Returns a token that you can pass to the config script. The token expires after one hour. You must authenticate using an access token with the repo scope to use this endpoint.

      \n

      Example using registration token:

      \n

      Configure your self-hosted runner, replacing TOKEN with the registration token provided by this endpoint.

      \n
      ./config.sh --url https://github.com/octo-org/octo-repo-artifacts --token TOKEN\n
      ", + "descriptionHTML": "

      Returns a token that you can pass to the config script. The token\nexpires after one hour.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      \n

      Example using registration token:

      \n

      Configure your self-hosted runner, replacing TOKEN with the registration token provided\nby this endpoint.

      \n

      config.sh --url https://github.com/octo-org/octo-repo-artifacts --token TOKEN

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -25037,7 +25037,7 @@ } ], "previews": [], - "descriptionHTML": "

      Returns a token that you can pass to remove a self-hosted runner from a repository. The token expires after one hour.\nYou must authenticate using an access token with the repo scope to use this endpoint.

      \n

      Example using remove token:

      \n

      To remove your self-hosted runner from a repository, replace TOKEN with the remove token provided by this endpoint.

      \n
      ./config.sh remove --token TOKEN\n
      ", + "descriptionHTML": "

      Returns a token that you can pass to remove a self-hosted runner from\na repository. The token expires after one hour.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      \n

      Example using remove token:

      \n

      To remove your self-hosted runner from a repository, replace TOKEN with\nthe remove token provided by this endpoint.

      \n

      config.sh remove --token TOKEN

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -25214,7 +25214,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a specific self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Gets a specific self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -25279,7 +25279,7 @@ } ], "previews": [], - "descriptionHTML": "

      Forces the removal of a self-hosted runner from a repository. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.

      \n

      You must authenticate using an access token with the repo\nscope to use this endpoint.

      ", + "descriptionHTML": "

      Forces the removal of a self-hosted runner from a repository. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -25411,7 +25411,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all labels for a self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Lists all labels for a self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -25562,7 +25562,7 @@ } ], "previews": [], - "descriptionHTML": "

      Add custom labels to a self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Add custom labels to a self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -25717,7 +25717,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove all previous custom labels and set the new custom labels for a specific\nself-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Remove all previous custom labels and set the new custom labels for a specific\nself-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -25852,7 +25852,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove all custom labels from a self-hosted runner configured in a\nrepository. Returns the remaining read-only labels from the runner.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Remove all custom labels from a self-hosted runner configured in a\nrepository. Returns the remaining read-only labels from the runner.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -25998,7 +25998,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove a custom label from a self-hosted runner configured\nin a repository. Returns the remaining labels from the runner.

      \n

      This endpoint returns a 404 Not Found status if the custom label is not\npresent on the runner.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Remove a custom label from a self-hosted runner configured\nin a repository. Returns the remaining labels from the runner.

      \n

      This endpoint returns a 404 Not Found status if the custom label is not\npresent on the runner.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -26174,7 +26174,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all organization variables. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the organization_actions_variables:read organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all organization variables.\nYou must authenticate using an access token with the admin:org scope to use this endpoint. If the repository is private, you must use an access token with the repo scope. GitHub Apps must have the organization_actions_variables:read organization permission to use this endpoint. Authenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -26271,7 +26271,7 @@ } ], "previews": [], - "descriptionHTML": "

      Creates an organization variable that you can reference in a GitHub Actions workflow.\nYou must authenticate using an access token with the admin:org scope to use this endpoint.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Creates an organization variable that you can reference in a GitHub Actions workflow.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -26395,7 +26395,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a specific variable in an organization. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the organization_actions_variables:read organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a specific variable in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the organization_actions_variables:read organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -26490,7 +26490,7 @@ } ], "previews": [], - "descriptionHTML": "

      Updates an organization variable that you can reference in a GitHub Actions workflow.\nYou must authenticate using an access token with the admin:org scope to use this endpoint.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Updates an organization variable that you can reference in a GitHub Actions workflow.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -26545,7 +26545,7 @@ } ], "previews": [], - "descriptionHTML": "

      Deletes an organization variable using the variable name.\nYou must authenticate using an access token with the admin:org scope to use this endpoint.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Deletes an organization variable using the variable name.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -27454,7 +27454,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all repositories that can access an organization variable that is available to selected repositories. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the organization_actions_variables:read organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all repositories that can access an organization variable\nthat is available to selected repositories.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the organization_actions_variables:read organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -27527,7 +27527,7 @@ } ], "previews": [], - "descriptionHTML": "

      Replaces all repositories for an organization variable that is available to selected repositories. Organization variables that are available to selected repositories have their visibility field set to selected. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Replaces all repositories for an organization variable that is available\nto selected repositories. Organization variables that are available to selected\nrepositories have their visibility field set to selected.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this\nendpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -27596,7 +27596,7 @@ } ], "previews": [], - "descriptionHTML": "

      Adds a repository to an organization variable that is available to selected repositories. Organization variables that are available to selected repositories have their visibility field set to selected. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Adds a repository to an organization variable that is available to selected repositories.\nOrganization variables that are available to selected repositories have their visibility field set to selected.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -27665,7 +27665,7 @@ } ], "previews": [], - "descriptionHTML": "

      Removes a repository from an organization variable that is available to selected repositories. Organization variables that are available to selected repositories have their visibility field set to selected. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Removes a repository from an organization variable that is\navailable to selected repositories. Organization variables that are available to\nselected repositories have their visibility field set to selected.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -27817,7 +27817,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all repository variables. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the actions_variables:read repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all repository variables.\nYou must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions_variables:read repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -27901,7 +27901,7 @@ } ], "previews": [], - "descriptionHTML": "

      Creates a repository variable that you can reference in a GitHub Actions workflow.\nYou must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the actions_variables:write repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Creates a repository variable that you can reference in a GitHub Actions workflow.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions_variables:write repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -28015,7 +28015,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a specific variable in a repository. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the actions_variables:read repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a specific variable in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions_variables:read repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -28098,7 +28098,7 @@ } ], "previews": [], - "descriptionHTML": "

      Updates a repository variable that you can reference in a GitHub Actions workflow.\nYou must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the actions_variables:write repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Updates a repository variable that you can reference in a GitHub Actions workflow.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions_variables:write repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -28163,7 +28163,7 @@ } ], "previews": [], - "descriptionHTML": "

      Deletes a repository variable using the variable name.\nYou must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the actions_variables:write repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Deletes a repository variable using the variable name.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions_variables:write repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -28311,7 +28311,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all environment variables. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the environments:read repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all environment variables.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the environments:read repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -28395,7 +28395,7 @@ } ], "previews": [], - "descriptionHTML": "

      Create an environment variable that you can reference in a GitHub Actions workflow.\nYou must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the environment:write repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Create an environment variable that you can reference in a GitHub Actions workflow.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the environment:write repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -28509,7 +28509,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a specific variable in an environment. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the environments:read repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a specific variable in an environment.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the environments:read repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -28592,7 +28592,7 @@ } ], "previews": [], - "descriptionHTML": "

      Updates an environment variable that you can reference in a GitHub Actions workflow.\nYou must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the environment:write repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Updates an environment variable that you can reference in a GitHub Actions workflow.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the environment:write repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -28657,7 +28657,7 @@ } ], "previews": [], - "descriptionHTML": "

      Deletes an environment variable using the variable name.\nYou must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the environment:write repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Deletes an environment variable using the variable name.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the environment:write repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -30312,7 +30312,7 @@ } ], "previews": [], - "descriptionHTML": "

      Re-run a job and its dependent jobs in a workflow run. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the actions:write permission to use this endpoint.

      ", + "descriptionHTML": "

      Re-run a job and its dependent jobs in a workflow run.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions:write permission to use this endpoint.

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -38767,7 +38767,7 @@ } ], "previews": [], - "descriptionHTML": "

      Cancels a workflow run using its id. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the actions:write permission to use this endpoint.

      ", + "descriptionHTML": "

      Cancels a workflow run using its id.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions:write permission to use this endpoint.

      ", "statusCodes": [ { "httpStatusCode": "202", @@ -186671,7 +186671,7 @@ }, { "httpStatusCode": "403", - "description": "

      Forbidden

      " + "description": "

      Response if GitHub Advanced Security is not enabled for this repository

      " }, { "httpStatusCode": "404", @@ -471532,7 +471532,7 @@ } ], "previews": [], - "descriptionHTML": "

      Team members will include the members of child teams.

      \n

      To get a user's membership with a team, the team must be visible to the authenticated user.

      \n

      Note: You can also specify a team by org_id and team_id using the route GET /organizations/{org_id}/team/{team_id}/memberships/{username}.

      \n

      Note:\nThe response contains the state of the membership and the member's role.

      \n

      The role for organization owners is set to maintainer. For more information about maintainer roles, see see Create a team.

      ", + "descriptionHTML": "

      Team members will include the members of child teams.

      \n

      To get a user's membership with a team, the team must be visible to the authenticated user.

      \n

      Note: You can also specify a team by org_id and team_id using the route GET /organizations/{org_id}/team/{team_id}/memberships/{username}.

      \n

      Note:\nThe response contains the state of the membership and the member's role.

      \n

      The role for organization owners is set to maintainer. For more information about maintainer roles, see Create a team.

      ", "statusCodes": [ { "httpStatusCode": "200", diff --git a/src/rest/data/ghes-3.9-2022-11-28/schema.json b/src/rest/data/ghes-3.9-2022-11-28/schema.json index 76ded6fef7..c8ea644a15 100644 --- a/src/rest/data/ghes-3.9-2022-11-28/schema.json +++ b/src/rest/data/ghes-3.9-2022-11-28/schema.json @@ -599,7 +599,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a redirect URL to download an archive for a repository. This URL expires after 1 minute. Look for Location: in\nthe response header to find the URL for the download. The :archive_format must be zip. Anyone with read access to\nthe repository can use this endpoint. If the repository is private you must use an access token with the repo scope.\nGitHub Apps must have the actions:read permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a redirect URL to download an archive for a repository. This URL expires after 1 minute. Look for Location: in\nthe response header to find the URL for the download. The :archive_format must be zip.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the actions:read permission to use this endpoint.

      ", "statusCodes": [ { "httpStatusCode": "302", @@ -6155,7 +6155,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all secrets available in an organization without revealing their encrypted values. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all secrets available in an organization without revealing their\nencrypted values.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -6254,7 +6254,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets your public key, which you need to encrypt secrets. You need to encrypt a secret before you can create or update secrets. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets your public key, which you need to encrypt secrets. You need to\nencrypt a secret before you can create or update secrets.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -6361,7 +6361,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a single organization secret without revealing its encrypted value. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a single organization secret without revealing its encrypted value.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -6491,7 +6491,7 @@ } ], "previews": [], - "descriptionHTML": "

      Creates or updates an organization secret with an encrypted value. Encrypt your secret using\nLibSodium. You must authenticate using an access\ntoken with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to\nuse this endpoint.

      \n

      *Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", + "descriptionHTML": "

      Creates or updates an organization secret with an encrypted value. Encrypt your secret using\nLibSodium.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      \n

      *Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -6550,7 +6550,7 @@ } ], "previews": [], - "descriptionHTML": "

      Deletes a secret in an organization using the secret name. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Deletes a secret in an organization using the secret name.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -7503,7 +7503,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all repositories that have been selected when the visibility for repository access to a secret is set to selected. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all repositories that have been selected when the visibility\nfor repository access to a secret is set to selected.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -7572,7 +7572,7 @@ } ], "previews": [], - "descriptionHTML": "

      Replaces all repositories for an organization secret when the visibility for repository access is set to selected. The visibility is set when you Create or update an organization secret. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Replaces all repositories for an organization secret when the visibility\nfor repository access is set to selected. The visibility is set when you Create\nor update an organization secret.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -7637,7 +7637,7 @@ } ], "previews": [], - "descriptionHTML": "

      Adds a repository to an organization secret when the visibility for repository access is set to selected. The visibility is set when you Create or update an organization secret. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Adds a repository to an organization secret when the visibility for\nrepository access is set to selected. The visibility is set when you Create or\nupdate an organization secret.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -7706,7 +7706,7 @@ } ], "previews": [], - "descriptionHTML": "

      Removes a repository from an organization secret when the visibility for repository access is set to selected. The visibility is set when you Create or update an organization secret. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the secrets organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Removes a repository from an organization secret when the visibility\nfor repository access is set to selected. The visibility is set when you Create\nor update an organization secret.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the secrets organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -7841,7 +7841,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all organization secrets shared with a repository without revealing their encrypted values. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all organization secrets shared with a repository without revealing their encrypted\nvalues.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -7972,7 +7972,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all secrets available in a repository without revealing their encrypted values. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all secrets available in a repository without revealing their encrypted\nvalues.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -8081,7 +8081,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets your public key, which you need to encrypt secrets. You need to encrypt a secret before you can create or update secrets. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the repo scope. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets your public key, which you need to encrypt secrets. You need to\nencrypt a secret before you can create or update secrets.

      \n

      Anyone with read access to the repository can use this endpoint.\nIf the repository is private you must use an access token with the repo scope.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -8179,7 +8179,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a single repository secret without revealing its encrypted value. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a single repository secret without revealing its encrypted value.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -8292,7 +8292,7 @@ } ], "previews": [], - "descriptionHTML": "

      Creates or updates a repository secret with an encrypted value. Encrypt your secret using\nLibSodium. You must authenticate using an access\ntoken with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use\nthis endpoint.

      \n

      Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", + "descriptionHTML": "

      Creates or updates a repository secret with an encrypted value. Encrypt your secret using\nLibSodium.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      \n

      Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -8361,7 +8361,7 @@ } ], "previews": [], - "descriptionHTML": "

      Deletes a secret in a repository using the secret name. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Deletes a secret in a repository using the secret name.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -8492,7 +8492,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all secrets available in an environment without revealing their encrypted values. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all secrets available in an environment without revealing their\nencrypted values.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -8601,7 +8601,7 @@ } ], "previews": [], - "descriptionHTML": "

      Get the public key for an environment, which you need to encrypt environment secrets. You need to encrypt a secret before you can create or update secrets. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the repo scope. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Get the public key for an environment, which you need to encrypt environment\nsecrets. You need to encrypt a secret before you can create or update secrets.

      \n

      Anyone with read access to the repository can use this endpoint.\nIf the repository is private you must use an access token with the repo scope.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -8699,7 +8699,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a single environment secret without revealing its encrypted value. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a single environment secret without revealing its encrypted value.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -8814,7 +8814,7 @@ } ], "previews": [], - "descriptionHTML": "

      Creates or updates an environment secret with an encrypted value. Encrypt your secret using\nLibSodium. You must authenticate using an access\ntoken with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use\nthis endpoint.

      \n

      Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", + "descriptionHTML": "

      Creates or updates an environment secret with an encrypted value. Encrypt your secret using\nLibSodium.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      \n

      Example encrypting a secret using Node.js

      \n

      Encrypt your secret using the libsodium-wrappers library.

      \n
      const sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n  // Convert Secret & Base64 key to Uint8Array.\n  let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n  let binsec = sodium.from_string(secret)\n\n  //Encrypt the secret using LibSodium\n  let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n  // Convert encrypted Uint8Array to Base64\n  let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n  console.log(output)\n});\n
      \n

      Example encrypting a secret using Python

      \n

      Encrypt your secret using pynacl with Python 3.

      \n
      from base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n  \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n  public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n  sealed_box = public.SealedBox(public_key)\n  encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n  return b64encode(encrypted).decode(\"utf-8\")\n
      \n

      Example encrypting a secret using C#

      \n

      Encrypt your secret using the Sodium.Core package.

      \n
      var secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n
      \n

      Example encrypting a secret using Ruby

      \n

      Encrypt your secret using the rbnacl gem.

      \n
      require \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -8883,7 +8883,7 @@ } ], "previews": [], - "descriptionHTML": "

      Deletes a secret in an environment using the secret name. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the secrets repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Deletes a secret in an environment using the secret name.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the secrets repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -17552,7 +17552,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all self-hosted runners configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists all self-hosted runners configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -17675,7 +17675,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists binaries for the runner application that you can download and run.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists binaries for the runner application that you can download and run.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -19250,7 +19250,7 @@ } ], "previews": [], - "descriptionHTML": "

      Returns a token that you can pass to the config script. The token expires after one hour.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      \n

      Example using registration token:

      \n

      Configure your self-hosted runner, replacing TOKEN with the registration token provided by this endpoint.

      \n
      ./config.sh --url https://github.com/octo-org --token TOKEN\n
      ", + "descriptionHTML": "

      Returns a token that you can pass to the config script. The token expires after one hour.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      \n

      Example using registration token:

      \n

      Configure your self-hosted runner, replacing TOKEN with the registration token provided by this endpoint.

      \n
      ./config.sh --url https://github.com/octo-org --token TOKEN\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -20825,7 +20825,7 @@ } ], "previews": [], - "descriptionHTML": "

      Returns a token that you can pass to the config script to remove a self-hosted runner from an organization. The token expires after one hour.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      \n

      Example using remove token:

      \n

      To remove your self-hosted runner from an organization, replace TOKEN with the remove token provided by this\nendpoint.

      \n
      ./config.sh remove --token TOKEN\n
      ", + "descriptionHTML": "

      Returns a token that you can pass to the config script to remove a self-hosted runner from an organization. The token expires after one hour.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      \n

      Example using remove token:

      \n

      To remove your self-hosted runner from an organization, replace TOKEN with the remove token provided by this\nendpoint.

      \n
      ./config.sh remove --token TOKEN\n
      ", "statusCodes": [ { "httpStatusCode": "201", @@ -20992,7 +20992,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a specific self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Gets a specific self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -21047,7 +21047,7 @@ } ], "previews": [], - "descriptionHTML": "

      Forces the removal of a self-hosted runner from an organization. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Forces the removal of a self-hosted runner from an organization. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -21169,7 +21169,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all labels for a self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists all labels for a self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -21310,7 +21310,7 @@ } ], "previews": [], - "descriptionHTML": "

      Add custom labels to a self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Add custom labels to a self-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -21455,7 +21455,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove all previous custom labels and set the new custom labels for a specific\nself-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Remove all previous custom labels and set the new custom labels for a specific\nself-hosted runner configured in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -21580,7 +21580,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove all custom labels from a self-hosted runner configured in an\norganization. Returns the remaining read-only labels from the runner.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Remove all custom labels from a self-hosted runner configured in an\norganization. Returns the remaining read-only labels from the runner.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -21716,7 +21716,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove a custom label from a self-hosted runner configured\nin an organization. Returns the remaining labels from the runner.

      \n

      This endpoint returns a 404 Not Found status if the custom label is not\npresent on the runner.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.

      ", + "descriptionHTML": "

      Remove a custom label from a self-hosted runner configured\nin an organization. Returns the remaining labels from the runner.

      \n

      This endpoint returns a 404 Not Found status if the custom label is not\npresent on the runner.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -21953,7 +21953,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all self-hosted runners configured in a repository. You must authenticate using an access token with the repo scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists all self-hosted runners configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -22086,7 +22086,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists binaries for the runner application that you can download and run.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.

      ", + "descriptionHTML": "

      Lists binaries for the runner application that you can download and run.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -23671,7 +23671,7 @@ } ], "previews": [], - "descriptionHTML": "

      Returns a token that you can pass to the config script. The token expires after one hour. You must authenticate using an access token with the repo scope to use this endpoint.

      \n

      Example using registration token:

      \n

      Configure your self-hosted runner, replacing TOKEN with the registration token provided by this endpoint.

      \n
      ./config.sh --url https://github.com/octo-org/octo-repo-artifacts --token TOKEN\n
      ", + "descriptionHTML": "

      Returns a token that you can pass to the config script. The token\nexpires after one hour.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      \n

      Example using registration token:

      \n

      Configure your self-hosted runner, replacing TOKEN with the registration token provided\nby this endpoint.

      \n

      config.sh --url https://github.com/octo-org/octo-repo-artifacts --token TOKEN

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -25256,7 +25256,7 @@ } ], "previews": [], - "descriptionHTML": "

      Returns a token that you can pass to remove a self-hosted runner from a repository. The token expires after one hour.\nYou must authenticate using an access token with the repo scope to use this endpoint.

      \n

      Example using remove token:

      \n

      To remove your self-hosted runner from a repository, replace TOKEN with the remove token provided by this endpoint.

      \n
      ./config.sh remove --token TOKEN\n
      ", + "descriptionHTML": "

      Returns a token that you can pass to remove a self-hosted runner from\na repository. The token expires after one hour.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      \n

      Example using remove token:

      \n

      To remove your self-hosted runner from a repository, replace TOKEN with\nthe remove token provided by this endpoint.

      \n

      config.sh remove --token TOKEN

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -25433,7 +25433,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a specific self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Gets a specific self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -25498,7 +25498,7 @@ } ], "previews": [], - "descriptionHTML": "

      Forces the removal of a self-hosted runner from a repository. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.

      \n

      You must authenticate using an access token with the repo\nscope to use this endpoint.

      ", + "descriptionHTML": "

      Forces the removal of a self-hosted runner from a repository. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -25630,7 +25630,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all labels for a self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Lists all labels for a self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -25781,7 +25781,7 @@ } ], "previews": [], - "descriptionHTML": "

      Add custom labels to a self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Add custom labels to a self-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -25936,7 +25936,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove all previous custom labels and set the new custom labels for a specific\nself-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Remove all previous custom labels and set the new custom labels for a specific\nself-hosted runner configured in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -26071,7 +26071,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove all custom labels from a self-hosted runner configured in a\nrepository. Returns the remaining read-only labels from the runner.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Remove all custom labels from a self-hosted runner configured in a\nrepository. Returns the remaining read-only labels from the runner.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -26217,7 +26217,7 @@ } ], "previews": [], - "descriptionHTML": "

      Remove a custom label from a self-hosted runner configured\nin a repository. Returns the remaining labels from the runner.

      \n

      This endpoint returns a 404 Not Found status if the custom label is not\npresent on the runner.

      \n

      You must authenticate using an access token with the repo scope to use this\nendpoint.

      ", + "descriptionHTML": "

      Remove a custom label from a self-hosted runner configured\nin a repository. Returns the remaining labels from the runner.

      \n

      This endpoint returns a 404 Not Found status if the custom label is not\npresent on the runner.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the administration permission for repositories and the organization_self_hosted_runners permission for organizations.\nAuthenticated users must have admin access to repositories or organizations, or the manage_runners:enterprise scope for enterprises, to use these endpoints.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -26393,7 +26393,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all organization variables. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the organization_actions_variables:read organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all organization variables.\nYou must authenticate using an access token with the admin:org scope to use this endpoint. If the repository is private, you must use an access token with the repo scope. GitHub Apps must have the organization_actions_variables:read organization permission to use this endpoint. Authenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -26490,7 +26490,7 @@ } ], "previews": [], - "descriptionHTML": "

      Creates an organization variable that you can reference in a GitHub Actions workflow.\nYou must authenticate using an access token with the admin:org scope to use this endpoint.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Creates an organization variable that you can reference in a GitHub Actions workflow.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -26614,7 +26614,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a specific variable in an organization. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the organization_actions_variables:read organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a specific variable in an organization.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the organization_actions_variables:read organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -26709,7 +26709,7 @@ } ], "previews": [], - "descriptionHTML": "

      Updates an organization variable that you can reference in a GitHub Actions workflow.\nYou must authenticate using an access token with the admin:org scope to use this endpoint.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Updates an organization variable that you can reference in a GitHub Actions workflow.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -26764,7 +26764,7 @@ } ], "previews": [], - "descriptionHTML": "

      Deletes an organization variable using the variable name.\nYou must authenticate using an access token with the admin:org scope to use this endpoint.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Deletes an organization variable using the variable name.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -27717,7 +27717,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all repositories that can access an organization variable that is available to selected repositories. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the organization_actions_variables:read organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all repositories that can access an organization variable\nthat is available to selected repositories.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the organization_actions_variables:read organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -27790,7 +27790,7 @@ } ], "previews": [], - "descriptionHTML": "

      Replaces all repositories for an organization variable that is available to selected repositories. Organization variables that are available to selected repositories have their visibility field set to selected. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Replaces all repositories for an organization variable that is available\nto selected repositories. Organization variables that are available to selected\nrepositories have their visibility field set to selected.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this\nendpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -27859,7 +27859,7 @@ } ], "previews": [], - "descriptionHTML": "

      Adds a repository to an organization variable that is available to selected repositories. Organization variables that are available to selected repositories have their visibility field set to selected. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Adds a repository to an organization variable that is available to selected repositories.\nOrganization variables that are available to selected repositories have their visibility field set to selected.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -27928,7 +27928,7 @@ } ], "previews": [], - "descriptionHTML": "

      Removes a repository from an organization variable that is available to selected repositories. Organization variables that are available to selected repositories have their visibility field set to selected. You must authenticate using an access token with the admin:org scope to use this endpoint. GitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.

      ", + "descriptionHTML": "

      Removes a repository from an organization variable that is\navailable to selected repositories. Organization variables that are available to\nselected repositories have their visibility field set to selected.

      \n

      You must authenticate using an access token with the admin:org scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the organization_actions_variables:write organization permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -28080,7 +28080,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all organiation variables shared with a repository. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the actions_variables:read repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all organiation variables shared with a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions_variables:read repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -28228,7 +28228,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all repository variables. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the actions_variables:read repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all repository variables.\nYou must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions_variables:read repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -28312,7 +28312,7 @@ } ], "previews": [], - "descriptionHTML": "

      Creates a repository variable that you can reference in a GitHub Actions workflow.\nYou must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the actions_variables:write repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Creates a repository variable that you can reference in a GitHub Actions workflow.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions_variables:write repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -28426,7 +28426,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a specific variable in a repository. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the actions_variables:read repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a specific variable in a repository.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions_variables:read repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -28509,7 +28509,7 @@ } ], "previews": [], - "descriptionHTML": "

      Updates a repository variable that you can reference in a GitHub Actions workflow.\nYou must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the actions_variables:write repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Updates a repository variable that you can reference in a GitHub Actions workflow.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions_variables:write repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -28574,7 +28574,7 @@ } ], "previews": [], - "descriptionHTML": "

      Deletes a repository variable using the variable name.\nYou must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the actions_variables:write repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Deletes a repository variable using the variable name.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions_variables:write repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -28722,7 +28722,7 @@ } ], "previews": [], - "descriptionHTML": "

      Lists all environment variables. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the environments:read repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Lists all environment variables.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the environments:read repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -28806,7 +28806,7 @@ } ], "previews": [], - "descriptionHTML": "

      Create an environment variable that you can reference in a GitHub Actions workflow.\nYou must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the environment:write repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Create an environment variable that you can reference in a GitHub Actions workflow.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the environment:write repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -28920,7 +28920,7 @@ } ], "previews": [], - "descriptionHTML": "

      Gets a specific variable in an environment. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the environments:read repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Gets a specific variable in an environment.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the environments:read repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "200", @@ -29003,7 +29003,7 @@ } ], "previews": [], - "descriptionHTML": "

      Updates an environment variable that you can reference in a GitHub Actions workflow.\nYou must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the environment:write repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Updates an environment variable that you can reference in a GitHub Actions workflow.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the environment:write repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -29068,7 +29068,7 @@ } ], "previews": [], - "descriptionHTML": "

      Deletes an environment variable using the variable name.\nYou must authenticate using an access token with the repo scope to use this endpoint.\nGitHub Apps must have the environment:write repository permission to use this endpoint.

      ", + "descriptionHTML": "

      Deletes an environment variable using the variable name.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the environment:write repository permission to use this endpoint.\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.

      ", "statusCodes": [ { "httpStatusCode": "204", @@ -30750,7 +30750,7 @@ } ], "previews": [], - "descriptionHTML": "

      Re-run a job and its dependent jobs in a workflow run. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the actions:write permission to use this endpoint.

      ", + "descriptionHTML": "

      Re-run a job and its dependent jobs in a workflow run.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions:write permission to use this endpoint.

      ", "statusCodes": [ { "httpStatusCode": "201", @@ -39469,7 +39469,7 @@ } ], "previews": [], - "descriptionHTML": "

      Cancels a workflow run using its id. You must authenticate using an access token with the repo scope to use this endpoint. GitHub Apps must have the actions:write permission to use this endpoint.

      ", + "descriptionHTML": "

      Cancels a workflow run using its id.

      \n

      You must authenticate using an access token with the repo scope to use this endpoint.\nIf the repository is private, you must use an access token with the repo scope.\nGitHub Apps must have the actions:write permission to use this endpoint.

      ", "statusCodes": [ { "httpStatusCode": "202", @@ -188558,7 +188558,7 @@ }, { "httpStatusCode": "403", - "description": "

      Forbidden

      " + "description": "

      Response if GitHub Advanced Security is not enabled for this repository

      " }, { "httpStatusCode": "404", @@ -490029,7 +490029,7 @@ } ], "previews": [], - "descriptionHTML": "

      Team members will include the members of child teams.

      \n

      To get a user's membership with a team, the team must be visible to the authenticated user.

      \n

      Note: You can also specify a team by org_id and team_id using the route GET /organizations/{org_id}/team/{team_id}/memberships/{username}.

      \n

      Note:\nThe response contains the state of the membership and the member's role.

      \n

      The role for organization owners is set to maintainer. For more information about maintainer roles, see see Create a team.

      ", + "descriptionHTML": "

      Team members will include the members of child teams.

      \n

      To get a user's membership with a team, the team must be visible to the authenticated user.

      \n

      Note: You can also specify a team by org_id and team_id using the route GET /organizations/{org_id}/team/{team_id}/memberships/{username}.

      \n

      Note:\nThe response contains the state of the membership and the member's role.

      \n

      The role for organization owners is set to maintainer. For more information about maintainer roles, see Create a team.

      ", "statusCodes": [ { "httpStatusCode": "200", diff --git a/src/rest/lib/config.json b/src/rest/lib/config.json index f4d72d4fbf..d7b47d540b 100644 --- a/src/rest/lib/config.json +++ b/src/rest/lib/config.json @@ -33,5 +33,5 @@ ] } }, - "sha": "a57e233e49ce02b9c7445b38c8d8c920c95dddfd" + "sha": "8482a8d60da584a11eb150f7849ad78b2f58aadd" } \ No newline at end of file diff --git a/src/webhooks/lib/config.json b/src/webhooks/lib/config.json index 90b10ab9e3..5fa257e694 100644 --- a/src/webhooks/lib/config.json +++ b/src/webhooks/lib/config.json @@ -1,3 +1,3 @@ { - "sha": "a57e233e49ce02b9c7445b38c8d8c920c95dddfd" + "sha": "8482a8d60da584a11eb150f7849ad78b2f58aadd" } \ No newline at end of file From 9a54faa00a7167e87c4035a4359c3d92479c2ce7 Mon Sep 17 00:00:00 2001 From: Ben Ahmady <32935794+subatoi@users.noreply.github.com> Date: Wed, 26 Jul 2023 17:46:46 +0100 Subject: [PATCH 09/14] Removes tag from placeholder token example (#39710) Co-authored-by: Peter Bengtsson --- content/rest/guides/getting-started-with-the-rest-api.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/content/rest/guides/getting-started-with-the-rest-api.md b/content/rest/guides/getting-started-with-the-rest-api.md index b890795b17..e16d525504 100644 --- a/content/rest/guides/getting-started-with-the-rest-api.md +++ b/content/rest/guides/getting-started-with-the-rest-api.md @@ -328,7 +328,7 @@ To send a header in a `curl` command, use the `--header` or `-H` flag followed b curl --request GET \ --url "https://api.github.com/octocat" \ --header "Accept: application/vnd.github+json" \ ---header "Authorization: Bearer YOUR-TOKEN"{% ifversion api-date-versioning %} \ +--header "Authorization: Bearer YOUR-TOKEN"{% ifversion api-date-versioning %} \ --header "X-GitHub-Api-Version: {{ allVersions[currentVersion].latestApiVersion }}"{% endif %} ``` From 899943e1950644e840fe523044efb331693acbf7 Mon Sep 17 00:00:00 2001 From: Peter Bengtsson Date: Wed, 26 Jul 2023 13:05:17 -0400 Subject: [PATCH 10/14] Don't let Dependabot upgrade styled-components (#39739) --- .github/dependabot.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/dependabot.yml b/.github/dependabot.yml index 5359049164..9a9d97ddba 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -7,7 +7,10 @@ updates: day: tuesday open-pull-requests-limit: 20 # default is 5 ignore: + # Because this is so dependent on the remote server we use - dependency-name: '@elastic/elasticsearch' + # Because whatever we have needs to match what @primer/react also uses + - dependency-name: 'styled-components' - dependency-name: '*' update-types: ['version-update:semver-patch', 'version-update:semver-minor'] From 5b2c7149509ae9bfbc60541f90f7938e97219535 Mon Sep 17 00:00:00 2001 From: Grace Park Date: Wed, 26 Jul 2023 12:27:36 -0700 Subject: [PATCH 11/14] Remove sidebarhomepage and add external links to More docs (#39738) --- components/DefaultLayout.tsx | 2 +- components/sidebar/SidebarNav.tsx | 7 +- .../components/ProductSelectionCard.tsx | 6 ++ src/landings/components/ProductSelections.tsx | 2 +- .../components/SidebarHomepage.module.scss | 10 --- src/landings/components/SidebarHomepage.tsx | 45 ----------- src/landings/pages/home.tsx | 32 ++++++++ tests/rendering-fixtures/homepage.js | 13 +++- .../playwright-rendering.spec.ts | 6 +- tests/rendering-fixtures/sidebar.js | 41 +--------- tests/rendering-fixtures/translations.js | 3 +- tests/rendering/server.js | 74 ------------------- 12 files changed, 54 insertions(+), 187 deletions(-) delete mode 100644 src/landings/components/SidebarHomepage.module.scss delete mode 100644 src/landings/components/SidebarHomepage.tsx diff --git a/components/DefaultLayout.tsx b/components/DefaultLayout.tsx index afd46ed9cb..8668469c99 100644 --- a/components/DefaultLayout.tsx +++ b/components/DefaultLayout.tsx @@ -113,7 +113,7 @@ export const DefaultLayout = (props: Props) => {
      - + {isHomepageVersion ? null : } {/* Need to set an explicit height for sticky elements since we also set overflow to auto */}
      diff --git a/components/sidebar/SidebarNav.tsx b/components/sidebar/SidebarNav.tsx index 325926a0e4..040ff17503 100644 --- a/components/sidebar/SidebarNav.tsx +++ b/components/sidebar/SidebarNav.tsx @@ -2,7 +2,6 @@ import cx from 'classnames' import { useMainContext } from 'components/context/MainContext' import { SidebarProduct } from 'src/landings/components/SidebarProduct' -import { SidebarHomepage } from 'src/landings/components/SidebarHomepage' import { AllProductsLink } from './AllProductsLink' import { ApiVersionPicker } from 'src/rest/components/ApiVersionPicker' import { Link } from 'components/Link' @@ -54,11 +53,7 @@ export const SidebarNav = ({ variant = 'full' }: Props) => { style={{ width: 326, height: 'calc(100vh - 175px)', paddingBottom: sidebarPaddingBottom }} role="banner" > - {!currentProduct || currentProduct.id === 'search' ? ( - - ) : ( - - )} +
      ) diff --git a/src/landings/components/ProductSelectionCard.tsx b/src/landings/components/ProductSelectionCard.tsx index 7250e73e24..99ba503fe5 100644 --- a/src/landings/components/ProductSelectionCard.tsx +++ b/src/landings/components/ProductSelectionCard.tsx @@ -6,6 +6,7 @@ import { useRouter } from 'next/router' import { useVersion } from 'components/hooks/useVersion' import { Link } from 'components/Link' import * as Octicons from '@primer/octicons-react' +import { LinkExternalIcon } from '@primer/octicons-react' type ProductSelectionCardProps = { name: string @@ -75,6 +76,11 @@ export const ProductSelectionCard = ({ name, group }: ProductSelectionCardProps)
    • {product.name} + {product.external && ( + + + + )}
    • ) diff --git a/src/landings/components/ProductSelections.tsx b/src/landings/components/ProductSelections.tsx index 852fedaf00..47f24d61d0 100644 --- a/src/landings/components/ProductSelections.tsx +++ b/src/landings/components/ProductSelections.tsx @@ -5,7 +5,7 @@ import { ProductSelectionCard } from './ProductSelectionCard' export type ProductGroupT = { name: string - icon: string + icon?: string octicon: string children: Array } diff --git a/src/landings/components/SidebarHomepage.module.scss b/src/landings/components/SidebarHomepage.module.scss deleted file mode 100644 index 9ca4626cb1..0000000000 --- a/src/landings/components/SidebarHomepage.module.scss +++ /dev/null @@ -1,10 +0,0 @@ -.keyboardFocus { - &:focus-within { - outline: 5px auto -webkit-focus-ring-color; - } - - &:hover { - outline: none; - background-color: rgba(208, 215, 222, 0.32); - } -} diff --git a/src/landings/components/SidebarHomepage.tsx b/src/landings/components/SidebarHomepage.tsx deleted file mode 100644 index 77128332fa..0000000000 --- a/src/landings/components/SidebarHomepage.tsx +++ /dev/null @@ -1,45 +0,0 @@ -import { LinkExternalIcon } from '@primer/octicons-react' -import cx from 'classnames' - -import { Link } from 'components/Link' -import { useMainContext } from 'components/context/MainContext' - -import styles from './SidebarHomepage.module.scss' - -export const SidebarHomepage = () => { - const { homepageLinks } = useMainContext() - if (!homepageLinks) throw new Error("'homepageLinks' not set in main context") - - return ( -
      -
        - {homepageLinks.map((link) => { - const { href, external, name } = link - return ( -
      • - - - {name} - {external && ( - - - - )} - - -
      • - ) - })} -
      -
      - ) -} diff --git a/src/landings/pages/home.tsx b/src/landings/pages/home.tsx index 3706d8ce59..8898152666 100644 --- a/src/landings/pages/home.tsx +++ b/src/landings/pages/home.tsx @@ -51,6 +51,38 @@ function HomePage(props: HomePageProps) { const { gettingStartedLinks, popularLinks, productGroups } = props const { t } = useTranslation(['toc']) + // Adding external links here due to accessibility design changes where we removed the sidebar on the homepage + // docs-team 2965 + if (!productGroups.find((group) => group.name === 'More docs')) { + productGroups.push({ + name: 'More docs', + octicon: 'PencilIcon', + children: [ + { + id: 'electron', + name: 'Electron', + href: 'https://www.electronjs.org/docs/latest', + versions: [], + external: true, + }, + { + id: 'codeql', + name: 'CodeQL', + href: 'https://codeql.github.com/docs/', + versions: [], + external: true, + }, + { + id: 'npm', + name: 'npm', + href: 'https://docs.npmjs.com/', + versions: [], + external: true, + }, + ], + }) + } + return (
      diff --git a/tests/rendering-fixtures/homepage.js b/tests/rendering-fixtures/homepage.js index 49446f7378..f9a4c6e127 100644 --- a/tests/rendering-fixtures/homepage.js +++ b/tests/rendering-fixtures/homepage.js @@ -16,11 +16,16 @@ describe('home page', () => { const main = $('[data-testid="product"]') const links = main.find('a[href*="/"]') const hrefs = links.map((i, link) => $(link)).get() + let externalLinks = 0 for (const href of hrefs) { - const res = await get(href.attr('href')) - expect(res.statusCode).toBe(200) // Not needing to redirect - expect(href.text().includes('{%')).toBe(false) + if (!href.attr('href').startsWith('https://')) { + const res = await get(href.attr('href')) + expect(res.statusCode).toBe(200) // Not needing to redirect + expect(href.text().includes('{%')).toBe(false) + } else { + externalLinks++ + } } - expect.assertions(hrefs.length * 2) + expect.assertions((hrefs.length - externalLinks) * 2) }) }) diff --git a/tests/rendering-fixtures/playwright-rendering.spec.ts b/tests/rendering-fixtures/playwright-rendering.spec.ts index 837c6610f6..77caff7b46 100644 --- a/tests/rendering-fixtures/playwright-rendering.spec.ts +++ b/tests/rendering-fixtures/playwright-rendering.spec.ts @@ -30,9 +30,8 @@ test('view the for-playwright article', async ({ page }) => { }) test('use sidebar to go to Hello World page', async ({ page }) => { - await page.goto('/') + await page.goto('/get-started') - await page.getByTestId('sidebar').getByText('Get started').click() await expect(page).toHaveTitle(/Getting started with HubGit/) await page.getByTestId('product-sidebar').getByText('Quickstart').click() @@ -190,8 +189,7 @@ test('navigate with side bar into article inside a map-topic inside a category', // Our TreeView sidebar only shows "2 levels". If you click and expand // the category, you'll be able to see the map-topic and the article // within. - await page.goto('/') - await page.getByTestId('sidebar').getByText('GitHub Actions').click() + await page.goto('/actions') await page.getByTestId('sidebar').getByRole('treeitem', { name: 'Category' }).click() await page.getByText('Map & Topic').click() await page.getByLabel('
      link').click() diff --git a/tests/rendering-fixtures/sidebar.js b/tests/rendering-fixtures/sidebar.js index dc48811254..1bd272a6d6 100644 --- a/tests/rendering-fixtures/sidebar.js +++ b/tests/rendering-fixtures/sidebar.js @@ -1,48 +1,9 @@ import { jest } from '@jest/globals' -import { getDOMCached as getDOM, get } from '../helpers/e2etest.js' +import { getDOMCached as getDOM } from '../helpers/e2etest.js' describe('sidebar', () => { jest.setTimeout(10 * 60 * 1000) - - describe('home page', () => { - test('includes external links', async () => { - const $ = await getDOM('/') - // Because we know exactly what's in the `externalProducts` - // frontmatter property of tests/fixtures/content/index.md - // We can predict what to expect to be present. - const links = $('[data-testid=sidebar] ul a[href="https://github.com"]') - expect(links.text()).toBe('GitHub itself') - }) - - test('early access is never a link', async () => { - const $ = await getDOM('/') - const links = $('[data-testid=sidebar] a[href]') - // The `content/index.md` has to list `early-access` in `children:` - // or else those pages won't become part of the site tree. But - // they should not actually appear in the side bar. - const earlyAccessLinks = links.filter((i, link) => - $(link).attr('href').split('/').includes('early-access'), - ) - expect(earlyAccessLinks.length).toBe(0) - }) - - test('all links have Liquid evaluated', async () => { - const $ = await getDOM('/') - const links = $('[data-testid=sidebar] a[href]') - const hrefs = links - .filter((i, link) => $(link).attr('href').startsWith('/')) - .map((i, link) => $(link)) - .get() - for (const href of hrefs) { - const res = await get(href.attr('href')) - expect(res.statusCode).toBe(200) // Not needing to redirect - expect(href.text().includes('{%')).toBe(false) - } - expect.assertions(hrefs.length * 2) - }) - }) - describe('nav', () => { test('top level product mentioned at top of sidebar', async () => { const $ = await getDOM('/get-started') diff --git a/tests/rendering-fixtures/translations.js b/tests/rendering-fixtures/translations.js index 6cb681bcaa..8b6e89ddec 100644 --- a/tests/rendering-fixtures/translations.js +++ b/tests/rendering-fixtures/translations.js @@ -16,8 +16,7 @@ describe('translations', () => { // You gotta know your tests/fixtures/translations/ja-jp/data/ui.yml expect(h1).toBe('日本 GitHub Docs') - // Sidebar uses the translated shortTitle - const links = $('[data-testid=sidebar] a[href]') + const links = $('[data-testid=product] a[href]') const hrefs = links .filter((i, link) => $(link).attr('href').startsWith('/')) .map((i, link) => $(link)) diff --git a/tests/rendering/server.js b/tests/rendering/server.js index d7c07ed05c..5732324e83 100644 --- a/tests/rendering/server.js +++ b/tests/rendering/server.js @@ -1,21 +1,15 @@ -import lodash from 'lodash-es' import enterpriseServerReleases from '../../lib/enterprise-server-releases.js' import { get, getDOM, head, post } from '../helpers/e2etest.js' import { describeViaActionsOnly } from '../helpers/conditional-runs.js' import { loadPages } from '../../lib/page-data.js' import CspParse from 'csp-parse' -import { productMap } from '../../lib/all-products.js' import { SURROGATE_ENUMS, makeLanguageSurrogateKey, } from '../../middleware/set-fastly-surrogate-key.js' -import { getPathWithoutVersion } from '../../lib/path-utils.js' import { describe, jest } from '@jest/globals' const AZURE_STORAGE_URL = 'githubdocs.azureedge.net' -const activeProducts = Object.values(productMap).filter( - (product) => !product.wip && !product.hidden, -) jest.useFakeTimers({ legacyFakeTimers: true }) @@ -47,74 +41,6 @@ describe('server', () => { expect(res.statusCode).toBe(200) }) - test('renders the homepage with links to expected products in both the sidebar and page body', async () => { - const $ = await getDOM('/en') - const sidebarItems = $('[data-testid=sidebar] ul a').get() - const sidebarTitles = sidebarItems.map((el) => $(el).text().trim()) - const sidebarHrefs = sidebarItems.map((el) => $(el).attr('href')) - - const productTitles = activeProducts.map((prod) => prod.name) - const productHrefs = activeProducts.map((prod) => - prod.external ? prod.href : `/en${prod.href}`, - ) - - const titlesInSidebarButNotProducts = lodash.difference(sidebarTitles, productTitles) - const titlesInProductsButNotSidebar = lodash.difference(productTitles, sidebarTitles) - - const hrefsInSidebarButNotProducts = lodash.difference(sidebarHrefs, productHrefs) - const hrefsInProductsButNotSidebar = lodash.difference(productHrefs, sidebarHrefs) - - expect( - titlesInSidebarButNotProducts.length, - `Found unexpected titles in sidebar: ${titlesInSidebarButNotProducts.join(', ')}`, - ).toBe(0) - expect( - titlesInProductsButNotSidebar.length, - `Found titles missing from sidebar: ${titlesInProductsButNotSidebar.join(', ')}`, - ).toBe(0) - expect( - hrefsInSidebarButNotProducts.length, - `Found unexpected hrefs in sidebar: ${hrefsInSidebarButNotProducts.join(', ')}`, - ).toBe(0) - expect( - hrefsInProductsButNotSidebar.length, - `Found hrefs missing from sidebar: ${hrefsInProductsButNotSidebar.join(', ')}`, - ).toBe(0) - }) - - test('renders the Enterprise homepages with links to expected products in both the sidebar and page body', async () => { - const enterpriseProducts = [ - `enterprise-server@${enterpriseServerReleases.latest}`, - 'enterprise-cloud@latest', - ] - - for (const ep of enterpriseProducts) { - const $ = await getDOM(`/en/${ep}`) - const sidebarItems = $('[data-testid=sidebar] ul a').get() - const sidebarTitles = sidebarItems.map((el) => $(el).text().trim()) - const sidebarHrefs = sidebarItems.map((el) => $(el).attr('href')) - const productItems = activeProducts.filter( - (prod) => prod.external || prod.versions.includes(ep), - ) - const productTitles = productItems.map((prod) => prod.name) - const productHrefs = productItems.map((prod) => - prod.external ? prod.href : `/en/${ep}${getPathWithoutVersion(prod.href)}`, - ) - - const titlesInProductsButNotSidebar = lodash.difference(productTitles, sidebarTitles) - const hrefsInProductsButNotSidebar = lodash.difference(productHrefs, sidebarHrefs) - - expect( - titlesInProductsButNotSidebar.length, - `Found titles missing from sidebar: ${titlesInProductsButNotSidebar.join(', ')}`, - ).toBe(0) - expect( - hrefsInProductsButNotSidebar.length, - `Found hrefs missing from sidebar: ${hrefsInProductsButNotSidebar.join(', ')}`, - ).toBe(0) - } - }) - test('sets Content Security Policy (CSP) headers', async () => { const res = await get('/en') expect(res.statusCode).toBe(200) From 913703d877a2ea2b6f6c17d232c14f182a84c482 Mon Sep 17 00:00:00 2001 From: Robert Sese <734194+rsese@users.noreply.github.com> Date: Wed, 26 Jul 2023 15:01:03 -0500 Subject: [PATCH 12/14] a11y: increase breakpoint width where we hide/show sidebar (#39465) Co-authored-by: Kevin Heis --- components/article/ArticleInlineLayout.tsx | 2 +- components/article/ArticlePage.tsx | 2 +- components/page-header/Header.tsx | 2 +- components/sidebar/SidebarNav.tsx | 6 +++--- playwright.config.ts | 18 ++++++++++++++++-- stylesheets/utilities.scss | 18 ++++++++++++++++++ .../playwright-rendering.spec.ts | 8 ++++---- 7 files changed, 44 insertions(+), 12 deletions(-) diff --git a/components/article/ArticleInlineLayout.tsx b/components/article/ArticleInlineLayout.tsx index 27f8062bfe..52bb5f62e3 100644 --- a/components/article/ArticleInlineLayout.tsx +++ b/components/article/ArticleInlineLayout.tsx @@ -26,7 +26,7 @@ export const ArticleInlineLayout = ({ return ( {breadcrumbs && ( - + {breadcrumbs} )} diff --git a/components/article/ArticlePage.tsx b/components/article/ArticlePage.tsx index 1088bd632a..dfee5bddd0 100644 --- a/components/article/ArticlePage.tsx +++ b/components/article/ArticlePage.tsx @@ -116,7 +116,7 @@ export const ArticlePage = () => { ) : (
      -
      +
      diff --git a/components/page-header/Header.tsx b/components/page-header/Header.tsx index 4febce4f23..d67d0e1c6c 100644 --- a/components/page-header/Header.tsx +++ b/components/page-header/Header.tsx @@ -315,7 +315,7 @@ export const Header = () => {
      {!isHomepageVersion && !isSearchResultsPage && ( -
      +
      { return (
      {variant === 'full' && currentProduct && (