@mobilerun/sdk 2.2.0 → 4.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 +513 -0
- package/README.md +46 -2
- package/client.d.mts +33 -5
- package/client.d.mts.map +1 -1
- package/client.d.ts +33 -5
- 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/env.js +2 -2
- package/internal/utils/env.js.map +1 -1
- package/internal/utils/env.mjs +2 -2
- package/internal/utils/env.mjs.map +1 -1
- 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 +30 -0
- package/resources/agents.d.mts.map +1 -0
- package/resources/agents.d.ts +30 -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 +63 -35
- package/resources/devices/devices.d.mts.map +1 -1
- package/resources/devices/devices.d.ts +63 -35
- package/resources/devices/devices.d.ts.map +1 -1
- package/resources/devices/devices.js +32 -2
- package/resources/devices/devices.js.map +1 -1
- package/resources/devices/devices.mjs +33 -3
- package/resources/devices/devices.mjs.map +1 -1
- package/resources/devices/esim.d.mts +95 -0
- package/resources/devices/esim.d.mts.map +1 -0
- package/resources/devices/esim.d.ts +95 -0
- package/resources/devices/esim.d.ts.map +1 -0
- package/resources/devices/esim.js +84 -0
- package/resources/devices/esim.js.map +1 -0
- package/resources/devices/esim.mjs +80 -0
- package/resources/devices/esim.mjs.map +1 -0
- 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 +9 -3
- package/resources/devices/index.d.mts.map +1 -1
- package/resources/devices/index.d.ts +9 -3
- package/resources/devices/index.d.ts.map +1 -1
- package/resources/devices/index.js +13 -1
- package/resources/devices/index.js.map +1 -1
- package/resources/devices/index.mjs +7 -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 +92 -0
- package/resources/devices/proxy.d.mts.map +1 -0
- package/resources/devices/proxy.d.ts +92 -0
- package/resources/devices/proxy.d.ts.map +1 -0
- package/resources/devices/proxy.js +65 -0
- package/resources/devices/proxy.js.map +1 -0
- package/resources/devices/proxy.mjs +61 -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 +45 -0
- package/resources/devices/time.d.mts.map +1 -0
- package/resources/devices/time.d.ts +45 -0
- package/resources/devices/time.d.ts.map +1 -0
- package/resources/devices/time.js +64 -0
- package/resources/devices/time.js.map +1 -0
- package/resources/devices/time.mjs +60 -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 +7 -2
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +7 -2
- 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 +103 -0
- package/resources/proxies.d.mts.map +1 -0
- package/resources/proxies.d.ts +103 -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 +104 -0
- package/resources/shared.d.mts.map +1 -0
- package/resources/shared.d.ts +104 -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 +141 -60
- package/resources/tasks/tasks.d.mts.map +1 -1
- package/resources/tasks/tasks.d.ts +141 -60
- 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 +112 -10
- package/src/internal/utils/env.ts +2 -2
- package/src/internal/utils/query.ts +7 -0
- package/src/internal/utils.ts +1 -0
- package/src/resources/agents.ts +45 -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 +171 -50
- package/src/resources/devices/esim.ts +201 -0
- package/src/resources/devices/files.ts +221 -0
- package/src/resources/devices/index.ts +52 -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 +173 -0
- package/src/resources/devices/state.ts +10 -44
- package/src/resources/devices/tasks.ts +2 -15
- package/src/resources/devices/time.ts +114 -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 +182 -0
- package/src/resources/shared.ts +161 -0
- package/src/resources/tasks/index.ts +3 -0
- package/src/resources/tasks/screenshots.ts +3 -0
- package/src/resources/tasks/tasks.ts +191 -68
- 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
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
import { APIResource } from '../../core/resource';
|
|
4
4
|
import * as TasksAPI from './tasks';
|
|
5
|
+
import * as Shared from '../shared';
|
|
5
6
|
import * as ScreenshotsAPI from './screenshots';
|
|
6
7
|
import { MediaResponse, ScreenshotListResponse, ScreenshotRetrieveParams, Screenshots } from './screenshots';
|
|
7
8
|
import * as UiStatesAPI from './ui-states';
|
|
@@ -11,6 +12,9 @@ import { buildHeaders } from '../../internal/headers';
|
|
|
11
12
|
import { RequestOptions } from '../../internal/request-options';
|
|
12
13
|
import { path } from '../../internal/utils/path';
|
|
13
14
|
|
|
15
|
+
/**
|
|
16
|
+
* Tasks API
|
|
17
|
+
*/
|
|
14
18
|
export class Tasks extends APIResource {
|
|
15
19
|
screenshots: ScreenshotsAPI.Screenshots = new ScreenshotsAPI.Screenshots(this._client);
|
|
16
20
|
uiStates: UiStatesAPI.UiStates = new UiStatesAPI.UiStates(this._client);
|
|
@@ -68,12 +72,20 @@ export class Tasks extends APIResource {
|
|
|
68
72
|
* Create and dispatch a new agent task, returning an SSE stream of task events.
|
|
69
73
|
* Cancels the task if the client disconnects.
|
|
70
74
|
*/
|
|
71
|
-
runStreamed(body: TaskRunStreamedParams, options?: RequestOptions): APIPromise<
|
|
72
|
-
return this._client.post('/tasks/stream', {
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
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 });
|
|
77
89
|
}
|
|
78
90
|
|
|
79
91
|
/**
|
|
@@ -105,12 +117,22 @@ export interface Task {
|
|
|
105
117
|
|
|
106
118
|
id?: string;
|
|
107
119
|
|
|
120
|
+
agentId?: number;
|
|
121
|
+
|
|
108
122
|
apps?: Array<string>;
|
|
109
123
|
|
|
124
|
+
cancelRequestedAt?: string | null;
|
|
125
|
+
|
|
126
|
+
claimedAt?: string | null;
|
|
127
|
+
|
|
128
|
+
continueOnFailure?: boolean;
|
|
129
|
+
|
|
110
130
|
createdAt?: string;
|
|
111
131
|
|
|
112
132
|
credentials?: Array<PackageCredentials>;
|
|
113
133
|
|
|
134
|
+
dispatchedAt?: string | null;
|
|
135
|
+
|
|
114
136
|
displayId?: number;
|
|
115
137
|
|
|
116
138
|
executionTimeout?: number;
|
|
@@ -121,6 +143,13 @@ export interface Task {
|
|
|
121
143
|
|
|
122
144
|
maxSteps?: number;
|
|
123
145
|
|
|
146
|
+
/**
|
|
147
|
+
* Memory namespace for cross-task personalization
|
|
148
|
+
*/
|
|
149
|
+
memoryNamespace?: string;
|
|
150
|
+
|
|
151
|
+
message?: string | null;
|
|
152
|
+
|
|
124
153
|
output?: { [key: string]: unknown } | null;
|
|
125
154
|
|
|
126
155
|
outputSchema?: { [key: string]: unknown } | null;
|
|
@@ -133,6 +162,13 @@ export interface Task {
|
|
|
133
162
|
|
|
134
163
|
steps?: number | null;
|
|
135
164
|
|
|
165
|
+
streamUrl?: string | null;
|
|
166
|
+
|
|
167
|
+
/**
|
|
168
|
+
* LLM model used by sub-agent roles: executor, app_opener, structured_output
|
|
169
|
+
*/
|
|
170
|
+
subagentModel?: string;
|
|
171
|
+
|
|
136
172
|
succeeded?: boolean | null;
|
|
137
173
|
|
|
138
174
|
temperature?: number;
|
|
@@ -148,7 +184,15 @@ export interface Task {
|
|
|
148
184
|
vpnCountry?: 'US' | 'BR' | 'FR' | 'DE' | 'IN' | 'JP' | 'KR' | 'ZA' | null;
|
|
149
185
|
}
|
|
150
186
|
|
|
151
|
-
export type TaskStatus =
|
|
187
|
+
export type TaskStatus =
|
|
188
|
+
| 'queued'
|
|
189
|
+
| 'created'
|
|
190
|
+
| 'running'
|
|
191
|
+
| 'cancelling'
|
|
192
|
+
| 'paused'
|
|
193
|
+
| 'completed'
|
|
194
|
+
| 'failed'
|
|
195
|
+
| 'cancelled';
|
|
152
196
|
|
|
153
197
|
export interface UsageResult {
|
|
154
198
|
request_tokens: number;
|
|
@@ -176,51 +220,39 @@ export interface TaskListResponse {
|
|
|
176
220
|
/**
|
|
177
221
|
* Pagination metadata
|
|
178
222
|
*/
|
|
179
|
-
pagination:
|
|
223
|
+
pagination: Shared.PaginationMeta;
|
|
180
224
|
}
|
|
181
225
|
|
|
182
|
-
export
|
|
226
|
+
export interface TaskGetStatusResponse {
|
|
183
227
|
/**
|
|
184
|
-
*
|
|
228
|
+
* The status of the task
|
|
185
229
|
*/
|
|
186
|
-
|
|
187
|
-
/**
|
|
188
|
-
* Whether there is a next page
|
|
189
|
-
*/
|
|
190
|
-
hasNext: boolean;
|
|
191
|
-
|
|
192
|
-
/**
|
|
193
|
-
* Whether there is a previous page
|
|
194
|
-
*/
|
|
195
|
-
hasPrev: boolean;
|
|
230
|
+
status: TaskStatus;
|
|
196
231
|
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
232
|
+
/**
|
|
233
|
+
* The last agent response (FastAgentResponseEvent or ManagerPlanEvent)
|
|
234
|
+
*/
|
|
235
|
+
lastResponse?: { [key: string]: unknown } | null;
|
|
201
236
|
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
237
|
+
/**
|
|
238
|
+
* The agent's final answer or failure reason
|
|
239
|
+
*/
|
|
240
|
+
message?: string | null;
|
|
206
241
|
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
242
|
+
/**
|
|
243
|
+
* Structured output if outputSchema was set
|
|
244
|
+
*/
|
|
245
|
+
output?: { [key: string]: unknown } | null;
|
|
211
246
|
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
}
|
|
217
|
-
}
|
|
247
|
+
/**
|
|
248
|
+
* Number of steps taken
|
|
249
|
+
*/
|
|
250
|
+
steps?: number | null;
|
|
218
251
|
|
|
219
|
-
export interface TaskGetStatusResponse {
|
|
220
252
|
/**
|
|
221
|
-
*
|
|
253
|
+
* Whether the task succeeded
|
|
222
254
|
*/
|
|
223
|
-
|
|
255
|
+
succeeded?: boolean | null;
|
|
224
256
|
}
|
|
225
257
|
|
|
226
258
|
export interface TaskGetTrajectoryResponse {
|
|
@@ -228,6 +260,7 @@ export interface TaskGetTrajectoryResponse {
|
|
|
228
260
|
* The trajectory of the task
|
|
229
261
|
*/
|
|
230
262
|
trajectory: Array<
|
|
263
|
+
| TaskGetTrajectoryResponse.TrajectoryQueuedEvent
|
|
231
264
|
| TaskGetTrajectoryResponse.TrajectoryCreatedEvent
|
|
232
265
|
| TaskGetTrajectoryResponse.TrajectoryExceptionEvent
|
|
233
266
|
| TaskGetTrajectoryResponse.TrajectoryCancelEvent
|
|
@@ -256,11 +289,32 @@ export interface TaskGetTrajectoryResponse {
|
|
|
256
289
|
| TaskGetTrajectoryResponse.TrajectoryExecutorResponseEvent
|
|
257
290
|
| TaskGetTrajectoryResponse.TrajectoryExecutorActionEvent
|
|
258
291
|
| TaskGetTrajectoryResponse.TrajectoryExecutorActionResultEvent
|
|
292
|
+
| TaskGetTrajectoryResponse.TrajectoryUserMessageEvent
|
|
259
293
|
| TaskGetTrajectoryResponse.TrajectoryUnknownEvent
|
|
260
294
|
>;
|
|
261
295
|
}
|
|
262
296
|
|
|
263
297
|
export namespace TaskGetTrajectoryResponse {
|
|
298
|
+
export interface TrajectoryQueuedEvent {
|
|
299
|
+
/**
|
|
300
|
+
* Emitted to SSE clients when the task is waiting in the device queue.
|
|
301
|
+
*/
|
|
302
|
+
data: TrajectoryQueuedEvent.Data;
|
|
303
|
+
|
|
304
|
+
event: 'QueuedEvent';
|
|
305
|
+
}
|
|
306
|
+
|
|
307
|
+
export namespace TrajectoryQueuedEvent {
|
|
308
|
+
/**
|
|
309
|
+
* Emitted to SSE clients when the task is waiting in the device queue.
|
|
310
|
+
*/
|
|
311
|
+
export interface Data {
|
|
312
|
+
id: string;
|
|
313
|
+
|
|
314
|
+
status?: string;
|
|
315
|
+
}
|
|
316
|
+
}
|
|
317
|
+
|
|
264
318
|
export interface TrajectoryCreatedEvent {
|
|
265
319
|
data: TrajectoryCreatedEvent.Data;
|
|
266
320
|
|
|
@@ -271,8 +325,6 @@ export namespace TaskGetTrajectoryResponse {
|
|
|
271
325
|
export interface Data {
|
|
272
326
|
id: string;
|
|
273
327
|
|
|
274
|
-
token: string;
|
|
275
|
-
|
|
276
328
|
streamUrl: string;
|
|
277
329
|
}
|
|
278
330
|
}
|
|
@@ -390,6 +442,8 @@ export namespace TaskGetTrajectoryResponse {
|
|
|
390
442
|
* API OpenAPI schema can reference it without the heavy droidrun import.
|
|
391
443
|
*/
|
|
392
444
|
export interface Data {
|
|
445
|
+
message?: string | null;
|
|
446
|
+
|
|
393
447
|
steps?: number | null;
|
|
394
448
|
|
|
395
449
|
structured_output?: { [key: string]: unknown } | null;
|
|
@@ -787,6 +841,32 @@ export namespace TaskGetTrajectoryResponse {
|
|
|
787
841
|
}
|
|
788
842
|
}
|
|
789
843
|
|
|
844
|
+
export interface TrajectoryUserMessageEvent {
|
|
845
|
+
/**
|
|
846
|
+
* Tracks the lifecycle of an external user message: queued → applied | dropped.
|
|
847
|
+
*/
|
|
848
|
+
data: TrajectoryUserMessageEvent.Data;
|
|
849
|
+
|
|
850
|
+
event: 'UserMessageEvent';
|
|
851
|
+
}
|
|
852
|
+
|
|
853
|
+
export namespace TrajectoryUserMessageEvent {
|
|
854
|
+
/**
|
|
855
|
+
* Tracks the lifecycle of an external user message: queued → applied | dropped.
|
|
856
|
+
*/
|
|
857
|
+
export interface Data {
|
|
858
|
+
action: string;
|
|
859
|
+
|
|
860
|
+
message_ids: Array<string>;
|
|
861
|
+
|
|
862
|
+
consumer?: string | null;
|
|
863
|
+
|
|
864
|
+
reason?: string | null;
|
|
865
|
+
|
|
866
|
+
step_number?: number | null;
|
|
867
|
+
}
|
|
868
|
+
}
|
|
869
|
+
|
|
790
870
|
export interface TrajectoryUnknownEvent {
|
|
791
871
|
event: string;
|
|
792
872
|
|
|
@@ -801,14 +881,23 @@ export interface TaskRunResponse {
|
|
|
801
881
|
id: string;
|
|
802
882
|
|
|
803
883
|
/**
|
|
804
|
-
* The
|
|
884
|
+
* The status of the task (queued or created)
|
|
885
|
+
*/
|
|
886
|
+
status: TaskStatus;
|
|
887
|
+
|
|
888
|
+
/**
|
|
889
|
+
* The URL of the stream (null when queued)
|
|
805
890
|
*/
|
|
806
|
-
|
|
891
|
+
streamUrl?: string | null;
|
|
892
|
+
}
|
|
893
|
+
|
|
894
|
+
export type TaskRunStreamedResponse = unknown;
|
|
807
895
|
|
|
896
|
+
export interface TaskSendMessageResponse {
|
|
808
897
|
/**
|
|
809
|
-
*
|
|
898
|
+
* Whether the message was queued for delivery
|
|
810
899
|
*/
|
|
811
|
-
|
|
900
|
+
sent: boolean;
|
|
812
901
|
}
|
|
813
902
|
|
|
814
903
|
export interface TaskStopResponse {
|
|
@@ -823,14 +912,8 @@ export interface TaskListParams {
|
|
|
823
912
|
|
|
824
913
|
orderByDirection?: 'asc' | 'desc';
|
|
825
914
|
|
|
826
|
-
|
|
827
|
-
* Page number (1-based). If provided, returns paginated results.
|
|
828
|
-
*/
|
|
829
|
-
page?: number | null;
|
|
915
|
+
page?: number;
|
|
830
916
|
|
|
831
|
-
/**
|
|
832
|
-
* Number of items per page
|
|
833
|
-
*/
|
|
834
917
|
pageSize?: number;
|
|
835
918
|
|
|
836
919
|
/**
|
|
@@ -843,20 +926,19 @@ export interface TaskListParams {
|
|
|
843
926
|
|
|
844
927
|
export interface TaskRunParams {
|
|
845
928
|
/**
|
|
846
|
-
* The
|
|
929
|
+
* The ID of the device to run the task on.
|
|
847
930
|
*/
|
|
848
|
-
|
|
931
|
+
deviceId: string;
|
|
849
932
|
|
|
850
933
|
task: string;
|
|
851
934
|
|
|
935
|
+
agentId?: number;
|
|
936
|
+
|
|
852
937
|
apps?: Array<string>;
|
|
853
938
|
|
|
854
|
-
|
|
939
|
+
continueOnFailure?: boolean;
|
|
855
940
|
|
|
856
|
-
|
|
857
|
-
* The ID of the device to run the task on.
|
|
858
|
-
*/
|
|
859
|
-
deviceId?: string | null;
|
|
941
|
+
credentials?: Array<PackageCredentials>;
|
|
860
942
|
|
|
861
943
|
/**
|
|
862
944
|
* The display ID of the device to run the task on.
|
|
@@ -867,14 +949,30 @@ export interface TaskRunParams {
|
|
|
867
949
|
|
|
868
950
|
files?: Array<string>;
|
|
869
951
|
|
|
952
|
+
/**
|
|
953
|
+
* The LLM model identifier to use for the task (e.g.
|
|
954
|
+
* 'google/gemini-3.1-flash-lite-preview')
|
|
955
|
+
*/
|
|
956
|
+
llmModel?: string;
|
|
957
|
+
|
|
870
958
|
maxSteps?: number;
|
|
871
959
|
|
|
960
|
+
/**
|
|
961
|
+
* Memory namespace for cross-task personalization
|
|
962
|
+
*/
|
|
963
|
+
memoryNamespace?: string;
|
|
964
|
+
|
|
872
965
|
outputSchema?: { [key: string]: unknown } | null;
|
|
873
966
|
|
|
874
967
|
reasoning?: boolean;
|
|
875
968
|
|
|
876
969
|
stealth?: boolean;
|
|
877
970
|
|
|
971
|
+
/**
|
|
972
|
+
* LLM model used by sub-agent roles: executor, app_opener, structured_output
|
|
973
|
+
*/
|
|
974
|
+
subagentModel?: string;
|
|
975
|
+
|
|
878
976
|
temperature?: number;
|
|
879
977
|
|
|
880
978
|
vision?: boolean;
|
|
@@ -884,20 +982,19 @@ export interface TaskRunParams {
|
|
|
884
982
|
|
|
885
983
|
export interface TaskRunStreamedParams {
|
|
886
984
|
/**
|
|
887
|
-
* The
|
|
985
|
+
* The ID of the device to run the task on.
|
|
888
986
|
*/
|
|
889
|
-
|
|
987
|
+
deviceId: string;
|
|
890
988
|
|
|
891
989
|
task: string;
|
|
892
990
|
|
|
991
|
+
agentId?: number;
|
|
992
|
+
|
|
893
993
|
apps?: Array<string>;
|
|
894
994
|
|
|
895
|
-
|
|
995
|
+
continueOnFailure?: boolean;
|
|
896
996
|
|
|
897
|
-
|
|
898
|
-
* The ID of the device to run the task on.
|
|
899
|
-
*/
|
|
900
|
-
deviceId?: string | null;
|
|
997
|
+
credentials?: Array<PackageCredentials>;
|
|
901
998
|
|
|
902
999
|
/**
|
|
903
1000
|
* The display ID of the device to run the task on.
|
|
@@ -908,14 +1005,30 @@ export interface TaskRunStreamedParams {
|
|
|
908
1005
|
|
|
909
1006
|
files?: Array<string>;
|
|
910
1007
|
|
|
1008
|
+
/**
|
|
1009
|
+
* The LLM model identifier to use for the task (e.g.
|
|
1010
|
+
* 'google/gemini-3.1-flash-lite-preview')
|
|
1011
|
+
*/
|
|
1012
|
+
llmModel?: string;
|
|
1013
|
+
|
|
911
1014
|
maxSteps?: number;
|
|
912
1015
|
|
|
1016
|
+
/**
|
|
1017
|
+
* Memory namespace for cross-task personalization
|
|
1018
|
+
*/
|
|
1019
|
+
memoryNamespace?: string;
|
|
1020
|
+
|
|
913
1021
|
outputSchema?: { [key: string]: unknown } | null;
|
|
914
1022
|
|
|
915
1023
|
reasoning?: boolean;
|
|
916
1024
|
|
|
917
1025
|
stealth?: boolean;
|
|
918
1026
|
|
|
1027
|
+
/**
|
|
1028
|
+
* LLM model used by sub-agent roles: executor, app_opener, structured_output
|
|
1029
|
+
*/
|
|
1030
|
+
subagentModel?: string;
|
|
1031
|
+
|
|
919
1032
|
temperature?: number;
|
|
920
1033
|
|
|
921
1034
|
vision?: boolean;
|
|
@@ -923,6 +1036,13 @@ export interface TaskRunStreamedParams {
|
|
|
923
1036
|
vpnCountry?: 'US' | 'BR' | 'FR' | 'DE' | 'IN' | 'JP' | 'KR' | 'ZA' | null;
|
|
924
1037
|
}
|
|
925
1038
|
|
|
1039
|
+
export interface TaskSendMessageParams {
|
|
1040
|
+
/**
|
|
1041
|
+
* Message to send to the running agent
|
|
1042
|
+
*/
|
|
1043
|
+
message: string;
|
|
1044
|
+
}
|
|
1045
|
+
|
|
926
1046
|
Tasks.Screenshots = Screenshots;
|
|
927
1047
|
Tasks.UiStates = UiStates;
|
|
928
1048
|
|
|
@@ -937,10 +1057,13 @@ export declare namespace Tasks {
|
|
|
937
1057
|
type TaskGetStatusResponse as TaskGetStatusResponse,
|
|
938
1058
|
type TaskGetTrajectoryResponse as TaskGetTrajectoryResponse,
|
|
939
1059
|
type TaskRunResponse as TaskRunResponse,
|
|
1060
|
+
type TaskRunStreamedResponse as TaskRunStreamedResponse,
|
|
1061
|
+
type TaskSendMessageResponse as TaskSendMessageResponse,
|
|
940
1062
|
type TaskStopResponse as TaskStopResponse,
|
|
941
1063
|
type TaskListParams as TaskListParams,
|
|
942
1064
|
type TaskRunParams as TaskRunParams,
|
|
943
1065
|
type TaskRunStreamedParams as TaskRunStreamedParams,
|
|
1066
|
+
type TaskSendMessageParams as TaskSendMessageParams,
|
|
944
1067
|
};
|
|
945
1068
|
|
|
946
1069
|
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 = '4.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 = "4.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 = "4.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 = '4.0.0'; // x-release-please-version
|
|
2
2
|
//# sourceMappingURL=version.mjs.map
|