cyberdesk 2.1.1 → 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.
Files changed (2) hide show
  1. package/dist/index.d.ts +252 -84
  2. package/package.json +1 -1
package/dist/index.d.ts CHANGED
@@ -75,9 +75,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
75
75
  * @param data - Machine configuration
76
76
  * @returns Created machine details
77
77
  */
78
- create: (data: MachineCreate) => Promise<{
79
- data?: MachineResponse;
80
- error?: any;
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;
81
87
  }>;
82
88
  /**
83
89
  * Get a specific machine by ID
@@ -85,9 +91,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
85
91
  * @param machineId - The ID of the machine
86
92
  * @returns Machine details
87
93
  */
88
- get: (machineId: string) => Promise<{
89
- data?: MachineResponse;
90
- error?: any;
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;
91
103
  }>;
92
104
  /**
93
105
  * Update a machine
@@ -121,9 +133,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
121
133
  * @param machineId - The ID of the machine
122
134
  * @returns List of pools the machine belongs to
123
135
  */
124
- getPools: (machineId: string) => Promise<{
125
- data?: PoolResponse[];
126
- error?: any;
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;
127
145
  }>;
128
146
  /**
129
147
  * Update a machine's pool assignments
@@ -134,9 +152,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
134
152
  * @param data - MachinePoolUpdate with pool_ids list
135
153
  * @returns Updated machine details
136
154
  */
137
- updatePools: (machineId: string, data: MachinePoolUpdate) => Promise<{
138
- data?: MachineResponse;
139
- error?: any;
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;
140
164
  }>;
141
165
  };
142
166
  pools: {
@@ -151,9 +175,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
151
175
  list: (params?: {
152
176
  skip?: number;
153
177
  limit?: number;
154
- }) => Promise<{
155
- data?: PaginatedResponsePoolResponse;
156
- error?: any;
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;
157
187
  }>;
158
188
  /**
159
189
  * Create a new pool
@@ -169,9 +199,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
169
199
  * });
170
200
  * ```
171
201
  */
172
- create: (data: PoolCreate) => Promise<{
173
- data?: PoolResponse;
174
- error?: any;
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;
175
211
  }>;
176
212
  /**
177
213
  * Get a specific pool by ID
@@ -180,9 +216,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
180
216
  * @param includeMachines - Whether to include full machine details
181
217
  * @returns Pool details, optionally with machine list
182
218
  */
183
- get: (poolId: string, includeMachines?: boolean) => Promise<{
184
- data?: PoolResponse | PoolWithMachines;
185
- error?: any;
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;
186
228
  }>;
187
229
  /**
188
230
  * Update a pool's details
@@ -191,9 +233,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
191
233
  * @param data - Update data (name, description)
192
234
  * @returns Updated pool details
193
235
  */
194
- update: (poolId: string, data: PoolUpdate) => Promise<{
195
- data?: PoolResponse;
196
- error?: any;
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;
197
245
  }>;
198
246
  /**
199
247
  * Delete a pool
@@ -226,9 +274,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
226
274
  * });
227
275
  * ```
228
276
  */
229
- addMachines: (poolId: string, data: MachinePoolAssignment) => Promise<{
230
- data?: PoolWithMachines;
231
- error?: any;
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;
232
286
  }>;
233
287
  /**
234
288
  * Remove machines from a pool
@@ -295,9 +349,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
295
349
  * });
296
350
  * ```
297
351
  */
298
- create: (data: WorkflowCreate) => Promise<{
299
- data?: WorkflowResponse;
300
- error?: any;
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;
301
361
  }>;
302
362
  /**
303
363
  * Get a specific workflow by ID
@@ -305,9 +365,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
305
365
  * @param workflowId - The ID of the workflow
306
366
  * @returns Workflow details
307
367
  */
308
- get: (workflowId: string) => Promise<{
309
- data?: WorkflowResponse;
310
- error?: any;
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;
311
377
  }>;
312
378
  /**
313
379
  * Update a workflow
@@ -316,9 +382,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
316
382
  * @param data - Update data (name, main_prompt, output_schema, etc.)
317
383
  * @returns Updated workflow details
318
384
  */
319
- update: (workflowId: string, data: WorkflowUpdate) => Promise<{
320
- data?: WorkflowResponse;
321
- error?: any;
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;
322
394
  }>;
323
395
  /**
324
396
  * Delete a workflow
@@ -392,9 +464,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
392
464
  * });
393
465
  * ```
394
466
  */
395
- create: (data: RunCreate) => Promise<{
396
- data?: RunResponse;
397
- error?: any;
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;
398
476
  }>;
399
477
  /**
400
478
  * Create multiple runs with the same configuration
@@ -434,9 +512,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
434
512
  * }
435
513
  * ```
436
514
  */
437
- bulkCreate: (data: RunBulkCreate) => Promise<{
438
- data?: RunBulkCreateResponse;
439
- error?: any;
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;
440
524
  }>;
441
525
  /**
442
526
  * Get a specific run by ID
@@ -444,9 +528,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
444
528
  * @param runId - The ID of the run
445
529
  * @returns Run details including status, output, and attachments
446
530
  */
447
- get: (runId: string) => Promise<{
448
- data?: RunResponse;
449
- error?: any;
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;
450
540
  }>;
451
541
  /**
452
542
  * Update a run
@@ -455,9 +545,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
455
545
  * @param data - Update data (status, output_data, error messages, etc.)
456
546
  * @returns Updated run details
457
547
  */
458
- update: (runId: string, data: RunUpdate) => Promise<{
459
- data?: RunResponse;
460
- error?: any;
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;
461
557
  }>;
462
558
  /**
463
559
  * Delete a run
@@ -491,9 +587,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
491
587
  limit?: number;
492
588
  machine_id?: string;
493
589
  status?: ConnectionStatus;
494
- }) => Promise<{
495
- data?: PaginatedResponseConnectionResponse;
496
- error?: any;
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;
497
599
  }>;
498
600
  /**
499
601
  * Create a new connection
@@ -501,9 +603,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
501
603
  * @param data - Connection data including machine ID and websocket info
502
604
  * @returns Created connection details
503
605
  */
504
- create: (data: ConnectionCreate) => Promise<{
505
- data?: ConnectionResponse;
506
- error?: any;
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;
507
615
  }>;
508
616
  };
