Assignments
Last updated
Was this helpful?
Last updated
Was this helpful?
Endpoint to list role assignments.
Args: role_id: ID of the role for which to list assignments. workspace_id: ID of the workspace for which to list assignments. project_id: ID of the project for which to list assignments. user: The authenticated user. rbac: RBAC component.
Returns: The users and teams that have this role assigned to them.
Model for viewing role assignments.
Endpoint to assign a role.
Args: role_id: ID of the role to assign. user_id: ID of the user to assign the role to. team_id: ID of the team to assign the role to. workspace_id: ID of the workspace to assign the role to. project_id: ID of the project to assign the role to. user: The authenticated user. rbac: RBAC component. organization_manager: Organization manager.
Returns: Model of the created role assignment.
Raises: ValueError: If both or None of user_id and team_id are specified. ValueError: If project_id is specified but workspace_id is not. IllegalOperationError: If the user/team and role are not part of the same organization. IllegalOperationError: If the role can't be assigned at the given scope. IllegalOperationError: If the role is a share role.
Model for viewing role assignments.
Endpoint to revoke a role.
Args: role_id: ID of the role to revoke. user_id: ID of the user to revoke the role from. team_id: ID of the team to revoke the role from. workspace_id: ID of the workspace to revoke the role from. project_id: ID of the project to revoke the role from. user: The authenticated user. rbac: RBAC component. organization_manager: Organization manager.
Raises: IllegalOperationError: If trying to revoke the admin role of an organization owner or the last assigned role of any organization member.
No content