Python
Default
from portkey_ai import Portkey# Initialize the Portkey clientportkey = Portkey( api_key="PORTKEY_API_KEY",)# Get user from workspaceusers = portkey.admin.workspaces.users.list( workspace_id="WORKSPACE_SLUG",)print(users)
{ "total": 2, "object": "list", "data": [ { "object": "workspace-user", "id": "25afb7bd-f98a-11ee-85fe-0e27d7367987", "first_name": "John", "last_name": "Doe", "org_role": "member", "role": "member", "created_at": "2024-01-01T00:00:00.000Z", "last_updated_at": "2024-01-01T00:00:00.000Z", "status": "active" } ] }
admin
manager
member
OK
2
list
"list"
Show child attributes
Was this page helpful?