Tenants
Endpoint to list workspaces.
Only superusers can list all workspaces, without membership.
Args: tenant_id: Deprecated, use workspace_id instead. tenant_name: Deprecated, use workspace_name instead. workspace_id: Workspace ID to filter by. workspace_name: Workspace name to filter by. url: Workspace service URL to filter by. organization_id: Organization ID to filter by. status: Filter by workspace status. is_managed: Filter by whether the workspace is managed by ZenML Pro. owner_id: Id of the Workspace owner offset: Offset for pagination. limit: Limit for pagination. auth_context: Auth context. workspace_manager: Workspace manager. organization_manager: Organization manager. rbac: RBAC component.
Returns: List of all workspaces within the given filter params.
Raises: IllegalOperationError: If the operation is not allowed.
Enum that represents the desired state or status of a workspace.
These values can be used in two places:
- in the
desired_state
field of a workspace object, to indicate the desired state of the workspace (with the exception ofPENDING
andFAILED
which are not valid values fordesired_state
) - in the
status
field of a workspace object, to indicate the current state of the workspace
0
100
GET /tenants HTTP/1.1
Host:
Authorization: Bearer YOUR_OAUTH2_TOKEN
Accept: */*
[
{
"id": "123e4567-e89b-12d3-a456-426614174000",
"name": "text",
"display_name": "text",
"description": "text",
"logo_url": "text",
"organization": {
"name": "text",
"description": "text",
"logo_url": "text",
"id": "123e4567-e89b-12d3-a456-426614174000",
"created": "2025-07-15T05:58:44.894Z",
"updated": "2025-07-15T05:58:44.894Z",
"owner": {
"password": "text",
"password_expired": true,
"name": "text",
"avatar_url": "text",
"company": "text",
"job_title": "text",
"metadata": {},
"id": "123e4567-e89b-12d3-a456-426614174000",
"username": "text",
"email": "text",
"oauth_provider": "text",
"oauth_id": "text",
"is_active": true,
"is_superuser": false,
"is_service_account": false,
"organization_id": "123e4567-e89b-12d3-a456-426614174000"
},
"has_active_subscription": true,
"trial_expiry": 1
},
"owner": {
"password": "text",
"password_expired": true,
"name": "text",
"avatar_url": "text",
"company": "text",
"job_title": "text",
"metadata": {},
"id": "123e4567-e89b-12d3-a456-426614174000",
"username": "text",
"email": "text",
"oauth_provider": "text",
"oauth_id": "text",
"is_active": true,
"is_superuser": false,
"is_service_account": false,
"organization_id": "123e4567-e89b-12d3-a456-426614174000"
},
"is_managed": true,
"enrollment_key": "text",
"zenml_service": {
"configuration": {
"version": "text",
"analytics_enabled": true,
"secrets_store": {
"type": "sql"
},
"backup_secrets_store": {
"type": "sql"
},
"admin": {
"helm_chart_version": "text",
"image_repository": "text",
"image_tag": "text",
"debug": true,
"rbac_implementation_source": "text",
"workload_manager_implementation_source": "text",
"feature_gate_implementation_source": "text",
"environment_vars": {
"ANY_ADDITIONAL_PROPERTY": "text"
},
"secret_environment_vars": {
"ANY_ADDITIONAL_PROPERTY": "text"
},
"provider_type": "argocd",
"provider_config": {},
"service_tier": "basic",
"resources": {
"replicas": 1,
"cpu": "text",
"memory": "text",
"max_cpu": "text",
"max_memory": "text",
"memory_migration": "text",
"max_memory_migration": "text",
"autoscaling_enabled": false,
"min_replicas": 1,
"max_replicas": 1,
"thread_pool_size": 40,
"db_pool_size": 20,
"db_pool_overflow": 20,
"workspace_node_pool": "main",
"workload_node_pool": "main",
"max_concurrent_template_runs": 1,
"memory_run_template": "text",
"max_memory_run_template": "text",
"max_storage_size": 1073741824
}
}
},
"status": {
"server_url": "text",
"version": "text",
"storage_size": 1,
"storage_size_last_updated": "2025-07-15T05:58:44.894Z",
"storage_access_blocked": false
}
},
"mlflow_service": {
"configuration": {
"version": "text",
"artifact_store": {
"type": "cloud",
"auth_config": {},
"auth_config_secret": "text"
},
"admin": {
"provider_config": {},
"service_tier": "basic",
"resources": {
"replicas": 1,
"cpu": "text",
"memory": "text"
}
}
},
"status": {
"server_url": "text",
"username": "text",
"password": "text"
}
},
"usage_counts": {
"ANY_ADDITIONAL_PROPERTY": 1
},
"desired_state": "not_initialized",
"state_reason": "user_action",
"status": "not_initialized",
"created": "2025-07-15T05:58:44.894Z",
"updated": "2025-07-15T05:58:44.894Z",
"status_updated": "2025-07-15T05:58:44.894Z"
}
]
Create or enroll a workspace.
Args: workspace_create: Workspace create model. organization_id: ID of the organization to which the workspace belongs to. force: If it should be created regardless of workspace limits. enroll: Set if this is an unmanaged workspace that is being enrolled. name: Name of the workspace. description: Description of the workspace. rbac: RBAC component. auth_context: Auth context. workspace_manager: Workspace manager. organization_manager: Organization manager.
Returns: Model of the created workspace.
Raises: IllegalOperationError: If the operation is not allowed.
false
false
POST /tenants HTTP/1.1
Host:
Authorization: Bearer YOUR_OAUTH2_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 1689
{
"id": "123e4567-e89b-12d3-a456-426614174000",
"name": "text",
"display_name": "text",
"description": "text",
"logo_url": "text",
"owner_id": "123e4567-e89b-12d3-a456-426614174000",
"organization_id": "123e4567-e89b-12d3-a456-426614174000",
"is_managed": true,
"enrollment_key": "text",
"zenml_service": {
"configuration": {
"version": "text",
"analytics_enabled": true,
"secrets_store": {
"type": "sql"
},
"backup_secrets_store": {
"type": "sql"
},
"admin": {
"helm_chart_version": "text",
"image_repository": "text",
"image_tag": "text",
"debug": true,
"rbac_implementation_source": "text",
"workload_manager_implementation_source": "text",
"feature_gate_implementation_source": "text",
"environment_vars": {
"ANY_ADDITIONAL_PROPERTY": "text"
},
"secret_environment_vars": {
"ANY_ADDITIONAL_PROPERTY": "text"
},
"provider_type": "argocd",
"provider_config": {},
"service_tier": "basic",
"resources": {
"replicas": 1,
"cpu": "text",
"memory": "text",
"max_cpu": "text",
"max_memory": "text",
"memory_migration": "text",
"max_memory_migration": "text",
"autoscaling_enabled": false,
"min_replicas": 1,
"max_replicas": 1,
"thread_pool_size": 40,
"db_pool_size": 20,
"db_pool_overflow": 20,
"workspace_node_pool": "main",
"workload_node_pool": "main",
"max_concurrent_template_runs": 1,
"memory_run_template": "text",
"max_memory_run_template": "text",
"max_storage_size": 1073741824
}
}
},
"status": {
"server_url": "text",
"version": "text",
"storage_size": 1,
"storage_size_last_updated": "2025-07-15T05:58:44.894Z",
"storage_access_blocked": false
}
},
"mlflow_service": {
"enabled": false,
"configuration": {
"version": "text",
"artifact_store": {
"type": "cloud",
"auth_config": {},
"auth_config_secret": "text"
},
"admin": {
"provider_config": {},
"service_tier": "basic",
"resources": {
"replicas": 1,
"cpu": "text",
"memory": "text"
}
}
}
}
}
{
"id": "123e4567-e89b-12d3-a456-426614174000",
"name": "text",
"display_name": "text",
"description": "text",
"logo_url": "text",
"organization": {
"name": "text",
"description": "text",
"logo_url": "text",
"id": "123e4567-e89b-12d3-a456-426614174000",
"created": "2025-07-15T05:58:44.894Z",
"updated": "2025-07-15T05:58:44.894Z",
"owner": {
"password": "text",
"password_expired": true,
"name": "text",
"avatar_url": "text",
"company": "text",
"job_title": "text",
"metadata": {},
"id": "123e4567-e89b-12d3-a456-426614174000",
"username": "text",
"email": "text",
"oauth_provider": "text",
"oauth_id": "text",
"is_active": true,
"is_superuser": false,
"is_service_account": false,
"organization_id": "123e4567-e89b-12d3-a456-426614174000"
},
"has_active_subscription": true,
"trial_expiry": 1
},
"owner": {
"password": "text",
"password_expired": true,
"name": "text",
"avatar_url": "text",
"company": "text",
"job_title": "text",
"metadata": {},
"id": "123e4567-e89b-12d3-a456-426614174000",
"username": "text",
"email": "text",
"oauth_provider": "text",
"oauth_id": "text",
"is_active": true,
"is_superuser": false,
"is_service_account": false,
"organization_id": "123e4567-e89b-12d3-a456-426614174000"
},
"is_managed": true,
"enrollment_key": "text",
"zenml_service": {
"configuration": {
"version": "text",
"analytics_enabled": true,
"secrets_store": {
"type": "sql"
},
"backup_secrets_store": {
"type": "sql"
},
"admin": {
"helm_chart_version": "text",
"image_repository": "text",
"image_tag": "text",
"debug": true,
"rbac_implementation_source": "text",
"workload_manager_implementation_source": "text",
"feature_gate_implementation_source": "text",
"environment_vars": {
"ANY_ADDITIONAL_PROPERTY": "text"
},
"secret_environment_vars": {
"ANY_ADDITIONAL_PROPERTY": "text"
},
"provider_type": "argocd",
"provider_config": {},
"service_tier": "basic",
"resources": {
"replicas": 1,
"cpu": "text",
"memory": "text",
"max_cpu": "text",
"max_memory": "text",
"memory_migration": "text",
"max_memory_migration": "text",
"autoscaling_enabled": false,
"min_replicas": 1,
"max_replicas": 1,
"thread_pool_size": 40,
"db_pool_size": 20,
"db_pool_overflow": 20,
"workspace_node_pool": "main",
"workload_node_pool": "main",
"max_concurrent_template_runs": 1,
"memory_run_template": "text",
"max_memory_run_template": "text",
"max_storage_size": 1073741824
}
}
},
"status": {
"server_url": "text",
"version": "text",
"storage_size": 1,
"storage_size_last_updated": "2025-07-15T05:58:44.894Z",
"storage_access_blocked": false
}
},
"mlflow_service": {
"configuration": {
"version": "text",
"artifact_store": {
"type": "cloud",
"auth_config": {},
"auth_config_secret": "text"
},
"admin": {
"provider_config": {},
"service_tier": "basic",
"resources": {
"replicas": 1,
"cpu": "text",
"memory": "text"
}
}
},
"status": {
"server_url": "text",
"username": "text",
"password": "text"
}
},
"usage_counts": {
"ANY_ADDITIONAL_PROPERTY": 1
},
"desired_state": "not_initialized",
"state_reason": "user_action",
"status": "not_initialized",
"created": "2025-07-15T05:58:44.894Z",
"updated": "2025-07-15T05:58:44.894Z",
"status_updated": "2025-07-15T05:58:44.894Z"
}
Delete all workspaces.
Args: user: Authenticated user. workspace_manager: Workspace manager.
Raises: IllegalOperationError: If a regular user tries to force delete or if the operation is not allowed in the current environment.
DELETE /tenants HTTP/1.1
Host:
Authorization: Bearer YOUR_OAUTH2_TOKEN
Accept: */*
Successful Response
No content
Last updated
Was this helpful?