blaxel 0.2.34__py3-none-any.whl → 0.2.35__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- blaxel/__init__.py +2 -2
- blaxel/core/client/api/agents/create_agent.py +64 -19
- blaxel/core/client/api/agents/delete_agent.py +44 -15
- blaxel/core/client/api/agents/get_agent.py +43 -14
- blaxel/core/client/api/agents/list_agents.py +40 -11
- blaxel/core/client/api/agents/update_agent.py +60 -19
- blaxel/core/client/api/compute/create_sandbox.py +60 -23
- blaxel/core/client/api/compute/delete_sandbox.py +40 -19
- blaxel/core/client/api/compute/get_sandbox.py +39 -18
- blaxel/core/client/api/compute/list_sandboxes.py +40 -19
- blaxel/core/client/api/compute/update_sandbox.py +56 -23
- blaxel/core/client/api/configurations/get_configuration.py +16 -4
- blaxel/core/client/api/customdomains/create_custom_domain.py +12 -0
- blaxel/core/client/api/customdomains/list_custom_domains.py +16 -4
- blaxel/core/client/api/default/get_template.py +8 -4
- blaxel/core/client/api/functions/create_function.py +62 -19
- blaxel/core/client/api/functions/delete_function.py +46 -15
- blaxel/core/client/api/functions/get_function.py +45 -14
- blaxel/core/client/api/functions/list_functions.py +44 -15
- blaxel/core/client/api/functions/update_function.py +62 -19
- blaxel/core/client/api/images/cleanup_images.py +12 -12
- blaxel/core/client/api/images/delete_image.py +12 -8
- blaxel/core/client/api/images/delete_image_tag.py +12 -8
- blaxel/core/client/api/images/get_image.py +12 -8
- blaxel/core/client/api/images/list_images.py +12 -8
- blaxel/core/client/api/integrations/create_integration_connection.py +56 -23
- blaxel/core/client/api/integrations/delete_integration_connection.py +48 -19
- blaxel/core/client/api/integrations/get_integration.py +12 -8
- blaxel/core/client/api/integrations/get_integration_connection.py +44 -19
- blaxel/core/client/api/integrations/get_integration_connection_model.py +2 -2
- blaxel/core/client/api/integrations/list_integration_connections.py +36 -19
- blaxel/core/client/api/integrations/update_integration_connection.py +52 -19
- blaxel/core/client/api/jobs/create_job.py +20 -12
- blaxel/core/client/api/jobs/create_job_execution.py +22 -16
- blaxel/core/client/api/jobs/delete_job.py +12 -8
- blaxel/core/client/api/jobs/delete_job_execution.py +12 -8
- blaxel/core/client/api/jobs/get_job.py +24 -20
- blaxel/core/client/api/jobs/get_job_execution.py +8 -4
- blaxel/core/client/api/jobs/list_job_executions.py +8 -4
- blaxel/core/client/api/jobs/list_jobs.py +12 -8
- blaxel/core/client/api/jobs/update_job.py +20 -12
- blaxel/core/client/api/locations/list_locations.py +12 -8
- blaxel/core/client/api/{default → mcphub}/list_mcp_hub_definitions.py +20 -4
- blaxel/core/client/api/models/create_model.py +52 -23
- blaxel/core/client/api/models/delete_model.py +40 -19
- blaxel/core/client/api/models/get_model.py +40 -19
- blaxel/core/client/api/models/list_models.py +40 -19
- blaxel/core/client/api/models/update_model.py +52 -23
- blaxel/core/client/api/policies/create_policy.py +12 -8
- blaxel/core/client/api/policies/delete_policy.py +12 -8
- blaxel/core/client/api/policies/get_policy.py +12 -8
- blaxel/core/client/api/policies/list_policies.py +12 -8
- blaxel/core/client/api/policies/update_policy.py +12 -8
- blaxel/core/client/api/public_ipslist/list_public_ips.py +37 -5
- blaxel/core/client/api/sandboxhub/__init__.py +0 -0
- blaxel/core/client/api/{default → sandboxhub}/list_sandbox_hub_definitions.py +20 -4
- blaxel/core/client/api/service_accounts/create_api_key_for_service_account.py +12 -8
- blaxel/core/client/api/service_accounts/create_workspace_service_account.py +12 -8
- blaxel/core/client/api/service_accounts/delete_api_key_for_service_account.py +6 -4
- blaxel/core/client/api/service_accounts/delete_workspace_service_account.py +12 -8
- blaxel/core/client/api/service_accounts/get_workspace_service_accounts.py +12 -8
- blaxel/core/client/api/service_accounts/list_api_keys_for_service_account.py +12 -8
- blaxel/core/client/api/service_accounts/update_workspace_service_account.py +8 -8
- blaxel/core/client/api/templates/list_templates.py +12 -8
- blaxel/core/client/api/volume_templates/create_volume_template.py +8 -4
- blaxel/core/client/api/volume_templates/list_volume_templates.py +8 -4
- blaxel/core/client/api/volumes/create_volume.py +56 -23
- blaxel/core/client/api/volumes/delete_volume.py +44 -19
- blaxel/core/client/api/volumes/get_volume.py +40 -19
- blaxel/core/client/api/volumes/list_volumes.py +40 -19
- blaxel/core/client/api/workspaces/create_workspace.py +54 -23
- blaxel/core/client/api/workspaces/delete_workspace.py +42 -19
- blaxel/core/client/api/workspaces/get_workspace.py +42 -19
- blaxel/core/client/api/workspaces/invite_workspace_user.py +8 -4
- blaxel/core/client/api/workspaces/list_workspace_users.py +12 -8
- blaxel/core/client/api/workspaces/list_workspaces.py +36 -19
- blaxel/core/client/api/workspaces/update_workspace.py +50 -19
- blaxel/core/client/models/__init__.py +76 -146
- blaxel/core/client/models/agent.py +43 -47
- blaxel/core/client/models/agent_runtime.py +139 -0
- blaxel/core/client/models/agent_runtime_generation.py +18 -0
- blaxel/core/client/models/agent_spec.py +33 -110
- blaxel/core/client/models/api_key.py +5 -4
- blaxel/core/client/models/core_event.py +5 -5
- blaxel/core/client/models/create_api_key_for_service_account_body.py +2 -1
- blaxel/core/client/models/create_job_execution_request.py +1 -1
- blaxel/core/client/models/create_job_execution_response.py +13 -9
- blaxel/core/client/models/custom_domain.py +19 -36
- blaxel/core/client/models/custom_domain_metadata.py +4 -3
- blaxel/core/client/models/custom_domain_spec.py +14 -5
- blaxel/core/client/models/custom_domain_spec_status.py +19 -0
- blaxel/core/client/models/entrypoint.py +39 -13
- blaxel/core/client/models/{workspace_labels.py → entrypoint_args_item.py} +6 -6
- blaxel/core/client/models/entrypoint_env.py +3 -3
- blaxel/core/client/models/{job_metrics_executions_total.py → entrypoint_super_gateway_args_item.py} +6 -6
- blaxel/core/client/models/{spec_configuration.py → env.py} +17 -8
- blaxel/core/{sandbox/client/models/welcome_response.py → client/models/error.py} +26 -23
- blaxel/core/client/models/expiration_policy.py +30 -11
- blaxel/core/client/models/expiration_policy_action.py +17 -0
- blaxel/core/client/models/expiration_policy_type.py +19 -0
- blaxel/core/client/models/flavor.py +13 -5
- blaxel/core/client/models/flavor_type.py +18 -0
- blaxel/core/client/models/form.py +6 -6
- blaxel/core/client/models/function.py +43 -47
- blaxel/core/client/models/function_runtime.py +138 -0
- blaxel/core/client/models/function_runtime_generation.py +18 -0
- blaxel/core/client/models/function_spec.py +27 -73
- blaxel/core/client/models/function_spec_transport.py +18 -0
- blaxel/core/client/models/image.py +19 -36
- blaxel/core/client/models/integration_connection.py +25 -39
- blaxel/core/client/models/integration_connection_spec.py +8 -5
- blaxel/core/client/models/integration_connection_spec_config.py +1 -1
- blaxel/core/client/models/integration_connection_spec_secret.py +1 -1
- blaxel/core/client/models/integration_endpoint.py +41 -11
- blaxel/core/client/models/integration_endpoint_ignore_models_item.py +45 -0
- blaxel/core/client/models/{mcp_definition_entrypoint.py → integration_endpoint_models_item.py} +6 -6
- blaxel/core/client/models/job.py +43 -47
- blaxel/core/client/models/job_execution.py +30 -37
- blaxel/core/client/models/job_execution_metadata.py +3 -3
- blaxel/core/client/models/job_execution_spec.py +2 -2
- blaxel/core/client/models/job_execution_stats.py +5 -5
- blaxel/core/client/models/job_execution_status.py +24 -0
- blaxel/core/client/models/job_execution_task.py +12 -4
- blaxel/core/client/models/job_execution_task_metadata.py +1 -1
- blaxel/core/client/models/job_execution_task_spec.py +2 -2
- blaxel/core/client/models/job_execution_task_status.py +23 -0
- blaxel/core/client/models/job_runtime.py +172 -0
- blaxel/core/client/models/job_runtime_generation.py +18 -0
- blaxel/core/client/models/job_spec.py +20 -88
- blaxel/core/client/models/location_response.py +5 -5
- blaxel/core/client/models/mcp_definition.py +30 -17
- blaxel/core/client/models/{job_metrics_tasks_total.py → mcp_definition_categories_item.py} +6 -6
- blaxel/core/client/models/metadata.py +23 -17
- blaxel/core/client/models/metadata_labels.py +4 -1
- blaxel/core/client/models/model.py +43 -47
- blaxel/core/client/models/model_runtime.py +99 -0
- blaxel/core/client/models/model_runtime_type.py +34 -0
- blaxel/core/client/models/model_spec.py +12 -58
- blaxel/core/client/models/o_auth.py +23 -6
- blaxel/core/client/models/{form_oauth.py → o_auth_scope_item.py} +6 -6
- blaxel/core/client/models/pending_invitation_accept.py +2 -1
- blaxel/core/client/models/pending_invitation_workspace_details.py +27 -6
- blaxel/core/client/models/{metrics_request_total_per_code.py → pending_invitation_workspace_details_emails_item.py} +6 -6
- blaxel/core/client/models/policy.py +20 -36
- blaxel/core/client/models/policy_location.py +13 -5
- blaxel/core/client/models/policy_location_type.py +19 -0
- blaxel/core/client/models/policy_max_tokens.py +6 -6
- blaxel/core/client/models/policy_resource_type.py +20 -0
- blaxel/core/client/models/policy_spec.py +31 -10
- blaxel/core/client/models/policy_spec_type.py +19 -0
- blaxel/core/client/models/port.py +25 -15
- blaxel/core/client/models/port_protocol.py +19 -0
- blaxel/core/client/models/preview.py +19 -36
- blaxel/core/client/models/preview_metadata.py +12 -10
- blaxel/core/client/models/preview_token.py +19 -36
- blaxel/core/client/models/preview_token_metadata.py +8 -6
- blaxel/core/client/models/repository.py +2 -2
- blaxel/core/client/models/revision_configuration.py +3 -3
- blaxel/core/client/models/sandbox.py +45 -58
- blaxel/core/client/models/sandbox_definition.py +37 -22
- blaxel/core/client/models/sandbox_definition_categories_item.py +45 -0
- blaxel/core/client/models/sandbox_error.py +148 -0
- blaxel/core/client/models/sandbox_error_details.py +45 -0
- blaxel/core/client/models/sandbox_lifecycle.py +3 -2
- blaxel/core/client/models/sandbox_runtime.py +145 -0
- blaxel/core/client/models/sandbox_spec.py +33 -134
- blaxel/core/client/models/status.py +25 -0
- blaxel/core/client/models/template.py +8 -7
- blaxel/core/client/models/template_variable.py +5 -5
- blaxel/core/client/models/trigger.py +14 -6
- blaxel/core/client/models/trigger_configuration.py +7 -6
- blaxel/core/client/models/trigger_type.py +19 -0
- blaxel/core/client/models/volume.py +35 -47
- blaxel/core/client/models/volume_attachment.py +6 -4
- blaxel/core/client/models/volume_spec.py +7 -4
- blaxel/core/client/models/volume_state.py +3 -3
- blaxel/core/client/models/volume_template.py +19 -33
- blaxel/core/client/models/volume_template_state.py +12 -4
- blaxel/core/client/models/volume_template_state_status.py +19 -0
- blaxel/core/client/models/volume_template_version.py +12 -4
- blaxel/core/client/models/volume_template_version_status.py +19 -0
- blaxel/core/client/models/workspace.py +35 -25
- blaxel/core/client/models/workspace_runtime.py +3 -2
- blaxel/core/client/models/workspace_status.py +22 -0
- blaxel/core/common/__init__.py +1 -1
- blaxel/core/jobs/__init__.py +0 -1
- blaxel/core/sandbox/__init__.py +2 -0
- blaxel/core/sandbox/client/api/process/post_process.py +8 -4
- blaxel/core/sandbox/client/models/__init__.py +0 -2
- blaxel/core/sandbox/client/models/process_response.py +16 -0
- blaxel/core/sandbox/client/models/process_response_status.py +9 -0
- blaxel/core/sandbox/default/__init__.py +2 -0
- blaxel/core/sandbox/default/interpreter.py +5 -1
- blaxel/core/sandbox/default/preview.py +3 -1
- blaxel/core/sandbox/default/sandbox.py +51 -16
- blaxel/core/sandbox/sync/process.py +2 -1
- blaxel/core/sandbox/sync/sandbox.py +34 -13
- blaxel/core/tools/common.py +16 -2
- blaxel/core/volume/__init__.py +2 -2
- blaxel/core/volume/volume.py +32 -10
- blaxel/langgraph/tools.py +34 -2
- blaxel/openai/tools.py +33 -1
- {blaxel-0.2.34.dist-info → blaxel-0.2.35.dist-info}/METADATA +3 -3
- {blaxel-0.2.34.dist-info → blaxel-0.2.35.dist-info}/RECORD +207 -246
- blaxel/core/client/models/acl.py +0 -133
- blaxel/core/client/models/billable_time_metric.py +0 -89
- blaxel/core/client/models/core_spec.py +0 -194
- blaxel/core/client/models/core_spec_configurations.py +0 -77
- blaxel/core/client/models/histogram_bucket.py +0 -79
- blaxel/core/client/models/histogram_stats.py +0 -88
- blaxel/core/client/models/integration_model.py +0 -162
- blaxel/core/client/models/job_execution_config.py +0 -79
- blaxel/core/client/models/job_metrics.py +0 -262
- blaxel/core/client/models/jobs_chart_value.py +0 -70
- blaxel/core/client/models/jobs_network_chart.py +0 -102
- blaxel/core/client/models/jobs_success_failed_chart.py +0 -147
- blaxel/core/client/models/jobs_total.py +0 -88
- blaxel/core/client/models/last_n_requests_metric.py +0 -97
- blaxel/core/client/models/latency_metric.py +0 -148
- blaxel/core/client/models/logs_response.py +0 -63
- blaxel/core/client/models/logs_response_data.py +0 -99
- blaxel/core/client/models/mcp_definition_form.py +0 -45
- blaxel/core/client/models/memory_allocation_by_name.py +0 -70
- blaxel/core/client/models/memory_allocation_metric.py +0 -61
- blaxel/core/client/models/metric.py +0 -79
- blaxel/core/client/models/metrics.py +0 -273
- blaxel/core/client/models/metrics_models.py +0 -45
- blaxel/core/client/models/metrics_rps_per_code.py +0 -45
- blaxel/core/client/models/pod_template_spec.py +0 -45
- blaxel/core/client/models/request_duration_over_time_metric.py +0 -97
- blaxel/core/client/models/request_duration_over_time_metrics.py +0 -84
- blaxel/core/client/models/request_total_by_origin_metric.py +0 -129
- blaxel/core/client/models/request_total_by_origin_metric_request_total_by_origin.py +0 -45
- blaxel/core/client/models/request_total_by_origin_metric_request_total_by_origin_and_code.py +0 -45
- blaxel/core/client/models/request_total_metric.py +0 -155
- blaxel/core/client/models/request_total_metric_request_total_per_code.py +0 -45
- blaxel/core/client/models/request_total_metric_rps_per_code.py +0 -45
- blaxel/core/client/models/request_total_response_data.py +0 -97
- blaxel/core/client/models/resource.py +0 -99
- blaxel/core/client/models/resource_log.py +0 -88
- blaxel/core/client/models/resource_log_chart.py +0 -133
- blaxel/core/client/models/resource_log_response.py +0 -83
- blaxel/core/client/models/resource_metrics.py +0 -618
- blaxel/core/client/models/resource_metrics_request_total_per_code.py +0 -45
- blaxel/core/client/models/resource_metrics_request_total_per_code_previous.py +0 -45
- blaxel/core/client/models/resource_metrics_rps_per_code.py +0 -45
- blaxel/core/client/models/resource_metrics_rps_per_code_previous.py +0 -45
- blaxel/core/client/models/resource_trace.py +0 -97
- blaxel/core/client/models/runtime.py +0 -317
- blaxel/core/client/models/runtime_configuration.py +0 -45
- blaxel/core/client/models/runtime_startup_probe.py +0 -45
- blaxel/core/client/models/sandbox_metrics.py +0 -88
- blaxel/core/client/models/serverless_config.py +0 -117
- blaxel/core/client/models/serverless_config_configuration.py +0 -45
- blaxel/core/client/models/start_sandbox.py +0 -98
- blaxel/core/client/models/stop_sandbox.py +0 -98
- blaxel/core/client/models/store_agent.py +0 -181
- blaxel/core/client/models/store_agent_labels.py +0 -45
- blaxel/core/client/models/store_configuration.py +0 -156
- blaxel/core/client/models/store_configuration_option.py +0 -79
- blaxel/core/client/models/time_to_first_token_over_time_metrics.py +0 -87
- blaxel/core/client/models/token_rate_metric.py +0 -106
- blaxel/core/client/models/token_rate_metrics.py +0 -124
- blaxel/core/client/models/token_total_metric.py +0 -112
- blaxel/core/client/models/trace_ids_response.py +0 -45
- blaxel/core/client/models/websocket_channel.py +0 -97
- blaxel/core/client/models/websocket_message.py +0 -106
- blaxel/core/sandbox/client/api/root/delete.py +0 -130
- blaxel/core/sandbox/client/api/root/get.py +0 -130
- blaxel/core/sandbox/client/api/root/options.py +0 -130
- blaxel/core/sandbox/client/api/root/patch.py +0 -130
- blaxel/core/sandbox/client/api/root/post.py +0 -130
- blaxel/core/sandbox/client/api/root/put.py +0 -130
- /blaxel/core/{sandbox/client/api/root → client/api/mcphub}/__init__.py +0 -0
- {blaxel-0.2.34.dist-info → blaxel-0.2.35.dist-info}/WHEEL +0 -0
- {blaxel-0.2.34.dist-info → blaxel-0.2.35.dist-info}/licenses/LICENSE +0 -0
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
from http import HTTPStatus
|
|
2
|
-
from typing import Any
|
|
2
|
+
from typing import Any, Union
|
|
3
3
|
|
|
4
4
|
import httpx
|
|
5
5
|
|
|
6
6
|
from ... import errors
|
|
7
7
|
from ...client import Client
|
|
8
|
+
from ...models.error import Error
|
|
8
9
|
from ...models.workspace import Workspace
|
|
9
10
|
from ...types import Response
|
|
10
11
|
|
|
@@ -20,18 +21,36 @@ def _get_kwargs(
|
|
|
20
21
|
return _kwargs
|
|
21
22
|
|
|
22
23
|
|
|
23
|
-
def _parse_response(*, client: Client, response: httpx.Response) -> Workspace | None:
|
|
24
|
+
def _parse_response(*, client: Client, response: httpx.Response) -> Union[Error, Workspace] | None:
|
|
24
25
|
if response.status_code == 200:
|
|
25
26
|
response_200 = Workspace.from_dict(response.json())
|
|
26
27
|
|
|
27
28
|
return response_200
|
|
29
|
+
if response.status_code == 401:
|
|
30
|
+
response_401 = Error.from_dict(response.json())
|
|
31
|
+
|
|
32
|
+
return response_401
|
|
33
|
+
if response.status_code == 403:
|
|
34
|
+
response_403 = Error.from_dict(response.json())
|
|
35
|
+
|
|
36
|
+
return response_403
|
|
37
|
+
if response.status_code == 404:
|
|
38
|
+
response_404 = Error.from_dict(response.json())
|
|
39
|
+
|
|
40
|
+
return response_404
|
|
41
|
+
if response.status_code == 500:
|
|
42
|
+
response_500 = Error.from_dict(response.json())
|
|
43
|
+
|
|
44
|
+
return response_500
|
|
28
45
|
if client.raise_on_unexpected_status:
|
|
29
46
|
raise errors.UnexpectedStatus(response.status_code, response.content)
|
|
30
47
|
else:
|
|
31
48
|
return None
|
|
32
49
|
|
|
33
50
|
|
|
34
|
-
def _build_response(
|
|
51
|
+
def _build_response(
|
|
52
|
+
*, client: Client, response: httpx.Response
|
|
53
|
+
) -> Response[Union[Error, Workspace]]:
|
|
35
54
|
return Response(
|
|
36
55
|
status_code=HTTPStatus(response.status_code),
|
|
37
56
|
content=response.content,
|
|
@@ -44,10 +63,11 @@ def sync_detailed(
|
|
|
44
63
|
workspace_name: str,
|
|
45
64
|
*,
|
|
46
65
|
client: Client,
|
|
47
|
-
) -> Response[Workspace]:
|
|
48
|
-
"""Delete workspace
|
|
66
|
+
) -> Response[Union[Error, Workspace]]:
|
|
67
|
+
"""Delete workspace tenant
|
|
49
68
|
|
|
50
|
-
|
|
69
|
+
Permanently deletes a workspace and ALL its resources (agents, functions, sandboxes, volumes, etc.).
|
|
70
|
+
This action cannot be undone. Only workspace admins can delete a workspace.
|
|
51
71
|
|
|
52
72
|
Args:
|
|
53
73
|
workspace_name (str):
|
|
@@ -57,7 +77,7 @@ def sync_detailed(
|
|
|
57
77
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
58
78
|
|
|
59
79
|
Returns:
|
|
60
|
-
Response[Workspace]
|
|
80
|
+
Response[Union[Error, Workspace]]
|
|
61
81
|
"""
|
|
62
82
|
|
|
63
83
|
kwargs = _get_kwargs(
|
|
@@ -75,10 +95,11 @@ def sync(
|
|
|
75
95
|
workspace_name: str,
|
|
76
96
|
*,
|
|
77
97
|
client: Client,
|
|
78
|
-
) -> Workspace | None:
|
|
79
|
-
"""Delete workspace
|
|
98
|
+
) -> Union[Error, Workspace] | None:
|
|
99
|
+
"""Delete workspace tenant
|
|
80
100
|
|
|
81
|
-
|
|
101
|
+
Permanently deletes a workspace and ALL its resources (agents, functions, sandboxes, volumes, etc.).
|
|
102
|
+
This action cannot be undone. Only workspace admins can delete a workspace.
|
|
82
103
|
|
|
83
104
|
Args:
|
|
84
105
|
workspace_name (str):
|
|
@@ -88,7 +109,7 @@ def sync(
|
|
|
88
109
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
89
110
|
|
|
90
111
|
Returns:
|
|
91
|
-
Workspace
|
|
112
|
+
Union[Error, Workspace]
|
|
92
113
|
"""
|
|
93
114
|
|
|
94
115
|
return sync_detailed(
|
|
@@ -101,10 +122,11 @@ async def asyncio_detailed(
|
|
|
101
122
|
workspace_name: str,
|
|
102
123
|
*,
|
|
103
124
|
client: Client,
|
|
104
|
-
) -> Response[Workspace]:
|
|
105
|
-
"""Delete workspace
|
|
125
|
+
) -> Response[Union[Error, Workspace]]:
|
|
126
|
+
"""Delete workspace tenant
|
|
106
127
|
|
|
107
|
-
|
|
128
|
+
Permanently deletes a workspace and ALL its resources (agents, functions, sandboxes, volumes, etc.).
|
|
129
|
+
This action cannot be undone. Only workspace admins can delete a workspace.
|
|
108
130
|
|
|
109
131
|
Args:
|
|
110
132
|
workspace_name (str):
|
|
@@ -114,7 +136,7 @@ async def asyncio_detailed(
|
|
|
114
136
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
115
137
|
|
|
116
138
|
Returns:
|
|
117
|
-
Response[Workspace]
|
|
139
|
+
Response[Union[Error, Workspace]]
|
|
118
140
|
"""
|
|
119
141
|
|
|
120
142
|
kwargs = _get_kwargs(
|
|
@@ -130,10 +152,11 @@ async def asyncio(
|
|
|
130
152
|
workspace_name: str,
|
|
131
153
|
*,
|
|
132
154
|
client: Client,
|
|
133
|
-
) -> Workspace | None:
|
|
134
|
-
"""Delete workspace
|
|
155
|
+
) -> Union[Error, Workspace] | None:
|
|
156
|
+
"""Delete workspace tenant
|
|
135
157
|
|
|
136
|
-
|
|
158
|
+
Permanently deletes a workspace and ALL its resources (agents, functions, sandboxes, volumes, etc.).
|
|
159
|
+
This action cannot be undone. Only workspace admins can delete a workspace.
|
|
137
160
|
|
|
138
161
|
Args:
|
|
139
162
|
workspace_name (str):
|
|
@@ -143,7 +166,7 @@ async def asyncio(
|
|
|
143
166
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
144
167
|
|
|
145
168
|
Returns:
|
|
146
|
-
Workspace
|
|
169
|
+
Union[Error, Workspace]
|
|
147
170
|
"""
|
|
148
171
|
|
|
149
172
|
return (
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
from http import HTTPStatus
|
|
2
|
-
from typing import Any
|
|
2
|
+
from typing import Any, Union
|
|
3
3
|
|
|
4
4
|
import httpx
|
|
5
5
|
|
|
6
6
|
from ... import errors
|
|
7
7
|
from ...client import Client
|
|
8
|
+
from ...models.error import Error
|
|
8
9
|
from ...models.workspace import Workspace
|
|
9
10
|
from ...types import Response
|
|
10
11
|
|
|
@@ -20,18 +21,36 @@ def _get_kwargs(
|
|
|
20
21
|
return _kwargs
|
|
21
22
|
|
|
22
23
|
|
|
23
|
-
def _parse_response(*, client: Client, response: httpx.Response) -> Workspace | None:
|
|
24
|
+
def _parse_response(*, client: Client, response: httpx.Response) -> Union[Error, Workspace] | None:
|
|
24
25
|
if response.status_code == 200:
|
|
25
26
|
response_200 = Workspace.from_dict(response.json())
|
|
26
27
|
|
|
27
28
|
return response_200
|
|
29
|
+
if response.status_code == 401:
|
|
30
|
+
response_401 = Error.from_dict(response.json())
|
|
31
|
+
|
|
32
|
+
return response_401
|
|
33
|
+
if response.status_code == 403:
|
|
34
|
+
response_403 = Error.from_dict(response.json())
|
|
35
|
+
|
|
36
|
+
return response_403
|
|
37
|
+
if response.status_code == 404:
|
|
38
|
+
response_404 = Error.from_dict(response.json())
|
|
39
|
+
|
|
40
|
+
return response_404
|
|
41
|
+
if response.status_code == 500:
|
|
42
|
+
response_500 = Error.from_dict(response.json())
|
|
43
|
+
|
|
44
|
+
return response_500
|
|
28
45
|
if client.raise_on_unexpected_status:
|
|
29
46
|
raise errors.UnexpectedStatus(response.status_code, response.content)
|
|
30
47
|
else:
|
|
31
48
|
return None
|
|
32
49
|
|
|
33
50
|
|
|
34
|
-
def _build_response(
|
|
51
|
+
def _build_response(
|
|
52
|
+
*, client: Client, response: httpx.Response
|
|
53
|
+
) -> Response[Union[Error, Workspace]]:
|
|
35
54
|
return Response(
|
|
36
55
|
status_code=HTTPStatus(response.status_code),
|
|
37
56
|
content=response.content,
|
|
@@ -44,10 +63,11 @@ def sync_detailed(
|
|
|
44
63
|
workspace_name: str,
|
|
45
64
|
*,
|
|
46
65
|
client: Client,
|
|
47
|
-
) -> Response[Workspace]:
|
|
48
|
-
"""Get workspace
|
|
66
|
+
) -> Response[Union[Error, Workspace]]:
|
|
67
|
+
"""Get workspace details
|
|
49
68
|
|
|
50
|
-
Returns a workspace
|
|
69
|
+
Returns detailed information about a workspace including its display name, account ID, status, and
|
|
70
|
+
runtime configuration.
|
|
51
71
|
|
|
52
72
|
Args:
|
|
53
73
|
workspace_name (str):
|
|
@@ -57,7 +77,7 @@ def sync_detailed(
|
|
|
57
77
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
58
78
|
|
|
59
79
|
Returns:
|
|
60
|
-
Response[Workspace]
|
|
80
|
+
Response[Union[Error, Workspace]]
|
|
61
81
|
"""
|
|
62
82
|
|
|
63
83
|
kwargs = _get_kwargs(
|
|
@@ -75,10 +95,11 @@ def sync(
|
|
|
75
95
|
workspace_name: str,
|
|
76
96
|
*,
|
|
77
97
|
client: Client,
|
|
78
|
-
) -> Workspace | None:
|
|
79
|
-
"""Get workspace
|
|
98
|
+
) -> Union[Error, Workspace] | None:
|
|
99
|
+
"""Get workspace details
|
|
80
100
|
|
|
81
|
-
Returns a workspace
|
|
101
|
+
Returns detailed information about a workspace including its display name, account ID, status, and
|
|
102
|
+
runtime configuration.
|
|
82
103
|
|
|
83
104
|
Args:
|
|
84
105
|
workspace_name (str):
|
|
@@ -88,7 +109,7 @@ def sync(
|
|
|
88
109
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
89
110
|
|
|
90
111
|
Returns:
|
|
91
|
-
Workspace
|
|
112
|
+
Union[Error, Workspace]
|
|
92
113
|
"""
|
|
93
114
|
|
|
94
115
|
return sync_detailed(
|
|
@@ -101,10 +122,11 @@ async def asyncio_detailed(
|
|
|
101
122
|
workspace_name: str,
|
|
102
123
|
*,
|
|
103
124
|
client: Client,
|
|
104
|
-
) -> Response[Workspace]:
|
|
105
|
-
"""Get workspace
|
|
125
|
+
) -> Response[Union[Error, Workspace]]:
|
|
126
|
+
"""Get workspace details
|
|
106
127
|
|
|
107
|
-
Returns a workspace
|
|
128
|
+
Returns detailed information about a workspace including its display name, account ID, status, and
|
|
129
|
+
runtime configuration.
|
|
108
130
|
|
|
109
131
|
Args:
|
|
110
132
|
workspace_name (str):
|
|
@@ -114,7 +136,7 @@ async def asyncio_detailed(
|
|
|
114
136
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
115
137
|
|
|
116
138
|
Returns:
|
|
117
|
-
Response[Workspace]
|
|
139
|
+
Response[Union[Error, Workspace]]
|
|
118
140
|
"""
|
|
119
141
|
|
|
120
142
|
kwargs = _get_kwargs(
|
|
@@ -130,10 +152,11 @@ async def asyncio(
|
|
|
130
152
|
workspace_name: str,
|
|
131
153
|
*,
|
|
132
154
|
client: Client,
|
|
133
|
-
) -> Workspace | None:
|
|
134
|
-
"""Get workspace
|
|
155
|
+
) -> Union[Error, Workspace] | None:
|
|
156
|
+
"""Get workspace details
|
|
135
157
|
|
|
136
|
-
Returns a workspace
|
|
158
|
+
Returns detailed information about a workspace including its display name, account ID, status, and
|
|
159
|
+
runtime configuration.
|
|
137
160
|
|
|
138
161
|
Args:
|
|
139
162
|
workspace_name (str):
|
|
@@ -143,7 +166,7 @@ async def asyncio(
|
|
|
143
166
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
144
167
|
|
|
145
168
|
Returns:
|
|
146
|
-
Workspace
|
|
169
|
+
Union[Error, Workspace]
|
|
147
170
|
"""
|
|
148
171
|
|
|
149
172
|
return (
|
|
@@ -70,7 +70,8 @@ def sync_detailed(
|
|
|
70
70
|
) -> Response[Union[Any, PendingInvitation]]:
|
|
71
71
|
"""Invite user to workspace
|
|
72
72
|
|
|
73
|
-
Invites a
|
|
73
|
+
Invites a new team member to the workspace by email. The invitee will receive an email to accept the
|
|
74
|
+
invitation before gaining access to workspace resources.
|
|
74
75
|
|
|
75
76
|
Args:
|
|
76
77
|
body (InviteWorkspaceUserBody):
|
|
@@ -101,7 +102,8 @@ def sync(
|
|
|
101
102
|
) -> Union[Any, PendingInvitation] | None:
|
|
102
103
|
"""Invite user to workspace
|
|
103
104
|
|
|
104
|
-
Invites a
|
|
105
|
+
Invites a new team member to the workspace by email. The invitee will receive an email to accept the
|
|
106
|
+
invitation before gaining access to workspace resources.
|
|
105
107
|
|
|
106
108
|
Args:
|
|
107
109
|
body (InviteWorkspaceUserBody):
|
|
@@ -127,7 +129,8 @@ async def asyncio_detailed(
|
|
|
127
129
|
) -> Response[Union[Any, PendingInvitation]]:
|
|
128
130
|
"""Invite user to workspace
|
|
129
131
|
|
|
130
|
-
Invites a
|
|
132
|
+
Invites a new team member to the workspace by email. The invitee will receive an email to accept the
|
|
133
|
+
invitation before gaining access to workspace resources.
|
|
131
134
|
|
|
132
135
|
Args:
|
|
133
136
|
body (InviteWorkspaceUserBody):
|
|
@@ -156,7 +159,8 @@ async def asyncio(
|
|
|
156
159
|
) -> Union[Any, PendingInvitation] | None:
|
|
157
160
|
"""Invite user to workspace
|
|
158
161
|
|
|
159
|
-
Invites a
|
|
162
|
+
Invites a new team member to the workspace by email. The invitee will receive an email to accept the
|
|
163
|
+
invitation before gaining access to workspace resources.
|
|
160
164
|
|
|
161
165
|
Args:
|
|
162
166
|
body (InviteWorkspaceUserBody):
|
|
@@ -47,9 +47,10 @@ def sync_detailed(
|
|
|
47
47
|
*,
|
|
48
48
|
client: Client,
|
|
49
49
|
) -> Response[list["WorkspaceUser"]]:
|
|
50
|
-
"""List
|
|
50
|
+
"""List workspace team members
|
|
51
51
|
|
|
52
|
-
Returns
|
|
52
|
+
Returns all team members in the workspace including their roles (admin or member) and invitation
|
|
53
|
+
status.
|
|
53
54
|
|
|
54
55
|
Raises:
|
|
55
56
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
@@ -72,9 +73,10 @@ def sync(
|
|
|
72
73
|
*,
|
|
73
74
|
client: Client,
|
|
74
75
|
) -> list["WorkspaceUser"] | None:
|
|
75
|
-
"""List
|
|
76
|
+
"""List workspace team members
|
|
76
77
|
|
|
77
|
-
Returns
|
|
78
|
+
Returns all team members in the workspace including their roles (admin or member) and invitation
|
|
79
|
+
status.
|
|
78
80
|
|
|
79
81
|
Raises:
|
|
80
82
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
@@ -93,9 +95,10 @@ async def asyncio_detailed(
|
|
|
93
95
|
*,
|
|
94
96
|
client: Client,
|
|
95
97
|
) -> Response[list["WorkspaceUser"]]:
|
|
96
|
-
"""List
|
|
98
|
+
"""List workspace team members
|
|
97
99
|
|
|
98
|
-
Returns
|
|
100
|
+
Returns all team members in the workspace including their roles (admin or member) and invitation
|
|
101
|
+
status.
|
|
99
102
|
|
|
100
103
|
Raises:
|
|
101
104
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
@@ -116,9 +119,10 @@ async def asyncio(
|
|
|
116
119
|
*,
|
|
117
120
|
client: Client,
|
|
118
121
|
) -> list["WorkspaceUser"] | None:
|
|
119
|
-
"""List
|
|
122
|
+
"""List workspace team members
|
|
120
123
|
|
|
121
|
-
Returns
|
|
124
|
+
Returns all team members in the workspace including their roles (admin or member) and invitation
|
|
125
|
+
status.
|
|
122
126
|
|
|
123
127
|
Raises:
|
|
124
128
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
from http import HTTPStatus
|
|
2
|
-
from typing import Any
|
|
2
|
+
from typing import Any, Union
|
|
3
3
|
|
|
4
4
|
import httpx
|
|
5
5
|
|
|
6
6
|
from ... import errors
|
|
7
7
|
from ...client import Client
|
|
8
|
+
from ...models.error import Error
|
|
8
9
|
from ...models.workspace import Workspace
|
|
9
10
|
from ...types import Response
|
|
10
11
|
|
|
@@ -18,7 +19,9 @@ def _get_kwargs() -> dict[str, Any]:
|
|
|
18
19
|
return _kwargs
|
|
19
20
|
|
|
20
21
|
|
|
21
|
-
def _parse_response(
|
|
22
|
+
def _parse_response(
|
|
23
|
+
*, client: Client, response: httpx.Response
|
|
24
|
+
) -> Union[Error, list["Workspace"]] | None:
|
|
22
25
|
if response.status_code == 200:
|
|
23
26
|
response_200 = []
|
|
24
27
|
_response_200 = response.json()
|
|
@@ -28,13 +31,23 @@ def _parse_response(*, client: Client, response: httpx.Response) -> list["Worksp
|
|
|
28
31
|
response_200.append(response_200_item)
|
|
29
32
|
|
|
30
33
|
return response_200
|
|
34
|
+
if response.status_code == 401:
|
|
35
|
+
response_401 = Error.from_dict(response.json())
|
|
36
|
+
|
|
37
|
+
return response_401
|
|
38
|
+
if response.status_code == 500:
|
|
39
|
+
response_500 = Error.from_dict(response.json())
|
|
40
|
+
|
|
41
|
+
return response_500
|
|
31
42
|
if client.raise_on_unexpected_status:
|
|
32
43
|
raise errors.UnexpectedStatus(response.status_code, response.content)
|
|
33
44
|
else:
|
|
34
45
|
return None
|
|
35
46
|
|
|
36
47
|
|
|
37
|
-
def _build_response(
|
|
48
|
+
def _build_response(
|
|
49
|
+
*, client: Client, response: httpx.Response
|
|
50
|
+
) -> Response[Union[Error, list["Workspace"]]]:
|
|
38
51
|
return Response(
|
|
39
52
|
status_code=HTTPStatus(response.status_code),
|
|
40
53
|
content=response.content,
|
|
@@ -46,17 +59,18 @@ def _build_response(*, client: Client, response: httpx.Response) -> Response[lis
|
|
|
46
59
|
def sync_detailed(
|
|
47
60
|
*,
|
|
48
61
|
client: Client,
|
|
49
|
-
) -> Response[list["Workspace"]]:
|
|
50
|
-
"""List workspaces
|
|
62
|
+
) -> Response[Union[Error, list["Workspace"]]]:
|
|
63
|
+
"""List accessible workspaces
|
|
51
64
|
|
|
52
|
-
Returns
|
|
65
|
+
Returns all workspaces the authenticated user has access to. Each workspace is a separate tenant
|
|
66
|
+
with its own resources, team members, and billing.
|
|
53
67
|
|
|
54
68
|
Raises:
|
|
55
69
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
56
70
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
57
71
|
|
|
58
72
|
Returns:
|
|
59
|
-
Response[list['Workspace']]
|
|
73
|
+
Response[Union[Error, list['Workspace']]]
|
|
60
74
|
"""
|
|
61
75
|
|
|
62
76
|
kwargs = _get_kwargs()
|
|
@@ -71,17 +85,18 @@ def sync_detailed(
|
|
|
71
85
|
def sync(
|
|
72
86
|
*,
|
|
73
87
|
client: Client,
|
|
74
|
-
) -> list["Workspace"] | None:
|
|
75
|
-
"""List workspaces
|
|
88
|
+
) -> Union[Error, list["Workspace"]] | None:
|
|
89
|
+
"""List accessible workspaces
|
|
76
90
|
|
|
77
|
-
Returns
|
|
91
|
+
Returns all workspaces the authenticated user has access to. Each workspace is a separate tenant
|
|
92
|
+
with its own resources, team members, and billing.
|
|
78
93
|
|
|
79
94
|
Raises:
|
|
80
95
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
81
96
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
82
97
|
|
|
83
98
|
Returns:
|
|
84
|
-
list['Workspace']
|
|
99
|
+
Union[Error, list['Workspace']]
|
|
85
100
|
"""
|
|
86
101
|
|
|
87
102
|
return sync_detailed(
|
|
@@ -92,17 +107,18 @@ def sync(
|
|
|
92
107
|
async def asyncio_detailed(
|
|
93
108
|
*,
|
|
94
109
|
client: Client,
|
|
95
|
-
) -> Response[list["Workspace"]]:
|
|
96
|
-
"""List workspaces
|
|
110
|
+
) -> Response[Union[Error, list["Workspace"]]]:
|
|
111
|
+
"""List accessible workspaces
|
|
97
112
|
|
|
98
|
-
Returns
|
|
113
|
+
Returns all workspaces the authenticated user has access to. Each workspace is a separate tenant
|
|
114
|
+
with its own resources, team members, and billing.
|
|
99
115
|
|
|
100
116
|
Raises:
|
|
101
117
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
102
118
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
103
119
|
|
|
104
120
|
Returns:
|
|
105
|
-
Response[list['Workspace']]
|
|
121
|
+
Response[Union[Error, list['Workspace']]]
|
|
106
122
|
"""
|
|
107
123
|
|
|
108
124
|
kwargs = _get_kwargs()
|
|
@@ -115,17 +131,18 @@ async def asyncio_detailed(
|
|
|
115
131
|
async def asyncio(
|
|
116
132
|
*,
|
|
117
133
|
client: Client,
|
|
118
|
-
) -> list["Workspace"] | None:
|
|
119
|
-
"""List workspaces
|
|
134
|
+
) -> Union[Error, list["Workspace"]] | None:
|
|
135
|
+
"""List accessible workspaces
|
|
120
136
|
|
|
121
|
-
Returns
|
|
137
|
+
Returns all workspaces the authenticated user has access to. Each workspace is a separate tenant
|
|
138
|
+
with its own resources, team members, and billing.
|
|
122
139
|
|
|
123
140
|
Raises:
|
|
124
141
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
125
142
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
126
143
|
|
|
127
144
|
Returns:
|
|
128
|
-
list['Workspace']
|
|
145
|
+
Union[Error, list['Workspace']]
|
|
129
146
|
"""
|
|
130
147
|
|
|
131
148
|
return (
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
from http import HTTPStatus
|
|
2
|
-
from typing import Any
|
|
2
|
+
from typing import Any, Union
|
|
3
3
|
|
|
4
4
|
import httpx
|
|
5
5
|
|
|
6
6
|
from ... import errors
|
|
7
7
|
from ...client import Client
|
|
8
|
+
from ...models.error import Error
|
|
8
9
|
from ...models.workspace import Workspace
|
|
9
10
|
from ...types import Response
|
|
10
11
|
|
|
@@ -33,18 +34,40 @@ def _get_kwargs(
|
|
|
33
34
|
return _kwargs
|
|
34
35
|
|
|
35
36
|
|
|
36
|
-
def _parse_response(*, client: Client, response: httpx.Response) -> Workspace | None:
|
|
37
|
+
def _parse_response(*, client: Client, response: httpx.Response) -> Union[Error, Workspace] | None:
|
|
37
38
|
if response.status_code == 200:
|
|
38
39
|
response_200 = Workspace.from_dict(response.json())
|
|
39
40
|
|
|
40
41
|
return response_200
|
|
42
|
+
if response.status_code == 400:
|
|
43
|
+
response_400 = Error.from_dict(response.json())
|
|
44
|
+
|
|
45
|
+
return response_400
|
|
46
|
+
if response.status_code == 401:
|
|
47
|
+
response_401 = Error.from_dict(response.json())
|
|
48
|
+
|
|
49
|
+
return response_401
|
|
50
|
+
if response.status_code == 403:
|
|
51
|
+
response_403 = Error.from_dict(response.json())
|
|
52
|
+
|
|
53
|
+
return response_403
|
|
54
|
+
if response.status_code == 404:
|
|
55
|
+
response_404 = Error.from_dict(response.json())
|
|
56
|
+
|
|
57
|
+
return response_404
|
|
58
|
+
if response.status_code == 500:
|
|
59
|
+
response_500 = Error.from_dict(response.json())
|
|
60
|
+
|
|
61
|
+
return response_500
|
|
41
62
|
if client.raise_on_unexpected_status:
|
|
42
63
|
raise errors.UnexpectedStatus(response.status_code, response.content)
|
|
43
64
|
else:
|
|
44
65
|
return None
|
|
45
66
|
|
|
46
67
|
|
|
47
|
-
def _build_response(
|
|
68
|
+
def _build_response(
|
|
69
|
+
*, client: Client, response: httpx.Response
|
|
70
|
+
) -> Response[Union[Error, Workspace]]:
|
|
48
71
|
return Response(
|
|
49
72
|
status_code=HTTPStatus(response.status_code),
|
|
50
73
|
content=response.content,
|
|
@@ -58,21 +81,23 @@ def sync_detailed(
|
|
|
58
81
|
*,
|
|
59
82
|
client: Client,
|
|
60
83
|
body: Workspace,
|
|
61
|
-
) -> Response[Workspace]:
|
|
84
|
+
) -> Response[Union[Error, Workspace]]:
|
|
62
85
|
"""Update workspace
|
|
63
86
|
|
|
64
|
-
Updates a workspace
|
|
87
|
+
Updates a workspace's settings such as display name and labels. The workspace name cannot be changed
|
|
88
|
+
after creation.
|
|
65
89
|
|
|
66
90
|
Args:
|
|
67
91
|
workspace_name (str):
|
|
68
|
-
body (Workspace):
|
|
92
|
+
body (Workspace): Tenant container that groups all Blaxel resources (agents, functions,
|
|
93
|
+
models, etc.) with shared team access control and billing.
|
|
69
94
|
|
|
70
95
|
Raises:
|
|
71
96
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
72
97
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
73
98
|
|
|
74
99
|
Returns:
|
|
75
|
-
Response[Workspace]
|
|
100
|
+
Response[Union[Error, Workspace]]
|
|
76
101
|
"""
|
|
77
102
|
|
|
78
103
|
kwargs = _get_kwargs(
|
|
@@ -92,21 +117,23 @@ def sync(
|
|
|
92
117
|
*,
|
|
93
118
|
client: Client,
|
|
94
119
|
body: Workspace,
|
|
95
|
-
) -> Workspace | None:
|
|
120
|
+
) -> Union[Error, Workspace] | None:
|
|
96
121
|
"""Update workspace
|
|
97
122
|
|
|
98
|
-
Updates a workspace
|
|
123
|
+
Updates a workspace's settings such as display name and labels. The workspace name cannot be changed
|
|
124
|
+
after creation.
|
|
99
125
|
|
|
100
126
|
Args:
|
|
101
127
|
workspace_name (str):
|
|
102
|
-
body (Workspace):
|
|
128
|
+
body (Workspace): Tenant container that groups all Blaxel resources (agents, functions,
|
|
129
|
+
models, etc.) with shared team access control and billing.
|
|
103
130
|
|
|
104
131
|
Raises:
|
|
105
132
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
106
133
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
107
134
|
|
|
108
135
|
Returns:
|
|
109
|
-
Workspace
|
|
136
|
+
Union[Error, Workspace]
|
|
110
137
|
"""
|
|
111
138
|
|
|
112
139
|
return sync_detailed(
|
|
@@ -121,21 +148,23 @@ async def asyncio_detailed(
|
|
|
121
148
|
*,
|
|
122
149
|
client: Client,
|
|
123
150
|
body: Workspace,
|
|
124
|
-
) -> Response[Workspace]:
|
|
151
|
+
) -> Response[Union[Error, Workspace]]:
|
|
125
152
|
"""Update workspace
|
|
126
153
|
|
|
127
|
-
Updates a workspace
|
|
154
|
+
Updates a workspace's settings such as display name and labels. The workspace name cannot be changed
|
|
155
|
+
after creation.
|
|
128
156
|
|
|
129
157
|
Args:
|
|
130
158
|
workspace_name (str):
|
|
131
|
-
body (Workspace):
|
|
159
|
+
body (Workspace): Tenant container that groups all Blaxel resources (agents, functions,
|
|
160
|
+
models, etc.) with shared team access control and billing.
|
|
132
161
|
|
|
133
162
|
Raises:
|
|
134
163
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
135
164
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
136
165
|
|
|
137
166
|
Returns:
|
|
138
|
-
Response[Workspace]
|
|
167
|
+
Response[Union[Error, Workspace]]
|
|
139
168
|
"""
|
|
140
169
|
|
|
141
170
|
kwargs = _get_kwargs(
|
|
@@ -153,21 +182,23 @@ async def asyncio(
|
|
|
153
182
|
*,
|
|
154
183
|
client: Client,
|
|
155
184
|
body: Workspace,
|
|
156
|
-
) -> Workspace | None:
|
|
185
|
+
) -> Union[Error, Workspace] | None:
|
|
157
186
|
"""Update workspace
|
|
158
187
|
|
|
159
|
-
Updates a workspace
|
|
188
|
+
Updates a workspace's settings such as display name and labels. The workspace name cannot be changed
|
|
189
|
+
after creation.
|
|
160
190
|
|
|
161
191
|
Args:
|
|
162
192
|
workspace_name (str):
|
|
163
|
-
body (Workspace):
|
|
193
|
+
body (Workspace): Tenant container that groups all Blaxel resources (agents, functions,
|
|
194
|
+
models, etc.) with shared team access control and billing.
|
|
164
195
|
|
|
165
196
|
Raises:
|
|
166
197
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
167
198
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
168
199
|
|
|
169
200
|
Returns:
|
|
170
|
-
Workspace
|
|
201
|
+
Union[Error, Workspace]
|
|
171
202
|
"""
|
|
172
203
|
|
|
173
204
|
return (
|