beamlit 0.0.24rc20__py3-none-any.whl → 0.0.25__py3-none-any.whl
Sign up to get free protection for your applications and to get access to all the features.
- beamlit/agents/chat.py +37 -11
- beamlit/agents/decorator.py +97 -65
- beamlit/api/agents/create_agent.py +9 -14
- beamlit/api/agents/delete_agent.py +22 -1
- beamlit/api/agents/delete_agent_history.py +2 -6
- beamlit/api/agents/get_agent.py +22 -1
- beamlit/api/agents/get_agent_environment_logs.py +11 -11
- beamlit/api/agents/get_agent_history.py +2 -6
- beamlit/api/agents/get_agent_metrics.py +22 -1
- beamlit/api/agents/list_agent_history.py +11 -11
- beamlit/api/agents/list_agents.py +36 -4
- beamlit/api/agents/put_agent_history.py +2 -6
- beamlit/api/agents/update_agent.py +9 -14
- beamlit/api/functions/create_function.py +9 -14
- beamlit/api/functions/delete_function.py +22 -1
- beamlit/api/functions/get_function.py +22 -1
- beamlit/api/functions/get_function_environment_logs.py +11 -11
- beamlit/api/functions/get_function_metrics.py +22 -1
- beamlit/api/functions/list_functions.py +36 -4
- beamlit/api/functions/update_function.py +9 -14
- beamlit/api/history/get_agents_history.py +12 -12
- beamlit/api/history/list_agents_history.py +12 -12
- beamlit/api/integrations/get_integration_connection.py +16 -12
- beamlit/api/integrations/get_integration_connection_model.py +8 -1
- beamlit/api/integrations/get_integration_model.py +8 -1
- beamlit/api/locations/list_locations.py +12 -12
- beamlit/api/models/create_model.py +13 -14
- beamlit/api/models/delete_model.py +22 -1
- beamlit/api/models/get_model.py +22 -1
- beamlit/api/models/get_model_environment_logs.py +11 -11
- beamlit/api/models/get_model_metrics.py +38 -13
- beamlit/api/models/list_models.py +36 -4
- beamlit/api/models/update_model.py +13 -14
- beamlit/api/privateclusters/__init__.py +0 -0
- beamlit/api/{agents/get_agent_deployment_metrics.py → privateclusters/create_private_cluster.py} +28 -55
- beamlit/api/{functions/list_function_deployments.py → privateclusters/delete_private_cluster.py} +38 -37
- beamlit/api/{agents/get_agent_deployment.py → privateclusters/get_private_cluster.py} +40 -44
- beamlit/api/privateclusters/get_private_cluster_health.py +97 -0
- beamlit/api/{agents/list_agent_deployments.py → privateclusters/list_private_clusters.py} +30 -45
- beamlit/api/{models/list_model_deployments.py → privateclusters/update_private_cluster.py} +38 -45
- beamlit/api/privateclusters/update_private_cluster_health.py +97 -0
- beamlit/authentication/device_mode.py +3 -9
- beamlit/common/generate.py +47 -34
- beamlit/common/settings.py +29 -27
- beamlit/deploy/deploy.py +101 -342
- beamlit/deploy/format.py +70 -0
- beamlit/deploy/parser.py +175 -0
- beamlit/functions/decorator.py +8 -11
- beamlit/models/__init__.py +64 -78
- beamlit/models/acl.py +4 -22
- beamlit/models/agent.py +34 -95
- beamlit/models/agent_history.py +7 -5
- beamlit/models/agent_history_event.py +11 -9
- beamlit/models/agent_metadata.py +5 -3
- beamlit/models/agent_spec.py +54 -45
- beamlit/models/api_key.py +14 -14
- beamlit/models/configuration.py +11 -0
- beamlit/models/core_spec.py +45 -32
- beamlit/models/{model_deployment_metrics_query_per_second_per_region_per_code.py → core_spec_configurations.py} +22 -22
- beamlit/models/environment.py +33 -105
- beamlit/models/environment_metadata.py +146 -0
- beamlit/models/environment_spec.py +8 -6
- beamlit/models/function.py +34 -95
- beamlit/models/function_metadata.py +5 -3
- beamlit/models/function_spec.py +53 -40
- beamlit/models/integration_connection.py +31 -137
- beamlit/models/integration_connection_spec.py +6 -4
- beamlit/models/metadata.py +5 -3
- beamlit/models/metadata_labels.py +4 -2
- beamlit/models/model.py +33 -94
- beamlit/models/model_metadata.py +5 -3
- beamlit/models/{function_provider_ref.py → model_private_cluster.py} +23 -14
- beamlit/models/model_provider.py +27 -43
- beamlit/models/model_spec.py +45 -32
- beamlit/models/owner_fields.py +4 -2
- beamlit/models/pending_invitation.py +14 -14
- beamlit/models/pod_template_spec.py +4 -2
- beamlit/models/policy.py +33 -159
- beamlit/models/policy_spec.py +24 -28
- beamlit/models/private_cluster.py +183 -0
- beamlit/models/{model_provider_ref.py → private_location.py} +7 -16
- beamlit/models/resource_deployment_metrics.py +0 -108
- beamlit/models/resource_environment_metrics.py +143 -71
- beamlit/models/{resource_deployment_metrics_inference_per_region.py → resource_environment_metrics_inference_per_region.py} +5 -5
- beamlit/models/resource_environment_metrics_inference_per_second_per_region.py +9 -11
- beamlit/models/{resource_deployment_metrics_query_per_region_per_code.py → resource_environment_metrics_query_per_region_per_code.py} +5 -5
- beamlit/models/resource_environment_metrics_query_per_second_per_region_per_code.py +5 -3
- beamlit/models/resource_log.py +4 -2
- beamlit/models/runtime.py +20 -2
- beamlit/models/serverless_config.py +28 -21
- beamlit/models/spec_configuration.py +7 -5
- beamlit/models/store_agent.py +14 -14
- beamlit/models/store_function.py +14 -14
- beamlit/models/time_fields.py +4 -2
- beamlit/models/websocket_channel.py +4 -2
- beamlit/models/workspace.py +23 -14
- beamlit/run.py +0 -1
- beamlit/serve/app.py +1 -0
- beamlit/serve/middlewares/accesslog.py +3 -1
- {beamlit-0.0.24rc20.dist-info → beamlit-0.0.25.dist-info}/METADATA +1 -1
- beamlit-0.0.25.dist-info/RECORD +243 -0
- beamlit/api/agents/delete_agent_deployment.py +0 -163
- beamlit/api/agents/delete_agent_deployment_history.py +0 -172
- beamlit/api/agents/get_agent_deployment_history.py +0 -172
- beamlit/api/agents/get_agent_deployment_logs.py +0 -164
- beamlit/api/agents/list_agent_deployment_history.py +0 -164
- beamlit/api/agents/put_agent_deployment.py +0 -185
- beamlit/api/agents/put_agent_deployment_history.py +0 -198
- beamlit/api/functions/delete_function_deployment.py +0 -163
- beamlit/api/functions/get_function_deployment.py +0 -163
- beamlit/api/functions/get_function_deployment_logs.py +0 -164
- beamlit/api/functions/get_function_deployment_metrics.py +0 -159
- beamlit/api/functions/put_function_deployment.py +0 -185
- beamlit/api/models/delete_model_deployment.py +0 -171
- beamlit/api/models/get_model_deployment.py +0 -171
- beamlit/api/models/get_model_deployment_logs.py +0 -168
- beamlit/api/models/get_model_deployment_metrics.py +0 -163
- beamlit/api/models/put_model_deployment.py +0 -193
- beamlit/models/agent_configuration.py +0 -70
- beamlit/models/agent_deployment.py +0 -340
- beamlit/models/agent_deployment_configuration.py +0 -45
- beamlit/models/agent_deployment_configuration_type_0.py +0 -43
- beamlit/models/agent_deployment_history.py +0 -185
- beamlit/models/agent_deployment_history_event.py +0 -133
- beamlit/models/agent_deployment_pod_template.py +0 -45
- beamlit/models/agent_deployment_pod_template_type_0.py +0 -43
- beamlit/models/agent_with_deployments.py +0 -176
- beamlit/models/authentication_provider_model.py +0 -144
- beamlit/models/authentication_provider_organization.py +0 -88
- beamlit/models/deployment_configuration.py +0 -70
- beamlit/models/deployment_configurations.py +0 -58
- beamlit/models/deployment_serverless_config.py +0 -131
- beamlit/models/deployment_serverless_config_type_0.py +0 -220
- beamlit/models/function_configuration.py +0 -70
- beamlit/models/function_deployment.py +0 -340
- beamlit/models/function_deployment_configuration.py +0 -45
- beamlit/models/function_deployment_configuration_type_0.py +0 -43
- beamlit/models/function_deployment_pod_template.py +0 -45
- beamlit/models/function_deployment_pod_template_type_0.py +0 -43
- beamlit/models/function_with_deployments.py +0 -176
- beamlit/models/integration.py +0 -198
- beamlit/models/integration_config.py +0 -45
- beamlit/models/integration_secret.py +0 -61
- beamlit/models/labels_type_0.py +0 -45
- beamlit/models/location.py +0 -122
- beamlit/models/model_deployment.py +0 -296
- beamlit/models/model_deployment_log.py +0 -70
- beamlit/models/model_deployment_metrics.py +0 -172
- beamlit/models/model_deployment_metrics_inference_per_second_per_region.py +0 -77
- beamlit/models/model_deployment_pod_template.py +0 -45
- beamlit/models/model_deployment_pod_template_type_0.py +0 -43
- beamlit/models/model_metrics.py +0 -96
- beamlit/models/model_with_deployments.py +0 -176
- beamlit/models/resource_deployment_log.py +0 -70
- beamlit/models/resource_deployment_metrics_inference_per_region_type_0.py +0 -79
- beamlit/models/resource_deployment_metrics_inference_per_second_per_region_type_0.py +0 -79
- beamlit/models/resource_deployment_metrics_query_per_region_per_code_type_0.py +0 -73
- beamlit/models/resource_deployment_metrics_query_per_second_per_region_per_code_type_0.py +0 -73
- beamlit/models/runtime_readiness_probe_type_0.py +0 -43
- beamlit/models/runtime_type_0.py +0 -111
- beamlit/models/runtime_type_0_readiness_probe.py +0 -43
- beamlit/models/runtime_type_0_readiness_probe_type_0.py +0 -43
- beamlit/models/runtime_type_0_resources.py +0 -59
- beamlit/models/standard_fields_dynamo_db.py +0 -88
- beamlit/models/store_agent_configuration.py +0 -97
- beamlit/models/store_agent_labels_type_0.py +0 -43
- beamlit/models/store_function_configuration.py +0 -97
- beamlit/models/store_function_labels_type_0.py +0 -43
- beamlit-0.0.24rc20.dist-info/RECORD +0 -303
- {beamlit-0.0.24rc20.dist-info → beamlit-0.0.25.dist-info}/WHEEL +0 -0
@@ -1,5 +1,5 @@
|
|
1
1
|
from http import HTTPStatus
|
2
|
-
from typing import Any,
|
2
|
+
from typing import Any, Optional, Union
|
3
3
|
|
4
4
|
import httpx
|
5
5
|
|
@@ -22,7 +22,7 @@ def _get_kwargs(
|
|
22
22
|
|
23
23
|
def _parse_response(
|
24
24
|
*, client: Union[AuthenticatedClient, Client], response: httpx.Response
|
25
|
-
) -> Optional[
|
25
|
+
) -> Optional[list["ResourceLog"]]:
|
26
26
|
if response.status_code == 200:
|
27
27
|
response_200 = []
|
28
28
|
_response_200 = response.json()
|
@@ -40,7 +40,7 @@ def _parse_response(
|
|
40
40
|
|
41
41
|
def _build_response(
|
42
42
|
*, client: Union[AuthenticatedClient, Client], response: httpx.Response
|
43
|
-
) -> Response[
|
43
|
+
) -> Response[list["ResourceLog"]]:
|
44
44
|
return Response(
|
45
45
|
status_code=HTTPStatus(response.status_code),
|
46
46
|
content=response.content,
|
@@ -53,7 +53,7 @@ def sync_detailed(
|
|
53
53
|
agent_name: str,
|
54
54
|
*,
|
55
55
|
client: AuthenticatedClient,
|
56
|
-
) -> Response[
|
56
|
+
) -> Response[list["ResourceLog"]]:
|
57
57
|
"""
|
58
58
|
Args:
|
59
59
|
agent_name (str):
|
@@ -63,7 +63,7 @@ def sync_detailed(
|
|
63
63
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
64
64
|
|
65
65
|
Returns:
|
66
|
-
Response[
|
66
|
+
Response[list['ResourceLog']]
|
67
67
|
"""
|
68
68
|
|
69
69
|
kwargs = _get_kwargs(
|
@@ -81,7 +81,7 @@ def sync(
|
|
81
81
|
agent_name: str,
|
82
82
|
*,
|
83
83
|
client: AuthenticatedClient,
|
84
|
-
) -> Optional[
|
84
|
+
) -> Optional[list["ResourceLog"]]:
|
85
85
|
"""
|
86
86
|
Args:
|
87
87
|
agent_name (str):
|
@@ -91,7 +91,7 @@ def sync(
|
|
91
91
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
92
92
|
|
93
93
|
Returns:
|
94
|
-
|
94
|
+
list['ResourceLog']
|
95
95
|
"""
|
96
96
|
|
97
97
|
return sync_detailed(
|
@@ -104,7 +104,7 @@ async def asyncio_detailed(
|
|
104
104
|
agent_name: str,
|
105
105
|
*,
|
106
106
|
client: AuthenticatedClient,
|
107
|
-
) -> Response[
|
107
|
+
) -> Response[list["ResourceLog"]]:
|
108
108
|
"""
|
109
109
|
Args:
|
110
110
|
agent_name (str):
|
@@ -114,7 +114,7 @@ async def asyncio_detailed(
|
|
114
114
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
115
115
|
|
116
116
|
Returns:
|
117
|
-
Response[
|
117
|
+
Response[list['ResourceLog']]
|
118
118
|
"""
|
119
119
|
|
120
120
|
kwargs = _get_kwargs(
|
@@ -130,7 +130,7 @@ async def asyncio(
|
|
130
130
|
agent_name: str,
|
131
131
|
*,
|
132
132
|
client: AuthenticatedClient,
|
133
|
-
) -> Optional[
|
133
|
+
) -> Optional[list["ResourceLog"]]:
|
134
134
|
"""
|
135
135
|
Args:
|
136
136
|
agent_name (str):
|
@@ -140,7 +140,7 @@ async def asyncio(
|
|
140
140
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
141
141
|
|
142
142
|
Returns:
|
143
|
-
|
143
|
+
list['ResourceLog']
|
144
144
|
"""
|
145
145
|
|
146
146
|
return (
|
@@ -21,9 +21,7 @@ def _get_kwargs(
|
|
21
21
|
return _kwargs
|
22
22
|
|
23
23
|
|
24
|
-
def _parse_response(
|
25
|
-
*, client: Union[AuthenticatedClient, Client], response: httpx.Response
|
26
|
-
) -> Optional[AgentHistory]:
|
24
|
+
def _parse_response(*, client: Union[AuthenticatedClient, Client], response: httpx.Response) -> Optional[AgentHistory]:
|
27
25
|
if response.status_code == 200:
|
28
26
|
response_200 = AgentHistory.from_dict(response.json())
|
29
27
|
|
@@ -34,9 +32,7 @@ def _parse_response(
|
|
34
32
|
return None
|
35
33
|
|
36
34
|
|
37
|
-
def _build_response(
|
38
|
-
*, client: Union[AuthenticatedClient, Client], response: httpx.Response
|
39
|
-
) -> Response[AgentHistory]:
|
35
|
+
def _build_response(*, client: Union[AuthenticatedClient, Client], response: httpx.Response) -> Response[AgentHistory]:
|
40
36
|
return Response(
|
41
37
|
status_code=HTTPStatus(response.status_code),
|
42
38
|
content=response.content,
|
@@ -6,15 +6,24 @@ import httpx
|
|
6
6
|
from ... import errors
|
7
7
|
from ...client import AuthenticatedClient, Client
|
8
8
|
from ...models.resource_metrics import ResourceMetrics
|
9
|
-
from ...types import Response
|
9
|
+
from ...types import UNSET, Response, Unset
|
10
10
|
|
11
11
|
|
12
12
|
def _get_kwargs(
|
13
13
|
agent_name: str,
|
14
|
+
*,
|
15
|
+
environment: Union[Unset, str] = UNSET,
|
14
16
|
) -> dict[str, Any]:
|
17
|
+
params: dict[str, Any] = {}
|
18
|
+
|
19
|
+
params["environment"] = environment
|
20
|
+
|
21
|
+
params = {k: v for k, v in params.items() if v is not UNSET and v is not None}
|
22
|
+
|
15
23
|
_kwargs: dict[str, Any] = {
|
16
24
|
"method": "get",
|
17
25
|
"url": f"/agents/{agent_name}/metrics",
|
26
|
+
"params": params,
|
18
27
|
}
|
19
28
|
|
20
29
|
return _kwargs
|
@@ -48,11 +57,13 @@ def sync_detailed(
|
|
48
57
|
agent_name: str,
|
49
58
|
*,
|
50
59
|
client: AuthenticatedClient,
|
60
|
+
environment: Union[Unset, str] = UNSET,
|
51
61
|
) -> Response[ResourceMetrics]:
|
52
62
|
"""Get agent metrics
|
53
63
|
|
54
64
|
Args:
|
55
65
|
agent_name (str):
|
66
|
+
environment (Union[Unset, str]):
|
56
67
|
|
57
68
|
Raises:
|
58
69
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
@@ -64,6 +75,7 @@ def sync_detailed(
|
|
64
75
|
|
65
76
|
kwargs = _get_kwargs(
|
66
77
|
agent_name=agent_name,
|
78
|
+
environment=environment,
|
67
79
|
)
|
68
80
|
|
69
81
|
response = client.get_httpx_client().request(
|
@@ -77,11 +89,13 @@ def sync(
|
|
77
89
|
agent_name: str,
|
78
90
|
*,
|
79
91
|
client: AuthenticatedClient,
|
92
|
+
environment: Union[Unset, str] = UNSET,
|
80
93
|
) -> Optional[ResourceMetrics]:
|
81
94
|
"""Get agent metrics
|
82
95
|
|
83
96
|
Args:
|
84
97
|
agent_name (str):
|
98
|
+
environment (Union[Unset, str]):
|
85
99
|
|
86
100
|
Raises:
|
87
101
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
@@ -94,6 +108,7 @@ def sync(
|
|
94
108
|
return sync_detailed(
|
95
109
|
agent_name=agent_name,
|
96
110
|
client=client,
|
111
|
+
environment=environment,
|
97
112
|
).parsed
|
98
113
|
|
99
114
|
|
@@ -101,11 +116,13 @@ async def asyncio_detailed(
|
|
101
116
|
agent_name: str,
|
102
117
|
*,
|
103
118
|
client: AuthenticatedClient,
|
119
|
+
environment: Union[Unset, str] = UNSET,
|
104
120
|
) -> Response[ResourceMetrics]:
|
105
121
|
"""Get agent metrics
|
106
122
|
|
107
123
|
Args:
|
108
124
|
agent_name (str):
|
125
|
+
environment (Union[Unset, str]):
|
109
126
|
|
110
127
|
Raises:
|
111
128
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
@@ -117,6 +134,7 @@ async def asyncio_detailed(
|
|
117
134
|
|
118
135
|
kwargs = _get_kwargs(
|
119
136
|
agent_name=agent_name,
|
137
|
+
environment=environment,
|
120
138
|
)
|
121
139
|
|
122
140
|
response = await client.get_async_httpx_client().request(**kwargs)
|
@@ -128,11 +146,13 @@ async def asyncio(
|
|
128
146
|
agent_name: str,
|
129
147
|
*,
|
130
148
|
client: AuthenticatedClient,
|
149
|
+
environment: Union[Unset, str] = UNSET,
|
131
150
|
) -> Optional[ResourceMetrics]:
|
132
151
|
"""Get agent metrics
|
133
152
|
|
134
153
|
Args:
|
135
154
|
agent_name (str):
|
155
|
+
environment (Union[Unset, str]):
|
136
156
|
|
137
157
|
Raises:
|
138
158
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
@@ -146,5 +166,6 @@ async def asyncio(
|
|
146
166
|
await asyncio_detailed(
|
147
167
|
agent_name=agent_name,
|
148
168
|
client=client,
|
169
|
+
environment=environment,
|
149
170
|
)
|
150
171
|
).parsed
|
@@ -1,5 +1,5 @@
|
|
1
1
|
from http import HTTPStatus
|
2
|
-
from typing import Any,
|
2
|
+
from typing import Any, Optional, Union
|
3
3
|
|
4
4
|
import httpx
|
5
5
|
|
@@ -22,7 +22,7 @@ def _get_kwargs(
|
|
22
22
|
|
23
23
|
def _parse_response(
|
24
24
|
*, client: Union[AuthenticatedClient, Client], response: httpx.Response
|
25
|
-
) -> Optional[
|
25
|
+
) -> Optional[list["AgentHistory"]]:
|
26
26
|
if response.status_code == 200:
|
27
27
|
response_200 = []
|
28
28
|
_response_200 = response.json()
|
@@ -40,7 +40,7 @@ def _parse_response(
|
|
40
40
|
|
41
41
|
def _build_response(
|
42
42
|
*, client: Union[AuthenticatedClient, Client], response: httpx.Response
|
43
|
-
) -> Response[
|
43
|
+
) -> Response[list["AgentHistory"]]:
|
44
44
|
return Response(
|
45
45
|
status_code=HTTPStatus(response.status_code),
|
46
46
|
content=response.content,
|
@@ -53,7 +53,7 @@ def sync_detailed(
|
|
53
53
|
agent_name: str,
|
54
54
|
*,
|
55
55
|
client: AuthenticatedClient,
|
56
|
-
) -> Response[
|
56
|
+
) -> Response[list["AgentHistory"]]:
|
57
57
|
"""
|
58
58
|
Args:
|
59
59
|
agent_name (str):
|
@@ -63,7 +63,7 @@ def sync_detailed(
|
|
63
63
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
64
64
|
|
65
65
|
Returns:
|
66
|
-
Response[
|
66
|
+
Response[list['AgentHistory']]
|
67
67
|
"""
|
68
68
|
|
69
69
|
kwargs = _get_kwargs(
|
@@ -81,7 +81,7 @@ def sync(
|
|
81
81
|
agent_name: str,
|
82
82
|
*,
|
83
83
|
client: AuthenticatedClient,
|
84
|
-
) -> Optional[
|
84
|
+
) -> Optional[list["AgentHistory"]]:
|
85
85
|
"""
|
86
86
|
Args:
|
87
87
|
agent_name (str):
|
@@ -91,7 +91,7 @@ def sync(
|
|
91
91
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
92
92
|
|
93
93
|
Returns:
|
94
|
-
|
94
|
+
list['AgentHistory']
|
95
95
|
"""
|
96
96
|
|
97
97
|
return sync_detailed(
|
@@ -104,7 +104,7 @@ async def asyncio_detailed(
|
|
104
104
|
agent_name: str,
|
105
105
|
*,
|
106
106
|
client: AuthenticatedClient,
|
107
|
-
) -> Response[
|
107
|
+
) -> Response[list["AgentHistory"]]:
|
108
108
|
"""
|
109
109
|
Args:
|
110
110
|
agent_name (str):
|
@@ -114,7 +114,7 @@ async def asyncio_detailed(
|
|
114
114
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
115
115
|
|
116
116
|
Returns:
|
117
|
-
Response[
|
117
|
+
Response[list['AgentHistory']]
|
118
118
|
"""
|
119
119
|
|
120
120
|
kwargs = _get_kwargs(
|
@@ -130,7 +130,7 @@ async def asyncio(
|
|
130
130
|
agent_name: str,
|
131
131
|
*,
|
132
132
|
client: AuthenticatedClient,
|
133
|
-
) -> Optional[
|
133
|
+
) -> Optional[list["AgentHistory"]]:
|
134
134
|
"""
|
135
135
|
Args:
|
136
136
|
agent_name (str):
|
@@ -140,7 +140,7 @@ async def asyncio(
|
|
140
140
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
141
141
|
|
142
142
|
Returns:
|
143
|
-
|
143
|
+
list['AgentHistory']
|
144
144
|
"""
|
145
145
|
|
146
146
|
return (
|
@@ -6,13 +6,23 @@ import httpx
|
|
6
6
|
from ... import errors
|
7
7
|
from ...client import AuthenticatedClient, Client
|
8
8
|
from ...models.agent import Agent
|
9
|
-
from ...types import Response
|
9
|
+
from ...types import UNSET, Response, Unset
|
10
10
|
|
11
11
|
|
12
|
-
def _get_kwargs(
|
12
|
+
def _get_kwargs(
|
13
|
+
*,
|
14
|
+
environment: Union[Unset, str] = UNSET,
|
15
|
+
) -> dict[str, Any]:
|
16
|
+
params: dict[str, Any] = {}
|
17
|
+
|
18
|
+
params["environment"] = environment
|
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": "/agents",
|
25
|
+
"params": params,
|
16
26
|
}
|
17
27
|
|
18
28
|
return _kwargs
|
@@ -46,9 +56,13 @@ def _build_response(*, client: Union[AuthenticatedClient, Client], response: htt
|
|
46
56
|
def sync_detailed(
|
47
57
|
*,
|
48
58
|
client: AuthenticatedClient,
|
59
|
+
environment: Union[Unset, str] = UNSET,
|
49
60
|
) -> Response[list["Agent"]]:
|
50
61
|
"""List all agents
|
51
62
|
|
63
|
+
Args:
|
64
|
+
environment (Union[Unset, str]):
|
65
|
+
|
52
66
|
Raises:
|
53
67
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
54
68
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
@@ -57,7 +71,9 @@ def sync_detailed(
|
|
57
71
|
Response[list['Agent']]
|
58
72
|
"""
|
59
73
|
|
60
|
-
kwargs = _get_kwargs(
|
74
|
+
kwargs = _get_kwargs(
|
75
|
+
environment=environment,
|
76
|
+
)
|
61
77
|
|
62
78
|
response = client.get_httpx_client().request(
|
63
79
|
**kwargs,
|
@@ -69,9 +85,13 @@ def sync_detailed(
|
|
69
85
|
def sync(
|
70
86
|
*,
|
71
87
|
client: AuthenticatedClient,
|
88
|
+
environment: Union[Unset, str] = UNSET,
|
72
89
|
) -> Optional[list["Agent"]]:
|
73
90
|
"""List all agents
|
74
91
|
|
92
|
+
Args:
|
93
|
+
environment (Union[Unset, str]):
|
94
|
+
|
75
95
|
Raises:
|
76
96
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
77
97
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
@@ -82,15 +102,20 @@ def sync(
|
|
82
102
|
|
83
103
|
return sync_detailed(
|
84
104
|
client=client,
|
105
|
+
environment=environment,
|
85
106
|
).parsed
|
86
107
|
|
87
108
|
|
88
109
|
async def asyncio_detailed(
|
89
110
|
*,
|
90
111
|
client: AuthenticatedClient,
|
112
|
+
environment: Union[Unset, str] = UNSET,
|
91
113
|
) -> Response[list["Agent"]]:
|
92
114
|
"""List all agents
|
93
115
|
|
116
|
+
Args:
|
117
|
+
environment (Union[Unset, str]):
|
118
|
+
|
94
119
|
Raises:
|
95
120
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
96
121
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
@@ -99,7 +124,9 @@ async def asyncio_detailed(
|
|
99
124
|
Response[list['Agent']]
|
100
125
|
"""
|
101
126
|
|
102
|
-
kwargs = _get_kwargs(
|
127
|
+
kwargs = _get_kwargs(
|
128
|
+
environment=environment,
|
129
|
+
)
|
103
130
|
|
104
131
|
response = await client.get_async_httpx_client().request(**kwargs)
|
105
132
|
|
@@ -109,9 +136,13 @@ async def asyncio_detailed(
|
|
109
136
|
async def asyncio(
|
110
137
|
*,
|
111
138
|
client: AuthenticatedClient,
|
139
|
+
environment: Union[Unset, str] = UNSET,
|
112
140
|
) -> Optional[list["Agent"]]:
|
113
141
|
"""List all agents
|
114
142
|
|
143
|
+
Args:
|
144
|
+
environment (Union[Unset, str]):
|
145
|
+
|
115
146
|
Raises:
|
116
147
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
117
148
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
@@ -123,5 +154,6 @@ async def asyncio(
|
|
123
154
|
return (
|
124
155
|
await asyncio_detailed(
|
125
156
|
client=client,
|
157
|
+
environment=environment,
|
126
158
|
)
|
127
159
|
).parsed
|
@@ -31,9 +31,7 @@ def _get_kwargs(
|
|
31
31
|
return _kwargs
|
32
32
|
|
33
33
|
|
34
|
-
def _parse_response(
|
35
|
-
*, client: Union[AuthenticatedClient, Client], response: httpx.Response
|
36
|
-
) -> Optional[AgentHistory]:
|
34
|
+
def _parse_response(*, client: Union[AuthenticatedClient, Client], response: httpx.Response) -> Optional[AgentHistory]:
|
37
35
|
if response.status_code == 200:
|
38
36
|
response_200 = AgentHistory.from_dict(response.json())
|
39
37
|
|
@@ -44,9 +42,7 @@ def _parse_response(
|
|
44
42
|
return None
|
45
43
|
|
46
44
|
|
47
|
-
def _build_response(
|
48
|
-
*, client: Union[AuthenticatedClient, Client], response: httpx.Response
|
49
|
-
) -> Response[AgentHistory]:
|
45
|
+
def _build_response(*, client: Union[AuthenticatedClient, Client], response: httpx.Response) -> Response[AgentHistory]:
|
50
46
|
return Response(
|
51
47
|
status_code=HTTPStatus(response.status_code),
|
52
48
|
content=response.content,
|
@@ -6,14 +6,13 @@ import httpx
|
|
6
6
|
from ... import errors
|
7
7
|
from ...client import AuthenticatedClient, Client
|
8
8
|
from ...models.agent import Agent
|
9
|
-
from ...models.agent_with_deployments import AgentWithDeployments
|
10
9
|
from ...types import Response
|
11
10
|
|
12
11
|
|
13
12
|
def _get_kwargs(
|
14
13
|
agent_name: str,
|
15
14
|
*,
|
16
|
-
body:
|
15
|
+
body: Agent,
|
17
16
|
) -> dict[str, Any]:
|
18
17
|
headers: dict[str, Any] = {}
|
19
18
|
|
@@ -55,14 +54,13 @@ def sync_detailed(
|
|
55
54
|
agent_name: str,
|
56
55
|
*,
|
57
56
|
client: AuthenticatedClient,
|
58
|
-
body:
|
57
|
+
body: Agent,
|
59
58
|
) -> Response[Agent]:
|
60
59
|
"""Update agent by name
|
61
60
|
|
62
61
|
Args:
|
63
62
|
agent_name (str):
|
64
|
-
body (
|
65
|
-
definition inside
|
63
|
+
body (Agent): Agent
|
66
64
|
|
67
65
|
Raises:
|
68
66
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
@@ -88,14 +86,13 @@ def sync(
|
|
88
86
|
agent_name: str,
|
89
87
|
*,
|
90
88
|
client: AuthenticatedClient,
|
91
|
-
body:
|
89
|
+
body: Agent,
|
92
90
|
) -> Optional[Agent]:
|
93
91
|
"""Update agent by name
|
94
92
|
|
95
93
|
Args:
|
96
94
|
agent_name (str):
|
97
|
-
body (
|
98
|
-
definition inside
|
95
|
+
body (Agent): Agent
|
99
96
|
|
100
97
|
Raises:
|
101
98
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
@@ -116,14 +113,13 @@ async def asyncio_detailed(
|
|
116
113
|
agent_name: str,
|
117
114
|
*,
|
118
115
|
client: AuthenticatedClient,
|
119
|
-
body:
|
116
|
+
body: Agent,
|
120
117
|
) -> Response[Agent]:
|
121
118
|
"""Update agent by name
|
122
119
|
|
123
120
|
Args:
|
124
121
|
agent_name (str):
|
125
|
-
body (
|
126
|
-
definition inside
|
122
|
+
body (Agent): Agent
|
127
123
|
|
128
124
|
Raises:
|
129
125
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
@@ -147,14 +143,13 @@ async def asyncio(
|
|
147
143
|
agent_name: str,
|
148
144
|
*,
|
149
145
|
client: AuthenticatedClient,
|
150
|
-
body:
|
146
|
+
body: Agent,
|
151
147
|
) -> Optional[Agent]:
|
152
148
|
"""Update agent by name
|
153
149
|
|
154
150
|
Args:
|
155
151
|
agent_name (str):
|
156
|
-
body (
|
157
|
-
definition inside
|
152
|
+
body (Agent): Agent
|
158
153
|
|
159
154
|
Raises:
|
160
155
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
@@ -6,13 +6,12 @@ import httpx
|
|
6
6
|
from ... import errors
|
7
7
|
from ...client import AuthenticatedClient, Client
|
8
8
|
from ...models.function import Function
|
9
|
-
from ...models.function_with_deployments import FunctionWithDeployments
|
10
9
|
from ...types import Response
|
11
10
|
|
12
11
|
|
13
12
|
def _get_kwargs(
|
14
13
|
*,
|
15
|
-
body:
|
14
|
+
body: Function,
|
16
15
|
) -> dict[str, Any]:
|
17
16
|
headers: dict[str, Any] = {}
|
18
17
|
|
@@ -53,13 +52,12 @@ def _build_response(*, client: Union[AuthenticatedClient, Client], response: htt
|
|
53
52
|
def sync_detailed(
|
54
53
|
*,
|
55
54
|
client: AuthenticatedClient,
|
56
|
-
body:
|
55
|
+
body: Function,
|
57
56
|
) -> Response[Function]:
|
58
57
|
"""Create function
|
59
58
|
|
60
59
|
Args:
|
61
|
-
body (
|
62
|
-
definition inside
|
60
|
+
body (Function): Function
|
63
61
|
|
64
62
|
Raises:
|
65
63
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
@@ -83,13 +81,12 @@ def sync_detailed(
|
|
83
81
|
def sync(
|
84
82
|
*,
|
85
83
|
client: AuthenticatedClient,
|
86
|
-
body:
|
84
|
+
body: Function,
|
87
85
|
) -> Optional[Function]:
|
88
86
|
"""Create function
|
89
87
|
|
90
88
|
Args:
|
91
|
-
body (
|
92
|
-
definition inside
|
89
|
+
body (Function): Function
|
93
90
|
|
94
91
|
Raises:
|
95
92
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
@@ -108,13 +105,12 @@ def sync(
|
|
108
105
|
async def asyncio_detailed(
|
109
106
|
*,
|
110
107
|
client: AuthenticatedClient,
|
111
|
-
body:
|
108
|
+
body: Function,
|
112
109
|
) -> Response[Function]:
|
113
110
|
"""Create function
|
114
111
|
|
115
112
|
Args:
|
116
|
-
body (
|
117
|
-
definition inside
|
113
|
+
body (Function): Function
|
118
114
|
|
119
115
|
Raises:
|
120
116
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
@@ -136,13 +132,12 @@ async def asyncio_detailed(
|
|
136
132
|
async def asyncio(
|
137
133
|
*,
|
138
134
|
client: AuthenticatedClient,
|
139
|
-
body:
|
135
|
+
body: Function,
|
140
136
|
) -> Optional[Function]:
|
141
137
|
"""Create function
|
142
138
|
|
143
139
|
Args:
|
144
|
-
body (
|
145
|
-
definition inside
|
140
|
+
body (Function): Function
|
146
141
|
|
147
142
|
Raises:
|
148
143
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|