blaxel 0.2.33__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.
Files changed (278) hide show
  1. blaxel/__init__.py +2 -2
  2. blaxel/core/__init__.py +2 -1
  3. blaxel/core/client/api/agents/create_agent.py +64 -19
  4. blaxel/core/client/api/agents/delete_agent.py +44 -15
  5. blaxel/core/client/api/agents/get_agent.py +43 -14
  6. blaxel/core/client/api/agents/list_agents.py +40 -11
  7. blaxel/core/client/api/agents/update_agent.py +60 -19
  8. blaxel/core/client/api/compute/create_sandbox.py +60 -23
  9. blaxel/core/client/api/compute/delete_sandbox.py +40 -19
  10. blaxel/core/client/api/compute/get_sandbox.py +39 -18
  11. blaxel/core/client/api/compute/list_sandboxes.py +40 -19
  12. blaxel/core/client/api/compute/update_sandbox.py +56 -23
  13. blaxel/core/client/api/configurations/get_configuration.py +16 -4
  14. blaxel/core/client/api/customdomains/create_custom_domain.py +12 -0
  15. blaxel/core/client/api/customdomains/list_custom_domains.py +16 -4
  16. blaxel/core/client/api/default/get_template.py +8 -4
  17. blaxel/core/client/api/functions/create_function.py +62 -19
  18. blaxel/core/client/api/functions/delete_function.py +46 -15
  19. blaxel/core/client/api/functions/get_function.py +45 -14
  20. blaxel/core/client/api/functions/list_functions.py +44 -15
  21. blaxel/core/client/api/functions/update_function.py +62 -19
  22. blaxel/core/client/api/images/cleanup_images.py +12 -12
  23. blaxel/core/client/api/images/delete_image.py +12 -8
  24. blaxel/core/client/api/images/delete_image_tag.py +12 -8
  25. blaxel/core/client/api/images/get_image.py +12 -8
  26. blaxel/core/client/api/images/list_images.py +12 -8
  27. blaxel/core/client/api/integrations/create_integration_connection.py +56 -23
  28. blaxel/core/client/api/integrations/delete_integration_connection.py +48 -19
  29. blaxel/core/client/api/integrations/get_integration.py +12 -8
  30. blaxel/core/client/api/integrations/get_integration_connection.py +44 -19
  31. blaxel/core/client/api/integrations/get_integration_connection_model.py +2 -2
  32. blaxel/core/client/api/integrations/list_integration_connections.py +36 -19
  33. blaxel/core/client/api/integrations/update_integration_connection.py +52 -19
  34. blaxel/core/client/api/jobs/create_job.py +20 -12
  35. blaxel/core/client/api/jobs/create_job_execution.py +22 -16
  36. blaxel/core/client/api/jobs/delete_job.py +12 -8
  37. blaxel/core/client/api/jobs/delete_job_execution.py +12 -8
  38. blaxel/core/client/api/jobs/get_job.py +24 -20
  39. blaxel/core/client/api/jobs/get_job_execution.py +8 -4
  40. blaxel/core/client/api/jobs/list_job_executions.py +8 -4
  41. blaxel/core/client/api/jobs/list_jobs.py +12 -8
  42. blaxel/core/client/api/jobs/update_job.py +20 -12
  43. blaxel/core/client/api/locations/list_locations.py +12 -8
  44. blaxel/core/client/api/{default → mcphub}/list_mcp_hub_definitions.py +20 -4
  45. blaxel/core/client/api/models/create_model.py +52 -23
  46. blaxel/core/client/api/models/delete_model.py +40 -19
  47. blaxel/core/client/api/models/get_model.py +40 -19
  48. blaxel/core/client/api/models/list_models.py +40 -19
  49. blaxel/core/client/api/models/update_model.py +52 -23
  50. blaxel/core/client/api/policies/create_policy.py +12 -8
  51. blaxel/core/client/api/policies/delete_policy.py +12 -8
  52. blaxel/core/client/api/policies/get_policy.py +12 -8
  53. blaxel/core/client/api/policies/list_policies.py +12 -8
  54. blaxel/core/client/api/policies/update_policy.py +12 -8
  55. blaxel/core/client/api/public_ipslist/list_public_ips.py +37 -5
  56. blaxel/core/client/api/sandboxhub/__init__.py +0 -0
  57. blaxel/core/client/api/{default → sandboxhub}/list_sandbox_hub_definitions.py +20 -4
  58. blaxel/core/client/api/service_accounts/create_api_key_for_service_account.py +12 -8
  59. blaxel/core/client/api/service_accounts/create_workspace_service_account.py +12 -8
  60. blaxel/core/client/api/service_accounts/delete_api_key_for_service_account.py +6 -4
  61. blaxel/core/client/api/service_accounts/delete_workspace_service_account.py +12 -8
  62. blaxel/core/client/api/service_accounts/get_workspace_service_accounts.py +12 -8
  63. blaxel/core/client/api/service_accounts/list_api_keys_for_service_account.py +12 -8
  64. blaxel/core/client/api/service_accounts/update_workspace_service_account.py +8 -8
  65. blaxel/core/client/api/templates/list_templates.py +12 -8
  66. blaxel/core/client/api/volume_templates/create_volume_template.py +8 -4
  67. blaxel/core/client/api/volume_templates/list_volume_templates.py +8 -4
  68. blaxel/core/client/api/volumes/create_volume.py +56 -23
  69. blaxel/core/client/api/volumes/delete_volume.py +44 -19
  70. blaxel/core/client/api/volumes/get_volume.py +40 -19
  71. blaxel/core/client/api/volumes/list_volumes.py +40 -19
  72. blaxel/core/client/api/workspaces/create_workspace.py +54 -23
  73. blaxel/core/client/api/workspaces/delete_workspace.py +42 -19
  74. blaxel/core/client/api/workspaces/get_workspace.py +42 -19
  75. blaxel/core/client/api/workspaces/invite_workspace_user.py +8 -4
  76. blaxel/core/client/api/workspaces/list_workspace_users.py +12 -8
  77. blaxel/core/client/api/workspaces/list_workspaces.py +36 -19
  78. blaxel/core/client/api/workspaces/update_workspace.py +50 -19
  79. blaxel/core/client/models/__init__.py +76 -146
  80. blaxel/core/client/models/agent.py +43 -47
  81. blaxel/core/client/models/agent_runtime.py +139 -0
  82. blaxel/core/client/models/agent_runtime_generation.py +18 -0
  83. blaxel/core/client/models/agent_spec.py +33 -110
  84. blaxel/core/client/models/api_key.py +5 -4
  85. blaxel/core/client/models/core_event.py +5 -5
  86. blaxel/core/client/models/create_api_key_for_service_account_body.py +2 -1
  87. blaxel/core/client/models/create_job_execution_request.py +1 -1
  88. blaxel/core/client/models/create_job_execution_response.py +13 -9
  89. blaxel/core/client/models/custom_domain.py +19 -36
  90. blaxel/core/client/models/custom_domain_metadata.py +4 -3
  91. blaxel/core/client/models/custom_domain_spec.py +14 -5
  92. blaxel/core/client/models/custom_domain_spec_status.py +19 -0
  93. blaxel/core/client/models/entrypoint.py +39 -13
  94. blaxel/core/client/models/{workspace_labels.py → entrypoint_args_item.py} +6 -6
  95. blaxel/core/client/models/entrypoint_env.py +3 -3
  96. blaxel/core/client/models/{job_metrics_executions_total.py → entrypoint_super_gateway_args_item.py} +6 -6
  97. blaxel/core/client/models/{spec_configuration.py → env.py} +17 -8
  98. blaxel/core/{sandbox/client/models/welcome_response.py → client/models/error.py} +26 -23
  99. blaxel/core/client/models/expiration_policy.py +30 -11
  100. blaxel/core/client/models/expiration_policy_action.py +17 -0
  101. blaxel/core/client/models/expiration_policy_type.py +19 -0
  102. blaxel/core/client/models/flavor.py +13 -5
  103. blaxel/core/client/models/flavor_type.py +18 -0
  104. blaxel/core/client/models/form.py +6 -6
  105. blaxel/core/client/models/function.py +43 -47
  106. blaxel/core/client/models/function_runtime.py +138 -0
  107. blaxel/core/client/models/function_runtime_generation.py +18 -0
  108. blaxel/core/client/models/function_spec.py +27 -73
  109. blaxel/core/client/models/function_spec_transport.py +18 -0
  110. blaxel/core/client/models/image.py +19 -36
  111. blaxel/core/client/models/integration_connection.py +25 -39
  112. blaxel/core/client/models/integration_connection_spec.py +8 -5
  113. blaxel/core/client/models/integration_connection_spec_config.py +1 -1
  114. blaxel/core/client/models/integration_connection_spec_secret.py +1 -1
  115. blaxel/core/client/models/integration_endpoint.py +41 -11
  116. blaxel/core/client/models/integration_endpoint_ignore_models_item.py +45 -0
  117. blaxel/core/client/models/{mcp_definition_entrypoint.py → integration_endpoint_models_item.py} +6 -6
  118. blaxel/core/client/models/job.py +43 -47
  119. blaxel/core/client/models/job_execution.py +30 -37
  120. blaxel/core/client/models/job_execution_metadata.py +3 -3
  121. blaxel/core/client/models/job_execution_spec.py +2 -2
  122. blaxel/core/client/models/job_execution_stats.py +5 -5
  123. blaxel/core/client/models/job_execution_status.py +24 -0
  124. blaxel/core/client/models/job_execution_task.py +12 -4
  125. blaxel/core/client/models/job_execution_task_metadata.py +1 -1
  126. blaxel/core/client/models/job_execution_task_spec.py +2 -2
  127. blaxel/core/client/models/job_execution_task_status.py +23 -0
  128. blaxel/core/client/models/job_runtime.py +172 -0
  129. blaxel/core/client/models/job_runtime_generation.py +18 -0
  130. blaxel/core/client/models/job_spec.py +20 -88
  131. blaxel/core/client/models/location_response.py +5 -5
  132. blaxel/core/client/models/mcp_definition.py +30 -17
  133. blaxel/core/client/models/{job_metrics_tasks_total.py → mcp_definition_categories_item.py} +6 -6
  134. blaxel/core/client/models/metadata.py +23 -17
  135. blaxel/core/client/models/metadata_labels.py +4 -1
  136. blaxel/core/client/models/model.py +43 -47
  137. blaxel/core/client/models/model_runtime.py +99 -0
  138. blaxel/core/client/models/model_runtime_type.py +34 -0
  139. blaxel/core/client/models/model_spec.py +12 -58
  140. blaxel/core/client/models/o_auth.py +23 -6
  141. blaxel/core/client/models/{form_oauth.py → o_auth_scope_item.py} +6 -6
  142. blaxel/core/client/models/pending_invitation_accept.py +2 -1
  143. blaxel/core/client/models/pending_invitation_workspace_details.py +27 -6
  144. blaxel/core/client/models/{metrics_request_total_per_code.py → pending_invitation_workspace_details_emails_item.py} +6 -6
  145. blaxel/core/client/models/policy.py +20 -36
  146. blaxel/core/client/models/policy_location.py +13 -5
  147. blaxel/core/client/models/policy_location_type.py +19 -0
  148. blaxel/core/client/models/policy_max_tokens.py +6 -6
  149. blaxel/core/client/models/policy_resource_type.py +20 -0
  150. blaxel/core/client/models/policy_spec.py +31 -10
  151. blaxel/core/client/models/policy_spec_type.py +19 -0
  152. blaxel/core/client/models/port.py +25 -15
  153. blaxel/core/client/models/port_protocol.py +19 -0
  154. blaxel/core/client/models/preview.py +19 -36
  155. blaxel/core/client/models/preview_metadata.py +12 -10
  156. blaxel/core/client/models/preview_token.py +19 -36
  157. blaxel/core/client/models/preview_token_metadata.py +8 -6
  158. blaxel/core/client/models/repository.py +2 -2
  159. blaxel/core/client/models/revision_configuration.py +3 -3
  160. blaxel/core/client/models/sandbox.py +45 -58
  161. blaxel/core/client/models/sandbox_definition.py +37 -22
  162. blaxel/core/client/models/sandbox_definition_categories_item.py +45 -0
  163. blaxel/core/client/models/sandbox_error.py +148 -0
  164. blaxel/core/client/models/sandbox_error_details.py +45 -0
  165. blaxel/core/client/models/sandbox_lifecycle.py +3 -2
  166. blaxel/core/client/models/sandbox_runtime.py +145 -0
  167. blaxel/core/client/models/sandbox_spec.py +33 -134
  168. blaxel/core/client/models/status.py +25 -0
  169. blaxel/core/client/models/template.py +8 -7
  170. blaxel/core/client/models/template_variable.py +5 -5
  171. blaxel/core/client/models/trigger.py +14 -6
  172. blaxel/core/client/models/trigger_configuration.py +7 -6
  173. blaxel/core/client/models/trigger_type.py +19 -0
  174. blaxel/core/client/models/volume.py +35 -47
  175. blaxel/core/client/models/volume_attachment.py +6 -4
  176. blaxel/core/client/models/volume_spec.py +7 -4
  177. blaxel/core/client/models/volume_state.py +3 -3
  178. blaxel/core/client/models/volume_template.py +19 -33
  179. blaxel/core/client/models/volume_template_state.py +12 -4
  180. blaxel/core/client/models/volume_template_state_status.py +19 -0
  181. blaxel/core/client/models/volume_template_version.py +12 -4
  182. blaxel/core/client/models/volume_template_version_status.py +19 -0
  183. blaxel/core/client/models/workspace.py +35 -25
  184. blaxel/core/client/models/workspace_runtime.py +3 -2
  185. blaxel/core/client/models/workspace_status.py +22 -0
  186. blaxel/core/common/__init__.py +1 -1
  187. blaxel/core/jobs/__init__.py +0 -1
  188. blaxel/core/sandbox/__init__.py +2 -0
  189. blaxel/core/sandbox/client/api/process/post_process.py +8 -4
  190. blaxel/core/sandbox/client/models/__init__.py +0 -2
  191. blaxel/core/sandbox/client/models/process_response.py +16 -0
  192. blaxel/core/sandbox/client/models/process_response_status.py +9 -0
  193. blaxel/core/sandbox/default/__init__.py +2 -0
  194. blaxel/core/sandbox/default/interpreter.py +5 -1
  195. blaxel/core/sandbox/default/preview.py +3 -1
  196. blaxel/core/sandbox/default/sandbox.py +85 -26
  197. blaxel/core/sandbox/sync/process.py +2 -1
  198. blaxel/core/sandbox/sync/sandbox.py +68 -23
  199. blaxel/core/sandbox/types.py +3 -0
  200. blaxel/core/tools/common.py +16 -2
  201. blaxel/core/volume/__init__.py +2 -2
  202. blaxel/core/volume/volume.py +227 -11
  203. blaxel/langgraph/tools.py +34 -2
  204. blaxel/openai/tools.py +33 -1
  205. {blaxel-0.2.33.dist-info → blaxel-0.2.35.dist-info}/METADATA +3 -3
  206. {blaxel-0.2.33.dist-info → blaxel-0.2.35.dist-info}/RECORD +209 -248
  207. blaxel/core/client/models/acl.py +0 -133
  208. blaxel/core/client/models/billable_time_metric.py +0 -89
  209. blaxel/core/client/models/core_spec.py +0 -194
  210. blaxel/core/client/models/core_spec_configurations.py +0 -77
  211. blaxel/core/client/models/histogram_bucket.py +0 -79
  212. blaxel/core/client/models/histogram_stats.py +0 -88
  213. blaxel/core/client/models/integration_model.py +0 -162
  214. blaxel/core/client/models/job_execution_config.py +0 -79
  215. blaxel/core/client/models/job_metrics.py +0 -262
  216. blaxel/core/client/models/jobs_chart_value.py +0 -70
  217. blaxel/core/client/models/jobs_network_chart.py +0 -102
  218. blaxel/core/client/models/jobs_success_failed_chart.py +0 -147
  219. blaxel/core/client/models/jobs_total.py +0 -88
  220. blaxel/core/client/models/last_n_requests_metric.py +0 -97
  221. blaxel/core/client/models/latency_metric.py +0 -148
  222. blaxel/core/client/models/logs_response.py +0 -63
  223. blaxel/core/client/models/logs_response_data.py +0 -99
  224. blaxel/core/client/models/mcp_definition_form.py +0 -45
  225. blaxel/core/client/models/memory_allocation_by_name.py +0 -70
  226. blaxel/core/client/models/memory_allocation_metric.py +0 -61
  227. blaxel/core/client/models/metric.py +0 -79
  228. blaxel/core/client/models/metrics.py +0 -273
  229. blaxel/core/client/models/metrics_models.py +0 -45
  230. blaxel/core/client/models/metrics_rps_per_code.py +0 -45
  231. blaxel/core/client/models/pod_template_spec.py +0 -45
  232. blaxel/core/client/models/request_duration_over_time_metric.py +0 -97
  233. blaxel/core/client/models/request_duration_over_time_metrics.py +0 -84
  234. blaxel/core/client/models/request_total_by_origin_metric.py +0 -129
  235. blaxel/core/client/models/request_total_by_origin_metric_request_total_by_origin.py +0 -45
  236. blaxel/core/client/models/request_total_by_origin_metric_request_total_by_origin_and_code.py +0 -45
  237. blaxel/core/client/models/request_total_metric.py +0 -155
  238. blaxel/core/client/models/request_total_metric_request_total_per_code.py +0 -45
  239. blaxel/core/client/models/request_total_metric_rps_per_code.py +0 -45
  240. blaxel/core/client/models/request_total_response_data.py +0 -97
  241. blaxel/core/client/models/resource.py +0 -99
  242. blaxel/core/client/models/resource_log.py +0 -88
  243. blaxel/core/client/models/resource_log_chart.py +0 -133
  244. blaxel/core/client/models/resource_log_response.py +0 -83
  245. blaxel/core/client/models/resource_metrics.py +0 -618
  246. blaxel/core/client/models/resource_metrics_request_total_per_code.py +0 -45
  247. blaxel/core/client/models/resource_metrics_request_total_per_code_previous.py +0 -45
  248. blaxel/core/client/models/resource_metrics_rps_per_code.py +0 -45
  249. blaxel/core/client/models/resource_metrics_rps_per_code_previous.py +0 -45
  250. blaxel/core/client/models/resource_trace.py +0 -97
  251. blaxel/core/client/models/runtime.py +0 -317
  252. blaxel/core/client/models/runtime_configuration.py +0 -45
  253. blaxel/core/client/models/runtime_startup_probe.py +0 -45
  254. blaxel/core/client/models/sandbox_metrics.py +0 -88
  255. blaxel/core/client/models/serverless_config.py +0 -117
  256. blaxel/core/client/models/serverless_config_configuration.py +0 -45
  257. blaxel/core/client/models/start_sandbox.py +0 -98
  258. blaxel/core/client/models/stop_sandbox.py +0 -98
  259. blaxel/core/client/models/store_agent.py +0 -181
  260. blaxel/core/client/models/store_agent_labels.py +0 -45
  261. blaxel/core/client/models/store_configuration.py +0 -156
  262. blaxel/core/client/models/store_configuration_option.py +0 -79
  263. blaxel/core/client/models/time_to_first_token_over_time_metrics.py +0 -87
  264. blaxel/core/client/models/token_rate_metric.py +0 -106
  265. blaxel/core/client/models/token_rate_metrics.py +0 -124
  266. blaxel/core/client/models/token_total_metric.py +0 -112
  267. blaxel/core/client/models/trace_ids_response.py +0 -45
  268. blaxel/core/client/models/websocket_channel.py +0 -97
  269. blaxel/core/client/models/websocket_message.py +0 -106
  270. blaxel/core/sandbox/client/api/root/delete.py +0 -130
  271. blaxel/core/sandbox/client/api/root/get.py +0 -130
  272. blaxel/core/sandbox/client/api/root/options.py +0 -130
  273. blaxel/core/sandbox/client/api/root/patch.py +0 -130
  274. blaxel/core/sandbox/client/api/root/post.py +0 -130
  275. blaxel/core/sandbox/client/api/root/put.py +0 -130
  276. /blaxel/core/{sandbox/client/api/root → client/api/mcphub}/__init__.py +0 -0
  277. {blaxel-0.2.33.dist-info → blaxel-0.2.35.dist-info}/WHEEL +0 -0
  278. {blaxel-0.2.33.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.model import Model
9
10
  from ...types import Response
10
11
 
@@ -33,18 +34,38 @@ def _get_kwargs(
33
34
  return _kwargs
34
35
 
35
36
 
36
- def _parse_response(*, client: Client, response: httpx.Response) -> Model | None:
37
+ def _parse_response(*, client: Client, response: httpx.Response) -> Union[Error, Model] | None:
37
38
  if response.status_code == 200:
38
39
  response_200 = Model.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(*, client: Client, response: httpx.Response) -> Response[Model]:
68
+ def _build_response(*, client: Client, response: httpx.Response) -> Response[Union[Error, Model]]:
48
69
  return Response(
49
70
  status_code=HTTPStatus(response.status_code),
50
71
  content=response.content,
@@ -58,21 +79,23 @@ def sync_detailed(
58
79
  *,
59
80
  client: Client,
60
81
  body: Model,
61
- ) -> Response[Model]:
62
- """Create or update model
82
+ ) -> Response[Union[Error, Model]]:
83
+ """Update model endpoint
63
84
 
64
- Update a model by name.
85
+ Updates a model gateway endpoint's configuration. Changes to provider settings or integration
86
+ connection take effect immediately.
65
87
 
66
88
  Args:
67
89
  model_name (str):
68
- body (Model): Logical object representing a model
90
+ body (Model): Gateway endpoint to external LLM provider APIs (OpenAI, Anthropic, etc.)
91
+ with unified access control, credentials management, and usage tracking.
69
92
 
70
93
  Raises:
71
94
  errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
72
95
  httpx.TimeoutException: If the request takes longer than Client.timeout.
73
96
 
74
97
  Returns:
75
- Response[Model]
98
+ Response[Union[Error, Model]]
76
99
  """
77
100
 
78
101
  kwargs = _get_kwargs(
@@ -92,21 +115,23 @@ def sync(
92
115
  *,
93
116
  client: Client,
94
117
  body: Model,
95
- ) -> Model | None:
96
- """Create or update model
118
+ ) -> Union[Error, Model] | None:
119
+ """Update model endpoint
97
120
 
98
- Update a model by name.
121
+ Updates a model gateway endpoint's configuration. Changes to provider settings or integration
122
+ connection take effect immediately.
99
123
 
100
124
  Args:
101
125
  model_name (str):
102
- body (Model): Logical object representing a model
126
+ body (Model): Gateway endpoint to external LLM provider APIs (OpenAI, Anthropic, etc.)
127
+ with unified access control, credentials management, and usage tracking.
103
128
 
104
129
  Raises:
105
130
  errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
106
131
  httpx.TimeoutException: If the request takes longer than Client.timeout.
107
132
 
108
133
  Returns:
109
- Model
134
+ Union[Error, Model]
110
135
  """
111
136
 
112
137
  return sync_detailed(
@@ -121,21 +146,23 @@ async def asyncio_detailed(
121
146
  *,
122
147
  client: Client,
123
148
  body: Model,
124
- ) -> Response[Model]:
125
- """Create or update model
149
+ ) -> Response[Union[Error, Model]]:
150
+ """Update model endpoint
126
151
 
127
- Update a model by name.
152
+ Updates a model gateway endpoint's configuration. Changes to provider settings or integration
153
+ connection take effect immediately.
128
154
 
129
155
  Args:
130
156
  model_name (str):
131
- body (Model): Logical object representing a model
157
+ body (Model): Gateway endpoint to external LLM provider APIs (OpenAI, Anthropic, etc.)
158
+ with unified access control, credentials management, and usage tracking.
132
159
 
133
160
  Raises:
134
161
  errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
135
162
  httpx.TimeoutException: If the request takes longer than Client.timeout.
136
163
 
137
164
  Returns:
138
- Response[Model]
165
+ Response[Union[Error, Model]]
139
166
  """
140
167
 
141
168
  kwargs = _get_kwargs(
@@ -153,21 +180,23 @@ async def asyncio(
153
180
  *,
154
181
  client: Client,
155
182
  body: Model,
156
- ) -> Model | None:
157
- """Create or update model
183
+ ) -> Union[Error, Model] | None:
184
+ """Update model endpoint
158
185
 
159
- Update a model by name.
186
+ Updates a model gateway endpoint's configuration. Changes to provider settings or integration
187
+ connection take effect immediately.
160
188
 
161
189
  Args:
162
190
  model_name (str):
163
- body (Model): Logical object representing a model
191
+ body (Model): Gateway endpoint to external LLM provider APIs (OpenAI, Anthropic, etc.)
192
+ with unified access control, credentials management, and usage tracking.
164
193
 
165
194
  Raises:
166
195
  errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
167
196
  httpx.TimeoutException: If the request takes longer than Client.timeout.
168
197
 
169
198
  Returns:
170
- Model
199
+ Union[Error, Model]
171
200
  """
172
201
 
173
202
  return (
@@ -57,9 +57,10 @@ def sync_detailed(
57
57
  client: Client,
58
58
  body: Policy,
59
59
  ) -> Response[Policy]:
60
- """Create policy
60
+ """Create governance policy
61
61
 
62
- Creates a policy.
62
+ Creates a new governance policy to control where and how resources are deployed. Policies can
63
+ restrict deployment to specific regions, countries, or continents for compliance.
63
64
 
64
65
  Args:
65
66
  body (Policy): Rule that controls how a deployment is made and served (e.g. location
@@ -89,9 +90,10 @@ def sync(
89
90
  client: Client,
90
91
  body: Policy,
91
92
  ) -> Policy | None:
92
- """Create policy
93
+ """Create governance policy
93
94
 
94
- Creates a policy.
95
+ Creates a new governance policy to control where and how resources are deployed. Policies can
96
+ restrict deployment to specific regions, countries, or continents for compliance.
95
97
 
96
98
  Args:
97
99
  body (Policy): Rule that controls how a deployment is made and served (e.g. location
@@ -116,9 +118,10 @@ async def asyncio_detailed(
116
118
  client: Client,
117
119
  body: Policy,
118
120
  ) -> Response[Policy]:
119
- """Create policy
121
+ """Create governance policy
120
122
 
121
- Creates a policy.
123
+ Creates a new governance policy to control where and how resources are deployed. Policies can
124
+ restrict deployment to specific regions, countries, or continents for compliance.
122
125
 
123
126
  Args:
124
127
  body (Policy): Rule that controls how a deployment is made and served (e.g. location
@@ -146,9 +149,10 @@ async def asyncio(
146
149
  client: Client,
147
150
  body: Policy,
148
151
  ) -> Policy | None:
149
- """Create policy
152
+ """Create governance policy
150
153
 
151
- Creates a policy.
154
+ Creates a new governance policy to control where and how resources are deployed. Policies can
155
+ restrict deployment to specific regions, countries, or continents for compliance.
152
156
 
153
157
  Args:
154
158
  body (Policy): Rule that controls how a deployment is made and served (e.g. location
@@ -45,9 +45,10 @@ def sync_detailed(
45
45
  *,
46
46
  client: Client,
47
47
  ) -> Response[Policy]:
48
- """Delete policy
48
+ """Delete governance policy
49
49
 
50
- Deletes a policy by name.
50
+ Permanently deletes a governance policy. Resources using this policy will need to be updated to use
51
+ a different policy.
51
52
 
52
53
  Args:
53
54
  policy_name (str):
@@ -76,9 +77,10 @@ def sync(
76
77
  *,
77
78
  client: Client,
78
79
  ) -> Policy | None:
79
- """Delete policy
80
+ """Delete governance policy
80
81
 
81
- Deletes a policy by name.
82
+ Permanently deletes a governance policy. Resources using this policy will need to be updated to use
83
+ a different policy.
82
84
 
83
85
  Args:
84
86
  policy_name (str):
@@ -102,9 +104,10 @@ async def asyncio_detailed(
102
104
  *,
103
105
  client: Client,
104
106
  ) -> Response[Policy]:
105
- """Delete policy
107
+ """Delete governance policy
106
108
 
107
- Deletes a policy by name.
109
+ Permanently deletes a governance policy. Resources using this policy will need to be updated to use
110
+ a different policy.
108
111
 
109
112
  Args:
110
113
  policy_name (str):
@@ -131,9 +134,10 @@ async def asyncio(
131
134
  *,
132
135
  client: Client,
133
136
  ) -> Policy | None:
134
- """Delete policy
137
+ """Delete governance policy
135
138
 
136
- Deletes a policy by name.
139
+ Permanently deletes a governance policy. Resources using this policy will need to be updated to use
140
+ a different policy.
137
141
 
138
142
  Args:
139
143
  policy_name (str):
@@ -45,9 +45,10 @@ def sync_detailed(
45
45
  *,
46
46
  client: Client,
47
47
  ) -> Response[Policy]:
48
- """Get policy
48
+ """Get governance policy
49
49
 
50
- Returns a policy by name.
50
+ Returns detailed information about a governance policy including its type (location, flavor, or
51
+ maxToken), restrictions, and which resource types it applies to.
51
52
 
52
53
  Args:
53
54
  policy_name (str):
@@ -76,9 +77,10 @@ def sync(
76
77
  *,
77
78
  client: Client,
78
79
  ) -> Policy | None:
79
- """Get policy
80
+ """Get governance policy
80
81
 
81
- Returns a policy by name.
82
+ Returns detailed information about a governance policy including its type (location, flavor, or
83
+ maxToken), restrictions, and which resource types it applies to.
82
84
 
83
85
  Args:
84
86
  policy_name (str):
@@ -102,9 +104,10 @@ async def asyncio_detailed(
102
104
  *,
103
105
  client: Client,
104
106
  ) -> Response[Policy]:
105
- """Get policy
107
+ """Get governance policy
106
108
 
107
- Returns a policy by name.
109
+ Returns detailed information about a governance policy including its type (location, flavor, or
110
+ maxToken), restrictions, and which resource types it applies to.
108
111
 
109
112
  Args:
110
113
  policy_name (str):
@@ -131,9 +134,10 @@ async def asyncio(
131
134
  *,
132
135
  client: Client,
133
136
  ) -> Policy | None:
134
- """Get policy
137
+ """Get governance policy
135
138
 
136
- Returns a policy by name.
139
+ Returns detailed information about a governance policy including its type (location, flavor, or
140
+ maxToken), restrictions, and which resource types it applies to.
137
141
 
138
142
  Args:
139
143
  policy_name (str):
@@ -47,9 +47,10 @@ def sync_detailed(
47
47
  *,
48
48
  client: Client,
49
49
  ) -> Response[list["Policy"]]:
50
- """List policies
50
+ """List governance policies
51
51
 
52
- Returns a list of all policies in the workspace.
52
+ Returns all governance policies in the workspace. Policies control deployment locations, hardware
53
+ flavors, and token limits for agents, functions, and models.
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["Policy"] | None:
75
- """List policies
76
+ """List governance policies
76
77
 
77
- Returns a list of all policies in the workspace.
78
+ Returns all governance policies in the workspace. Policies control deployment locations, hardware
79
+ flavors, and token limits for agents, functions, and models.
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["Policy"]]:
96
- """List policies
98
+ """List governance policies
97
99
 
98
- Returns a list of all policies in the workspace.
100
+ Returns all governance policies in the workspace. Policies control deployment locations, hardware
101
+ flavors, and token limits for agents, functions, and models.
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["Policy"] | None:
119
- """List policies
122
+ """List governance policies
120
123
 
121
- Returns a list of all policies in the workspace.
124
+ Returns all governance policies in the workspace. Policies control deployment locations, hardware
125
+ flavors, and token limits for agents, functions, and models.
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.
@@ -59,9 +59,10 @@ def sync_detailed(
59
59
  client: Client,
60
60
  body: Policy,
61
61
  ) -> Response[Policy]:
62
- """Update policy
62
+ """Update governance policy
63
63
 
64
- Updates a policy.
64
+ Updates a governance policy's restrictions. Changes take effect on the next deployment of resources
65
+ using this policy.
65
66
 
66
67
  Args:
67
68
  policy_name (str):
@@ -94,9 +95,10 @@ def sync(
94
95
  client: Client,
95
96
  body: Policy,
96
97
  ) -> Policy | None:
97
- """Update policy
98
+ """Update governance policy
98
99
 
99
- Updates a policy.
100
+ Updates a governance policy's restrictions. Changes take effect on the next deployment of resources
101
+ using this policy.
100
102
 
101
103
  Args:
102
104
  policy_name (str):
@@ -124,9 +126,10 @@ async def asyncio_detailed(
124
126
  client: Client,
125
127
  body: Policy,
126
128
  ) -> Response[Policy]:
127
- """Update policy
129
+ """Update governance policy
128
130
 
129
- Updates a policy.
131
+ Updates a governance policy's restrictions. Changes take effect on the next deployment of resources
132
+ using this policy.
130
133
 
131
134
  Args:
132
135
  policy_name (str):
@@ -157,9 +160,10 @@ async def asyncio(
157
160
  client: Client,
158
161
  body: Policy,
159
162
  ) -> Policy | None:
160
- """Update policy
163
+ """Update governance policy
161
164
 
162
- Updates a policy.
165
+ Updates a governance policy's restrictions. Changes take effect on the next deployment of resources
166
+ using this policy.
163
167
 
164
168
  Args:
165
169
  policy_name (str):
@@ -1,18 +1,28 @@
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
8
  from ...models.public_ips import PublicIps
9
- from ...types import Response
9
+ from ...types import UNSET, Response, Unset
10
10
 
11
11
 
12
- def _get_kwargs() -> dict[str, Any]:
12
+ def _get_kwargs(
13
+ *,
14
+ region: Union[Unset, str] = UNSET,
15
+ ) -> dict[str, Any]:
16
+ params: dict[str, Any] = {}
17
+
18
+ params["region"] = region
19
+
20
+ params = {k: v for k, v in params.items() if v is not UNSET and v is not None}
21
+
13
22
  _kwargs: dict[str, Any] = {
14
23
  "method": "get",
15
24
  "url": "/publicIps",
25
+ "params": params,
16
26
  }
17
27
 
18
28
  return _kwargs
@@ -41,11 +51,15 @@ def _build_response(*, client: Client, response: httpx.Response) -> Response[Pub
41
51
  def sync_detailed(
42
52
  *,
43
53
  client: Client,
54
+ region: Union[Unset, str] = UNSET,
44
55
  ) -> Response[PublicIps]:
45
56
  """List public ips
46
57
 
47
58
  Returns a list of all public ips used in Blaxel..
48
59
 
60
+ Args:
61
+ region (Union[Unset, str]):
62
+
49
63
  Raises:
50
64
  errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
51
65
  httpx.TimeoutException: If the request takes longer than Client.timeout.
@@ -54,7 +68,9 @@ def sync_detailed(
54
68
  Response[PublicIps]
55
69
  """
56
70
 
57
- kwargs = _get_kwargs()
71
+ kwargs = _get_kwargs(
72
+ region=region,
73
+ )
58
74
 
59
75
  response = client.get_httpx_client().request(
60
76
  **kwargs,
@@ -66,11 +82,15 @@ def sync_detailed(
66
82
  def sync(
67
83
  *,
68
84
  client: Client,
85
+ region: Union[Unset, str] = UNSET,
69
86
  ) -> PublicIps | None:
70
87
  """List public ips
71
88
 
72
89
  Returns a list of all public ips used in Blaxel..
73
90
 
91
+ Args:
92
+ region (Union[Unset, str]):
93
+
74
94
  Raises:
75
95
  errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
76
96
  httpx.TimeoutException: If the request takes longer than Client.timeout.
@@ -81,17 +101,22 @@ def sync(
81
101
 
82
102
  return sync_detailed(
83
103
  client=client,
104
+ region=region,
84
105
  ).parsed
85
106
 
86
107
 
87
108
  async def asyncio_detailed(
88
109
  *,
89
110
  client: Client,
111
+ region: Union[Unset, str] = UNSET,
90
112
  ) -> Response[PublicIps]:
91
113
  """List public ips
92
114
 
93
115
  Returns a list of all public ips used in Blaxel..
94
116
 
117
+ Args:
118
+ region (Union[Unset, str]):
119
+
95
120
  Raises:
96
121
  errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
97
122
  httpx.TimeoutException: If the request takes longer than Client.timeout.
@@ -100,7 +125,9 @@ async def asyncio_detailed(
100
125
  Response[PublicIps]
101
126
  """
102
127
 
103
- kwargs = _get_kwargs()
128
+ kwargs = _get_kwargs(
129
+ region=region,
130
+ )
104
131
 
105
132
  response = await client.get_async_httpx_client().request(**kwargs)
106
133
 
@@ -110,11 +137,15 @@ async def asyncio_detailed(
110
137
  async def asyncio(
111
138
  *,
112
139
  client: Client,
140
+ region: Union[Unset, str] = UNSET,
113
141
  ) -> PublicIps | None:
114
142
  """List public ips
115
143
 
116
144
  Returns a list of all public ips used in Blaxel..
117
145
 
146
+ Args:
147
+ region (Union[Unset, str]):
148
+
118
149
  Raises:
119
150
  errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
120
151
  httpx.TimeoutException: If the request takes longer than Client.timeout.
@@ -126,5 +157,6 @@ async def asyncio(
126
157
  return (
127
158
  await asyncio_detailed(
128
159
  client=client,
160
+ region=region,
129
161
  )
130
162
  ).parsed
File without changes
@@ -51,7 +51,11 @@ def sync_detailed(
51
51
  *,
52
52
  client: Client,
53
53
  ) -> Response[list["SandboxDefinition"]]:
54
- """
54
+ """List Sandbox Hub templates
55
+
56
+ Returns all pre-built sandbox templates available in the Blaxel Hub. These include popular
57
+ development environments with pre-installed tools and frameworks.
58
+
55
59
  Raises:
56
60
  errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
57
61
  httpx.TimeoutException: If the request takes longer than Client.timeout.
@@ -73,7 +77,11 @@ def sync(
73
77
  *,
74
78
  client: Client,
75
79
  ) -> list["SandboxDefinition"] | None:
76
- """
80
+ """List Sandbox Hub templates
81
+
82
+ Returns all pre-built sandbox templates available in the Blaxel Hub. These include popular
83
+ development environments with pre-installed tools and frameworks.
84
+
77
85
  Raises:
78
86
  errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
79
87
  httpx.TimeoutException: If the request takes longer than Client.timeout.
@@ -91,7 +99,11 @@ async def asyncio_detailed(
91
99
  *,
92
100
  client: Client,
93
101
  ) -> Response[list["SandboxDefinition"]]:
94
- """
102
+ """List Sandbox Hub templates
103
+
104
+ Returns all pre-built sandbox templates available in the Blaxel Hub. These include popular
105
+ development environments with pre-installed tools and frameworks.
106
+
95
107
  Raises:
96
108
  errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
97
109
  httpx.TimeoutException: If the request takes longer than Client.timeout.
@@ -111,7 +123,11 @@ async def asyncio(
111
123
  *,
112
124
  client: Client,
113
125
  ) -> list["SandboxDefinition"] | None:
114
- """
126
+ """List Sandbox Hub templates
127
+
128
+ Returns all pre-built sandbox templates available in the Blaxel Hub. These include popular
129
+ development environments with pre-installed tools and frameworks.
130
+
115
131
  Raises:
116
132
  errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
117
133
  httpx.TimeoutException: If the request takes longer than Client.timeout.
@@ -60,9 +60,10 @@ def sync_detailed(
60
60
  client: Client,
61
61
  body: CreateApiKeyForServiceAccountBody,
62
62
  ) -> Response[ApiKey]:
63
- """Create API key for service account
63
+ """Create service account API key
64
64
 
65
- Creates an API key for a service account.
65
+ Creates a new long-lived API key for a service account. The full key value is only returned once at
66
+ creation. API keys can have optional expiration dates.
66
67
 
67
68
  Args:
68
69
  client_id (str):
@@ -94,9 +95,10 @@ def sync(
94
95
  client: Client,
95
96
  body: CreateApiKeyForServiceAccountBody,
96
97
  ) -> ApiKey | None:
97
- """Create API key for service account
98
+ """Create service account API key
98
99
 
99
- Creates an API key for a service account.
100
+ Creates a new long-lived API key for a service account. The full key value is only returned once at
101
+ creation. API keys can have optional expiration dates.
100
102
 
101
103
  Args:
102
104
  client_id (str):
@@ -123,9 +125,10 @@ async def asyncio_detailed(
123
125
  client: Client,
124
126
  body: CreateApiKeyForServiceAccountBody,
125
127
  ) -> Response[ApiKey]:
126
- """Create API key for service account
128
+ """Create service account API key
127
129
 
128
- Creates an API key for a service account.
130
+ Creates a new long-lived API key for a service account. The full key value is only returned once at
131
+ creation. API keys can have optional expiration dates.
129
132
 
130
133
  Args:
131
134
  client_id (str):
@@ -155,9 +158,10 @@ async def asyncio(
155
158
  client: Client,
156
159
  body: CreateApiKeyForServiceAccountBody,
157
160
  ) -> ApiKey | None:
158
- """Create API key for service account
161
+ """Create service account API key
159
162
 
160
- Creates an API key for a service account.
163
+ Creates a new long-lived API key for a service account. The full key value is only returned once at
164
+ creation. API keys can have optional expiration dates.
161
165
 
162
166
  Args:
163
167
  client_id (str):