@cloudfleet/sdk 0.0.1-4e71ce0 → 0.0.1-4ee2c6f

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/zod.gen.js CHANGED
@@ -199,13 +199,13 @@ export const zClusterCreateInput = z.object({
199
199
  'northamerica-central-1',
200
200
  'europe-central-1a',
201
201
  'northamerica-central-1a'
202
- ]).optional(),
202
+ ]).optional().default('staging-1a'),
203
203
  version_channel: z.enum([
204
204
  '1.x.x-cfke.x',
205
205
  '1.31.x-cfke.x',
206
206
  '1.32.x-cfke.x',
207
207
  '1.33.x-cfke.x'
208
- ]).optional()
208
+ ]).optional().default('1.x.x-cfke.x')
209
209
  });
210
210
  export const zClusterJoinInformation = z.object({
211
211
  certificate_authority: z.string(),
@@ -233,7 +233,7 @@ export const zCluster = z.object({
233
233
  'northamerica-central-1',
234
234
  'europe-central-1a',
235
235
  'northamerica-central-1a'
236
- ]).optional(),
236
+ ]).optional().default('staging-1a'),
237
237
  id: z.uuid(),
238
238
  status: z.enum([
239
239
  'active',
@@ -262,7 +262,7 @@ export const zClusterUpdateInput = z.object({
262
262
  });
263
263
  export const zFleetCreateInput = z.object({
264
264
  limits: z.object({
265
- cpu: z.number().gte(0)
265
+ cpu: z.number().gte(8).optional()
266
266
  }).optional(),
267
267
  gcp: z.object({
268
268
  enabled: z.boolean().optional().default(true),
@@ -270,17 +270,248 @@ export const zFleetCreateInput = z.object({
270
270
  }).optional(),
271
271
  hetzner: z.object({
272
272
  enabled: z.boolean().optional().default(true),
273
- apiKey: z.string()
273
+ apiKey: z.string().optional()
274
274
  }).optional(),
275
275
  aws: z.object({
276
276
  enabled: z.boolean().optional().default(true),
277
277
  controllerRoleArn: z.string()
278
278
  }).optional(),
279
+ constraints: z.object({
280
+ 'karpenter.sh/capacity-type': z.array(z.enum(['on-demand', 'spot'])).optional(),
281
+ 'kubernetes.io/arch': z.array(z.enum(['amd64', 'arm64'])).optional(),
282
+ 'cfke.io/instance-family': z.array(z.enum([
283
+ 'a1',
284
+ 'a2',
285
+ 'a3',
286
+ 'a4',
287
+ 'c1',
288
+ 'c2',
289
+ 'c2d',
290
+ 'c3',
291
+ 'c3d',
292
+ 'c4',
293
+ 'c4a',
294
+ 'c4d',
295
+ 'c5',
296
+ 'c5a',
297
+ 'c5ad',
298
+ 'c5d',
299
+ 'c5n',
300
+ 'c6a',
301
+ 'c6g',
302
+ 'c6gd',
303
+ 'c6gn',
304
+ 'c6i',
305
+ 'c6id',
306
+ 'c6in',
307
+ 'c7a',
308
+ 'c7g',
309
+ 'c7gd',
310
+ 'c7gn',
311
+ 'c7i',
312
+ 'c7i-flex',
313
+ 'c8g',
314
+ 'c8gd',
315
+ 'cax',
316
+ 'ccx',
317
+ 'cpx',
318
+ 'cx',
319
+ 'd2',
320
+ 'd3',
321
+ 'd3en',
322
+ 'dl1',
323
+ 'dl2q',
324
+ 'e2',
325
+ 'f1',
326
+ 'f2',
327
+ 'g1',
328
+ 'g2',
329
+ 'g4ad',
330
+ 'g4dn',
331
+ 'g5',
332
+ 'g5g',
333
+ 'g6',
334
+ 'g6e',
335
+ 'gr6',
336
+ 'h1',
337
+ 'h3',
338
+ 'hpc6a',
339
+ 'hpc6id',
340
+ 'hpc7a',
341
+ 'hpc7g',
342
+ 'i2',
343
+ 'i3',
344
+ 'i3en',
345
+ 'i4g',
346
+ 'i4i',
347
+ 'i7i',
348
+ 'i7ie',
349
+ 'i8g',
350
+ 'im4gn',
351
+ 'inf1',
352
+ 'inf2',
353
+ 'is4gen',
354
+ 'm1',
355
+ 'm2',
356
+ 'm3',
357
+ 'm4',
358
+ 'm5',
359
+ 'm5a',
360
+ 'm5ad',
361
+ 'm5d',
362
+ 'm5dn',
363
+ 'm5n',
364
+ 'm5zn',
365
+ 'm6a',
366
+ 'm6g',
367
+ 'm6gd',
368
+ 'm6i',
369
+ 'm6id',
370
+ 'm6idn',
371
+ 'm6in',
372
+ 'm7a',
373
+ 'm7g',
374
+ 'm7gd',
375
+ 'm7i',
376
+ 'm7i-flex',
377
+ 'm8g',
378
+ 'm8gd',
379
+ 'n1',
380
+ 'n2',
381
+ 'n2d',
382
+ 'n4',
383
+ 'p3',
384
+ 'p3dn',
385
+ 'p4d',
386
+ 'p4de',
387
+ 'p5',
388
+ 'p5e',
389
+ 'p5en',
390
+ 'p6-b200',
391
+ 'r3',
392
+ 'r4',
393
+ 'r5',
394
+ 'r5a',
395
+ 'r5ad',
396
+ 'r5b',
397
+ 'r5d',
398
+ 'r5dn',
399
+ 'r5n',
400
+ 'r6a',
401
+ 'r6g',
402
+ 'r6gd',
403
+ 'r6i',
404
+ 'r6id',
405
+ 'r6idn',
406
+ 'r6in',
407
+ 'r7a',
408
+ 'r7g',
409
+ 'r7gd',
410
+ 'r7i',
411
+ 'r7iz',
412
+ 'r8g',
413
+ 'r8gd',
414
+ 't2',
415
+ 't2a',
416
+ 't2d',
417
+ 't3',
418
+ 't3a',
419
+ 't4g',
420
+ 'trn1',
421
+ 'trn1n',
422
+ 'u-3tb1',
423
+ 'u-6tb1',
424
+ 'u7i-12tb',
425
+ 'u7i-6tb',
426
+ 'u7i-8tb',
427
+ 'u7in-16tb',
428
+ 'u7in-24tb',
429
+ 'u7in-32tb',
430
+ 'vt1',
431
+ 'x1',
432
+ 'x1e',
433
+ 'x2gd',
434
+ 'x2idn',
435
+ 'x2iedn',
436
+ 'x2iezn',
437
+ 'x4',
438
+ 'x8g',
439
+ 'z1d',
440
+ 'z3'
441
+ ])).optional(),
442
+ 'topology.kubernetes.io/region': z.array(z.enum([
443
+ 'africa-south1',
444
+ 'ap-northeast-1',
445
+ 'ap-northeast-2',
446
+ 'ap-northeast-3',
447
+ 'ap-south-1',
448
+ 'ap-southeast-1',
449
+ 'ap-southeast-2',
450
+ 'ash',
451
+ 'asia-east1',
452
+ 'asia-east2',
453
+ 'asia-northeast1',
454
+ 'asia-northeast2',
455
+ 'asia-northeast3',
456
+ 'asia-south1',
457
+ 'asia-south2',
458
+ 'asia-southeast1',
459
+ 'asia-southeast2',
460
+ 'australia-southeast1',
461
+ 'australia-southeast2',
462
+ 'ca-central-1',
463
+ 'eu-central-1',
464
+ 'eu-central-2',
465
+ 'eu-north-1',
466
+ 'eu-west-1',
467
+ 'eu-west-2',
468
+ 'eu-west-3',
469
+ 'europe-central2',
470
+ 'europe-north1',
471
+ 'europe-southwest1',
472
+ 'europe-west1',
473
+ 'europe-west10',
474
+ 'europe-west12',
475
+ 'europe-west2',
476
+ 'europe-west3',
477
+ 'europe-west4',
478
+ 'europe-west6',
479
+ 'europe-west8',
480
+ 'europe-west9',
481
+ 'fsn1',
482
+ 'hel1',
483
+ 'hil',
484
+ 'me-central1',
485
+ 'me-central2',
486
+ 'me-west1',
487
+ 'nbg1',
488
+ 'northamerica-northeast1',
489
+ 'northamerica-northeast2',
490
+ 'sa-east-1',
491
+ 'sin',
492
+ 'southamerica-east1',
493
+ 'southamerica-west1',
494
+ 'us-central1',
495
+ 'us-east-1',
496
+ 'us-east-2',
497
+ 'us-east1',
498
+ 'us-east4',
499
+ 'us-east5',
500
+ 'us-south1',
501
+ 'us-west-1',
502
+ 'us-west-2',
503
+ 'us-west1',
504
+ 'us-west2',
505
+ 'us-west3',
506
+ 'us-west4'
507
+ ])).optional()
508
+ }).optional(),
509
+ scalingProfile: z.enum(['aggressive', 'conservative']).optional(),
279
510
  id: z.string().min(1).max(63).regex(/^[a-z0-9]([-a-z0-9]*[a-z0-9])?$/)
280
511
  });
281
512
  export const zFleet = z.object({
282
513
  limits: z.object({
283
- cpu: z.number().gte(0)
514
+ cpu: z.number().gte(8).optional()
284
515
  }).optional(),
285
516
  gcp: z.object({
286
517
  enabled: z.boolean().optional().default(true),
@@ -288,17 +519,248 @@ export const zFleet = z.object({
288
519
  }).optional(),
289
520
  hetzner: z.object({
290
521
  enabled: z.boolean().optional().default(true),
291
- apiKey: z.string()
522
+ apiKey: z.string().optional()
292
523
  }).optional(),
293
524
  aws: z.object({
294
525
  enabled: z.boolean().optional().default(true),
295
526
  controllerRoleArn: z.string()
296
527
  }).optional(),
528
+ constraints: z.object({
529
+ 'karpenter.sh/capacity-type': z.array(z.enum(['on-demand', 'spot'])).optional(),
530
+ 'kubernetes.io/arch': z.array(z.enum(['amd64', 'arm64'])).optional(),
531
+ 'cfke.io/instance-family': z.array(z.enum([
532
+ 'a1',
533
+ 'a2',
534
+ 'a3',
535
+ 'a4',
536
+ 'c1',
537
+ 'c2',
538
+ 'c2d',
539
+ 'c3',
540
+ 'c3d',
541
+ 'c4',
542
+ 'c4a',
543
+ 'c4d',
544
+ 'c5',
545
+ 'c5a',
546
+ 'c5ad',
547
+ 'c5d',
548
+ 'c5n',
549
+ 'c6a',
550
+ 'c6g',
551
+ 'c6gd',
552
+ 'c6gn',
553
+ 'c6i',
554
+ 'c6id',
555
+ 'c6in',
556
+ 'c7a',
557
+ 'c7g',
558
+ 'c7gd',
559
+ 'c7gn',
560
+ 'c7i',
561
+ 'c7i-flex',
562
+ 'c8g',
563
+ 'c8gd',
564
+ 'cax',
565
+ 'ccx',
566
+ 'cpx',
567
+ 'cx',
568
+ 'd2',
569
+ 'd3',
570
+ 'd3en',
571
+ 'dl1',
572
+ 'dl2q',
573
+ 'e2',
574
+ 'f1',
575
+ 'f2',
576
+ 'g1',
577
+ 'g2',
578
+ 'g4ad',
579
+ 'g4dn',
580
+ 'g5',
581
+ 'g5g',
582
+ 'g6',
583
+ 'g6e',
584
+ 'gr6',
585
+ 'h1',
586
+ 'h3',
587
+ 'hpc6a',
588
+ 'hpc6id',
589
+ 'hpc7a',
590
+ 'hpc7g',
591
+ 'i2',
592
+ 'i3',
593
+ 'i3en',
594
+ 'i4g',
595
+ 'i4i',
596
+ 'i7i',
597
+ 'i7ie',
598
+ 'i8g',
599
+ 'im4gn',
600
+ 'inf1',
601
+ 'inf2',
602
+ 'is4gen',
603
+ 'm1',
604
+ 'm2',
605
+ 'm3',
606
+ 'm4',
607
+ 'm5',
608
+ 'm5a',
609
+ 'm5ad',
610
+ 'm5d',
611
+ 'm5dn',
612
+ 'm5n',
613
+ 'm5zn',
614
+ 'm6a',
615
+ 'm6g',
616
+ 'm6gd',
617
+ 'm6i',
618
+ 'm6id',
619
+ 'm6idn',
620
+ 'm6in',
621
+ 'm7a',
622
+ 'm7g',
623
+ 'm7gd',
624
+ 'm7i',
625
+ 'm7i-flex',
626
+ 'm8g',
627
+ 'm8gd',
628
+ 'n1',
629
+ 'n2',
630
+ 'n2d',
631
+ 'n4',
632
+ 'p3',
633
+ 'p3dn',
634
+ 'p4d',
635
+ 'p4de',
636
+ 'p5',
637
+ 'p5e',
638
+ 'p5en',
639
+ 'p6-b200',
640
+ 'r3',
641
+ 'r4',
642
+ 'r5',
643
+ 'r5a',
644
+ 'r5ad',
645
+ 'r5b',
646
+ 'r5d',
647
+ 'r5dn',
648
+ 'r5n',
649
+ 'r6a',
650
+ 'r6g',
651
+ 'r6gd',
652
+ 'r6i',
653
+ 'r6id',
654
+ 'r6idn',
655
+ 'r6in',
656
+ 'r7a',
657
+ 'r7g',
658
+ 'r7gd',
659
+ 'r7i',
660
+ 'r7iz',
661
+ 'r8g',
662
+ 'r8gd',
663
+ 't2',
664
+ 't2a',
665
+ 't2d',
666
+ 't3',
667
+ 't3a',
668
+ 't4g',
669
+ 'trn1',
670
+ 'trn1n',
671
+ 'u-3tb1',
672
+ 'u-6tb1',
673
+ 'u7i-12tb',
674
+ 'u7i-6tb',
675
+ 'u7i-8tb',
676
+ 'u7in-16tb',
677
+ 'u7in-24tb',
678
+ 'u7in-32tb',
679
+ 'vt1',
680
+ 'x1',
681
+ 'x1e',
682
+ 'x2gd',
683
+ 'x2idn',
684
+ 'x2iedn',
685
+ 'x2iezn',
686
+ 'x4',
687
+ 'x8g',
688
+ 'z1d',
689
+ 'z3'
690
+ ])).optional(),
691
+ 'topology.kubernetes.io/region': z.array(z.enum([
692
+ 'africa-south1',
693
+ 'ap-northeast-1',
694
+ 'ap-northeast-2',
695
+ 'ap-northeast-3',
696
+ 'ap-south-1',
697
+ 'ap-southeast-1',
698
+ 'ap-southeast-2',
699
+ 'ash',
700
+ 'asia-east1',
701
+ 'asia-east2',
702
+ 'asia-northeast1',
703
+ 'asia-northeast2',
704
+ 'asia-northeast3',
705
+ 'asia-south1',
706
+ 'asia-south2',
707
+ 'asia-southeast1',
708
+ 'asia-southeast2',
709
+ 'australia-southeast1',
710
+ 'australia-southeast2',
711
+ 'ca-central-1',
712
+ 'eu-central-1',
713
+ 'eu-central-2',
714
+ 'eu-north-1',
715
+ 'eu-west-1',
716
+ 'eu-west-2',
717
+ 'eu-west-3',
718
+ 'europe-central2',
719
+ 'europe-north1',
720
+ 'europe-southwest1',
721
+ 'europe-west1',
722
+ 'europe-west10',
723
+ 'europe-west12',
724
+ 'europe-west2',
725
+ 'europe-west3',
726
+ 'europe-west4',
727
+ 'europe-west6',
728
+ 'europe-west8',
729
+ 'europe-west9',
730
+ 'fsn1',
731
+ 'hel1',
732
+ 'hil',
733
+ 'me-central1',
734
+ 'me-central2',
735
+ 'me-west1',
736
+ 'nbg1',
737
+ 'northamerica-northeast1',
738
+ 'northamerica-northeast2',
739
+ 'sa-east-1',
740
+ 'sin',
741
+ 'southamerica-east1',
742
+ 'southamerica-west1',
743
+ 'us-central1',
744
+ 'us-east-1',
745
+ 'us-east-2',
746
+ 'us-east1',
747
+ 'us-east4',
748
+ 'us-east5',
749
+ 'us-south1',
750
+ 'us-west-1',
751
+ 'us-west-2',
752
+ 'us-west1',
753
+ 'us-west2',
754
+ 'us-west3',
755
+ 'us-west4'
756
+ ])).optional()
757
+ }).optional(),
758
+ scalingProfile: z.enum(['aggressive', 'conservative']).optional(),
297
759
  id: z.string().min(1).max(63).regex(/^[a-z0-9]([-a-z0-9]*[a-z0-9])?$/)
298
760
  });
299
761
  export const zFleetUpdateInput = z.object({
300
762
  limits: z.object({
301
- cpu: z.number().gte(0)
763
+ cpu: z.number().gte(8).optional()
302
764
  }).optional(),
303
765
  gcp: z.object({
304
766
  enabled: z.boolean().optional().default(true),
@@ -306,12 +768,243 @@ export const zFleetUpdateInput = z.object({
306
768
  }).optional(),
307
769
  hetzner: z.object({
308
770
  enabled: z.boolean().optional().default(true),
309
- apiKey: z.string()
771
+ apiKey: z.string().optional()
310
772
  }).optional(),
311
773
  aws: z.object({
312
774
  enabled: z.boolean().optional().default(true),
313
775
  controllerRoleArn: z.string()
314
- }).optional()
776
+ }).optional(),
777
+ constraints: z.object({
778
+ 'karpenter.sh/capacity-type': z.array(z.enum(['on-demand', 'spot'])).optional(),
779
+ 'kubernetes.io/arch': z.array(z.enum(['amd64', 'arm64'])).optional(),
780
+ 'cfke.io/instance-family': z.array(z.enum([
781
+ 'a1',
782
+ 'a2',
783
+ 'a3',
784
+ 'a4',
785
+ 'c1',
786
+ 'c2',
787
+ 'c2d',
788
+ 'c3',
789
+ 'c3d',
790
+ 'c4',
791
+ 'c4a',
792
+ 'c4d',
793
+ 'c5',
794
+ 'c5a',
795
+ 'c5ad',
796
+ 'c5d',
797
+ 'c5n',
798
+ 'c6a',
799
+ 'c6g',
800
+ 'c6gd',
801
+ 'c6gn',
802
+ 'c6i',
803
+ 'c6id',
804
+ 'c6in',
805
+ 'c7a',
806
+ 'c7g',
807
+ 'c7gd',
808
+ 'c7gn',
809
+ 'c7i',
810
+ 'c7i-flex',
811
+ 'c8g',
812
+ 'c8gd',
813
+ 'cax',
814
+ 'ccx',
815
+ 'cpx',
816
+ 'cx',
817
+ 'd2',
818
+ 'd3',
819
+ 'd3en',
820
+ 'dl1',
821
+ 'dl2q',
822
+ 'e2',
823
+ 'f1',
824
+ 'f2',
825
+ 'g1',
826
+ 'g2',
827
+ 'g4ad',
828
+ 'g4dn',
829
+ 'g5',
830
+ 'g5g',
831
+ 'g6',
832
+ 'g6e',
833
+ 'gr6',
834
+ 'h1',
835
+ 'h3',
836
+ 'hpc6a',
837
+ 'hpc6id',
838
+ 'hpc7a',
839
+ 'hpc7g',
840
+ 'i2',
841
+ 'i3',
842
+ 'i3en',
843
+ 'i4g',
844
+ 'i4i',
845
+ 'i7i',
846
+ 'i7ie',
847
+ 'i8g',
848
+ 'im4gn',
849
+ 'inf1',
850
+ 'inf2',
851
+ 'is4gen',
852
+ 'm1',
853
+ 'm2',
854
+ 'm3',
855
+ 'm4',
856
+ 'm5',
857
+ 'm5a',
858
+ 'm5ad',
859
+ 'm5d',
860
+ 'm5dn',
861
+ 'm5n',
862
+ 'm5zn',
863
+ 'm6a',
864
+ 'm6g',
865
+ 'm6gd',
866
+ 'm6i',
867
+ 'm6id',
868
+ 'm6idn',
869
+ 'm6in',
870
+ 'm7a',
871
+ 'm7g',
872
+ 'm7gd',
873
+ 'm7i',
874
+ 'm7i-flex',
875
+ 'm8g',
876
+ 'm8gd',
877
+ 'n1',
878
+ 'n2',
879
+ 'n2d',
880
+ 'n4',
881
+ 'p3',
882
+ 'p3dn',
883
+ 'p4d',
884
+ 'p4de',
885
+ 'p5',
886
+ 'p5e',
887
+ 'p5en',
888
+ 'p6-b200',
889
+ 'r3',
890
+ 'r4',
891
+ 'r5',
892
+ 'r5a',
893
+ 'r5ad',
894
+ 'r5b',
895
+ 'r5d',
896
+ 'r5dn',
897
+ 'r5n',
898
+ 'r6a',
899
+ 'r6g',
900
+ 'r6gd',
901
+ 'r6i',
902
+ 'r6id',
903
+ 'r6idn',
904
+ 'r6in',
905
+ 'r7a',
906
+ 'r7g',
907
+ 'r7gd',
908
+ 'r7i',
909
+ 'r7iz',
910
+ 'r8g',
911
+ 'r8gd',
912
+ 't2',
913
+ 't2a',
914
+ 't2d',
915
+ 't3',
916
+ 't3a',
917
+ 't4g',
918
+ 'trn1',
919
+ 'trn1n',
920
+ 'u-3tb1',
921
+ 'u-6tb1',
922
+ 'u7i-12tb',
923
+ 'u7i-6tb',
924
+ 'u7i-8tb',
925
+ 'u7in-16tb',
926
+ 'u7in-24tb',
927
+ 'u7in-32tb',
928
+ 'vt1',
929
+ 'x1',
930
+ 'x1e',
931
+ 'x2gd',
932
+ 'x2idn',
933
+ 'x2iedn',
934
+ 'x2iezn',
935
+ 'x4',
936
+ 'x8g',
937
+ 'z1d',
938
+ 'z3'
939
+ ])).optional(),
940
+ 'topology.kubernetes.io/region': z.array(z.enum([
941
+ 'africa-south1',
942
+ 'ap-northeast-1',
943
+ 'ap-northeast-2',
944
+ 'ap-northeast-3',
945
+ 'ap-south-1',
946
+ 'ap-southeast-1',
947
+ 'ap-southeast-2',
948
+ 'ash',
949
+ 'asia-east1',
950
+ 'asia-east2',
951
+ 'asia-northeast1',
952
+ 'asia-northeast2',
953
+ 'asia-northeast3',
954
+ 'asia-south1',
955
+ 'asia-south2',
956
+ 'asia-southeast1',
957
+ 'asia-southeast2',
958
+ 'australia-southeast1',
959
+ 'australia-southeast2',
960
+ 'ca-central-1',
961
+ 'eu-central-1',
962
+ 'eu-central-2',
963
+ 'eu-north-1',
964
+ 'eu-west-1',
965
+ 'eu-west-2',
966
+ 'eu-west-3',
967
+ 'europe-central2',
968
+ 'europe-north1',
969
+ 'europe-southwest1',
970
+ 'europe-west1',
971
+ 'europe-west10',
972
+ 'europe-west12',
973
+ 'europe-west2',
974
+ 'europe-west3',
975
+ 'europe-west4',
976
+ 'europe-west6',
977
+ 'europe-west8',
978
+ 'europe-west9',
979
+ 'fsn1',
980
+ 'hel1',
981
+ 'hil',
982
+ 'me-central1',
983
+ 'me-central2',
984
+ 'me-west1',
985
+ 'nbg1',
986
+ 'northamerica-northeast1',
987
+ 'northamerica-northeast2',
988
+ 'sa-east-1',
989
+ 'sin',
990
+ 'southamerica-east1',
991
+ 'southamerica-west1',
992
+ 'us-central1',
993
+ 'us-east-1',
994
+ 'us-east-2',
995
+ 'us-east1',
996
+ 'us-east4',
997
+ 'us-east5',
998
+ 'us-south1',
999
+ 'us-west-1',
1000
+ 'us-west-2',
1001
+ 'us-west1',
1002
+ 'us-west2',
1003
+ 'us-west3',
1004
+ 'us-west4'
1005
+ ])).optional()
1006
+ }).optional(),
1007
+ scalingProfile: z.enum(['aggressive', 'conservative']).optional()
315
1008
  });
316
1009
  export const zInvite = z.object({
317
1010
  id: z.string().optional(),
@@ -380,8 +1073,6 @@ export const zOrganization = z.object({
380
1073
  id: z.string(),
381
1074
  label: z.string()
382
1075
  })).min(1),
383
- copilot_user_hourly_tokens: z.int().gte(0),
384
- copilot_organization_hourly_tokens: z.int().gte(0),
385
1076
  cfcr_storage_gb: z.int().gte(-1)
386
1077
  }),
387
1078
  status: z.enum([
@@ -421,8 +1112,6 @@ export const zPlatformQuota = z.object({
421
1112
  id: z.string(),
422
1113
  label: z.string()
423
1114
  })).min(1),
424
- copilot_user_hourly_tokens: z.int().gte(0),
425
- copilot_organization_hourly_tokens: z.int().gte(0),
426
1115
  cfcr_storage_gb: z.int().gte(-1)
427
1116
  });
428
1117
  export const zRegistryRepository = z.object({
@@ -471,6 +1160,102 @@ export const zRegistryTag = z.object({
471
1160
  repository: z.string(),
472
1161
  uri: z.string()
473
1162
  });
1163
+ export const zTicketAttachment = z.object({
1164
+ id: z.string(),
1165
+ filename: z.string(),
1166
+ content_type: z.string(),
1167
+ size: z.int()
1168
+ });
1169
+ export const zTicketCreateInput = z.object({
1170
+ category: z.enum([
1171
+ 'billing',
1172
+ 'technical',
1173
+ 'general'
1174
+ ]),
1175
+ body: z.string().min(1).max(50000).regex(/\S/),
1176
+ properties: z.record(z.string(), z.unknown()).optional()
1177
+ });
1178
+ export const zTicketListResponse = z.object({
1179
+ items: z.array(z.object({
1180
+ id: z.string(),
1181
+ status: z.enum([
1182
+ 'waiting_on_us',
1183
+ 'waiting_on_user',
1184
+ 'closed'
1185
+ ]),
1186
+ category: z.enum([
1187
+ 'billing',
1188
+ 'technical',
1189
+ 'general'
1190
+ ]),
1191
+ summary: z.string(),
1192
+ closed_at: z.iso.datetime().optional(),
1193
+ date_created: z.iso.datetime(),
1194
+ date_updated: z.iso.datetime(),
1195
+ messages: z.array(z.object({
1196
+ id: z.string(),
1197
+ type: z.enum(['customer_reply', 'agent_reply']),
1198
+ body: z.string(),
1199
+ author_first_name: z.string().optional(),
1200
+ author_last_name: z.string().optional(),
1201
+ attachments: z.array(z.object({
1202
+ id: z.string(),
1203
+ filename: z.string(),
1204
+ content_type: z.string(),
1205
+ size: z.int()
1206
+ })).optional(),
1207
+ date_created: z.iso.datetime()
1208
+ })).optional()
1209
+ }))
1210
+ });
1211
+ export const zTicketMessageInput = z.object({
1212
+ body: z.string().min(1).max(50000).regex(/\S/)
1213
+ });
1214
+ export const zTicketMessage = z.object({
1215
+ id: z.string(),
1216
+ type: z.enum(['customer_reply', 'agent_reply']),
1217
+ body: z.string(),
1218
+ author_first_name: z.string().optional(),
1219
+ author_last_name: z.string().optional(),
1220
+ attachments: z.array(z.object({
1221
+ id: z.string(),
1222
+ filename: z.string(),
1223
+ content_type: z.string(),
1224
+ size: z.int()
1225
+ })).optional(),
1226
+ date_created: z.iso.datetime()
1227
+ });
1228
+ export const zTicket = z.object({
1229
+ id: z.string(),
1230
+ status: z.enum([
1231
+ 'waiting_on_us',
1232
+ 'waiting_on_user',
1233
+ 'closed'
1234
+ ]),
1235
+ category: z.enum([
1236
+ 'billing',
1237
+ 'technical',
1238
+ 'general'
1239
+ ]),
1240
+ summary: z.string(),
1241
+ closed_at: z.iso.datetime().optional(),
1242
+ date_created: z.iso.datetime(),
1243
+ date_updated: z.iso.datetime(),
1244
+ messages: z.array(z.object({
1245
+ id: z.string(),
1246
+ type: z.enum(['customer_reply', 'agent_reply']),
1247
+ body: z.string(),
1248
+ author_first_name: z.string().optional(),
1249
+ author_last_name: z.string().optional(),
1250
+ attachments: z.array(z.object({
1251
+ id: z.string(),
1252
+ filename: z.string(),
1253
+ content_type: z.string(),
1254
+ size: z.int()
1255
+ })).optional(),
1256
+ date_created: z.iso.datetime()
1257
+ })).optional()
1258
+ });
474
1259
  export const zTokenCreateInput = z.object({
475
1260
  name: z.string().min(1).max(63).regex(/^[a-z0-9]([-a-z0-9]*[a-z0-9])?$/),
476
1261
  role: z.enum(['Administrator', 'User'])
@@ -542,7 +1327,7 @@ export const zGetUsageQuery = z.object({
542
1327
  'hourly',
543
1328
  'daily',
544
1329
  'monthly'
545
- ]).optional()
1330
+ ]).optional().default('daily')
546
1331
  });
547
1332
  /**
548
1333
  * Usage data with facets for filtering
@@ -791,6 +1576,51 @@ export const zGetTagPath = z.object({
791
1576
  * Tag details
792
1577
  */
793
1578
  export const zGetTagResponse = zRegistryTag;
1579
+ /**
1580
+ * Tickets for the organization.
1581
+ */
1582
+ export const zListTicketsResponse = zTicketListResponse;
1583
+ export const zCreateTicketBody = z.object({
1584
+ payload: z.string().optional(),
1585
+ attachments: z.array(z.string()).optional()
1586
+ });
1587
+ /**
1588
+ * Ticket created.
1589
+ */
1590
+ export const zCreateTicketResponse = zTicket;
1591
+ export const zCloseTicketPath = z.object({
1592
+ ticket_id: z.string()
1593
+ });
1594
+ /**
1595
+ * Ticket closed.
1596
+ */
1597
+ export const zCloseTicketResponse = zTicket;
1598
+ export const zGetTicketPath = z.object({
1599
+ ticket_id: z.string()
1600
+ });
1601
+ /**
1602
+ * Ticket with messages (internal notes excluded).
1603
+ */
1604
+ export const zGetTicketResponse = zTicket;
1605
+ export const zReplyTicketBody = z.object({
1606
+ payload: z.string().optional(),
1607
+ attachments: z.array(z.string()).optional()
1608
+ });
1609
+ export const zReplyTicketPath = z.object({
1610
+ ticket_id: z.string()
1611
+ });
1612
+ /**
1613
+ * Reply appended.
1614
+ */
1615
+ export const zReplyTicketResponse = zTicketMessage;
1616
+ export const zGetTicketAttachmentPath = z.object({
1617
+ ticket_id: z.string(),
1618
+ attachment_id: z.string()
1619
+ });
1620
+ /**
1621
+ * Attachment binary stream.
1622
+ */
1623
+ export const zGetTicketAttachmentResponse = z.string();
794
1624
  /**
795
1625
  * Returns a list of access token details with masked secrets.
796
1626
  */