cyberdesk 2.1.0 → 2.1.2
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/types.gen.d.ts +50 -2
- package/dist/index.d.ts +300 -96
- package/dist/index.js +45 -16
- package/package.json +1 -1
|
@@ -375,7 +375,7 @@ export type RunBulkCreate = {
|
|
|
375
375
|
*/
|
|
376
376
|
machine_id?: string | null;
|
|
377
377
|
/**
|
|
378
|
-
* Pool IDs to filter available machines. Machine must belong to
|
|
378
|
+
* Pool IDs to filter available machines. Machine must belong to all of these pools (intersection). Ignored when machine_id is provided.
|
|
379
379
|
*/
|
|
380
380
|
pool_ids?: Array<string> | null;
|
|
381
381
|
/**
|
|
@@ -411,7 +411,7 @@ export type RunCreate = {
|
|
|
411
411
|
*/
|
|
412
412
|
machine_id?: string | null;
|
|
413
413
|
/**
|
|
414
|
-
* Pool IDs to filter available machines. Machine must belong to
|
|
414
|
+
* Pool IDs to filter available machines. Machine must belong to all of these pools (intersection). Ignored when machine_id is provided.
|
|
415
415
|
*/
|
|
416
416
|
pool_ids?: Array<string> | null;
|
|
417
417
|
/**
|
|
@@ -620,6 +620,14 @@ export type ListMachinesV1MachinesGetData = {
|
|
|
620
620
|
* Filter by machine status
|
|
621
621
|
*/
|
|
622
622
|
status?: MachineStatus | null;
|
|
623
|
+
/**
|
|
624
|
+
* Filter machines created at or after this ISO timestamp (UTC)
|
|
625
|
+
*/
|
|
626
|
+
created_at_from?: string | null;
|
|
627
|
+
/**
|
|
628
|
+
* Filter machines created at or before this ISO timestamp (UTC)
|
|
629
|
+
*/
|
|
630
|
+
created_at_to?: string | null;
|
|
623
631
|
skip?: number;
|
|
624
632
|
limit?: number;
|
|
625
633
|
};
|
|
@@ -931,6 +939,22 @@ export type ListWorkflowsV1WorkflowsGetData = {
|
|
|
931
939
|
body?: never;
|
|
932
940
|
path?: never;
|
|
933
941
|
query?: {
|
|
942
|
+
/**
|
|
943
|
+
* Filter workflows created at or after this ISO timestamp (UTC)
|
|
944
|
+
*/
|
|
945
|
+
created_at_from?: string | null;
|
|
946
|
+
/**
|
|
947
|
+
* Filter workflows created at or before this ISO timestamp (UTC)
|
|
948
|
+
*/
|
|
949
|
+
created_at_to?: string | null;
|
|
950
|
+
/**
|
|
951
|
+
* Filter workflows updated at or after this ISO timestamp (UTC)
|
|
952
|
+
*/
|
|
953
|
+
updated_at_from?: string | null;
|
|
954
|
+
/**
|
|
955
|
+
* Filter workflows updated at or before this ISO timestamp (UTC)
|
|
956
|
+
*/
|
|
957
|
+
updated_at_to?: string | null;
|
|
934
958
|
skip?: number;
|
|
935
959
|
limit?: number;
|
|
936
960
|
};
|
|
@@ -1076,6 +1100,14 @@ export type ListRunsV1RunsGetData = {
|
|
|
1076
1100
|
* Filter by run status
|
|
1077
1101
|
*/
|
|
1078
1102
|
status?: RunStatus | null;
|
|
1103
|
+
/**
|
|
1104
|
+
* Filter runs created at or after this ISO timestamp (UTC)
|
|
1105
|
+
*/
|
|
1106
|
+
created_at_from?: string | null;
|
|
1107
|
+
/**
|
|
1108
|
+
* Filter runs created at or before this ISO timestamp (UTC)
|
|
1109
|
+
*/
|
|
1110
|
+
created_at_to?: string | null;
|
|
1079
1111
|
skip?: number;
|
|
1080
1112
|
limit?: number;
|
|
1081
1113
|
};
|
|
@@ -1612,6 +1644,22 @@ export type ListTrajectoriesV1TrajectoriesGetData = {
|
|
|
1612
1644
|
* Filter by workflow ID
|
|
1613
1645
|
*/
|
|
1614
1646
|
workflow_id?: string | null;
|
|
1647
|
+
/**
|
|
1648
|
+
* Filter trajectories created at or after this ISO timestamp (UTC)
|
|
1649
|
+
*/
|
|
1650
|
+
created_at_from?: string | null;
|
|
1651
|
+
/**
|
|
1652
|
+
* Filter trajectories created at or before this ISO timestamp (UTC)
|
|
1653
|
+
*/
|
|
1654
|
+
created_at_to?: string | null;
|
|
1655
|
+
/**
|
|
1656
|
+
* Filter trajectories updated at or after this ISO timestamp (UTC)
|
|
1657
|
+
*/
|
|
1658
|
+
updated_at_from?: string | null;
|
|
1659
|
+
/**
|
|
1660
|
+
* Filter trajectories updated at or before this ISO timestamp (UTC)
|
|
1661
|
+
*/
|
|
1662
|
+
updated_at_to?: string | null;
|
|
1615
1663
|
skip?: number;
|
|
1616
1664
|
limit?: number;
|
|
1617
1665
|
};
|
package/dist/index.d.ts
CHANGED
|
@@ -57,9 +57,17 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
|
|
|
57
57
|
skip?: number;
|
|
58
58
|
limit?: number;
|
|
59
59
|
status?: MachineStatus;
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
60
|
+
created_at_from?: string | Date;
|
|
61
|
+
created_at_to?: string | Date;
|
|
62
|
+
}) => Promise<({
|
|
63
|
+
data: PaginatedResponseMachineResponse;
|
|
64
|
+
error: undefined;
|
|
65
|
+
} | {
|
|
66
|
+
data: undefined;
|
|
67
|
+
error: import("./client/types.gen").HttpValidationError;
|
|
68
|
+
}) & {
|
|
69
|
+
request: Request;
|
|
70
|
+
response: Response;
|
|
63
71
|
}>;
|
|
64
72
|
/**
|
|
65
73
|
* Create a new machine
|
|
@@ -67,9 +75,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
|
|
|
67
75
|
* @param data - Machine configuration
|
|
68
76
|
* @returns Created machine details
|
|
69
77
|
*/
|
|
70
|
-
create: (data: MachineCreate) => Promise<{
|
|
71
|
-
data
|
|
72
|
-
error
|
|
78
|
+
create: (data: MachineCreate) => Promise<({
|
|
79
|
+
data: undefined;
|
|
80
|
+
error: import("./client/types.gen").HttpValidationError;
|
|
81
|
+
} | {
|
|
82
|
+
data: MachineResponse;
|
|
83
|
+
error: undefined;
|
|
84
|
+
}) & {
|
|
85
|
+
request: Request;
|
|
86
|
+
response: Response;
|
|
73
87
|
}>;
|
|
74
88
|
/**
|
|
75
89
|
* Get a specific machine by ID
|
|
@@ -77,9 +91,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
|
|
|
77
91
|
* @param machineId - The ID of the machine
|
|
78
92
|
* @returns Machine details
|
|
79
93
|
*/
|
|
80
|
-
get: (machineId: string) => Promise<{
|
|
81
|
-
data
|
|
82
|
-
error
|
|
94
|
+
get: (machineId: string) => Promise<({
|
|
95
|
+
data: undefined;
|
|
96
|
+
error: import("./client/types.gen").HttpValidationError;
|
|
97
|
+
} | {
|
|
98
|
+
data: MachineResponse;
|
|
99
|
+
error: undefined;
|
|
100
|
+
}) & {
|
|
101
|
+
request: Request;
|
|
102
|
+
response: Response;
|
|
83
103
|
}>;
|
|
84
104
|
/**
|
|
85
105
|
* Update a machine
|
|
@@ -113,9 +133,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
|
|
|
113
133
|
* @param machineId - The ID of the machine
|
|
114
134
|
* @returns List of pools the machine belongs to
|
|
115
135
|
*/
|
|
116
|
-
getPools: (machineId: string) => Promise<{
|
|
117
|
-
data
|
|
118
|
-
error
|
|
136
|
+
getPools: (machineId: string) => Promise<({
|
|
137
|
+
data: undefined;
|
|
138
|
+
error: import("./client/types.gen").HttpValidationError;
|
|
139
|
+
} | {
|
|
140
|
+
data: PoolResponse[];
|
|
141
|
+
error: undefined;
|
|
142
|
+
}) & {
|
|
143
|
+
request: Request;
|
|
144
|
+
response: Response;
|
|
119
145
|
}>;
|
|
120
146
|
/**
|
|
121
147
|
* Update a machine's pool assignments
|
|
@@ -126,9 +152,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
|
|
|
126
152
|
* @param data - MachinePoolUpdate with pool_ids list
|
|
127
153
|
* @returns Updated machine details
|
|
128
154
|
*/
|
|
129
|
-
updatePools: (machineId: string, data: MachinePoolUpdate) => Promise<{
|
|
130
|
-
data
|
|
131
|
-
error
|
|
155
|
+
updatePools: (machineId: string, data: MachinePoolUpdate) => Promise<({
|
|
156
|
+
data: undefined;
|
|
157
|
+
error: import("./client/types.gen").HttpValidationError;
|
|
158
|
+
} | {
|
|
159
|
+
data: MachineResponse;
|
|
160
|
+
error: undefined;
|
|
161
|
+
}) & {
|
|
162
|
+
request: Request;
|
|
163
|
+
response: Response;
|
|
132
164
|
}>;
|
|
133
165
|
};
|
|
134
166
|
pools: {
|
|
@@ -143,9 +175,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
|
|
|
143
175
|
list: (params?: {
|
|
144
176
|
skip?: number;
|
|
145
177
|
limit?: number;
|
|
146
|
-
}) => Promise<{
|
|
147
|
-
data
|
|
148
|
-
error
|
|
178
|
+
}) => Promise<({
|
|
179
|
+
data: undefined;
|
|
180
|
+
error: import("./client/types.gen").HttpValidationError;
|
|
181
|
+
} | {
|
|
182
|
+
data: PaginatedResponsePoolResponse;
|
|
183
|
+
error: undefined;
|
|
184
|
+
}) & {
|
|
185
|
+
request: Request;
|
|
186
|
+
response: Response;
|
|
149
187
|
}>;
|
|
150
188
|
/**
|
|
151
189
|
* Create a new pool
|
|
@@ -161,9 +199,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
|
|
|
161
199
|
* });
|
|
162
200
|
* ```
|
|
163
201
|
*/
|
|
164
|
-
create: (data: PoolCreate) => Promise<{
|
|
165
|
-
data
|
|
166
|
-
error
|
|
202
|
+
create: (data: PoolCreate) => Promise<({
|
|
203
|
+
data: undefined;
|
|
204
|
+
error: import("./client/types.gen").HttpValidationError;
|
|
205
|
+
} | {
|
|
206
|
+
data: PoolResponse;
|
|
207
|
+
error: undefined;
|
|
208
|
+
}) & {
|
|
209
|
+
request: Request;
|
|
210
|
+
response: Response;
|
|
167
211
|
}>;
|
|
168
212
|
/**
|
|
169
213
|
* Get a specific pool by ID
|
|
@@ -172,9 +216,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
|
|
|
172
216
|
* @param includeMachines - Whether to include full machine details
|
|
173
217
|
* @returns Pool details, optionally with machine list
|
|
174
218
|
*/
|
|
175
|
-
get: (poolId: string, includeMachines?: boolean) => Promise<{
|
|
176
|
-
data
|
|
177
|
-
error
|
|
219
|
+
get: (poolId: string, includeMachines?: boolean) => Promise<({
|
|
220
|
+
data: undefined;
|
|
221
|
+
error: import("./client/types.gen").HttpValidationError;
|
|
222
|
+
} | {
|
|
223
|
+
data: PoolWithMachines;
|
|
224
|
+
error: undefined;
|
|
225
|
+
}) & {
|
|
226
|
+
request: Request;
|
|
227
|
+
response: Response;
|
|
178
228
|
}>;
|
|
179
229
|
/**
|
|
180
230
|
* Update a pool's details
|
|
@@ -183,9 +233,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
|
|
|
183
233
|
* @param data - Update data (name, description)
|
|
184
234
|
* @returns Updated pool details
|
|
185
235
|
*/
|
|
186
|
-
update: (poolId: string, data: PoolUpdate) => Promise<{
|
|
187
|
-
data
|
|
188
|
-
error
|
|
236
|
+
update: (poolId: string, data: PoolUpdate) => Promise<({
|
|
237
|
+
data: undefined;
|
|
238
|
+
error: import("./client/types.gen").HttpValidationError;
|
|
239
|
+
} | {
|
|
240
|
+
data: PoolResponse;
|
|
241
|
+
error: undefined;
|
|
242
|
+
}) & {
|
|
243
|
+
request: Request;
|
|
244
|
+
response: Response;
|
|
189
245
|
}>;
|
|
190
246
|
/**
|
|
191
247
|
* Delete a pool
|
|
@@ -218,9 +274,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
|
|
|
218
274
|
* });
|
|
219
275
|
* ```
|
|
220
276
|
*/
|
|
221
|
-
addMachines: (poolId: string, data: MachinePoolAssignment) => Promise<{
|
|
222
|
-
data
|
|
223
|
-
error
|
|
277
|
+
addMachines: (poolId: string, data: MachinePoolAssignment) => Promise<({
|
|
278
|
+
data: undefined;
|
|
279
|
+
error: import("./client/types.gen").HttpValidationError;
|
|
280
|
+
} | {
|
|
281
|
+
data: PoolWithMachines;
|
|
282
|
+
error: undefined;
|
|
283
|
+
}) & {
|
|
284
|
+
request: Request;
|
|
285
|
+
response: Response;
|
|
224
286
|
}>;
|
|
225
287
|
/**
|
|
226
288
|
* Remove machines from a pool
|
|
@@ -258,9 +320,19 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
|
|
|
258
320
|
list: (params?: {
|
|
259
321
|
skip?: number;
|
|
260
322
|
limit?: number;
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
323
|
+
created_at_from?: string | Date;
|
|
324
|
+
created_at_to?: string | Date;
|
|
325
|
+
updated_at_from?: string | Date;
|
|
326
|
+
updated_at_to?: string | Date;
|
|
327
|
+
}) => Promise<({
|
|
328
|
+
data: undefined;
|
|
329
|
+
error: import("./client/types.gen").HttpValidationError;
|
|
330
|
+
} | {
|
|
331
|
+
data: PaginatedResponseWorkflowResponse;
|
|
332
|
+
error: undefined;
|
|
333
|
+
}) & {
|
|
334
|
+
request: Request;
|
|
335
|
+
response: Response;
|
|
264
336
|
}>;
|
|
265
337
|
/**
|
|
266
338
|
* Create a new workflow
|
|
@@ -277,9 +349,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
|
|
|
277
349
|
* });
|
|
278
350
|
* ```
|
|
279
351
|
*/
|
|
280
|
-
create: (data: WorkflowCreate) => Promise<{
|
|
281
|
-
data
|
|
282
|
-
error
|
|
352
|
+
create: (data: WorkflowCreate) => Promise<({
|
|
353
|
+
data: undefined;
|
|
354
|
+
error: import("./client/types.gen").HttpValidationError;
|
|
355
|
+
} | {
|
|
356
|
+
data: WorkflowResponse;
|
|
357
|
+
error: undefined;
|
|
358
|
+
}) & {
|
|
359
|
+
request: Request;
|
|
360
|
+
response: Response;
|
|
283
361
|
}>;
|
|
284
362
|
/**
|
|
285
363
|
* Get a specific workflow by ID
|
|
@@ -287,9 +365,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
|
|
|
287
365
|
* @param workflowId - The ID of the workflow
|
|
288
366
|
* @returns Workflow details
|
|
289
367
|
*/
|
|
290
|
-
get: (workflowId: string) => Promise<{
|
|
291
|
-
data
|
|
292
|
-
error
|
|
368
|
+
get: (workflowId: string) => Promise<({
|
|
369
|
+
data: undefined;
|
|
370
|
+
error: import("./client/types.gen").HttpValidationError;
|
|
371
|
+
} | {
|
|
372
|
+
data: WorkflowResponse;
|
|
373
|
+
error: undefined;
|
|
374
|
+
}) & {
|
|
375
|
+
request: Request;
|
|
376
|
+
response: Response;
|
|
293
377
|
}>;
|
|
294
378
|
/**
|
|
295
379
|
* Update a workflow
|
|
@@ -298,9 +382,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
|
|
|
298
382
|
* @param data - Update data (name, main_prompt, output_schema, etc.)
|
|
299
383
|
* @returns Updated workflow details
|
|
300
384
|
*/
|
|
301
|
-
update: (workflowId: string, data: WorkflowUpdate) => Promise<{
|
|
302
|
-
data
|
|
303
|
-
error
|
|
385
|
+
update: (workflowId: string, data: WorkflowUpdate) => Promise<({
|
|
386
|
+
data: undefined;
|
|
387
|
+
error: import("./client/types.gen").HttpValidationError;
|
|
388
|
+
} | {
|
|
389
|
+
data: WorkflowResponse;
|
|
390
|
+
error: undefined;
|
|
391
|
+
}) & {
|
|
392
|
+
request: Request;
|
|
393
|
+
response: Response;
|
|
304
394
|
}>;
|
|
305
395
|
/**
|
|
306
396
|
* Delete a workflow
|
|
@@ -336,9 +426,17 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
|
|
|
336
426
|
status?: RunStatus;
|
|
337
427
|
workflow_id?: string;
|
|
338
428
|
machine_id?: string;
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
429
|
+
created_at_from?: string | Date;
|
|
430
|
+
created_at_to?: string | Date;
|
|
431
|
+
}) => Promise<({
|
|
432
|
+
data: undefined;
|
|
433
|
+
error: import("./client/types.gen").HttpValidationError;
|
|
434
|
+
} | {
|
|
435
|
+
data: PaginatedResponseRunResponse;
|
|
436
|
+
error: undefined;
|
|
437
|
+
}) & {
|
|
438
|
+
request: Request;
|
|
439
|
+
response: Response;
|
|
342
440
|
}>;
|
|
343
441
|
/**
|
|
344
442
|
* Create a new run
|
|
@@ -366,9 +464,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
|
|
|
366
464
|
* });
|
|
367
465
|
* ```
|
|
368
466
|
*/
|
|
369
|
-
create: (data: RunCreate) => Promise<{
|
|
370
|
-
data
|
|
371
|
-
error
|
|
467
|
+
create: (data: RunCreate) => Promise<({
|
|
468
|
+
data: undefined;
|
|
469
|
+
error: import("./client/types.gen").HttpValidationError;
|
|
470
|
+
} | {
|
|
471
|
+
data: RunResponse;
|
|
472
|
+
error: undefined;
|
|
473
|
+
}) & {
|
|
474
|
+
request: Request;
|
|
475
|
+
response: Response;
|
|
372
476
|
}>;
|
|
373
477
|
/**
|
|
374
478
|
* Create multiple runs with the same configuration
|
|
@@ -408,9 +512,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
|
|
|
408
512
|
* }
|
|
409
513
|
* ```
|
|
410
514
|
*/
|
|
411
|
-
bulkCreate: (data: RunBulkCreate) => Promise<{
|
|
412
|
-
data
|
|
413
|
-
error
|
|
515
|
+
bulkCreate: (data: RunBulkCreate) => Promise<({
|
|
516
|
+
data: undefined;
|
|
517
|
+
error: import("./client/types.gen").HttpValidationError;
|
|
518
|
+
} | {
|
|
519
|
+
data: RunBulkCreateResponse;
|
|
520
|
+
error: undefined;
|
|
521
|
+
}) & {
|
|
522
|
+
request: Request;
|
|
523
|
+
response: Response;
|
|
414
524
|
}>;
|
|
415
525
|
/**
|
|
416
526
|
* Get a specific run by ID
|
|
@@ -418,9 +528,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
|
|
|
418
528
|
* @param runId - The ID of the run
|
|
419
529
|
* @returns Run details including status, output, and attachments
|
|
420
530
|
*/
|
|
421
|
-
get: (runId: string) => Promise<{
|
|
422
|
-
data
|
|
423
|
-
error
|
|
531
|
+
get: (runId: string) => Promise<({
|
|
532
|
+
data: undefined;
|
|
533
|
+
error: import("./client/types.gen").HttpValidationError;
|
|
534
|
+
} | {
|
|
535
|
+
data: RunResponse;
|
|
536
|
+
error: undefined;
|
|
537
|
+
}) & {
|
|
538
|
+
request: Request;
|
|
539
|
+
response: Response;
|
|
424
540
|
}>;
|
|
425
541
|
/**
|
|
426
542
|
* Update a run
|
|
@@ -429,9 +545,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
|
|
|
429
545
|
* @param data - Update data (status, output_data, error messages, etc.)
|
|
430
546
|
* @returns Updated run details
|
|
431
547
|
*/
|
|
432
|
-
update: (runId: string, data: RunUpdate) => Promise<{
|
|
433
|
-
data
|
|
434
|
-
error
|
|
548
|
+
update: (runId: string, data: RunUpdate) => Promise<({
|
|
549
|
+
data: undefined;
|
|
550
|
+
error: import("./client/types.gen").HttpValidationError;
|
|
551
|
+
} | {
|
|
552
|
+
data: RunResponse;
|
|
553
|
+
error: undefined;
|
|
554
|
+
}) & {
|
|
555
|
+
request: Request;
|
|
556
|
+
response: Response;
|
|
435
557
|
}>;
|
|
436
558
|
/**
|
|
437
559
|
* Delete a run
|
|
@@ -465,9 +587,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
|
|
|
465
587
|
limit?: number;
|
|
466
588
|
machine_id?: string;
|
|
467
589
|
status?: ConnectionStatus;
|
|
468
|
-
}) => Promise<{
|
|
469
|
-
data
|
|
470
|
-
error
|
|
590
|
+
}) => Promise<({
|
|
591
|
+
data: undefined;
|
|
592
|
+
error: import("./client/types.gen").HttpValidationError;
|
|
593
|
+
} | {
|
|
594
|
+
data: PaginatedResponseConnectionResponse;
|
|
595
|
+
error: undefined;
|
|
596
|
+
}) & {
|
|
597
|
+
request: Request;
|
|
598
|
+
response: Response;
|
|
471
599
|
}>;
|
|
472
600
|
/**
|
|
473
601
|
* Create a new connection
|
|
@@ -475,9 +603,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
|
|
|
475
603
|
* @param data - Connection data including machine ID and websocket info
|
|
476
604
|
* @returns Created connection details
|
|
477
605
|
*/
|
|
478
|
-
create: (data: ConnectionCreate) => Promise<{
|
|
479
|
-
data
|
|
480
|
-
error
|
|
606
|
+
create: (data: ConnectionCreate) => Promise<({
|
|
607
|
+
data: undefined;
|
|
608
|
+
error: import("./client/types.gen").HttpValidationError;
|
|
609
|
+
} | {
|
|
610
|
+
data: ConnectionResponse;
|
|
611
|
+
error: undefined;
|
|
612
|
+
}) & {
|
|
613
|
+
request: Request;
|
|
614
|
+
response: Response;
|
|
481
615
|
}>;
|
|
482
616
|
};
|
|
483
617
|
trajectories: {
|
|
@@ -494,9 +628,19 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
|
|
|
494
628
|
skip?: number;
|
|
495
629
|
limit?: number;
|
|
496
630
|
workflow_id?: string;
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
631
|
+
created_at_from?: string | Date;
|
|
632
|
+
created_at_to?: string | Date;
|
|
633
|
+
updated_at_from?: string | Date;
|
|
634
|
+
updated_at_to?: string | Date;
|
|
635
|
+
}) => Promise<({
|
|
636
|
+
data: undefined;
|
|
637
|
+
error: import("./client/types.gen").HttpValidationError;
|
|
638
|
+
} | {
|
|
639
|
+
data: PaginatedResponseTrajectoryResponse;
|
|
640
|
+
error: undefined;
|
|
641
|
+
}) & {
|
|
642
|
+
request: Request;
|
|
643
|
+
response: Response;
|
|
500
644
|
}>;
|
|
501
645
|
/**
|
|
502
646
|
* Create a new trajectory
|
|
@@ -510,9 +654,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
|
|
|
510
654
|
* @param data.original_input_values - Input values used during recording
|
|
511
655
|
* @returns Created trajectory details
|
|
512
656
|
*/
|
|
513
|
-
create: (data: TrajectoryCreate) => Promise<{
|
|
514
|
-
data
|
|
515
|
-
error
|
|
657
|
+
create: (data: TrajectoryCreate) => Promise<({
|
|
658
|
+
data: undefined;
|
|
659
|
+
error: import("./client/types.gen").HttpValidationError;
|
|
660
|
+
} | {
|
|
661
|
+
data: TrajectoryResponse;
|
|
662
|
+
error: undefined;
|
|
663
|
+
}) & {
|
|
664
|
+
request: Request;
|
|
665
|
+
response: Response;
|
|
516
666
|
}>;
|
|
517
667
|
/**
|
|
518
668
|
* Get a specific trajectory by ID
|
|
@@ -520,9 +670,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
|
|
|
520
670
|
* @param trajectoryId - The ID of the trajectory
|
|
521
671
|
* @returns Trajectory details including recorded actions
|
|
522
672
|
*/
|
|
523
|
-
get: (trajectoryId: string) => Promise<{
|
|
524
|
-
data
|
|
525
|
-
error
|
|
673
|
+
get: (trajectoryId: string) => Promise<({
|
|
674
|
+
data: undefined;
|
|
675
|
+
error: import("./client/types.gen").HttpValidationError;
|
|
676
|
+
} | {
|
|
677
|
+
data: TrajectoryResponse;
|
|
678
|
+
error: undefined;
|
|
679
|
+
}) & {
|
|
680
|
+
request: Request;
|
|
681
|
+
response: Response;
|
|
526
682
|
}>;
|
|
527
683
|
/**
|
|
528
684
|
* Update a trajectory
|
|
@@ -531,9 +687,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
|
|
|
531
687
|
* @param data - Update data (trajectory_data)
|
|
532
688
|
* @returns Updated trajectory details
|
|
533
689
|
*/
|
|
534
|
-
update: (trajectoryId: string, data: TrajectoryUpdate) => Promise<{
|
|
535
|
-
data
|
|
536
|
-
error
|
|
690
|
+
update: (trajectoryId: string, data: TrajectoryUpdate) => Promise<({
|
|
691
|
+
data: undefined;
|
|
692
|
+
error: import("./client/types.gen").HttpValidationError;
|
|
693
|
+
} | {
|
|
694
|
+
data: TrajectoryResponse;
|
|
695
|
+
error: undefined;
|
|
696
|
+
}) & {
|
|
697
|
+
request: Request;
|
|
698
|
+
response: Response;
|
|
537
699
|
}>;
|
|
538
700
|
/**
|
|
539
701
|
* Delete a trajectory
|
|
@@ -559,9 +721,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
|
|
|
559
721
|
* @param workflowId - The ID of the workflow
|
|
560
722
|
* @returns Latest trajectory for the workflow, or null if none exists
|
|
561
723
|
*/
|
|
562
|
-
getLatestForWorkflow: (workflowId: string) => Promise<{
|
|
563
|
-
data
|
|
564
|
-
error
|
|
724
|
+
getLatestForWorkflow: (workflowId: string) => Promise<({
|
|
725
|
+
data: undefined;
|
|
726
|
+
error: import("./client/types.gen").HttpValidationError;
|
|
727
|
+
} | {
|
|
728
|
+
data: TrajectoryResponse;
|
|
729
|
+
error: undefined;
|
|
730
|
+
}) & {
|
|
731
|
+
request: Request;
|
|
732
|
+
response: Response;
|
|
565
733
|
}>;
|
|
566
734
|
};
|
|
567
735
|
run_attachments: {
|
|
@@ -580,9 +748,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
|
|
|
580
748
|
limit?: number;
|
|
581
749
|
run_id?: string;
|
|
582
750
|
attachment_type?: AttachmentType;
|
|
583
|
-
}) => Promise<{
|
|
584
|
-
data
|
|
585
|
-
error
|
|
751
|
+
}) => Promise<({
|
|
752
|
+
data: undefined;
|
|
753
|
+
error: import("./client/types.gen").HttpValidationError;
|
|
754
|
+
} | {
|
|
755
|
+
data: PaginatedResponseRunAttachmentResponse;
|
|
756
|
+
error: undefined;
|
|
757
|
+
}) & {
|
|
758
|
+
request: Request;
|
|
759
|
+
response: Response;
|
|
586
760
|
}>;
|
|
587
761
|
/**
|
|
588
762
|
* Create a new run attachment
|
|
@@ -590,9 +764,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
|
|
|
590
764
|
* @param data - Attachment data including file content as base64
|
|
591
765
|
* @returns Created attachment details
|
|
592
766
|
*/
|
|
593
|
-
create: (data: RunAttachmentCreate) => Promise<{
|
|
594
|
-
data
|
|
595
|
-
error
|
|
767
|
+
create: (data: RunAttachmentCreate) => Promise<({
|
|
768
|
+
data: undefined;
|
|
769
|
+
error: import("./client/types.gen").HttpValidationError;
|
|
770
|
+
} | {
|
|
771
|
+
data: RunAttachmentResponse;
|
|
772
|
+
error: undefined;
|
|
773
|
+
}) & {
|
|
774
|
+
request: Request;
|
|
775
|
+
response: Response;
|
|
596
776
|
}>;
|
|
597
777
|
/**
|
|
598
778
|
* Get run attachment details
|
|
@@ -600,9 +780,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
|
|
|
600
780
|
* @param attachmentId - The ID of the attachment
|
|
601
781
|
* @returns Attachment metadata
|
|
602
782
|
*/
|
|
603
|
-
get: (attachmentId: string) => Promise<{
|
|
604
|
-
data
|
|
605
|
-
error
|
|
783
|
+
get: (attachmentId: string) => Promise<({
|
|
784
|
+
data: undefined;
|
|
785
|
+
error: import("./client/types.gen").HttpValidationError;
|
|
786
|
+
} | {
|
|
787
|
+
data: RunAttachmentResponse;
|
|
788
|
+
error: undefined;
|
|
789
|
+
}) & {
|
|
790
|
+
request: Request;
|
|
791
|
+
response: Response;
|
|
606
792
|
}>;
|
|
607
793
|
/**
|
|
608
794
|
* Get a signed download URL for a run attachment
|
|
@@ -622,9 +808,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
|
|
|
622
808
|
* }
|
|
623
809
|
* ```
|
|
624
810
|
*/
|
|
625
|
-
getDownloadUrl: (attachmentId: string, expiresIn?: number) => Promise<{
|
|
626
|
-
data
|
|
627
|
-
error
|
|
811
|
+
getDownloadUrl: (attachmentId: string, expiresIn?: number) => Promise<({
|
|
812
|
+
data: undefined;
|
|
813
|
+
error: import("./client/types.gen").HttpValidationError;
|
|
814
|
+
} | {
|
|
815
|
+
data: RunAttachmentDownloadUrlResponse;
|
|
816
|
+
error: undefined;
|
|
817
|
+
}) & {
|
|
818
|
+
request: Request;
|
|
819
|
+
response: Response;
|
|
628
820
|
}>;
|
|
629
821
|
/**
|
|
630
822
|
* Download a run attachment file directly
|
|
@@ -644,9 +836,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
|
|
|
644
836
|
* }
|
|
645
837
|
* ```
|
|
646
838
|
*/
|
|
647
|
-
download: (attachmentId: string) => Promise<{
|
|
648
|
-
data
|
|
649
|
-
error
|
|
839
|
+
download: (attachmentId: string) => Promise<({
|
|
840
|
+
data: undefined;
|
|
841
|
+
error: import("./client/types.gen").HttpValidationError;
|
|
842
|
+
} | {
|
|
843
|
+
data: unknown;
|
|
844
|
+
error: undefined;
|
|
845
|
+
}) & {
|
|
846
|
+
request: Request;
|
|
847
|
+
response: Response;
|
|
650
848
|
}>;
|
|
651
849
|
/**
|
|
652
850
|
* Update a run attachment (e.g., set expiration)
|
|
@@ -655,9 +853,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
|
|
|
655
853
|
* @param data - Update data
|
|
656
854
|
* @returns Updated attachment details
|
|
657
855
|
*/
|
|
658
|
-
update: (attachmentId: string, data: RunAttachmentUpdate) => Promise<{
|
|
659
|
-
data
|
|
660
|
-
error
|
|
856
|
+
update: (attachmentId: string, data: RunAttachmentUpdate) => Promise<({
|
|
857
|
+
data: undefined;
|
|
858
|
+
error: import("./client/types.gen").HttpValidationError;
|
|
859
|
+
} | {
|
|
860
|
+
data: RunAttachmentResponse;
|
|
861
|
+
error: undefined;
|
|
862
|
+
}) & {
|
|
863
|
+
request: Request;
|
|
864
|
+
response: Response;
|
|
661
865
|
}>;
|
|
662
866
|
/**
|
|
663
867
|
* Delete a run attachment
|
package/dist/index.js
CHANGED
|
@@ -79,6 +79,12 @@ function createApiClient(apiKey, baseUrl = DEFAULT_API_BASE_URL) {
|
|
|
79
79
|
},
|
|
80
80
|
});
|
|
81
81
|
}
|
|
82
|
+
// Helpers
|
|
83
|
+
function toIsoUtc(value) {
|
|
84
|
+
if (value == null)
|
|
85
|
+
return undefined;
|
|
86
|
+
return typeof value === 'string' ? value : value.toISOString();
|
|
87
|
+
}
|
|
82
88
|
/**
|
|
83
89
|
* Create a Cyberdesk API client
|
|
84
90
|
*
|
|
@@ -107,10 +113,14 @@ function createCyberdeskClient(apiKey, baseUrl) {
|
|
|
107
113
|
* @returns Paginated list of machines
|
|
108
114
|
*/
|
|
109
115
|
list: (params) => __awaiter(this, void 0, void 0, function* () {
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
116
|
+
const query = {
|
|
117
|
+
status: params === null || params === void 0 ? void 0 : params.status,
|
|
118
|
+
skip: params === null || params === void 0 ? void 0 : params.skip,
|
|
119
|
+
limit: params === null || params === void 0 ? void 0 : params.limit,
|
|
120
|
+
created_at_from: toIsoUtc(params === null || params === void 0 ? void 0 : params.created_at_from),
|
|
121
|
+
created_at_to: toIsoUtc(params === null || params === void 0 ? void 0 : params.created_at_to),
|
|
122
|
+
};
|
|
123
|
+
return (0, sdk_gen_1.listMachinesV1MachinesGet)({ client, query });
|
|
114
124
|
}),
|
|
115
125
|
/**
|
|
116
126
|
* Create a new machine
|
|
@@ -320,10 +330,15 @@ function createCyberdeskClient(apiKey, baseUrl) {
|
|
|
320
330
|
* @returns Paginated list of workflows
|
|
321
331
|
*/
|
|
322
332
|
list: (params) => __awaiter(this, void 0, void 0, function* () {
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
333
|
+
const query = {
|
|
334
|
+
skip: params === null || params === void 0 ? void 0 : params.skip,
|
|
335
|
+
limit: params === null || params === void 0 ? void 0 : params.limit,
|
|
336
|
+
created_at_from: toIsoUtc(params === null || params === void 0 ? void 0 : params.created_at_from),
|
|
337
|
+
created_at_to: toIsoUtc(params === null || params === void 0 ? void 0 : params.created_at_to),
|
|
338
|
+
updated_at_from: toIsoUtc(params === null || params === void 0 ? void 0 : params.updated_at_from),
|
|
339
|
+
updated_at_to: toIsoUtc(params === null || params === void 0 ? void 0 : params.updated_at_to),
|
|
340
|
+
};
|
|
341
|
+
return (0, sdk_gen_1.listWorkflowsV1WorkflowsGet)({ client, query });
|
|
327
342
|
}),
|
|
328
343
|
/**
|
|
329
344
|
* Create a new workflow
|
|
@@ -398,10 +413,17 @@ function createCyberdeskClient(apiKey, baseUrl) {
|
|
|
398
413
|
* @returns Paginated list of runs
|
|
399
414
|
*/
|
|
400
415
|
list: (params) => __awaiter(this, void 0, void 0, function* () {
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
416
|
+
var _a, _b, _c;
|
|
417
|
+
const query = {
|
|
418
|
+
skip: params === null || params === void 0 ? void 0 : params.skip,
|
|
419
|
+
limit: params === null || params === void 0 ? void 0 : params.limit,
|
|
420
|
+
status: (_a = params === null || params === void 0 ? void 0 : params.status) !== null && _a !== void 0 ? _a : undefined,
|
|
421
|
+
workflow_id: (_b = params === null || params === void 0 ? void 0 : params.workflow_id) !== null && _b !== void 0 ? _b : undefined,
|
|
422
|
+
machine_id: (_c = params === null || params === void 0 ? void 0 : params.machine_id) !== null && _c !== void 0 ? _c : undefined,
|
|
423
|
+
created_at_from: toIsoUtc(params === null || params === void 0 ? void 0 : params.created_at_from),
|
|
424
|
+
created_at_to: toIsoUtc(params === null || params === void 0 ? void 0 : params.created_at_to),
|
|
425
|
+
};
|
|
426
|
+
return (0, sdk_gen_1.listRunsV1RunsGet)({ client, query });
|
|
405
427
|
}),
|
|
406
428
|
/**
|
|
407
429
|
* Create a new run
|
|
@@ -560,10 +582,17 @@ function createCyberdeskClient(apiKey, baseUrl) {
|
|
|
560
582
|
* @returns Paginated list of trajectories
|
|
561
583
|
*/
|
|
562
584
|
list: (params) => __awaiter(this, void 0, void 0, function* () {
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
585
|
+
var _a;
|
|
586
|
+
const query = {
|
|
587
|
+
skip: params === null || params === void 0 ? void 0 : params.skip,
|
|
588
|
+
limit: params === null || params === void 0 ? void 0 : params.limit,
|
|
589
|
+
workflow_id: (_a = params === null || params === void 0 ? void 0 : params.workflow_id) !== null && _a !== void 0 ? _a : undefined,
|
|
590
|
+
created_at_from: toIsoUtc(params === null || params === void 0 ? void 0 : params.created_at_from),
|
|
591
|
+
created_at_to: toIsoUtc(params === null || params === void 0 ? void 0 : params.created_at_to),
|
|
592
|
+
updated_at_from: toIsoUtc(params === null || params === void 0 ? void 0 : params.updated_at_from),
|
|
593
|
+
updated_at_to: toIsoUtc(params === null || params === void 0 ? void 0 : params.updated_at_to),
|
|
594
|
+
};
|
|
595
|
+
return (0, sdk_gen_1.listTrajectoriesV1TrajectoriesGet)({ client, query });
|
|
567
596
|
}),
|
|
568
597
|
/**
|
|
569
598
|
* Create a new trajectory
|