Unassign Role From User
DELETEhttps://cloud.agenta.ai/api/workspaces/:workspace_id/roles
Delete a role assignment from a user in a workspace.
Args: workspace_id (str): The ID of the workspace. email (str): The email of the user to remove the role from. org_id (str): The ID of the organization. role (str): The role to remove from the user. request (Request): The FastAPI request object.
Returns: bool: True if the role assignment was successfully deleted.
Raises: HTTPException: If there is an error in the request or the user does not have permission to perform the action. HTTPException: If there is an error in updating the user's roles.
Request
Path Parameters
workspace_id Workspace Idrequired
Query Parameters
email Emailrequired
org_id Org Idrequired
role Rolerequired
Responses
- 200
- 422
Successful Response
- application/json
- Schema
Schema
any
Validation Error
- application/json
- Schema
- Example (from schema)
Schema
detail
object[]
{
"detail": [
{
"loc": [
"string",
0
],
"msg": "string",
"type": "string"
}
]
}
- curl
- python
- go
- nodejs
- ruby
- csharp
- php
- java
- powershell
- CURL
curl -L -X DELETE 'https://cloud.agenta.ai/api/workspaces/:workspace_id/roles' \
-H 'Accept: application/json' \
-H 'Authorization: <API_KEY_VALUE>'
ResponseClear