cyberdesk 2.2.16 → 2.2.17
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/dist/client/sdk.gen.d.ts +35 -8
- package/dist/client/sdk.gen.js +27 -0
- package/dist/client/types.gen.d.ts +238 -24
- package/dist/index.d.ts +60 -17
- package/dist/index.js +71 -11
- package/package.json +1 -1
package/dist/client/sdk.gen.d.ts
CHANGED
|
@@ -34,8 +34,11 @@ export declare const databaseHealthCheckV1HealthDbGet: <ThrowOnError extends boo
|
|
|
34
34
|
* List all machines for the authenticated organization.
|
|
35
35
|
*
|
|
36
36
|
* Supports pagination and filtering by status.
|
|
37
|
+
*
|
|
38
|
+
* Use the `include` parameter to fetch related resources in the response.
|
|
39
|
+
* Related resources are returned in the `included` array following the JSON:API pattern.
|
|
37
40
|
*/
|
|
38
|
-
export declare const listMachinesV1MachinesGet: <ThrowOnError extends boolean = false>(options?: Options<ListMachinesV1MachinesGetData, ThrowOnError>) => import("@hey-api/client-fetch").RequestResult<import("./types.gen").
|
|
41
|
+
export declare const listMachinesV1MachinesGet: <ThrowOnError extends boolean = false>(options?: Options<ListMachinesV1MachinesGetData, ThrowOnError>) => import("@hey-api/client-fetch").RequestResult<import("./types.gen").PaginatedResponseWithIncludesMachineResponse, import("./types.gen").HttpValidationError, ThrowOnError>;
|
|
39
42
|
/**
|
|
40
43
|
* Create Machine
|
|
41
44
|
* Create a new machine.
|
|
@@ -59,8 +62,11 @@ export declare const deleteMachineV1MachinesMachineIdDelete: <ThrowOnError exten
|
|
|
59
62
|
* Get a specific machine by ID.
|
|
60
63
|
*
|
|
61
64
|
* The machine must belong to the authenticated organization.
|
|
65
|
+
*
|
|
66
|
+
* Use the `include` parameter to fetch related resources in the response.
|
|
67
|
+
* Related resources are returned in the `included` array following the JSON:API pattern.
|
|
62
68
|
*/
|
|
63
|
-
export declare const getMachineV1MachinesMachineIdGet: <ThrowOnError extends boolean = false>(options: Options<GetMachineV1MachinesMachineIdGetData, ThrowOnError>) => import("@hey-api/client-fetch").RequestResult<import("./types.gen").
|
|
69
|
+
export declare const getMachineV1MachinesMachineIdGet: <ThrowOnError extends boolean = false>(options: Options<GetMachineV1MachinesMachineIdGetData, ThrowOnError>) => import("@hey-api/client-fetch").RequestResult<import("./types.gen").MachineResponseWithIncludes, import("./types.gen").HttpValidationError, ThrowOnError>;
|
|
64
70
|
/**
|
|
65
71
|
* Update Machine
|
|
66
72
|
* Update a machine's information.
|
|
@@ -86,8 +92,11 @@ export declare const updateMachinePoolsV1MachinesMachineIdPoolsPut: <ThrowOnErro
|
|
|
86
92
|
/**
|
|
87
93
|
* List Pools
|
|
88
94
|
* List all pools for the organization.
|
|
95
|
+
*
|
|
96
|
+
* Use the `include` parameter to fetch related resources in the response.
|
|
97
|
+
* Related resources are returned in the `included` array following the JSON:API pattern.
|
|
89
98
|
*/
|
|
90
|
-
export declare const listPoolsV1PoolsGet: <ThrowOnError extends boolean = false>(options?: Options<ListPoolsV1PoolsGetData, ThrowOnError>) => import("@hey-api/client-fetch").RequestResult<import("./types.gen").
|
|
99
|
+
export declare const listPoolsV1PoolsGet: <ThrowOnError extends boolean = false>(options?: Options<ListPoolsV1PoolsGetData, ThrowOnError>) => import("@hey-api/client-fetch").RequestResult<import("./types.gen").PaginatedResponseWithIncludesPoolResponse, import("./types.gen").HttpValidationError, ThrowOnError>;
|
|
91
100
|
/**
|
|
92
101
|
* Create Pool
|
|
93
102
|
* Create a new pool for organizing machines.
|
|
@@ -101,8 +110,13 @@ export declare const deletePoolV1PoolsPoolIdDelete: <ThrowOnError extends boolea
|
|
|
101
110
|
/**
|
|
102
111
|
* Get Pool
|
|
103
112
|
* Get a specific pool by ID.
|
|
113
|
+
*
|
|
114
|
+
* Use the `include` parameter to fetch related resources in the response.
|
|
115
|
+
* Related resources are returned in the `included` array following the JSON:API pattern.
|
|
116
|
+
*
|
|
117
|
+
* Note: The `include_machines` parameter is deprecated. Use `include=machines` instead.
|
|
104
118
|
*/
|
|
105
|
-
export declare const getPoolV1PoolsPoolIdGet: <ThrowOnError extends boolean = false>(options: Options<GetPoolV1PoolsPoolIdGetData, ThrowOnError>) => import("@hey-api/client-fetch").RequestResult<import("./types.gen").
|
|
119
|
+
export declare const getPoolV1PoolsPoolIdGet: <ThrowOnError extends boolean = false>(options: Options<GetPoolV1PoolsPoolIdGetData, ThrowOnError>) => import("@hey-api/client-fetch").RequestResult<import("./types.gen").PoolResponseWithIncludes, import("./types.gen").HttpValidationError, ThrowOnError>;
|
|
106
120
|
/**
|
|
107
121
|
* Update Pool
|
|
108
122
|
* Update a pool's details.
|
|
@@ -223,8 +237,12 @@ export declare const updateModelConfigurationV1ModelConfigurationsModelConfigura
|
|
|
223
237
|
*
|
|
224
238
|
* Supports pagination and filtering by workflow, machine, and status.
|
|
225
239
|
* Returns runs with their associated workflow and machine data.
|
|
240
|
+
*
|
|
241
|
+
* Use the `include` parameter to fetch related resources in the response.
|
|
242
|
+
* Related resources are returned in the `included` array following the JSON:API pattern.
|
|
243
|
+
* Resources are deduplicated across all items in the list.
|
|
226
244
|
*/
|
|
227
|
-
export declare const listRunsV1RunsGet: <ThrowOnError extends boolean = false>(options?: Options<ListRunsV1RunsGetData, ThrowOnError>) => import("@hey-api/client-fetch").RequestResult<import("./types.gen").
|
|
245
|
+
export declare const listRunsV1RunsGet: <ThrowOnError extends boolean = false>(options?: Options<ListRunsV1RunsGetData, ThrowOnError>) => import("@hey-api/client-fetch").RequestResult<import("./types.gen").PaginatedResponseWithIncludesRunResponse, import("./types.gen").HttpValidationError, ThrowOnError>;
|
|
228
246
|
/**
|
|
229
247
|
* Create Run
|
|
230
248
|
* Create a new run.
|
|
@@ -248,8 +266,11 @@ export declare const deleteRunV1RunsRunIdDelete: <ThrowOnError extends boolean =
|
|
|
248
266
|
*
|
|
249
267
|
* The run must belong to the authenticated organization.
|
|
250
268
|
* Returns the run with its associated workflow and machine data.
|
|
269
|
+
*
|
|
270
|
+
* Use the `include` parameter to fetch related resources in the response.
|
|
271
|
+
* Related resources are returned in the `included` array following the JSON:API pattern.
|
|
251
272
|
*/
|
|
252
|
-
export declare const getRunV1RunsRunIdGet: <ThrowOnError extends boolean = false>(options: Options<GetRunV1RunsRunIdGetData, ThrowOnError>) => import("@hey-api/client-fetch").RequestResult<import("./types.gen").
|
|
273
|
+
export declare const getRunV1RunsRunIdGet: <ThrowOnError extends boolean = false>(options: Options<GetRunV1RunsRunIdGetData, ThrowOnError>) => import("@hey-api/client-fetch").RequestResult<import("./types.gen").RunResponseWithIncludes, import("./types.gen").HttpValidationError, ThrowOnError>;
|
|
253
274
|
/**
|
|
254
275
|
* Update Run
|
|
255
276
|
* Update a run's data.
|
|
@@ -426,8 +447,11 @@ export declare const updateRequestLogV1RequestLogsLogIdPatch: <ThrowOnError exte
|
|
|
426
447
|
* Supports pagination and filtering by workflow and approval status.
|
|
427
448
|
* Only approved trajectories are used during workflow execution.
|
|
428
449
|
* Returns trajectories with their associated workflow data.
|
|
450
|
+
*
|
|
451
|
+
* Use the `include` parameter to fetch related resources in the response.
|
|
452
|
+
* Related resources are returned in the `included` array following the JSON:API pattern.
|
|
429
453
|
*/
|
|
430
|
-
export declare const listTrajectoriesV1TrajectoriesGet: <ThrowOnError extends boolean = false>(options?: Options<ListTrajectoriesV1TrajectoriesGetData, ThrowOnError>) => import("@hey-api/client-fetch").RequestResult<import("./types.gen").
|
|
454
|
+
export declare const listTrajectoriesV1TrajectoriesGet: <ThrowOnError extends boolean = false>(options?: Options<ListTrajectoriesV1TrajectoriesGetData, ThrowOnError>) => import("@hey-api/client-fetch").RequestResult<import("./types.gen").PaginatedResponseWithIncludesTrajectoryResponse, import("./types.gen").HttpValidationError, ThrowOnError>;
|
|
431
455
|
/**
|
|
432
456
|
* Create Trajectory
|
|
433
457
|
* Create a new trajectory for a workflow.
|
|
@@ -449,8 +473,11 @@ export declare const deleteTrajectoryV1TrajectoriesTrajectoryIdDelete: <ThrowOnE
|
|
|
449
473
|
*
|
|
450
474
|
* Returns the trajectory with its associated workflow data.
|
|
451
475
|
* The trajectory must belong to the authenticated organization.
|
|
476
|
+
*
|
|
477
|
+
* Use the `include` parameter to fetch related resources in the response.
|
|
478
|
+
* Related resources are returned in the `included` array following the JSON:API pattern.
|
|
452
479
|
*/
|
|
453
|
-
export declare const getTrajectoryV1TrajectoriesTrajectoryIdGet: <ThrowOnError extends boolean = false>(options: Options<GetTrajectoryV1TrajectoriesTrajectoryIdGetData, ThrowOnError>) => import("@hey-api/client-fetch").RequestResult<import("./types.gen").
|
|
480
|
+
export declare const getTrajectoryV1TrajectoriesTrajectoryIdGet: <ThrowOnError extends boolean = false>(options: Options<GetTrajectoryV1TrajectoriesTrajectoryIdGetData, ThrowOnError>) => import("@hey-api/client-fetch").RequestResult<import("./types.gen").TrajectoryResponseWithIncludes, import("./types.gen").HttpValidationError, ThrowOnError>;
|
|
454
481
|
/**
|
|
455
482
|
* Update Trajectory
|
|
456
483
|
* Update a trajectory's data.
|
package/dist/client/sdk.gen.js
CHANGED
|
@@ -32,6 +32,9 @@ exports.databaseHealthCheckV1HealthDbGet = databaseHealthCheckV1HealthDbGet;
|
|
|
32
32
|
* List all machines for the authenticated organization.
|
|
33
33
|
*
|
|
34
34
|
* Supports pagination and filtering by status.
|
|
35
|
+
*
|
|
36
|
+
* Use the `include` parameter to fetch related resources in the response.
|
|
37
|
+
* Related resources are returned in the `included` array following the JSON:API pattern.
|
|
35
38
|
*/
|
|
36
39
|
const listMachinesV1MachinesGet = (options) => {
|
|
37
40
|
var _a;
|
|
@@ -84,6 +87,9 @@ exports.deleteMachineV1MachinesMachineIdDelete = deleteMachineV1MachinesMachineI
|
|
|
84
87
|
* Get a specific machine by ID.
|
|
85
88
|
*
|
|
86
89
|
* The machine must belong to the authenticated organization.
|
|
90
|
+
*
|
|
91
|
+
* Use the `include` parameter to fetch related resources in the response.
|
|
92
|
+
* Related resources are returned in the `included` array following the JSON:API pattern.
|
|
87
93
|
*/
|
|
88
94
|
const getMachineV1MachinesMachineIdGet = (options) => {
|
|
89
95
|
var _a;
|
|
@@ -147,6 +153,9 @@ exports.updateMachinePoolsV1MachinesMachineIdPoolsPut = updateMachinePoolsV1Mach
|
|
|
147
153
|
/**
|
|
148
154
|
* List Pools
|
|
149
155
|
* List all pools for the organization.
|
|
156
|
+
*
|
|
157
|
+
* Use the `include` parameter to fetch related resources in the response.
|
|
158
|
+
* Related resources are returned in the `included` array following the JSON:API pattern.
|
|
150
159
|
*/
|
|
151
160
|
const listPoolsV1PoolsGet = (options) => {
|
|
152
161
|
var _a;
|
|
@@ -189,6 +198,11 @@ exports.deletePoolV1PoolsPoolIdDelete = deletePoolV1PoolsPoolIdDelete;
|
|
|
189
198
|
/**
|
|
190
199
|
* Get Pool
|
|
191
200
|
* Get a specific pool by ID.
|
|
201
|
+
*
|
|
202
|
+
* Use the `include` parameter to fetch related resources in the response.
|
|
203
|
+
* Related resources are returned in the `included` array following the JSON:API pattern.
|
|
204
|
+
*
|
|
205
|
+
* Note: The `include_machines` parameter is deprecated. Use `include=machines` instead.
|
|
192
206
|
*/
|
|
193
207
|
const getPoolV1PoolsPoolIdGet = (options) => {
|
|
194
208
|
var _a;
|
|
@@ -480,6 +494,10 @@ exports.updateModelConfigurationV1ModelConfigurationsModelConfigurationIdPatch =
|
|
|
480
494
|
*
|
|
481
495
|
* Supports pagination and filtering by workflow, machine, and status.
|
|
482
496
|
* Returns runs with their associated workflow and machine data.
|
|
497
|
+
*
|
|
498
|
+
* Use the `include` parameter to fetch related resources in the response.
|
|
499
|
+
* Related resources are returned in the `included` array following the JSON:API pattern.
|
|
500
|
+
* Resources are deduplicated across all items in the list.
|
|
483
501
|
*/
|
|
484
502
|
const listRunsV1RunsGet = (options) => {
|
|
485
503
|
var _a;
|
|
@@ -532,6 +550,9 @@ exports.deleteRunV1RunsRunIdDelete = deleteRunV1RunsRunIdDelete;
|
|
|
532
550
|
*
|
|
533
551
|
* The run must belong to the authenticated organization.
|
|
534
552
|
* Returns the run with its associated workflow and machine data.
|
|
553
|
+
*
|
|
554
|
+
* Use the `include` parameter to fetch related resources in the response.
|
|
555
|
+
* Related resources are returned in the `included` array following the JSON:API pattern.
|
|
535
556
|
*/
|
|
536
557
|
const getRunV1RunsRunIdGet = (options) => {
|
|
537
558
|
var _a;
|
|
@@ -908,6 +929,9 @@ exports.updateRequestLogV1RequestLogsLogIdPatch = updateRequestLogV1RequestLogsL
|
|
|
908
929
|
* Supports pagination and filtering by workflow and approval status.
|
|
909
930
|
* Only approved trajectories are used during workflow execution.
|
|
910
931
|
* Returns trajectories with their associated workflow data.
|
|
932
|
+
*
|
|
933
|
+
* Use the `include` parameter to fetch related resources in the response.
|
|
934
|
+
* Related resources are returned in the `included` array following the JSON:API pattern.
|
|
911
935
|
*/
|
|
912
936
|
const listTrajectoriesV1TrajectoriesGet = (options) => {
|
|
913
937
|
var _a;
|
|
@@ -958,6 +982,9 @@ exports.deleteTrajectoryV1TrajectoriesTrajectoryIdDelete = deleteTrajectoryV1Tra
|
|
|
958
982
|
*
|
|
959
983
|
* Returns the trajectory with its associated workflow data.
|
|
960
984
|
* The trajectory must belong to the authenticated organization.
|
|
985
|
+
*
|
|
986
|
+
* Use the `include` parameter to fetch related resources in the response.
|
|
987
|
+
* Related resources are returned in the `included` array following the JSON:API pattern.
|
|
961
988
|
*/
|
|
962
989
|
const getTrajectoryV1TrajectoriesTrajectoryIdGet = (options) => {
|
|
963
990
|
var _a;
|
|
@@ -96,6 +96,33 @@ export type FileWriteRequest = {
|
|
|
96
96
|
export type HttpValidationError = {
|
|
97
97
|
detail?: Array<ValidationError>;
|
|
98
98
|
};
|
|
99
|
+
/**
|
|
100
|
+
* A resource in the JSON:API-style included array.
|
|
101
|
+
*
|
|
102
|
+
* Each included resource has a `type` field indicating what kind of resource it is
|
|
103
|
+
* (e.g., "workflow", "machine", "pool") and an `id` field with the resource's UUID.
|
|
104
|
+
* All other fields from the resource's response model are included.
|
|
105
|
+
*
|
|
106
|
+
* Example:
|
|
107
|
+
* {
|
|
108
|
+
* "type": "workflow",
|
|
109
|
+
* "id": "550e8400-e29b-41d4-a716-446655440000",
|
|
110
|
+
* "name": "My Workflow",
|
|
111
|
+
* "main_prompt": "Do something...",
|
|
112
|
+
* "created_at": "2024-01-15T10:30:00Z"
|
|
113
|
+
* }
|
|
114
|
+
*/
|
|
115
|
+
export type IncludedResource = {
|
|
116
|
+
/**
|
|
117
|
+
* Resource type (e.g., 'workflow', 'machine', 'pool')
|
|
118
|
+
*/
|
|
119
|
+
type: string;
|
|
120
|
+
/**
|
|
121
|
+
* Resource UUID
|
|
122
|
+
*/
|
|
123
|
+
id: string;
|
|
124
|
+
[key: string]: unknown | string;
|
|
125
|
+
};
|
|
99
126
|
export type KeyboardKeyRequest = {
|
|
100
127
|
text: string;
|
|
101
128
|
};
|
|
@@ -180,6 +207,38 @@ export type MachineResponse = {
|
|
|
180
207
|
last_seen: string;
|
|
181
208
|
pools?: Array<PoolResponse> | null;
|
|
182
209
|
};
|
|
210
|
+
/**
|
|
211
|
+
* Machine response with optional included related resources.
|
|
212
|
+
*/
|
|
213
|
+
export type MachineResponseWithIncludes = {
|
|
214
|
+
id: string;
|
|
215
|
+
user_id?: string | null;
|
|
216
|
+
organization_id?: string | null;
|
|
217
|
+
name?: string | null;
|
|
218
|
+
fingerprint: string;
|
|
219
|
+
unkey_key_id: string;
|
|
220
|
+
version?: string | null;
|
|
221
|
+
hostname?: string | null;
|
|
222
|
+
os_info?: string | null;
|
|
223
|
+
machine_parameters?: {
|
|
224
|
+
[key: string]: unknown;
|
|
225
|
+
} | null;
|
|
226
|
+
machine_sensitive_parameters?: {
|
|
227
|
+
[key: string]: string;
|
|
228
|
+
} | null;
|
|
229
|
+
status: MachineStatus;
|
|
230
|
+
is_available: boolean;
|
|
231
|
+
reserved_session_id?: string | null;
|
|
232
|
+
linked_keepalive_machine_id?: string | null;
|
|
233
|
+
physical_server_id?: string | null;
|
|
234
|
+
created_at: string;
|
|
235
|
+
last_seen: string;
|
|
236
|
+
pools?: Array<PoolResponse> | null;
|
|
237
|
+
/**
|
|
238
|
+
* Related resources requested via the `include` query parameter
|
|
239
|
+
*/
|
|
240
|
+
included?: Array<IncludedResource> | null;
|
|
241
|
+
};
|
|
183
242
|
export type MachineStatus = 'connected' | 'disconnected' | 'error';
|
|
184
243
|
/**
|
|
185
244
|
* Schema for updating a machine
|
|
@@ -361,38 +420,54 @@ export type PaginatedResponse = {
|
|
|
361
420
|
skip: number;
|
|
362
421
|
limit: number;
|
|
363
422
|
};
|
|
364
|
-
export type
|
|
365
|
-
items: Array<
|
|
423
|
+
export type PaginatedResponseWithIncludesMachineResponse = {
|
|
424
|
+
items: Array<MachineResponse>;
|
|
366
425
|
total: number;
|
|
367
426
|
skip: number;
|
|
368
427
|
limit: number;
|
|
428
|
+
/**
|
|
429
|
+
* Related resources requested via the `include` query parameter
|
|
430
|
+
*/
|
|
431
|
+
included?: Array<IncludedResource> | null;
|
|
369
432
|
};
|
|
370
|
-
export type
|
|
371
|
-
items: Array<
|
|
433
|
+
export type PaginatedResponseWithIncludesPoolResponse = {
|
|
434
|
+
items: Array<PoolResponse>;
|
|
372
435
|
total: number;
|
|
373
436
|
skip: number;
|
|
374
437
|
limit: number;
|
|
438
|
+
/**
|
|
439
|
+
* Related resources requested via the `include` query parameter
|
|
440
|
+
*/
|
|
441
|
+
included?: Array<IncludedResource> | null;
|
|
375
442
|
};
|
|
376
|
-
export type
|
|
377
|
-
items: Array<
|
|
443
|
+
export type PaginatedResponseWithIncludesRunResponse = {
|
|
444
|
+
items: Array<RunResponse>;
|
|
378
445
|
total: number;
|
|
379
446
|
skip: number;
|
|
380
447
|
limit: number;
|
|
448
|
+
/**
|
|
449
|
+
* Related resources requested via the `include` query parameter
|
|
450
|
+
*/
|
|
451
|
+
included?: Array<IncludedResource> | null;
|
|
381
452
|
};
|
|
382
|
-
export type
|
|
383
|
-
items: Array<
|
|
453
|
+
export type PaginatedResponseWithIncludesTrajectoryResponse = {
|
|
454
|
+
items: Array<TrajectoryResponse>;
|
|
384
455
|
total: number;
|
|
385
456
|
skip: number;
|
|
386
457
|
limit: number;
|
|
458
|
+
/**
|
|
459
|
+
* Related resources requested via the `include` query parameter
|
|
460
|
+
*/
|
|
461
|
+
included?: Array<IncludedResource> | null;
|
|
387
462
|
};
|
|
388
|
-
export type
|
|
389
|
-
items: Array<
|
|
463
|
+
export type PaginatedResponseConnectionResponse = {
|
|
464
|
+
items: Array<ConnectionResponse>;
|
|
390
465
|
total: number;
|
|
391
466
|
skip: number;
|
|
392
467
|
limit: number;
|
|
393
468
|
};
|
|
394
|
-
export type
|
|
395
|
-
items: Array<
|
|
469
|
+
export type PaginatedResponseRunAttachmentResponse = {
|
|
470
|
+
items: Array<RunAttachmentResponse>;
|
|
396
471
|
total: number;
|
|
397
472
|
skip: number;
|
|
398
473
|
limit: number;
|
|
@@ -425,6 +500,29 @@ export type PoolResponse = {
|
|
|
425
500
|
*/
|
|
426
501
|
machine_count?: number | null;
|
|
427
502
|
};
|
|
503
|
+
/**
|
|
504
|
+
* Pool response with optional included related resources.
|
|
505
|
+
*/
|
|
506
|
+
export type PoolResponseWithIncludes = {
|
|
507
|
+
id: string;
|
|
508
|
+
organization_id: string;
|
|
509
|
+
name: string;
|
|
510
|
+
description?: string | null;
|
|
511
|
+
created_at: string;
|
|
512
|
+
updated_at: string;
|
|
513
|
+
/**
|
|
514
|
+
* Number of machines in this pool
|
|
515
|
+
*/
|
|
516
|
+
machine_count?: number | null;
|
|
517
|
+
/**
|
|
518
|
+
* [Deprecated] Machines in this pool. Use `included` array instead.
|
|
519
|
+
*/
|
|
520
|
+
machines?: Array<MachineResponse> | null;
|
|
521
|
+
/**
|
|
522
|
+
* Related resources requested via the `include` query parameter
|
|
523
|
+
*/
|
|
524
|
+
included?: Array<IncludedResource> | null;
|
|
525
|
+
};
|
|
428
526
|
/**
|
|
429
527
|
* Schema for updating a pool
|
|
430
528
|
*/
|
|
@@ -738,6 +836,54 @@ export type RunResponse = {
|
|
|
738
836
|
started_at?: string | null;
|
|
739
837
|
ended_at?: string | null;
|
|
740
838
|
};
|
|
839
|
+
/**
|
|
840
|
+
* Run response with optional included related resources.
|
|
841
|
+
*
|
|
842
|
+
* When the `include` query parameter is used, related resources are returned
|
|
843
|
+
* in the `included` array following the JSON:API pattern.
|
|
844
|
+
*
|
|
845
|
+
* Example request: GET /v1/runs/123?include=workflow,machine
|
|
846
|
+
*/
|
|
847
|
+
export type RunResponseWithIncludes = {
|
|
848
|
+
id: string;
|
|
849
|
+
workflow_id: string;
|
|
850
|
+
machine_id?: string | null;
|
|
851
|
+
user_id?: string | null;
|
|
852
|
+
organization_id?: string | null;
|
|
853
|
+
status: RunStatus;
|
|
854
|
+
error?: Array<string> | null;
|
|
855
|
+
output_data?: {
|
|
856
|
+
[key: string]: unknown;
|
|
857
|
+
} | null;
|
|
858
|
+
input_attachment_ids?: Array<string> | null;
|
|
859
|
+
output_attachment_ids?: Array<string> | null;
|
|
860
|
+
run_message_history?: Array<{
|
|
861
|
+
[key: string]: unknown;
|
|
862
|
+
}> | null;
|
|
863
|
+
input_values?: {
|
|
864
|
+
[key: string]: unknown;
|
|
865
|
+
} | null;
|
|
866
|
+
pool_ids?: Array<string> | null;
|
|
867
|
+
sensitive_input_aliases?: {
|
|
868
|
+
[key: string]: string;
|
|
869
|
+
} | null;
|
|
870
|
+
/**
|
|
871
|
+
* Arbitrary usage/billing metadata captured during a run
|
|
872
|
+
*/
|
|
873
|
+
usage_metadata?: {
|
|
874
|
+
[key: string]: unknown;
|
|
875
|
+
} | null;
|
|
876
|
+
session_id?: string | null;
|
|
877
|
+
session_alias?: string | null;
|
|
878
|
+
release_session_after?: boolean | null;
|
|
879
|
+
created_at: string;
|
|
880
|
+
started_at?: string | null;
|
|
881
|
+
ended_at?: string | null;
|
|
882
|
+
/**
|
|
883
|
+
* Related resources requested via the `include` query parameter
|
|
884
|
+
*/
|
|
885
|
+
included?: Array<IncludedResource> | null;
|
|
886
|
+
};
|
|
741
887
|
/**
|
|
742
888
|
* Options for retrying an existing run in-place (same run_id).
|
|
743
889
|
*
|
|
@@ -864,6 +1010,39 @@ export type TrajectoryResponse = {
|
|
|
864
1010
|
created_at: string;
|
|
865
1011
|
updated_at: string;
|
|
866
1012
|
};
|
|
1013
|
+
/**
|
|
1014
|
+
* Trajectory response with optional included related resources.
|
|
1015
|
+
*/
|
|
1016
|
+
export type TrajectoryResponseWithIncludes = {
|
|
1017
|
+
id: string;
|
|
1018
|
+
workflow_id: string;
|
|
1019
|
+
user_id?: string | null;
|
|
1020
|
+
organization_id?: string | null;
|
|
1021
|
+
name?: string | null;
|
|
1022
|
+
description?: string | null;
|
|
1023
|
+
is_approved: boolean;
|
|
1024
|
+
trajectory_data?: Array<{
|
|
1025
|
+
[key: string]: unknown;
|
|
1026
|
+
}> | null;
|
|
1027
|
+
/**
|
|
1028
|
+
* Display dimensions when trajectory was recorded
|
|
1029
|
+
*/
|
|
1030
|
+
dimensions: {
|
|
1031
|
+
[key: string]: number;
|
|
1032
|
+
};
|
|
1033
|
+
/**
|
|
1034
|
+
* Original input values used when trajectory was created
|
|
1035
|
+
*/
|
|
1036
|
+
original_input_values?: {
|
|
1037
|
+
[key: string]: unknown;
|
|
1038
|
+
} | null;
|
|
1039
|
+
created_at: string;
|
|
1040
|
+
updated_at: string;
|
|
1041
|
+
/**
|
|
1042
|
+
* Related resources requested via the `include` query parameter
|
|
1043
|
+
*/
|
|
1044
|
+
included?: Array<IncludedResource> | null;
|
|
1045
|
+
};
|
|
867
1046
|
/**
|
|
868
1047
|
* Schema for updating a trajectory
|
|
869
1048
|
*/
|
|
@@ -1136,6 +1315,10 @@ export type ListMachinesV1MachinesGetData = {
|
|
|
1136
1315
|
* Filter machines created at or before this ISO timestamp (UTC)
|
|
1137
1316
|
*/
|
|
1138
1317
|
created_at_to?: string | null;
|
|
1318
|
+
/**
|
|
1319
|
+
* Comma-separated list of related resources to include. Allowed values: pools. Example: include=pools
|
|
1320
|
+
*/
|
|
1321
|
+
include?: string | null;
|
|
1139
1322
|
skip?: number;
|
|
1140
1323
|
limit?: number;
|
|
1141
1324
|
};
|
|
@@ -1152,7 +1335,7 @@ export type ListMachinesV1MachinesGetResponses = {
|
|
|
1152
1335
|
/**
|
|
1153
1336
|
* Successful Response
|
|
1154
1337
|
*/
|
|
1155
|
-
200:
|
|
1338
|
+
200: PaginatedResponseWithIncludesMachineResponse;
|
|
1156
1339
|
};
|
|
1157
1340
|
export type ListMachinesV1MachinesGetResponse = ListMachinesV1MachinesGetResponses[keyof ListMachinesV1MachinesGetResponses];
|
|
1158
1341
|
export type CreateMachineV1MachinesPostData = {
|
|
@@ -1214,7 +1397,12 @@ export type GetMachineV1MachinesMachineIdGetData = {
|
|
|
1214
1397
|
path: {
|
|
1215
1398
|
machine_id: string;
|
|
1216
1399
|
};
|
|
1217
|
-
query?:
|
|
1400
|
+
query?: {
|
|
1401
|
+
/**
|
|
1402
|
+
* Comma-separated list of related resources to include. Allowed values: pools. Example: include=pools
|
|
1403
|
+
*/
|
|
1404
|
+
include?: string | null;
|
|
1405
|
+
};
|
|
1218
1406
|
url: '/v1/machines/{machine_id}';
|
|
1219
1407
|
};
|
|
1220
1408
|
export type GetMachineV1MachinesMachineIdGetErrors = {
|
|
@@ -1228,7 +1416,7 @@ export type GetMachineV1MachinesMachineIdGetResponses = {
|
|
|
1228
1416
|
/**
|
|
1229
1417
|
* Successful Response
|
|
1230
1418
|
*/
|
|
1231
|
-
200:
|
|
1419
|
+
200: MachineResponseWithIncludes;
|
|
1232
1420
|
};
|
|
1233
1421
|
export type GetMachineV1MachinesMachineIdGetResponse = GetMachineV1MachinesMachineIdGetResponses[keyof GetMachineV1MachinesMachineIdGetResponses];
|
|
1234
1422
|
export type UpdateMachineV1MachinesMachineIdPatchData = {
|
|
@@ -1313,6 +1501,10 @@ export type ListPoolsV1PoolsGetData = {
|
|
|
1313
1501
|
body?: never;
|
|
1314
1502
|
path?: never;
|
|
1315
1503
|
query?: {
|
|
1504
|
+
/**
|
|
1505
|
+
* Comma-separated list of related resources to include. Allowed values: machines. Example: include=machines
|
|
1506
|
+
*/
|
|
1507
|
+
include?: string | null;
|
|
1316
1508
|
skip?: number;
|
|
1317
1509
|
limit?: number;
|
|
1318
1510
|
};
|
|
@@ -1329,7 +1521,7 @@ export type ListPoolsV1PoolsGetResponses = {
|
|
|
1329
1521
|
/**
|
|
1330
1522
|
* Successful Response
|
|
1331
1523
|
*/
|
|
1332
|
-
200:
|
|
1524
|
+
200: PaginatedResponseWithIncludesPoolResponse;
|
|
1333
1525
|
};
|
|
1334
1526
|
export type ListPoolsV1PoolsGetResponse = ListPoolsV1PoolsGetResponses[keyof ListPoolsV1PoolsGetResponses];
|
|
1335
1527
|
export type CreatePoolV1PoolsPostData = {
|
|
@@ -1393,9 +1585,13 @@ export type GetPoolV1PoolsPoolIdGetData = {
|
|
|
1393
1585
|
};
|
|
1394
1586
|
query?: {
|
|
1395
1587
|
/**
|
|
1396
|
-
* Include full machine details
|
|
1588
|
+
* [Deprecated] Use include=machines instead. Include full machine details
|
|
1397
1589
|
*/
|
|
1398
1590
|
include_machines?: boolean;
|
|
1591
|
+
/**
|
|
1592
|
+
* Comma-separated list of related resources to include. Allowed values: machines. Example: include=machines
|
|
1593
|
+
*/
|
|
1594
|
+
include?: string | null;
|
|
1399
1595
|
};
|
|
1400
1596
|
url: '/v1/pools/{pool_id}';
|
|
1401
1597
|
};
|
|
@@ -1410,7 +1606,7 @@ export type GetPoolV1PoolsPoolIdGetResponses = {
|
|
|
1410
1606
|
/**
|
|
1411
1607
|
* Successful Response
|
|
1412
1608
|
*/
|
|
1413
|
-
200:
|
|
1609
|
+
200: PoolResponseWithIncludes;
|
|
1414
1610
|
};
|
|
1415
1611
|
export type GetPoolV1PoolsPoolIdGetResponse = GetPoolV1PoolsPoolIdGetResponses[keyof GetPoolV1PoolsPoolIdGetResponses];
|
|
1416
1612
|
export type UpdatePoolV1PoolsPoolIdPatchData = {
|
|
@@ -1908,6 +2104,10 @@ export type ListRunsV1RunsGetData = {
|
|
|
1908
2104
|
* Optional list of fields to include per run. Always includes: id, workflow_id, machine_id, status, created_at. Provide multiple 'fields=' params to include more.
|
|
1909
2105
|
*/
|
|
1910
2106
|
fields?: Array<RunField> | null;
|
|
2107
|
+
/**
|
|
2108
|
+
* Comma-separated list of related resources to include. Allowed values: workflow, machine, machine.pools. Example: include=workflow,machine
|
|
2109
|
+
*/
|
|
2110
|
+
include?: string | null;
|
|
1911
2111
|
skip?: number;
|
|
1912
2112
|
limit?: number;
|
|
1913
2113
|
};
|
|
@@ -1924,7 +2124,7 @@ export type ListRunsV1RunsGetResponses = {
|
|
|
1924
2124
|
/**
|
|
1925
2125
|
* Successful Response
|
|
1926
2126
|
*/
|
|
1927
|
-
200:
|
|
2127
|
+
200: PaginatedResponseWithIncludesRunResponse;
|
|
1928
2128
|
};
|
|
1929
2129
|
export type ListRunsV1RunsGetResponse = ListRunsV1RunsGetResponses[keyof ListRunsV1RunsGetResponses];
|
|
1930
2130
|
export type CreateRunV1RunsPostData = {
|
|
@@ -1986,7 +2186,12 @@ export type GetRunV1RunsRunIdGetData = {
|
|
|
1986
2186
|
path: {
|
|
1987
2187
|
run_id: string;
|
|
1988
2188
|
};
|
|
1989
|
-
query?:
|
|
2189
|
+
query?: {
|
|
2190
|
+
/**
|
|
2191
|
+
* Comma-separated list of related resources to include. Allowed values: workflow, machine, machine.pools. Example: include=workflow,machine
|
|
2192
|
+
*/
|
|
2193
|
+
include?: string | null;
|
|
2194
|
+
};
|
|
1990
2195
|
url: '/v1/runs/{run_id}';
|
|
1991
2196
|
};
|
|
1992
2197
|
export type GetRunV1RunsRunIdGetErrors = {
|
|
@@ -2000,7 +2205,7 @@ export type GetRunV1RunsRunIdGetResponses = {
|
|
|
2000
2205
|
/**
|
|
2001
2206
|
* Successful Response
|
|
2002
2207
|
*/
|
|
2003
|
-
200:
|
|
2208
|
+
200: RunResponseWithIncludes;
|
|
2004
2209
|
};
|
|
2005
2210
|
export type GetRunV1RunsRunIdGetResponse = GetRunV1RunsRunIdGetResponses[keyof GetRunV1RunsRunIdGetResponses];
|
|
2006
2211
|
export type UpdateRunV1RunsRunIdPatchData = {
|
|
@@ -2597,6 +2802,10 @@ export type ListTrajectoriesV1TrajectoriesGetData = {
|
|
|
2597
2802
|
* Filter trajectories updated at or before this ISO timestamp (UTC)
|
|
2598
2803
|
*/
|
|
2599
2804
|
updated_at_to?: string | null;
|
|
2805
|
+
/**
|
|
2806
|
+
* Comma-separated list of related resources to include. Allowed values: workflow. Example: include=workflow
|
|
2807
|
+
*/
|
|
2808
|
+
include?: string | null;
|
|
2600
2809
|
skip?: number;
|
|
2601
2810
|
limit?: number;
|
|
2602
2811
|
};
|
|
@@ -2613,7 +2822,7 @@ export type ListTrajectoriesV1TrajectoriesGetResponses = {
|
|
|
2613
2822
|
/**
|
|
2614
2823
|
* Successful Response
|
|
2615
2824
|
*/
|
|
2616
|
-
200:
|
|
2825
|
+
200: PaginatedResponseWithIncludesTrajectoryResponse;
|
|
2617
2826
|
};
|
|
2618
2827
|
export type ListTrajectoriesV1TrajectoriesGetResponse = ListTrajectoriesV1TrajectoriesGetResponses[keyof ListTrajectoriesV1TrajectoriesGetResponses];
|
|
2619
2828
|
export type CreateTrajectoryV1TrajectoriesPostData = {
|
|
@@ -2675,7 +2884,12 @@ export type GetTrajectoryV1TrajectoriesTrajectoryIdGetData = {
|
|
|
2675
2884
|
path: {
|
|
2676
2885
|
trajectory_id: string;
|
|
2677
2886
|
};
|
|
2678
|
-
query?:
|
|
2887
|
+
query?: {
|
|
2888
|
+
/**
|
|
2889
|
+
* Comma-separated list of related resources to include. Allowed values: workflow. Example: include=workflow
|
|
2890
|
+
*/
|
|
2891
|
+
include?: string | null;
|
|
2892
|
+
};
|
|
2679
2893
|
url: '/v1/trajectories/{trajectory_id}';
|
|
2680
2894
|
};
|
|
2681
2895
|
export type GetTrajectoryV1TrajectoriesTrajectoryIdGetErrors = {
|
|
@@ -2689,7 +2903,7 @@ export type GetTrajectoryV1TrajectoriesTrajectoryIdGetResponses = {
|
|
|
2689
2903
|
/**
|
|
2690
2904
|
* Successful Response
|
|
2691
2905
|
*/
|
|
2692
|
-
200:
|
|
2906
|
+
200: TrajectoryResponseWithIncludes;
|
|
2693
2907
|
};
|
|
2694
2908
|
export type GetTrajectoryV1TrajectoriesTrajectoryIdGetResponse = GetTrajectoryV1TrajectoriesTrajectoryIdGetResponses[keyof GetTrajectoryV1TrajectoriesTrajectoryIdGetResponses];
|
|
2695
2909
|
export type UpdateTrajectoryV1TrajectoriesTrajectoryIdPatchData = {
|
package/dist/index.d.ts
CHANGED
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
* });
|
|
26
26
|
* ```
|
|
27
27
|
*/
|
|
28
|
-
import { type MachineResponse, type MachinePoolUpdate, type PoolResponse, type PoolCreate, type PoolUpdate, type PoolWithMachines, type MachinePoolAssignment, type WorkflowResponse, type RunResponse, type ConnectionResponse, type TrajectoryResponse, type
|
|
28
|
+
import { type MachineResponse, type MachinePoolUpdate, type PoolResponse, type PoolCreate, type PoolUpdate, type PoolWithMachines, type MachinePoolAssignment, type WorkflowResponse, type RunResponse, type ConnectionResponse, type TrajectoryResponse, type PaginatedResponseWithIncludesMachineResponse, type PaginatedResponseWithIncludesPoolResponse, type PaginatedResponseWorkflowResponse, type PaginatedResponseWithIncludesRunResponse, type PaginatedResponseConnectionResponse, type PaginatedResponseWithIncludesTrajectoryResponse, type MachineStatus, type RunStatus, type ConnectionStatus, type MachineCreate, type WorkflowCreate, type RunCreate, type RunBulkCreate, type RunBulkCreateResponse, type WorkflowChainCreate, type WorkflowChainResponse, type FileInput, type ConnectionCreate, type TrajectoryCreate, type MachineUpdate, type WorkflowUpdate, type RunUpdate, type TrajectoryUpdate, type RunAttachmentCreate, type RunAttachmentUpdate, type RunAttachmentResponse, type RunAttachmentDownloadUrlResponse, type AttachmentType, type IncludedResource, type PaginatedResponseRunAttachmentResponse, type RunRetry, type RunField, type ModelConfigurationCreate, type ModelConfigurationUpdate, type ModelConfigurationResponse, type UsageAggregateResponse, type UsageMode } from './client/types.gen';
|
|
29
29
|
export * from './client/types.gen';
|
|
30
30
|
export * from './client/sdk.gen';
|
|
31
31
|
export * from './client/client.gen';
|
|
@@ -121,6 +121,8 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string,
|
|
|
121
121
|
* @param params.skip - Number of items to skip (for pagination)
|
|
122
122
|
* @param params.limit - Maximum number of items to return
|
|
123
123
|
* @param params.status - Filter by machine status
|
|
124
|
+
* @param params.include - Optional list of related resources to include. Available: ["pools"].
|
|
125
|
+
* Related resources are returned in the `included` array following the JSON:API pattern.
|
|
124
126
|
* @returns Paginated list of machines. Each machine includes desktop parameters
|
|
125
127
|
* (machine_parameters, machine_sensitive_parameters) if configured,
|
|
126
128
|
* plus the current physical_server_id when connected to WebSockets.
|
|
@@ -131,8 +133,9 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string,
|
|
|
131
133
|
status?: MachineStatus;
|
|
132
134
|
created_at_from?: string | Date;
|
|
133
135
|
created_at_to?: string | Date;
|
|
136
|
+
include?: string[];
|
|
134
137
|
}) => Promise<({
|
|
135
|
-
data:
|
|
138
|
+
data: PaginatedResponseWithIncludesMachineResponse;
|
|
136
139
|
error: undefined;
|
|
137
140
|
} | {
|
|
138
141
|
data: undefined;
|
|
@@ -167,18 +170,24 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string,
|
|
|
167
170
|
* Get a specific machine by ID
|
|
168
171
|
*
|
|
169
172
|
* @param machineId - The ID of the machine
|
|
173
|
+
* @param params - Optional parameters
|
|
174
|
+
* @param params.include - Optional list of related resources to include. Available: ["pools"].
|
|
175
|
+
* Related resources are returned in the `included` array following the JSON:API pattern.
|
|
170
176
|
* @returns Machine details including:
|
|
171
177
|
* - Basic info: id, name, status, fingerprint, etc.
|
|
172
178
|
* - machine_parameters: Dict of desktop parameters (if configured)
|
|
173
179
|
* - machine_sensitive_parameters: Dict of sensitive parameter aliases (if configured)
|
|
174
180
|
* - physical_server_id: Fly machine ID currently hosting the WebSocket connection
|
|
175
181
|
* - pools: List of pools this machine belongs to
|
|
182
|
+
* - included: Related resources (when include parameter is used)
|
|
176
183
|
*/
|
|
177
|
-
get: (machineId: string
|
|
184
|
+
get: (machineId: string, params?: {
|
|
185
|
+
include?: string[];
|
|
186
|
+
}) => Promise<({
|
|
178
187
|
data: undefined;
|
|
179
188
|
error: import("./client/types.gen").HttpValidationError;
|
|
180
189
|
} | {
|
|
181
|
-
data:
|
|
190
|
+
data: import("./client/types.gen").MachineResponseWithIncludes;
|
|
182
191
|
error: undefined;
|
|
183
192
|
}) & {
|
|
184
193
|
request: Request;
|
|
@@ -311,16 +320,19 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string,
|
|
|
311
320
|
* @param params - Optional query parameters
|
|
312
321
|
* @param params.skip - Number of items to skip (for pagination)
|
|
313
322
|
* @param params.limit - Maximum number of items to return
|
|
323
|
+
* @param params.include - Optional list of related resources to include. Available: ["machines"].
|
|
324
|
+
* Related resources are returned in the `included` array following the JSON:API pattern.
|
|
314
325
|
* @returns Paginated list of pools
|
|
315
326
|
*/
|
|
316
327
|
list: (params?: {
|
|
317
328
|
skip?: number;
|
|
318
329
|
limit?: number;
|
|
330
|
+
include?: string[];
|
|
319
331
|
}) => Promise<({
|
|
320
332
|
data: undefined;
|
|
321
333
|
error: import("./client/types.gen").HttpValidationError;
|
|
322
334
|
} | {
|
|
323
|
-
data:
|
|
335
|
+
data: PaginatedResponseWithIncludesPoolResponse;
|
|
324
336
|
error: undefined;
|
|
325
337
|
}) & {
|
|
326
338
|
request: Request;
|
|
@@ -354,14 +366,27 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string,
|
|
|
354
366
|
* Get a specific pool by ID
|
|
355
367
|
*
|
|
356
368
|
* @param poolId - The ID of the pool
|
|
357
|
-
* @param
|
|
358
|
-
*
|
|
369
|
+
* @param paramsOrIncludeMachines - Optional. Either a boolean for backward compatibility (deprecated),
|
|
370
|
+
* or an options object with includeMachines and include fields.
|
|
371
|
+
* @returns Pool details with optional included resources
|
|
372
|
+
*
|
|
373
|
+
* @example
|
|
374
|
+
* ```typescript
|
|
375
|
+
* // New style (recommended)
|
|
376
|
+
* const pool = await client.pools.get("pool-id", { include: ["machines"] });
|
|
377
|
+
*
|
|
378
|
+
* // Legacy style (deprecated but still supported)
|
|
379
|
+
* const pool = await client.pools.get("pool-id", true);
|
|
380
|
+
* ```
|
|
359
381
|
*/
|
|
360
|
-
get: (poolId: string,
|
|
382
|
+
get: (poolId: string, paramsOrIncludeMachines?: boolean | {
|
|
383
|
+
includeMachines?: boolean;
|
|
384
|
+
include?: string[];
|
|
385
|
+
}) => Promise<({
|
|
361
386
|
data: undefined;
|
|
362
387
|
error: import("./client/types.gen").HttpValidationError;
|
|
363
388
|
} | {
|
|
364
|
-
data:
|
|
389
|
+
data: import("./client/types.gen").PoolResponseWithIncludes;
|
|
365
390
|
error: undefined;
|
|
366
391
|
}) & {
|
|
367
392
|
request: Request;
|
|
@@ -565,10 +590,13 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string,
|
|
|
565
590
|
* @param params.session_id - Filter by session ID
|
|
566
591
|
* @param params.fields - Optional list of fields to include per run (projection). Available fields include:
|
|
567
592
|
* started_at, ended_at, error, output_data, input_values, usage_metadata, and more.
|
|
593
|
+
* @param params.include - Optional list of related resources to include. Available: ["workflow", "machine", "machine.pools"].
|
|
594
|
+
* Related resources are returned in the `included` array following the JSON:API pattern.
|
|
568
595
|
* @returns Paginated list of runs including timing fields:
|
|
569
596
|
* - created_at: When run was created
|
|
570
597
|
* - started_at: When run execution started (null for SCHEDULING runs)
|
|
571
598
|
* - ended_at: When run completed (null for RUNNING/SCHEDULING runs)
|
|
599
|
+
* - included: Related resources (when include parameter is used)
|
|
572
600
|
*/
|
|
573
601
|
list: (params?: {
|
|
574
602
|
skip?: number;
|
|
@@ -580,11 +608,12 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string,
|
|
|
580
608
|
created_at_from?: string | Date;
|
|
581
609
|
created_at_to?: string | Date;
|
|
582
610
|
fields?: RunField[];
|
|
611
|
+
include?: string[];
|
|
583
612
|
}) => Promise<({
|
|
584
613
|
data: undefined;
|
|
585
614
|
error: import("./client/types.gen").HttpValidationError;
|
|
586
615
|
} | {
|
|
587
|
-
data:
|
|
616
|
+
data: PaginatedResponseWithIncludesRunResponse;
|
|
588
617
|
error: undefined;
|
|
589
618
|
}) & {
|
|
590
619
|
request: Request;
|
|
@@ -704,16 +733,22 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string,
|
|
|
704
733
|
* Get a specific run by ID
|
|
705
734
|
*
|
|
706
735
|
* @param runId - The ID of the run
|
|
736
|
+
* @param params - Optional parameters
|
|
737
|
+
* @param params.include - Optional list of related resources to include. Available: ["workflow", "machine", "machine.pools"].
|
|
738
|
+
* Related resources are returned in the `included` array following the JSON:API pattern.
|
|
707
739
|
* @returns Run details including timing information:
|
|
708
740
|
* - created_at: When run was created
|
|
709
741
|
* - started_at: When run execution started (null if not started)
|
|
710
742
|
* - ended_at: When run completed (null if not finished)
|
|
743
|
+
* - included: Related resources (when include parameter is used)
|
|
711
744
|
*/
|
|
712
|
-
get: (runId: string
|
|
745
|
+
get: (runId: string, params?: {
|
|
746
|
+
include?: string[];
|
|
747
|
+
}) => Promise<({
|
|
713
748
|
data: undefined;
|
|
714
749
|
error: import("./client/types.gen").HttpValidationError;
|
|
715
750
|
} | {
|
|
716
|
-
data:
|
|
751
|
+
data: import("./client/types.gen").RunResponseWithIncludes;
|
|
717
752
|
error: undefined;
|
|
718
753
|
}) & {
|
|
719
754
|
request: Request;
|
|
@@ -827,6 +862,8 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string,
|
|
|
827
862
|
* @param params.created_at_to - Filter created at or before this date
|
|
828
863
|
* @param params.updated_at_from - Filter updated at or after this date
|
|
829
864
|
* @param params.updated_at_to - Filter updated at or before this date
|
|
865
|
+
* @param params.include - Optional list of related resources to include. Available: ["workflow"].
|
|
866
|
+
* Related resources are returned in the `included` array following the JSON:API pattern.
|
|
830
867
|
* @returns Paginated list of trajectories
|
|
831
868
|
*
|
|
832
869
|
* @remarks
|
|
@@ -842,11 +879,12 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string,
|
|
|
842
879
|
created_at_to?: string | Date;
|
|
843
880
|
updated_at_from?: string | Date;
|
|
844
881
|
updated_at_to?: string | Date;
|
|
882
|
+
include?: string[];
|
|
845
883
|
}) => Promise<({
|
|
846
884
|
data: undefined;
|
|
847
885
|
error: import("./client/types.gen").HttpValidationError;
|
|
848
886
|
} | {
|
|
849
|
-
data:
|
|
887
|
+
data: PaginatedResponseWithIncludesTrajectoryResponse;
|
|
850
888
|
error: undefined;
|
|
851
889
|
}) & {
|
|
852
890
|
request: Request;
|
|
@@ -882,13 +920,18 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string,
|
|
|
882
920
|
* Get a specific trajectory by ID
|
|
883
921
|
*
|
|
884
922
|
* @param trajectoryId - The ID of the trajectory
|
|
885
|
-
* @
|
|
923
|
+
* @param params - Optional parameters
|
|
924
|
+
* @param params.include - Optional list of related resources to include. Available: ["workflow"].
|
|
925
|
+
* Related resources are returned in the `included` array following the JSON:API pattern.
|
|
926
|
+
* @returns Trajectory details including recorded actions and optional included resources
|
|
886
927
|
*/
|
|
887
|
-
get: (trajectoryId: string
|
|
928
|
+
get: (trajectoryId: string, params?: {
|
|
929
|
+
include?: string[];
|
|
930
|
+
}) => Promise<({
|
|
888
931
|
data: undefined;
|
|
889
932
|
error: import("./client/types.gen").HttpValidationError;
|
|
890
933
|
} | {
|
|
891
|
-
data:
|
|
934
|
+
data: import("./client/types.gen").TrajectoryResponseWithIncludes;
|
|
892
935
|
error: undefined;
|
|
893
936
|
}) & {
|
|
894
937
|
request: Request;
|
|
@@ -1264,4 +1307,4 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string,
|
|
|
1264
1307
|
}>;
|
|
1265
1308
|
};
|
|
1266
1309
|
};
|
|
1267
|
-
export type { MachineResponse, MachinePoolUpdate, PoolResponse, PoolCreate, PoolUpdate, PoolWithMachines, MachinePoolAssignment, WorkflowResponse, RunResponse, RunBulkCreate, RunBulkCreateResponse, ConnectionResponse, TrajectoryResponse, RunAttachmentResponse, RunAttachmentDownloadUrlResponse, FileInput, AttachmentType,
|
|
1310
|
+
export type { MachineResponse, MachinePoolUpdate, PoolResponse, PoolCreate, PoolUpdate, PoolWithMachines, MachinePoolAssignment, WorkflowResponse, RunResponse, RunBulkCreate, RunBulkCreateResponse, ConnectionResponse, TrajectoryResponse, RunAttachmentResponse, RunAttachmentDownloadUrlResponse, FileInput, AttachmentType, IncludedResource, PaginatedResponseWithIncludesMachineResponse, PaginatedResponseWithIncludesPoolResponse, PaginatedResponseWorkflowResponse, PaginatedResponseWithIncludesRunResponse, PaginatedResponseConnectionResponse, PaginatedResponseWithIncludesTrajectoryResponse, PaginatedResponseRunAttachmentResponse, ModelConfigurationCreate, ModelConfigurationUpdate, ModelConfigurationResponse, UsageAggregateResponse, UsageMode, };
|
package/dist/index.js
CHANGED
|
@@ -285,17 +285,21 @@ function createCyberdeskClient(apiKey, baseUrl, options) {
|
|
|
285
285
|
* @param params.skip - Number of items to skip (for pagination)
|
|
286
286
|
* @param params.limit - Maximum number of items to return
|
|
287
287
|
* @param params.status - Filter by machine status
|
|
288
|
+
* @param params.include - Optional list of related resources to include. Available: ["pools"].
|
|
289
|
+
* Related resources are returned in the `included` array following the JSON:API pattern.
|
|
288
290
|
* @returns Paginated list of machines. Each machine includes desktop parameters
|
|
289
291
|
* (machine_parameters, machine_sensitive_parameters) if configured,
|
|
290
292
|
* plus the current physical_server_id when connected to WebSockets.
|
|
291
293
|
*/
|
|
292
294
|
list: (params) => __awaiter(this, void 0, void 0, function* () {
|
|
295
|
+
var _a;
|
|
293
296
|
const query = {
|
|
294
297
|
status: params === null || params === void 0 ? void 0 : params.status,
|
|
295
298
|
skip: params === null || params === void 0 ? void 0 : params.skip,
|
|
296
299
|
limit: params === null || params === void 0 ? void 0 : params.limit,
|
|
297
300
|
created_at_from: toIsoUtc(params === null || params === void 0 ? void 0 : params.created_at_from),
|
|
298
301
|
created_at_to: toIsoUtc(params === null || params === void 0 ? void 0 : params.created_at_to),
|
|
302
|
+
include: (_a = params === null || params === void 0 ? void 0 : params.include) === null || _a === void 0 ? void 0 : _a.join(','),
|
|
299
303
|
};
|
|
300
304
|
return (0, sdk_gen_1.listMachinesV1MachinesGet)({ client, query });
|
|
301
305
|
}),
|
|
@@ -321,17 +325,23 @@ function createCyberdeskClient(apiKey, baseUrl, options) {
|
|
|
321
325
|
* Get a specific machine by ID
|
|
322
326
|
*
|
|
323
327
|
* @param machineId - The ID of the machine
|
|
328
|
+
* @param params - Optional parameters
|
|
329
|
+
* @param params.include - Optional list of related resources to include. Available: ["pools"].
|
|
330
|
+
* Related resources are returned in the `included` array following the JSON:API pattern.
|
|
324
331
|
* @returns Machine details including:
|
|
325
332
|
* - Basic info: id, name, status, fingerprint, etc.
|
|
326
333
|
* - machine_parameters: Dict of desktop parameters (if configured)
|
|
327
334
|
* - machine_sensitive_parameters: Dict of sensitive parameter aliases (if configured)
|
|
328
335
|
* - physical_server_id: Fly machine ID currently hosting the WebSocket connection
|
|
329
336
|
* - pools: List of pools this machine belongs to
|
|
337
|
+
* - included: Related resources (when include parameter is used)
|
|
330
338
|
*/
|
|
331
|
-
get: (machineId) => __awaiter(this, void 0, void 0, function* () {
|
|
339
|
+
get: (machineId, params) => __awaiter(this, void 0, void 0, function* () {
|
|
340
|
+
var _a;
|
|
332
341
|
return (0, sdk_gen_1.getMachineV1MachinesMachineIdGet)({
|
|
333
342
|
client,
|
|
334
343
|
path: { machine_id: machineId },
|
|
344
|
+
query: { include: (_a = params === null || params === void 0 ? void 0 : params.include) === null || _a === void 0 ? void 0 : _a.join(',') },
|
|
335
345
|
});
|
|
336
346
|
}),
|
|
337
347
|
/**
|
|
@@ -452,12 +462,19 @@ function createCyberdeskClient(apiKey, baseUrl, options) {
|
|
|
452
462
|
* @param params - Optional query parameters
|
|
453
463
|
* @param params.skip - Number of items to skip (for pagination)
|
|
454
464
|
* @param params.limit - Maximum number of items to return
|
|
465
|
+
* @param params.include - Optional list of related resources to include. Available: ["machines"].
|
|
466
|
+
* Related resources are returned in the `included` array following the JSON:API pattern.
|
|
455
467
|
* @returns Paginated list of pools
|
|
456
468
|
*/
|
|
457
469
|
list: (params) => __awaiter(this, void 0, void 0, function* () {
|
|
470
|
+
var _a;
|
|
458
471
|
return (0, sdk_gen_1.listPoolsV1PoolsGet)({
|
|
459
472
|
client,
|
|
460
|
-
query:
|
|
473
|
+
query: {
|
|
474
|
+
skip: params === null || params === void 0 ? void 0 : params.skip,
|
|
475
|
+
limit: params === null || params === void 0 ? void 0 : params.limit,
|
|
476
|
+
include: (_a = params === null || params === void 0 ? void 0 : params.include) === null || _a === void 0 ? void 0 : _a.join(','),
|
|
477
|
+
},
|
|
461
478
|
});
|
|
462
479
|
}),
|
|
463
480
|
/**
|
|
@@ -484,14 +501,39 @@ function createCyberdeskClient(apiKey, baseUrl, options) {
|
|
|
484
501
|
* Get a specific pool by ID
|
|
485
502
|
*
|
|
486
503
|
* @param poolId - The ID of the pool
|
|
487
|
-
* @param
|
|
488
|
-
*
|
|
504
|
+
* @param paramsOrIncludeMachines - Optional. Either a boolean for backward compatibility (deprecated),
|
|
505
|
+
* or an options object with includeMachines and include fields.
|
|
506
|
+
* @returns Pool details with optional included resources
|
|
507
|
+
*
|
|
508
|
+
* @example
|
|
509
|
+
* ```typescript
|
|
510
|
+
* // New style (recommended)
|
|
511
|
+
* const pool = await client.pools.get("pool-id", { include: ["machines"] });
|
|
512
|
+
*
|
|
513
|
+
* // Legacy style (deprecated but still supported)
|
|
514
|
+
* const pool = await client.pools.get("pool-id", true);
|
|
515
|
+
* ```
|
|
489
516
|
*/
|
|
490
|
-
get: (poolId,
|
|
517
|
+
get: (poolId, paramsOrIncludeMachines) => __awaiter(this, void 0, void 0, function* () {
|
|
518
|
+
// Support both old signature (boolean) and new signature (object) for backward compatibility
|
|
519
|
+
let includeMachines;
|
|
520
|
+
let include;
|
|
521
|
+
if (typeof paramsOrIncludeMachines === 'boolean') {
|
|
522
|
+
// Legacy call: client.pools.get("id", true)
|
|
523
|
+
includeMachines = paramsOrIncludeMachines;
|
|
524
|
+
}
|
|
525
|
+
else if (paramsOrIncludeMachines) {
|
|
526
|
+
// New call: client.pools.get("id", { includeMachines: true, include: ["machines"] })
|
|
527
|
+
includeMachines = paramsOrIncludeMachines.includeMachines;
|
|
528
|
+
include = paramsOrIncludeMachines.include;
|
|
529
|
+
}
|
|
491
530
|
return (0, sdk_gen_1.getPoolV1PoolsPoolIdGet)({
|
|
492
531
|
client,
|
|
493
532
|
path: { pool_id: poolId },
|
|
494
|
-
query:
|
|
533
|
+
query: {
|
|
534
|
+
include_machines: includeMachines,
|
|
535
|
+
include: include === null || include === void 0 ? void 0 : include.join(','),
|
|
536
|
+
},
|
|
495
537
|
});
|
|
496
538
|
}),
|
|
497
539
|
/**
|
|
@@ -660,13 +702,16 @@ function createCyberdeskClient(apiKey, baseUrl, options) {
|
|
|
660
702
|
* @param params.session_id - Filter by session ID
|
|
661
703
|
* @param params.fields - Optional list of fields to include per run (projection). Available fields include:
|
|
662
704
|
* started_at, ended_at, error, output_data, input_values, usage_metadata, and more.
|
|
705
|
+
* @param params.include - Optional list of related resources to include. Available: ["workflow", "machine", "machine.pools"].
|
|
706
|
+
* Related resources are returned in the `included` array following the JSON:API pattern.
|
|
663
707
|
* @returns Paginated list of runs including timing fields:
|
|
664
708
|
* - created_at: When run was created
|
|
665
709
|
* - started_at: When run execution started (null for SCHEDULING runs)
|
|
666
710
|
* - ended_at: When run completed (null for RUNNING/SCHEDULING runs)
|
|
711
|
+
* - included: Related resources (when include parameter is used)
|
|
667
712
|
*/
|
|
668
713
|
list: (params) => __awaiter(this, void 0, void 0, function* () {
|
|
669
|
-
var _a, _b, _c, _d;
|
|
714
|
+
var _a, _b, _c, _d, _e;
|
|
670
715
|
const query = {
|
|
671
716
|
skip: params === null || params === void 0 ? void 0 : params.skip,
|
|
672
717
|
limit: params === null || params === void 0 ? void 0 : params.limit,
|
|
@@ -677,6 +722,7 @@ function createCyberdeskClient(apiKey, baseUrl, options) {
|
|
|
677
722
|
created_at_from: toIsoUtc(params === null || params === void 0 ? void 0 : params.created_at_from),
|
|
678
723
|
created_at_to: toIsoUtc(params === null || params === void 0 ? void 0 : params.created_at_to),
|
|
679
724
|
fields: params === null || params === void 0 ? void 0 : params.fields,
|
|
725
|
+
include: (_e = params === null || params === void 0 ? void 0 : params.include) === null || _e === void 0 ? void 0 : _e.join(','),
|
|
680
726
|
};
|
|
681
727
|
return (0, sdk_gen_1.listRunsV1RunsGet)({ client, query });
|
|
682
728
|
}),
|
|
@@ -782,15 +828,21 @@ function createCyberdeskClient(apiKey, baseUrl, options) {
|
|
|
782
828
|
* Get a specific run by ID
|
|
783
829
|
*
|
|
784
830
|
* @param runId - The ID of the run
|
|
831
|
+
* @param params - Optional parameters
|
|
832
|
+
* @param params.include - Optional list of related resources to include. Available: ["workflow", "machine", "machine.pools"].
|
|
833
|
+
* Related resources are returned in the `included` array following the JSON:API pattern.
|
|
785
834
|
* @returns Run details including timing information:
|
|
786
835
|
* - created_at: When run was created
|
|
787
836
|
* - started_at: When run execution started (null if not started)
|
|
788
837
|
* - ended_at: When run completed (null if not finished)
|
|
838
|
+
* - included: Related resources (when include parameter is used)
|
|
789
839
|
*/
|
|
790
|
-
get: (runId) => __awaiter(this, void 0, void 0, function* () {
|
|
840
|
+
get: (runId, params) => __awaiter(this, void 0, void 0, function* () {
|
|
841
|
+
var _a;
|
|
791
842
|
return (0, sdk_gen_1.getRunV1RunsRunIdGet)({
|
|
792
843
|
client,
|
|
793
844
|
path: { run_id: runId },
|
|
845
|
+
query: { include: (_a = params === null || params === void 0 ? void 0 : params.include) === null || _a === void 0 ? void 0 : _a.join(',') },
|
|
794
846
|
});
|
|
795
847
|
}),
|
|
796
848
|
/**
|
|
@@ -880,6 +932,8 @@ function createCyberdeskClient(apiKey, baseUrl, options) {
|
|
|
880
932
|
* @param params.created_at_to - Filter created at or before this date
|
|
881
933
|
* @param params.updated_at_from - Filter updated at or after this date
|
|
882
934
|
* @param params.updated_at_to - Filter updated at or before this date
|
|
935
|
+
* @param params.include - Optional list of related resources to include. Available: ["workflow"].
|
|
936
|
+
* Related resources are returned in the `included` array following the JSON:API pattern.
|
|
883
937
|
* @returns Paginated list of trajectories
|
|
884
938
|
*
|
|
885
939
|
* @remarks
|
|
@@ -887,7 +941,7 @@ function createCyberdeskClient(apiKey, baseUrl, options) {
|
|
|
887
941
|
* Only approved trajectories are used during workflow execution.
|
|
888
942
|
*/
|
|
889
943
|
list: (params) => __awaiter(this, void 0, void 0, function* () {
|
|
890
|
-
var _a, _b;
|
|
944
|
+
var _a, _b, _c;
|
|
891
945
|
const query = {
|
|
892
946
|
skip: params === null || params === void 0 ? void 0 : params.skip,
|
|
893
947
|
limit: params === null || params === void 0 ? void 0 : params.limit,
|
|
@@ -897,6 +951,7 @@ function createCyberdeskClient(apiKey, baseUrl, options) {
|
|
|
897
951
|
created_at_to: toIsoUtc(params === null || params === void 0 ? void 0 : params.created_at_to),
|
|
898
952
|
updated_at_from: toIsoUtc(params === null || params === void 0 ? void 0 : params.updated_at_from),
|
|
899
953
|
updated_at_to: toIsoUtc(params === null || params === void 0 ? void 0 : params.updated_at_to),
|
|
954
|
+
include: (_c = params === null || params === void 0 ? void 0 : params.include) === null || _c === void 0 ? void 0 : _c.join(','),
|
|
900
955
|
};
|
|
901
956
|
return (0, sdk_gen_1.listTrajectoriesV1TrajectoriesGet)({ client, query });
|
|
902
957
|
}),
|
|
@@ -926,12 +981,17 @@ function createCyberdeskClient(apiKey, baseUrl, options) {
|
|
|
926
981
|
* Get a specific trajectory by ID
|
|
927
982
|
*
|
|
928
983
|
* @param trajectoryId - The ID of the trajectory
|
|
929
|
-
* @
|
|
984
|
+
* @param params - Optional parameters
|
|
985
|
+
* @param params.include - Optional list of related resources to include. Available: ["workflow"].
|
|
986
|
+
* Related resources are returned in the `included` array following the JSON:API pattern.
|
|
987
|
+
* @returns Trajectory details including recorded actions and optional included resources
|
|
930
988
|
*/
|
|
931
|
-
get: (trajectoryId) => __awaiter(this, void 0, void 0, function* () {
|
|
989
|
+
get: (trajectoryId, params) => __awaiter(this, void 0, void 0, function* () {
|
|
990
|
+
var _a;
|
|
932
991
|
return (0, sdk_gen_1.getTrajectoryV1TrajectoriesTrajectoryIdGet)({
|
|
933
992
|
client,
|
|
934
993
|
path: { trajectory_id: trajectoryId },
|
|
994
|
+
query: { include: (_a = params === null || params === void 0 ? void 0 : params.include) === null || _a === void 0 ? void 0 : _a.join(',') },
|
|
935
995
|
});
|
|
936
996
|
}),
|
|
937
997
|
/**
|