Skip to content

Update OpenAPI 3.0 Descriptions #4784

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
89 changes: 79 additions & 10 deletions descriptions/api.github.com/api.github.com.2022-11-28.json
Original file line number Diff line number Diff line change
Expand Up @@ -180,6 +180,10 @@
"name": "hosted-compute",
"description": "Manage hosted compute networking resources."
},
{
"name": "credentials",
"description": "Revoke compromised or leaked GitHub credentials."
},
{
"name": "campaigns",
"description": "Endpoints to manage campaigns via the REST API."
Expand Down Expand Up @@ -2032,6 +2036,71 @@
}
}
},
"/credentials/revoke": {
"post": {
"summary": "Revoke a list of credentials",
"description": "Submit a list of credentials to be revoked. This endpoint is intended to revoke credentials the caller does not own and may have found exposed on GitHub.com or elsewhere. It can also be used for credentials associated with an old user account that you no longer have access to. Credential owners will be notified of the revocation.\n\nThis endpoint currently accepts the following credential types:\n- Personal access tokens (classic)\n- Fine-grained personal access tokens\n\nRevoked credentials may impact users on GitHub Free, Pro, & Team and GitHub Enterprise Cloud, and GitHub Enterprise Cloud with Enterprise Managed Users.\nGitHub cannot reactivate any credentials that have been revoked; new credentials will need to be generated.\n\nTo prevent abuse, this API is limited to only 60 unauthenticated requests per hour and a max of 1000 tokens per API request.\n\n> [!NOTE]\n> Any authenticated requests will return a 403.",
"tags": [
"credentials"
],
"operationId": "credentials/revoke",
"externalDocs": {
"description": "API method documentation",
"url": "https://docs.github.com/rest/credentials/revoke#revoke-a-list-of-credentials"
},
"requestBody": {
"required": true,
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"credentials": {
"type": "array",
"description": "A list of credentials to be revoked, up to 1000 per request.",
"items": {
"type": "string"
},
"minItems": 1,
"maxItems": 1000
}
},
"required": [
"credentials"
]
},
"examples": {
"default": {
"value": {
"credentials": [
"ghp_1234567890abcdef1234567890abcdef12345678",
"ghp_abcdef1234567890abcdef1234567890abcdef12"
]
}
}
}
}
}
},
"responses": {
"202": {
"$ref": "#/components/responses/accepted"
},
"422": {
"$ref": "#/components/responses/validation_failed_simple"
},
"500": {
"$ref": "#/components/responses/internal_error"
}
},
"x-github": {
"githubCloudOnly": false,
"enabledForGitHubApps": false,
"category": "credentials",
"subcategory": "revoke"
}
}
},
"/emojis": {
"get": {
"summary": "Get emojis",
Expand Down Expand Up @@ -300936,6 +301005,16 @@
}
}
},
"internal_error": {
"description": "Internal Error",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/basic-error"
}
}
}
},
"conflict": {
"description": "Conflict",
"content": {
Expand Down Expand Up @@ -301028,16 +301107,6 @@
}
}
},
"internal_error": {
"description": "Internal Error",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/basic-error"
}
}
}
},
"actions_runner_jitconfig": {
"description": "Response",
"content": {
Expand Down
72 changes: 66 additions & 6 deletions descriptions/api.github.com/api.github.com.2022-11-28.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,8 @@ tags:
description: Manage private registry configurations.
- name: hosted-compute
description: Manage hosted compute networking resources.
- name: credentials
description: Revoke compromised or leaked GitHub credentials.
- name: campaigns
description: Endpoints to manage campaigns via the REST API.
servers:
Expand Down Expand Up @@ -1401,6 +1403,64 @@ paths:
enabledForGitHubApps: true
category: codes-of-conduct
subcategory: codes-of-conduct
"/credentials/revoke":
post:
summary: Revoke a list of credentials
description: |-
Submit a list of credentials to be revoked. This endpoint is intended to revoke credentials the caller does not own and may have found exposed on GitHub.com or elsewhere. It can also be used for credentials associated with an old user account that you no longer have access to. Credential owners will be notified of the revocation.

This endpoint currently accepts the following credential types:
- Personal access tokens (classic)
- Fine-grained personal access tokens

Revoked credentials may impact users on GitHub Free, Pro, & Team and GitHub Enterprise Cloud, and GitHub Enterprise Cloud with Enterprise Managed Users.
GitHub cannot reactivate any credentials that have been revoked; new credentials will need to be generated.

To prevent abuse, this API is limited to only 60 unauthenticated requests per hour and a max of 1000 tokens per API request.

> [!NOTE]
> Any authenticated requests will return a 403.
tags:
- credentials
operationId: credentials/revoke
externalDocs:
description: API method documentation
url: https://docs.github.com/rest/credentials/revoke#revoke-a-list-of-credentials
requestBody:
required: true
content:
application/json:
schema:
type: object
properties:
credentials:
type: array
description: A list of credentials to be revoked, up to 1000 per
request.
items:
type: string
minItems: 1
maxItems: 1000
required:
- credentials
examples:
default:
value:
credentials:
- ghp_1234567890abcdef1234567890abcdef12345678
- ghp_abcdef1234567890abcdef1234567890abcdef12
responses:
'202':
"$ref": "#/components/responses/accepted"
'422':
"$ref": "#/components/responses/validation_failed_simple"
'500':
"$ref": "#/components/responses/internal_error"
x-github:
githubCloudOnly: false
enabledForGitHubApps: false
category: credentials
subcategory: revoke
"/emojis":
get:
summary: Get emojis
Expand Down Expand Up @@ -228756,6 +228816,12 @@ components:
application/json:
schema:
"$ref": "#/components/schemas/basic-error"
internal_error:
description: Internal Error
content:
application/json:
schema:
"$ref": "#/components/schemas/basic-error"
conflict:
description: Conflict
content:
Expand Down Expand Up @@ -228813,12 +228879,6 @@ components:
examples:
default:
"$ref": "#/components/examples/billing-usage-report"
internal_error:
description: Internal Error
content:
application/json:
schema:
"$ref": "#/components/schemas/basic-error"
actions_runner_jitconfig:
description: Response
content:
Expand Down
89 changes: 79 additions & 10 deletions descriptions/api.github.com/api.github.com.json
Original file line number Diff line number Diff line change
Expand Up @@ -180,6 +180,10 @@
"name": "hosted-compute",
"description": "Manage hosted compute networking resources."
},
{
"name": "credentials",
"description": "Revoke compromised or leaked GitHub credentials."
},
{
"name": "campaigns",
"description": "Endpoints to manage campaigns via the REST API."
Expand Down Expand Up @@ -2032,6 +2036,71 @@
}
}
},
"/credentials/revoke": {
"post": {
"summary": "Revoke a list of credentials",
"description": "Submit a list of credentials to be revoked. This endpoint is intended to revoke credentials the caller does not own and may have found exposed on GitHub.com or elsewhere. It can also be used for credentials associated with an old user account that you no longer have access to. Credential owners will be notified of the revocation.\n\nThis endpoint currently accepts the following credential types:\n- Personal access tokens (classic)\n- Fine-grained personal access tokens\n\nRevoked credentials may impact users on GitHub Free, Pro, & Team and GitHub Enterprise Cloud, and GitHub Enterprise Cloud with Enterprise Managed Users.\nGitHub cannot reactivate any credentials that have been revoked; new credentials will need to be generated.\n\nTo prevent abuse, this API is limited to only 60 unauthenticated requests per hour and a max of 1000 tokens per API request.\n\n> [!NOTE]\n> Any authenticated requests will return a 403.",
"tags": [
"credentials"
],
"operationId": "credentials/revoke",
"externalDocs": {
"description": "API method documentation",
"url": "https://docs.github.com/rest/credentials/revoke#revoke-a-list-of-credentials"
},
"requestBody": {
"required": true,
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"credentials": {
"type": "array",
"description": "A list of credentials to be revoked, up to 1000 per request.",
"items": {
"type": "string"
},
"minItems": 1,
"maxItems": 1000
}
},
"required": [
"credentials"
]
},
"examples": {
"default": {
"value": {
"credentials": [
"ghp_1234567890abcdef1234567890abcdef12345678",
"ghp_abcdef1234567890abcdef1234567890abcdef12"
]
}
}
}
}
}
},
"responses": {
"202": {
"$ref": "#/components/responses/accepted"
},
"422": {
"$ref": "#/components/responses/validation_failed_simple"
},
"500": {
"$ref": "#/components/responses/internal_error"
}
},
"x-github": {
"githubCloudOnly": false,
"enabledForGitHubApps": false,
"category": "credentials",
"subcategory": "revoke"
}
}
},
"/emojis": {
"get": {
"summary": "Get emojis",
Expand Down Expand Up @@ -300936,6 +301005,16 @@
}
}
},
"internal_error": {
"description": "Internal Error",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/basic-error"
}
}
}
},
"conflict": {
"description": "Conflict",
"content": {
Expand Down Expand Up @@ -301028,16 +301107,6 @@
}
}
},
"internal_error": {
"description": "Internal Error",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/basic-error"
}
}
}
},
"actions_runner_jitconfig": {
"description": "Response",
"content": {
Expand Down
Loading