DELETE/users/{username}/copilot-spaces/{space_number}/collaborators/{actor_type}/{actor_identifier}

Remove a collaborator from a Copilot Space for a user

Removes a collaborator from a specific Copilot Space owned by a user. The authenticated user must be the owner of the space or have admin access to the space.

OAuth app tokens and personal access tokens (classic) need the user scope to use this endpoint.

  • RetriesRetries up to 2×, 500ms backoff, 30s timeout.

4 parameters
usernamestringrequired
The handle for the GitHub user account.
space_numberintegerrequired
The unique identifier of the Copilot Space.
actor_typestringrequired
The type of actor (must be `User` for user-owned spaces; `Team` will be rejected).
Allowed:UserTeam
actor_identifierstringrequired
The username of the collaborator. The numeric user ID is also accepted.

3 status codes
204Response
403Forbidden
messagestringoptional
documentation_urlstringoptional
urlstringoptional
statusstringoptional
404Resource not found
messagestringoptional
documentation_urlstringoptional
urlstringoptional
statusstringoptional

Error handling

A 403 is returned: Forbidden. A 404 is returned: Resource not found.

Was this helpful?