anchorbrowser 0.1.0a3__py3-none-any.whl → 0.2.0__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.
- anchorbrowser/__init__.py +3 -1
- anchorbrowser/_base_client.py +16 -13
- anchorbrowser/_client.py +38 -9
- anchorbrowser/_compat.py +48 -48
- anchorbrowser/_files.py +4 -4
- anchorbrowser/_models.py +54 -45
- anchorbrowser/_qs.py +7 -7
- anchorbrowser/_types.py +53 -12
- anchorbrowser/_utils/__init__.py +9 -2
- anchorbrowser/_utils/_compat.py +45 -0
- anchorbrowser/_utils/_datetime_parse.py +136 -0
- anchorbrowser/_utils/_transform.py +13 -3
- anchorbrowser/_utils/_typing.py +6 -1
- anchorbrowser/_utils/_utils.py +4 -5
- anchorbrowser/_version.py +1 -1
- anchorbrowser/lib/browser.py +1 -1
- anchorbrowser/resources/__init__.py +42 -0
- anchorbrowser/resources/batch_sessions.py +288 -0
- anchorbrowser/resources/events.py +270 -0
- anchorbrowser/resources/extensions.py +9 -9
- anchorbrowser/resources/profiles.py +24 -150
- anchorbrowser/resources/sessions/__init__.py +14 -0
- anchorbrowser/resources/sessions/agent/__init__.py +33 -0
- anchorbrowser/resources/sessions/agent/agent.py +273 -0
- anchorbrowser/resources/sessions/agent/files.py +280 -0
- anchorbrowser/resources/sessions/all.py +5 -5
- anchorbrowser/resources/sessions/clipboard.py +5 -5
- anchorbrowser/resources/sessions/keyboard.py +11 -13
- anchorbrowser/resources/sessions/mouse.py +12 -244
- anchorbrowser/resources/sessions/recordings/primary.py +3 -3
- anchorbrowser/resources/sessions/recordings/recordings.py +7 -7
- anchorbrowser/resources/sessions/sessions.py +345 -30
- anchorbrowser/resources/task/__init__.py +33 -0
- anchorbrowser/resources/task/run.py +225 -0
- anchorbrowser/resources/task/task.py +358 -0
- anchorbrowser/resources/tools.py +107 -37
- anchorbrowser/types/__init__.py +14 -1
- anchorbrowser/types/batch_session_create_params.py +487 -0
- anchorbrowser/types/batch_session_create_response.py +27 -0
- anchorbrowser/types/batch_session_retrieve_response.py +90 -0
- anchorbrowser/types/event_signal_params.py +13 -0
- anchorbrowser/types/event_wait_for_params.py +14 -0
- anchorbrowser/types/event_wait_for_response.py +12 -0
- anchorbrowser/types/extension_manifest.py +6 -1
- anchorbrowser/types/profile_create_params.py +3 -6
- anchorbrowser/types/profile_list_response.py +0 -3
- anchorbrowser/types/profile_retrieve_response.py +0 -3
- anchorbrowser/types/session_create_params.py +308 -29
- anchorbrowser/types/session_list_pages_response.py +25 -0
- anchorbrowser/types/session_retrieve_response.py +46 -0
- anchorbrowser/types/session_scroll_params.py +3 -0
- anchorbrowser/types/session_upload_file_params.py +14 -0
- anchorbrowser/types/session_upload_file_response.py +17 -0
- anchorbrowser/types/sessions/__init__.py +0 -4
- anchorbrowser/types/sessions/agent/__init__.py +7 -0
- anchorbrowser/types/sessions/agent/file_list_response.py +32 -0
- anchorbrowser/types/sessions/agent/file_upload_params.py +14 -0
- anchorbrowser/types/sessions/agent/file_upload_response.py +17 -0
- anchorbrowser/types/sessions/keyboard_shortcut_params.py +2 -2
- anchorbrowser/types/sessions/recording_list_response.py +4 -8
- anchorbrowser/types/task/__init__.py +6 -0
- anchorbrowser/types/task/run_execute_params.py +324 -0
- anchorbrowser/types/task/run_execute_response.py +33 -0
- anchorbrowser/types/task_create_params.py +317 -0
- anchorbrowser/types/task_create_response.py +345 -0
- anchorbrowser/types/task_list_params.py +15 -0
- anchorbrowser/types/task_list_response.py +361 -0
- anchorbrowser/types/tool_fetch_webpage_params.py +15 -0
- anchorbrowser/types/tool_perform_web_task_params.py +17 -1
- anchorbrowser/types/tool_perform_web_task_response.py +3 -3
- {anchorbrowser-0.1.0a3.dist-info → anchorbrowser-0.2.0.dist-info}/METADATA +13 -14
- anchorbrowser-0.2.0.dist-info/RECORD +126 -0
- anchorbrowser/types/profile_update_params.py +0 -27
- anchorbrowser/types/sessions/mouse_down_params.py +0 -18
- anchorbrowser/types/sessions/mouse_down_response.py +0 -11
- anchorbrowser/types/sessions/mouse_up_params.py +0 -18
- anchorbrowser/types/sessions/mouse_up_response.py +0 -11
- anchorbrowser-0.1.0a3.dist-info/RECORD +0 -100
- {anchorbrowser-0.1.0a3.dist-info → anchorbrowser-0.2.0.dist-info}/WHEEL +0 -0
- {anchorbrowser-0.1.0a3.dist-info → anchorbrowser-0.2.0.dist-info}/licenses/LICENSE +0 -0
|
@@ -28,9 +28,6 @@ class Data(BaseModel):
|
|
|
28
28
|
status: Optional[str] = None
|
|
29
29
|
"""The current status of the profile."""
|
|
30
30
|
|
|
31
|
-
store_cache: Optional[bool] = None
|
|
32
|
-
"""Whether the profile stores browser cache."""
|
|
33
|
-
|
|
34
31
|
|
|
35
32
|
class ProfileRetrieveResponse(BaseModel):
|
|
36
33
|
data: Optional[Data] = None
|
|
@@ -2,25 +2,33 @@
|
|
|
2
2
|
|
|
3
3
|
from __future__ import annotations
|
|
4
4
|
|
|
5
|
-
from typing import Union
|
|
5
|
+
from typing import Union, Iterable
|
|
6
6
|
from typing_extensions import Literal, Required, TypeAlias, TypedDict
|
|
7
7
|
|
|
8
|
+
from .._types import SequenceNotStr
|
|
9
|
+
|
|
8
10
|
__all__ = [
|
|
9
11
|
"SessionCreateParams",
|
|
10
12
|
"Browser",
|
|
11
13
|
"BrowserAdblock",
|
|
12
14
|
"BrowserCaptchaSolver",
|
|
15
|
+
"BrowserDisableWebSecurity",
|
|
16
|
+
"BrowserExtraStealth",
|
|
17
|
+
"BrowserFullscreen",
|
|
13
18
|
"BrowserHeadless",
|
|
14
19
|
"BrowserP2pDownload",
|
|
15
20
|
"BrowserPopupBlocker",
|
|
16
21
|
"BrowserProfile",
|
|
17
22
|
"BrowserViewport",
|
|
23
|
+
"Integration",
|
|
24
|
+
"IntegrationConfiguration",
|
|
25
|
+
"IntegrationConfigurationOnePasswordAllSecretsConfig",
|
|
26
|
+
"IntegrationConfigurationOnePasswordSpecificSecretsConfig",
|
|
18
27
|
"Session",
|
|
19
28
|
"SessionLiveView",
|
|
20
29
|
"SessionProxy",
|
|
21
|
-
"
|
|
22
|
-
"
|
|
23
|
-
"SessionProxyCustomProxyType",
|
|
30
|
+
"SessionProxyAnchorProxy",
|
|
31
|
+
"SessionProxyCustomProxy",
|
|
24
32
|
"SessionRecording",
|
|
25
33
|
"SessionTimeout",
|
|
26
34
|
]
|
|
@@ -30,6 +38,12 @@ class SessionCreateParams(TypedDict, total=False):
|
|
|
30
38
|
browser: Browser
|
|
31
39
|
"""Browser-specific configurations."""
|
|
32
40
|
|
|
41
|
+
integrations: Iterable[Integration]
|
|
42
|
+
"""Array of integrations to load in the browser session.
|
|
43
|
+
|
|
44
|
+
Integrations must be previously created using the Integrations API.
|
|
45
|
+
"""
|
|
46
|
+
|
|
33
47
|
session: Session
|
|
34
48
|
"""Session-related configurations."""
|
|
35
49
|
|
|
@@ -47,6 +61,28 @@ class BrowserCaptchaSolver(TypedDict, total=False):
|
|
|
47
61
|
"""
|
|
48
62
|
|
|
49
63
|
|
|
64
|
+
class BrowserDisableWebSecurity(TypedDict, total=False):
|
|
65
|
+
active: bool
|
|
66
|
+
"""Whether to disable web security features (CORS, same-origin policy, etc.).
|
|
67
|
+
|
|
68
|
+
Allows accessing iframes and resources from different origins. Defaults to
|
|
69
|
+
`false`.
|
|
70
|
+
"""
|
|
71
|
+
|
|
72
|
+
|
|
73
|
+
class BrowserExtraStealth(TypedDict, total=False):
|
|
74
|
+
active: bool
|
|
75
|
+
"""Enable or disable extra stealth mode."""
|
|
76
|
+
|
|
77
|
+
|
|
78
|
+
class BrowserFullscreen(TypedDict, total=False):
|
|
79
|
+
active: bool
|
|
80
|
+
"""Enable or disable fullscreen mode.
|
|
81
|
+
|
|
82
|
+
When enabled, the browser will start in fullscreen mode. Defaults to `false`.
|
|
83
|
+
"""
|
|
84
|
+
|
|
85
|
+
|
|
50
86
|
class BrowserHeadless(TypedDict, total=False):
|
|
51
87
|
active: bool
|
|
52
88
|
"""Whether browser should be headless or headful. Defaults to `false`."""
|
|
@@ -79,12 +115,6 @@ class BrowserProfile(TypedDict, total=False):
|
|
|
79
115
|
browser session ends. Defaults to `false`.
|
|
80
116
|
"""
|
|
81
117
|
|
|
82
|
-
store_cache: bool
|
|
83
|
-
"""
|
|
84
|
-
Indicates whether the browser session cache should be saved when the browser
|
|
85
|
-
session ends. Defaults to `false`.
|
|
86
|
-
"""
|
|
87
|
-
|
|
88
118
|
|
|
89
119
|
class BrowserViewport(TypedDict, total=False):
|
|
90
120
|
height: int
|
|
@@ -101,6 +131,24 @@ class Browser(TypedDict, total=False):
|
|
|
101
131
|
captcha_solver: BrowserCaptchaSolver
|
|
102
132
|
"""Configuration for captcha-solving."""
|
|
103
133
|
|
|
134
|
+
disable_web_security: BrowserDisableWebSecurity
|
|
135
|
+
"""Configuration for disabling web security features."""
|
|
136
|
+
|
|
137
|
+
extensions: SequenceNotStr[str]
|
|
138
|
+
"""Array of extension IDs to load in the browser session.
|
|
139
|
+
|
|
140
|
+
Extensions must be previously uploaded using the Extensions API.
|
|
141
|
+
"""
|
|
142
|
+
|
|
143
|
+
extra_stealth: BrowserExtraStealth
|
|
144
|
+
"""
|
|
145
|
+
Configuration for extra stealth mode to enhance browser fingerprinting
|
|
146
|
+
protection.
|
|
147
|
+
"""
|
|
148
|
+
|
|
149
|
+
fullscreen: BrowserFullscreen
|
|
150
|
+
"""Configuration for fullscreen mode."""
|
|
151
|
+
|
|
104
152
|
headless: BrowserHeadless
|
|
105
153
|
"""Configuration for headless mode."""
|
|
106
154
|
|
|
@@ -117,32 +165,262 @@ class Browser(TypedDict, total=False):
|
|
|
117
165
|
"""Configuration for the browser's viewport size."""
|
|
118
166
|
|
|
119
167
|
|
|
168
|
+
class IntegrationConfigurationOnePasswordAllSecretsConfig(TypedDict, total=False):
|
|
169
|
+
load_mode: Required[Literal["all"]]
|
|
170
|
+
"""Load all secrets from 1Password"""
|
|
171
|
+
|
|
172
|
+
|
|
173
|
+
class IntegrationConfigurationOnePasswordSpecificSecretsConfig(TypedDict, total=False):
|
|
174
|
+
load_mode: Required[Literal["specific"]]
|
|
175
|
+
"""Load specific secrets from 1Password"""
|
|
176
|
+
|
|
177
|
+
secrets: Required[SequenceNotStr[str]]
|
|
178
|
+
"""Array of secret references to load"""
|
|
179
|
+
|
|
180
|
+
|
|
181
|
+
IntegrationConfiguration: TypeAlias = Union[
|
|
182
|
+
IntegrationConfigurationOnePasswordAllSecretsConfig, IntegrationConfigurationOnePasswordSpecificSecretsConfig
|
|
183
|
+
]
|
|
184
|
+
|
|
185
|
+
|
|
186
|
+
class Integration(TypedDict, total=False):
|
|
187
|
+
id: Required[str]
|
|
188
|
+
"""Unique integration ID"""
|
|
189
|
+
|
|
190
|
+
configuration: Required[IntegrationConfiguration]
|
|
191
|
+
|
|
192
|
+
type: Required[Literal["1PASSWORD"]]
|
|
193
|
+
"""Integration type"""
|
|
194
|
+
|
|
195
|
+
|
|
120
196
|
class SessionLiveView(TypedDict, total=False):
|
|
121
197
|
read_only: bool
|
|
122
198
|
"""Enable or disable read-only mode for live viewing. Defaults to `false`."""
|
|
123
199
|
|
|
124
200
|
|
|
125
|
-
class
|
|
126
|
-
|
|
201
|
+
class SessionProxyAnchorProxy(TypedDict, total=False):
|
|
202
|
+
active: Required[bool]
|
|
127
203
|
|
|
128
|
-
active: bool
|
|
129
204
|
"""Enable or disable proxy usage. Defaults to `false`."""
|
|
205
|
+
city: str
|
|
206
|
+
"""City name for precise geographic targeting.
|
|
130
207
|
|
|
131
|
-
|
|
132
|
-
"""
|
|
208
|
+
Supported for anchor_proxy only. Can only be used when region is also provided.
|
|
209
|
+
"""
|
|
133
210
|
|
|
211
|
+
country_code: Literal[
|
|
212
|
+
"af",
|
|
213
|
+
"al",
|
|
214
|
+
"dz",
|
|
215
|
+
"ad",
|
|
216
|
+
"ao",
|
|
217
|
+
"as",
|
|
218
|
+
"ag",
|
|
219
|
+
"ar",
|
|
220
|
+
"am",
|
|
221
|
+
"aw",
|
|
222
|
+
"au",
|
|
223
|
+
"at",
|
|
224
|
+
"az",
|
|
225
|
+
"bs",
|
|
226
|
+
"bh",
|
|
227
|
+
"bb",
|
|
228
|
+
"by",
|
|
229
|
+
"be",
|
|
230
|
+
"bz",
|
|
231
|
+
"bj",
|
|
232
|
+
"bm",
|
|
233
|
+
"bo",
|
|
234
|
+
"ba",
|
|
235
|
+
"br",
|
|
236
|
+
"bg",
|
|
237
|
+
"bf",
|
|
238
|
+
"cm",
|
|
239
|
+
"ca",
|
|
240
|
+
"cv",
|
|
241
|
+
"td",
|
|
242
|
+
"cl",
|
|
243
|
+
"co",
|
|
244
|
+
"cg",
|
|
245
|
+
"cr",
|
|
246
|
+
"ci",
|
|
247
|
+
"hr",
|
|
248
|
+
"cu",
|
|
249
|
+
"cy",
|
|
250
|
+
"cz",
|
|
251
|
+
"dk",
|
|
252
|
+
"dm",
|
|
253
|
+
"do",
|
|
254
|
+
"ec",
|
|
255
|
+
"eg",
|
|
256
|
+
"sv",
|
|
257
|
+
"ee",
|
|
258
|
+
"et",
|
|
259
|
+
"fo",
|
|
260
|
+
"fi",
|
|
261
|
+
"fr",
|
|
262
|
+
"gf",
|
|
263
|
+
"pf",
|
|
264
|
+
"ga",
|
|
265
|
+
"gm",
|
|
266
|
+
"ge",
|
|
267
|
+
"de",
|
|
268
|
+
"gh",
|
|
269
|
+
"gi",
|
|
270
|
+
"gr",
|
|
271
|
+
"gd",
|
|
272
|
+
"gp",
|
|
273
|
+
"gt",
|
|
274
|
+
"gg",
|
|
275
|
+
"gn",
|
|
276
|
+
"gw",
|
|
277
|
+
"gy",
|
|
278
|
+
"ht",
|
|
279
|
+
"hn",
|
|
280
|
+
"hu",
|
|
281
|
+
"is",
|
|
282
|
+
"in",
|
|
283
|
+
"ir",
|
|
284
|
+
"iq",
|
|
285
|
+
"ie",
|
|
286
|
+
"il",
|
|
287
|
+
"it",
|
|
288
|
+
"jm",
|
|
289
|
+
"jp",
|
|
290
|
+
"jo",
|
|
291
|
+
"kz",
|
|
292
|
+
"kw",
|
|
293
|
+
"kg",
|
|
294
|
+
"lv",
|
|
295
|
+
"lb",
|
|
296
|
+
"ly",
|
|
297
|
+
"li",
|
|
298
|
+
"lt",
|
|
299
|
+
"lu",
|
|
300
|
+
"mk",
|
|
301
|
+
"ml",
|
|
302
|
+
"mt",
|
|
303
|
+
"mq",
|
|
304
|
+
"mr",
|
|
305
|
+
"mx",
|
|
306
|
+
"md",
|
|
307
|
+
"mc",
|
|
308
|
+
"me",
|
|
309
|
+
"ma",
|
|
310
|
+
"nl",
|
|
311
|
+
"nz",
|
|
312
|
+
"ni",
|
|
313
|
+
"ng",
|
|
314
|
+
"no",
|
|
315
|
+
"pk",
|
|
316
|
+
"pa",
|
|
317
|
+
"py",
|
|
318
|
+
"pe",
|
|
319
|
+
"ph",
|
|
320
|
+
"pl",
|
|
321
|
+
"pt",
|
|
322
|
+
"pr",
|
|
323
|
+
"qa",
|
|
324
|
+
"ro",
|
|
325
|
+
"lc",
|
|
326
|
+
"sm",
|
|
327
|
+
"sa",
|
|
328
|
+
"sn",
|
|
329
|
+
"rs",
|
|
330
|
+
"sc",
|
|
331
|
+
"sl",
|
|
332
|
+
"sk",
|
|
333
|
+
"si",
|
|
334
|
+
"so",
|
|
335
|
+
"za",
|
|
336
|
+
"kr",
|
|
337
|
+
"es",
|
|
338
|
+
"sr",
|
|
339
|
+
"se",
|
|
340
|
+
"ch",
|
|
341
|
+
"sy",
|
|
342
|
+
"st",
|
|
343
|
+
"tw",
|
|
344
|
+
"tj",
|
|
345
|
+
"tg",
|
|
346
|
+
"tt",
|
|
347
|
+
"tn",
|
|
348
|
+
"tr",
|
|
349
|
+
"tc",
|
|
350
|
+
"ua",
|
|
351
|
+
"ae",
|
|
352
|
+
"us",
|
|
353
|
+
"uy",
|
|
354
|
+
"uz",
|
|
355
|
+
"ve",
|
|
356
|
+
"ye",
|
|
357
|
+
"bd",
|
|
358
|
+
"bw",
|
|
359
|
+
"bn",
|
|
360
|
+
"bi",
|
|
361
|
+
"kh",
|
|
362
|
+
"cn",
|
|
363
|
+
"dj",
|
|
364
|
+
"gq",
|
|
365
|
+
"sz",
|
|
366
|
+
"fj",
|
|
367
|
+
"hk",
|
|
368
|
+
"id",
|
|
369
|
+
"ke",
|
|
370
|
+
"la",
|
|
371
|
+
"ls",
|
|
372
|
+
"lr",
|
|
373
|
+
"mg",
|
|
374
|
+
"mw",
|
|
375
|
+
"my",
|
|
376
|
+
"mv",
|
|
377
|
+
"mn",
|
|
378
|
+
"mz",
|
|
379
|
+
"mm",
|
|
380
|
+
"na",
|
|
381
|
+
"np",
|
|
382
|
+
"nc",
|
|
383
|
+
"ne",
|
|
384
|
+
"om",
|
|
385
|
+
"pg",
|
|
386
|
+
"ru",
|
|
387
|
+
"rw",
|
|
388
|
+
"ws",
|
|
389
|
+
"sg",
|
|
390
|
+
"ss",
|
|
391
|
+
"lk",
|
|
392
|
+
"sd",
|
|
393
|
+
"tz",
|
|
394
|
+
"th",
|
|
395
|
+
"tl",
|
|
396
|
+
"tm",
|
|
397
|
+
"ug",
|
|
398
|
+
"gb",
|
|
399
|
+
"vu",
|
|
400
|
+
"vn",
|
|
401
|
+
"zm",
|
|
402
|
+
"zw",
|
|
403
|
+
"bt",
|
|
404
|
+
"mu",
|
|
405
|
+
]
|
|
406
|
+
"""Supported country codes ISO 2 lowercase
|
|
407
|
+
|
|
408
|
+
**On change make sure to update the Proxy type.**
|
|
409
|
+
"""
|
|
134
410
|
|
|
135
|
-
|
|
136
|
-
|
|
411
|
+
region: str
|
|
412
|
+
"""
|
|
413
|
+
Region code for more specific geographic targeting. The city parameter can only
|
|
414
|
+
be used when region is also provided.
|
|
415
|
+
"""
|
|
137
416
|
|
|
138
|
-
|
|
139
|
-
"""
|
|
417
|
+
type: Literal["anchor_proxy", "anchor_residential", "anchor_mobile", "anchor_gov"]
|
|
418
|
+
"""**On change make sure to update the country_code.**"""
|
|
140
419
|
|
|
141
|
-
country_code: Literal["us", "uk", "fr", "it", "jp", "au", "de", "fi", "ca"]
|
|
142
|
-
"""Country code for mobile proxy"""
|
|
143
420
|
|
|
421
|
+
class SessionProxyCustomProxy(TypedDict, total=False):
|
|
422
|
+
active: Required[bool]
|
|
144
423
|
|
|
145
|
-
class SessionProxyCustomProxyType(TypedDict, total=False):
|
|
146
424
|
password: Required[str]
|
|
147
425
|
"""Proxy password"""
|
|
148
426
|
|
|
@@ -154,13 +432,8 @@ class SessionProxyCustomProxyType(TypedDict, total=False):
|
|
|
154
432
|
username: Required[str]
|
|
155
433
|
"""Proxy username"""
|
|
156
434
|
|
|
157
|
-
active: bool
|
|
158
|
-
"""Enable or disable proxy usage. Defaults to `false`."""
|
|
159
|
-
|
|
160
435
|
|
|
161
|
-
SessionProxy: TypeAlias = Union[
|
|
162
|
-
SessionProxyAnchorResidentialProxyType, SessionProxyAnchorMobileProxyType, SessionProxyCustomProxyType
|
|
163
|
-
]
|
|
436
|
+
SessionProxy: TypeAlias = Union[SessionProxyAnchorProxy, SessionProxyCustomProxy]
|
|
164
437
|
|
|
165
438
|
|
|
166
439
|
class SessionRecording(TypedDict, total=False):
|
|
@@ -183,11 +456,17 @@ class SessionTimeout(TypedDict, total=False):
|
|
|
183
456
|
|
|
184
457
|
|
|
185
458
|
class Session(TypedDict, total=False):
|
|
459
|
+
initial_url: str
|
|
460
|
+
"""The URL to navigate to when the browser session starts.
|
|
461
|
+
|
|
462
|
+
If not provided, the browser will load an empty page.
|
|
463
|
+
"""
|
|
464
|
+
|
|
186
465
|
live_view: SessionLiveView
|
|
187
466
|
"""Configuration for live viewing the browser session."""
|
|
188
467
|
|
|
189
468
|
proxy: SessionProxy
|
|
190
|
-
"""
|
|
469
|
+
"""Proxy Documentation available at [Proxy Documentation](/advanced/proxy)"""
|
|
191
470
|
|
|
192
471
|
recording: SessionRecording
|
|
193
472
|
"""Configuration for session recording."""
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import List
|
|
4
|
+
from typing_extensions import TypeAlias
|
|
5
|
+
|
|
6
|
+
from .._models import BaseModel
|
|
7
|
+
|
|
8
|
+
__all__ = ["SessionListPagesResponse", "SessionListPagesResponseItem"]
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
class SessionListPagesResponseItem(BaseModel):
|
|
12
|
+
id: str
|
|
13
|
+
"""The unique identifier of the page."""
|
|
14
|
+
|
|
15
|
+
frontend_url: str
|
|
16
|
+
"""The frontend URL for accessing the page."""
|
|
17
|
+
|
|
18
|
+
title: str
|
|
19
|
+
"""The title of the page."""
|
|
20
|
+
|
|
21
|
+
url: str
|
|
22
|
+
"""The URL of the page."""
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
SessionListPagesResponse: TypeAlias = List[SessionListPagesResponseItem]
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import List, Optional
|
|
4
|
+
from datetime import datetime
|
|
5
|
+
|
|
6
|
+
from .._models import BaseModel
|
|
7
|
+
|
|
8
|
+
__all__ = ["SessionRetrieveResponse"]
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
class SessionRetrieveResponse(BaseModel):
|
|
12
|
+
configuration: Optional[object] = None
|
|
13
|
+
"""The configuration settings for the session."""
|
|
14
|
+
|
|
15
|
+
created_at: Optional[datetime] = None
|
|
16
|
+
"""The timestamp when the session was created."""
|
|
17
|
+
|
|
18
|
+
credits_used: Optional[float] = None
|
|
19
|
+
"""The number of credits consumed by the session."""
|
|
20
|
+
|
|
21
|
+
duration: Optional[int] = None
|
|
22
|
+
"""The duration of the session in seconds."""
|
|
23
|
+
|
|
24
|
+
playground: Optional[bool] = None
|
|
25
|
+
"""Whether this is a playground session."""
|
|
26
|
+
|
|
27
|
+
proxy_bytes: Optional[int] = None
|
|
28
|
+
"""The number of bytes transferred through the proxy."""
|
|
29
|
+
|
|
30
|
+
session_id: Optional[str] = None
|
|
31
|
+
"""The unique identifier of the session."""
|
|
32
|
+
|
|
33
|
+
status: Optional[str] = None
|
|
34
|
+
"""The current status of the session."""
|
|
35
|
+
|
|
36
|
+
steps: Optional[List[object]] = None
|
|
37
|
+
"""Array of steps executed in the session."""
|
|
38
|
+
|
|
39
|
+
tags: Optional[object] = None
|
|
40
|
+
"""Tags associated with the session."""
|
|
41
|
+
|
|
42
|
+
team_id: Optional[str] = None
|
|
43
|
+
"""The team ID associated with the session."""
|
|
44
|
+
|
|
45
|
+
tokens: Optional[object] = None
|
|
46
|
+
"""Token usage information."""
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
from typing_extensions import Required, TypedDict
|
|
6
|
+
|
|
7
|
+
from .._types import FileTypes
|
|
8
|
+
|
|
9
|
+
__all__ = ["SessionUploadFileParams"]
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
class SessionUploadFileParams(TypedDict, total=False):
|
|
13
|
+
file: Required[FileTypes]
|
|
14
|
+
"""File to upload to the browser session"""
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import Optional
|
|
4
|
+
|
|
5
|
+
from .._models import BaseModel
|
|
6
|
+
|
|
7
|
+
__all__ = ["SessionUploadFileResponse", "Data"]
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
class Data(BaseModel):
|
|
11
|
+
message: Optional[str] = None
|
|
12
|
+
|
|
13
|
+
status: Optional[str] = None
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
class SessionUploadFileResponse(BaseModel):
|
|
17
|
+
data: Optional[Data] = None
|
|
@@ -2,13 +2,9 @@
|
|
|
2
2
|
|
|
3
3
|
from __future__ import annotations
|
|
4
4
|
|
|
5
|
-
from .mouse_up_params import MouseUpParams as MouseUpParams
|
|
6
|
-
from .mouse_down_params import MouseDownParams as MouseDownParams
|
|
7
5
|
from .mouse_move_params import MouseMoveParams as MouseMoveParams
|
|
8
|
-
from .mouse_up_response import MouseUpResponse as MouseUpResponse
|
|
9
6
|
from .mouse_click_params import MouseClickParams as MouseClickParams
|
|
10
7
|
from .all_status_response import AllStatusResponse as AllStatusResponse
|
|
11
|
-
from .mouse_down_response import MouseDownResponse as MouseDownResponse
|
|
12
8
|
from .mouse_move_response import MouseMoveResponse as MouseMoveResponse
|
|
13
9
|
from .clipboard_set_params import ClipboardSetParams as ClipboardSetParams
|
|
14
10
|
from .keyboard_type_params import KeyboardTypeParams as KeyboardTypeParams
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
from .file_list_response import FileListResponse as FileListResponse
|
|
6
|
+
from .file_upload_params import FileUploadParams as FileUploadParams
|
|
7
|
+
from .file_upload_response import FileUploadResponse as FileUploadResponse
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import List, Optional
|
|
4
|
+
from datetime import datetime
|
|
5
|
+
|
|
6
|
+
from pydantic import Field as FieldInfo
|
|
7
|
+
|
|
8
|
+
from ...._models import BaseModel
|
|
9
|
+
|
|
10
|
+
__all__ = ["FileListResponse", "Data", "DataFile"]
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
class DataFile(BaseModel):
|
|
14
|
+
last_modified: Optional[datetime] = FieldInfo(alias="lastModified", default=None)
|
|
15
|
+
"""When the resource was last modified"""
|
|
16
|
+
|
|
17
|
+
name: Optional[str] = None
|
|
18
|
+
"""The resource name"""
|
|
19
|
+
|
|
20
|
+
size: Optional[int] = None
|
|
21
|
+
"""Resource size in bytes"""
|
|
22
|
+
|
|
23
|
+
type: Optional[str] = None
|
|
24
|
+
"""Resource extension/type"""
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
class Data(BaseModel):
|
|
28
|
+
files: Optional[List[DataFile]] = None
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
class FileListResponse(BaseModel):
|
|
32
|
+
data: Optional[Data] = None
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
from typing_extensions import Required, TypedDict
|
|
6
|
+
|
|
7
|
+
from ...._types import FileTypes
|
|
8
|
+
|
|
9
|
+
__all__ = ["FileUploadParams"]
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
class FileUploadParams(TypedDict, total=False):
|
|
13
|
+
file: Required[FileTypes]
|
|
14
|
+
"""File to upload as agent resource (ZIP files will be extracted automatically)"""
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import Optional
|
|
4
|
+
|
|
5
|
+
from ...._models import BaseModel
|
|
6
|
+
|
|
7
|
+
__all__ = ["FileUploadResponse", "Data"]
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
class Data(BaseModel):
|
|
11
|
+
message: Optional[str] = None
|
|
12
|
+
|
|
13
|
+
status: Optional[str] = None
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
class FileUploadResponse(BaseModel):
|
|
17
|
+
data: Optional[Data] = None
|
|
@@ -2,16 +2,16 @@
|
|
|
2
2
|
|
|
3
3
|
from __future__ import annotations
|
|
4
4
|
|
|
5
|
-
from typing import List
|
|
6
5
|
from typing_extensions import Required, Annotated, TypedDict
|
|
7
6
|
|
|
7
|
+
from ..._types import SequenceNotStr
|
|
8
8
|
from ..._utils import PropertyInfo
|
|
9
9
|
|
|
10
10
|
__all__ = ["KeyboardShortcutParams"]
|
|
11
11
|
|
|
12
12
|
|
|
13
13
|
class KeyboardShortcutParams(TypedDict, total=False):
|
|
14
|
-
keys: Required[
|
|
14
|
+
keys: Required[SequenceNotStr[str]]
|
|
15
15
|
"""Array of keys to press simultaneously"""
|
|
16
16
|
|
|
17
17
|
hold_time: Annotated[int, PropertyInfo(alias="holdTime")]
|
|
@@ -5,10 +5,10 @@ from datetime import datetime
|
|
|
5
5
|
|
|
6
6
|
from ..._models import BaseModel
|
|
7
7
|
|
|
8
|
-
__all__ = ["RecordingListResponse", "Data", "
|
|
8
|
+
__all__ = ["RecordingListResponse", "Data", "DataItem"]
|
|
9
9
|
|
|
10
10
|
|
|
11
|
-
class
|
|
11
|
+
class DataItem(BaseModel):
|
|
12
12
|
id: Optional[str] = None
|
|
13
13
|
"""Unique identifier for the recording"""
|
|
14
14
|
|
|
@@ -31,15 +31,11 @@ class DataDataItem(BaseModel):
|
|
|
31
31
|
"""Suggested filename for the recording"""
|
|
32
32
|
|
|
33
33
|
|
|
34
|
-
class
|
|
34
|
+
class Data(BaseModel):
|
|
35
35
|
count: Optional[int] = None
|
|
36
36
|
"""Total number of video recordings"""
|
|
37
37
|
|
|
38
|
-
items: Optional[List[
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
class Data(BaseModel):
|
|
42
|
-
data: Optional[DataData] = None
|
|
38
|
+
items: Optional[List[DataItem]] = None
|
|
43
39
|
|
|
44
40
|
|
|
45
41
|
class RecordingListResponse(BaseModel):
|