Skip to content
Primary navigation

Unassign organization role from user

DELETE/organization/users/{user_id}/roles/{role_id}

Unassigns an organization role from a user within the organization.

Path ParametersExpand Collapse
user_id: string
role_id: string
ReturnsExpand Collapse
deleted: boolean

Whether the assignment was removed.

object: string

Identifier for the deleted assignment, such as group.role.deleted or user.role.deleted.

Unassign organization role from user

curl -X DELETE https://api.openai.com/v1/organization/users/user_abc123/roles/role_01J1F8ROLE01 \
  -H "Authorization: Bearer $OPENAI_ADMIN_KEY" \
  -H "Content-Type: application/json"
{
    "object": "user.role.deleted",
    "deleted": true
}
Returns Examples
{
    "object": "user.role.deleted",
    "deleted": true
}