From e344bfbb8dcb2aa325e02dc7b882c7f2733bb1a0 Mon Sep 17 00:00:00 2001 From: github-openapi-bot Date: Tue, 27 Sep 2022 15:20:48 -0700 Subject: [PATCH] Update OpenAPI 3.0 Descriptions --- .../api.github.com/api.github.com.json | 88 +++++ .../api.github.com/api.github.com.yaml | 64 ++++ .../dereferenced/api.github.com.deref.json | 206 +++++++++++ .../dereferenced/api.github.com.deref.yaml | 322 +++++++++++------- .../ghec/dereferenced/ghec.deref.json | 206 +++++++++++ .../ghec/dereferenced/ghec.deref.yaml | 322 +++++++++++------- descriptions/ghec/ghec.json | 88 +++++ descriptions/ghec/ghec.yaml | 64 ++++ 8 files changed, 1098 insertions(+), 262 deletions(-) diff --git a/descriptions/api.github.com/api.github.com.json b/descriptions/api.github.com/api.github.com.json index 3d12739615..9a064b83db 100644 --- a/descriptions/api.github.com/api.github.com.json +++ b/descriptions/api.github.com/api.github.com.json @@ -10024,6 +10024,94 @@ } } }, + "/orgs/{org}/codespaces/billing": { + "put": { + "summary": "Set the visibility of organization codespaces", + "description": "Sets which users can access codespaces in an organization. This is synonymous with granting or revoking codespaces billing permissions for users according to the visibility.\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.", + "tags": [ + "codespaces" + ], + "operationId": "codespaces/set-codespaces-billing", + "externalDocs": { + "description": "API method documentation", + "url": "https://docs.github.com/rest/reference/codespaces#set-codespaces-billing" + }, + "parameters": [ + { + "$ref": "#/components/parameters/org" + } + ], + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "visibility": { + "type": "string", + "description": "Which users can access codespaces in the organization. `disabled` means that no users can access codespaces in the organization.", + "enum": [ + "disabled", + "selected_members", + "all_members", + "all_members_and_outside_collaborators" + ] + }, + "selected_usernames": { + "type": "array", + "description": "The usernames of the organization members who should be granted access to codespaces in the organization. Required when `visibility` is `selected_members`.", + "items": { + "type": "string" + } + } + }, + "required": [ + "visibility" + ] + }, + "examples": { + "default": { + "value": { + "visibility": "selected_members", + "selected_usernames": [ + "johnDoe", + "atomIO" + ] + } + } + } + } + } + }, + "responses": { + "204": { + "description": "Response when successfully modifying permissions." + }, + "304": { + "$ref": "#/components/responses/not_modified" + }, + "400": { + "description": "Users are neither members nor collaborators of this organization." + }, + "404": { + "$ref": "#/components/responses/not_found" + }, + "422": { + "$ref": "#/components/responses/validation_failed" + }, + "500": { + "$ref": "#/components/responses/internal_error" + } + }, + "x-github": { + "githubCloudOnly": false, + "enabledForGitHubApps": false, + "category": "codespaces", + "subcategory": "organizations" + } + } + }, "/orgs/{org}/custom_roles": { "post": { "summary": "Create a custom role", diff --git a/descriptions/api.github.com/api.github.com.yaml b/descriptions/api.github.com/api.github.com.yaml index 69cbc9fdd4..a7d2938c41 100644 --- a/descriptions/api.github.com/api.github.com.yaml +++ b/descriptions/api.github.com/api.github.com.yaml @@ -7264,6 +7264,70 @@ paths: enabledForGitHubApps: false category: codespaces subcategory: organizations + "/orgs/{org}/codespaces/billing": + put: + summary: Set the visibility of organization codespaces + description: |- + Sets which users can access codespaces in an organization. This is synonymous with granting or revoking codespaces billing permissions for users according to the visibility. + You must authenticate using an access token with the `admin:org` scope to use this endpoint. + tags: + - codespaces + operationId: codespaces/set-codespaces-billing + externalDocs: + description: API method documentation + url: https://docs.github.com/rest/reference/codespaces#set-codespaces-billing + parameters: + - "$ref": "#/components/parameters/org" + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + visibility: + type: string + description: Which users can access codespaces in the organization. + `disabled` means that no users can access codespaces in the organization. + enum: + - disabled + - selected_members + - all_members + - all_members_and_outside_collaborators + selected_usernames: + type: array + description: The usernames of the organization members who should + be granted access to codespaces in the organization. Required + when `visibility` is `selected_members`. + items: + type: string + required: + - visibility + examples: + default: + value: + visibility: selected_members + selected_usernames: + - johnDoe + - atomIO + responses: + '204': + description: Response when successfully modifying permissions. + '304': + "$ref": "#/components/responses/not_modified" + '400': + description: Users are neither members nor collaborators of this organization. + '404': + "$ref": "#/components/responses/not_found" + '422': + "$ref": "#/components/responses/validation_failed" + '500': + "$ref": "#/components/responses/internal_error" + x-github: + githubCloudOnly: false + enabledForGitHubApps: false + category: codespaces + subcategory: organizations "/orgs/{org}/custom_roles": post: summary: Create a custom role diff --git a/descriptions/api.github.com/dereferenced/api.github.com.deref.json b/descriptions/api.github.com/dereferenced/api.github.com.deref.json index 28f867751e..6eff664681 100644 --- a/descriptions/api.github.com/dereferenced/api.github.com.deref.json +++ b/descriptions/api.github.com/dereferenced/api.github.com.deref.json @@ -71807,6 +71807,212 @@ } } }, + "/orgs/{org}/codespaces/billing": { + "put": { + "summary": "Set the visibility of organization codespaces", + "description": "Sets which users can access codespaces in an organization. This is synonymous with granting or revoking codespaces billing permissions for users according to the visibility.\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.", + "tags": [ + "codespaces" + ], + "operationId": "codespaces/set-codespaces-billing", + "externalDocs": { + "description": "API method documentation", + "url": "https://docs.github.com/rest/reference/codespaces#set-codespaces-billing" + }, + "parameters": [ + { + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "path", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "visibility": { + "type": "string", + "description": "Which users can access codespaces in the organization. `disabled` means that no users can access codespaces in the organization.", + "enum": [ + "disabled", + "selected_members", + "all_members", + "all_members_and_outside_collaborators" + ] + }, + "selected_usernames": { + "type": "array", + "description": "The usernames of the organization members who should be granted access to codespaces in the organization. Required when `visibility` is `selected_members`.", + "items": { + "type": "string" + } + } + }, + "required": [ + "visibility" + ] + }, + "examples": { + "default": { + "value": { + "visibility": "selected_members", + "selected_usernames": [ + "johnDoe", + "atomIO" + ] + } + } + } + } + } + }, + "responses": { + "204": { + "description": "Response when successfully modifying permissions." + }, + "304": { + "description": "Not modified" + }, + "400": { + "description": "Users are neither members nor collaborators of this organization." + }, + "404": { + "description": "Resource not found", + "content": { + "application/json": { + "schema": { + "title": "Basic Error", + "description": "Basic Error", + "type": "object", + "properties": { + "message": { + "type": "string" + }, + "documentation_url": { + "type": "string" + }, + "url": { + "type": "string" + }, + "status": { + "type": "string" + } + } + } + } + } + }, + "422": { + "description": "Validation failed, or the endpoint has been spammed.", + "content": { + "application/json": { + "schema": { + "title": "Validation Error", + "description": "Validation Error", + "type": "object", + "required": [ + "message", + "documentation_url" + ], + "properties": { + "message": { + "type": "string" + }, + "documentation_url": { + "type": "string" + }, + "errors": { + "type": "array", + "items": { + "type": "object", + "required": [ + "code" + ], + "properties": { + "resource": { + "type": "string" + }, + "field": { + "type": "string" + }, + "message": { + "type": "string" + }, + "code": { + "type": "string" + }, + "index": { + "type": "integer" + }, + "value": { + "oneOf": [ + { + "type": "string", + "nullable": true + }, + { + "type": "integer", + "nullable": true + }, + { + "type": "array", + "nullable": true, + "items": { + "type": "string" + } + } + ] + } + } + } + } + } + } + } + } + }, + "500": { + "description": "Internal Error", + "content": { + "application/json": { + "schema": { + "title": "Basic Error", + "description": "Basic Error", + "type": "object", + "properties": { + "message": { + "type": "string" + }, + "documentation_url": { + "type": "string" + }, + "url": { + "type": "string" + }, + "status": { + "type": "string" + } + } + } + } + } + } + }, + "x-github": { + "githubCloudOnly": false, + "enabledForGitHubApps": false, + "category": "codespaces", + "subcategory": "organizations" + } + } + }, "/orgs/{org}/custom_roles": { "post": { "summary": "Create a custom role", diff --git a/descriptions/api.github.com/dereferenced/api.github.com.deref.yaml b/descriptions/api.github.com/dereferenced/api.github.com.deref.yaml index c2846786a5..54cd749212 100644 --- a/descriptions/api.github.com/dereferenced/api.github.com.deref.yaml +++ b/descriptions/api.github.com/dereferenced/api.github.com.deref.yaml @@ -819,7 +819,7 @@ paths: schema: type: integer default: 30 - - &137 + - &138 name: cursor description: 'Used for pagination: the starting delivery from which the page of deliveries is fetched. Refer to the `link` header for the next and previous @@ -835,7 +835,7 @@ paths: application/json: schema: type: array - items: &138 + items: &139 title: Simple webhook delivery description: Delivery made by a webhook, without request and response information. @@ -906,7 +906,7 @@ paths: - installation_id - repository_id examples: - default: &139 + default: &140 value: - id: 12345678 guid: 0b989ba4-242f-11e5-81e1-c7b6966d2516 @@ -1032,7 +1032,7 @@ paths: description: Response content: application/json: - schema: &140 + schema: &141 title: Webhook delivery description: Delivery made by a webhook. type: object @@ -1140,7 +1140,7 @@ paths: - request - response examples: - default: &141 + default: &142 value: id: 12345678 guid: 0b989ba4-242f-11e5-81e1-c7b6966d2516 @@ -1199,7 +1199,7 @@ paths: parameters: - *11 responses: - '202': &142 + '202': &143 description: Accepted content: application/json: @@ -11618,7 +11618,7 @@ paths: - closed - all default: open - - &149 + - &150 name: labels description: 'A list of comma separated label names. Example: `bug,ui,@high`' in: query @@ -11669,7 +11669,7 @@ paths: type: array items: *81 examples: - default: &150 + default: &151 value: - id: 1 node_id: MDU6SXNzdWUx @@ -14034,7 +14034,7 @@ paths: type: integer custom_roles: type: array - items: &131 + items: &132 title: Organization Custom Repository Role description: Custom repository roles created by organization administrators @@ -17715,7 +17715,7 @@ paths: type: array items: *19 examples: - default: &151 + default: &152 value: - login: octocat id: 1 @@ -18587,7 +18587,7 @@ paths: stop_url: https://api.github.com/user/codespaces/monalisa-octocat-hello-world-f8adfad99a/stop recent_folders: [] '304': *27 - '500': &152 + '500': &131 description: Internal Error content: application/json: @@ -18600,6 +18600,66 @@ paths: enabledForGitHubApps: false category: codespaces subcategory: organizations + "/orgs/{org}/codespaces/billing": + put: + summary: Set the visibility of organization codespaces + description: |- + Sets which users can access codespaces in an organization. This is synonymous with granting or revoking codespaces billing permissions for users according to the visibility. + You must authenticate using an access token with the `admin:org` scope to use this endpoint. + tags: + - codespaces + operationId: codespaces/set-codespaces-billing + externalDocs: + description: API method documentation + url: https://docs.github.com/rest/reference/codespaces#set-codespaces-billing + parameters: + - *100 + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + visibility: + type: string + description: Which users can access codespaces in the organization. + `disabled` means that no users can access codespaces in the organization. + enum: + - disabled + - selected_members + - all_members + - all_members_and_outside_collaborators + selected_usernames: + type: array + description: The usernames of the organization members who should + be granted access to codespaces in the organization. Required + when `visibility` is `selected_members`. + items: + type: string + required: + - visibility + examples: + default: + value: + visibility: selected_members + selected_usernames: + - johnDoe + - atomIO + responses: + '204': + description: Response when successfully modifying permissions. + '304': *27 + '400': + description: Users are neither members nor collaborators of this organization. + '404': *16 + '422': *10 + '500': *131 + x-github: + githubCloudOnly: false + enabledForGitHubApps: false + category: codespaces + subcategory: organizations "/orgs/{org}/custom_roles": post: summary: Create a custom role @@ -18664,7 +18724,7 @@ paths: description: Response content: application/json: - schema: *131 + schema: *132 examples: default: value: @@ -18722,7 +18782,7 @@ paths: url: https://docs.github.com/rest/reference/orgs#update-a-custom-role parameters: - *100 - - &132 + - &133 name: role_id description: The unique identifier of the role. in: path @@ -18772,7 +18832,7 @@ paths: description: Response content: application/json: - schema: *131 + schema: *132 examples: default: value: @@ -18831,7 +18891,7 @@ paths: url: https://docs.github.com/rest/reference/orgs#delete-a-custom-role parameters: - *100 - - *132 + - *133 responses: '204': description: Response @@ -18873,7 +18933,7 @@ paths: type: integer secrets: type: array - items: &133 + items: &134 title: Dependabot Secret for an Organization description: Secrets for GitHub Dependabot for an organization. type: object @@ -18997,7 +19057,7 @@ paths: description: Response content: application/json: - schema: *133 + schema: *134 examples: default: value: @@ -19443,7 +19503,7 @@ paths: application/json: schema: type: array - items: &146 + items: &147 title: Organization Invitation description: Organization Invitation type: object @@ -19486,7 +19546,7 @@ paths: - invitation_teams_url - node_id examples: - default: &147 + default: &148 value: - id: 1 login: monalisa @@ -19598,7 +19658,7 @@ paths: application/json: schema: type: array - items: &134 + items: &135 title: Org Hook description: Org Hook type: object @@ -19764,9 +19824,9 @@ paths: description: Response content: application/json: - schema: *134 + schema: *135 examples: - default: &135 + default: &136 value: id: 1 url: https://api.github.com/orgs/octocat/hooks/1 @@ -19808,7 +19868,7 @@ paths: url: https://docs.github.com/rest/reference/orgs#get-an-organization-webhook parameters: - *100 - - &136 + - &137 name: hook_id description: The unique identifier of the hook. in: path @@ -19820,9 +19880,9 @@ paths: description: Response content: application/json: - schema: *134 + schema: *135 examples: - default: *135 + default: *136 '404': *16 x-github: githubCloudOnly: false @@ -19844,7 +19904,7 @@ paths: url: https://docs.github.com/rest/reference/orgs#update-an-organization-webhook parameters: - *100 - - *136 + - *137 requestBody: required: false content: @@ -19890,7 +19950,7 @@ paths: description: Response content: application/json: - schema: *134 + schema: *135 examples: default: value: @@ -19926,7 +19986,7 @@ paths: url: https://docs.github.com/rest/reference/orgs#delete-an-organization-webhook parameters: - *100 - - *136 + - *137 responses: '204': description: Response @@ -19951,7 +20011,7 @@ paths: url: https://docs.github.com/rest/reference/orgs#get-a-webhook-configuration-for-an-organization parameters: - *100 - - *136 + - *137 responses: '200': description: Response @@ -19979,7 +20039,7 @@ paths: url: https://docs.github.com/rest/reference/orgs#update-a-webhook-configuration-for-an-organization parameters: - *100 - - *136 + - *137 requestBody: required: false content: @@ -20025,9 +20085,9 @@ paths: url: https://docs.github.com/rest/reference/orgs#list-deliveries-for-an-organization-webhook parameters: - *100 - - *136 - - *12 - *137 + - *12 + - *138 responses: '200': description: Response @@ -20035,9 +20095,9 @@ paths: application/json: schema: type: array - items: *138 + items: *139 examples: - default: *139 + default: *140 '400': *9 '422': *10 x-github: @@ -20057,16 +20117,16 @@ paths: url: https://docs.github.com/rest/reference/orgs#get-a-webhook-delivery-for-an-organization-webhook parameters: - *100 - - *136 + - *137 - *11 responses: '200': description: Response content: application/json: - schema: *140 + schema: *141 examples: - default: *141 + default: *142 '400': *9 '422': *10 x-github: @@ -20086,10 +20146,10 @@ paths: url: https://docs.github.com/rest/reference/orgs#redeliver-a-delivery-for-an-organization-webhook parameters: - *100 - - *136 + - *137 - *11 responses: - '202': *142 + '202': *143 '400': *9 '422': *10 x-github: @@ -20110,7 +20170,7 @@ paths: url: https://docs.github.com/rest/reference/orgs#ping-an-organization-webhook parameters: - *100 - - *136 + - *137 responses: '204': description: Response @@ -20303,12 +20363,12 @@ paths: application/json: schema: anyOf: - - &144 + - &145 title: Interaction Limits description: Interaction limit settings. type: object properties: - limit: &143 + limit: &144 type: string description: The type of GitHub user that can comment, open issues, or create pull requests while the interaction limit @@ -20333,7 +20393,7 @@ paths: properties: {} additionalProperties: false examples: - default: &145 + default: &146 value: limit: collaborators_only origin: organization @@ -20368,7 +20428,7 @@ paths: duration type: object properties: - limit: *143 + limit: *144 expiry: type: string description: 'The duration of the interaction restriction. Default: @@ -20387,9 +20447,9 @@ paths: description: Response content: application/json: - schema: *144 + schema: *145 examples: - default: *145 + default: *146 '422': *10 x-github: githubCloudOnly: false @@ -20440,9 +20500,9 @@ paths: application/json: schema: type: array - items: *146 + items: *147 examples: - default: *147 + default: *148 headers: Link: *28 '404': *16 @@ -20514,7 +20574,7 @@ paths: description: Response content: application/json: - schema: *146 + schema: *147 examples: default: value: @@ -20568,7 +20628,7 @@ paths: url: https://docs.github.com/rest/reference/orgs#cancel-an-organization-invitation parameters: - *100 - - &148 + - &149 name: invitation_id description: The unique identifier of the invitation. in: path @@ -20599,7 +20659,7 @@ paths: url: https://docs.github.com/rest/reference/orgs#list-organization-invitation-teams parameters: - *100 - - *148 + - *149 - *12 - *32 responses: @@ -20810,7 +20870,7 @@ paths: - closed - all default: open - - *149 + - *150 - name: sort description: What to sort results by. in: query @@ -20835,7 +20895,7 @@ paths: type: array items: *81 examples: - default: *150 + default: *151 headers: Link: *28 '404': *16 @@ -20893,7 +20953,7 @@ paths: type: array items: *19 examples: - default: *151 + default: *152 headers: Link: *28 '422': *10 @@ -20980,9 +21040,9 @@ paths: schema: type: string responses: - '202': *142 + '202': *143 '304': *27 - '500': *152 + '500': *131 '401': *23 '403': *24 '404': *16 @@ -21157,7 +21217,7 @@ paths: recent_folders: [] template: '304': *27 - '500': *152 + '500': *131 '401': *23 '403': *24 '404': *16 @@ -22330,7 +22390,7 @@ paths: type: array items: *19 examples: - default: *151 + default: *152 headers: Link: *28 x-github: @@ -23321,7 +23381,7 @@ paths: type: array items: *19 examples: - default: *151 + default: *152 headers: Link: *28 x-github: @@ -26034,9 +26094,9 @@ paths: application/json: schema: type: array - items: *146 + items: *147 examples: - default: *147 + default: *148 headers: Link: *28 x-github: @@ -26082,7 +26142,7 @@ paths: type: array items: *19 examples: - default: *151 + default: *152 headers: Link: *28 x-github: @@ -28420,7 +28480,7 @@ paths: type: array items: *19 examples: - default: *151 + default: *152 headers: Link: *28 '404': *16 @@ -33545,7 +33605,7 @@ paths: '204': description: Response '403': *24 - '500': *152 + '500': *131 x-github: githubCloudOnly: false enabledForGitHubApps: true @@ -34832,7 +34892,7 @@ paths: type: array items: *19 examples: - default: *151 + default: *152 headers: Link: *28 '404': *16 @@ -38049,7 +38109,7 @@ paths: type: array items: *19 examples: - default: *151 + default: *152 '404': *16 x-github: githubCloudOnly: false @@ -38112,7 +38172,7 @@ paths: type: array items: *19 examples: - default: *151 + default: *152 '422': *10 x-github: githubCloudOnly: false @@ -38176,7 +38236,7 @@ paths: type: array items: *19 examples: - default: *151 + default: *152 '422': *10 x-github: githubCloudOnly: false @@ -38239,7 +38299,7 @@ paths: type: array items: *19 examples: - default: *151 + default: *152 '422': *10 x-github: githubCloudOnly: false @@ -42378,7 +42438,7 @@ paths: start_url: https://api.github.com/user/codespaces/monalisa-octocat-hello-world-3f89ada1j3/start stop_url: https://api.github.com/user/codespaces/monalisa-octocat-hello-world-3f89ada1j3/stop recent_folders: [] - '500': *152 + '500': *131 '401': *23 '403': *24 '404': *16 @@ -42531,7 +42591,7 @@ paths: name: kitchensink - path: ".devcontainer.json" total_count: 3 - '500': *152 + '500': *131 '400': *9 '401': *23 '403': *24 @@ -42610,7 +42670,7 @@ paths: memory_in_bytes: 17179869184 cpus: 8 '304': *27 - '500': *152 + '500': *131 '401': *23 '403': *24 '404': *16 @@ -44094,7 +44154,7 @@ paths: sha: 6dcb09b5b57875f334f61aebed695e2e4193db5e headers: Link: *28 - '500': *152 + '500': *131 '400': *9 '404': *16 '409': *228 @@ -45219,7 +45279,7 @@ paths: ..... '422': *10 '404': *16 - '500': *152 + '500': *131 '503': *63 x-github: githubCloudOnly: false @@ -46374,7 +46434,7 @@ paths: patch: "@@ -132,7 +132,7 @@ module Test @@ -1000,7 +1000,7 @@ module Test" '404': *16 - '500': *152 + '500': *131 '503': *63 x-github: githubCloudOnly: false @@ -52386,7 +52446,7 @@ paths: parameters: - *196 - *197 - - *136 + - *137 responses: '200': description: Response @@ -52416,7 +52476,7 @@ paths: parameters: - *196 - *197 - - *136 + - *137 requestBody: required: true content: @@ -52499,7 +52559,7 @@ paths: parameters: - *196 - *197 - - *136 + - *137 responses: '204': description: Response @@ -52525,7 +52585,7 @@ paths: parameters: - *196 - *197 - - *136 + - *137 responses: '200': description: Response @@ -52554,7 +52614,7 @@ paths: parameters: - *196 - *197 - - *136 + - *137 requestBody: required: false content: @@ -52599,9 +52659,9 @@ paths: parameters: - *196 - *197 - - *136 - - *12 - *137 + - *12 + - *138 responses: '200': description: Response @@ -52609,9 +52669,9 @@ paths: application/json: schema: type: array - items: *138 + items: *139 examples: - default: *139 + default: *140 '400': *9 '422': *10 x-github: @@ -52632,16 +52692,16 @@ paths: parameters: - *196 - *197 - - *136 + - *137 - *11 responses: '200': description: Response content: application/json: - schema: *140 + schema: *141 examples: - default: *141 + default: *142 '400': *9 '422': *10 x-github: @@ -52662,10 +52722,10 @@ paths: parameters: - *196 - *197 - - *136 + - *137 - *11 responses: - '202': *142 + '202': *143 '400': *9 '422': *10 x-github: @@ -52687,7 +52747,7 @@ paths: parameters: - *196 - *197 - - *136 + - *137 responses: '204': description: Response @@ -52713,7 +52773,7 @@ paths: parameters: - *196 - *197 - - *136 + - *137 responses: '204': description: Response @@ -53435,7 +53495,7 @@ paths: application/json: schema: anyOf: - - *144 + - *145 - type: object properties: {} additionalProperties: false @@ -53483,7 +53543,7 @@ paths: description: Response content: application/json: - schema: *144 + schema: *145 examples: default: *353 '409': @@ -53677,7 +53737,7 @@ paths: parameters: - *196 - *197 - - *148 + - *149 requestBody: required: false content: @@ -53839,7 +53899,7 @@ paths: parameters: - *196 - *197 - - *148 + - *149 responses: '204': description: Response @@ -53906,7 +53966,7 @@ paths: required: false schema: type: string - - *149 + - *150 - name: sort description: What to sort results by. in: query @@ -58338,7 +58398,7 @@ paths: - *196 - *197 responses: - '202': *142 + '202': *143 '403': description: |- We will return a 403 with one of the following messages: @@ -62444,7 +62504,7 @@ paths: default: *401 '304': *27 '404': *16 - '500': *152 + '500': *131 '503': *63 x-github: githubCloudOnly: false @@ -63011,7 +63071,7 @@ paths: headers: Link: *28 '422': *10 - '500': *152 + '500': *131 '503': *63 x-github: githubCloudOnly: false @@ -67081,7 +67141,7 @@ paths: - - 1302998400 - 1124 - -435 - '202': *142 + '202': *143 '204': &422 description: A header with no content is returned. x-github: @@ -67150,7 +67210,7 @@ paths: - 0 total: 89 week: 1336280400 - '202': *142 + '202': *143 '204': *422 x-github: githubCloudOnly: false @@ -67249,7 +67309,7 @@ paths: a: 6898 d: 77 c: 10 - '202': *142 + '202': *143 '204': *422 x-github: githubCloudOnly: false @@ -67591,7 +67651,7 @@ paths: type: array items: *19 examples: - default: *151 + default: *152 headers: Link: *28 x-github: @@ -72188,9 +72248,9 @@ paths: application/json: schema: type: array - items: *146 + items: *147 examples: - default: *147 + default: *148 headers: Link: *28 x-github: @@ -72238,7 +72298,7 @@ paths: type: array items: *19 examples: - default: *151 + default: *152 headers: Link: *28 '404': *16 @@ -73530,7 +73590,7 @@ paths: type: array items: *19 examples: - default: *151 + default: *152 '304': *27 '404': *16 '403': *24 @@ -73657,7 +73717,7 @@ paths: examples: default: *448 '304': *27 - '500': *152 + '500': *131 '401': *23 '403': *24 '404': *16 @@ -74162,7 +74222,7 @@ paths: '401': *23 '403': *24 '404': *16 - '500': *152 + '500': *131 x-github: githubCloudOnly: false enabledForGitHubApps: false @@ -74215,7 +74275,7 @@ paths: '401': *23 '403': *24 '404': *16 - '500': *152 + '500': *131 x-github: githubCloudOnly: false enabledForGitHubApps: false @@ -74247,7 +74307,7 @@ paths: '401': *23 '403': *24 '404': *16 - '500': *152 + '500': *131 x-github: githubCloudOnly: false enabledForGitHubApps: false @@ -74278,7 +74338,7 @@ paths: '401': *23 '403': *24 '404': *16 - '500': *152 + '500': *131 x-github: githubCloudOnly: false enabledForGitHubApps: false @@ -74310,7 +74370,7 @@ paths: examples: default: *286 '304': *27 - '500': *152 + '500': *131 '401': *23 '403': *24 '404': *16 @@ -74394,9 +74454,9 @@ paths: parameters: - *153 responses: - '202': *142 + '202': *143 '304': *27 - '500': *152 + '500': *131 '401': *23 '403': *24 '404': *16 @@ -74473,7 +74533,7 @@ paths: sha: fd95a81ca01e48ede9f39c799ecbcef817b8a3b2 id: latest export_url: https://api.github.com/user/codespaces/:name/exports/latest - '500': *152 + '500': *131 '401': *23 '403': *24 '404': *16 @@ -74554,7 +74614,7 @@ paths: examples: default: *454 '304': *27 - '500': *152 + '500': *131 '401': *23 '403': *24 '404': *16 @@ -74589,7 +74649,7 @@ paths: examples: default: *286 '304': *27 - '500': *152 + '500': *131 '400': *9 '401': *23 '402': @@ -74630,7 +74690,7 @@ paths: schema: *154 examples: default: *286 - '500': *152 + '500': *131 '401': *23 '403': *24 '404': *16 @@ -74924,7 +74984,7 @@ paths: type: array items: *19 examples: - default: *151 + default: *152 headers: Link: *28 '304': *27 @@ -74957,7 +75017,7 @@ paths: type: array items: *19 examples: - default: *151 + default: *152 headers: Link: *28 '304': *27 @@ -75637,12 +75697,12 @@ paths: application/json: schema: anyOf: - - *144 + - *145 - type: object properties: {} additionalProperties: false examples: - default: *145 + default: *146 '204': description: Response when there are no restrictions x-github: @@ -75672,7 +75732,7 @@ paths: description: Response content: application/json: - schema: *144 + schema: *145 examples: default: value: @@ -75748,7 +75808,7 @@ paths: - closed - all default: open - - *149 + - *150 - name: sort description: What to sort results by. in: query @@ -75773,7 +75833,7 @@ paths: type: array items: *81 examples: - default: *150 + default: *151 headers: Link: *28 '404': *16 @@ -78235,7 +78295,7 @@ paths: description: API method documentation url: https://docs.github.com/rest/collaborators/invitations#accept-a-repository-invitation parameters: - - *148 + - *149 responses: '204': description: Response @@ -78258,7 +78318,7 @@ paths: description: API method documentation url: https://docs.github.com/rest/collaborators/invitations#decline-a-repository-invitation parameters: - - *148 + - *149 responses: '204': description: Response @@ -78852,7 +78912,7 @@ paths: type: array items: *19 examples: - default: *151 + default: *152 headers: Link: example: ; rel="next" @@ -79241,7 +79301,7 @@ paths: type: array items: *19 examples: - default: *151 + default: *152 headers: Link: *28 x-github: @@ -79272,7 +79332,7 @@ paths: type: array items: *19 examples: - default: *151 + default: *152 headers: Link: *28 x-github: diff --git a/descriptions/ghec/dereferenced/ghec.deref.json b/descriptions/ghec/dereferenced/ghec.deref.json index 00e59c2530..107bafb3aa 100644 --- a/descriptions/ghec/dereferenced/ghec.deref.json +++ b/descriptions/ghec/dereferenced/ghec.deref.json @@ -73357,6 +73357,212 @@ } } }, + "/orgs/{org}/codespaces/billing": { + "put": { + "summary": "Set the visibility of organization codespaces", + "description": "Sets which users can access codespaces in an organization. This is synonymous with granting or revoking codespaces billing permissions for users according to the visibility.\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.", + "tags": [ + "codespaces" + ], + "operationId": "codespaces/set-codespaces-billing", + "externalDocs": { + "description": "API method documentation", + "url": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#set-codespaces-billing" + }, + "parameters": [ + { + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "path", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "visibility": { + "type": "string", + "description": "Which users can access codespaces in the organization. `disabled` means that no users can access codespaces in the organization.", + "enum": [ + "disabled", + "selected_members", + "all_members", + "all_members_and_outside_collaborators" + ] + }, + "selected_usernames": { + "type": "array", + "description": "The usernames of the organization members who should be granted access to codespaces in the organization. Required when `visibility` is `selected_members`.", + "items": { + "type": "string" + } + } + }, + "required": [ + "visibility" + ] + }, + "examples": { + "default": { + "value": { + "visibility": "selected_members", + "selected_usernames": [ + "johnDoe", + "atomIO" + ] + } + } + } + } + } + }, + "responses": { + "204": { + "description": "Response when successfully modifying permissions." + }, + "304": { + "description": "Not modified" + }, + "400": { + "description": "Users are neither members nor collaborators of this organization." + }, + "404": { + "description": "Resource not found", + "content": { + "application/json": { + "schema": { + "title": "Basic Error", + "description": "Basic Error", + "type": "object", + "properties": { + "message": { + "type": "string" + }, + "documentation_url": { + "type": "string" + }, + "url": { + "type": "string" + }, + "status": { + "type": "string" + } + } + } + } + } + }, + "422": { + "description": "Validation failed, or the endpoint has been spammed.", + "content": { + "application/json": { + "schema": { + "title": "Validation Error", + "description": "Validation Error", + "type": "object", + "required": [ + "message", + "documentation_url" + ], + "properties": { + "message": { + "type": "string" + }, + "documentation_url": { + "type": "string" + }, + "errors": { + "type": "array", + "items": { + "type": "object", + "required": [ + "code" + ], + "properties": { + "resource": { + "type": "string" + }, + "field": { + "type": "string" + }, + "message": { + "type": "string" + }, + "code": { + "type": "string" + }, + "index": { + "type": "integer" + }, + "value": { + "oneOf": [ + { + "type": "string", + "nullable": true + }, + { + "type": "integer", + "nullable": true + }, + { + "type": "array", + "nullable": true, + "items": { + "type": "string" + } + } + ] + } + } + } + } + } + } + } + } + }, + "500": { + "description": "Internal Error", + "content": { + "application/json": { + "schema": { + "title": "Basic Error", + "description": "Basic Error", + "type": "object", + "properties": { + "message": { + "type": "string" + }, + "documentation_url": { + "type": "string" + }, + "url": { + "type": "string" + }, + "status": { + "type": "string" + } + } + } + } + } + } + }, + "x-github": { + "githubCloudOnly": false, + "enabledForGitHubApps": false, + "category": "codespaces", + "subcategory": "organizations" + } + } + }, "/orgs/{org}/credential-authorizations": { "get": { "summary": "List SAML SSO authorizations for an organization", diff --git a/descriptions/ghec/dereferenced/ghec.deref.yaml b/descriptions/ghec/dereferenced/ghec.deref.yaml index e59e70144b..3ee7f6ddbf 100644 --- a/descriptions/ghec/dereferenced/ghec.deref.yaml +++ b/descriptions/ghec/dereferenced/ghec.deref.yaml @@ -823,7 +823,7 @@ paths: schema: type: integer default: 30 - - &146 + - &147 name: cursor description: 'Used for pagination: the starting delivery from which the page of deliveries is fetched. Refer to the `link` header for the next and previous @@ -839,7 +839,7 @@ paths: application/json: schema: type: array - items: &147 + items: &148 title: Simple webhook delivery description: Delivery made by a webhook, without request and response information. @@ -910,7 +910,7 @@ paths: - installation_id - repository_id examples: - default: &148 + default: &149 value: - id: 12345678 guid: 0b989ba4-242f-11e5-81e1-c7b6966d2516 @@ -1036,7 +1036,7 @@ paths: description: Response content: application/json: - schema: &149 + schema: &150 title: Webhook delivery description: Delivery made by a webhook. type: object @@ -1144,7 +1144,7 @@ paths: - request - response examples: - default: &150 + default: &151 value: id: 12345678 guid: 0b989ba4-242f-11e5-81e1-c7b6966d2516 @@ -1203,7 +1203,7 @@ paths: parameters: - *11 responses: - '202': &151 + '202': &152 description: Accepted content: application/json: @@ -12304,7 +12304,7 @@ paths: - closed - all default: open - - &158 + - &159 name: labels description: 'A list of comma separated label names. Example: `bug,ui,@high`' in: query @@ -12355,7 +12355,7 @@ paths: type: array items: *81 examples: - default: &159 + default: &160 value: - id: 1 node_id: MDU6SXNzdWUx @@ -14720,7 +14720,7 @@ paths: type: integer custom_roles: type: array - items: &140 + items: &141 title: Organization Custom Repository Role description: Custom repository roles created by organization administrators @@ -18549,7 +18549,7 @@ paths: type: array items: *19 examples: - default: &160 + default: &161 value: - login: octocat id: 1 @@ -19421,7 +19421,7 @@ paths: stop_url: https://api.github.com/user/codespaces/monalisa-octocat-hello-world-f8adfad99a/stop recent_folders: [] '304': *27 - '500': &161 + '500': &140 description: Internal Error content: application/json: @@ -19434,6 +19434,66 @@ paths: enabledForGitHubApps: false category: codespaces subcategory: organizations + "/orgs/{org}/codespaces/billing": + put: + summary: Set the visibility of organization codespaces + description: |- + Sets which users can access codespaces in an organization. This is synonymous with granting or revoking codespaces billing permissions for users according to the visibility. + You must authenticate using an access token with the `admin:org` scope to use this endpoint. + tags: + - codespaces + operationId: codespaces/set-codespaces-billing + externalDocs: + description: API method documentation + url: https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#set-codespaces-billing + parameters: + - *100 + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + visibility: + type: string + description: Which users can access codespaces in the organization. + `disabled` means that no users can access codespaces in the organization. + enum: + - disabled + - selected_members + - all_members + - all_members_and_outside_collaborators + selected_usernames: + type: array + description: The usernames of the organization members who should + be granted access to codespaces in the organization. Required + when `visibility` is `selected_members`. + items: + type: string + required: + - visibility + examples: + default: + value: + visibility: selected_members + selected_usernames: + - johnDoe + - atomIO + responses: + '204': + description: Response when successfully modifying permissions. + '304': *27 + '400': + description: Users are neither members nor collaborators of this organization. + '404': *16 + '422': *10 + '500': *140 + x-github: + githubCloudOnly: false + enabledForGitHubApps: false + category: codespaces + subcategory: organizations "/orgs/{org}/credential-authorizations": get: summary: List SAML SSO authorizations for an organization @@ -19662,7 +19722,7 @@ paths: description: Response content: application/json: - schema: *140 + schema: *141 examples: default: value: @@ -19720,7 +19780,7 @@ paths: url: https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#update-a-custom-role parameters: - *100 - - &141 + - &142 name: role_id description: The unique identifier of the role. in: path @@ -19770,7 +19830,7 @@ paths: description: Response content: application/json: - schema: *140 + schema: *141 examples: default: value: @@ -19829,7 +19889,7 @@ paths: url: https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#delete-a-custom-role parameters: - *100 - - *141 + - *142 responses: '204': description: Response @@ -19871,7 +19931,7 @@ paths: type: integer secrets: type: array - items: &142 + items: &143 title: Dependabot Secret for an Organization description: Secrets for GitHub Dependabot for an organization. type: object @@ -19995,7 +20055,7 @@ paths: description: Response content: application/json: - schema: *142 + schema: *143 examples: default: value: @@ -20660,7 +20720,7 @@ paths: application/json: schema: type: array - items: &155 + items: &156 title: Organization Invitation description: Organization Invitation type: object @@ -20703,7 +20763,7 @@ paths: - invitation_teams_url - node_id examples: - default: &156 + default: &157 value: - id: 1 login: monalisa @@ -20815,7 +20875,7 @@ paths: application/json: schema: type: array - items: &143 + items: &144 title: Org Hook description: Org Hook type: object @@ -20981,9 +21041,9 @@ paths: description: Response content: application/json: - schema: *143 + schema: *144 examples: - default: &144 + default: &145 value: id: 1 url: https://api.github.com/orgs/octocat/hooks/1 @@ -21025,7 +21085,7 @@ paths: url: https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#get-an-organization-webhook parameters: - *100 - - &145 + - &146 name: hook_id description: The unique identifier of the hook. in: path @@ -21037,9 +21097,9 @@ paths: description: Response content: application/json: - schema: *143 + schema: *144 examples: - default: *144 + default: *145 '404': *16 x-github: githubCloudOnly: false @@ -21061,7 +21121,7 @@ paths: url: https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#update-an-organization-webhook parameters: - *100 - - *145 + - *146 requestBody: required: false content: @@ -21107,7 +21167,7 @@ paths: description: Response content: application/json: - schema: *143 + schema: *144 examples: default: value: @@ -21143,7 +21203,7 @@ paths: url: https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#delete-an-organization-webhook parameters: - *100 - - *145 + - *146 responses: '204': description: Response @@ -21168,7 +21228,7 @@ paths: url: https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#get-a-webhook-configuration-for-an-organization parameters: - *100 - - *145 + - *146 responses: '200': description: Response @@ -21196,7 +21256,7 @@ paths: url: https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#update-a-webhook-configuration-for-an-organization parameters: - *100 - - *145 + - *146 requestBody: required: false content: @@ -21242,9 +21302,9 @@ paths: url: https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-deliveries-for-an-organization-webhook parameters: - *100 - - *145 - - *12 - *146 + - *12 + - *147 responses: '200': description: Response @@ -21252,9 +21312,9 @@ paths: application/json: schema: type: array - items: *147 + items: *148 examples: - default: *148 + default: *149 '400': *9 '422': *10 x-github: @@ -21274,16 +21334,16 @@ paths: url: https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#get-a-webhook-delivery-for-an-organization-webhook parameters: - *100 - - *145 + - *146 - *11 responses: '200': description: Response content: application/json: - schema: *149 + schema: *150 examples: - default: *150 + default: *151 '400': *9 '422': *10 x-github: @@ -21303,10 +21363,10 @@ paths: url: https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#redeliver-a-delivery-for-an-organization-webhook parameters: - *100 - - *145 + - *146 - *11 responses: - '202': *151 + '202': *152 '400': *9 '422': *10 x-github: @@ -21327,7 +21387,7 @@ paths: url: https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#ping-an-organization-webhook parameters: - *100 - - *145 + - *146 responses: '204': description: Response @@ -21520,12 +21580,12 @@ paths: application/json: schema: anyOf: - - &153 + - &154 title: Interaction Limits description: Interaction limit settings. type: object properties: - limit: &152 + limit: &153 type: string description: The type of GitHub user that can comment, open issues, or create pull requests while the interaction limit @@ -21550,7 +21610,7 @@ paths: properties: {} additionalProperties: false examples: - default: &154 + default: &155 value: limit: collaborators_only origin: organization @@ -21585,7 +21645,7 @@ paths: duration type: object properties: - limit: *152 + limit: *153 expiry: type: string description: 'The duration of the interaction restriction. Default: @@ -21604,9 +21664,9 @@ paths: description: Response content: application/json: - schema: *153 + schema: *154 examples: - default: *154 + default: *155 '422': *10 x-github: githubCloudOnly: false @@ -21658,9 +21718,9 @@ paths: application/json: schema: type: array - items: *155 + items: *156 examples: - default: *156 + default: *157 headers: Link: *28 '404': *16 @@ -21732,7 +21792,7 @@ paths: description: Response content: application/json: - schema: *155 + schema: *156 examples: default: value: @@ -21786,7 +21846,7 @@ paths: url: https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#cancel-an-organization-invitation parameters: - *100 - - &157 + - &158 name: invitation_id description: The unique identifier of the invitation. in: path @@ -21817,7 +21877,7 @@ paths: url: https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-organization-invitation-teams parameters: - *100 - - *157 + - *158 - *12 - *32 responses: @@ -22028,7 +22088,7 @@ paths: - closed - all default: open - - *158 + - *159 - name: sort description: What to sort results by. in: query @@ -22053,7 +22113,7 @@ paths: type: array items: *81 examples: - default: *159 + default: *160 headers: Link: *28 '404': *16 @@ -22111,7 +22171,7 @@ paths: type: array items: *19 examples: - default: *160 + default: *161 headers: Link: *28 '422': *10 @@ -22198,9 +22258,9 @@ paths: schema: type: string responses: - '202': *151 + '202': *152 '304': *27 - '500': *161 + '500': *140 '401': *23 '403': *24 '404': *16 @@ -22375,7 +22435,7 @@ paths: recent_folders: [] template: '304': *27 - '500': *161 + '500': *140 '401': *23 '403': *24 '404': *16 @@ -23548,7 +23608,7 @@ paths: type: array items: *19 examples: - default: *160 + default: *161 headers: Link: *28 x-github: @@ -24539,7 +24599,7 @@ paths: type: array items: *19 examples: - default: *160 + default: *161 headers: Link: *28 x-github: @@ -27329,9 +27389,9 @@ paths: application/json: schema: type: array - items: *155 + items: *156 examples: - default: *156 + default: *157 headers: Link: *28 x-github: @@ -27377,7 +27437,7 @@ paths: type: array items: *19 examples: - default: *160 + default: *161 headers: Link: *28 x-github: @@ -29822,7 +29882,7 @@ paths: type: array items: *19 examples: - default: *160 + default: *161 headers: Link: *28 '404': *16 @@ -35026,7 +35086,7 @@ paths: '204': description: Response '403': *24 - '500': *161 + '500': *140 x-github: githubCloudOnly: false enabledForGitHubApps: true @@ -36313,7 +36373,7 @@ paths: type: array items: *19 examples: - default: *160 + default: *161 headers: Link: *28 '404': *16 @@ -39530,7 +39590,7 @@ paths: type: array items: *19 examples: - default: *160 + default: *161 '404': *16 x-github: githubCloudOnly: false @@ -39593,7 +39653,7 @@ paths: type: array items: *19 examples: - default: *160 + default: *161 '422': *10 x-github: githubCloudOnly: false @@ -39657,7 +39717,7 @@ paths: type: array items: *19 examples: - default: *160 + default: *161 '422': *10 x-github: githubCloudOnly: false @@ -39720,7 +39780,7 @@ paths: type: array items: *19 examples: - default: *160 + default: *161 '422': *10 x-github: githubCloudOnly: false @@ -43859,7 +43919,7 @@ paths: start_url: https://api.github.com/user/codespaces/monalisa-octocat-hello-world-3f89ada1j3/start stop_url: https://api.github.com/user/codespaces/monalisa-octocat-hello-world-3f89ada1j3/stop recent_folders: [] - '500': *161 + '500': *140 '401': *23 '403': *24 '404': *16 @@ -44012,7 +44072,7 @@ paths: name: kitchensink - path: ".devcontainer.json" total_count: 3 - '500': *161 + '500': *140 '400': *9 '401': *23 '403': *24 @@ -44091,7 +44151,7 @@ paths: memory_in_bytes: 17179869184 cpus: 8 '304': *27 - '500': *161 + '500': *140 '401': *23 '403': *24 '404': *16 @@ -45575,7 +45635,7 @@ paths: sha: 6dcb09b5b57875f334f61aebed695e2e4193db5e headers: Link: *28 - '500': *161 + '500': *140 '400': *9 '404': *16 '409': *251 @@ -46700,7 +46760,7 @@ paths: ..... '422': *10 '404': *16 - '500': *161 + '500': *140 '503': *63 x-github: githubCloudOnly: false @@ -47855,7 +47915,7 @@ paths: patch: "@@ -132,7 +132,7 @@ module Test @@ -1000,7 +1000,7 @@ module Test" '404': *16 - '500': *161 + '500': *140 '503': *63 x-github: githubCloudOnly: false @@ -53867,7 +53927,7 @@ paths: parameters: - *215 - *216 - - *145 + - *146 responses: '200': description: Response @@ -53897,7 +53957,7 @@ paths: parameters: - *215 - *216 - - *145 + - *146 requestBody: required: true content: @@ -53980,7 +54040,7 @@ paths: parameters: - *215 - *216 - - *145 + - *146 responses: '204': description: Response @@ -54006,7 +54066,7 @@ paths: parameters: - *215 - *216 - - *145 + - *146 responses: '200': description: Response @@ -54035,7 +54095,7 @@ paths: parameters: - *215 - *216 - - *145 + - *146 requestBody: required: false content: @@ -54080,9 +54140,9 @@ paths: parameters: - *215 - *216 - - *145 - - *12 - *146 + - *12 + - *147 responses: '200': description: Response @@ -54090,9 +54150,9 @@ paths: application/json: schema: type: array - items: *147 + items: *148 examples: - default: *148 + default: *149 '400': *9 '422': *10 x-github: @@ -54113,16 +54173,16 @@ paths: parameters: - *215 - *216 - - *145 + - *146 - *11 responses: '200': description: Response content: application/json: - schema: *149 + schema: *150 examples: - default: *150 + default: *151 '400': *9 '422': *10 x-github: @@ -54143,10 +54203,10 @@ paths: parameters: - *215 - *216 - - *145 + - *146 - *11 responses: - '202': *151 + '202': *152 '400': *9 '422': *10 x-github: @@ -54168,7 +54228,7 @@ paths: parameters: - *215 - *216 - - *145 + - *146 responses: '204': description: Response @@ -54194,7 +54254,7 @@ paths: parameters: - *215 - *216 - - *145 + - *146 responses: '204': description: Response @@ -54917,7 +54977,7 @@ paths: application/json: schema: anyOf: - - *153 + - *154 - type: object properties: {} additionalProperties: false @@ -54965,7 +55025,7 @@ paths: description: Response content: application/json: - schema: *153 + schema: *154 examples: default: *376 '409': @@ -55159,7 +55219,7 @@ paths: parameters: - *215 - *216 - - *157 + - *158 requestBody: required: false content: @@ -55321,7 +55381,7 @@ paths: parameters: - *215 - *216 - - *157 + - *158 responses: '204': description: Response @@ -55388,7 +55448,7 @@ paths: required: false schema: type: string - - *158 + - *159 - name: sort description: What to sort results by. in: query @@ -59820,7 +59880,7 @@ paths: - *215 - *216 responses: - '202': *151 + '202': *152 '403': description: |- We will return a 403 with one of the following messages: @@ -63926,7 +63986,7 @@ paths: default: *424 '304': *27 '404': *16 - '500': *161 + '500': *140 '503': *63 x-github: githubCloudOnly: false @@ -64493,7 +64553,7 @@ paths: headers: Link: *28 '422': *10 - '500': *161 + '500': *140 '503': *63 x-github: githubCloudOnly: false @@ -68564,7 +68624,7 @@ paths: - - 1302998400 - 1124 - -435 - '202': *151 + '202': *152 '204': &445 description: A header with no content is returned. x-github: @@ -68633,7 +68693,7 @@ paths: - 0 total: 89 week: 1336280400 - '202': *151 + '202': *152 '204': *445 x-github: githubCloudOnly: false @@ -68732,7 +68792,7 @@ paths: a: 6898 d: 77 c: 10 - '202': *151 + '202': *152 '204': *445 x-github: githubCloudOnly: false @@ -69074,7 +69134,7 @@ paths: type: array items: *19 examples: - default: *160 + default: *161 headers: Link: *28 x-github: @@ -74415,9 +74475,9 @@ paths: application/json: schema: type: array - items: *155 + items: *156 examples: - default: *156 + default: *157 headers: Link: *28 x-github: @@ -74465,7 +74525,7 @@ paths: type: array items: *19 examples: - default: *160 + default: *161 headers: Link: *28 '404': *16 @@ -75882,7 +75942,7 @@ paths: type: array items: *19 examples: - default: *160 + default: *161 '304': *27 '404': *16 '403': *24 @@ -76009,7 +76069,7 @@ paths: examples: default: *478 '304': *27 - '500': *161 + '500': *140 '401': *23 '403': *24 '404': *16 @@ -76514,7 +76574,7 @@ paths: '401': *23 '403': *24 '404': *16 - '500': *161 + '500': *140 x-github: githubCloudOnly: false enabledForGitHubApps: false @@ -76567,7 +76627,7 @@ paths: '401': *23 '403': *24 '404': *16 - '500': *161 + '500': *140 x-github: githubCloudOnly: false enabledForGitHubApps: false @@ -76599,7 +76659,7 @@ paths: '401': *23 '403': *24 '404': *16 - '500': *161 + '500': *140 x-github: githubCloudOnly: false enabledForGitHubApps: false @@ -76630,7 +76690,7 @@ paths: '401': *23 '403': *24 '404': *16 - '500': *161 + '500': *140 x-github: githubCloudOnly: false enabledForGitHubApps: false @@ -76662,7 +76722,7 @@ paths: examples: default: *309 '304': *27 - '500': *161 + '500': *140 '401': *23 '403': *24 '404': *16 @@ -76746,9 +76806,9 @@ paths: parameters: - *162 responses: - '202': *151 + '202': *152 '304': *27 - '500': *161 + '500': *140 '401': *23 '403': *24 '404': *16 @@ -76825,7 +76885,7 @@ paths: sha: fd95a81ca01e48ede9f39c799ecbcef817b8a3b2 id: latest export_url: https://api.github.com/user/codespaces/:name/exports/latest - '500': *161 + '500': *140 '401': *23 '403': *24 '404': *16 @@ -76906,7 +76966,7 @@ paths: examples: default: *484 '304': *27 - '500': *161 + '500': *140 '401': *23 '403': *24 '404': *16 @@ -76941,7 +77001,7 @@ paths: examples: default: *309 '304': *27 - '500': *161 + '500': *140 '400': *9 '401': *23 '402': @@ -76982,7 +77042,7 @@ paths: schema: *163 examples: default: *309 - '500': *161 + '500': *140 '401': *23 '403': *24 '404': *16 @@ -77276,7 +77336,7 @@ paths: type: array items: *19 examples: - default: *160 + default: *161 headers: Link: *28 '304': *27 @@ -77309,7 +77369,7 @@ paths: type: array items: *19 examples: - default: *160 + default: *161 headers: Link: *28 '304': *27 @@ -77989,12 +78049,12 @@ paths: application/json: schema: anyOf: - - *153 + - *154 - type: object properties: {} additionalProperties: false examples: - default: *154 + default: *155 '204': description: Response when there are no restrictions x-github: @@ -78024,7 +78084,7 @@ paths: description: Response content: application/json: - schema: *153 + schema: *154 examples: default: value: @@ -78100,7 +78160,7 @@ paths: - closed - all default: open - - *158 + - *159 - name: sort description: What to sort results by. in: query @@ -78125,7 +78185,7 @@ paths: type: array items: *81 examples: - default: *159 + default: *160 headers: Link: *28 '404': *16 @@ -80587,7 +80647,7 @@ paths: description: API method documentation url: https://docs.github.com/enterprise-cloud@latest//rest/collaborators/invitations#accept-a-repository-invitation parameters: - - *157 + - *158 responses: '204': description: Response @@ -80610,7 +80670,7 @@ paths: description: API method documentation url: https://docs.github.com/enterprise-cloud@latest//rest/collaborators/invitations#decline-a-repository-invitation parameters: - - *157 + - *158 responses: '204': description: Response @@ -81204,7 +81264,7 @@ paths: type: array items: *19 examples: - default: *160 + default: *161 headers: Link: example: ; rel="next" @@ -81593,7 +81653,7 @@ paths: type: array items: *19 examples: - default: *160 + default: *161 headers: Link: *28 x-github: @@ -81624,7 +81684,7 @@ paths: type: array items: *19 examples: - default: *160 + default: *161 headers: Link: *28 x-github: diff --git a/descriptions/ghec/ghec.json b/descriptions/ghec/ghec.json index a9a7e6f572..215014e438 100644 --- a/descriptions/ghec/ghec.json +++ b/descriptions/ghec/ghec.json @@ -10573,6 +10573,94 @@ } } }, + "/orgs/{org}/codespaces/billing": { + "put": { + "summary": "Set the visibility of organization codespaces", + "description": "Sets which users can access codespaces in an organization. This is synonymous with granting or revoking codespaces billing permissions for users according to the visibility.\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.", + "tags": [ + "codespaces" + ], + "operationId": "codespaces/set-codespaces-billing", + "externalDocs": { + "description": "API method documentation", + "url": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#set-codespaces-billing" + }, + "parameters": [ + { + "$ref": "#/components/parameters/org" + } + ], + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "visibility": { + "type": "string", + "description": "Which users can access codespaces in the organization. `disabled` means that no users can access codespaces in the organization.", + "enum": [ + "disabled", + "selected_members", + "all_members", + "all_members_and_outside_collaborators" + ] + }, + "selected_usernames": { + "type": "array", + "description": "The usernames of the organization members who should be granted access to codespaces in the organization. Required when `visibility` is `selected_members`.", + "items": { + "type": "string" + } + } + }, + "required": [ + "visibility" + ] + }, + "examples": { + "default": { + "value": { + "visibility": "selected_members", + "selected_usernames": [ + "johnDoe", + "atomIO" + ] + } + } + } + } + } + }, + "responses": { + "204": { + "description": "Response when successfully modifying permissions." + }, + "304": { + "$ref": "#/components/responses/not_modified" + }, + "400": { + "description": "Users are neither members nor collaborators of this organization." + }, + "404": { + "$ref": "#/components/responses/not_found" + }, + "422": { + "$ref": "#/components/responses/validation_failed" + }, + "500": { + "$ref": "#/components/responses/internal_error" + } + }, + "x-github": { + "githubCloudOnly": false, + "enabledForGitHubApps": false, + "category": "codespaces", + "subcategory": "organizations" + } + } + }, "/orgs/{org}/credential-authorizations": { "get": { "summary": "List SAML SSO authorizations for an organization", diff --git a/descriptions/ghec/ghec.yaml b/descriptions/ghec/ghec.yaml index 50d980e239..42a338ee0a 100644 --- a/descriptions/ghec/ghec.yaml +++ b/descriptions/ghec/ghec.yaml @@ -7647,6 +7647,70 @@ paths: enabledForGitHubApps: false category: codespaces subcategory: organizations + "/orgs/{org}/codespaces/billing": + put: + summary: Set the visibility of organization codespaces + description: |- + Sets which users can access codespaces in an organization. This is synonymous with granting or revoking codespaces billing permissions for users according to the visibility. + You must authenticate using an access token with the `admin:org` scope to use this endpoint. + tags: + - codespaces + operationId: codespaces/set-codespaces-billing + externalDocs: + description: API method documentation + url: https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#set-codespaces-billing + parameters: + - "$ref": "#/components/parameters/org" + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + visibility: + type: string + description: Which users can access codespaces in the organization. + `disabled` means that no users can access codespaces in the organization. + enum: + - disabled + - selected_members + - all_members + - all_members_and_outside_collaborators + selected_usernames: + type: array + description: The usernames of the organization members who should + be granted access to codespaces in the organization. Required + when `visibility` is `selected_members`. + items: + type: string + required: + - visibility + examples: + default: + value: + visibility: selected_members + selected_usernames: + - johnDoe + - atomIO + responses: + '204': + description: Response when successfully modifying permissions. + '304': + "$ref": "#/components/responses/not_modified" + '400': + description: Users are neither members nor collaborators of this organization. + '404': + "$ref": "#/components/responses/not_found" + '422': + "$ref": "#/components/responses/validation_failed" + '500': + "$ref": "#/components/responses/internal_error" + x-github: + githubCloudOnly: false + enabledForGitHubApps: false + category: codespaces + subcategory: organizations "/orgs/{org}/credential-authorizations": get: summary: List SAML SSO authorizations for an organization