raccoonai 0.1.0a8__py3-none-any.whl → 0.1.0a10__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.
Potentially problematic release.
This version of raccoonai might be problematic. Click here for more details.
- raccoonai/_base_client.py +1 -96
- raccoonai/_client.py +2 -9
- raccoonai/_version.py +1 -1
- raccoonai/resources/__init__.py +0 -14
- raccoonai/resources/fleet/__init__.py +47 -0
- raccoonai/resources/{extensions.py → fleet/extensions.py} +10 -10
- raccoonai/resources/fleet/fleet.py +134 -0
- raccoonai/resources/{fleet.py → fleet/sessions.py} +234 -151
- raccoonai/resources/lam/__init__.py +33 -0
- raccoonai/resources/{lam.py → lam/lam.py} +42 -173
- raccoonai/resources/lam/tasks.py +338 -0
- raccoonai/resources/tail/__init__.py +14 -14
- raccoonai/resources/tail/tail.py +27 -166
- raccoonai/resources/tail/users.py +405 -0
- raccoonai/types/__init__.py +0 -15
- raccoonai/types/fleet/__init__.py +16 -0
- raccoonai/types/{extension_all_response.py → fleet/extension_all_response.py} +1 -1
- raccoonai/types/{extension_get_response.py → fleet/extension_get_response.py} +1 -1
- raccoonai/types/{extension_upload_params.py → fleet/extension_upload_params.py} +1 -1
- raccoonai/types/{extension_upload_response.py → fleet/extension_upload_response.py} +1 -1
- raccoonai/types/{fleet_sessions_params.py → fleet/session_all_params.py} +3 -3
- raccoonai/types/{fleet_sessions_response.py → fleet/session_all_response.py} +3 -3
- raccoonai/types/{fleet_create_params.py → fleet/session_create_params.py} +2 -2
- raccoonai/types/{fleet_create_response.py → fleet/session_create_response.py} +3 -3
- raccoonai/types/{fleet_logs_response.py → fleet/session_logs_response.py} +3 -3
- raccoonai/types/fleet/session_media_response.py +42 -0
- raccoonai/types/{fleet_status_response.py → fleet/session_status_response.py} +3 -3
- raccoonai/types/{fleet_terminate_response.py → fleet/session_terminate_response.py} +3 -3
- raccoonai/types/lam/__init__.py +7 -0
- raccoonai/types/{lam_tasks_params.py → lam/task_all_params.py} +3 -3
- raccoonai/types/{lam_tasks_response.py → lam/task_all_response.py} +3 -3
- raccoonai/types/lam/task_media_response.py +50 -0
- raccoonai/types/tail/__init__.py +6 -2
- raccoonai/types/{tail_users_params.py → tail/user_all_params.py} +3 -3
- raccoonai/types/{tail_users_response.py → tail/user_all_response.py} +3 -3
- raccoonai/types/tail/user_create_params.py +15 -0
- raccoonai/types/tail/user_create_response.py +22 -0
- raccoonai/types/tail/{auth_status_params.py → user_status_params.py} +2 -2
- raccoonai/types/tail/{auth_status_response.py → user_status_response.py} +2 -2
- {raccoonai-0.1.0a8.dist-info → raccoonai-0.1.0a10.dist-info}/METADATA +2 -2
- raccoonai-0.1.0a10.dist-info/RECORD +71 -0
- raccoonai/resources/tail/auth.py +0 -186
- raccoonai-0.1.0a8.dist-info/RECORD +0 -61
- {raccoonai-0.1.0a8.dist-info → raccoonai-0.1.0a10.dist-info}/WHEEL +0 -0
- {raccoonai-0.1.0a8.dist-info → raccoonai-0.1.0a10.dist-info}/licenses/LICENSE +0 -0
|
@@ -7,59 +7,60 @@ from typing_extensions import Literal
|
|
|
7
7
|
|
|
8
8
|
import httpx
|
|
9
9
|
|
|
10
|
-
from
|
|
11
|
-
from
|
|
12
|
-
from .._utils import (
|
|
10
|
+
from ..._types import NOT_GIVEN, Body, Query, Headers, NotGiven
|
|
11
|
+
from ..._utils import (
|
|
13
12
|
maybe_transform,
|
|
14
13
|
async_maybe_transform,
|
|
15
14
|
)
|
|
16
|
-
from
|
|
17
|
-
from
|
|
18
|
-
from
|
|
15
|
+
from ..._compat import cached_property
|
|
16
|
+
from ..._resource import SyncAPIResource, AsyncAPIResource
|
|
17
|
+
from ..._response import (
|
|
19
18
|
to_raw_response_wrapper,
|
|
20
19
|
to_streamed_response_wrapper,
|
|
21
20
|
async_to_raw_response_wrapper,
|
|
22
21
|
async_to_streamed_response_wrapper,
|
|
23
22
|
)
|
|
24
|
-
from
|
|
25
|
-
from
|
|
26
|
-
from
|
|
27
|
-
from
|
|
28
|
-
from
|
|
29
|
-
from
|
|
23
|
+
from ...types.fleet import session_all_params, session_create_params
|
|
24
|
+
from ..._base_client import make_request_options
|
|
25
|
+
from ...types.fleet.session_all_response import SessionAllResponse
|
|
26
|
+
from ...types.fleet.session_logs_response import SessionLogsResponse
|
|
27
|
+
from ...types.fleet.session_media_response import SessionMediaResponse
|
|
28
|
+
from ...types.fleet.session_create_response import SessionCreateResponse
|
|
29
|
+
from ...types.fleet.session_status_response import SessionStatusResponse
|
|
30
|
+
from ...types.fleet.session_terminate_response import SessionTerminateResponse
|
|
30
31
|
|
|
31
|
-
__all__ = ["
|
|
32
|
+
__all__ = ["SessionsResource", "AsyncSessionsResource"]
|
|
32
33
|
|
|
33
34
|
|
|
34
|
-
class
|
|
35
|
+
class SessionsResource(SyncAPIResource):
|
|
35
36
|
@cached_property
|
|
36
|
-
def with_raw_response(self) ->
|
|
37
|
+
def with_raw_response(self) -> SessionsResourceWithRawResponse:
|
|
37
38
|
"""
|
|
38
39
|
This property can be used as a prefix for any HTTP method call to return
|
|
39
40
|
the raw response object instead of the parsed content.
|
|
40
41
|
|
|
41
42
|
For more information, see https://www.github.com/raccoonaihq/raccoonai-python#accessing-raw-response-data-eg-headers
|
|
42
43
|
"""
|
|
43
|
-
return
|
|
44
|
+
return SessionsResourceWithRawResponse(self)
|
|
44
45
|
|
|
45
46
|
@cached_property
|
|
46
|
-
def with_streaming_response(self) ->
|
|
47
|
+
def with_streaming_response(self) -> SessionsResourceWithStreamingResponse:
|
|
47
48
|
"""
|
|
48
49
|
An alternative to `.with_raw_response` that doesn't eagerly read the response body.
|
|
49
50
|
|
|
50
51
|
For more information, see https://www.github.com/raccoonaihq/raccoonai-python#with_streaming_response
|
|
51
52
|
"""
|
|
52
|
-
return
|
|
53
|
+
return SessionsResourceWithStreamingResponse(self)
|
|
53
54
|
|
|
54
55
|
def create(
|
|
55
56
|
self,
|
|
56
57
|
*,
|
|
57
|
-
advanced: Optional[
|
|
58
|
+
advanced: Optional[session_create_params.Advanced] | NotGiven = NOT_GIVEN,
|
|
58
59
|
browser_type: Optional[Literal["chromium", "firefox", "webkit"]] | NotGiven = NOT_GIVEN,
|
|
59
60
|
headless: Optional[bool] | NotGiven = NOT_GIVEN,
|
|
60
61
|
raccoon_passcode: Optional[str] | NotGiven = NOT_GIVEN,
|
|
61
62
|
session_timeout: Optional[int] | NotGiven = NOT_GIVEN,
|
|
62
|
-
settings: Optional[
|
|
63
|
+
settings: Optional[session_create_params.Settings] | NotGiven = NOT_GIVEN,
|
|
63
64
|
url: Optional[str] | NotGiven = NOT_GIVEN,
|
|
64
65
|
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
65
66
|
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
@@ -67,7 +68,7 @@ class FleetResource(SyncAPIResource):
|
|
|
67
68
|
extra_query: Query | None = None,
|
|
68
69
|
extra_body: Body | None = None,
|
|
69
70
|
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
|
|
70
|
-
) ->
|
|
71
|
+
) -> SessionCreateResponse:
|
|
71
72
|
"""
|
|
72
73
|
Fleet Websocket Session Create Endpoint
|
|
73
74
|
|
|
@@ -110,48 +111,15 @@ class FleetResource(SyncAPIResource):
|
|
|
110
111
|
"settings": settings,
|
|
111
112
|
"url": url,
|
|
112
113
|
},
|
|
113
|
-
|
|
114
|
+
session_create_params.SessionCreateParams,
|
|
114
115
|
),
|
|
115
116
|
options=make_request_options(
|
|
116
117
|
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
117
118
|
),
|
|
118
|
-
cast_to=
|
|
119
|
+
cast_to=SessionCreateResponse,
|
|
119
120
|
)
|
|
120
121
|
|
|
121
|
-
def
|
|
122
|
-
self,
|
|
123
|
-
session_id: str,
|
|
124
|
-
*,
|
|
125
|
-
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
126
|
-
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
127
|
-
extra_headers: Headers | None = None,
|
|
128
|
-
extra_query: Query | None = None,
|
|
129
|
-
extra_body: Body | None = None,
|
|
130
|
-
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
|
|
131
|
-
) -> FleetLogsResponse:
|
|
132
|
-
"""
|
|
133
|
-
Fleet Session Logs Endpoint
|
|
134
|
-
|
|
135
|
-
Args:
|
|
136
|
-
extra_headers: Send extra headers
|
|
137
|
-
|
|
138
|
-
extra_query: Add additional query parameters to the request
|
|
139
|
-
|
|
140
|
-
extra_body: Add additional JSON properties to the request
|
|
141
|
-
|
|
142
|
-
timeout: Override the client-level default timeout for this request, in seconds
|
|
143
|
-
"""
|
|
144
|
-
if not session_id:
|
|
145
|
-
raise ValueError(f"Expected a non-empty value for `session_id` but received {session_id!r}")
|
|
146
|
-
return self._get(
|
|
147
|
-
f"/sessions/{session_id}/logs",
|
|
148
|
-
options=make_request_options(
|
|
149
|
-
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
150
|
-
),
|
|
151
|
-
cast_to=FleetLogsResponse,
|
|
152
|
-
)
|
|
153
|
-
|
|
154
|
-
def sessions(
|
|
122
|
+
def all(
|
|
155
123
|
self,
|
|
156
124
|
*,
|
|
157
125
|
end_time: Optional[int] | NotGiven = NOT_GIVEN,
|
|
@@ -171,7 +139,7 @@ class FleetResource(SyncAPIResource):
|
|
|
171
139
|
extra_query: Query | None = None,
|
|
172
140
|
extra_body: Body | None = None,
|
|
173
141
|
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
|
|
174
|
-
) ->
|
|
142
|
+
) -> SessionAllResponse:
|
|
175
143
|
"""
|
|
176
144
|
Get Sessions Endpoint
|
|
177
145
|
|
|
@@ -224,10 +192,78 @@ class FleetResource(SyncAPIResource):
|
|
|
224
192
|
"start_time": start_time,
|
|
225
193
|
"task_id": task_id,
|
|
226
194
|
},
|
|
227
|
-
|
|
195
|
+
session_all_params.SessionAllParams,
|
|
228
196
|
),
|
|
229
197
|
),
|
|
230
|
-
cast_to=
|
|
198
|
+
cast_to=SessionAllResponse,
|
|
199
|
+
)
|
|
200
|
+
|
|
201
|
+
def logs(
|
|
202
|
+
self,
|
|
203
|
+
session_id: str,
|
|
204
|
+
*,
|
|
205
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
206
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
207
|
+
extra_headers: Headers | None = None,
|
|
208
|
+
extra_query: Query | None = None,
|
|
209
|
+
extra_body: Body | None = None,
|
|
210
|
+
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
|
|
211
|
+
) -> SessionLogsResponse:
|
|
212
|
+
"""
|
|
213
|
+
Fleet Session Logs Endpoint
|
|
214
|
+
|
|
215
|
+
Args:
|
|
216
|
+
extra_headers: Send extra headers
|
|
217
|
+
|
|
218
|
+
extra_query: Add additional query parameters to the request
|
|
219
|
+
|
|
220
|
+
extra_body: Add additional JSON properties to the request
|
|
221
|
+
|
|
222
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
223
|
+
"""
|
|
224
|
+
if not session_id:
|
|
225
|
+
raise ValueError(f"Expected a non-empty value for `session_id` but received {session_id!r}")
|
|
226
|
+
return self._get(
|
|
227
|
+
f"/sessions/{session_id}/logs",
|
|
228
|
+
options=make_request_options(
|
|
229
|
+
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
230
|
+
),
|
|
231
|
+
cast_to=SessionLogsResponse,
|
|
232
|
+
)
|
|
233
|
+
|
|
234
|
+
def media(
|
|
235
|
+
self,
|
|
236
|
+
session_id: str,
|
|
237
|
+
*,
|
|
238
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
239
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
240
|
+
extra_headers: Headers | None = None,
|
|
241
|
+
extra_query: Query | None = None,
|
|
242
|
+
extra_body: Body | None = None,
|
|
243
|
+
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
|
|
244
|
+
) -> SessionMediaResponse:
|
|
245
|
+
"""
|
|
246
|
+
Get Session Media Endpoint
|
|
247
|
+
|
|
248
|
+
Args:
|
|
249
|
+
session_id: The ID of the session
|
|
250
|
+
|
|
251
|
+
extra_headers: Send extra headers
|
|
252
|
+
|
|
253
|
+
extra_query: Add additional query parameters to the request
|
|
254
|
+
|
|
255
|
+
extra_body: Add additional JSON properties to the request
|
|
256
|
+
|
|
257
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
258
|
+
"""
|
|
259
|
+
if not session_id:
|
|
260
|
+
raise ValueError(f"Expected a non-empty value for `session_id` but received {session_id!r}")
|
|
261
|
+
return self._get(
|
|
262
|
+
f"/sessions/{session_id}/media",
|
|
263
|
+
options=make_request_options(
|
|
264
|
+
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
265
|
+
),
|
|
266
|
+
cast_to=SessionMediaResponse,
|
|
231
267
|
)
|
|
232
268
|
|
|
233
269
|
def status(
|
|
@@ -240,7 +276,7 @@ class FleetResource(SyncAPIResource):
|
|
|
240
276
|
extra_query: Query | None = None,
|
|
241
277
|
extra_body: Body | None = None,
|
|
242
278
|
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
|
|
243
|
-
) ->
|
|
279
|
+
) -> SessionStatusResponse:
|
|
244
280
|
"""
|
|
245
281
|
Fleet Session Status Endpoint
|
|
246
282
|
|
|
@@ -260,7 +296,7 @@ class FleetResource(SyncAPIResource):
|
|
|
260
296
|
options=make_request_options(
|
|
261
297
|
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
262
298
|
),
|
|
263
|
-
cast_to=
|
|
299
|
+
cast_to=SessionStatusResponse,
|
|
264
300
|
)
|
|
265
301
|
|
|
266
302
|
def terminate(
|
|
@@ -273,7 +309,7 @@ class FleetResource(SyncAPIResource):
|
|
|
273
309
|
extra_query: Query | None = None,
|
|
274
310
|
extra_body: Body | None = None,
|
|
275
311
|
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
|
|
276
|
-
) ->
|
|
312
|
+
) -> SessionTerminateResponse:
|
|
277
313
|
"""
|
|
278
314
|
Fleet Session Terminate Endpoint
|
|
279
315
|
|
|
@@ -293,39 +329,39 @@ class FleetResource(SyncAPIResource):
|
|
|
293
329
|
options=make_request_options(
|
|
294
330
|
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
295
331
|
),
|
|
296
|
-
cast_to=
|
|
332
|
+
cast_to=SessionTerminateResponse,
|
|
297
333
|
)
|
|
298
334
|
|
|
299
335
|
|
|
300
|
-
class
|
|
336
|
+
class AsyncSessionsResource(AsyncAPIResource):
|
|
301
337
|
@cached_property
|
|
302
|
-
def with_raw_response(self) ->
|
|
338
|
+
def with_raw_response(self) -> AsyncSessionsResourceWithRawResponse:
|
|
303
339
|
"""
|
|
304
340
|
This property can be used as a prefix for any HTTP method call to return
|
|
305
341
|
the raw response object instead of the parsed content.
|
|
306
342
|
|
|
307
343
|
For more information, see https://www.github.com/raccoonaihq/raccoonai-python#accessing-raw-response-data-eg-headers
|
|
308
344
|
"""
|
|
309
|
-
return
|
|
345
|
+
return AsyncSessionsResourceWithRawResponse(self)
|
|
310
346
|
|
|
311
347
|
@cached_property
|
|
312
|
-
def with_streaming_response(self) ->
|
|
348
|
+
def with_streaming_response(self) -> AsyncSessionsResourceWithStreamingResponse:
|
|
313
349
|
"""
|
|
314
350
|
An alternative to `.with_raw_response` that doesn't eagerly read the response body.
|
|
315
351
|
|
|
316
352
|
For more information, see https://www.github.com/raccoonaihq/raccoonai-python#with_streaming_response
|
|
317
353
|
"""
|
|
318
|
-
return
|
|
354
|
+
return AsyncSessionsResourceWithStreamingResponse(self)
|
|
319
355
|
|
|
320
356
|
async def create(
|
|
321
357
|
self,
|
|
322
358
|
*,
|
|
323
|
-
advanced: Optional[
|
|
359
|
+
advanced: Optional[session_create_params.Advanced] | NotGiven = NOT_GIVEN,
|
|
324
360
|
browser_type: Optional[Literal["chromium", "firefox", "webkit"]] | NotGiven = NOT_GIVEN,
|
|
325
361
|
headless: Optional[bool] | NotGiven = NOT_GIVEN,
|
|
326
362
|
raccoon_passcode: Optional[str] | NotGiven = NOT_GIVEN,
|
|
327
363
|
session_timeout: Optional[int] | NotGiven = NOT_GIVEN,
|
|
328
|
-
settings: Optional[
|
|
364
|
+
settings: Optional[session_create_params.Settings] | NotGiven = NOT_GIVEN,
|
|
329
365
|
url: Optional[str] | NotGiven = NOT_GIVEN,
|
|
330
366
|
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
331
367
|
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
@@ -333,7 +369,7 @@ class AsyncFleetResource(AsyncAPIResource):
|
|
|
333
369
|
extra_query: Query | None = None,
|
|
334
370
|
extra_body: Body | None = None,
|
|
335
371
|
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
|
|
336
|
-
) ->
|
|
372
|
+
) -> SessionCreateResponse:
|
|
337
373
|
"""
|
|
338
374
|
Fleet Websocket Session Create Endpoint
|
|
339
375
|
|
|
@@ -376,48 +412,15 @@ class AsyncFleetResource(AsyncAPIResource):
|
|
|
376
412
|
"settings": settings,
|
|
377
413
|
"url": url,
|
|
378
414
|
},
|
|
379
|
-
|
|
380
|
-
),
|
|
381
|
-
options=make_request_options(
|
|
382
|
-
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
415
|
+
session_create_params.SessionCreateParams,
|
|
383
416
|
),
|
|
384
|
-
cast_to=FleetCreateResponse,
|
|
385
|
-
)
|
|
386
|
-
|
|
387
|
-
async def logs(
|
|
388
|
-
self,
|
|
389
|
-
session_id: str,
|
|
390
|
-
*,
|
|
391
|
-
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
392
|
-
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
393
|
-
extra_headers: Headers | None = None,
|
|
394
|
-
extra_query: Query | None = None,
|
|
395
|
-
extra_body: Body | None = None,
|
|
396
|
-
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
|
|
397
|
-
) -> FleetLogsResponse:
|
|
398
|
-
"""
|
|
399
|
-
Fleet Session Logs Endpoint
|
|
400
|
-
|
|
401
|
-
Args:
|
|
402
|
-
extra_headers: Send extra headers
|
|
403
|
-
|
|
404
|
-
extra_query: Add additional query parameters to the request
|
|
405
|
-
|
|
406
|
-
extra_body: Add additional JSON properties to the request
|
|
407
|
-
|
|
408
|
-
timeout: Override the client-level default timeout for this request, in seconds
|
|
409
|
-
"""
|
|
410
|
-
if not session_id:
|
|
411
|
-
raise ValueError(f"Expected a non-empty value for `session_id` but received {session_id!r}")
|
|
412
|
-
return await self._get(
|
|
413
|
-
f"/sessions/{session_id}/logs",
|
|
414
417
|
options=make_request_options(
|
|
415
418
|
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
416
419
|
),
|
|
417
|
-
cast_to=
|
|
420
|
+
cast_to=SessionCreateResponse,
|
|
418
421
|
)
|
|
419
422
|
|
|
420
|
-
async def
|
|
423
|
+
async def all(
|
|
421
424
|
self,
|
|
422
425
|
*,
|
|
423
426
|
end_time: Optional[int] | NotGiven = NOT_GIVEN,
|
|
@@ -437,7 +440,7 @@ class AsyncFleetResource(AsyncAPIResource):
|
|
|
437
440
|
extra_query: Query | None = None,
|
|
438
441
|
extra_body: Body | None = None,
|
|
439
442
|
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
|
|
440
|
-
) ->
|
|
443
|
+
) -> SessionAllResponse:
|
|
441
444
|
"""
|
|
442
445
|
Get Sessions Endpoint
|
|
443
446
|
|
|
@@ -490,10 +493,78 @@ class AsyncFleetResource(AsyncAPIResource):
|
|
|
490
493
|
"start_time": start_time,
|
|
491
494
|
"task_id": task_id,
|
|
492
495
|
},
|
|
493
|
-
|
|
496
|
+
session_all_params.SessionAllParams,
|
|
494
497
|
),
|
|
495
498
|
),
|
|
496
|
-
cast_to=
|
|
499
|
+
cast_to=SessionAllResponse,
|
|
500
|
+
)
|
|
501
|
+
|
|
502
|
+
async def logs(
|
|
503
|
+
self,
|
|
504
|
+
session_id: str,
|
|
505
|
+
*,
|
|
506
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
507
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
508
|
+
extra_headers: Headers | None = None,
|
|
509
|
+
extra_query: Query | None = None,
|
|
510
|
+
extra_body: Body | None = None,
|
|
511
|
+
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
|
|
512
|
+
) -> SessionLogsResponse:
|
|
513
|
+
"""
|
|
514
|
+
Fleet Session Logs Endpoint
|
|
515
|
+
|
|
516
|
+
Args:
|
|
517
|
+
extra_headers: Send extra headers
|
|
518
|
+
|
|
519
|
+
extra_query: Add additional query parameters to the request
|
|
520
|
+
|
|
521
|
+
extra_body: Add additional JSON properties to the request
|
|
522
|
+
|
|
523
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
524
|
+
"""
|
|
525
|
+
if not session_id:
|
|
526
|
+
raise ValueError(f"Expected a non-empty value for `session_id` but received {session_id!r}")
|
|
527
|
+
return await self._get(
|
|
528
|
+
f"/sessions/{session_id}/logs",
|
|
529
|
+
options=make_request_options(
|
|
530
|
+
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
531
|
+
),
|
|
532
|
+
cast_to=SessionLogsResponse,
|
|
533
|
+
)
|
|
534
|
+
|
|
535
|
+
async def media(
|
|
536
|
+
self,
|
|
537
|
+
session_id: str,
|
|
538
|
+
*,
|
|
539
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
540
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
541
|
+
extra_headers: Headers | None = None,
|
|
542
|
+
extra_query: Query | None = None,
|
|
543
|
+
extra_body: Body | None = None,
|
|
544
|
+
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
|
|
545
|
+
) -> SessionMediaResponse:
|
|
546
|
+
"""
|
|
547
|
+
Get Session Media Endpoint
|
|
548
|
+
|
|
549
|
+
Args:
|
|
550
|
+
session_id: The ID of the session
|
|
551
|
+
|
|
552
|
+
extra_headers: Send extra headers
|
|
553
|
+
|
|
554
|
+
extra_query: Add additional query parameters to the request
|
|
555
|
+
|
|
556
|
+
extra_body: Add additional JSON properties to the request
|
|
557
|
+
|
|
558
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
559
|
+
"""
|
|
560
|
+
if not session_id:
|
|
561
|
+
raise ValueError(f"Expected a non-empty value for `session_id` but received {session_id!r}")
|
|
562
|
+
return await self._get(
|
|
563
|
+
f"/sessions/{session_id}/media",
|
|
564
|
+
options=make_request_options(
|
|
565
|
+
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
566
|
+
),
|
|
567
|
+
cast_to=SessionMediaResponse,
|
|
497
568
|
)
|
|
498
569
|
|
|
499
570
|
async def status(
|
|
@@ -506,7 +577,7 @@ class AsyncFleetResource(AsyncAPIResource):
|
|
|
506
577
|
extra_query: Query | None = None,
|
|
507
578
|
extra_body: Body | None = None,
|
|
508
579
|
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
|
|
509
|
-
) ->
|
|
580
|
+
) -> SessionStatusResponse:
|
|
510
581
|
"""
|
|
511
582
|
Fleet Session Status Endpoint
|
|
512
583
|
|
|
@@ -526,7 +597,7 @@ class AsyncFleetResource(AsyncAPIResource):
|
|
|
526
597
|
options=make_request_options(
|
|
527
598
|
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
528
599
|
),
|
|
529
|
-
cast_to=
|
|
600
|
+
cast_to=SessionStatusResponse,
|
|
530
601
|
)
|
|
531
602
|
|
|
532
603
|
async def terminate(
|
|
@@ -539,7 +610,7 @@ class AsyncFleetResource(AsyncAPIResource):
|
|
|
539
610
|
extra_query: Query | None = None,
|
|
540
611
|
extra_body: Body | None = None,
|
|
541
612
|
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
|
|
542
|
-
) ->
|
|
613
|
+
) -> SessionTerminateResponse:
|
|
543
614
|
"""
|
|
544
615
|
Fleet Session Terminate Endpoint
|
|
545
616
|
|
|
@@ -559,89 +630,101 @@ class AsyncFleetResource(AsyncAPIResource):
|
|
|
559
630
|
options=make_request_options(
|
|
560
631
|
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
561
632
|
),
|
|
562
|
-
cast_to=
|
|
633
|
+
cast_to=SessionTerminateResponse,
|
|
563
634
|
)
|
|
564
635
|
|
|
565
636
|
|
|
566
|
-
class
|
|
567
|
-
def __init__(self,
|
|
568
|
-
self.
|
|
637
|
+
class SessionsResourceWithRawResponse:
|
|
638
|
+
def __init__(self, sessions: SessionsResource) -> None:
|
|
639
|
+
self._sessions = sessions
|
|
569
640
|
|
|
570
641
|
self.create = to_raw_response_wrapper(
|
|
571
|
-
|
|
642
|
+
sessions.create,
|
|
643
|
+
)
|
|
644
|
+
self.all = to_raw_response_wrapper(
|
|
645
|
+
sessions.all,
|
|
572
646
|
)
|
|
573
647
|
self.logs = to_raw_response_wrapper(
|
|
574
|
-
|
|
648
|
+
sessions.logs,
|
|
575
649
|
)
|
|
576
|
-
self.
|
|
577
|
-
|
|
650
|
+
self.media = to_raw_response_wrapper(
|
|
651
|
+
sessions.media,
|
|
578
652
|
)
|
|
579
653
|
self.status = to_raw_response_wrapper(
|
|
580
|
-
|
|
654
|
+
sessions.status,
|
|
581
655
|
)
|
|
582
656
|
self.terminate = to_raw_response_wrapper(
|
|
583
|
-
|
|
657
|
+
sessions.terminate,
|
|
584
658
|
)
|
|
585
659
|
|
|
586
660
|
|
|
587
|
-
class
|
|
588
|
-
def __init__(self,
|
|
589
|
-
self.
|
|
661
|
+
class AsyncSessionsResourceWithRawResponse:
|
|
662
|
+
def __init__(self, sessions: AsyncSessionsResource) -> None:
|
|
663
|
+
self._sessions = sessions
|
|
590
664
|
|
|
591
665
|
self.create = async_to_raw_response_wrapper(
|
|
592
|
-
|
|
666
|
+
sessions.create,
|
|
667
|
+
)
|
|
668
|
+
self.all = async_to_raw_response_wrapper(
|
|
669
|
+
sessions.all,
|
|
593
670
|
)
|
|
594
671
|
self.logs = async_to_raw_response_wrapper(
|
|
595
|
-
|
|
672
|
+
sessions.logs,
|
|
596
673
|
)
|
|
597
|
-
self.
|
|
598
|
-
|
|
674
|
+
self.media = async_to_raw_response_wrapper(
|
|
675
|
+
sessions.media,
|
|
599
676
|
)
|
|
600
677
|
self.status = async_to_raw_response_wrapper(
|
|
601
|
-
|
|
678
|
+
sessions.status,
|
|
602
679
|
)
|
|
603
680
|
self.terminate = async_to_raw_response_wrapper(
|
|
604
|
-
|
|
681
|
+
sessions.terminate,
|
|
605
682
|
)
|
|
606
683
|
|
|
607
684
|
|
|
608
|
-
class
|
|
609
|
-
def __init__(self,
|
|
610
|
-
self.
|
|
685
|
+
class SessionsResourceWithStreamingResponse:
|
|
686
|
+
def __init__(self, sessions: SessionsResource) -> None:
|
|
687
|
+
self._sessions = sessions
|
|
611
688
|
|
|
612
689
|
self.create = to_streamed_response_wrapper(
|
|
613
|
-
|
|
690
|
+
sessions.create,
|
|
691
|
+
)
|
|
692
|
+
self.all = to_streamed_response_wrapper(
|
|
693
|
+
sessions.all,
|
|
614
694
|
)
|
|
615
695
|
self.logs = to_streamed_response_wrapper(
|
|
616
|
-
|
|
696
|
+
sessions.logs,
|
|
617
697
|
)
|
|
618
|
-
self.
|
|
619
|
-
|
|
698
|
+
self.media = to_streamed_response_wrapper(
|
|
699
|
+
sessions.media,
|
|
620
700
|
)
|
|
621
701
|
self.status = to_streamed_response_wrapper(
|
|
622
|
-
|
|
702
|
+
sessions.status,
|
|
623
703
|
)
|
|
624
704
|
self.terminate = to_streamed_response_wrapper(
|
|
625
|
-
|
|
705
|
+
sessions.terminate,
|
|
626
706
|
)
|
|
627
707
|
|
|
628
708
|
|
|
629
|
-
class
|
|
630
|
-
def __init__(self,
|
|
631
|
-
self.
|
|
709
|
+
class AsyncSessionsResourceWithStreamingResponse:
|
|
710
|
+
def __init__(self, sessions: AsyncSessionsResource) -> None:
|
|
711
|
+
self._sessions = sessions
|
|
632
712
|
|
|
633
713
|
self.create = async_to_streamed_response_wrapper(
|
|
634
|
-
|
|
714
|
+
sessions.create,
|
|
715
|
+
)
|
|
716
|
+
self.all = async_to_streamed_response_wrapper(
|
|
717
|
+
sessions.all,
|
|
635
718
|
)
|
|
636
719
|
self.logs = async_to_streamed_response_wrapper(
|
|
637
|
-
|
|
720
|
+
sessions.logs,
|
|
638
721
|
)
|
|
639
|
-
self.
|
|
640
|
-
|
|
722
|
+
self.media = async_to_streamed_response_wrapper(
|
|
723
|
+
sessions.media,
|
|
641
724
|
)
|
|
642
725
|
self.status = async_to_streamed_response_wrapper(
|
|
643
|
-
|
|
726
|
+
sessions.status,
|
|
644
727
|
)
|
|
645
728
|
self.terminate = async_to_streamed_response_wrapper(
|
|
646
|
-
|
|
729
|
+
sessions.terminate,
|
|
647
730
|
)
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from .lam import (
|
|
4
|
+
LamResource,
|
|
5
|
+
AsyncLamResource,
|
|
6
|
+
LamResourceWithRawResponse,
|
|
7
|
+
AsyncLamResourceWithRawResponse,
|
|
8
|
+
LamResourceWithStreamingResponse,
|
|
9
|
+
AsyncLamResourceWithStreamingResponse,
|
|
10
|
+
)
|
|
11
|
+
from .tasks import (
|
|
12
|
+
TasksResource,
|
|
13
|
+
AsyncTasksResource,
|
|
14
|
+
TasksResourceWithRawResponse,
|
|
15
|
+
AsyncTasksResourceWithRawResponse,
|
|
16
|
+
TasksResourceWithStreamingResponse,
|
|
17
|
+
AsyncTasksResourceWithStreamingResponse,
|
|
18
|
+
)
|
|
19
|
+
|
|
20
|
+
__all__ = [
|
|
21
|
+
"TasksResource",
|
|
22
|
+
"AsyncTasksResource",
|
|
23
|
+
"TasksResourceWithRawResponse",
|
|
24
|
+
"AsyncTasksResourceWithRawResponse",
|
|
25
|
+
"TasksResourceWithStreamingResponse",
|
|
26
|
+
"AsyncTasksResourceWithStreamingResponse",
|
|
27
|
+
"LamResource",
|
|
28
|
+
"AsyncLamResource",
|
|
29
|
+
"LamResourceWithRawResponse",
|
|
30
|
+
"AsyncLamResourceWithRawResponse",
|
|
31
|
+
"LamResourceWithStreamingResponse",
|
|
32
|
+
"AsyncLamResourceWithStreamingResponse",
|
|
33
|
+
]
|