@runwayml/sdk 3.16.0 → 3.18.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 +46 -0
- package/client.d.mts +6 -0
- package/client.d.mts.map +1 -1
- package/client.d.ts +6 -0
- package/client.d.ts.map +1 -1
- package/client.js +6 -0
- package/client.js.map +1 -1
- package/client.mjs +6 -0
- package/client.mjs.map +1 -1
- package/index.d.mts +1 -1
- package/index.d.mts.map +1 -1
- package/index.d.ts +1 -1
- package/index.d.ts.map +1 -1
- package/index.js +3 -1
- package/index.js.map +1 -1
- package/index.mjs +1 -1
- package/index.mjs.map +1 -1
- package/lib/polling.d.mts +22 -0
- package/lib/polling.d.mts.map +1 -1
- package/lib/polling.d.ts +22 -0
- package/lib/polling.d.ts.map +1 -1
- package/lib/polling.js +54 -1
- package/lib/polling.js.map +1 -1
- package/lib/polling.mjs +50 -0
- package/lib/polling.mjs.map +1 -1
- package/package.json +1 -1
- package/resources/index.d.mts +2 -0
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +2 -0
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +5 -1
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +2 -0
- package/resources/index.mjs.map +1 -1
- package/resources/realtime-sessions.d.mts +274 -0
- package/resources/realtime-sessions.d.mts.map +1 -1
- package/resources/realtime-sessions.d.ts +274 -0
- package/resources/realtime-sessions.d.ts.map +1 -1
- package/resources/workflow-invocations.d.mts +195 -0
- package/resources/workflow-invocations.d.mts.map +1 -0
- package/resources/workflow-invocations.d.ts +195 -0
- package/resources/workflow-invocations.d.ts.map +1 -0
- package/resources/workflow-invocations.js +19 -0
- package/resources/workflow-invocations.js.map +1 -0
- package/resources/workflow-invocations.mjs +15 -0
- package/resources/workflow-invocations.mjs.map +1 -0
- package/resources/workflows.d.mts +171 -0
- package/resources/workflows.d.mts.map +1 -0
- package/resources/workflows.d.ts +171 -0
- package/resources/workflows.d.ts.map +1 -0
- package/resources/workflows.js +31 -0
- package/resources/workflows.js.map +1 -0
- package/resources/workflows.mjs +27 -0
- package/resources/workflows.mjs.map +1 -0
- package/src/client.ts +25 -0
- package/src/index.ts +3 -0
- package/src/lib/polling.ts +81 -0
- package/src/resources/index.ts +8 -0
- package/src/resources/realtime-sessions.ts +354 -0
- package/src/resources/workflow-invocations.ts +236 -0
- package/src/resources/workflows.ts +222 -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
|
@@ -161,6 +161,10 @@ export interface RealtimeSessionCreateParams {
|
|
|
161
161
|
* avatar default.
|
|
162
162
|
*/
|
|
163
163
|
startScript?: string;
|
|
164
|
+
/**
|
|
165
|
+
* Tools available to the avatar during the session.
|
|
166
|
+
*/
|
|
167
|
+
tools?: Array<RealtimeSessionCreateParams.ClientEvent | RealtimeSessionCreateParams.BackendRpc>;
|
|
164
168
|
}
|
|
165
169
|
export declare namespace RealtimeSessionCreateParams {
|
|
166
170
|
/**
|
|
@@ -183,6 +187,276 @@ export declare namespace RealtimeSessionCreateParams {
|
|
|
183
187
|
avatarId: string;
|
|
184
188
|
type: 'custom';
|
|
185
189
|
}
|
|
190
|
+
/**
|
|
191
|
+
* A fire-and-forget tool that sends arguments to the frontend client of the
|
|
192
|
+
* realtime session.
|
|
193
|
+
*/
|
|
194
|
+
interface ClientEvent {
|
|
195
|
+
/**
|
|
196
|
+
* A description of when and how the tool should be used. Be specific so the avatar
|
|
197
|
+
* understands the right context to invoke it.
|
|
198
|
+
*/
|
|
199
|
+
description: string;
|
|
200
|
+
/**
|
|
201
|
+
* The tool name. Must start with a letter or underscore, followed by alphanumeric
|
|
202
|
+
* characters or underscores.
|
|
203
|
+
*/
|
|
204
|
+
name: string;
|
|
205
|
+
type: 'client_event';
|
|
206
|
+
parameters?: Array<ClientEvent.String | ClientEvent.Integer | ClientEvent.Number | ClientEvent.Boolean | ClientEvent.Array_ | ClientEvent.Object>;
|
|
207
|
+
}
|
|
208
|
+
namespace ClientEvent {
|
|
209
|
+
interface String {
|
|
210
|
+
/**
|
|
211
|
+
* A description of the parameter.
|
|
212
|
+
*/
|
|
213
|
+
description: string;
|
|
214
|
+
/**
|
|
215
|
+
* The parameter name.
|
|
216
|
+
*/
|
|
217
|
+
name: string;
|
|
218
|
+
type: 'string';
|
|
219
|
+
/**
|
|
220
|
+
* Allowed values for the parameter.
|
|
221
|
+
*/
|
|
222
|
+
enum?: Array<string>;
|
|
223
|
+
/**
|
|
224
|
+
* Whether the parameter is required.
|
|
225
|
+
*/
|
|
226
|
+
required?: boolean;
|
|
227
|
+
}
|
|
228
|
+
interface Integer {
|
|
229
|
+
/**
|
|
230
|
+
* A description of the parameter.
|
|
231
|
+
*/
|
|
232
|
+
description: string;
|
|
233
|
+
/**
|
|
234
|
+
* The parameter name.
|
|
235
|
+
*/
|
|
236
|
+
name: string;
|
|
237
|
+
type: 'integer';
|
|
238
|
+
/**
|
|
239
|
+
* Whether the parameter is required.
|
|
240
|
+
*/
|
|
241
|
+
required?: boolean;
|
|
242
|
+
}
|
|
243
|
+
interface Number {
|
|
244
|
+
/**
|
|
245
|
+
* A description of the parameter.
|
|
246
|
+
*/
|
|
247
|
+
description: string;
|
|
248
|
+
/**
|
|
249
|
+
* The parameter name.
|
|
250
|
+
*/
|
|
251
|
+
name: string;
|
|
252
|
+
type: 'number';
|
|
253
|
+
/**
|
|
254
|
+
* Whether the parameter is required.
|
|
255
|
+
*/
|
|
256
|
+
required?: boolean;
|
|
257
|
+
}
|
|
258
|
+
interface Boolean {
|
|
259
|
+
/**
|
|
260
|
+
* A description of the parameter.
|
|
261
|
+
*/
|
|
262
|
+
description: string;
|
|
263
|
+
/**
|
|
264
|
+
* The parameter name.
|
|
265
|
+
*/
|
|
266
|
+
name: string;
|
|
267
|
+
type: 'boolean';
|
|
268
|
+
/**
|
|
269
|
+
* Whether the parameter is required.
|
|
270
|
+
*/
|
|
271
|
+
required?: boolean;
|
|
272
|
+
}
|
|
273
|
+
interface Array_ {
|
|
274
|
+
/**
|
|
275
|
+
* A description of the parameter.
|
|
276
|
+
*/
|
|
277
|
+
description: string;
|
|
278
|
+
/**
|
|
279
|
+
* Item schema for array elements.
|
|
280
|
+
*/
|
|
281
|
+
items: Array_.Items;
|
|
282
|
+
/**
|
|
283
|
+
* The parameter name.
|
|
284
|
+
*/
|
|
285
|
+
name: string;
|
|
286
|
+
type: 'array';
|
|
287
|
+
/**
|
|
288
|
+
* Whether the parameter is required.
|
|
289
|
+
*/
|
|
290
|
+
required?: boolean;
|
|
291
|
+
}
|
|
292
|
+
namespace Array_ {
|
|
293
|
+
/**
|
|
294
|
+
* Item schema for array elements.
|
|
295
|
+
*/
|
|
296
|
+
interface Items {
|
|
297
|
+
/**
|
|
298
|
+
* The type of each element in the array.
|
|
299
|
+
*/
|
|
300
|
+
type: 'string' | 'integer' | 'number' | 'boolean';
|
|
301
|
+
}
|
|
302
|
+
}
|
|
303
|
+
interface Object {
|
|
304
|
+
/**
|
|
305
|
+
* A description of the parameter.
|
|
306
|
+
*/
|
|
307
|
+
description: string;
|
|
308
|
+
/**
|
|
309
|
+
* The parameter name.
|
|
310
|
+
*/
|
|
311
|
+
name: string;
|
|
312
|
+
/**
|
|
313
|
+
* The properties of the object.
|
|
314
|
+
*/
|
|
315
|
+
properties: Array<unknown>;
|
|
316
|
+
type: 'object';
|
|
317
|
+
/**
|
|
318
|
+
* Whether the parameter is required.
|
|
319
|
+
*/
|
|
320
|
+
required?: boolean;
|
|
321
|
+
}
|
|
322
|
+
}
|
|
323
|
+
/**
|
|
324
|
+
* A tool that makes a round-trip RPC call to your backend server during the
|
|
325
|
+
* session.
|
|
326
|
+
*/
|
|
327
|
+
interface BackendRpc {
|
|
328
|
+
/**
|
|
329
|
+
* A description of when and how the tool should be used. Be specific so the avatar
|
|
330
|
+
* understands the right context to invoke it.
|
|
331
|
+
*/
|
|
332
|
+
description: string;
|
|
333
|
+
/**
|
|
334
|
+
* The tool name. Must start with a letter or underscore, followed by alphanumeric
|
|
335
|
+
* characters or underscores.
|
|
336
|
+
*/
|
|
337
|
+
name: string;
|
|
338
|
+
type: 'backend_rpc';
|
|
339
|
+
parameters?: Array<BackendRpc.String | BackendRpc.Integer | BackendRpc.Number | BackendRpc.Boolean | BackendRpc.Array_ | BackendRpc.Object>;
|
|
340
|
+
/**
|
|
341
|
+
* Maximum time to wait for the backend to respond.
|
|
342
|
+
*/
|
|
343
|
+
timeoutSeconds?: number;
|
|
344
|
+
}
|
|
345
|
+
namespace BackendRpc {
|
|
346
|
+
interface String {
|
|
347
|
+
/**
|
|
348
|
+
* A description of the parameter.
|
|
349
|
+
*/
|
|
350
|
+
description: string;
|
|
351
|
+
/**
|
|
352
|
+
* The parameter name.
|
|
353
|
+
*/
|
|
354
|
+
name: string;
|
|
355
|
+
type: 'string';
|
|
356
|
+
/**
|
|
357
|
+
* Allowed values for the parameter.
|
|
358
|
+
*/
|
|
359
|
+
enum?: Array<string>;
|
|
360
|
+
/**
|
|
361
|
+
* Whether the parameter is required.
|
|
362
|
+
*/
|
|
363
|
+
required?: boolean;
|
|
364
|
+
}
|
|
365
|
+
interface Integer {
|
|
366
|
+
/**
|
|
367
|
+
* A description of the parameter.
|
|
368
|
+
*/
|
|
369
|
+
description: string;
|
|
370
|
+
/**
|
|
371
|
+
* The parameter name.
|
|
372
|
+
*/
|
|
373
|
+
name: string;
|
|
374
|
+
type: 'integer';
|
|
375
|
+
/**
|
|
376
|
+
* Whether the parameter is required.
|
|
377
|
+
*/
|
|
378
|
+
required?: boolean;
|
|
379
|
+
}
|
|
380
|
+
interface Number {
|
|
381
|
+
/**
|
|
382
|
+
* A description of the parameter.
|
|
383
|
+
*/
|
|
384
|
+
description: string;
|
|
385
|
+
/**
|
|
386
|
+
* The parameter name.
|
|
387
|
+
*/
|
|
388
|
+
name: string;
|
|
389
|
+
type: 'number';
|
|
390
|
+
/**
|
|
391
|
+
* Whether the parameter is required.
|
|
392
|
+
*/
|
|
393
|
+
required?: boolean;
|
|
394
|
+
}
|
|
395
|
+
interface Boolean {
|
|
396
|
+
/**
|
|
397
|
+
* A description of the parameter.
|
|
398
|
+
*/
|
|
399
|
+
description: string;
|
|
400
|
+
/**
|
|
401
|
+
* The parameter name.
|
|
402
|
+
*/
|
|
403
|
+
name: string;
|
|
404
|
+
type: 'boolean';
|
|
405
|
+
/**
|
|
406
|
+
* Whether the parameter is required.
|
|
407
|
+
*/
|
|
408
|
+
required?: boolean;
|
|
409
|
+
}
|
|
410
|
+
interface Array_ {
|
|
411
|
+
/**
|
|
412
|
+
* A description of the parameter.
|
|
413
|
+
*/
|
|
414
|
+
description: string;
|
|
415
|
+
/**
|
|
416
|
+
* Item schema for array elements.
|
|
417
|
+
*/
|
|
418
|
+
items: Array_.Items;
|
|
419
|
+
/**
|
|
420
|
+
* The parameter name.
|
|
421
|
+
*/
|
|
422
|
+
name: string;
|
|
423
|
+
type: 'array';
|
|
424
|
+
/**
|
|
425
|
+
* Whether the parameter is required.
|
|
426
|
+
*/
|
|
427
|
+
required?: boolean;
|
|
428
|
+
}
|
|
429
|
+
namespace Array_ {
|
|
430
|
+
/**
|
|
431
|
+
* Item schema for array elements.
|
|
432
|
+
*/
|
|
433
|
+
interface Items {
|
|
434
|
+
/**
|
|
435
|
+
* The type of each element in the array.
|
|
436
|
+
*/
|
|
437
|
+
type: 'string' | 'integer' | 'number' | 'boolean';
|
|
438
|
+
}
|
|
439
|
+
}
|
|
440
|
+
interface Object {
|
|
441
|
+
/**
|
|
442
|
+
* A description of the parameter.
|
|
443
|
+
*/
|
|
444
|
+
description: string;
|
|
445
|
+
/**
|
|
446
|
+
* The parameter name.
|
|
447
|
+
*/
|
|
448
|
+
name: string;
|
|
449
|
+
/**
|
|
450
|
+
* The properties of the object.
|
|
451
|
+
*/
|
|
452
|
+
properties: Array<unknown>;
|
|
453
|
+
type: 'object';
|
|
454
|
+
/**
|
|
455
|
+
* Whether the parameter is required.
|
|
456
|
+
*/
|
|
457
|
+
required?: boolean;
|
|
458
|
+
}
|
|
459
|
+
}
|
|
186
460
|
}
|
|
187
461
|
export declare namespace RealtimeSessions {
|
|
188
462
|
export { type RealtimeSessionCreateResponse as RealtimeSessionCreateResponse, type RealtimeSessionRetrieveResponse as RealtimeSessionRetrieveResponse, type RealtimeSessionCreateParams as RealtimeSessionCreateParams, };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"realtime-sessions.d.ts","sourceRoot":"","sources":["../src/resources/realtime-sessions.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,EAAE,UAAU,EAAE;OAEd,EAAE,cAAc,EAAE;AAGzB,qBAAa,gBAAiB,SAAQ,WAAW;IAC/C;;OAEG;IACH,MAAM,CACJ,IAAI,EAAE,2BAA2B,EACjC,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,6BAA6B,CAAC;IAI5C;;OAEG;IACH,QAAQ,CAAC,EAAE,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,+BAA+B,CAAC;IAI3F;;OAEG;IACH,MAAM,CAAC,EAAE,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,IAAI,CAAC;CAM/D;AAED,MAAM,WAAW,6BAA6B;IAC5C;;OAEG;IACH,EAAE,EAAE,MAAM,CAAC;CACZ;AAED;;GAEG;AACH,MAAM,MAAM,+BAA+B,GACvC,+BAA+B,CAAC,QAAQ,GACxC,+BAA+B,CAAC,KAAK,GACrC,+BAA+B,CAAC,OAAO,GACvC,+BAA+B,CAAC,SAAS,GACzC,+BAA+B,CAAC,MAAM,GACtC,+BAA+B,CAAC,SAAS,CAAC;AAE9C,yBAAiB,+BAA+B,CAAC;IAC/C;;OAEG;IACH,UAAiB,QAAQ;QACvB;;WAEG;QACH,EAAE,EAAE,MAAM,CAAC;QAEX;;WAEG;QACH,SAAS,EAAE,MAAM,CAAC;QAElB,M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,EAAE,MAAM,CAAC;YAEb,IAAI,EAAE,OAAO,CAAC;YAEd;;eAEG;YACH,QAAQ,CAAC,EAAE,OAAO,CAAC;SACpB;QAED,UAAiB,MAAM,CAAC;YACtB;;eAEG;YACH,UAAiB,KAAK;gBACpB;;mBAEG;gBACH,IAAI,EAAE,QAAQ,GAAG,SAAS,GAAG,QAAQ,GAAG,SAAS,CAAC;aACnD;SACF;QAED,UAAiB,MAAM;YACrB;;eAEG;YACH,WAAW,EAAE,MAAM,CAAC;YAEpB;;eAEG;YACH,IAAI,EAAE,MAAM,CAAC;YAEb;;eAEG;YACH,UAAU,EAAE,KAAK,CAAC,OAAO,CAAC,CAAC;YAE3B,IAAI,EAAE,QAAQ,CAAC;YAEf;;eAEG;YACH,QAAQ,CAAC,EAAE,OAAO,CAAC;SACpB;KACF;CACF;AAED,MAAM,CAAC,OAAO,WAAW,gBAAgB,CAAC;IACxC,OAAO,EACL,KAAK,6BAA6B,IAAI,6BAA6B,EACnE,KAAK,+BAA+B,IAAI,+BAA+B,EACvE,KAAK,2BAA2B,IAAI,2BAA2B,GAChE,CAAC;CACH"}
|
|
@@ -0,0 +1,195 @@
|
|
|
1
|
+
import { APIResource } from "../core/resource.mjs";
|
|
2
|
+
import { RequestOptions } from "../internal/request-options.mjs";
|
|
3
|
+
import { APIPromiseWithAwaitableWorkflowInvocation } from "../lib/polling.mjs";
|
|
4
|
+
export declare class WorkflowInvocations extends APIResource {
|
|
5
|
+
/**
|
|
6
|
+
* Return details about a workflow invocation. Consumers of this API should not
|
|
7
|
+
* expect updates more frequent than once every five seconds for a given workflow
|
|
8
|
+
* invocation.
|
|
9
|
+
*/
|
|
10
|
+
retrieve(id: string, options?: RequestOptions): APIPromiseWithAwaitableWorkflowInvocation<WorkflowInvocationRetrieveResponse>;
|
|
11
|
+
}
|
|
12
|
+
/**
|
|
13
|
+
* A pending workflow invocation
|
|
14
|
+
*/
|
|
15
|
+
export type WorkflowInvocationRetrieveResponse = WorkflowInvocationRetrieveResponse.Pending | WorkflowInvocationRetrieveResponse.Throttled | WorkflowInvocationRetrieveResponse.Cancelled | WorkflowInvocationRetrieveResponse.Running | WorkflowInvocationRetrieveResponse.Failed | WorkflowInvocationRetrieveResponse.Succeeded;
|
|
16
|
+
export declare namespace WorkflowInvocationRetrieveResponse {
|
|
17
|
+
/**
|
|
18
|
+
* A pending workflow invocation
|
|
19
|
+
*/
|
|
20
|
+
interface Pending {
|
|
21
|
+
/**
|
|
22
|
+
* The ID of the workflow invocation being returned.
|
|
23
|
+
*/
|
|
24
|
+
id: string;
|
|
25
|
+
/**
|
|
26
|
+
* The timestamp that the workflow invocation was submitted at.
|
|
27
|
+
*/
|
|
28
|
+
createdAt: string;
|
|
29
|
+
status: 'PENDING';
|
|
30
|
+
}
|
|
31
|
+
/**
|
|
32
|
+
* A throttled workflow invocation
|
|
33
|
+
*/
|
|
34
|
+
interface Throttled {
|
|
35
|
+
/**
|
|
36
|
+
* The ID of the workflow invocation being returned.
|
|
37
|
+
*/
|
|
38
|
+
id: string;
|
|
39
|
+
/**
|
|
40
|
+
* The timestamp that the workflow invocation was submitted at.
|
|
41
|
+
*/
|
|
42
|
+
createdAt: string;
|
|
43
|
+
status: 'THROTTLED';
|
|
44
|
+
}
|
|
45
|
+
/**
|
|
46
|
+
* A cancelled or deleted workflow invocation
|
|
47
|
+
*/
|
|
48
|
+
interface Cancelled {
|
|
49
|
+
/**
|
|
50
|
+
* The ID of the workflow invocation being returned.
|
|
51
|
+
*/
|
|
52
|
+
id: string;
|
|
53
|
+
/**
|
|
54
|
+
* The timestamp that the workflow invocation was submitted at.
|
|
55
|
+
*/
|
|
56
|
+
createdAt: string;
|
|
57
|
+
status: 'CANCELLED';
|
|
58
|
+
}
|
|
59
|
+
/**
|
|
60
|
+
* A running workflow invocation
|
|
61
|
+
*/
|
|
62
|
+
interface Running {
|
|
63
|
+
/**
|
|
64
|
+
* The ID of the workflow invocation being returned.
|
|
65
|
+
*/
|
|
66
|
+
id: string;
|
|
67
|
+
/**
|
|
68
|
+
* The timestamp that the workflow invocation was submitted at.
|
|
69
|
+
*/
|
|
70
|
+
createdAt: string;
|
|
71
|
+
/**
|
|
72
|
+
* A record mapping workflow node IDs to arrays of output URLs for nodes that have
|
|
73
|
+
* already completed. This allows streaming partial results while the workflow is
|
|
74
|
+
* still running.
|
|
75
|
+
*/
|
|
76
|
+
output: {
|
|
77
|
+
[key: string]: Array<string>;
|
|
78
|
+
};
|
|
79
|
+
/**
|
|
80
|
+
* A number between 0 and 1 representing the overall workflow execution progress.
|
|
81
|
+
*/
|
|
82
|
+
progress: number;
|
|
83
|
+
status: 'RUNNING';
|
|
84
|
+
/**
|
|
85
|
+
* A record mapping workflow node IDs to their error details. Only present when one
|
|
86
|
+
* or more nodes have errored.
|
|
87
|
+
*/
|
|
88
|
+
nodeErrors?: {
|
|
89
|
+
[key: string]: Running.NodeErrors;
|
|
90
|
+
};
|
|
91
|
+
}
|
|
92
|
+
namespace Running {
|
|
93
|
+
interface NodeErrors {
|
|
94
|
+
/**
|
|
95
|
+
* A human-readable description of the node error.
|
|
96
|
+
*/
|
|
97
|
+
message: string;
|
|
98
|
+
/**
|
|
99
|
+
* The human-readable name of the node that errored.
|
|
100
|
+
*/
|
|
101
|
+
nodeName?: string;
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
/**
|
|
105
|
+
* A failed workflow invocation
|
|
106
|
+
*/
|
|
107
|
+
interface Failed {
|
|
108
|
+
/**
|
|
109
|
+
* The ID of the workflow invocation being returned.
|
|
110
|
+
*/
|
|
111
|
+
id: string;
|
|
112
|
+
/**
|
|
113
|
+
* The timestamp that the workflow invocation was submitted at.
|
|
114
|
+
*/
|
|
115
|
+
createdAt: string;
|
|
116
|
+
/**
|
|
117
|
+
* A human-friendly reason for the failure. We do not recommend returning this to
|
|
118
|
+
* users directly without adding context.
|
|
119
|
+
*/
|
|
120
|
+
failure: string;
|
|
121
|
+
status: 'FAILED';
|
|
122
|
+
/**
|
|
123
|
+
* A machine-readable error code for the failure. See
|
|
124
|
+
* https://docs.dev.runwayml.com/errors/task-failures/ for more information.
|
|
125
|
+
*/
|
|
126
|
+
failureCode?: string;
|
|
127
|
+
/**
|
|
128
|
+
* A record mapping workflow node IDs to their error details. Only present when one
|
|
129
|
+
* or more nodes have errored.
|
|
130
|
+
*/
|
|
131
|
+
nodeErrors?: {
|
|
132
|
+
[key: string]: Failed.NodeErrors;
|
|
133
|
+
};
|
|
134
|
+
}
|
|
135
|
+
namespace Failed {
|
|
136
|
+
interface NodeErrors {
|
|
137
|
+
/**
|
|
138
|
+
* A human-readable description of the node error.
|
|
139
|
+
*/
|
|
140
|
+
message: string;
|
|
141
|
+
/**
|
|
142
|
+
* The human-readable name of the node that errored.
|
|
143
|
+
*/
|
|
144
|
+
nodeName?: string;
|
|
145
|
+
}
|
|
146
|
+
}
|
|
147
|
+
/**
|
|
148
|
+
* A succeeded workflow invocation
|
|
149
|
+
*/
|
|
150
|
+
interface Succeeded {
|
|
151
|
+
/**
|
|
152
|
+
* The ID of the workflow invocation being returned.
|
|
153
|
+
*/
|
|
154
|
+
id: string;
|
|
155
|
+
/**
|
|
156
|
+
* The timestamp that the workflow invocation was submitted at.
|
|
157
|
+
*/
|
|
158
|
+
createdAt: string;
|
|
159
|
+
/**
|
|
160
|
+
* A record mapping workflow node IDs to arrays of output URLs. Each key is the
|
|
161
|
+
* UUID of a workflow node that produced output, and each value is an array of URLs
|
|
162
|
+
* for that node's artifacts. These URLs will expire within 24-48 hours; fetch the
|
|
163
|
+
* invocation again to get fresh URLs. It is expected that you download the assets
|
|
164
|
+
* at these URLs and store them in your own storage system.
|
|
165
|
+
*/
|
|
166
|
+
output: {
|
|
167
|
+
[key: string]: Array<string>;
|
|
168
|
+
};
|
|
169
|
+
status: 'SUCCEEDED';
|
|
170
|
+
/**
|
|
171
|
+
* A record mapping workflow node IDs to their error details. Even when the overall
|
|
172
|
+
* workflow succeeds, individual nodes may have encountered non-fatal errors. Only
|
|
173
|
+
* present when one or more nodes have errored.
|
|
174
|
+
*/
|
|
175
|
+
nodeErrors?: {
|
|
176
|
+
[key: string]: Succeeded.NodeErrors;
|
|
177
|
+
};
|
|
178
|
+
}
|
|
179
|
+
namespace Succeeded {
|
|
180
|
+
interface NodeErrors {
|
|
181
|
+
/**
|
|
182
|
+
* A human-readable description of the node error.
|
|
183
|
+
*/
|
|
184
|
+
message: string;
|
|
185
|
+
/**
|
|
186
|
+
* The human-readable name of the node that errored.
|
|
187
|
+
*/
|
|
188
|
+
nodeName?: string;
|
|
189
|
+
}
|
|
190
|
+
}
|
|
191
|
+
}
|
|
192
|
+
export declare namespace WorkflowInvocations {
|
|
193
|
+
export { type WorkflowInvocationRetrieveResponse as WorkflowInvocationRetrieveResponse };
|
|
194
|
+
}
|
|
195
|
+
//# sourceMappingURL=workflow-invocations.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"workflow-invocations.d.mts","sourceRoot":"","sources":["../src/resources/workflow-invocations.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,EAAE,cAAc,EAAE;OAElB,EAAE,yCAAyC,EAAoC;AAEtF,qBAAa,mBAAoB,SAAQ,WAAW;IAClD;;;;OAIG;IACH,QAAQ,CACN,EAAE,EAAE,MAAM,EACV,OAAO,CAAC,EAAE,cAAc,GACvB,yCAAyC,CAAC,kCAAkC,CAAC;CAMjF;AAED;;GAEG;AACH,MAAM,MAAM,kCAAkC,GAC1C,kCAAkC,CAAC,OAAO,GAC1C,kCAAkC,CAAC,SAAS,GAC5C,kCAAkC,CAAC,SAAS,GAC5C,kCAAkC,CAAC,OAAO,GAC1C,kCAAkC,CAAC,MAAM,GACzC,kCAAkC,CAAC,SAAS,CAAC;AAEjD,yBAAiB,kCAAkC,CAAC;IAClD;;OAEG;IACH,UAAiB,OAAO;QACtB;;WAEG;QACH,EAAE,EAAE,MAAM,CAAC;QAEX;;WAEG;QACH,SAAS,EAAE,MAAM,CAAC;QAElB,MA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AE,CAAC;KACnD;IAED,UAAiB,MAAM,CAAC;QACtB,UAAiB,UAAU;YACzB;;eAEG;YACH,OAAO,EAAE,MAAM,CAAC;YAEhB;;eAEG;YACH,QAAQ,CAAC,EAAE,MAAM,CAAC;SACnB;KACF;IAED;;OAEG;IACH,UAAiB,SAAS;QACxB;;WAEG;QACH,EAAE,EAAE,MAAM,CAAC;QAEX;;WAEG;QACH,SAAS,EAAE,MAAM,CAAC;QAElB;;;;;;WAMG;QACH,MAAM,EAAE;YAAE,CAAC,GAAG,EAAE,MAAM,GAAG,KAAK,CAAC,MAAM,CAAC,CAAA;SAAE,CAAC;QAEzC,MAAM,EAAE,WAAW,CAAC;QAEpB;;;;WAIG;QACH,UAAU,CAAC,EAAE;YAAE,CAAC,GAAG,EAAE,MAAM,GAAG,SAAS,CAAC,UAAU,CAAA;SAAE,CAAC;KACtD;IAED,UAAiB,SAAS,CAAC;QACzB,UAAiB,UAAU;YACzB;;eAEG;YACH,OAAO,EAAE,MAAM,CAAC;YAEhB;;eAEG;YACH,QAAQ,CAAC,EAAE,MAAM,CAAC;SACnB;KACF;CACF;AAED,MAAM,CAAC,OAAO,WAAW,mBAAmB,CAAC;IAC3C,OAAO,EAAE,KAAK,kCAAkC,IAAI,kCAAkC,EAAE,CAAC;CAC1F"}
|
|
@@ -0,0 +1,195 @@
|
|
|
1
|
+
import { APIResource } from "../core/resource.js";
|
|
2
|
+
import { RequestOptions } from "../internal/request-options.js";
|
|
3
|
+
import { APIPromiseWithAwaitableWorkflowInvocation } from "../lib/polling.js";
|
|
4
|
+
export declare class WorkflowInvocations extends APIResource {
|
|
5
|
+
/**
|
|
6
|
+
* Return details about a workflow invocation. Consumers of this API should not
|
|
7
|
+
* expect updates more frequent than once every five seconds for a given workflow
|
|
8
|
+
* invocation.
|
|
9
|
+
*/
|
|
10
|
+
retrieve(id: string, options?: RequestOptions): APIPromiseWithAwaitableWorkflowInvocation<WorkflowInvocationRetrieveResponse>;
|
|
11
|
+
}
|
|
12
|
+
/**
|
|
13
|
+
* A pending workflow invocation
|
|
14
|
+
*/
|
|
15
|
+
export type WorkflowInvocationRetrieveResponse = WorkflowInvocationRetrieveResponse.Pending | WorkflowInvocationRetrieveResponse.Throttled | WorkflowInvocationRetrieveResponse.Cancelled | WorkflowInvocationRetrieveResponse.Running | WorkflowInvocationRetrieveResponse.Failed | WorkflowInvocationRetrieveResponse.Succeeded;
|
|
16
|
+
export declare namespace WorkflowInvocationRetrieveResponse {
|
|
17
|
+
/**
|
|
18
|
+
* A pending workflow invocation
|
|
19
|
+
*/
|
|
20
|
+
interface Pending {
|
|
21
|
+
/**
|
|
22
|
+
* The ID of the workflow invocation being returned.
|
|
23
|
+
*/
|
|
24
|
+
id: string;
|
|
25
|
+
/**
|
|
26
|
+
* The timestamp that the workflow invocation was submitted at.
|
|
27
|
+
*/
|
|
28
|
+
createdAt: string;
|
|
29
|
+
status: 'PENDING';
|
|
30
|
+
}
|
|
31
|
+
/**
|
|
32
|
+
* A throttled workflow invocation
|
|
33
|
+
*/
|
|
34
|
+
interface Throttled {
|
|
35
|
+
/**
|
|
36
|
+
* The ID of the workflow invocation being returned.
|
|
37
|
+
*/
|
|
38
|
+
id: string;
|
|
39
|
+
/**
|
|
40
|
+
* The timestamp that the workflow invocation was submitted at.
|
|
41
|
+
*/
|
|
42
|
+
createdAt: string;
|
|
43
|
+
status: 'THROTTLED';
|
|
44
|
+
}
|
|
45
|
+
/**
|
|
46
|
+
* A cancelled or deleted workflow invocation
|
|
47
|
+
*/
|
|
48
|
+
interface Cancelled {
|
|
49
|
+
/**
|
|
50
|
+
* The ID of the workflow invocation being returned.
|
|
51
|
+
*/
|
|
52
|
+
id: string;
|
|
53
|
+
/**
|
|
54
|
+
* The timestamp that the workflow invocation was submitted at.
|
|
55
|
+
*/
|
|
56
|
+
createdAt: string;
|
|
57
|
+
status: 'CANCELLED';
|
|
58
|
+
}
|
|
59
|
+
/**
|
|
60
|
+
* A running workflow invocation
|
|
61
|
+
*/
|
|
62
|
+
interface Running {
|
|
63
|
+
/**
|
|
64
|
+
* The ID of the workflow invocation being returned.
|
|
65
|
+
*/
|
|
66
|
+
id: string;
|
|
67
|
+
/**
|
|
68
|
+
* The timestamp that the workflow invocation was submitted at.
|
|
69
|
+
*/
|
|
70
|
+
createdAt: string;
|
|
71
|
+
/**
|
|
72
|
+
* A record mapping workflow node IDs to arrays of output URLs for nodes that have
|
|
73
|
+
* already completed. This allows streaming partial results while the workflow is
|
|
74
|
+
* still running.
|
|
75
|
+
*/
|
|
76
|
+
output: {
|
|
77
|
+
[key: string]: Array<string>;
|
|
78
|
+
};
|
|
79
|
+
/**
|
|
80
|
+
* A number between 0 and 1 representing the overall workflow execution progress.
|
|
81
|
+
*/
|
|
82
|
+
progress: number;
|
|
83
|
+
status: 'RUNNING';
|
|
84
|
+
/**
|
|
85
|
+
* A record mapping workflow node IDs to their error details. Only present when one
|
|
86
|
+
* or more nodes have errored.
|
|
87
|
+
*/
|
|
88
|
+
nodeErrors?: {
|
|
89
|
+
[key: string]: Running.NodeErrors;
|
|
90
|
+
};
|
|
91
|
+
}
|
|
92
|
+
namespace Running {
|
|
93
|
+
interface NodeErrors {
|
|
94
|
+
/**
|
|
95
|
+
* A human-readable description of the node error.
|
|
96
|
+
*/
|
|
97
|
+
message: string;
|
|
98
|
+
/**
|
|
99
|
+
* The human-readable name of the node that errored.
|
|
100
|
+
*/
|
|
101
|
+
nodeName?: string;
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
/**
|
|
105
|
+
* A failed workflow invocation
|
|
106
|
+
*/
|
|
107
|
+
interface Failed {
|
|
108
|
+
/**
|
|
109
|
+
* The ID of the workflow invocation being returned.
|
|
110
|
+
*/
|
|
111
|
+
id: string;
|
|
112
|
+
/**
|
|
113
|
+
* The timestamp that the workflow invocation was submitted at.
|
|
114
|
+
*/
|
|
115
|
+
createdAt: string;
|
|
116
|
+
/**
|
|
117
|
+
* A human-friendly reason for the failure. We do not recommend returning this to
|
|
118
|
+
* users directly without adding context.
|
|
119
|
+
*/
|
|
120
|
+
failure: string;
|
|
121
|
+
status: 'FAILED';
|
|
122
|
+
/**
|
|
123
|
+
* A machine-readable error code for the failure. See
|
|
124
|
+
* https://docs.dev.runwayml.com/errors/task-failures/ for more information.
|
|
125
|
+
*/
|
|
126
|
+
failureCode?: string;
|
|
127
|
+
/**
|
|
128
|
+
* A record mapping workflow node IDs to their error details. Only present when one
|
|
129
|
+
* or more nodes have errored.
|
|
130
|
+
*/
|
|
131
|
+
nodeErrors?: {
|
|
132
|
+
[key: string]: Failed.NodeErrors;
|
|
133
|
+
};
|
|
134
|
+
}
|
|
135
|
+
namespace Failed {
|
|
136
|
+
interface NodeErrors {
|
|
137
|
+
/**
|
|
138
|
+
* A human-readable description of the node error.
|
|
139
|
+
*/
|
|
140
|
+
message: string;
|
|
141
|
+
/**
|
|
142
|
+
* The human-readable name of the node that errored.
|
|
143
|
+
*/
|
|
144
|
+
nodeName?: string;
|
|
145
|
+
}
|
|
146
|
+
}
|
|
147
|
+
/**
|
|
148
|
+
* A succeeded workflow invocation
|
|
149
|
+
*/
|
|
150
|
+
interface Succeeded {
|
|
151
|
+
/**
|
|
152
|
+
* The ID of the workflow invocation being returned.
|
|
153
|
+
*/
|
|
154
|
+
id: string;
|
|
155
|
+
/**
|
|
156
|
+
* The timestamp that the workflow invocation was submitted at.
|
|
157
|
+
*/
|
|
158
|
+
createdAt: string;
|
|
159
|
+
/**
|
|
160
|
+
* A record mapping workflow node IDs to arrays of output URLs. Each key is the
|
|
161
|
+
* UUID of a workflow node that produced output, and each value is an array of URLs
|
|
162
|
+
* for that node's artifacts. These URLs will expire within 24-48 hours; fetch the
|
|
163
|
+
* invocation again to get fresh URLs. It is expected that you download the assets
|
|
164
|
+
* at these URLs and store them in your own storage system.
|
|
165
|
+
*/
|
|
166
|
+
output: {
|
|
167
|
+
[key: string]: Array<string>;
|
|
168
|
+
};
|
|
169
|
+
status: 'SUCCEEDED';
|
|
170
|
+
/**
|
|
171
|
+
* A record mapping workflow node IDs to their error details. Even when the overall
|
|
172
|
+
* workflow succeeds, individual nodes may have encountered non-fatal errors. Only
|
|
173
|
+
* present when one or more nodes have errored.
|
|
174
|
+
*/
|
|
175
|
+
nodeErrors?: {
|
|
176
|
+
[key: string]: Succeeded.NodeErrors;
|
|
177
|
+
};
|
|
178
|
+
}
|
|
179
|
+
namespace Succeeded {
|
|
180
|
+
interface NodeErrors {
|
|
181
|
+
/**
|
|
182
|
+
* A human-readable description of the node error.
|
|
183
|
+
*/
|
|
184
|
+
message: string;
|
|
185
|
+
/**
|
|
186
|
+
* The human-readable name of the node that errored.
|
|
187
|
+
*/
|
|
188
|
+
nodeName?: string;
|
|
189
|
+
}
|
|
190
|
+
}
|
|
191
|
+
}
|
|
192
|
+
export declare namespace WorkflowInvocations {
|
|
193
|
+
export { type WorkflowInvocationRetrieveResponse as WorkflowInvocationRetrieveResponse };
|
|
194
|
+
}
|
|
195
|
+
//# sourceMappingURL=workflow-invocations.d.ts.map
|