Claude Platform Docs

Usuarios

Listar usuarios
organization.users.list(**kwargs) -> Page<OrganizationUser>
GET/v1/organizations/users

Lista los miembros de la organización.

Obtener usuario
organization.users.retrieve(user_id) -> OrganizationUser
GET/v1/organizations/users/{user_id}

Recupera un miembro de la organización por ID de usuario.

Actualizar usuario
organization.users.update(user_id, **kwargs) -> OrganizationUser
POST/v1/organizations/users/{user_id}

Actualiza el rol de un miembro en la organización.

Quitar usuario
organization.users.remove(user_id) -> UserRemoveResponse
DELETE/v1/organizations/users/{user_id}

Quita a un miembro de la organización.

Models
class CannotRemoveLastMemberErrorDetails { error_code }
error_code: :cannot_remove_last_member
class OrganizationUser { type: :user, id, added_at, 3 more }
type: :user

Object type.

For Users, this is always "user".

id: String

ID of the User.

added_at: Time

RFC 3339 datetime string indicating when the User joined the Organization.

formatdate-time
email: String

Email of the User.

name: String

Name of the User.

Organization role of the User.

One of the following:
:admin
:billing
:claude_code_user
:developer
:managed
:membership_admin
:owner
:primary_owner
:user
class UserRemoveResponse { type: :user_deleted, id }
type: :user_deleted

Deleted object type.

For Users, this is always "user_deleted".

id: String

ID of the User.

Errors
class CannotRemoveLastMemberError < Anthropic::Errors::BadRequestError { error_code, details }⁠HTTP status 400

The user is the organization's only member. Add another member before removing this one.

error_code: :cannot_remove_last_member
details: CannotRemoveLastMemberErrorDetails { error_code }
error_code: :cannot_remove_last_member