509
617
  trajectories: {
@@ -546,9 +654,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
546
654
  * @param data.original_input_values - Input values used during recording
547
655
  * @returns Created trajectory details
548
656
  */
549
- create: (data: TrajectoryCreate) => Promise<{
550
- data?: TrajectoryResponse;
551
- error?: any;
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;
552
666
  }>;
553
667
  /**
554
668
  * Get a specific trajectory by ID
@@ -556,9 +670,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
556
670
  * @param trajectoryId - The ID of the trajectory
557
671
  * @returns Trajectory details including recorded actions
558
672
  */
559
- get: (trajectoryId: string) => Promise<{
560
- data?: TrajectoryResponse;
561
- error?: any;
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;
562
682
  }>;
563
683
  /**
564
684
  * Update a trajectory
@@ -567,9 +687,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
567
687
  * @param data - Update data (trajectory_data)
568
688
  * @returns Updated trajectory details
569
689
  */
570
- update: (trajectoryId: string, data: TrajectoryUpdate) => Promise<{
571
- data?: TrajectoryResponse;
572
- error?: any;
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;
573
699
  }>;
574
700
  /**
575
701
  * Delete a trajectory
@@ -595,9 +721,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
595
721
  * @param workflowId - The ID of the workflow
596
722
  * @returns Latest trajectory for the workflow, or null if none exists
597
723
  */
598
- getLatestForWorkflow: (workflowId: string) => Promise<{
599
- data?: TrajectoryResponse;
600
- error?: any;
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;
601
733
  }>;
602
734
  };
603
735
  run_attachments: {
@@ -616,9 +748,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
616
748
  limit?: number;
617
749
  run_id?: string;
618
750
  attachment_type?: AttachmentType;
619
- }) => Promise<{
620
- data?: PaginatedResponseRunAttachmentResponse;
621
- error?: any;
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;
622
760
  }>;
623
761
  /**
624
762
  * Create a new run attachment
@@ -626,9 +764,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
626
764
  * @param data - Attachment data including file content as base64
627
765
  * @returns Created attachment details
628
766
  */
629
- create: (data: RunAttachmentCreate) => Promise<{
630
- data?: RunAttachmentResponse;
631
- error?: any;
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;
632
776
  }>;
633
777
  /**
634
778
  * Get run attachment details
@@ -636,9 +780,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
636
780
  * @param attachmentId - The ID of the attachment
637
781
  * @returns Attachment metadata
638
782
  */
639
- get: (attachmentId: string) => Promise<{
640
- data?: RunAttachmentResponse;
641
- error?: any;
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;
642
792
  }>;
643
793
  /**
644
794
  * Get a signed download URL for a run attachment
@@ -658,9 +808,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
658
808
  * }
659
809
  * ```
660
810
  */
661
- getDownloadUrl: (attachmentId: string, expiresIn?: number) => Promise<{
662
- data?: RunAttachmentDownloadUrlResponse;
663
- error?: any;
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;
664
820
  }>;
665
821
  /**
666
822
  * Download a run attachment file directly
@@ -680,9 +836,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
680
836
  * }
681
837
  * ```
682
838
  */
683
- download: (attachmentId: string) => Promise<{
684
- data?: any;
685
- error?: any;
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;
686
848
  }>;
687
849
  /**
688
850
  * Update a run attachment (e.g., set expiration)
@@ -691,9 +853,15 @@ export declare function createCyberdeskClient(apiKey: string, baseUrl?: string):
691
853
  * @param data - Update data
692
854
  * @returns Updated attachment details
693
855
  */
694
- update: (attachmentId: string, data: RunAttachmentUpdate) => Promise<{
695
- data?: RunAttachmentResponse;
696
- error?: any;
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;
697
865
  }>;
698
866
  /**
699
867
  * Delete a run attachment
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cyberdesk",
3
- "version": "2.1.1",
3
+ "version": "2.1.2",
4
4
  "description": "The official TypeScript SDK for Cyberdesk",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",