@mobilerun/sdk 2.1.0 → 3.0.0
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.
- package/CHANGELOG.md +253 -0
- package/README.md +44 -0
- package/client.d.mts +32 -3
- package/client.d.mts.map +1 -1
- package/client.d.ts +32 -3
- package/client.d.ts.map +1 -1
- package/client.js +29 -7
- package/client.js.map +1 -1
- package/client.mjs +29 -7
- package/client.mjs.map +1 -1
- package/internal/tslib.js +6 -6
- package/internal/utils/query.d.mts +2 -0
- package/internal/utils/query.d.mts.map +1 -0
- package/internal/utils/query.d.ts +2 -0
- package/internal/utils/query.d.ts.map +1 -0
- package/internal/utils/query.js +10 -0
- package/internal/utils/query.js.map +1 -0
- package/internal/utils/query.mjs +6 -0
- package/internal/utils/query.mjs.map +1 -0
- package/internal/utils.d.mts +1 -0
- package/internal/utils.d.ts +1 -0
- package/internal/utils.js +1 -0
- package/internal/utils.js.map +1 -1
- package/internal/utils.mjs +1 -0
- package/package.json +7 -1
- package/resources/agents.d.mts +29 -0
- package/resources/agents.d.mts.map +1 -0
- package/resources/agents.d.ts +29 -0
- package/resources/agents.d.ts.map +1 -0
- package/resources/agents.js +18 -0
- package/resources/agents.js.map +1 -0
- package/resources/agents.mjs +14 -0
- package/resources/agents.mjs.map +1 -0
- package/resources/apps.d.mts +10 -12
- package/resources/apps.d.mts.map +1 -1
- package/resources/apps.d.ts +10 -12
- package/resources/apps.d.ts.map +1 -1
- package/resources/apps.js.map +1 -1
- package/resources/apps.mjs.map +1 -1
- package/resources/carriers.d.mts +233 -0
- package/resources/carriers.d.mts.map +1 -0
- package/resources/carriers.d.ts +233 -0
- package/resources/carriers.d.ts.map +1 -0
- package/resources/carriers.js +46 -0
- package/resources/carriers.js.map +1 -0
- package/resources/carriers.mjs +42 -0
- package/resources/carriers.mjs.map +1 -0
- package/resources/credentials/credentials.d.mts +4 -13
- package/resources/credentials/credentials.d.mts.map +1 -1
- package/resources/credentials/credentials.d.ts +4 -13
- package/resources/credentials/credentials.d.ts.map +1 -1
- package/resources/credentials/credentials.js.map +1 -1
- package/resources/credentials/credentials.mjs.map +1 -1
- package/resources/devices/actions.d.mts +37 -1
- package/resources/devices/actions.d.mts.map +1 -1
- package/resources/devices/actions.d.ts +37 -1
- package/resources/devices/actions.d.ts.map +1 -1
- package/resources/devices/actions.js +36 -0
- package/resources/devices/actions.js.map +1 -1
- package/resources/devices/actions.mjs +36 -0
- package/resources/devices/actions.mjs.map +1 -1
- package/resources/devices/apps.d.mts +4 -0
- package/resources/devices/apps.d.mts.map +1 -1
- package/resources/devices/apps.d.ts +4 -0
- package/resources/devices/apps.d.ts.map +1 -1
- package/resources/devices/devices.d.mts +40 -38
- package/resources/devices/devices.d.mts.map +1 -1
- package/resources/devices/devices.d.ts +40 -38
- package/resources/devices/devices.d.ts.map +1 -1
- package/resources/devices/devices.js +22 -2
- package/resources/devices/devices.js.map +1 -1
- package/resources/devices/devices.mjs +23 -3
- package/resources/devices/devices.mjs.map +1 -1
- package/resources/devices/files.d.mts +108 -0
- package/resources/devices/files.d.mts.map +1 -0
- package/resources/devices/files.d.ts +108 -0
- package/resources/devices/files.d.ts.map +1 -0
- package/resources/devices/files.js +87 -0
- package/resources/devices/files.js.map +1 -0
- package/resources/devices/files.mjs +83 -0
- package/resources/devices/files.mjs.map +1 -0
- package/resources/devices/index.d.mts +7 -2
- package/resources/devices/index.d.mts.map +1 -1
- package/resources/devices/index.d.ts +7 -2
- package/resources/devices/index.d.ts.map +1 -1
- package/resources/devices/index.js +11 -1
- package/resources/devices/index.js.map +1 -1
- package/resources/devices/index.mjs +6 -1
- package/resources/devices/index.mjs.map +1 -1
- package/resources/devices/keyboard.d.mts +10 -2
- package/resources/devices/keyboard.d.mts.map +1 -1
- package/resources/devices/keyboard.d.ts +10 -2
- package/resources/devices/keyboard.d.ts.map +1 -1
- package/resources/devices/location.d.mts +42 -0
- package/resources/devices/location.d.mts.map +1 -0
- package/resources/devices/location.d.ts +42 -0
- package/resources/devices/location.d.ts.map +1 -0
- package/resources/devices/location.js +47 -0
- package/resources/devices/location.js.map +1 -0
- package/resources/devices/location.mjs +43 -0
- package/resources/devices/location.mjs.map +1 -0
- package/resources/devices/packages.d.mts +4 -0
- package/resources/devices/packages.d.mts.map +1 -1
- package/resources/devices/packages.d.ts +4 -0
- package/resources/devices/packages.d.ts.map +1 -1
- package/resources/devices/profile.d.mts +23 -0
- package/resources/devices/profile.d.mts.map +1 -0
- package/resources/devices/profile.d.ts +23 -0
- package/resources/devices/profile.d.ts.map +1 -0
- package/resources/devices/profile.js +30 -0
- package/resources/devices/profile.js.map +1 -0
- package/resources/devices/profile.mjs +26 -0
- package/resources/devices/profile.mjs.map +1 -0
- package/resources/devices/proxy.d.mts +61 -0
- package/resources/devices/proxy.d.mts.map +1 -0
- package/resources/devices/proxy.d.ts +61 -0
- package/resources/devices/proxy.d.ts.map +1 -0
- package/resources/devices/proxy.js +48 -0
- package/resources/devices/proxy.js.map +1 -0
- package/resources/devices/proxy.mjs +44 -0
- package/resources/devices/proxy.mjs.map +1 -0
- package/resources/devices/state.d.mts +8 -19
- package/resources/devices/state.d.mts.map +1 -1
- package/resources/devices/state.d.ts +8 -19
- package/resources/devices/state.d.ts.map +1 -1
- package/resources/devices/state.js +0 -17
- package/resources/devices/state.js.map +1 -1
- package/resources/devices/state.mjs +0 -17
- package/resources/devices/state.mjs.map +1 -1
- package/resources/devices/tasks.d.mts +2 -9
- package/resources/devices/tasks.d.mts.map +1 -1
- package/resources/devices/tasks.d.ts +2 -9
- package/resources/devices/tasks.d.ts.map +1 -1
- package/resources/devices/tasks.js.map +1 -1
- package/resources/devices/tasks.mjs.map +1 -1
- package/resources/devices/time.d.mts +59 -0
- package/resources/devices/time.d.mts.map +1 -0
- package/resources/devices/time.d.ts +59 -0
- package/resources/devices/time.d.ts.map +1 -0
- package/resources/devices/time.js +83 -0
- package/resources/devices/time.js.map +1 -0
- package/resources/devices/time.mjs +79 -0
- package/resources/devices/time.mjs.map +1 -0
- package/resources/hooks.d.mts +5 -30
- package/resources/hooks.d.mts.map +1 -1
- package/resources/hooks.d.ts +5 -30
- package/resources/hooks.d.ts.map +1 -1
- package/resources/hooks.js +3 -0
- package/resources/hooks.js.map +1 -1
- package/resources/hooks.mjs +3 -0
- package/resources/hooks.mjs.map +1 -1
- package/resources/index.d.mts +6 -1
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +6 -1
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +11 -1
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +5 -0
- package/resources/index.mjs.map +1 -1
- package/resources/profiles.d.mts +84 -0
- package/resources/profiles.d.mts.map +1 -0
- package/resources/profiles.d.ts +84 -0
- package/resources/profiles.d.ts.map +1 -0
- package/resources/profiles.js +40 -0
- package/resources/profiles.js.map +1 -0
- package/resources/profiles.mjs +36 -0
- package/resources/profiles.mjs.map +1 -0
- package/resources/proxies.d.mts +72 -0
- package/resources/proxies.d.mts.map +1 -0
- package/resources/proxies.d.ts +72 -0
- package/resources/proxies.d.ts.map +1 -0
- package/resources/proxies.js +40 -0
- package/resources/proxies.js.map +1 -0
- package/resources/proxies.mjs +36 -0
- package/resources/proxies.mjs.map +1 -0
- package/resources/shared.d.mts +95 -0
- package/resources/shared.d.mts.map +1 -0
- package/resources/shared.d.ts +95 -0
- package/resources/shared.d.ts.map +1 -0
- package/resources/shared.js +4 -0
- package/resources/shared.js.map +1 -0
- package/resources/shared.mjs +3 -0
- package/resources/shared.mjs.map +1 -0
- package/resources/tasks/index.d.mts +1 -1
- package/resources/tasks/index.d.mts.map +1 -1
- package/resources/tasks/index.d.ts +1 -1
- package/resources/tasks/index.d.ts.map +1 -1
- package/resources/tasks/index.js.map +1 -1
- package/resources/tasks/index.mjs.map +1 -1
- package/resources/tasks/screenshots.d.mts +3 -0
- package/resources/tasks/screenshots.d.mts.map +1 -1
- package/resources/tasks/screenshots.d.ts +3 -0
- package/resources/tasks/screenshots.d.ts.map +1 -1
- package/resources/tasks/screenshots.js +3 -0
- package/resources/tasks/screenshots.js.map +1 -1
- package/resources/tasks/screenshots.mjs +3 -0
- package/resources/tasks/screenshots.mjs.map +1 -1
- package/resources/tasks/tasks.d.mts +105 -106
- package/resources/tasks/tasks.d.mts.map +1 -1
- package/resources/tasks/tasks.d.ts +105 -106
- package/resources/tasks/tasks.d.ts.map +1 -1
- package/resources/tasks/tasks.js +11 -5
- package/resources/tasks/tasks.js.map +1 -1
- package/resources/tasks/tasks.mjs +11 -5
- package/resources/tasks/tasks.mjs.map +1 -1
- package/resources/tasks/ui-states.d.mts +3 -0
- package/resources/tasks/ui-states.d.mts.map +1 -1
- package/resources/tasks/ui-states.d.ts +3 -0
- package/resources/tasks/ui-states.d.ts.map +1 -1
- package/resources/tasks/ui-states.js +3 -0
- package/resources/tasks/ui-states.js.map +1 -1
- package/resources/tasks/ui-states.mjs +3 -0
- package/resources/tasks/ui-states.mjs.map +1 -1
- package/src/client.ts +113 -10
- package/src/internal/utils/query.ts +7 -0
- package/src/internal/utils.ts +1 -0
- package/src/resources/agents.ts +43 -0
- package/src/resources/apps.ts +11 -19
- package/src/resources/carriers.ts +327 -0
- package/src/resources/credentials/credentials.ts +4 -19
- package/src/resources/devices/actions.ts +84 -0
- package/src/resources/devices/apps.ts +5 -0
- package/src/resources/devices/devices.ts +107 -61
- package/src/resources/devices/files.ts +221 -0
- package/src/resources/devices/index.ts +37 -3
- package/src/resources/devices/keyboard.ts +12 -2
- package/src/resources/devices/location.ts +91 -0
- package/src/resources/devices/packages.ts +5 -0
- package/src/resources/devices/profile.ts +45 -0
- package/src/resources/devices/proxy.ts +115 -0
- package/src/resources/devices/state.ts +10 -44
- package/src/resources/devices/tasks.ts +2 -15
- package/src/resources/devices/time.ts +147 -0
- package/src/resources/hooks.ts +5 -36
- package/src/resources/index.ts +37 -0
- package/src/resources/profiles.ts +133 -0
- package/src/resources/proxies.ts +130 -0
- package/src/resources/shared.ts +149 -0
- package/src/resources/tasks/index.ts +5 -0
- package/src/resources/tasks/screenshots.ts +3 -0
- package/src/resources/tasks/tasks.ts +134 -130
- package/src/resources/tasks/ui-states.ts +3 -0
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
|
|
3
3
|
import { APIResource } from '../../core/resource';
|
|
4
|
+
import * as TasksAPI from './tasks';
|
|
5
|
+
import * as Shared from '../shared';
|
|
4
6
|
import * as ScreenshotsAPI from './screenshots';
|
|
5
7
|
import { MediaResponse, ScreenshotListResponse, ScreenshotRetrieveParams, Screenshots } from './screenshots';
|
|
6
8
|
import * as UiStatesAPI from './ui-states';
|
|
@@ -10,6 +12,9 @@ import { buildHeaders } from '../../internal/headers';
|
|
|
10
12
|
import { RequestOptions } from '../../internal/request-options';
|
|
11
13
|
import { path } from '../../internal/utils/path';
|
|
12
14
|
|
|
15
|
+
/**
|
|
16
|
+
* Tasks API
|
|
17
|
+
*/
|
|
13
18
|
export class Tasks extends APIResource {
|
|
14
19
|
screenshots: ScreenshotsAPI.Screenshots = new ScreenshotsAPI.Screenshots(this._client);
|
|
15
20
|
uiStates: UiStatesAPI.UiStates = new UiStatesAPI.UiStates(this._client);
|
|
@@ -67,12 +72,20 @@ export class Tasks extends APIResource {
|
|
|
67
72
|
* Create and dispatch a new agent task, returning an SSE stream of task events.
|
|
68
73
|
* Cancels the task if the client disconnects.
|
|
69
74
|
*/
|
|
70
|
-
runStreamed(body: TaskRunStreamedParams, options?: RequestOptions): APIPromise<
|
|
71
|
-
return this._client.post('/tasks/stream', {
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
75
|
+
runStreamed(body: TaskRunStreamedParams, options?: RequestOptions): APIPromise<unknown> {
|
|
76
|
+
return this._client.post('/tasks/stream', { body, ...options });
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
/**
|
|
80
|
+
* Send a message to a running agent task. The message ID is delivered via SSE
|
|
81
|
+
* (UserMessageEvent with action=queued).
|
|
82
|
+
*/
|
|
83
|
+
sendMessage(
|
|
84
|
+
taskID: string,
|
|
85
|
+
body: TaskSendMessageParams,
|
|
86
|
+
options?: RequestOptions,
|
|
87
|
+
): APIPromise<TaskSendMessageResponse> {
|
|
88
|
+
return this._client.post(path`/tasks/${taskID}/message`, { body, ...options });
|
|
76
89
|
}
|
|
77
90
|
|
|
78
91
|
/**
|
|
@@ -84,6 +97,12 @@ export class Tasks extends APIResource {
|
|
|
84
97
|
}
|
|
85
98
|
}
|
|
86
99
|
|
|
100
|
+
export interface PackageCredentials {
|
|
101
|
+
credentialNames: Array<string>;
|
|
102
|
+
|
|
103
|
+
packageName: string;
|
|
104
|
+
}
|
|
105
|
+
|
|
87
106
|
export interface Task {
|
|
88
107
|
deviceId: string;
|
|
89
108
|
|
|
@@ -98,11 +117,13 @@ export interface Task {
|
|
|
98
117
|
|
|
99
118
|
id?: string;
|
|
100
119
|
|
|
120
|
+
agentId?: number;
|
|
121
|
+
|
|
101
122
|
apps?: Array<string>;
|
|
102
123
|
|
|
103
124
|
createdAt?: string;
|
|
104
125
|
|
|
105
|
-
credentials?: Array<
|
|
126
|
+
credentials?: Array<PackageCredentials>;
|
|
106
127
|
|
|
107
128
|
displayId?: number;
|
|
108
129
|
|
|
@@ -114,6 +135,8 @@ export interface Task {
|
|
|
114
135
|
|
|
115
136
|
maxSteps?: number;
|
|
116
137
|
|
|
138
|
+
message?: string | null;
|
|
139
|
+
|
|
117
140
|
output?: { [key: string]: unknown } | null;
|
|
118
141
|
|
|
119
142
|
outputSchema?: { [key: string]: unknown } | null;
|
|
@@ -141,15 +164,17 @@ export interface Task {
|
|
|
141
164
|
vpnCountry?: 'US' | 'BR' | 'FR' | 'DE' | 'IN' | 'JP' | 'KR' | 'ZA' | null;
|
|
142
165
|
}
|
|
143
166
|
|
|
144
|
-
export
|
|
145
|
-
export interface Credential {
|
|
146
|
-
credentialNames: Array<string>;
|
|
167
|
+
export type TaskStatus = 'created' | 'running' | 'paused' | 'completed' | 'failed' | 'cancelled';
|
|
147
168
|
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
}
|
|
169
|
+
export interface UsageResult {
|
|
170
|
+
request_tokens: number;
|
|
151
171
|
|
|
152
|
-
|
|
172
|
+
requests: number;
|
|
173
|
+
|
|
174
|
+
response_tokens: number;
|
|
175
|
+
|
|
176
|
+
total_tokens: number;
|
|
177
|
+
}
|
|
153
178
|
|
|
154
179
|
export interface TaskRetrieveResponse {
|
|
155
180
|
/**
|
|
@@ -167,51 +192,39 @@ export interface TaskListResponse {
|
|
|
167
192
|
/**
|
|
168
193
|
* Pagination metadata
|
|
169
194
|
*/
|
|
170
|
-
pagination:
|
|
195
|
+
pagination: Shared.PaginationMeta;
|
|
171
196
|
}
|
|
172
197
|
|
|
173
|
-
export
|
|
198
|
+
export interface TaskGetStatusResponse {
|
|
174
199
|
/**
|
|
175
|
-
*
|
|
200
|
+
* The status of the task
|
|
176
201
|
*/
|
|
177
|
-
|
|
178
|
-
/**
|
|
179
|
-
* Whether there is a next page
|
|
180
|
-
*/
|
|
181
|
-
hasNext: boolean;
|
|
182
|
-
|
|
183
|
-
/**
|
|
184
|
-
* Whether there is a previous page
|
|
185
|
-
*/
|
|
186
|
-
hasPrev: boolean;
|
|
202
|
+
status: TaskStatus;
|
|
187
203
|
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
204
|
+
/**
|
|
205
|
+
* The last agent response (FastAgentResponseEvent or ManagerPlanEvent)
|
|
206
|
+
*/
|
|
207
|
+
lastResponse?: { [key: string]: unknown } | null;
|
|
192
208
|
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
209
|
+
/**
|
|
210
|
+
* The agent's final answer or failure reason
|
|
211
|
+
*/
|
|
212
|
+
message?: string | null;
|
|
197
213
|
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
214
|
+
/**
|
|
215
|
+
* Structured output if outputSchema was set
|
|
216
|
+
*/
|
|
217
|
+
output?: { [key: string]: unknown } | null;
|
|
202
218
|
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
}
|
|
208
|
-
}
|
|
219
|
+
/**
|
|
220
|
+
* Number of steps taken
|
|
221
|
+
*/
|
|
222
|
+
steps?: number | null;
|
|
209
223
|
|
|
210
|
-
export interface TaskGetStatusResponse {
|
|
211
224
|
/**
|
|
212
|
-
*
|
|
225
|
+
* Whether the task succeeded
|
|
213
226
|
*/
|
|
214
|
-
|
|
227
|
+
succeeded?: boolean | null;
|
|
215
228
|
}
|
|
216
229
|
|
|
217
230
|
export interface TaskGetTrajectoryResponse {
|
|
@@ -247,6 +260,7 @@ export interface TaskGetTrajectoryResponse {
|
|
|
247
260
|
| TaskGetTrajectoryResponse.TrajectoryExecutorResponseEvent
|
|
248
261
|
| TaskGetTrajectoryResponse.TrajectoryExecutorActionEvent
|
|
249
262
|
| TaskGetTrajectoryResponse.TrajectoryExecutorActionResultEvent
|
|
263
|
+
| TaskGetTrajectoryResponse.TrajectoryUserMessageEvent
|
|
250
264
|
| TaskGetTrajectoryResponse.TrajectoryUnknownEvent
|
|
251
265
|
>;
|
|
252
266
|
}
|
|
@@ -262,8 +276,6 @@ export namespace TaskGetTrajectoryResponse {
|
|
|
262
276
|
export interface Data {
|
|
263
277
|
id: string;
|
|
264
278
|
|
|
265
|
-
token: string;
|
|
266
|
-
|
|
267
279
|
streamUrl: string;
|
|
268
280
|
}
|
|
269
281
|
}
|
|
@@ -381,6 +393,8 @@ export namespace TaskGetTrajectoryResponse {
|
|
|
381
393
|
* API OpenAPI schema can reference it without the heavy droidrun import.
|
|
382
394
|
*/
|
|
383
395
|
export interface Data {
|
|
396
|
+
message?: string | null;
|
|
397
|
+
|
|
384
398
|
steps?: number | null;
|
|
385
399
|
|
|
386
400
|
structured_output?: { [key: string]: unknown } | null;
|
|
@@ -499,19 +513,7 @@ export namespace TaskGetTrajectoryResponse {
|
|
|
499
513
|
|
|
500
514
|
code?: string | null;
|
|
501
515
|
|
|
502
|
-
usage?:
|
|
503
|
-
}
|
|
504
|
-
|
|
505
|
-
export namespace Data {
|
|
506
|
-
export interface Usage {
|
|
507
|
-
request_tokens: number;
|
|
508
|
-
|
|
509
|
-
requests: number;
|
|
510
|
-
|
|
511
|
-
response_tokens: number;
|
|
512
|
-
|
|
513
|
-
total_tokens: number;
|
|
514
|
-
}
|
|
516
|
+
usage?: TasksAPI.UsageResult | null;
|
|
515
517
|
}
|
|
516
518
|
}
|
|
517
519
|
|
|
@@ -664,19 +666,7 @@ export namespace TaskGetTrajectoryResponse {
|
|
|
664
666
|
export interface Data {
|
|
665
667
|
response: string;
|
|
666
668
|
|
|
667
|
-
usage?:
|
|
668
|
-
}
|
|
669
|
-
|
|
670
|
-
export namespace Data {
|
|
671
|
-
export interface Usage {
|
|
672
|
-
request_tokens: number;
|
|
673
|
-
|
|
674
|
-
requests: number;
|
|
675
|
-
|
|
676
|
-
response_tokens: number;
|
|
677
|
-
|
|
678
|
-
total_tokens: number;
|
|
679
|
-
}
|
|
669
|
+
usage?: TasksAPI.UsageResult | null;
|
|
680
670
|
}
|
|
681
671
|
}
|
|
682
672
|
|
|
@@ -746,19 +736,7 @@ export namespace TaskGetTrajectoryResponse {
|
|
|
746
736
|
export interface Data {
|
|
747
737
|
response: string;
|
|
748
738
|
|
|
749
|
-
usage?:
|
|
750
|
-
}
|
|
751
|
-
|
|
752
|
-
export namespace Data {
|
|
753
|
-
export interface Usage {
|
|
754
|
-
request_tokens: number;
|
|
755
|
-
|
|
756
|
-
requests: number;
|
|
757
|
-
|
|
758
|
-
response_tokens: number;
|
|
759
|
-
|
|
760
|
-
total_tokens: number;
|
|
761
|
-
}
|
|
739
|
+
usage?: TasksAPI.UsageResult | null;
|
|
762
740
|
}
|
|
763
741
|
}
|
|
764
742
|
|
|
@@ -814,6 +792,32 @@ export namespace TaskGetTrajectoryResponse {
|
|
|
814
792
|
}
|
|
815
793
|
}
|
|
816
794
|
|
|
795
|
+
export interface TrajectoryUserMessageEvent {
|
|
796
|
+
/**
|
|
797
|
+
* Tracks the lifecycle of an external user message: queued → applied | dropped.
|
|
798
|
+
*/
|
|
799
|
+
data: TrajectoryUserMessageEvent.Data;
|
|
800
|
+
|
|
801
|
+
event: 'UserMessageEvent';
|
|
802
|
+
}
|
|
803
|
+
|
|
804
|
+
export namespace TrajectoryUserMessageEvent {
|
|
805
|
+
/**
|
|
806
|
+
* Tracks the lifecycle of an external user message: queued → applied | dropped.
|
|
807
|
+
*/
|
|
808
|
+
export interface Data {
|
|
809
|
+
action: string;
|
|
810
|
+
|
|
811
|
+
message_ids: Array<string>;
|
|
812
|
+
|
|
813
|
+
consumer?: string | null;
|
|
814
|
+
|
|
815
|
+
reason?: string | null;
|
|
816
|
+
|
|
817
|
+
step_number?: number | null;
|
|
818
|
+
}
|
|
819
|
+
}
|
|
820
|
+
|
|
817
821
|
export interface TrajectoryUnknownEvent {
|
|
818
822
|
event: string;
|
|
819
823
|
|
|
@@ -828,14 +832,18 @@ export interface TaskRunResponse {
|
|
|
828
832
|
id: string;
|
|
829
833
|
|
|
830
834
|
/**
|
|
831
|
-
* The
|
|
835
|
+
* The URL of the stream
|
|
832
836
|
*/
|
|
833
|
-
|
|
837
|
+
streamUrl: string;
|
|
838
|
+
}
|
|
834
839
|
|
|
840
|
+
export type TaskRunStreamedResponse = unknown;
|
|
841
|
+
|
|
842
|
+
export interface TaskSendMessageResponse {
|
|
835
843
|
/**
|
|
836
|
-
*
|
|
844
|
+
* Whether the message was queued for delivery
|
|
837
845
|
*/
|
|
838
|
-
|
|
846
|
+
sent: boolean;
|
|
839
847
|
}
|
|
840
848
|
|
|
841
849
|
export interface TaskStopResponse {
|
|
@@ -850,14 +858,8 @@ export interface TaskListParams {
|
|
|
850
858
|
|
|
851
859
|
orderByDirection?: 'asc' | 'desc';
|
|
852
860
|
|
|
853
|
-
|
|
854
|
-
* Page number (1-based). If provided, returns paginated results.
|
|
855
|
-
*/
|
|
856
|
-
page?: number | null;
|
|
861
|
+
page?: number;
|
|
857
862
|
|
|
858
|
-
/**
|
|
859
|
-
* Number of items per page
|
|
860
|
-
*/
|
|
861
863
|
pageSize?: number;
|
|
862
864
|
|
|
863
865
|
/**
|
|
@@ -870,20 +872,17 @@ export interface TaskListParams {
|
|
|
870
872
|
|
|
871
873
|
export interface TaskRunParams {
|
|
872
874
|
/**
|
|
873
|
-
* The
|
|
875
|
+
* The ID of the device to run the task on.
|
|
874
876
|
*/
|
|
875
|
-
|
|
877
|
+
deviceId: string;
|
|
876
878
|
|
|
877
879
|
task: string;
|
|
878
880
|
|
|
879
|
-
|
|
881
|
+
agentId?: number;
|
|
880
882
|
|
|
881
|
-
|
|
883
|
+
apps?: Array<string>;
|
|
882
884
|
|
|
883
|
-
|
|
884
|
-
* The ID of the device to run the task on.
|
|
885
|
-
*/
|
|
886
|
-
deviceId?: string | null;
|
|
885
|
+
credentials?: Array<PackageCredentials>;
|
|
887
886
|
|
|
888
887
|
/**
|
|
889
888
|
* The display ID of the device to run the task on.
|
|
@@ -894,6 +893,12 @@ export interface TaskRunParams {
|
|
|
894
893
|
|
|
895
894
|
files?: Array<string>;
|
|
896
895
|
|
|
896
|
+
/**
|
|
897
|
+
* The LLM model identifier to use for the task (e.g.
|
|
898
|
+
* 'google/gemini-3.1-flash-lite-preview')
|
|
899
|
+
*/
|
|
900
|
+
llmModel?: string;
|
|
901
|
+
|
|
897
902
|
maxSteps?: number;
|
|
898
903
|
|
|
899
904
|
outputSchema?: { [key: string]: unknown } | null;
|
|
@@ -909,30 +914,19 @@ export interface TaskRunParams {
|
|
|
909
914
|
vpnCountry?: 'US' | 'BR' | 'FR' | 'DE' | 'IN' | 'JP' | 'KR' | 'ZA' | null;
|
|
910
915
|
}
|
|
911
916
|
|
|
912
|
-
export namespace TaskRunParams {
|
|
913
|
-
export interface Credential {
|
|
914
|
-
credentialNames: Array<string>;
|
|
915
|
-
|
|
916
|
-
packageName: string;
|
|
917
|
-
}
|
|
918
|
-
}
|
|
919
|
-
|
|
920
917
|
export interface TaskRunStreamedParams {
|
|
921
918
|
/**
|
|
922
|
-
* The
|
|
919
|
+
* The ID of the device to run the task on.
|
|
923
920
|
*/
|
|
924
|
-
|
|
921
|
+
deviceId: string;
|
|
925
922
|
|
|
926
923
|
task: string;
|
|
927
924
|
|
|
928
|
-
|
|
925
|
+
agentId?: number;
|
|
929
926
|
|
|
930
|
-
|
|
927
|
+
apps?: Array<string>;
|
|
931
928
|
|
|
932
|
-
|
|
933
|
-
* The ID of the device to run the task on.
|
|
934
|
-
*/
|
|
935
|
-
deviceId?: string | null;
|
|
929
|
+
credentials?: Array<PackageCredentials>;
|
|
936
930
|
|
|
937
931
|
/**
|
|
938
932
|
* The display ID of the device to run the task on.
|
|
@@ -943,6 +937,12 @@ export interface TaskRunStreamedParams {
|
|
|
943
937
|
|
|
944
938
|
files?: Array<string>;
|
|
945
939
|
|
|
940
|
+
/**
|
|
941
|
+
* The LLM model identifier to use for the task (e.g.
|
|
942
|
+
* 'google/gemini-3.1-flash-lite-preview')
|
|
943
|
+
*/
|
|
944
|
+
llmModel?: string;
|
|
945
|
+
|
|
946
946
|
maxSteps?: number;
|
|
947
947
|
|
|
948
948
|
outputSchema?: { [key: string]: unknown } | null;
|
|
@@ -958,12 +958,11 @@ export interface TaskRunStreamedParams {
|
|
|
958
958
|
vpnCountry?: 'US' | 'BR' | 'FR' | 'DE' | 'IN' | 'JP' | 'KR' | 'ZA' | null;
|
|
959
959
|
}
|
|
960
960
|
|
|
961
|
-
export
|
|
962
|
-
|
|
963
|
-
|
|
964
|
-
|
|
965
|
-
|
|
966
|
-
}
|
|
961
|
+
export interface TaskSendMessageParams {
|
|
962
|
+
/**
|
|
963
|
+
* Message to send to the running agent
|
|
964
|
+
*/
|
|
965
|
+
message: string;
|
|
967
966
|
}
|
|
968
967
|
|
|
969
968
|
Tasks.Screenshots = Screenshots;
|
|
@@ -971,17 +970,22 @@ Tasks.UiStates = UiStates;
|
|
|
971
970
|
|
|
972
971
|
export declare namespace Tasks {
|
|
973
972
|
export {
|
|
973
|
+
type PackageCredentials as PackageCredentials,
|
|
974
974
|
type Task as Task,
|
|
975
975
|
type TaskStatus as TaskStatus,
|
|
976
|
+
type UsageResult as UsageResult,
|
|
976
977
|
type TaskRetrieveResponse as TaskRetrieveResponse,
|
|
977
978
|
type TaskListResponse as TaskListResponse,
|
|
978
979
|
type TaskGetStatusResponse as TaskGetStatusResponse,
|
|
979
980
|
type TaskGetTrajectoryResponse as TaskGetTrajectoryResponse,
|
|
980
981
|
type TaskRunResponse as TaskRunResponse,
|
|
982
|
+
type TaskRunStreamedResponse as TaskRunStreamedResponse,
|
|
983
|
+
type TaskSendMessageResponse as TaskSendMessageResponse,
|
|
981
984
|
type TaskStopResponse as TaskStopResponse,
|
|
982
985
|
type TaskListParams as TaskListParams,
|
|
983
986
|
type TaskRunParams as TaskRunParams,
|
|
984
987
|
type TaskRunStreamedParams as TaskRunStreamedParams,
|
|
988
|
+
type TaskSendMessageParams as TaskSendMessageParams,
|
|
985
989
|
};
|
|
986
990
|
|
|
987
991
|
export {
|
|
@@ -6,6 +6,9 @@ import { APIPromise } from '../../core/api-promise';
|
|
|
6
6
|
import { RequestOptions } from '../../internal/request-options';
|
|
7
7
|
import { path } from '../../internal/utils/path';
|
|
8
8
|
|
|
9
|
+
/**
|
|
10
|
+
* Tasks API
|
|
11
|
+
*/
|
|
9
12
|
export class UiStates extends APIResource {
|
|
10
13
|
/**
|
|
11
14
|
* Get a specific UI state by index.
|
package/src/version.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const VERSION = '
|
|
1
|
+
export const VERSION = '3.0.0'; // x-release-please-version
|
package/version.d.mts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "
|
|
1
|
+
export declare const VERSION = "3.0.0";
|
|
2
2
|
//# sourceMappingURL=version.d.mts.map
|
package/version.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "
|
|
1
|
+
export declare const VERSION = "3.0.0";
|
|
2
2
|
//# sourceMappingURL=version.d.ts.map
|
package/version.js
CHANGED
package/version.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export const VERSION = '
|
|
1
|
+
export const VERSION = '3.0.0'; // x-release-please-version
|
|
2
2
|
//# sourceMappingURL=version.mjs.map
|