Search + K

Command Palette

Search for a command to run...

Sign In

Manage access control for organization codespaces

Deprecated
PUT /orgs/{org}/codespaces/access
Copy endpoint
https://api.github.com

Sets which users can access codespaces in an organization. This is synonymous with granting or revoking codespaces access permissions for users according to the visibility. OAuth app tokens and personal access tokens (classic) need the admin:org scope to use this endpoint.

Parameters

path Path Parameters

Name Type
org required

The organization name. The name is not case sensitive.

string

Request Body

application/json required
{ visibility: "disabled" | "selected_members" | "all_members" | "all_members_and_outside_collaborators";selected_usernames?: string[]; }

Responses

204

Response when successfully modifying permissions.

unknown

Redirects

304

Not modified

unknown

Client Errors

400

Users are neither members nor collaborators of this organization.

unknown
404 application/json

Resource not found

interface BasicError {
message?: string;
documentation_url?: string;
url?: string;
status?: string;
}
422 application/json

Validation failed, or the endpoint has been spammed.

interface ValidationError {
message: string;
documentation_url: string;
errors?: {
resource?: string;
field?: string;
message?: string;
code: string;
index?: number;
value?: string[] | string | number | null;
}
[]
;
}

Server Errors

500 application/json

Internal Error

interface BasicError {
message?: string;
documentation_url?: string;
url?: string;
status?: string;
}