diff --git a/package-lock.json b/package-lock.json index c742e53c6..ae8adf16e 100644 --- a/package-lock.json +++ b/package-lock.json @@ -9,7 +9,7 @@ "version": "0.0.0-development", "license": "MIT", "dependencies": { - "@octokit/openapi-types": "^20.0.0" + "@octokit/openapi-types": "^21.0.0" }, "devDependencies": { "@octokit/tsconfig": "^2.0.0", @@ -250,9 +250,9 @@ } }, "node_modules/@octokit/openapi-types": { - "version": "20.0.0", - "resolved": "https://registry.npmjs.org/@octokit/openapi-types/-/openapi-types-20.0.0.tgz", - "integrity": "sha512-EtqRBEjp1dL/15V7WiX5LJMIxxkdiGJnabzYx5Apx4FkQIFgAfKumXeYAqqJCj1s+BMX4cPFIFC4OLCR6stlnA==" + "version": "21.0.0", + "resolved": "https://registry.npmjs.org/@octokit/openapi-types/-/openapi-types-21.0.0.tgz", + "integrity": "sha512-B6/NBvsNQT5UWYWSFcUT55XTMZBHyflNke7Ryvhs3dLe3I2TTPwpGPMib70YS1Ha5Iccc5CtXTLU7lHstC5e3Q==" }, "node_modules/@octokit/plugin-paginate-rest": { "version": "9.1.4", diff --git a/package.json b/package.json index 848f5646f..cdd914f6a 100644 --- a/package.json +++ b/package.json @@ -6,7 +6,7 @@ }, "description": "Shared TypeScript definitions for Octokit projects", "dependencies": { - "@octokit/openapi-types": "^20.0.0" + "@octokit/openapi-types": "^21.0.0" }, "scripts": { "build": "node scripts/build.mjs && tsc -p tsconfig.json", @@ -80,6 +80,6 @@ ] }, "octokit": { - "openapi-version": "14.0.0" + "openapi-version": "14.1.0" } } diff --git a/scripts/update-endpoints/generated/endpoints.json b/scripts/update-endpoints/generated/endpoints.json index 80b5cb21e..5a509f014 100644 --- a/scripts/update-endpoints/generated/endpoints.json +++ b/scripts/update-endpoints/generated/endpoints.json @@ -83,15 +83,11 @@ }, { "method": "POST", - "url": "/repositories/{repository_id}/environments/{environment_name}/variables", + "url": "/repos/{owner}/{repo}/environments/{environment_name}/variables", "documentationUrl": "https://docs.github.com/rest/actions/variables#create-an-environment-variable", "parameters": [ - { - "alias": null, - "deprecated": null, - "in": "PATH", - "name": "repository_id" - }, + { "alias": null, "deprecated": null, "in": "PATH", "name": "owner" }, + { "alias": null, "deprecated": null, "in": "PATH", "name": "repo" }, { "alias": null, "deprecated": null, @@ -105,15 +101,11 @@ }, { "method": "PUT", - "url": "/repositories/{repository_id}/environments/{environment_name}/secrets/{secret_name}", + "url": "/repos/{owner}/{repo}/environments/{environment_name}/secrets/{secret_name}", "documentationUrl": "https://docs.github.com/rest/actions/secrets#create-or-update-an-environment-secret", "parameters": [ - { - "alias": null, - "deprecated": null, - "in": "PATH", - "name": "repository_id" - }, + { "alias": null, "deprecated": null, "in": "PATH", "name": "owner" }, + { "alias": null, "deprecated": null, "in": "PATH", "name": "repo" }, { "alias": null, "deprecated": null, @@ -311,15 +303,11 @@ }, { "method": "DELETE", - "url": "/repositories/{repository_id}/environments/{environment_name}/secrets/{secret_name}", + "url": "/repos/{owner}/{repo}/environments/{environment_name}/secrets/{secret_name}", "documentationUrl": "https://docs.github.com/rest/actions/secrets#delete-an-environment-secret", "parameters": [ - { - "alias": null, - "deprecated": null, - "in": "PATH", - "name": "repository_id" - }, + { "alias": null, "deprecated": null, "in": "PATH", "name": "owner" }, + { "alias": null, "deprecated": null, "in": "PATH", "name": "repo" }, { "alias": null, "deprecated": null, @@ -332,15 +320,11 @@ }, { "method": "DELETE", - "url": "/repositories/{repository_id}/environments/{environment_name}/variables/{name}", + "url": "/repos/{owner}/{repo}/environments/{environment_name}/variables/{name}", "documentationUrl": "https://docs.github.com/rest/actions/variables#delete-an-environment-variable", "parameters": [ - { - "alias": null, - "deprecated": null, - "in": "PATH", - "name": "repository_id" - }, + { "alias": null, "deprecated": null, "in": "PATH", "name": "owner" }, + { "alias": null, "deprecated": null, "in": "PATH", "name": "repo" }, { "alias": null, "deprecated": null, "in": "PATH", "name": "name" }, { "alias": null, @@ -685,15 +669,11 @@ }, { "method": "GET", - "url": "/repositories/{repository_id}/environments/{environment_name}/secrets/public-key", + "url": "/repos/{owner}/{repo}/environments/{environment_name}/secrets/public-key", "documentationUrl": "https://docs.github.com/rest/actions/secrets#get-an-environment-public-key", "parameters": [ - { - "alias": null, - "deprecated": null, - "in": "PATH", - "name": "repository_id" - }, + { "alias": null, "deprecated": null, "in": "PATH", "name": "owner" }, + { "alias": null, "deprecated": null, "in": "PATH", "name": "repo" }, { "alias": null, "deprecated": null, @@ -705,15 +685,11 @@ }, { "method": "GET", - "url": "/repositories/{repository_id}/environments/{environment_name}/secrets/{secret_name}", + "url": "/repos/{owner}/{repo}/environments/{environment_name}/secrets/{secret_name}", "documentationUrl": "https://docs.github.com/rest/actions/secrets#get-an-environment-secret", "parameters": [ - { - "alias": null, - "deprecated": null, - "in": "PATH", - "name": "repository_id" - }, + { "alias": null, "deprecated": null, "in": "PATH", "name": "owner" }, + { "alias": null, "deprecated": null, "in": "PATH", "name": "repo" }, { "alias": null, "deprecated": null, @@ -726,15 +702,11 @@ }, { "method": "GET", - "url": "/repositories/{repository_id}/environments/{environment_name}/variables/{name}", + "url": "/repos/{owner}/{repo}/environments/{environment_name}/variables/{name}", "documentationUrl": "https://docs.github.com/rest/actions/variables#get-an-environment-variable", "parameters": [ - { - "alias": null, - "deprecated": null, - "in": "PATH", - "name": "repository_id" - }, + { "alias": null, "deprecated": null, "in": "PATH", "name": "owner" }, + { "alias": null, "deprecated": null, "in": "PATH", "name": "repo" }, { "alias": null, "deprecated": null, @@ -1006,15 +978,11 @@ }, { "method": "GET", - "url": "/repositories/{repository_id}/environments/{environment_name}/secrets", + "url": "/repos/{owner}/{repo}/environments/{environment_name}/secrets", "documentationUrl": "https://docs.github.com/rest/actions/secrets#list-environment-secrets", "parameters": [ - { - "alias": null, - "deprecated": null, - "in": "PATH", - "name": "repository_id" - }, + { "alias": null, "deprecated": null, "in": "PATH", "name": "owner" }, + { "alias": null, "deprecated": null, "in": "PATH", "name": "repo" }, { "alias": null, "deprecated": null, @@ -1028,15 +996,11 @@ }, { "method": "GET", - "url": "/repositories/{repository_id}/environments/{environment_name}/variables", + "url": "/repos/{owner}/{repo}/environments/{environment_name}/variables", "documentationUrl": "https://docs.github.com/rest/actions/variables#list-environment-variables", "parameters": [ - { - "alias": null, - "deprecated": null, - "in": "PATH", - "name": "repository_id" - }, + { "alias": null, "deprecated": null, "in": "PATH", "name": "owner" }, + { "alias": null, "deprecated": null, "in": "PATH", "name": "repo" }, { "alias": null, "deprecated": null, @@ -1761,15 +1725,11 @@ }, { "method": "PATCH", - "url": "/repositories/{repository_id}/environments/{environment_name}/variables/{name}", + "url": "/repos/{owner}/{repo}/environments/{environment_name}/variables/{name}", "documentationUrl": "https://docs.github.com/rest/actions/variables#update-an-environment-variable", "parameters": [ - { - "alias": null, - "deprecated": null, - "in": "PATH", - "name": "repository_id" - }, + { "alias": null, "deprecated": null, "in": "PATH", "name": "owner" }, + { "alias": null, "deprecated": null, "in": "PATH", "name": "repo" }, { "alias": null, "deprecated": null, "in": "BODY", "name": "name" }, { "alias": null, @@ -6897,7 +6857,8 @@ "documentationUrl": "https://docs.github.com/rest/licenses/licenses#get-the-license-for-a-repository", "parameters": [ { "alias": null, "deprecated": null, "in": "PATH", "name": "owner" }, - { "alias": null, "deprecated": null, "in": "PATH", "name": "repo" } + { "alias": null, "deprecated": null, "in": "PATH", "name": "repo" }, + { "alias": null, "deprecated": null, "in": "QUERY", "name": "ref" } ], "renamed": null }, @@ -10656,6 +10617,16 @@ ], "renamed": null }, + { + "method": "GET", + "url": "/repos/{owner}/{repo}/private-vulnerability-reporting", + "documentationUrl": "https://docs.github.com/rest/repos/repos#check-if-private-vulnerability-reporting-is-enabled-for-a-repository", + "parameters": [ + { "alias": null, "deprecated": null, "in": "PATH", "name": "owner" }, + { "alias": null, "deprecated": null, "in": "PATH", "name": "repo" } + ], + "renamed": null + }, { "method": "GET", "url": "/repos/{owner}/{repo}/vulnerability-alerts", diff --git a/src/generated/Endpoints.ts b/src/generated/Endpoints.ts index 8ecc1b675..5799e2930 100644 --- a/src/generated/Endpoints.ts +++ b/src/generated/Endpoints.ts @@ -741,6 +741,20 @@ export interface Endpoints { "/repos/{owner}/{repo}/environments/{environment_name}/deployment_protection_rules/{protection_rule_id}", "delete" >; + /** + * @see https://docs.github.com/rest/actions/secrets#delete-an-environment-secret + */ + "DELETE /repos/{owner}/{repo}/environments/{environment_name}/secrets/{secret_name}": Operation< + "/repos/{owner}/{repo}/environments/{environment_name}/secrets/{secret_name}", + "delete" + >; + /** + * @see https://docs.github.com/rest/actions/variables#delete-an-environment-variable + */ + "DELETE /repos/{owner}/{repo}/environments/{environment_name}/variables/{name}": Operation< + "/repos/{owner}/{repo}/environments/{environment_name}/variables/{name}", + "delete" + >; /** * @see https://docs.github.com/rest/git/refs#delete-a-reference */ @@ -937,20 +951,6 @@ export interface Endpoints { "/repos/{owner}/{repo}/vulnerability-alerts", "delete" >; - /** - * @see https://docs.github.com/rest/actions/secrets#delete-an-environment-secret - */ - "DELETE /repositories/{repository_id}/environments/{environment_name}/secrets/{secret_name}": Operation< - "/repositories/{repository_id}/environments/{environment_name}/secrets/{secret_name}", - "delete" - >; - /** - * @see https://docs.github.com/rest/actions/variables#delete-an-environment-variable - */ - "DELETE /repositories/{repository_id}/environments/{environment_name}/variables/{name}": Operation< - "/repositories/{repository_id}/environments/{environment_name}/variables/{name}", - "delete" - >; /** * @see https://docs.github.com/rest/teams/teams#delete-a-team-legacy */ @@ -2971,6 +2971,41 @@ export interface Endpoints { "/repos/{owner}/{repo}/environments/{environment_name}/deployment_protection_rules/{protection_rule_id}", "get" >; + /** + * @see https://docs.github.com/rest/actions/secrets#list-environment-secrets + */ + "GET /repos/{owner}/{repo}/environments/{environment_name}/secrets": Operation< + "/repos/{owner}/{repo}/environments/{environment_name}/secrets", + "get" + >; + /** + * @see https://docs.github.com/rest/actions/secrets#get-an-environment-public-key + */ + "GET /repos/{owner}/{repo}/environments/{environment_name}/secrets/public-key": Operation< + "/repos/{owner}/{repo}/environments/{environment_name}/secrets/public-key", + "get" + >; + /** + * @see https://docs.github.com/rest/actions/secrets#get-an-environment-secret + */ + "GET /repos/{owner}/{repo}/environments/{environment_name}/secrets/{secret_name}": Operation< + "/repos/{owner}/{repo}/environments/{environment_name}/secrets/{secret_name}", + "get" + >; + /** + * @see https://docs.github.com/rest/actions/variables#list-environment-variables + */ + "GET /repos/{owner}/{repo}/environments/{environment_name}/variables": Operation< + "/repos/{owner}/{repo}/environments/{environment_name}/variables", + "get" + >; + /** + * @see https://docs.github.com/rest/actions/variables#get-an-environment-variable + */ + "GET /repos/{owner}/{repo}/environments/{environment_name}/variables/{name}": Operation< + "/repos/{owner}/{repo}/environments/{environment_name}/variables/{name}", + "get" + >; /** * @see https://docs.github.com/rest/activity/events#list-repository-events */ @@ -3307,6 +3342,13 @@ export interface Endpoints { "/repos/{owner}/{repo}/pages/health", "get" >; + /** + * @see https://docs.github.com/rest/repos/repos#check-if-private-vulnerability-reporting-is-enabled-for-a-repository + */ + "GET /repos/{owner}/{repo}/private-vulnerability-reporting": Operation< + "/repos/{owner}/{repo}/private-vulnerability-reporting", + "get" + >; /** * @see https://docs.github.com/rest/projects/projects#list-repository-projects */ @@ -3682,41 +3724,6 @@ export interface Endpoints { * @see https://docs.github.com/rest/repos/repos#list-public-repositories */ "GET /repositories": Operation<"/repositories", "get">; - /** - * @see https://docs.github.com/rest/actions/secrets#list-environment-secrets - */ - "GET /repositories/{repository_id}/environments/{environment_name}/secrets": Operation< - "/repositories/{repository_id}/environments/{environment_name}/secrets", - "get" - >; - /** - * @see https://docs.github.com/rest/actions/secrets#get-an-environment-public-key - */ - "GET /repositories/{repository_id}/environments/{environment_name}/secrets/public-key": Operation< - "/repositories/{repository_id}/environments/{environment_name}/secrets/public-key", - "get" - >; - /** - * @see https://docs.github.com/rest/actions/secrets#get-an-environment-secret - */ - "GET /repositories/{repository_id}/environments/{environment_name}/secrets/{secret_name}": Operation< - "/repositories/{repository_id}/environments/{environment_name}/secrets/{secret_name}", - "get" - >; - /** - * @see https://docs.github.com/rest/actions/variables#list-environment-variables - */ - "GET /repositories/{repository_id}/environments/{environment_name}/variables": Operation< - "/repositories/{repository_id}/environments/{environment_name}/variables", - "get" - >; - /** - * @see https://docs.github.com/rest/actions/variables#get-an-environment-variable - */ - "GET /repositories/{repository_id}/environments/{environment_name}/variables/{name}": Operation< - "/repositories/{repository_id}/environments/{environment_name}/variables/{name}", - "get" - >; /** * @see https://docs.github.com/rest/search/search#search-code */ @@ -4474,6 +4481,13 @@ export interface Endpoints { "/repos/{owner}/{repo}/dependabot/alerts/{alert_number}", "patch" >; + /** + * @see https://docs.github.com/rest/actions/variables#update-an-environment-variable + */ + "PATCH /repos/{owner}/{repo}/environments/{environment_name}/variables/{name}": Operation< + "/repos/{owner}/{repo}/environments/{environment_name}/variables/{name}", + "patch" + >; /** * @see https://docs.github.com/rest/git/refs#update-a-reference */ @@ -4600,13 +4614,6 @@ export interface Endpoints { "/repos/{owner}/{repo}/security-advisories/{ghsa_id}", "patch" >; - /** - * @see https://docs.github.com/rest/actions/variables#update-an-environment-variable - */ - "PATCH /repositories/{repository_id}/environments/{environment_name}/variables/{name}": Operation< - "/repositories/{repository_id}/environments/{environment_name}/variables/{name}", - "patch" - >; /** * @see https://docs.github.com/rest/teams/teams#update-a-team-legacy */ @@ -5181,6 +5188,13 @@ export interface Endpoints { "/repos/{owner}/{repo}/environments/{environment_name}/deployment_protection_rules", "post" >; + /** + * @see https://docs.github.com/rest/actions/variables#create-an-environment-variable + */ + "POST /repos/{owner}/{repo}/environments/{environment_name}/variables": Operation< + "/repos/{owner}/{repo}/environments/{environment_name}/variables", + "post" + >; /** * @see https://docs.github.com/rest/repos/forks#create-a-fork */ @@ -5503,13 +5517,6 @@ export interface Endpoints { "/repos/{template_owner}/{template_repo}/generate", "post" >; - /** - * @see https://docs.github.com/rest/actions/variables#create-an-environment-variable - */ - "POST /repositories/{repository_id}/environments/{environment_name}/variables": Operation< - "/repositories/{repository_id}/environments/{environment_name}/variables", - "post" - >; /** * @see https://docs.github.com/rest/teams/discussions#create-a-discussion-legacy */ @@ -6037,6 +6044,13 @@ export interface Endpoints { "/repos/{owner}/{repo}/environments/{environment_name}/deployment-branch-policies/{branch_policy_id}", "put" >; + /** + * @see https://docs.github.com/rest/actions/secrets#create-or-update-an-environment-secret + */ + "PUT /repos/{owner}/{repo}/environments/{environment_name}/secrets/{secret_name}": Operation< + "/repos/{owner}/{repo}/environments/{environment_name}/secrets/{secret_name}", + "put" + >; /** * @see https://docs.github.com/rest/migrations/source-imports#start-an-import */ @@ -6142,13 +6156,6 @@ export interface Endpoints { "/repos/{owner}/{repo}/vulnerability-alerts", "put" >; - /** - * @see https://docs.github.com/rest/actions/secrets#create-or-update-an-environment-secret - */ - "PUT /repositories/{repository_id}/environments/{environment_name}/secrets/{secret_name}": Operation< - "/repositories/{repository_id}/environments/{environment_name}/secrets/{secret_name}", - "put" - >; /** * @see https://docs.github.com/rest/teams/members#add-team-member-legacy */