Files
jetbrains-client-api-reposi…/apis/github/Apis/OrgsApi.http
Julien Lengrand-Lambert 11f40e54fa First test with API repository
2024-03-06 12:35:34 +01:00

601 lines
19 KiB
HTTP

## OrgsApi
### Add a security manager team
## Add a security manager team
PUT https://api.github.com/orgs/{{org}}/security-managers/teams/{{team_slug}}
Authorization: Bearer={{bearerToken}}
### Assign an organization role to a team
## Assign an organization role to a team
PUT https://api.github.com/orgs/{{org}}/organization-roles/teams/{{team_slug}}/{{role_id}}
Authorization: Bearer={{bearerToken}}
### Assign an organization role to a user
## Assign an organization role to a user
PUT https://api.github.com/orgs/{{org}}/organization-roles/users/{{username}}/{{role_id}}
Authorization: Bearer={{bearerToken}}
### Block a user from an organization
## Block a user from an organization
PUT https://api.github.com/orgs/{{org}}/blocks/{{username}}
Accept: application/json
Authorization: Bearer={{bearerToken}}
### Cancel an organization invitation
## Cancel an organization invitation
DELETE https://api.github.com/orgs/{{org}}/invitations/{{invitation_id}}
Accept: application/json
Authorization: Bearer={{bearerToken}}
### Check if a user is blocked by an organization
## Check if a user is blocked by an organization
GET https://api.github.com/orgs/{{org}}/blocks/{{username}}
Accept: application/json
Authorization: Bearer={{bearerToken}}
### Check organization membership for a user
## Check organization membership for a user
GET https://api.github.com/orgs/{{org}}/members/{{username}}
Authorization: Bearer={{bearerToken}}
### Check public organization membership for a user
## Check public organization membership for a user
GET https://api.github.com/orgs/{{org}}/public_members/{{username}}
Authorization: Bearer={{bearerToken}}
### Convert an organization member to outside collaborator
## Convert an organization member to outside collaborator
PUT https://api.github.com/orgs/{{org}}/outside_collaborators/{{username}}
Content-Type: application/json
Accept: application/json
Authorization: Bearer={{bearerToken}}
{
"async" : true
}
### Create a custom organization role
## Create a custom organization role
POST https://api.github.com/orgs/{{org}}/organization-roles
Content-Type: application/json
Accept: application/json
Authorization: Bearer={{bearerToken}}
{
"name" : "Custom Role Manager",
"description" : "Permissions to manage custom roles within an org",
"permissions" : [ "write_organization_custom_repo_role", "write_organization_custom_org_role", "read_organization_custom_repo_role", "read_organization_custom_org_role" ]
}
### Create an organization invitation
## Create an organization invitation
POST https://api.github.com/orgs/{{org}}/invitations
Content-Type: application/json
Accept: application/json
Authorization: Bearer={{bearerToken}}
{
"email" : "octocat@github.com",
"role" : "direct_member",
"team_ids" : [ 12, 26 ]
}
### Create or update custom properties for an organization
## Create or update custom properties for an organization
PATCH https://api.github.com/orgs/{{org}}/properties/schema
Content-Type: application/json
Accept: application/json
Authorization: Bearer={{bearerToken}}
{
"properties" : [ {
"property_name" : "environment",
"value_type" : "single_select",
"required" : true,
"default_value" : "production",
"description" : "Prod or dev environment",
"allowed_values" : [ "production", "development" ],
"values_editable_by" : "org_actors"
}, {
"property_name" : "service",
"value_type" : "string"
}, {
"property_name" : "team",
"value_type" : "string",
"description" : "Team owning the repository"
} ]
}
### Create or update custom property values for organization repositories
##
PATCH https://api.github.com/orgs/{{org}}/properties/values
Content-Type: application/json
Accept: application/json
Authorization: Bearer={{bearerToken}}
{
"repository_names" : [ "Hello-World", "octo-repo" ],
"properties" : [ {
"property_name" : "environment",
"value" : "production"
}, {
"property_name" : "service",
"value" : "web"
}, {
"property_name" : "team",
"value" : "octocat"
} ]
}
### Create or update a custom property for an organization
## Create or update a custom property for an organization
PUT https://api.github.com/orgs/{{org}}/properties/schema/{{custom_property_name}}
Content-Type: application/json
Accept: application/json
Authorization: Bearer={{bearerToken}}
{
"value_type" : "single_select",
"required" : true,
"default_value" : "production",
"description" : "Prod or dev environment",
"allowed_values" : [ "production", "development" ]
}
### Create an organization webhook
## Create an organization webhook
POST https://api.github.com/orgs/{{org}}/hooks
Content-Type: application/json
Accept: application/json
Authorization: Bearer={{bearerToken}}
{
"name" : "web",
"active" : true,
"events" : [ "push", "pull_request" ],
"config" : {
"url" : "http://example.com/webhook",
"content_type" : "json"
}
}
### Delete an organization
## Delete an organization
DELETE https://api.github.com/orgs/{{org}}
Accept: application/json
Authorization: Bearer={{bearerToken}}
### Delete a custom organization role.
## Delete a custom organization role.
DELETE https://api.github.com/orgs/{{org}}/organization-roles/{{role_id}}
Authorization: Bearer={{bearerToken}}
### Delete an organization webhook
## Delete an organization webhook
DELETE https://api.github.com/orgs/{{org}}/hooks/{{hook_id}}
Accept: application/json
Authorization: Bearer={{bearerToken}}
### Get an organization
## Get an organization
GET https://api.github.com/orgs/{{org}}
Accept: application/json
Authorization: Bearer={{bearerToken}}
### Get all custom properties for an organization
## Get all custom properties for an organization
GET https://api.github.com/orgs/{{org}}/properties/schema
Accept: application/json
Authorization: Bearer={{bearerToken}}
### Get a custom property for an organization
## Get a custom property for an organization
GET https://api.github.com/orgs/{{org}}/properties/schema/{{custom_property_name}}
Accept: application/json
Authorization: Bearer={{bearerToken}}
### Get an organization membership for the authenticated user
## Get an organization membership for the authenticated user
GET https://api.github.com/user/memberships/orgs/{{org}}
Accept: application/json
Authorization: Bearer={{bearerToken}}
### Get organization membership for a user
## Get organization membership for a user
GET https://api.github.com/orgs/{{org}}/memberships/{{username}}
Accept: application/json
Authorization: Bearer={{bearerToken}}
### Get an organization role
## Get an organization role
GET https://api.github.com/orgs/{{org}}/organization-roles/{{role_id}}
Accept: application/json
Authorization: Bearer={{bearerToken}}
### Get an organization webhook
## Get an organization webhook
GET https://api.github.com/orgs/{{org}}/hooks/{{hook_id}}
Accept: application/json
Authorization: Bearer={{bearerToken}}
### Get a webhook configuration for an organization
## Get a webhook configuration for an organization
GET https://api.github.com/orgs/{{org}}/hooks/{{hook_id}}/config
Accept: application/json
Authorization: Bearer={{bearerToken}}
### Get a webhook delivery for an organization webhook
## Get a webhook delivery for an organization webhook
GET https://api.github.com/orgs/{{org}}/hooks/{{hook_id}}/deliveries/{{delivery_id}}
Accept: application/json
Accept: application/scim+json
Authorization: Bearer={{bearerToken}}
### List organizations
## List organizations
GET https://api.github.com/organizations
Accept: application/json
Authorization: Bearer={{bearerToken}}
### List app installations for an organization
## List app installations for an organization
GET https://api.github.com/orgs/{{org}}/installations
Accept: application/json
Authorization: Bearer={{bearerToken}}
### List users blocked by an organization
## List users blocked by an organization
GET https://api.github.com/orgs/{{org}}/blocks
Accept: application/json
Authorization: Bearer={{bearerToken}}
### List custom property values for organization repositories
## List custom property values for organization repositories
GET https://api.github.com/orgs/{{org}}/properties/values
Accept: application/json
Authorization: Bearer={{bearerToken}}
### List failed organization invitations
## List failed organization invitations
GET https://api.github.com/orgs/{{org}}/failed_invitations
Accept: application/json
Authorization: Bearer={{bearerToken}}
### List organizations for the authenticated user
## List organizations for the authenticated user
GET https://api.github.com/user/orgs
Accept: application/json
Authorization: Bearer={{bearerToken}}
### List organizations for a user
## List organizations for a user
GET https://api.github.com/users/{{username}}/orgs
Accept: application/json
Authorization: Bearer={{bearerToken}}
### List organization invitation teams
## List organization invitation teams
GET https://api.github.com/orgs/{{org}}/invitations/{{invitation_id}}/teams
Accept: application/json
Authorization: Bearer={{bearerToken}}
### List organization members
## List organization members
GET https://api.github.com/orgs/{{org}}/members
Accept: application/json
Authorization: Bearer={{bearerToken}}
### List organization memberships for the authenticated user
## List organization memberships for the authenticated user
GET https://api.github.com/user/memberships/orgs
Accept: application/json
Authorization: Bearer={{bearerToken}}
### List teams that are assigned to an organization role
## List teams that are assigned to an organization role
GET https://api.github.com/orgs/{{org}}/organization-roles/{{role_id}}/teams
Accept: application/json
Authorization: Bearer={{bearerToken}}
### List users that are assigned to an organization role
## List users that are assigned to an organization role
GET https://api.github.com/orgs/{{org}}/organization-roles/{{role_id}}/users
Accept: application/json
Authorization: Bearer={{bearerToken}}
### Get all organization roles for an organization
## Get all organization roles for an organization
GET https://api.github.com/orgs/{{org}}/organization-roles
Accept: application/json
Authorization: Bearer={{bearerToken}}
### List organization fine-grained permissions for an organization
## List organization fine-grained permissions for an organization
GET https://api.github.com/orgs/{{org}}/organization-fine-grained-permissions
Accept: application/json
Authorization: Bearer={{bearerToken}}
### List outside collaborators for an organization
## List outside collaborators for an organization
GET https://api.github.com/orgs/{{org}}/outside_collaborators
Accept: application/json
Authorization: Bearer={{bearerToken}}
### List repositories a fine-grained personal access token has access to
## List repositories a fine-grained personal access token has access to
GET https://api.github.com/orgs/{{org}}/personal-access-tokens/{{pat_id}}/repositories
Accept: application/json
Authorization: Bearer={{bearerToken}}
### List repositories requested to be accessed by a fine-grained personal access token
## List repositories requested to be accessed by a fine-grained personal access token
GET https://api.github.com/orgs/{{org}}/personal-access-token-requests/{{pat_request_id}}/repositories
Accept: application/json
Authorization: Bearer={{bearerToken}}
### List requests to access organization resources with fine-grained personal access tokens
## List requests to access organization resources with fine-grained personal access tokens
GET https://api.github.com/orgs/{{org}}/personal-access-token-requests
Accept: application/json
Authorization: Bearer={{bearerToken}}
### List fine-grained personal access tokens with access to organization resources
## List fine-grained personal access tokens with access to organization resources
GET https://api.github.com/orgs/{{org}}/personal-access-tokens
Accept: application/json
Authorization: Bearer={{bearerToken}}
### List pending organization invitations
## List pending organization invitations
GET https://api.github.com/orgs/{{org}}/invitations
Accept: application/json
Authorization: Bearer={{bearerToken}}
### List public organization members
## List public organization members
GET https://api.github.com/orgs/{{org}}/public_members
Accept: application/json
Authorization: Bearer={{bearerToken}}
### List security manager teams
## List security manager teams
GET https://api.github.com/orgs/{{org}}/security-managers
Accept: application/json
Authorization: Bearer={{bearerToken}}
### List deliveries for an organization webhook
## List deliveries for an organization webhook
GET https://api.github.com/orgs/{{org}}/hooks/{{hook_id}}/deliveries
Accept: application/json
Accept: application/scim+json
Authorization: Bearer={{bearerToken}}
### List organization webhooks
## List organization webhooks
GET https://api.github.com/orgs/{{org}}/hooks
Accept: application/json
Authorization: Bearer={{bearerToken}}
### Update a custom organization role
## Update a custom organization role
PATCH https://api.github.com/orgs/{{org}}/organization-roles/{{role_id}}
Content-Type: application/json
Accept: application/json
Authorization: Bearer={{bearerToken}}
{
"description" : "Permissions to manage custom roles within an org."
}
### Ping an organization webhook
## Ping an organization webhook
POST https://api.github.com/orgs/{{org}}/hooks/{{hook_id}}/pings
Accept: application/json
Authorization: Bearer={{bearerToken}}
### Redeliver a delivery for an organization webhook
## Redeliver a delivery for an organization webhook
POST https://api.github.com/orgs/{{org}}/hooks/{{hook_id}}/deliveries/{{delivery_id}}/attempts
Accept: application/json
Accept: application/scim+json
Authorization: Bearer={{bearerToken}}
### Remove a custom property for an organization
## Remove a custom property for an organization
DELETE https://api.github.com/orgs/{{org}}/properties/schema/{{custom_property_name}}
Accept: application/json
Authorization: Bearer={{bearerToken}}
### Remove an organization member
## Remove an organization member
DELETE https://api.github.com/orgs/{{org}}/members/{{username}}
Accept: application/json
Authorization: Bearer={{bearerToken}}
### Remove organization membership for a user
## Remove organization membership for a user
DELETE https://api.github.com/orgs/{{org}}/memberships/{{username}}
Accept: application/json
Authorization: Bearer={{bearerToken}}
### Remove outside collaborator from an organization
## Remove outside collaborator from an organization
DELETE https://api.github.com/orgs/{{org}}/outside_collaborators/{{username}}
Accept: application/json
Authorization: Bearer={{bearerToken}}
### Remove public organization membership for the authenticated user
## Remove public organization membership for the authenticated user
DELETE https://api.github.com/orgs/{{org}}/public_members/{{username}}
Authorization: Bearer={{bearerToken}}
### Remove a security manager team
## Remove a security manager team
DELETE https://api.github.com/orgs/{{org}}/security-managers/teams/{{team_slug}}
Authorization: Bearer={{bearerToken}}
### Review a request to access organization resources with a fine-grained personal access token
## Review a request to access organization resources with a fine-grained personal access token
POST https://api.github.com/orgs/{{org}}/personal-access-token-requests/{{pat_request_id}}
Content-Type: application/json
Accept: application/json
Authorization: Bearer={{bearerToken}}
{
"action" : "deny",
"reason" : "This request is denied because the access is too broad."
}
### Review requests to access organization resources with fine-grained personal access tokens
## Review requests to access organization resources with fine-grained personal access tokens
POST https://api.github.com/orgs/{{org}}/personal-access-token-requests
Content-Type: application/json
Accept: application/json
Authorization: Bearer={{bearerToken}}
{
"pat_request_ids" : [ 42, 73 ],
"action" : "deny",
"reason" : "Access is too broad."
}
### Remove all organization roles for a team
## Remove all organization roles for a team
DELETE https://api.github.com/orgs/{{org}}/organization-roles/teams/{{team_slug}}
Authorization: Bearer={{bearerToken}}
### Remove all organization roles for a user
## Remove all organization roles for a user
DELETE https://api.github.com/orgs/{{org}}/organization-roles/users/{{username}}
Authorization: Bearer={{bearerToken}}
### Remove an organization role from a team
## Remove an organization role from a team
DELETE https://api.github.com/orgs/{{org}}/organization-roles/teams/{{team_slug}}/{{role_id}}
Authorization: Bearer={{bearerToken}}
### Remove an organization role from a user
## Remove an organization role from a user
DELETE https://api.github.com/orgs/{{org}}/organization-roles/users/{{username}}/{{role_id}}
Authorization: Bearer={{bearerToken}}
### Set organization membership for a user
## Set organization membership for a user
PUT https://api.github.com/orgs/{{org}}/memberships/{{username}}
Content-Type: application/json
Accept: application/json
Authorization: Bearer={{bearerToken}}
{
"role" : "member"
}
### Set public organization membership for the authenticated user
## Set public organization membership for the authenticated user
PUT https://api.github.com/orgs/{{org}}/public_members/{{username}}
Accept: application/json
Authorization: Bearer={{bearerToken}}
### Unblock a user from an organization
## Unblock a user from an organization
DELETE https://api.github.com/orgs/{{org}}/blocks/{{username}}
Authorization: Bearer={{bearerToken}}
### Update an organization
## Update an organization
PATCH https://api.github.com/orgs/{{org}}
Content-Type: application/json
Accept: application/json
Authorization: Bearer={{bearerToken}}
{
"billing_email" : "mona@github.com",
"company" : "GitHub",
"email" : "mona@github.com",
"twitter_username" : "github",
"location" : "San Francisco",
"name" : "github",
"description" : "GitHub, the company.",
"default_repository_permission" : "read",
"members_can_create_repositories" : true,
"members_allowed_repository_creation_type" : "all"
}
### Update an organization membership for the authenticated user
## Update an organization membership for the authenticated user
PATCH https://api.github.com/user/memberships/orgs/{{org}}
Content-Type: application/json
Accept: application/json
Authorization: Bearer={{bearerToken}}
{
"state" : "active"
}
### Update the access a fine-grained personal access token has to organization resources
## Update the access a fine-grained personal access token has to organization resources
POST https://api.github.com/orgs/{{org}}/personal-access-tokens/{{pat_id}}
Content-Type: application/json
Accept: application/json
Authorization: Bearer={{bearerToken}}
{
"action" : "revoke"
}
### Update the access to organization resources via fine-grained personal access tokens
## Update the access to organization resources via fine-grained personal access tokens
POST https://api.github.com/orgs/{{org}}/personal-access-tokens
Content-Type: application/json
Accept: application/json
Authorization: Bearer={{bearerToken}}
{
"action" : "revoke",
"pat_ids" : [ 1296269, 1296280 ]
}
### Update an organization webhook
## Update an organization webhook
PATCH https://api.github.com/orgs/{{org}}/hooks/{{hook_id}}
Content-Type: application/json
Accept: application/json
Authorization: Bearer={{bearerToken}}
{
"active" : true,
"events" : [ "pull_request" ]
}
### Update a webhook configuration for an organization
## Update a webhook configuration for an organization
PATCH https://api.github.com/orgs/{{org}}/hooks/{{hook_id}}/config
Content-Type: application/json
Accept: application/json
Authorization: Bearer={{bearerToken}}
{
"url" : "http://example.com/webhook",
"content_type" : "json",
"insecure_ssl" : "0",
"secret" : "********"
}