@paperclipai/shared 0.3.1 → 2026.3.17-canary.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/constants.d.ts +148 -3
- package/dist/constants.d.ts.map +1 -1
- package/dist/constants.js +352 -2
- package/dist/constants.js.map +1 -1
- package/dist/index.d.ts +4 -3
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +3 -2
- package/dist/index.js.map +1 -1
- package/dist/types/agent.d.ts +3 -1
- package/dist/types/agent.d.ts.map +1 -1
- package/dist/types/budget.d.ts +86 -0
- package/dist/types/budget.d.ts.map +1 -0
- package/dist/types/budget.js +2 -0
- package/dist/types/budget.js.map +1 -0
- package/dist/types/company.d.ts +5 -1
- package/dist/types/company.d.ts.map +1 -1
- package/dist/types/cost.d.ts +71 -0
- package/dist/types/cost.d.ts.map +1 -1
- package/dist/types/dashboard.d.ts +6 -0
- package/dist/types/dashboard.d.ts.map +1 -1
- package/dist/types/finance.d.ts +57 -0
- package/dist/types/finance.d.ts.map +1 -0
- package/dist/types/finance.js +2 -0
- package/dist/types/finance.js.map +1 -0
- package/dist/types/index.d.ts +11 -4
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/instance.d.ts +10 -0
- package/dist/types/instance.d.ts.map +1 -0
- package/dist/types/instance.js +2 -0
- package/dist/types/instance.js.map +1 -0
- package/dist/types/issue.d.ts +48 -1
- package/dist/types/issue.d.ts.map +1 -1
- package/dist/types/plugin.d.ts +419 -0
- package/dist/types/plugin.d.ts.map +1 -0
- package/dist/types/plugin.js +2 -0
- package/dist/types/plugin.js.map +1 -0
- package/dist/types/project.d.ts +26 -1
- package/dist/types/project.d.ts.map +1 -1
- package/dist/types/quota.d.ts +26 -0
- package/dist/types/quota.d.ts.map +1 -0
- package/dist/types/quota.js +2 -0
- package/dist/types/quota.js.map +1 -0
- package/dist/types/work-product.d.ts +27 -0
- package/dist/types/work-product.d.ts.map +1 -0
- package/dist/types/work-product.js +2 -0
- package/dist/types/work-product.js.map +1 -0
- package/dist/types/workspace-operation.d.ts +26 -0
- package/dist/types/workspace-operation.d.ts.map +1 -0
- package/dist/types/workspace-operation.js +2 -0
- package/dist/types/workspace-operation.js.map +1 -0
- package/dist/types/workspace-runtime.d.ts +35 -3
- package/dist/types/workspace-runtime.d.ts.map +1 -1
- package/dist/validators/access.d.ts +3 -3
- package/dist/validators/agent.d.ts +14 -11
- package/dist/validators/agent.d.ts.map +1 -1
- package/dist/validators/agent.js +1 -0
- package/dist/validators/agent.js.map +1 -1
- package/dist/validators/approval.d.ts +3 -3
- package/dist/validators/budget.d.ts +56 -0
- package/dist/validators/budget.d.ts.map +1 -0
- package/dist/validators/budget.js +27 -0
- package/dist/validators/budget.js.map +1 -0
- package/dist/validators/company-portability.d.ts +144 -144
- package/dist/validators/company.d.ts +3 -0
- package/dist/validators/company.d.ts.map +1 -1
- package/dist/validators/company.js +2 -0
- package/dist/validators/company.js.map +1 -1
- package/dist/validators/cost.d.ts +45 -1
- package/dist/validators/cost.d.ts.map +1 -1
- package/dist/validators/cost.js +9 -1
- package/dist/validators/cost.js.map +1 -1
- package/dist/validators/execution-workspace.d.ts +20 -0
- package/dist/validators/execution-workspace.d.ts.map +1 -0
- package/dist/validators/execution-workspace.js +15 -0
- package/dist/validators/execution-workspace.js.map +1 -0
- package/dist/validators/finance.d.ts +129 -0
- package/dist/validators/finance.d.ts.map +1 -0
- package/dist/validators/finance.js +32 -0
- package/dist/validators/finance.js.map +1 -0
- package/dist/validators/index.d.ts +7 -1
- package/dist/validators/index.d.ts.map +1 -1
- package/dist/validators/index.js +7 -1
- package/dist/validators/index.js.map +1 -1
- package/dist/validators/instance.d.ts +18 -0
- package/dist/validators/instance.d.ts.map +1 -0
- package/dist/validators/instance.js +6 -0
- package/dist/validators/instance.js.map +1 -0
- package/dist/validators/issue.d.ts +76 -34
- package/dist/validators/issue.d.ts.map +1 -1
- package/dist/validators/issue.js +27 -2
- package/dist/validators/issue.js.map +1 -1
- package/dist/validators/plugin.d.ts +1173 -0
- package/dist/validators/plugin.d.ts.map +1 -0
- package/dist/validators/plugin.js +547 -0
- package/dist/validators/plugin.js.map +1 -0
- package/dist/validators/project.d.ts +188 -42
- package/dist/validators/project.d.ts.map +1 -1
- package/dist/validators/project.js +32 -7
- package/dist/validators/project.js.map +1 -1
- package/dist/validators/work-product.d.ts +105 -0
- package/dist/validators/work-product.d.ts.map +1 -0
- package/dist/validators/work-product.js +46 -0
- package/dist/validators/work-product.js.map +1 -0
- package/package.json +11 -1
|
@@ -202,14 +202,6 @@ export declare const portabilityManifestSchema: z.ZodObject<{
|
|
|
202
202
|
requireBoardApprovalForNewAgents: boolean;
|
|
203
203
|
brandColor: string | null;
|
|
204
204
|
} | null;
|
|
205
|
-
includes: {
|
|
206
|
-
company: boolean;
|
|
207
|
-
agents: boolean;
|
|
208
|
-
};
|
|
209
|
-
source: {
|
|
210
|
-
companyId: string;
|
|
211
|
-
companyName: string;
|
|
212
|
-
} | null;
|
|
213
205
|
agents: {
|
|
214
206
|
path: string;
|
|
215
207
|
name: string;
|
|
@@ -226,6 +218,14 @@ export declare const portabilityManifestSchema: z.ZodObject<{
|
|
|
226
218
|
permissions: Record<string, unknown>;
|
|
227
219
|
metadata: Record<string, unknown> | null;
|
|
228
220
|
}[];
|
|
221
|
+
includes: {
|
|
222
|
+
company: boolean;
|
|
223
|
+
agents: boolean;
|
|
224
|
+
};
|
|
225
|
+
source: {
|
|
226
|
+
companyId: string;
|
|
227
|
+
companyName: string;
|
|
228
|
+
} | null;
|
|
229
229
|
schemaVersion: number;
|
|
230
230
|
generatedAt: string;
|
|
231
231
|
requiredSecrets: {
|
|
@@ -242,14 +242,6 @@ export declare const portabilityManifestSchema: z.ZodObject<{
|
|
|
242
242
|
requireBoardApprovalForNewAgents: boolean;
|
|
243
243
|
brandColor: string | null;
|
|
244
244
|
} | null;
|
|
245
|
-
includes: {
|
|
246
|
-
company: boolean;
|
|
247
|
-
agents: boolean;
|
|
248
|
-
};
|
|
249
|
-
source: {
|
|
250
|
-
companyId: string;
|
|
251
|
-
companyName: string;
|
|
252
|
-
} | null;
|
|
253
245
|
agents: {
|
|
254
246
|
path: string;
|
|
255
247
|
name: string;
|
|
@@ -266,6 +258,14 @@ export declare const portabilityManifestSchema: z.ZodObject<{
|
|
|
266
258
|
permissions: Record<string, unknown>;
|
|
267
259
|
metadata: Record<string, unknown> | null;
|
|
268
260
|
}[];
|
|
261
|
+
includes: {
|
|
262
|
+
company: boolean;
|
|
263
|
+
agents: boolean;
|
|
264
|
+
};
|
|
265
|
+
source: {
|
|
266
|
+
companyId: string;
|
|
267
|
+
companyName: string;
|
|
268
|
+
} | null;
|
|
269
269
|
schemaVersion: number;
|
|
270
270
|
generatedAt: string;
|
|
271
271
|
requiredSecrets?: {
|
|
@@ -389,14 +389,6 @@ export declare const portabilitySourceSchema: z.ZodDiscriminatedUnion<"type", [z
|
|
|
389
389
|
requireBoardApprovalForNewAgents: boolean;
|
|
390
390
|
brandColor: string | null;
|
|
391
391
|
} | null;
|
|
392
|
-
includes: {
|
|
393
|
-
company: boolean;
|
|
394
|
-
agents: boolean;
|
|
395
|
-
};
|
|
396
|
-
source: {
|
|
397
|
-
companyId: string;
|
|
398
|
-
companyName: string;
|
|
399
|
-
} | null;
|
|
400
392
|
agents: {
|
|
401
393
|
path: string;
|
|
402
394
|
name: string;
|
|
@@ -413,6 +405,14 @@ export declare const portabilitySourceSchema: z.ZodDiscriminatedUnion<"type", [z
|
|
|
413
405
|
permissions: Record<string, unknown>;
|
|
414
406
|
metadata: Record<string, unknown> | null;
|
|
415
407
|
}[];
|
|
408
|
+
includes: {
|
|
409
|
+
company: boolean;
|
|
410
|
+
agents: boolean;
|
|
411
|
+
};
|
|
412
|
+
source: {
|
|
413
|
+
companyId: string;
|
|
414
|
+
companyName: string;
|
|
415
|
+
} | null;
|
|
416
416
|
schemaVersion: number;
|
|
417
417
|
generatedAt: string;
|
|
418
418
|
requiredSecrets: {
|
|
@@ -429,14 +429,6 @@ export declare const portabilitySourceSchema: z.ZodDiscriminatedUnion<"type", [z
|
|
|
429
429
|
requireBoardApprovalForNewAgents: boolean;
|
|
430
430
|
brandColor: string | null;
|
|
431
431
|
} | null;
|
|
432
|
-
includes: {
|
|
433
|
-
company: boolean;
|
|
434
|
-
agents: boolean;
|
|
435
|
-
};
|
|
436
|
-
source: {
|
|
437
|
-
companyId: string;
|
|
438
|
-
companyName: string;
|
|
439
|
-
} | null;
|
|
440
432
|
agents: {
|
|
441
433
|
path: string;
|
|
442
434
|
name: string;
|
|
@@ -453,6 +445,14 @@ export declare const portabilitySourceSchema: z.ZodDiscriminatedUnion<"type", [z
|
|
|
453
445
|
permissions: Record<string, unknown>;
|
|
454
446
|
metadata: Record<string, unknown> | null;
|
|
455
447
|
}[];
|
|
448
|
+
includes: {
|
|
449
|
+
company: boolean;
|
|
450
|
+
agents: boolean;
|
|
451
|
+
};
|
|
452
|
+
source: {
|
|
453
|
+
companyId: string;
|
|
454
|
+
companyName: string;
|
|
455
|
+
} | null;
|
|
456
456
|
schemaVersion: number;
|
|
457
457
|
generatedAt: string;
|
|
458
458
|
requiredSecrets?: {
|
|
@@ -473,14 +473,6 @@ export declare const portabilitySourceSchema: z.ZodDiscriminatedUnion<"type", [z
|
|
|
473
473
|
requireBoardApprovalForNewAgents: boolean;
|
|
474
474
|
brandColor: string | null;
|
|
475
475
|
} | null;
|
|
476
|
-
includes: {
|
|
477
|
-
company: boolean;
|
|
478
|
-
agents: boolean;
|
|
479
|
-
};
|
|
480
|
-
source: {
|
|
481
|
-
companyId: string;
|
|
482
|
-
companyName: string;
|
|
483
|
-
} | null;
|
|
484
476
|
agents: {
|
|
485
477
|
path: string;
|
|
486
478
|
name: string;
|
|
@@ -497,6 +489,14 @@ export declare const portabilitySourceSchema: z.ZodDiscriminatedUnion<"type", [z
|
|
|
497
489
|
permissions: Record<string, unknown>;
|
|
498
490
|
metadata: Record<string, unknown> | null;
|
|
499
491
|
}[];
|
|
492
|
+
includes: {
|
|
493
|
+
company: boolean;
|
|
494
|
+
agents: boolean;
|
|
495
|
+
};
|
|
496
|
+
source: {
|
|
497
|
+
companyId: string;
|
|
498
|
+
companyName: string;
|
|
499
|
+
} | null;
|
|
500
500
|
schemaVersion: number;
|
|
501
501
|
generatedAt: string;
|
|
502
502
|
requiredSecrets: {
|
|
@@ -517,14 +517,6 @@ export declare const portabilitySourceSchema: z.ZodDiscriminatedUnion<"type", [z
|
|
|
517
517
|
requireBoardApprovalForNewAgents: boolean;
|
|
518
518
|
brandColor: string | null;
|
|
519
519
|
} | null;
|
|
520
|
-
includes: {
|
|
521
|
-
company: boolean;
|
|
522
|
-
agents: boolean;
|
|
523
|
-
};
|
|
524
|
-
source: {
|
|
525
|
-
companyId: string;
|
|
526
|
-
companyName: string;
|
|
527
|
-
} | null;
|
|
528
520
|
agents: {
|
|
529
521
|
path: string;
|
|
530
522
|
name: string;
|
|
@@ -541,6 +533,14 @@ export declare const portabilitySourceSchema: z.ZodDiscriminatedUnion<"type", [z
|
|
|
541
533
|
permissions: Record<string, unknown>;
|
|
542
534
|
metadata: Record<string, unknown> | null;
|
|
543
535
|
}[];
|
|
536
|
+
includes: {
|
|
537
|
+
company: boolean;
|
|
538
|
+
agents: boolean;
|
|
539
|
+
};
|
|
540
|
+
source: {
|
|
541
|
+
companyId: string;
|
|
542
|
+
companyName: string;
|
|
543
|
+
} | null;
|
|
544
544
|
schemaVersion: number;
|
|
545
545
|
generatedAt: string;
|
|
546
546
|
requiredSecrets?: {
|
|
@@ -729,14 +729,6 @@ export declare const companyPortabilityPreviewSchema: z.ZodObject<{
|
|
|
729
729
|
requireBoardApprovalForNewAgents: boolean;
|
|
730
730
|
brandColor: string | null;
|
|
731
731
|
} | null;
|
|
732
|
-
includes: {
|
|
733
|
-
company: boolean;
|
|
734
|
-
agents: boolean;
|
|
735
|
-
};
|
|
736
|
-
source: {
|
|
737
|
-
companyId: string;
|
|
738
|
-
companyName: string;
|
|
739
|
-
} | null;
|
|
740
732
|
agents: {
|
|
741
733
|
path: string;
|
|
742
734
|
name: string;
|
|
@@ -753,6 +745,14 @@ export declare const companyPortabilityPreviewSchema: z.ZodObject<{
|
|
|
753
745
|
permissions: Record<string, unknown>;
|
|
754
746
|
metadata: Record<string, unknown> | null;
|
|
755
747
|
}[];
|
|
748
|
+
includes: {
|
|
749
|
+
company: boolean;
|
|
750
|
+
agents: boolean;
|
|
751
|
+
};
|
|
752
|
+
source: {
|
|
753
|
+
companyId: string;
|
|
754
|
+
companyName: string;
|
|
755
|
+
} | null;
|
|
756
756
|
schemaVersion: number;
|
|
757
757
|
generatedAt: string;
|
|
758
758
|
requiredSecrets: {
|
|
@@ -769,14 +769,6 @@ export declare const companyPortabilityPreviewSchema: z.ZodObject<{
|
|
|
769
769
|
requireBoardApprovalForNewAgents: boolean;
|
|
770
770
|
brandColor: string | null;
|
|
771
771
|
} | null;
|
|
772
|
-
includes: {
|
|
773
|
-
company: boolean;
|
|
774
|
-
agents: boolean;
|
|
775
|
-
};
|
|
776
|
-
source: {
|
|
777
|
-
companyId: string;
|
|
778
|
-
companyName: string;
|
|
779
|
-
} | null;
|
|
780
772
|
agents: {
|
|
781
773
|
path: string;
|
|
782
774
|
name: string;
|
|
@@ -793,6 +785,14 @@ export declare const companyPortabilityPreviewSchema: z.ZodObject<{
|
|
|
793
785
|
permissions: Record<string, unknown>;
|
|
794
786
|
metadata: Record<string, unknown> | null;
|
|
795
787
|
}[];
|
|
788
|
+
includes: {
|
|
789
|
+
company: boolean;
|
|
790
|
+
agents: boolean;
|
|
791
|
+
};
|
|
792
|
+
source: {
|
|
793
|
+
companyId: string;
|
|
794
|
+
companyName: string;
|
|
795
|
+
} | null;
|
|
796
796
|
schemaVersion: number;
|
|
797
797
|
generatedAt: string;
|
|
798
798
|
requiredSecrets?: {
|
|
@@ -813,14 +813,6 @@ export declare const companyPortabilityPreviewSchema: z.ZodObject<{
|
|
|
813
813
|
requireBoardApprovalForNewAgents: boolean;
|
|
814
814
|
brandColor: string | null;
|
|
815
815
|
} | null;
|
|
816
|
-
includes: {
|
|
817
|
-
company: boolean;
|
|
818
|
-
agents: boolean;
|
|
819
|
-
};
|
|
820
|
-
source: {
|
|
821
|
-
companyId: string;
|
|
822
|
-
companyName: string;
|
|
823
|
-
} | null;
|
|
824
816
|
agents: {
|
|
825
817
|
path: string;
|
|
826
818
|
name: string;
|
|
@@ -837,6 +829,14 @@ export declare const companyPortabilityPreviewSchema: z.ZodObject<{
|
|
|
837
829
|
permissions: Record<string, unknown>;
|
|
838
830
|
metadata: Record<string, unknown> | null;
|
|
839
831
|
}[];
|
|
832
|
+
includes: {
|
|
833
|
+
company: boolean;
|
|
834
|
+
agents: boolean;
|
|
835
|
+
};
|
|
836
|
+
source: {
|
|
837
|
+
companyId: string;
|
|
838
|
+
companyName: string;
|
|
839
|
+
} | null;
|
|
840
840
|
schemaVersion: number;
|
|
841
841
|
generatedAt: string;
|
|
842
842
|
requiredSecrets: {
|
|
@@ -857,14 +857,6 @@ export declare const companyPortabilityPreviewSchema: z.ZodObject<{
|
|
|
857
857
|
requireBoardApprovalForNewAgents: boolean;
|
|
858
858
|
brandColor: string | null;
|
|
859
859
|
} | null;
|
|
860
|
-
includes: {
|
|
861
|
-
company: boolean;
|
|
862
|
-
agents: boolean;
|
|
863
|
-
};
|
|
864
|
-
source: {
|
|
865
|
-
companyId: string;
|
|
866
|
-
companyName: string;
|
|
867
|
-
} | null;
|
|
868
860
|
agents: {
|
|
869
861
|
path: string;
|
|
870
862
|
name: string;
|
|
@@ -881,6 +873,14 @@ export declare const companyPortabilityPreviewSchema: z.ZodObject<{
|
|
|
881
873
|
permissions: Record<string, unknown>;
|
|
882
874
|
metadata: Record<string, unknown> | null;
|
|
883
875
|
}[];
|
|
876
|
+
includes: {
|
|
877
|
+
company: boolean;
|
|
878
|
+
agents: boolean;
|
|
879
|
+
};
|
|
880
|
+
source: {
|
|
881
|
+
companyId: string;
|
|
882
|
+
companyName: string;
|
|
883
|
+
} | null;
|
|
884
884
|
schemaVersion: number;
|
|
885
885
|
generatedAt: string;
|
|
886
886
|
requiredSecrets?: {
|
|
@@ -959,14 +959,6 @@ export declare const companyPortabilityPreviewSchema: z.ZodObject<{
|
|
|
959
959
|
requireBoardApprovalForNewAgents: boolean;
|
|
960
960
|
brandColor: string | null;
|
|
961
961
|
} | null;
|
|
962
|
-
includes: {
|
|
963
|
-
company: boolean;
|
|
964
|
-
agents: boolean;
|
|
965
|
-
};
|
|
966
|
-
source: {
|
|
967
|
-
companyId: string;
|
|
968
|
-
companyName: string;
|
|
969
|
-
} | null;
|
|
970
962
|
agents: {
|
|
971
963
|
path: string;
|
|
972
964
|
name: string;
|
|
@@ -983,6 +975,14 @@ export declare const companyPortabilityPreviewSchema: z.ZodObject<{
|
|
|
983
975
|
permissions: Record<string, unknown>;
|
|
984
976
|
metadata: Record<string, unknown> | null;
|
|
985
977
|
}[];
|
|
978
|
+
includes: {
|
|
979
|
+
company: boolean;
|
|
980
|
+
agents: boolean;
|
|
981
|
+
};
|
|
982
|
+
source: {
|
|
983
|
+
companyId: string;
|
|
984
|
+
companyName: string;
|
|
985
|
+
} | null;
|
|
986
986
|
schemaVersion: number;
|
|
987
987
|
generatedAt: string;
|
|
988
988
|
requiredSecrets: {
|
|
@@ -1024,14 +1024,6 @@ export declare const companyPortabilityPreviewSchema: z.ZodObject<{
|
|
|
1024
1024
|
requireBoardApprovalForNewAgents: boolean;
|
|
1025
1025
|
brandColor: string | null;
|
|
1026
1026
|
} | null;
|
|
1027
|
-
includes: {
|
|
1028
|
-
company: boolean;
|
|
1029
|
-
agents: boolean;
|
|
1030
|
-
};
|
|
1031
|
-
source: {
|
|
1032
|
-
companyId: string;
|
|
1033
|
-
companyName: string;
|
|
1034
|
-
} | null;
|
|
1035
1027
|
agents: {
|
|
1036
1028
|
path: string;
|
|
1037
1029
|
name: string;
|
|
@@ -1048,6 +1040,14 @@ export declare const companyPortabilityPreviewSchema: z.ZodObject<{
|
|
|
1048
1040
|
permissions: Record<string, unknown>;
|
|
1049
1041
|
metadata: Record<string, unknown> | null;
|
|
1050
1042
|
}[];
|
|
1043
|
+
includes: {
|
|
1044
|
+
company: boolean;
|
|
1045
|
+
agents: boolean;
|
|
1046
|
+
};
|
|
1047
|
+
source: {
|
|
1048
|
+
companyId: string;
|
|
1049
|
+
companyName: string;
|
|
1050
|
+
} | null;
|
|
1051
1051
|
schemaVersion: number;
|
|
1052
1052
|
generatedAt: string;
|
|
1053
1053
|
requiredSecrets?: {
|
|
@@ -1188,14 +1188,6 @@ export declare const companyPortabilityImportSchema: z.ZodObject<{
|
|
|
1188
1188
|
requireBoardApprovalForNewAgents: boolean;
|
|
1189
1189
|
brandColor: string | null;
|
|
1190
1190
|
} | null;
|
|
1191
|
-
includes: {
|
|
1192
|
-
company: boolean;
|
|
1193
|
-
agents: boolean;
|
|
1194
|
-
};
|
|
1195
|
-
source: {
|
|
1196
|
-
companyId: string;
|
|
1197
|
-
companyName: string;
|
|
1198
|
-
} | null;
|
|
1199
1191
|
agents: {
|
|
1200
1192
|
path: string;
|
|
1201
1193
|
name: string;
|
|
@@ -1212,6 +1204,14 @@ export declare const companyPortabilityImportSchema: z.ZodObject<{
|
|
|
1212
1204
|
permissions: Record<string, unknown>;
|
|
1213
1205
|
metadata: Record<string, unknown> | null;
|
|
1214
1206
|
}[];
|
|
1207
|
+
includes: {
|
|
1208
|
+
company: boolean;
|
|
1209
|
+
agents: boolean;
|
|
1210
|
+
};
|
|
1211
|
+
source: {
|
|
1212
|
+
companyId: string;
|
|
1213
|
+
companyName: string;
|
|
1214
|
+
} | null;
|
|
1215
1215
|
schemaVersion: number;
|
|
1216
1216
|
generatedAt: string;
|
|
1217
1217
|
requiredSecrets: {
|
|
@@ -1228,14 +1228,6 @@ export declare const companyPortabilityImportSchema: z.ZodObject<{
|
|
|
1228
1228
|
requireBoardApprovalForNewAgents: boolean;
|
|
1229
1229
|
brandColor: string | null;
|
|
1230
1230
|
} | null;
|
|
1231
|
-
includes: {
|
|
1232
|
-
company: boolean;
|
|
1233
|
-
agents: boolean;
|
|
1234
|
-
};
|
|
1235
|
-
source: {
|
|
1236
|
-
companyId: string;
|
|
1237
|
-
companyName: string;
|
|
1238
|
-
} | null;
|
|
1239
1231
|
agents: {
|
|
1240
1232
|
path: string;
|
|
1241
1233
|
name: string;
|
|
@@ -1252,6 +1244,14 @@ export declare const companyPortabilityImportSchema: z.ZodObject<{
|
|
|
1252
1244
|
permissions: Record<string, unknown>;
|
|
1253
1245
|
metadata: Record<string, unknown> | null;
|
|
1254
1246
|
}[];
|
|
1247
|
+
includes: {
|
|
1248
|
+
company: boolean;
|
|
1249
|
+
agents: boolean;
|
|
1250
|
+
};
|
|
1251
|
+
source: {
|
|
1252
|
+
companyId: string;
|
|
1253
|
+
companyName: string;
|
|
1254
|
+
} | null;
|
|
1255
1255
|
schemaVersion: number;
|
|
1256
1256
|
generatedAt: string;
|
|
1257
1257
|
requiredSecrets?: {
|
|
@@ -1272,14 +1272,6 @@ export declare const companyPortabilityImportSchema: z.ZodObject<{
|
|
|
1272
1272
|
requireBoardApprovalForNewAgents: boolean;
|
|
1273
1273
|
brandColor: string | null;
|
|
1274
1274
|
} | null;
|
|
1275
|
-
includes: {
|
|
1276
|
-
company: boolean;
|
|
1277
|
-
agents: boolean;
|
|
1278
|
-
};
|
|
1279
|
-
source: {
|
|
1280
|
-
companyId: string;
|
|
1281
|
-
companyName: string;
|
|
1282
|
-
} | null;
|
|
1283
1275
|
agents: {
|
|
1284
1276
|
path: string;
|
|
1285
1277
|
name: string;
|
|
@@ -1296,6 +1288,14 @@ export declare const companyPortabilityImportSchema: z.ZodObject<{
|
|
|
1296
1288
|
permissions: Record<string, unknown>;
|
|
1297
1289
|
metadata: Record<string, unknown> | null;
|
|
1298
1290
|
}[];
|
|
1291
|
+
includes: {
|
|
1292
|
+
company: boolean;
|
|
1293
|
+
agents: boolean;
|
|
1294
|
+
};
|
|
1295
|
+
source: {
|
|
1296
|
+
companyId: string;
|
|
1297
|
+
companyName: string;
|
|
1298
|
+
} | null;
|
|
1299
1299
|
schemaVersion: number;
|
|
1300
1300
|
generatedAt: string;
|
|
1301
1301
|
requiredSecrets: {
|
|
@@ -1316,14 +1316,6 @@ export declare const companyPortabilityImportSchema: z.ZodObject<{
|
|
|
1316
1316
|
requireBoardApprovalForNewAgents: boolean;
|
|
1317
1317
|
brandColor: string | null;
|
|
1318
1318
|
} | null;
|
|
1319
|
-
includes: {
|
|
1320
|
-
company: boolean;
|
|
1321
|
-
agents: boolean;
|
|
1322
|
-
};
|
|
1323
|
-
source: {
|
|
1324
|
-
companyId: string;
|
|
1325
|
-
companyName: string;
|
|
1326
|
-
} | null;
|
|
1327
1319
|
agents: {
|
|
1328
1320
|
path: string;
|
|
1329
1321
|
name: string;
|
|
@@ -1340,6 +1332,14 @@ export declare const companyPortabilityImportSchema: z.ZodObject<{
|
|
|
1340
1332
|
permissions: Record<string, unknown>;
|
|
1341
1333
|
metadata: Record<string, unknown> | null;
|
|
1342
1334
|
}[];
|
|
1335
|
+
includes: {
|
|
1336
|
+
company: boolean;
|
|
1337
|
+
agents: boolean;
|
|
1338
|
+
};
|
|
1339
|
+
source: {
|
|
1340
|
+
companyId: string;
|
|
1341
|
+
companyName: string;
|
|
1342
|
+
} | null;
|
|
1343
1343
|
schemaVersion: number;
|
|
1344
1344
|
generatedAt: string;
|
|
1345
1345
|
requiredSecrets?: {
|
|
@@ -1418,14 +1418,6 @@ export declare const companyPortabilityImportSchema: z.ZodObject<{
|
|
|
1418
1418
|
requireBoardApprovalForNewAgents: boolean;
|
|
1419
1419
|
brandColor: string | null;
|
|
1420
1420
|
} | null;
|
|
1421
|
-
includes: {
|
|
1422
|
-
company: boolean;
|
|
1423
|
-
agents: boolean;
|
|
1424
|
-
};
|
|
1425
|
-
source: {
|
|
1426
|
-
companyId: string;
|
|
1427
|
-
companyName: string;
|
|
1428
|
-
} | null;
|
|
1429
1421
|
agents: {
|
|
1430
1422
|
path: string;
|
|
1431
1423
|
name: string;
|
|
@@ -1442,6 +1434,14 @@ export declare const companyPortabilityImportSchema: z.ZodObject<{
|
|
|
1442
1434
|
permissions: Record<string, unknown>;
|
|
1443
1435
|
metadata: Record<string, unknown> | null;
|
|
1444
1436
|
}[];
|
|
1437
|
+
includes: {
|
|
1438
|
+
company: boolean;
|
|
1439
|
+
agents: boolean;
|
|
1440
|
+
};
|
|
1441
|
+
source: {
|
|
1442
|
+
companyId: string;
|
|
1443
|
+
companyName: string;
|
|
1444
|
+
} | null;
|
|
1445
1445
|
schemaVersion: number;
|
|
1446
1446
|
generatedAt: string;
|
|
1447
1447
|
requiredSecrets: {
|
|
@@ -1483,14 +1483,6 @@ export declare const companyPortabilityImportSchema: z.ZodObject<{
|
|
|
1483
1483
|
requireBoardApprovalForNewAgents: boolean;
|
|
1484
1484
|
brandColor: string | null;
|
|
1485
1485
|
} | null;
|
|
1486
|
-
includes: {
|
|
1487
|
-
company: boolean;
|
|
1488
|
-
agents: boolean;
|
|
1489
|
-
};
|
|
1490
|
-
source: {
|
|
1491
|
-
companyId: string;
|
|
1492
|
-
companyName: string;
|
|
1493
|
-
} | null;
|
|
1494
1486
|
agents: {
|
|
1495
1487
|
path: string;
|
|
1496
1488
|
name: string;
|
|
@@ -1507,6 +1499,14 @@ export declare const companyPortabilityImportSchema: z.ZodObject<{
|
|
|
1507
1499
|
permissions: Record<string, unknown>;
|
|
1508
1500
|
metadata: Record<string, unknown> | null;
|
|
1509
1501
|
}[];
|
|
1502
|
+
includes: {
|
|
1503
|
+
company: boolean;
|
|
1504
|
+
agents: boolean;
|
|
1505
|
+
};
|
|
1506
|
+
source: {
|
|
1507
|
+
companyId: string;
|
|
1508
|
+
companyName: string;
|
|
1509
|
+
} | null;
|
|
1510
1510
|
schemaVersion: number;
|
|
1511
1511
|
generatedAt: string;
|
|
1512
1512
|
requiredSecrets?: {
|
|
@@ -22,6 +22,7 @@ export declare const updateCompanySchema: z.ZodObject<{
|
|
|
22
22
|
spentMonthlyCents: z.ZodOptional<z.ZodNumber>;
|
|
23
23
|
requireBoardApprovalForNewAgents: z.ZodOptional<z.ZodBoolean>;
|
|
24
24
|
brandColor: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
25
|
+
logoAssetId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
25
26
|
}, "strip", z.ZodTypeAny, {
|
|
26
27
|
status?: "active" | "paused" | "archived" | undefined;
|
|
27
28
|
name?: string | undefined;
|
|
@@ -30,6 +31,7 @@ export declare const updateCompanySchema: z.ZodObject<{
|
|
|
30
31
|
spentMonthlyCents?: number | undefined;
|
|
31
32
|
requireBoardApprovalForNewAgents?: boolean | undefined;
|
|
32
33
|
brandColor?: string | null | undefined;
|
|
34
|
+
logoAssetId?: string | null | undefined;
|
|
33
35
|
}, {
|
|
34
36
|
status?: "active" | "paused" | "archived" | undefined;
|
|
35
37
|
name?: string | undefined;
|
|
@@ -38,6 +40,7 @@ export declare const updateCompanySchema: z.ZodObject<{
|
|
|
38
40
|
spentMonthlyCents?: number | undefined;
|
|
39
41
|
requireBoardApprovalForNewAgents?: boolean | undefined;
|
|
40
42
|
brandColor?: string | null | undefined;
|
|
43
|
+
logoAssetId?: string | null | undefined;
|
|
41
44
|
}>;
|
|
42
45
|
export type UpdateCompany = z.infer<typeof updateCompanySchema>;
|
|
43
46
|
//# sourceMappingURL=company.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"company.d.ts","sourceRoot":"","sources":["../../src/validators/company.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;
|
|
1
|
+
{"version":3,"file":"company.d.ts","sourceRoot":"","sources":["../../src/validators/company.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAKxB,eAAO,MAAM,mBAAmB;;;;;;;;;;;;EAI9B,CAAC;AAEH,MAAM,MAAM,aAAa,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAEhE,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAQ5B,CAAC;AAEL,MAAM,MAAM,aAAa,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC"}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
2
|
import { COMPANY_STATUSES } from "../constants.js";
|
|
3
|
+
const logoAssetIdSchema = z.string().uuid().nullable().optional();
|
|
3
4
|
export const createCompanySchema = z.object({
|
|
4
5
|
name: z.string().min(1),
|
|
5
6
|
description: z.string().optional().nullable(),
|
|
@@ -12,5 +13,6 @@ export const updateCompanySchema = createCompanySchema
|
|
|
12
13
|
spentMonthlyCents: z.number().int().nonnegative().optional(),
|
|
13
14
|
requireBoardApprovalForNewAgents: z.boolean().optional(),
|
|
14
15
|
brandColor: z.string().regex(/^#[0-9a-fA-F]{6}$/).nullable().optional(),
|
|
16
|
+
logoAssetId: logoAssetIdSchema,
|
|
15
17
|
});
|
|
16
18
|
//# sourceMappingURL=company.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"company.js","sourceRoot":"","sources":["../../src/validators/company.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,gBAAgB,EAAE,MAAM,iBAAiB,CAAC;AAEnD,MAAM,CAAC,MAAM,mBAAmB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC1C,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC;IACvB,WAAW,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,EAAE;IAC7C,kBAAkB,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,WAAW,EAAE,CAAC,QAAQ,EAAE,CAAC,OAAO,CAAC,CAAC,CAAC;CACzE,CAAC,CAAC;AAIH,MAAM,CAAC,MAAM,mBAAmB,GAAG,mBAAmB;KACnD,OAAO,EAAE;KACT,MAAM,CAAC;IACN,MAAM,EAAE,CAAC,CAAC,IAAI,CAAC,gBAAgB,CAAC,CAAC,QAAQ,EAAE;IAC3C,iBAAiB,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,WAAW,EAAE,CAAC,QAAQ,EAAE;IAC5D,gCAAgC,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC,QAAQ,EAAE;IACxD,UAAU,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,KAAK,CAAC,mBAAmB,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,EAAE;
|
|
1
|
+
{"version":3,"file":"company.js","sourceRoot":"","sources":["../../src/validators/company.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,gBAAgB,EAAE,MAAM,iBAAiB,CAAC;AAEnD,MAAM,iBAAiB,GAAG,CAAC,CAAC,MAAM,EAAE,CAAC,IAAI,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,EAAE,CAAC;AAElE,MAAM,CAAC,MAAM,mBAAmB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC1C,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC;IACvB,WAAW,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,EAAE;IAC7C,kBAAkB,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,WAAW,EAAE,CAAC,QAAQ,EAAE,CAAC,OAAO,CAAC,CAAC,CAAC;CACzE,CAAC,CAAC;AAIH,MAAM,CAAC,MAAM,mBAAmB,GAAG,mBAAmB;KACnD,OAAO,EAAE;KACT,MAAM,CAAC;IACN,MAAM,EAAE,CAAC,CAAC,IAAI,CAAC,gBAAgB,CAAC,CAAC,QAAQ,EAAE;IAC3C,iBAAiB,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,WAAW,EAAE,CAAC,QAAQ,EAAE;IAC5D,gCAAgC,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC,QAAQ,EAAE;IACxD,UAAU,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,KAAK,CAAC,mBAAmB,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,EAAE;IACvE,WAAW,EAAE,iBAAiB;CAC/B,CAAC,CAAC"}
|
|
@@ -1,21 +1,27 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
|
-
export declare const createCostEventSchema: z.ZodObject<{
|
|
2
|
+
export declare const createCostEventSchema: z.ZodEffects<z.ZodObject<{
|
|
3
3
|
agentId: z.ZodString;
|
|
4
4
|
issueId: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
5
5
|
projectId: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
6
6
|
goalId: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
7
|
+
heartbeatRunId: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
7
8
|
billingCode: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
8
9
|
provider: z.ZodString;
|
|
10
|
+
biller: z.ZodOptional<z.ZodString>;
|
|
11
|
+
billingType: z.ZodDefault<z.ZodOptional<z.ZodEnum<["metered_api", "subscription_included", "subscription_overage", "credits", "fixed", "unknown"]>>>;
|
|
9
12
|
model: z.ZodString;
|
|
10
13
|
inputTokens: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
14
|
+
cachedInputTokens: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
11
15
|
outputTokens: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
12
16
|
costCents: z.ZodNumber;
|
|
13
17
|
occurredAt: z.ZodString;
|
|
14
18
|
}, "strip", z.ZodTypeAny, {
|
|
15
19
|
provider: string;
|
|
16
20
|
agentId: string;
|
|
21
|
+
billingType: "metered_api" | "subscription_included" | "subscription_overage" | "credits" | "fixed" | "unknown";
|
|
17
22
|
model: string;
|
|
18
23
|
inputTokens: number;
|
|
24
|
+
cachedInputTokens: number;
|
|
19
25
|
outputTokens: number;
|
|
20
26
|
costCents: number;
|
|
21
27
|
occurredAt: string;
|
|
@@ -23,6 +29,8 @@ export declare const createCostEventSchema: z.ZodObject<{
|
|
|
23
29
|
projectId?: string | null | undefined;
|
|
24
30
|
billingCode?: string | null | undefined;
|
|
25
31
|
issueId?: string | null | undefined;
|
|
32
|
+
heartbeatRunId?: string | null | undefined;
|
|
33
|
+
biller?: string | undefined;
|
|
26
34
|
}, {
|
|
27
35
|
provider: string;
|
|
28
36
|
agentId: string;
|
|
@@ -33,7 +41,43 @@ export declare const createCostEventSchema: z.ZodObject<{
|
|
|
33
41
|
projectId?: string | null | undefined;
|
|
34
42
|
billingCode?: string | null | undefined;
|
|
35
43
|
issueId?: string | null | undefined;
|
|
44
|
+
heartbeatRunId?: string | null | undefined;
|
|
45
|
+
biller?: string | undefined;
|
|
46
|
+
billingType?: "metered_api" | "subscription_included" | "subscription_overage" | "credits" | "fixed" | "unknown" | undefined;
|
|
36
47
|
inputTokens?: number | undefined;
|
|
48
|
+
cachedInputTokens?: number | undefined;
|
|
49
|
+
outputTokens?: number | undefined;
|
|
50
|
+
}>, {
|
|
51
|
+
biller: string;
|
|
52
|
+
provider: string;
|
|
53
|
+
agentId: string;
|
|
54
|
+
billingType: "metered_api" | "subscription_included" | "subscription_overage" | "credits" | "fixed" | "unknown";
|
|
55
|
+
model: string;
|
|
56
|
+
inputTokens: number;
|
|
57
|
+
cachedInputTokens: number;
|
|
58
|
+
outputTokens: number;
|
|
59
|
+
costCents: number;
|
|
60
|
+
occurredAt: string;
|
|
61
|
+
goalId?: string | null | undefined;
|
|
62
|
+
projectId?: string | null | undefined;
|
|
63
|
+
billingCode?: string | null | undefined;
|
|
64
|
+
issueId?: string | null | undefined;
|
|
65
|
+
heartbeatRunId?: string | null | undefined;
|
|
66
|
+
}, {
|
|
67
|
+
provider: string;
|
|
68
|
+
agentId: string;
|
|
69
|
+
model: string;
|
|
70
|
+
costCents: number;
|
|
71
|
+
occurredAt: string;
|
|
72
|
+
goalId?: string | null | undefined;
|
|
73
|
+
projectId?: string | null | undefined;
|
|
74
|
+
billingCode?: string | null | undefined;
|
|
75
|
+
issueId?: string | null | undefined;
|
|
76
|
+
heartbeatRunId?: string | null | undefined;
|
|
77
|
+
biller?: string | undefined;
|
|
78
|
+
billingType?: "metered_api" | "subscription_included" | "subscription_overage" | "credits" | "fixed" | "unknown" | undefined;
|
|
79
|
+
inputTokens?: number | undefined;
|
|
80
|
+
cachedInputTokens?: number | undefined;
|
|
37
81
|
outputTokens?: number | undefined;
|
|
38
82
|
}>;
|
|
39
83
|
export type CreateCostEvent = z.infer<typeof createCostEventSchema>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cost.d.ts","sourceRoot":"","sources":["../../src/validators/cost.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;
|
|
1
|
+
{"version":3,"file":"cost.d.ts","sourceRoot":"","sources":["../../src/validators/cost.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAmB/B,CAAC;AAEJ,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,qBAAqB,CAAC,CAAC;AAEpE,eAAO,MAAM,kBAAkB;;;;;;EAE7B,CAAC;AAEH,MAAM,MAAM,YAAY,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,kBAAkB,CAAC,CAAC"}
|
package/dist/validators/cost.js
CHANGED
|
@@ -1,17 +1,25 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
|
+
import { BILLING_TYPES } from "../constants.js";
|
|
2
3
|
export const createCostEventSchema = z.object({
|
|
3
4
|
agentId: z.string().uuid(),
|
|
4
5
|
issueId: z.string().uuid().optional().nullable(),
|
|
5
6
|
projectId: z.string().uuid().optional().nullable(),
|
|
6
7
|
goalId: z.string().uuid().optional().nullable(),
|
|
8
|
+
heartbeatRunId: z.string().uuid().optional().nullable(),
|
|
7
9
|
billingCode: z.string().optional().nullable(),
|
|
8
10
|
provider: z.string().min(1),
|
|
11
|
+
biller: z.string().min(1).optional(),
|
|
12
|
+
billingType: z.enum(BILLING_TYPES).optional().default("unknown"),
|
|
9
13
|
model: z.string().min(1),
|
|
10
14
|
inputTokens: z.number().int().nonnegative().optional().default(0),
|
|
15
|
+
cachedInputTokens: z.number().int().nonnegative().optional().default(0),
|
|
11
16
|
outputTokens: z.number().int().nonnegative().optional().default(0),
|
|
12
17
|
costCents: z.number().int().nonnegative(),
|
|
13
18
|
occurredAt: z.string().datetime(),
|
|
14
|
-
})
|
|
19
|
+
}).transform((value) => ({
|
|
20
|
+
...value,
|
|
21
|
+
biller: value.biller ?? value.provider,
|
|
22
|
+
}));
|
|
15
23
|
export const updateBudgetSchema = z.object({
|
|
16
24
|
budgetMonthlyCents: z.number().int().nonnegative(),
|
|
17
25
|
});
|