|
15 | 15 | RunsResourceWithStreamingResponse, |
16 | 16 | AsyncRunsResourceWithStreamingResponse, |
17 | 17 | ) |
18 | | -from ...types import agent_run_params, agent_list_params, agent_list_environments_params |
| 18 | +from ...types import agent_run_params, agent_list_params |
19 | 19 | from ..._types import Body, Omit, Query, Headers, NotGiven, omit, not_given |
20 | 20 | from ..._utils import path_template, maybe_transform, async_maybe_transform |
21 | 21 | from .sessions import ( |
|
47 | 47 | from ...types.agent_list_response import AgentListResponse |
48 | 48 | from ...types.ambient_agent_config_param import AmbientAgentConfigParam |
49 | 49 | from ...types.agent_get_artifact_response import AgentGetArtifactResponse |
50 | | -from ...types.agent_list_environments_response import AgentListEnvironmentsResponse |
51 | 50 |
|
52 | 51 | __all__ = ["AgentResource", "AsyncAgentResource"] |
53 | 52 |
|
@@ -191,49 +190,6 @@ def get_artifact( |
191 | 190 | ), |
192 | 191 | ) |
193 | 192 |
|
194 | | - def list_environments( |
195 | | - self, |
196 | | - *, |
197 | | - sort_by: Literal["name", "last_updated"] | Omit = omit, |
198 | | - # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs. |
199 | | - # The extra values given here take precedence over values defined on the client or passed to this method. |
200 | | - extra_headers: Headers | None = None, |
201 | | - extra_query: Query | None = None, |
202 | | - extra_body: Body | None = None, |
203 | | - timeout: float | httpx.Timeout | None | NotGiven = not_given, |
204 | | - ) -> AgentListEnvironmentsResponse: |
205 | | - """Retrieve cloud environments accessible to the authenticated principal. |
206 | | -
|
207 | | - Returns |
208 | | - environments the caller owns, has been granted guest access to, or has accessed |
209 | | - via link sharing. |
210 | | -
|
211 | | - Args: |
212 | | - sort_by: Sort order for the returned environments. |
213 | | -
|
214 | | - - `name`: alphabetical by environment name |
215 | | - - `last_updated`: most recently updated first (default) |
216 | | -
|
217 | | - extra_headers: Send extra headers |
218 | | -
|
219 | | - extra_query: Add additional query parameters to the request |
220 | | -
|
221 | | - extra_body: Add additional JSON properties to the request |
222 | | -
|
223 | | - timeout: Override the client-level default timeout for this request, in seconds |
224 | | - """ |
225 | | - return self._get( |
226 | | - "/agent/environments", |
227 | | - options=make_request_options( |
228 | | - extra_headers=extra_headers, |
229 | | - extra_query=extra_query, |
230 | | - extra_body=extra_body, |
231 | | - timeout=timeout, |
232 | | - query=maybe_transform({"sort_by": sort_by}, agent_list_environments_params.AgentListEnvironmentsParams), |
233 | | - ), |
234 | | - cast_to=AgentListEnvironmentsResponse, |
235 | | - ) |
236 | | - |
237 | 193 | def run( |
238 | 194 | self, |
239 | 195 | *, |
@@ -463,51 +419,6 @@ async def get_artifact( |
463 | 419 | ), |
464 | 420 | ) |
465 | 421 |
|
466 | | - async def list_environments( |
467 | | - self, |
468 | | - *, |
469 | | - sort_by: Literal["name", "last_updated"] | Omit = omit, |
470 | | - # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs. |
471 | | - # The extra values given here take precedence over values defined on the client or passed to this method. |
472 | | - extra_headers: Headers | None = None, |
473 | | - extra_query: Query | None = None, |
474 | | - extra_body: Body | None = None, |
475 | | - timeout: float | httpx.Timeout | None | NotGiven = not_given, |
476 | | - ) -> AgentListEnvironmentsResponse: |
477 | | - """Retrieve cloud environments accessible to the authenticated principal. |
478 | | -
|
479 | | - Returns |
480 | | - environments the caller owns, has been granted guest access to, or has accessed |
481 | | - via link sharing. |
482 | | -
|
483 | | - Args: |
484 | | - sort_by: Sort order for the returned environments. |
485 | | -
|
486 | | - - `name`: alphabetical by environment name |
487 | | - - `last_updated`: most recently updated first (default) |
488 | | -
|
489 | | - extra_headers: Send extra headers |
490 | | -
|
491 | | - extra_query: Add additional query parameters to the request |
492 | | -
|
493 | | - extra_body: Add additional JSON properties to the request |
494 | | -
|
495 | | - timeout: Override the client-level default timeout for this request, in seconds |
496 | | - """ |
497 | | - return await self._get( |
498 | | - "/agent/environments", |
499 | | - options=make_request_options( |
500 | | - extra_headers=extra_headers, |
501 | | - extra_query=extra_query, |
502 | | - extra_body=extra_body, |
503 | | - timeout=timeout, |
504 | | - query=await async_maybe_transform( |
505 | | - {"sort_by": sort_by}, agent_list_environments_params.AgentListEnvironmentsParams |
506 | | - ), |
507 | | - ), |
508 | | - cast_to=AgentListEnvironmentsResponse, |
509 | | - ) |
510 | | - |
511 | 422 | async def run( |
512 | 423 | self, |
513 | 424 | *, |
@@ -608,9 +519,6 @@ def __init__(self, agent: AgentResource) -> None: |
608 | 519 | self.get_artifact = to_raw_response_wrapper( |
609 | 520 | agent.get_artifact, |
610 | 521 | ) |
611 | | - self.list_environments = to_raw_response_wrapper( |
612 | | - agent.list_environments, |
613 | | - ) |
614 | 522 | self.run = to_raw_response_wrapper( |
615 | 523 | agent.run, |
616 | 524 | ) |
@@ -641,9 +549,6 @@ def __init__(self, agent: AsyncAgentResource) -> None: |
641 | 549 | self.get_artifact = async_to_raw_response_wrapper( |
642 | 550 | agent.get_artifact, |
643 | 551 | ) |
644 | | - self.list_environments = async_to_raw_response_wrapper( |
645 | | - agent.list_environments, |
646 | | - ) |
647 | 552 | self.run = async_to_raw_response_wrapper( |
648 | 553 | agent.run, |
649 | 554 | ) |
@@ -674,9 +579,6 @@ def __init__(self, agent: AgentResource) -> None: |
674 | 579 | self.get_artifact = to_streamed_response_wrapper( |
675 | 580 | agent.get_artifact, |
676 | 581 | ) |
677 | | - self.list_environments = to_streamed_response_wrapper( |
678 | | - agent.list_environments, |
679 | | - ) |
680 | 582 | self.run = to_streamed_response_wrapper( |
681 | 583 | agent.run, |
682 | 584 | ) |
@@ -707,9 +609,6 @@ def __init__(self, agent: AsyncAgentResource) -> None: |
707 | 609 | self.get_artifact = async_to_streamed_response_wrapper( |
708 | 610 | agent.get_artifact, |
709 | 611 | ) |
710 | | - self.list_environments = async_to_streamed_response_wrapper( |
711 | | - agent.list_environments, |
712 | | - ) |
713 | 612 | self.run = async_to_streamed_response_wrapper( |
714 | 613 | agent.run, |
715 | 614 | ) |
|
0 commit comments