@deepintel-ltd/farmpro-contracts 1.10.0 → 1.11.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.
@@ -48,13 +48,42 @@ export declare const commodityDealsRouter: {
48
48
  currency: z.ZodDefault<z.ZodString>;
49
49
  status: z.ZodEnum<["draft", "in_transit", "invoiced", "paid", "cancelled"]>;
50
50
  notes: z.ZodNullable<z.ZodString>;
51
+ companyCommissionRate: z.ZodNullable<z.ZodNumber>;
52
+ participants: z.ZodOptional<z.ZodArray<z.ZodObject<{
53
+ userId: z.ZodString;
54
+ name: z.ZodOptional<z.ZodString>;
55
+ email: z.ZodOptional<z.ZodString>;
56
+ capitalContributed: z.ZodNumber;
57
+ ownershipPercent: z.ZodNumber;
58
+ earningsAmount: z.ZodNullable<z.ZodNumber>;
59
+ }, "strip", z.ZodTypeAny, {
60
+ userId: string;
61
+ capitalContributed: number;
62
+ ownershipPercent: number;
63
+ earningsAmount: number | null;
64
+ email?: string | undefined;
65
+ name?: string | undefined;
66
+ }, {
67
+ userId: string;
68
+ capitalContributed: number;
69
+ ownershipPercent: number;
70
+ earningsAmount: number | null;
71
+ email?: string | undefined;
72
+ name?: string | undefined;
73
+ }>, "many">>;
51
74
  computed: z.ZodObject<{
52
75
  totalCost: z.ZodNumber;
53
76
  saleAmount: z.ZodNullable<z.ZodNumber>;
54
77
  grossProfit: z.ZodNullable<z.ZodNumber>;
55
78
  commissionRate: z.ZodNullable<z.ZodNumber>;
79
+ staffCommissionRate: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
56
80
  commissionAmount: z.ZodNullable<z.ZodNumber>;
81
+ staffCommissionAmount: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
57
82
  companyNet: z.ZodNullable<z.ZodNumber>;
83
+ netAfterStaff: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
84
+ companyCommissionRate: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
85
+ companyCommissionAmount: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
86
+ investorPool: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
58
87
  isRealized: z.ZodBoolean;
59
88
  }, "strip", z.ZodTypeAny, {
60
89
  totalCost: number;
@@ -64,6 +93,12 @@ export declare const commodityDealsRouter: {
64
93
  commissionAmount: number | null;
65
94
  companyNet: number | null;
66
95
  isRealized: boolean;
96
+ companyCommissionRate?: number | null | undefined;
97
+ staffCommissionRate?: number | null | undefined;
98
+ staffCommissionAmount?: number | null | undefined;
99
+ netAfterStaff?: number | null | undefined;
100
+ companyCommissionAmount?: number | null | undefined;
101
+ investorPool?: number | null | undefined;
67
102
  }, {
68
103
  totalCost: number;
69
104
  saleAmount: number | null;
@@ -72,6 +107,12 @@ export declare const commodityDealsRouter: {
72
107
  commissionAmount: number | null;
73
108
  companyNet: number | null;
74
109
  isRealized: boolean;
110
+ companyCommissionRate?: number | null | undefined;
111
+ staffCommissionRate?: number | null | undefined;
112
+ staffCommissionAmount?: number | null | undefined;
113
+ netAfterStaff?: number | null | undefined;
114
+ companyCommissionAmount?: number | null | undefined;
115
+ investorPool?: number | null | undefined;
75
116
  }>;
76
117
  } & {
77
118
  createdAt: z.ZodString;
@@ -85,6 +126,7 @@ export declare const commodityDealsRouter: {
85
126
  buyerName: string | null;
86
127
  transportCost: number;
87
128
  organizationId: string;
129
+ companyCommissionRate: number | null;
88
130
  waybillNumber: string | null;
89
131
  purchaseCost: number;
90
132
  miscellaneousCost: number;
@@ -100,7 +142,21 @@ export declare const commodityDealsRouter: {
100
142
  commissionAmount: number | null;
101
143
  companyNet: number | null;
102
144
  isRealized: boolean;
145
+ companyCommissionRate?: number | null | undefined;
146
+ staffCommissionRate?: number | null | undefined;
147
+ staffCommissionAmount?: number | null | undefined;
148
+ netAfterStaff?: number | null | undefined;
149
+ companyCommissionAmount?: number | null | undefined;
150
+ investorPool?: number | null | undefined;
103
151
  };
152
+ participants?: {
153
+ userId: string;
154
+ capitalContributed: number;
155
+ ownershipPercent: number;
156
+ earningsAmount: number | null;
157
+ email?: string | undefined;
158
+ name?: string | undefined;
159
+ }[] | undefined;
104
160
  }, {
105
161
  status: "cancelled" | "paid" | "draft" | "in_transit" | "invoiced";
106
162
  createdAt: string;
@@ -109,6 +165,7 @@ export declare const commodityDealsRouter: {
109
165
  buyerName: string | null;
110
166
  transportCost: number;
111
167
  organizationId: string;
168
+ companyCommissionRate: number | null;
112
169
  waybillNumber: string | null;
113
170
  purchaseCost: number;
114
171
  miscellaneousCost: number;
@@ -124,8 +181,22 @@ export declare const commodityDealsRouter: {
124
181
  commissionAmount: number | null;
125
182
  companyNet: number | null;
126
183
  isRealized: boolean;
184
+ companyCommissionRate?: number | null | undefined;
185
+ staffCommissionRate?: number | null | undefined;
186
+ staffCommissionAmount?: number | null | undefined;
187
+ netAfterStaff?: number | null | undefined;
188
+ companyCommissionAmount?: number | null | undefined;
189
+ investorPool?: number | null | undefined;
127
190
  };
128
191
  currency?: string | undefined;
192
+ participants?: {
193
+ userId: string;
194
+ capitalContributed: number;
195
+ ownershipPercent: number;
196
+ earningsAmount: number | null;
197
+ email?: string | undefined;
198
+ name?: string | undefined;
199
+ }[] | undefined;
129
200
  }>;
130
201
  relationships: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
131
202
  links: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
@@ -142,6 +213,7 @@ export declare const commodityDealsRouter: {
142
213
  buyerName: string | null;
143
214
  transportCost: number;
144
215
  organizationId: string;
216
+ companyCommissionRate: number | null;
145
217
  waybillNumber: string | null;
146
218
  purchaseCost: number;
147
219
  miscellaneousCost: number;
@@ -157,7 +229,21 @@ export declare const commodityDealsRouter: {
157
229
  commissionAmount: number | null;
158
230
  companyNet: number | null;
159
231
  isRealized: boolean;
232
+ companyCommissionRate?: number | null | undefined;
233
+ staffCommissionRate?: number | null | undefined;
234
+ staffCommissionAmount?: number | null | undefined;
235
+ netAfterStaff?: number | null | undefined;
236
+ companyCommissionAmount?: number | null | undefined;
237
+ investorPool?: number | null | undefined;
160
238
  };
239
+ participants?: {
240
+ userId: string;
241
+ capitalContributed: number;
242
+ ownershipPercent: number;
243
+ earningsAmount: number | null;
244
+ email?: string | undefined;
245
+ name?: string | undefined;
246
+ }[] | undefined;
161
247
  };
162
248
  relationships?: Record<string, unknown> | undefined;
163
249
  links?: Record<string, string> | undefined;
@@ -173,6 +259,7 @@ export declare const commodityDealsRouter: {
173
259
  buyerName: string | null;
174
260
  transportCost: number;
175
261
  organizationId: string;
262
+ companyCommissionRate: number | null;
176
263
  waybillNumber: string | null;
177
264
  purchaseCost: number;
178
265
  miscellaneousCost: number;
@@ -188,8 +275,22 @@ export declare const commodityDealsRouter: {
188
275
  commissionAmount: number | null;
189
276
  companyNet: number | null;
190
277
  isRealized: boolean;
278
+ companyCommissionRate?: number | null | undefined;
279
+ staffCommissionRate?: number | null | undefined;
280
+ staffCommissionAmount?: number | null | undefined;
281
+ netAfterStaff?: number | null | undefined;
282
+ companyCommissionAmount?: number | null | undefined;
283
+ investorPool?: number | null | undefined;
191
284
  };
192
285
  currency?: string | undefined;
286
+ participants?: {
287
+ userId: string;
288
+ capitalContributed: number;
289
+ ownershipPercent: number;
290
+ earningsAmount: number | null;
291
+ email?: string | undefined;
292
+ name?: string | undefined;
293
+ }[] | undefined;
193
294
  };
194
295
  relationships?: Record<string, unknown> | undefined;
195
296
  links?: Record<string, string> | undefined;
@@ -232,6 +333,7 @@ export declare const commodityDealsRouter: {
232
333
  buyerName: string | null;
233
334
  transportCost: number;
234
335
  organizationId: string;
336
+ companyCommissionRate: number | null;
235
337
  waybillNumber: string | null;
236
338
  purchaseCost: number;
237
339
  miscellaneousCost: number;
@@ -247,7 +349,21 @@ export declare const commodityDealsRouter: {
247
349
  commissionAmount: number | null;
248
350
  companyNet: number | null;
249
351
  isRealized: boolean;
352
+ companyCommissionRate?: number | null | undefined;
353
+ staffCommissionRate?: number | null | undefined;
354
+ staffCommissionAmount?: number | null | undefined;
355
+ netAfterStaff?: number | null | undefined;
356
+ companyCommissionAmount?: number | null | undefined;
357
+ investorPool?: number | null | undefined;
250
358
  };
359
+ participants?: {
360
+ userId: string;
361
+ capitalContributed: number;
362
+ ownershipPercent: number;
363
+ earningsAmount: number | null;
364
+ email?: string | undefined;
365
+ name?: string | undefined;
366
+ }[] | undefined;
251
367
  };
252
368
  relationships?: Record<string, unknown> | undefined;
253
369
  links?: Record<string, string> | undefined;
@@ -275,6 +391,7 @@ export declare const commodityDealsRouter: {
275
391
  buyerName: string | null;
276
392
  transportCost: number;
277
393
  organizationId: string;
394
+ companyCommissionRate: number | null;
278
395
  waybillNumber: string | null;
279
396
  purchaseCost: number;
280
397
  miscellaneousCost: number;
@@ -290,8 +407,22 @@ export declare const commodityDealsRouter: {
290
407
  commissionAmount: number | null;
291
408
  companyNet: number | null;
292
409
  isRealized: boolean;
410
+ companyCommissionRate?: number | null | undefined;
411
+ staffCommissionRate?: number | null | undefined;
412
+ staffCommissionAmount?: number | null | undefined;
413
+ netAfterStaff?: number | null | undefined;
414
+ companyCommissionAmount?: number | null | undefined;
415
+ investorPool?: number | null | undefined;
293
416
  };
294
417
  currency?: string | undefined;
418
+ participants?: {
419
+ userId: string;
420
+ capitalContributed: number;
421
+ ownershipPercent: number;
422
+ earningsAmount: number | null;
423
+ email?: string | undefined;
424
+ name?: string | undefined;
425
+ }[] | undefined;
295
426
  };
296
427
  relationships?: Record<string, unknown> | undefined;
297
428
  links?: Record<string, string> | undefined;
@@ -511,6 +642,8 @@ export declare const commodityDealsRouter: {
511
642
  grossProfitOnPaidDeals: z.ZodNumber;
512
643
  totalCommissionOnPaidDeals: z.ZodNumber;
513
644
  companyNetOnPaidDeals: z.ZodNumber;
645
+ totalCompanyCommissionOnPaidDeals: z.ZodOptional<z.ZodNumber>;
646
+ totalInvestorPoolOnPaidDeals: z.ZodOptional<z.ZodNumber>;
514
647
  unrealizedGrossProfit: z.ZodNumber;
515
648
  currency: z.ZodDefault<z.ZodString>;
516
649
  }, "strip", z.ZodTypeAny, {
@@ -523,6 +656,8 @@ export declare const commodityDealsRouter: {
523
656
  totalCommissionOnPaidDeals: number;
524
657
  companyNetOnPaidDeals: number;
525
658
  unrealizedGrossProfit: number;
659
+ totalCompanyCommissionOnPaidDeals?: number | undefined;
660
+ totalInvestorPoolOnPaidDeals?: number | undefined;
526
661
  }, {
527
662
  paidDealCount: number;
528
663
  invoicedUnpaidCount: number;
@@ -533,6 +668,8 @@ export declare const commodityDealsRouter: {
533
668
  companyNetOnPaidDeals: number;
534
669
  unrealizedGrossProfit: number;
535
670
  currency?: string | undefined;
671
+ totalCompanyCommissionOnPaidDeals?: number | undefined;
672
+ totalInvestorPoolOnPaidDeals?: number | undefined;
536
673
  }>;
537
674
  }, "strip", z.ZodTypeAny, {
538
675
  data: {
@@ -545,6 +682,8 @@ export declare const commodityDealsRouter: {
545
682
  totalCommissionOnPaidDeals: number;
546
683
  companyNetOnPaidDeals: number;
547
684
  unrealizedGrossProfit: number;
685
+ totalCompanyCommissionOnPaidDeals?: number | undefined;
686
+ totalInvestorPoolOnPaidDeals?: number | undefined;
548
687
  };
549
688
  }, {
550
689
  data: {
@@ -557,6 +696,271 @@ export declare const commodityDealsRouter: {
557
696
  companyNetOnPaidDeals: number;
558
697
  unrealizedGrossProfit: number;
559
698
  currency?: string | undefined;
699
+ totalCompanyCommissionOnPaidDeals?: number | undefined;
700
+ totalInvestorPoolOnPaidDeals?: number | undefined;
701
+ };
702
+ }>;
703
+ 401: z.ZodObject<{
704
+ errors: z.ZodArray<z.ZodObject<{
705
+ id: z.ZodOptional<z.ZodString>;
706
+ links: z.ZodOptional<z.ZodObject<{
707
+ about: z.ZodOptional<z.ZodString>;
708
+ }, "strip", z.ZodTypeAny, {
709
+ about?: string | undefined;
710
+ }, {
711
+ about?: string | undefined;
712
+ }>>;
713
+ status: z.ZodOptional<z.ZodString>;
714
+ code: z.ZodOptional<z.ZodString>;
715
+ title: z.ZodOptional<z.ZodString>;
716
+ detail: z.ZodOptional<z.ZodString>;
717
+ source: z.ZodOptional<z.ZodObject<{
718
+ pointer: z.ZodOptional<z.ZodString>;
719
+ parameter: z.ZodOptional<z.ZodString>;
720
+ }, "strip", z.ZodTypeAny, {
721
+ pointer?: string | undefined;
722
+ parameter?: string | undefined;
723
+ }, {
724
+ pointer?: string | undefined;
725
+ parameter?: string | undefined;
726
+ }>>;
727
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
728
+ }, "strip", z.ZodTypeAny, {
729
+ status?: string | undefined;
730
+ code?: string | undefined;
731
+ id?: string | undefined;
732
+ links?: {
733
+ about?: string | undefined;
734
+ } | undefined;
735
+ meta?: Record<string, unknown> | undefined;
736
+ title?: string | undefined;
737
+ detail?: string | undefined;
738
+ source?: {
739
+ pointer?: string | undefined;
740
+ parameter?: string | undefined;
741
+ } | undefined;
742
+ }, {
743
+ status?: string | undefined;
744
+ code?: string | undefined;
745
+ id?: string | undefined;
746
+ links?: {
747
+ about?: string | undefined;
748
+ } | undefined;
749
+ meta?: Record<string, unknown> | undefined;
750
+ title?: string | undefined;
751
+ detail?: string | undefined;
752
+ source?: {
753
+ pointer?: string | undefined;
754
+ parameter?: string | undefined;
755
+ } | undefined;
756
+ }>, "many">;
757
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
758
+ }, "strip", z.ZodTypeAny, {
759
+ errors: {
760
+ status?: string | undefined;
761
+ code?: string | undefined;
762
+ id?: string | undefined;
763
+ links?: {
764
+ about?: string | undefined;
765
+ } | undefined;
766
+ meta?: Record<string, unknown> | undefined;
767
+ title?: string | undefined;
768
+ detail?: string | undefined;
769
+ source?: {
770
+ pointer?: string | undefined;
771
+ parameter?: string | undefined;
772
+ } | undefined;
773
+ }[];
774
+ meta?: Record<string, unknown> | undefined;
775
+ }, {
776
+ errors: {
777
+ status?: string | undefined;
778
+ code?: string | undefined;
779
+ id?: string | undefined;
780
+ links?: {
781
+ about?: string | undefined;
782
+ } | undefined;
783
+ meta?: Record<string, unknown> | undefined;
784
+ title?: string | undefined;
785
+ detail?: string | undefined;
786
+ source?: {
787
+ pointer?: string | undefined;
788
+ parameter?: string | undefined;
789
+ } | undefined;
790
+ }[];
791
+ meta?: Record<string, unknown> | undefined;
792
+ }>;
793
+ 404: z.ZodObject<{
794
+ errors: z.ZodArray<z.ZodObject<{
795
+ id: z.ZodOptional<z.ZodString>;
796
+ links: z.ZodOptional<z.ZodObject<{
797
+ about: z.ZodOptional<z.ZodString>;
798
+ }, "strip", z.ZodTypeAny, {
799
+ about?: string | undefined;
800
+ }, {
801
+ about?: string | undefined;
802
+ }>>;
803
+ status: z.ZodOptional<z.ZodString>;
804
+ code: z.ZodOptional<z.ZodString>;
805
+ title: z.ZodOptional<z.ZodString>;
806
+ detail: z.ZodOptional<z.ZodString>;
807
+ source: z.ZodOptional<z.ZodObject<{
808
+ pointer: z.ZodOptional<z.ZodString>;
809
+ parameter: z.ZodOptional<z.ZodString>;
810
+ }, "strip", z.ZodTypeAny, {
811
+ pointer?: string | undefined;
812
+ parameter?: string | undefined;
813
+ }, {
814
+ pointer?: string | undefined;
815
+ parameter?: string | undefined;
816
+ }>>;
817
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
818
+ }, "strip", z.ZodTypeAny, {
819
+ status?: string | undefined;
820
+ code?: string | undefined;
821
+ id?: string | undefined;
822
+ links?: {
823
+ about?: string | undefined;
824
+ } | undefined;
825
+ meta?: Record<string, unknown> | undefined;
826
+ title?: string | undefined;
827
+ detail?: string | undefined;
828
+ source?: {
829
+ pointer?: string | undefined;
830
+ parameter?: string | undefined;
831
+ } | undefined;
832
+ }, {
833
+ status?: string | undefined;
834
+ code?: string | undefined;
835
+ id?: string | undefined;
836
+ links?: {
837
+ about?: string | undefined;
838
+ } | undefined;
839
+ meta?: Record<string, unknown> | undefined;
840
+ title?: string | undefined;
841
+ detail?: string | undefined;
842
+ source?: {
843
+ pointer?: string | undefined;
844
+ parameter?: string | undefined;
845
+ } | undefined;
846
+ }>, "many">;
847
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
848
+ }, "strip", z.ZodTypeAny, {
849
+ errors: {
850
+ status?: string | undefined;
851
+ code?: string | undefined;
852
+ id?: string | undefined;
853
+ links?: {
854
+ about?: string | undefined;
855
+ } | undefined;
856
+ meta?: Record<string, unknown> | undefined;
857
+ title?: string | undefined;
858
+ detail?: string | undefined;
859
+ source?: {
860
+ pointer?: string | undefined;
861
+ parameter?: string | undefined;
862
+ } | undefined;
863
+ }[];
864
+ meta?: Record<string, unknown> | undefined;
865
+ }, {
866
+ errors: {
867
+ status?: string | undefined;
868
+ code?: string | undefined;
869
+ id?: string | undefined;
870
+ links?: {
871
+ about?: string | undefined;
872
+ } | undefined;
873
+ meta?: Record<string, unknown> | undefined;
874
+ title?: string | undefined;
875
+ detail?: string | undefined;
876
+ source?: {
877
+ pointer?: string | undefined;
878
+ parameter?: string | undefined;
879
+ } | undefined;
880
+ }[];
881
+ meta?: Record<string, unknown> | undefined;
882
+ }>;
883
+ };
884
+ };
885
+ getMyEarnings: {
886
+ pathParams: z.ZodObject<{
887
+ organizationId: z.ZodString;
888
+ }, "strip", z.ZodTypeAny, {
889
+ organizationId: string;
890
+ }, {
891
+ organizationId: string;
892
+ }>;
893
+ summary: "Get investor earnings for the current user in an organization";
894
+ method: "GET";
895
+ path: "/organizations/:organizationId/commodity-deals/my-earnings";
896
+ responses: {
897
+ 200: z.ZodObject<{
898
+ data: z.ZodObject<{
899
+ type: z.ZodLiteral<"investor-earnings">;
900
+ id: z.ZodString;
901
+ attributes: z.ZodObject<{
902
+ realizedEarnings: z.ZodNumber;
903
+ projectedEarnings: z.ZodNumber;
904
+ capitalDeployed: z.ZodNumber;
905
+ dealCount: z.ZodNumber;
906
+ currency: z.ZodDefault<z.ZodString>;
907
+ }, "strip", z.ZodTypeAny, {
908
+ currency: string;
909
+ realizedEarnings: number;
910
+ projectedEarnings: number;
911
+ capitalDeployed: number;
912
+ dealCount: number;
913
+ }, {
914
+ realizedEarnings: number;
915
+ projectedEarnings: number;
916
+ capitalDeployed: number;
917
+ dealCount: number;
918
+ currency?: string | undefined;
919
+ }>;
920
+ }, "strip", z.ZodTypeAny, {
921
+ type: "investor-earnings";
922
+ id: string;
923
+ attributes: {
924
+ currency: string;
925
+ realizedEarnings: number;
926
+ projectedEarnings: number;
927
+ capitalDeployed: number;
928
+ dealCount: number;
929
+ };
930
+ }, {
931
+ type: "investor-earnings";
932
+ id: string;
933
+ attributes: {
934
+ realizedEarnings: number;
935
+ projectedEarnings: number;
936
+ capitalDeployed: number;
937
+ dealCount: number;
938
+ currency?: string | undefined;
939
+ };
940
+ }>;
941
+ }, "strip", z.ZodTypeAny, {
942
+ data: {
943
+ type: "investor-earnings";
944
+ id: string;
945
+ attributes: {
946
+ currency: string;
947
+ realizedEarnings: number;
948
+ projectedEarnings: number;
949
+ capitalDeployed: number;
950
+ dealCount: number;
951
+ };
952
+ };
953
+ }, {
954
+ data: {
955
+ type: "investor-earnings";
956
+ id: string;
957
+ attributes: {
958
+ realizedEarnings: number;
959
+ projectedEarnings: number;
960
+ capitalDeployed: number;
961
+ dealCount: number;
962
+ currency?: string | undefined;
963
+ };
560
964
  };
561
965
  }>;
562
966
  401: z.ZodObject<{
@@ -774,13 +1178,42 @@ export declare const commodityDealsRouter: {
774
1178
  currency: z.ZodDefault<z.ZodString>;
775
1179
  status: z.ZodEnum<["draft", "in_transit", "invoiced", "paid", "cancelled"]>;
776
1180
  notes: z.ZodNullable<z.ZodString>;
1181
+ companyCommissionRate: z.ZodNullable<z.ZodNumber>;
1182
+ participants: z.ZodOptional<z.ZodArray<z.ZodObject<{
1183
+ userId: z.ZodString;
1184
+ name: z.ZodOptional<z.ZodString>;
1185
+ email: z.ZodOptional<z.ZodString>;
1186
+ capitalContributed: z.ZodNumber;
1187
+ ownershipPercent: z.ZodNumber;
1188
+ earningsAmount: z.ZodNullable<z.ZodNumber>;
1189
+ }, "strip", z.ZodTypeAny, {
1190
+ userId: string;
1191
+ capitalContributed: number;
1192
+ ownershipPercent: number;
1193
+ earningsAmount: number | null;
1194
+ email?: string | undefined;
1195
+ name?: string | undefined;
1196
+ }, {
1197
+ userId: string;
1198
+ capitalContributed: number;
1199
+ ownershipPercent: number;
1200
+ earningsAmount: number | null;
1201
+ email?: string | undefined;
1202
+ name?: string | undefined;
1203
+ }>, "many">>;
777
1204
  computed: z.ZodObject<{
778
1205
  totalCost: z.ZodNumber;
779
1206
  saleAmount: z.ZodNullable<z.ZodNumber>;
780
1207
  grossProfit: z.ZodNullable<z.ZodNumber>;
781
1208
  commissionRate: z.ZodNullable<z.ZodNumber>;
1209
+ staffCommissionRate: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
782
1210
  commissionAmount: z.ZodNullable<z.ZodNumber>;
1211
+ staffCommissionAmount: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
783
1212
  companyNet: z.ZodNullable<z.ZodNumber>;
1213
+ netAfterStaff: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
1214
+ companyCommissionRate: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
1215
+ companyCommissionAmount: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
1216
+ investorPool: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
784
1217
  isRealized: z.ZodBoolean;
785
1218
  }, "strip", z.ZodTypeAny, {
786
1219
  totalCost: number;
@@ -790,6 +1223,12 @@ export declare const commodityDealsRouter: {
790
1223
  commissionAmount: number | null;
791
1224
  companyNet: number | null;
792
1225
  isRealized: boolean;
1226
+ companyCommissionRate?: number | null | undefined;
1227
+ staffCommissionRate?: number | null | undefined;
1228
+ staffCommissionAmount?: number | null | undefined;
1229
+ netAfterStaff?: number | null | undefined;
1230
+ companyCommissionAmount?: number | null | undefined;
1231
+ investorPool?: number | null | undefined;
793
1232
  }, {
794
1233
  totalCost: number;
795
1234
  saleAmount: number | null;
@@ -798,6 +1237,12 @@ export declare const commodityDealsRouter: {
798
1237
  commissionAmount: number | null;
799
1238
  companyNet: number | null;
800
1239
  isRealized: boolean;
1240
+ companyCommissionRate?: number | null | undefined;
1241
+ staffCommissionRate?: number | null | undefined;
1242
+ staffCommissionAmount?: number | null | undefined;
1243
+ netAfterStaff?: number | null | undefined;
1244
+ companyCommissionAmount?: number | null | undefined;
1245
+ investorPool?: number | null | undefined;
801
1246
  }>;
802
1247
  } & {
803
1248
  createdAt: z.ZodString;
@@ -811,6 +1256,7 @@ export declare const commodityDealsRouter: {
811
1256
  buyerName: string | null;
812
1257
  transportCost: number;
813
1258
  organizationId: string;
1259
+ companyCommissionRate: number | null;
814
1260
  waybillNumber: string | null;
815
1261
  purchaseCost: number;
816
1262
  miscellaneousCost: number;
@@ -826,7 +1272,21 @@ export declare const commodityDealsRouter: {
826
1272
  commissionAmount: number | null;
827
1273
  companyNet: number | null;
828
1274
  isRealized: boolean;
1275
+ companyCommissionRate?: number | null | undefined;
1276
+ staffCommissionRate?: number | null | undefined;
1277
+ staffCommissionAmount?: number | null | undefined;
1278
+ netAfterStaff?: number | null | undefined;
1279
+ companyCommissionAmount?: number | null | undefined;
1280
+ investorPool?: number | null | undefined;
829
1281
  };
1282
+ participants?: {
1283
+ userId: string;
1284
+ capitalContributed: number;
1285
+ ownershipPercent: number;
1286
+ earningsAmount: number | null;
1287
+ email?: string | undefined;
1288
+ name?: string | undefined;
1289
+ }[] | undefined;
830
1290
  }, {
831
1291
  status: "cancelled" | "paid" | "draft" | "in_transit" | "invoiced";
832
1292
  createdAt: string;
@@ -835,6 +1295,7 @@ export declare const commodityDealsRouter: {
835
1295
  buyerName: string | null;
836
1296
  transportCost: number;
837
1297
  organizationId: string;
1298
+ companyCommissionRate: number | null;
838
1299
  waybillNumber: string | null;
839
1300
  purchaseCost: number;
840
1301
  miscellaneousCost: number;
@@ -850,8 +1311,22 @@ export declare const commodityDealsRouter: {
850
1311
  commissionAmount: number | null;
851
1312
  companyNet: number | null;
852
1313
  isRealized: boolean;
1314
+ companyCommissionRate?: number | null | undefined;
1315
+ staffCommissionRate?: number | null | undefined;
1316
+ staffCommissionAmount?: number | null | undefined;
1317
+ netAfterStaff?: number | null | undefined;
1318
+ companyCommissionAmount?: number | null | undefined;
1319
+ investorPool?: number | null | undefined;
853
1320
  };
854
1321
  currency?: string | undefined;
1322
+ participants?: {
1323
+ userId: string;
1324
+ capitalContributed: number;
1325
+ ownershipPercent: number;
1326
+ earningsAmount: number | null;
1327
+ email?: string | undefined;
1328
+ name?: string | undefined;
1329
+ }[] | undefined;
855
1330
  }>;
856
1331
  relationships: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
857
1332
  links: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
@@ -868,6 +1343,7 @@ export declare const commodityDealsRouter: {
868
1343
  buyerName: string | null;
869
1344
  transportCost: number;
870
1345
  organizationId: string;
1346
+ companyCommissionRate: number | null;
871
1347
  waybillNumber: string | null;
872
1348
  purchaseCost: number;
873
1349
  miscellaneousCost: number;
@@ -883,7 +1359,21 @@ export declare const commodityDealsRouter: {
883
1359
  commissionAmount: number | null;
884
1360
  companyNet: number | null;
885
1361
  isRealized: boolean;
1362
+ companyCommissionRate?: number | null | undefined;
1363
+ staffCommissionRate?: number | null | undefined;
1364
+ staffCommissionAmount?: number | null | undefined;
1365
+ netAfterStaff?: number | null | undefined;
1366
+ companyCommissionAmount?: number | null | undefined;
1367
+ investorPool?: number | null | undefined;
886
1368
  };
1369
+ participants?: {
1370
+ userId: string;
1371
+ capitalContributed: number;
1372
+ ownershipPercent: number;
1373
+ earningsAmount: number | null;
1374
+ email?: string | undefined;
1375
+ name?: string | undefined;
1376
+ }[] | undefined;
887
1377
  };
888
1378
  relationships?: Record<string, unknown> | undefined;
889
1379
  links?: Record<string, string> | undefined;
@@ -899,6 +1389,7 @@ export declare const commodityDealsRouter: {
899
1389
  buyerName: string | null;
900
1390
  transportCost: number;
901
1391
  organizationId: string;
1392
+ companyCommissionRate: number | null;
902
1393
  waybillNumber: string | null;
903
1394
  purchaseCost: number;
904
1395
  miscellaneousCost: number;
@@ -914,8 +1405,22 @@ export declare const commodityDealsRouter: {
914
1405
  commissionAmount: number | null;
915
1406
  companyNet: number | null;
916
1407
  isRealized: boolean;
1408
+ companyCommissionRate?: number | null | undefined;
1409
+ staffCommissionRate?: number | null | undefined;
1410
+ staffCommissionAmount?: number | null | undefined;
1411
+ netAfterStaff?: number | null | undefined;
1412
+ companyCommissionAmount?: number | null | undefined;
1413
+ investorPool?: number | null | undefined;
917
1414
  };
918
1415
  currency?: string | undefined;
1416
+ participants?: {
1417
+ userId: string;
1418
+ capitalContributed: number;
1419
+ ownershipPercent: number;
1420
+ earningsAmount: number | null;
1421
+ email?: string | undefined;
1422
+ name?: string | undefined;
1423
+ }[] | undefined;
919
1424
  };
920
1425
  relationships?: Record<string, unknown> | undefined;
921
1426
  links?: Record<string, string> | undefined;
@@ -958,6 +1463,7 @@ export declare const commodityDealsRouter: {
958
1463
  buyerName: string | null;
959
1464
  transportCost: number;
960
1465
  organizationId: string;
1466
+ companyCommissionRate: number | null;
961
1467
  waybillNumber: string | null;
962
1468
  purchaseCost: number;
963
1469
  miscellaneousCost: number;
@@ -973,7 +1479,21 @@ export declare const commodityDealsRouter: {
973
1479
  commissionAmount: number | null;
974
1480
  companyNet: number | null;
975
1481
  isRealized: boolean;
1482
+ companyCommissionRate?: number | null | undefined;
1483
+ staffCommissionRate?: number | null | undefined;
1484
+ staffCommissionAmount?: number | null | undefined;
1485
+ netAfterStaff?: number | null | undefined;
1486
+ companyCommissionAmount?: number | null | undefined;
1487
+ investorPool?: number | null | undefined;
976
1488
  };
1489
+ participants?: {
1490
+ userId: string;
1491
+ capitalContributed: number;
1492
+ ownershipPercent: number;
1493
+ earningsAmount: number | null;
1494
+ email?: string | undefined;
1495
+ name?: string | undefined;
1496
+ }[] | undefined;
977
1497
  };
978
1498
  relationships?: Record<string, unknown> | undefined;
979
1499
  links?: Record<string, string> | undefined;
@@ -1001,6 +1521,7 @@ export declare const commodityDealsRouter: {
1001
1521
  buyerName: string | null;
1002
1522
  transportCost: number;
1003
1523
  organizationId: string;
1524
+ companyCommissionRate: number | null;
1004
1525
  waybillNumber: string | null;
1005
1526
  purchaseCost: number;
1006
1527
  miscellaneousCost: number;
@@ -1016,8 +1537,22 @@ export declare const commodityDealsRouter: {
1016
1537
  commissionAmount: number | null;
1017
1538
  companyNet: number | null;
1018
1539
  isRealized: boolean;
1540
+ companyCommissionRate?: number | null | undefined;
1541
+ staffCommissionRate?: number | null | undefined;
1542
+ staffCommissionAmount?: number | null | undefined;
1543
+ netAfterStaff?: number | null | undefined;
1544
+ companyCommissionAmount?: number | null | undefined;
1545
+ investorPool?: number | null | undefined;
1019
1546
  };
1020
1547
  currency?: string | undefined;
1548
+ participants?: {
1549
+ userId: string;
1550
+ capitalContributed: number;
1551
+ ownershipPercent: number;
1552
+ earningsAmount: number | null;
1553
+ email?: string | undefined;
1554
+ name?: string | undefined;
1555
+ }[] | undefined;
1021
1556
  };
1022
1557
  relationships?: Record<string, unknown> | undefined;
1023
1558
  links?: Record<string, string> | undefined;
@@ -1238,6 +1773,7 @@ export declare const commodityDealsRouter: {
1238
1773
  status: z.ZodOptional<z.ZodEnum<["draft", "in_transit", "invoiced", "paid", "cancelled"]>>;
1239
1774
  notes: z.ZodOptional<z.ZodString>;
1240
1775
  handlerUserId: z.ZodOptional<z.ZodString>;
1776
+ companyCommissionRate: z.ZodOptional<z.ZodNumber>;
1241
1777
  }, "strip", z.ZodTypeAny, {
1242
1778
  currency: string;
1243
1779
  transportCost: number;
@@ -1246,6 +1782,7 @@ export declare const commodityDealsRouter: {
1246
1782
  waybillId: string;
1247
1783
  status?: "cancelled" | "paid" | "draft" | "in_transit" | "invoiced" | undefined;
1248
1784
  notes?: string | undefined;
1785
+ companyCommissionRate?: number | undefined;
1249
1786
  handlerUserId?: string | undefined;
1250
1787
  }, {
1251
1788
  purchaseCost: number;
@@ -1254,6 +1791,7 @@ export declare const commodityDealsRouter: {
1254
1791
  currency?: string | undefined;
1255
1792
  notes?: string | undefined;
1256
1793
  transportCost?: number | undefined;
1794
+ companyCommissionRate?: number | undefined;
1257
1795
  miscellaneousCost?: number | undefined;
1258
1796
  handlerUserId?: string | undefined;
1259
1797
  }>;
@@ -1267,6 +1805,7 @@ export declare const commodityDealsRouter: {
1267
1805
  waybillId: string;
1268
1806
  status?: "cancelled" | "paid" | "draft" | "in_transit" | "invoiced" | undefined;
1269
1807
  notes?: string | undefined;
1808
+ companyCommissionRate?: number | undefined;
1270
1809
  handlerUserId?: string | undefined;
1271
1810
  };
1272
1811
  }, {
@@ -1278,6 +1817,7 @@ export declare const commodityDealsRouter: {
1278
1817
  currency?: string | undefined;
1279
1818
  notes?: string | undefined;
1280
1819
  transportCost?: number | undefined;
1820
+ companyCommissionRate?: number | undefined;
1281
1821
  miscellaneousCost?: number | undefined;
1282
1822
  handlerUserId?: string | undefined;
1283
1823
  };
@@ -1293,6 +1833,7 @@ export declare const commodityDealsRouter: {
1293
1833
  waybillId: string;
1294
1834
  status?: "cancelled" | "paid" | "draft" | "in_transit" | "invoiced" | undefined;
1295
1835
  notes?: string | undefined;
1836
+ companyCommissionRate?: number | undefined;
1296
1837
  handlerUserId?: string | undefined;
1297
1838
  };
1298
1839
  };
@@ -1306,6 +1847,7 @@ export declare const commodityDealsRouter: {
1306
1847
  currency?: string | undefined;
1307
1848
  notes?: string | undefined;
1308
1849
  transportCost?: number | undefined;
1850
+ companyCommissionRate?: number | undefined;
1309
1851
  miscellaneousCost?: number | undefined;
1310
1852
  handlerUserId?: string | undefined;
1311
1853
  };
@@ -1331,13 +1873,42 @@ export declare const commodityDealsRouter: {
1331
1873
  currency: z.ZodDefault<z.ZodString>;
1332
1874
  status: z.ZodEnum<["draft", "in_transit", "invoiced", "paid", "cancelled"]>;
1333
1875
  notes: z.ZodNullable<z.ZodString>;
1876
+ companyCommissionRate: z.ZodNullable<z.ZodNumber>;
1877
+ participants: z.ZodOptional<z.ZodArray<z.ZodObject<{
1878
+ userId: z.ZodString;
1879
+ name: z.ZodOptional<z.ZodString>;
1880
+ email: z.ZodOptional<z.ZodString>;
1881
+ capitalContributed: z.ZodNumber;
1882
+ ownershipPercent: z.ZodNumber;
1883
+ earningsAmount: z.ZodNullable<z.ZodNumber>;
1884
+ }, "strip", z.ZodTypeAny, {
1885
+ userId: string;
1886
+ capitalContributed: number;
1887
+ ownershipPercent: number;
1888
+ earningsAmount: number | null;
1889
+ email?: string | undefined;
1890
+ name?: string | undefined;
1891
+ }, {
1892
+ userId: string;
1893
+ capitalContributed: number;
1894
+ ownershipPercent: number;
1895
+ earningsAmount: number | null;
1896
+ email?: string | undefined;
1897
+ name?: string | undefined;
1898
+ }>, "many">>;
1334
1899
  computed: z.ZodObject<{
1335
1900
  totalCost: z.ZodNumber;
1336
1901
  saleAmount: z.ZodNullable<z.ZodNumber>;
1337
1902
  grossProfit: z.ZodNullable<z.ZodNumber>;
1338
1903
  commissionRate: z.ZodNullable<z.ZodNumber>;
1904
+ staffCommissionRate: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
1339
1905
  commissionAmount: z.ZodNullable<z.ZodNumber>;
1906
+ staffCommissionAmount: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
1340
1907
  companyNet: z.ZodNullable<z.ZodNumber>;
1908
+ netAfterStaff: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
1909
+ companyCommissionRate: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
1910
+ companyCommissionAmount: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
1911
+ investorPool: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
1341
1912
  isRealized: z.ZodBoolean;
1342
1913
  }, "strip", z.ZodTypeAny, {
1343
1914
  totalCost: number;
@@ -1347,6 +1918,12 @@ export declare const commodityDealsRouter: {
1347
1918
  commissionAmount: number | null;
1348
1919
  companyNet: number | null;
1349
1920
  isRealized: boolean;
1921
+ companyCommissionRate?: number | null | undefined;
1922
+ staffCommissionRate?: number | null | undefined;
1923
+ staffCommissionAmount?: number | null | undefined;
1924
+ netAfterStaff?: number | null | undefined;
1925
+ companyCommissionAmount?: number | null | undefined;
1926
+ investorPool?: number | null | undefined;
1350
1927
  }, {
1351
1928
  totalCost: number;
1352
1929
  saleAmount: number | null;
@@ -1355,6 +1932,12 @@ export declare const commodityDealsRouter: {
1355
1932
  commissionAmount: number | null;
1356
1933
  companyNet: number | null;
1357
1934
  isRealized: boolean;
1935
+ companyCommissionRate?: number | null | undefined;
1936
+ staffCommissionRate?: number | null | undefined;
1937
+ staffCommissionAmount?: number | null | undefined;
1938
+ netAfterStaff?: number | null | undefined;
1939
+ companyCommissionAmount?: number | null | undefined;
1940
+ investorPool?: number | null | undefined;
1358
1941
  }>;
1359
1942
  } & {
1360
1943
  createdAt: z.ZodString;
@@ -1368,6 +1951,7 @@ export declare const commodityDealsRouter: {
1368
1951
  buyerName: string | null;
1369
1952
  transportCost: number;
1370
1953
  organizationId: string;
1954
+ companyCommissionRate: number | null;
1371
1955
  waybillNumber: string | null;
1372
1956
  purchaseCost: number;
1373
1957
  miscellaneousCost: number;
@@ -1383,7 +1967,21 @@ export declare const commodityDealsRouter: {
1383
1967
  commissionAmount: number | null;
1384
1968
  companyNet: number | null;
1385
1969
  isRealized: boolean;
1970
+ companyCommissionRate?: number | null | undefined;
1971
+ staffCommissionRate?: number | null | undefined;
1972
+ staffCommissionAmount?: number | null | undefined;
1973
+ netAfterStaff?: number | null | undefined;
1974
+ companyCommissionAmount?: number | null | undefined;
1975
+ investorPool?: number | null | undefined;
1386
1976
  };
1977
+ participants?: {
1978
+ userId: string;
1979
+ capitalContributed: number;
1980
+ ownershipPercent: number;
1981
+ earningsAmount: number | null;
1982
+ email?: string | undefined;
1983
+ name?: string | undefined;
1984
+ }[] | undefined;
1387
1985
  }, {
1388
1986
  status: "cancelled" | "paid" | "draft" | "in_transit" | "invoiced";
1389
1987
  createdAt: string;
@@ -1392,6 +1990,7 @@ export declare const commodityDealsRouter: {
1392
1990
  buyerName: string | null;
1393
1991
  transportCost: number;
1394
1992
  organizationId: string;
1993
+ companyCommissionRate: number | null;
1395
1994
  waybillNumber: string | null;
1396
1995
  purchaseCost: number;
1397
1996
  miscellaneousCost: number;
@@ -1407,8 +2006,22 @@ export declare const commodityDealsRouter: {
1407
2006
  commissionAmount: number | null;
1408
2007
  companyNet: number | null;
1409
2008
  isRealized: boolean;
2009
+ companyCommissionRate?: number | null | undefined;
2010
+ staffCommissionRate?: number | null | undefined;
2011
+ staffCommissionAmount?: number | null | undefined;
2012
+ netAfterStaff?: number | null | undefined;
2013
+ companyCommissionAmount?: number | null | undefined;
2014
+ investorPool?: number | null | undefined;
1410
2015
  };
1411
2016
  currency?: string | undefined;
2017
+ participants?: {
2018
+ userId: string;
2019
+ capitalContributed: number;
2020
+ ownershipPercent: number;
2021
+ earningsAmount: number | null;
2022
+ email?: string | undefined;
2023
+ name?: string | undefined;
2024
+ }[] | undefined;
1412
2025
  }>;
1413
2026
  relationships: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1414
2027
  links: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
@@ -1425,6 +2038,7 @@ export declare const commodityDealsRouter: {
1425
2038
  buyerName: string | null;
1426
2039
  transportCost: number;
1427
2040
  organizationId: string;
2041
+ companyCommissionRate: number | null;
1428
2042
  waybillNumber: string | null;
1429
2043
  purchaseCost: number;
1430
2044
  miscellaneousCost: number;
@@ -1440,7 +2054,21 @@ export declare const commodityDealsRouter: {
1440
2054
  commissionAmount: number | null;
1441
2055
  companyNet: number | null;
1442
2056
  isRealized: boolean;
2057
+ companyCommissionRate?: number | null | undefined;
2058
+ staffCommissionRate?: number | null | undefined;
2059
+ staffCommissionAmount?: number | null | undefined;
2060
+ netAfterStaff?: number | null | undefined;
2061
+ companyCommissionAmount?: number | null | undefined;
2062
+ investorPool?: number | null | undefined;
1443
2063
  };
2064
+ participants?: {
2065
+ userId: string;
2066
+ capitalContributed: number;
2067
+ ownershipPercent: number;
2068
+ earningsAmount: number | null;
2069
+ email?: string | undefined;
2070
+ name?: string | undefined;
2071
+ }[] | undefined;
1444
2072
  };
1445
2073
  relationships?: Record<string, unknown> | undefined;
1446
2074
  links?: Record<string, string> | undefined;
@@ -1456,6 +2084,7 @@ export declare const commodityDealsRouter: {
1456
2084
  buyerName: string | null;
1457
2085
  transportCost: number;
1458
2086
  organizationId: string;
2087
+ companyCommissionRate: number | null;
1459
2088
  waybillNumber: string | null;
1460
2089
  purchaseCost: number;
1461
2090
  miscellaneousCost: number;
@@ -1471,8 +2100,22 @@ export declare const commodityDealsRouter: {
1471
2100
  commissionAmount: number | null;
1472
2101
  companyNet: number | null;
1473
2102
  isRealized: boolean;
2103
+ companyCommissionRate?: number | null | undefined;
2104
+ staffCommissionRate?: number | null | undefined;
2105
+ staffCommissionAmount?: number | null | undefined;
2106
+ netAfterStaff?: number | null | undefined;
2107
+ companyCommissionAmount?: number | null | undefined;
2108
+ investorPool?: number | null | undefined;
1474
2109
  };
1475
2110
  currency?: string | undefined;
2111
+ participants?: {
2112
+ userId: string;
2113
+ capitalContributed: number;
2114
+ ownershipPercent: number;
2115
+ earningsAmount: number | null;
2116
+ email?: string | undefined;
2117
+ name?: string | undefined;
2118
+ }[] | undefined;
1476
2119
  };
1477
2120
  relationships?: Record<string, unknown> | undefined;
1478
2121
  links?: Record<string, string> | undefined;
@@ -1515,6 +2158,7 @@ export declare const commodityDealsRouter: {
1515
2158
  buyerName: string | null;
1516
2159
  transportCost: number;
1517
2160
  organizationId: string;
2161
+ companyCommissionRate: number | null;
1518
2162
  waybillNumber: string | null;
1519
2163
  purchaseCost: number;
1520
2164
  miscellaneousCost: number;
@@ -1530,7 +2174,21 @@ export declare const commodityDealsRouter: {
1530
2174
  commissionAmount: number | null;
1531
2175
  companyNet: number | null;
1532
2176
  isRealized: boolean;
2177
+ companyCommissionRate?: number | null | undefined;
2178
+ staffCommissionRate?: number | null | undefined;
2179
+ staffCommissionAmount?: number | null | undefined;
2180
+ netAfterStaff?: number | null | undefined;
2181
+ companyCommissionAmount?: number | null | undefined;
2182
+ investorPool?: number | null | undefined;
1533
2183
  };
2184
+ participants?: {
2185
+ userId: string;
2186
+ capitalContributed: number;
2187
+ ownershipPercent: number;
2188
+ earningsAmount: number | null;
2189
+ email?: string | undefined;
2190
+ name?: string | undefined;
2191
+ }[] | undefined;
1534
2192
  };
1535
2193
  relationships?: Record<string, unknown> | undefined;
1536
2194
  links?: Record<string, string> | undefined;
@@ -1558,6 +2216,7 @@ export declare const commodityDealsRouter: {
1558
2216
  buyerName: string | null;
1559
2217
  transportCost: number;
1560
2218
  organizationId: string;
2219
+ companyCommissionRate: number | null;
1561
2220
  waybillNumber: string | null;
1562
2221
  purchaseCost: number;
1563
2222
  miscellaneousCost: number;
@@ -1573,8 +2232,22 @@ export declare const commodityDealsRouter: {
1573
2232
  commissionAmount: number | null;
1574
2233
  companyNet: number | null;
1575
2234
  isRealized: boolean;
2235
+ companyCommissionRate?: number | null | undefined;
2236
+ staffCommissionRate?: number | null | undefined;
2237
+ staffCommissionAmount?: number | null | undefined;
2238
+ netAfterStaff?: number | null | undefined;
2239
+ companyCommissionAmount?: number | null | undefined;
2240
+ investorPool?: number | null | undefined;
1576
2241
  };
1577
2242
  currency?: string | undefined;
2243
+ participants?: {
2244
+ userId: string;
2245
+ capitalContributed: number;
2246
+ ownershipPercent: number;
2247
+ earningsAmount: number | null;
2248
+ email?: string | undefined;
2249
+ name?: string | undefined;
2250
+ }[] | undefined;
1578
2251
  };
1579
2252
  relationships?: Record<string, unknown> | undefined;
1580
2253
  links?: Record<string, string> | undefined;
@@ -1771,7 +2444,7 @@ export declare const commodityDealsRouter: {
1771
2444
  }[];
1772
2445
  meta?: Record<string, unknown> | undefined;
1773
2446
  }>;
1774
- 404: z.ZodObject<{
2447
+ 403: z.ZodObject<{
1775
2448
  errors: z.ZodArray<z.ZodObject<{
1776
2449
  id: z.ZodOptional<z.ZodString>;
1777
2450
  links: z.ZodOptional<z.ZodObject<{
@@ -1861,7 +2534,7 @@ export declare const commodityDealsRouter: {
1861
2534
  }[];
1862
2535
  meta?: Record<string, unknown> | undefined;
1863
2536
  }>;
1864
- 422: z.ZodObject<{
2537
+ 404: z.ZodObject<{
1865
2538
  errors: z.ZodArray<z.ZodObject<{
1866
2539
  id: z.ZodOptional<z.ZodString>;
1867
2540
  links: z.ZodOptional<z.ZodObject<{
@@ -1951,26 +2624,116 @@ export declare const commodityDealsRouter: {
1951
2624
  }[];
1952
2625
  meta?: Record<string, unknown> | undefined;
1953
2626
  }>;
1954
- };
1955
- };
1956
- updateCommodityDeal: {
1957
- pathParams: z.ZodObject<{
1958
- organizationId: z.ZodString;
1959
- id: z.ZodString;
1960
- }, "strip", z.ZodTypeAny, {
1961
- id: string;
1962
- organizationId: string;
1963
- }, {
1964
- id: string;
1965
- organizationId: string;
1966
- }>;
1967
- summary: "Update commodity deal costs or status";
1968
- method: "PATCH";
1969
- body: z.ZodObject<{
1970
- data: z.ZodObject<{
1971
- type: z.ZodLiteral<"commodity-deals">;
1972
- id: z.ZodOptional<z.ZodString>;
1973
- attributes: z.ZodObject<{
2627
+ 422: z.ZodObject<{
2628
+ errors: z.ZodArray<z.ZodObject<{
2629
+ id: z.ZodOptional<z.ZodString>;
2630
+ links: z.ZodOptional<z.ZodObject<{
2631
+ about: z.ZodOptional<z.ZodString>;
2632
+ }, "strip", z.ZodTypeAny, {
2633
+ about?: string | undefined;
2634
+ }, {
2635
+ about?: string | undefined;
2636
+ }>>;
2637
+ status: z.ZodOptional<z.ZodString>;
2638
+ code: z.ZodOptional<z.ZodString>;
2639
+ title: z.ZodOptional<z.ZodString>;
2640
+ detail: z.ZodOptional<z.ZodString>;
2641
+ source: z.ZodOptional<z.ZodObject<{
2642
+ pointer: z.ZodOptional<z.ZodString>;
2643
+ parameter: z.ZodOptional<z.ZodString>;
2644
+ }, "strip", z.ZodTypeAny, {
2645
+ pointer?: string | undefined;
2646
+ parameter?: string | undefined;
2647
+ }, {
2648
+ pointer?: string | undefined;
2649
+ parameter?: string | undefined;
2650
+ }>>;
2651
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
2652
+ }, "strip", z.ZodTypeAny, {
2653
+ status?: string | undefined;
2654
+ code?: string | undefined;
2655
+ id?: string | undefined;
2656
+ links?: {
2657
+ about?: string | undefined;
2658
+ } | undefined;
2659
+ meta?: Record<string, unknown> | undefined;
2660
+ title?: string | undefined;
2661
+ detail?: string | undefined;
2662
+ source?: {
2663
+ pointer?: string | undefined;
2664
+ parameter?: string | undefined;
2665
+ } | undefined;
2666
+ }, {
2667
+ status?: string | undefined;
2668
+ code?: string | undefined;
2669
+ id?: string | undefined;
2670
+ links?: {
2671
+ about?: string | undefined;
2672
+ } | undefined;
2673
+ meta?: Record<string, unknown> | undefined;
2674
+ title?: string | undefined;
2675
+ detail?: string | undefined;
2676
+ source?: {
2677
+ pointer?: string | undefined;
2678
+ parameter?: string | undefined;
2679
+ } | undefined;
2680
+ }>, "many">;
2681
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
2682
+ }, "strip", z.ZodTypeAny, {
2683
+ errors: {
2684
+ status?: string | undefined;
2685
+ code?: string | undefined;
2686
+ id?: string | undefined;
2687
+ links?: {
2688
+ about?: string | undefined;
2689
+ } | undefined;
2690
+ meta?: Record<string, unknown> | undefined;
2691
+ title?: string | undefined;
2692
+ detail?: string | undefined;
2693
+ source?: {
2694
+ pointer?: string | undefined;
2695
+ parameter?: string | undefined;
2696
+ } | undefined;
2697
+ }[];
2698
+ meta?: Record<string, unknown> | undefined;
2699
+ }, {
2700
+ errors: {
2701
+ status?: string | undefined;
2702
+ code?: string | undefined;
2703
+ id?: string | undefined;
2704
+ links?: {
2705
+ about?: string | undefined;
2706
+ } | undefined;
2707
+ meta?: Record<string, unknown> | undefined;
2708
+ title?: string | undefined;
2709
+ detail?: string | undefined;
2710
+ source?: {
2711
+ pointer?: string | undefined;
2712
+ parameter?: string | undefined;
2713
+ } | undefined;
2714
+ }[];
2715
+ meta?: Record<string, unknown> | undefined;
2716
+ }>;
2717
+ };
2718
+ };
2719
+ updateCommodityDeal: {
2720
+ pathParams: z.ZodObject<{
2721
+ organizationId: z.ZodString;
2722
+ id: z.ZodString;
2723
+ }, "strip", z.ZodTypeAny, {
2724
+ id: string;
2725
+ organizationId: string;
2726
+ }, {
2727
+ id: string;
2728
+ organizationId: string;
2729
+ }>;
2730
+ summary: "Update commodity deal costs or status";
2731
+ method: "PATCH";
2732
+ body: z.ZodObject<{
2733
+ data: z.ZodObject<{
2734
+ type: z.ZodLiteral<"commodity-deals">;
2735
+ id: z.ZodOptional<z.ZodString>;
2736
+ attributes: z.ZodObject<{
1974
2737
  purchaseCost: z.ZodOptional<z.ZodNumber>;
1975
2738
  transportCost: z.ZodOptional<z.ZodNumber>;
1976
2739
  miscellaneousCost: z.ZodOptional<z.ZodNumber>;
@@ -1979,11 +2742,13 @@ export declare const commodityDealsRouter: {
1979
2742
  notes: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1980
2743
  invoiceId: z.ZodOptional<z.ZodString>;
1981
2744
  handlerUserId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
2745
+ companyCommissionRate: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
1982
2746
  }, "strip", z.ZodTypeAny, {
1983
2747
  status?: "cancelled" | "paid" | "draft" | "in_transit" | "invoiced" | undefined;
1984
2748
  currency?: string | undefined;
1985
2749
  notes?: string | null | undefined;
1986
2750
  transportCost?: number | undefined;
2751
+ companyCommissionRate?: number | null | undefined;
1987
2752
  purchaseCost?: number | undefined;
1988
2753
  miscellaneousCost?: number | undefined;
1989
2754
  invoiceId?: string | undefined;
@@ -1993,6 +2758,7 @@ export declare const commodityDealsRouter: {
1993
2758
  currency?: string | undefined;
1994
2759
  notes?: string | null | undefined;
1995
2760
  transportCost?: number | undefined;
2761
+ companyCommissionRate?: number | null | undefined;
1996
2762
  purchaseCost?: number | undefined;
1997
2763
  miscellaneousCost?: number | undefined;
1998
2764
  invoiceId?: string | undefined;
@@ -2005,6 +2771,7 @@ export declare const commodityDealsRouter: {
2005
2771
  currency?: string | undefined;
2006
2772
  notes?: string | null | undefined;
2007
2773
  transportCost?: number | undefined;
2774
+ companyCommissionRate?: number | null | undefined;
2008
2775
  purchaseCost?: number | undefined;
2009
2776
  miscellaneousCost?: number | undefined;
2010
2777
  invoiceId?: string | undefined;
@@ -2018,6 +2785,7 @@ export declare const commodityDealsRouter: {
2018
2785
  currency?: string | undefined;
2019
2786
  notes?: string | null | undefined;
2020
2787
  transportCost?: number | undefined;
2788
+ companyCommissionRate?: number | null | undefined;
2021
2789
  purchaseCost?: number | undefined;
2022
2790
  miscellaneousCost?: number | undefined;
2023
2791
  invoiceId?: string | undefined;
@@ -2033,6 +2801,7 @@ export declare const commodityDealsRouter: {
2033
2801
  currency?: string | undefined;
2034
2802
  notes?: string | null | undefined;
2035
2803
  transportCost?: number | undefined;
2804
+ companyCommissionRate?: number | null | undefined;
2036
2805
  purchaseCost?: number | undefined;
2037
2806
  miscellaneousCost?: number | undefined;
2038
2807
  invoiceId?: string | undefined;
@@ -2048,6 +2817,7 @@ export declare const commodityDealsRouter: {
2048
2817
  currency?: string | undefined;
2049
2818
  notes?: string | null | undefined;
2050
2819
  transportCost?: number | undefined;
2820
+ companyCommissionRate?: number | null | undefined;
2051
2821
  purchaseCost?: number | undefined;
2052
2822
  miscellaneousCost?: number | undefined;
2053
2823
  invoiceId?: string | undefined;
@@ -2076,13 +2846,42 @@ export declare const commodityDealsRouter: {
2076
2846
  currency: z.ZodDefault<z.ZodString>;
2077
2847
  status: z.ZodEnum<["draft", "in_transit", "invoiced", "paid", "cancelled"]>;
2078
2848
  notes: z.ZodNullable<z.ZodString>;
2849
+ companyCommissionRate: z.ZodNullable<z.ZodNumber>;
2850
+ participants: z.ZodOptional<z.ZodArray<z.ZodObject<{
2851
+ userId: z.ZodString;
2852
+ name: z.ZodOptional<z.ZodString>;
2853
+ email: z.ZodOptional<z.ZodString>;
2854
+ capitalContributed: z.ZodNumber;
2855
+ ownershipPercent: z.ZodNumber;
2856
+ earningsAmount: z.ZodNullable<z.ZodNumber>;
2857
+ }, "strip", z.ZodTypeAny, {
2858
+ userId: string;
2859
+ capitalContributed: number;
2860
+ ownershipPercent: number;
2861
+ earningsAmount: number | null;
2862
+ email?: string | undefined;
2863
+ name?: string | undefined;
2864
+ }, {
2865
+ userId: string;
2866
+ capitalContributed: number;
2867
+ ownershipPercent: number;
2868
+ earningsAmount: number | null;
2869
+ email?: string | undefined;
2870
+ name?: string | undefined;
2871
+ }>, "many">>;
2079
2872
  computed: z.ZodObject<{
2080
2873
  totalCost: z.ZodNumber;
2081
2874
  saleAmount: z.ZodNullable<z.ZodNumber>;
2082
2875
  grossProfit: z.ZodNullable<z.ZodNumber>;
2083
2876
  commissionRate: z.ZodNullable<z.ZodNumber>;
2877
+ staffCommissionRate: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
2084
2878
  commissionAmount: z.ZodNullable<z.ZodNumber>;
2879
+ staffCommissionAmount: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
2085
2880
  companyNet: z.ZodNullable<z.ZodNumber>;
2881
+ netAfterStaff: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
2882
+ companyCommissionRate: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
2883
+ companyCommissionAmount: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
2884
+ investorPool: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
2086
2885
  isRealized: z.ZodBoolean;
2087
2886
  }, "strip", z.ZodTypeAny, {
2088
2887
  totalCost: number;
@@ -2092,6 +2891,12 @@ export declare const commodityDealsRouter: {
2092
2891
  commissionAmount: number | null;
2093
2892
  companyNet: number | null;
2094
2893
  isRealized: boolean;
2894
+ companyCommissionRate?: number | null | undefined;
2895
+ staffCommissionRate?: number | null | undefined;
2896
+ staffCommissionAmount?: number | null | undefined;
2897
+ netAfterStaff?: number | null | undefined;
2898
+ companyCommissionAmount?: number | null | undefined;
2899
+ investorPool?: number | null | undefined;
2095
2900
  }, {
2096
2901
  totalCost: number;
2097
2902
  saleAmount: number | null;
@@ -2100,6 +2905,12 @@ export declare const commodityDealsRouter: {
2100
2905
  commissionAmount: number | null;
2101
2906
  companyNet: number | null;
2102
2907
  isRealized: boolean;
2908
+ companyCommissionRate?: number | null | undefined;
2909
+ staffCommissionRate?: number | null | undefined;
2910
+ staffCommissionAmount?: number | null | undefined;
2911
+ netAfterStaff?: number | null | undefined;
2912
+ companyCommissionAmount?: number | null | undefined;
2913
+ investorPool?: number | null | undefined;
2103
2914
  }>;
2104
2915
  } & {
2105
2916
  createdAt: z.ZodString;
@@ -2113,6 +2924,7 @@ export declare const commodityDealsRouter: {
2113
2924
  buyerName: string | null;
2114
2925
  transportCost: number;
2115
2926
  organizationId: string;
2927
+ companyCommissionRate: number | null;
2116
2928
  waybillNumber: string | null;
2117
2929
  purchaseCost: number;
2118
2930
  miscellaneousCost: number;
@@ -2128,7 +2940,21 @@ export declare const commodityDealsRouter: {
2128
2940
  commissionAmount: number | null;
2129
2941
  companyNet: number | null;
2130
2942
  isRealized: boolean;
2943
+ companyCommissionRate?: number | null | undefined;
2944
+ staffCommissionRate?: number | null | undefined;
2945
+ staffCommissionAmount?: number | null | undefined;
2946
+ netAfterStaff?: number | null | undefined;
2947
+ companyCommissionAmount?: number | null | undefined;
2948
+ investorPool?: number | null | undefined;
2131
2949
  };
2950
+ participants?: {
2951
+ userId: string;
2952
+ capitalContributed: number;
2953
+ ownershipPercent: number;
2954
+ earningsAmount: number | null;
2955
+ email?: string | undefined;
2956
+ name?: string | undefined;
2957
+ }[] | undefined;
2132
2958
  }, {
2133
2959
  status: "cancelled" | "paid" | "draft" | "in_transit" | "invoiced";
2134
2960
  createdAt: string;
@@ -2137,6 +2963,7 @@ export declare const commodityDealsRouter: {
2137
2963
  buyerName: string | null;
2138
2964
  transportCost: number;
2139
2965
  organizationId: string;
2966
+ companyCommissionRate: number | null;
2140
2967
  waybillNumber: string | null;
2141
2968
  purchaseCost: number;
2142
2969
  miscellaneousCost: number;
@@ -2152,8 +2979,22 @@ export declare const commodityDealsRouter: {
2152
2979
  commissionAmount: number | null;
2153
2980
  companyNet: number | null;
2154
2981
  isRealized: boolean;
2982
+ companyCommissionRate?: number | null | undefined;
2983
+ staffCommissionRate?: number | null | undefined;
2984
+ staffCommissionAmount?: number | null | undefined;
2985
+ netAfterStaff?: number | null | undefined;
2986
+ companyCommissionAmount?: number | null | undefined;
2987
+ investorPool?: number | null | undefined;
2155
2988
  };
2156
2989
  currency?: string | undefined;
2990
+ participants?: {
2991
+ userId: string;
2992
+ capitalContributed: number;
2993
+ ownershipPercent: number;
2994
+ earningsAmount: number | null;
2995
+ email?: string | undefined;
2996
+ name?: string | undefined;
2997
+ }[] | undefined;
2157
2998
  }>;
2158
2999
  relationships: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
2159
3000
  links: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
@@ -2170,6 +3011,7 @@ export declare const commodityDealsRouter: {
2170
3011
  buyerName: string | null;
2171
3012
  transportCost: number;
2172
3013
  organizationId: string;
3014
+ companyCommissionRate: number | null;
2173
3015
  waybillNumber: string | null;
2174
3016
  purchaseCost: number;
2175
3017
  miscellaneousCost: number;
@@ -2185,7 +3027,21 @@ export declare const commodityDealsRouter: {
2185
3027
  commissionAmount: number | null;
2186
3028
  companyNet: number | null;
2187
3029
  isRealized: boolean;
3030
+ companyCommissionRate?: number | null | undefined;
3031
+ staffCommissionRate?: number | null | undefined;
3032
+ staffCommissionAmount?: number | null | undefined;
3033
+ netAfterStaff?: number | null | undefined;
3034
+ companyCommissionAmount?: number | null | undefined;
3035
+ investorPool?: number | null | undefined;
2188
3036
  };
3037
+ participants?: {
3038
+ userId: string;
3039
+ capitalContributed: number;
3040
+ ownershipPercent: number;
3041
+ earningsAmount: number | null;
3042
+ email?: string | undefined;
3043
+ name?: string | undefined;
3044
+ }[] | undefined;
2189
3045
  };
2190
3046
  relationships?: Record<string, unknown> | undefined;
2191
3047
  links?: Record<string, string> | undefined;
@@ -2201,6 +3057,7 @@ export declare const commodityDealsRouter: {
2201
3057
  buyerName: string | null;
2202
3058
  transportCost: number;
2203
3059
  organizationId: string;
3060
+ companyCommissionRate: number | null;
2204
3061
  waybillNumber: string | null;
2205
3062
  purchaseCost: number;
2206
3063
  miscellaneousCost: number;
@@ -2216,8 +3073,22 @@ export declare const commodityDealsRouter: {
2216
3073
  commissionAmount: number | null;
2217
3074
  companyNet: number | null;
2218
3075
  isRealized: boolean;
3076
+ companyCommissionRate?: number | null | undefined;
3077
+ staffCommissionRate?: number | null | undefined;
3078
+ staffCommissionAmount?: number | null | undefined;
3079
+ netAfterStaff?: number | null | undefined;
3080
+ companyCommissionAmount?: number | null | undefined;
3081
+ investorPool?: number | null | undefined;
2219
3082
  };
2220
3083
  currency?: string | undefined;
3084
+ participants?: {
3085
+ userId: string;
3086
+ capitalContributed: number;
3087
+ ownershipPercent: number;
3088
+ earningsAmount: number | null;
3089
+ email?: string | undefined;
3090
+ name?: string | undefined;
3091
+ }[] | undefined;
2221
3092
  };
2222
3093
  relationships?: Record<string, unknown> | undefined;
2223
3094
  links?: Record<string, string> | undefined;
@@ -2260,6 +3131,7 @@ export declare const commodityDealsRouter: {
2260
3131
  buyerName: string | null;
2261
3132
  transportCost: number;
2262
3133
  organizationId: string;
3134
+ companyCommissionRate: number | null;
2263
3135
  waybillNumber: string | null;
2264
3136
  purchaseCost: number;
2265
3137
  miscellaneousCost: number;
@@ -2275,7 +3147,21 @@ export declare const commodityDealsRouter: {
2275
3147
  commissionAmount: number | null;
2276
3148
  companyNet: number | null;
2277
3149
  isRealized: boolean;
3150
+ companyCommissionRate?: number | null | undefined;
3151
+ staffCommissionRate?: number | null | undefined;
3152
+ staffCommissionAmount?: number | null | undefined;
3153
+ netAfterStaff?: number | null | undefined;
3154
+ companyCommissionAmount?: number | null | undefined;
3155
+ investorPool?: number | null | undefined;
2278
3156
  };
3157
+ participants?: {
3158
+ userId: string;
3159
+ capitalContributed: number;
3160
+ ownershipPercent: number;
3161
+ earningsAmount: number | null;
3162
+ email?: string | undefined;
3163
+ name?: string | undefined;
3164
+ }[] | undefined;
2279
3165
  };
2280
3166
  relationships?: Record<string, unknown> | undefined;
2281
3167
  links?: Record<string, string> | undefined;
@@ -2303,6 +3189,7 @@ export declare const commodityDealsRouter: {
2303
3189
  buyerName: string | null;
2304
3190
  transportCost: number;
2305
3191
  organizationId: string;
3192
+ companyCommissionRate: number | null;
2306
3193
  waybillNumber: string | null;
2307
3194
  purchaseCost: number;
2308
3195
  miscellaneousCost: number;
@@ -2318,8 +3205,22 @@ export declare const commodityDealsRouter: {
2318
3205
  commissionAmount: number | null;
2319
3206
  companyNet: number | null;
2320
3207
  isRealized: boolean;
3208
+ companyCommissionRate?: number | null | undefined;
3209
+ staffCommissionRate?: number | null | undefined;
3210
+ staffCommissionAmount?: number | null | undefined;
3211
+ netAfterStaff?: number | null | undefined;
3212
+ companyCommissionAmount?: number | null | undefined;
3213
+ investorPool?: number | null | undefined;
2321
3214
  };
2322
3215
  currency?: string | undefined;
3216
+ participants?: {
3217
+ userId: string;
3218
+ capitalContributed: number;
3219
+ ownershipPercent: number;
3220
+ earningsAmount: number | null;
3221
+ email?: string | undefined;
3222
+ name?: string | undefined;
3223
+ }[] | undefined;
2323
3224
  };
2324
3225
  relationships?: Record<string, unknown> | undefined;
2325
3226
  links?: Record<string, string> | undefined;
@@ -2426,6 +3327,96 @@ export declare const commodityDealsRouter: {
2426
3327
  }[];
2427
3328
  meta?: Record<string, unknown> | undefined;
2428
3329
  }>;
3330
+ 403: z.ZodObject<{
3331
+ errors: z.ZodArray<z.ZodObject<{
3332
+ id: z.ZodOptional<z.ZodString>;
3333
+ links: z.ZodOptional<z.ZodObject<{
3334
+ about: z.ZodOptional<z.ZodString>;
3335
+ }, "strip", z.ZodTypeAny, {
3336
+ about?: string | undefined;
3337
+ }, {
3338
+ about?: string | undefined;
3339
+ }>>;
3340
+ status: z.ZodOptional<z.ZodString>;
3341
+ code: z.ZodOptional<z.ZodString>;
3342
+ title: z.ZodOptional<z.ZodString>;
3343
+ detail: z.ZodOptional<z.ZodString>;
3344
+ source: z.ZodOptional<z.ZodObject<{
3345
+ pointer: z.ZodOptional<z.ZodString>;
3346
+ parameter: z.ZodOptional<z.ZodString>;
3347
+ }, "strip", z.ZodTypeAny, {
3348
+ pointer?: string | undefined;
3349
+ parameter?: string | undefined;
3350
+ }, {
3351
+ pointer?: string | undefined;
3352
+ parameter?: string | undefined;
3353
+ }>>;
3354
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
3355
+ }, "strip", z.ZodTypeAny, {
3356
+ status?: string | undefined;
3357
+ code?: string | undefined;
3358
+ id?: string | undefined;
3359
+ links?: {
3360
+ about?: string | undefined;
3361
+ } | undefined;
3362
+ meta?: Record<string, unknown> | undefined;
3363
+ title?: string | undefined;
3364
+ detail?: string | undefined;
3365
+ source?: {
3366
+ pointer?: string | undefined;
3367
+ parameter?: string | undefined;
3368
+ } | undefined;
3369
+ }, {
3370
+ status?: string | undefined;
3371
+ code?: string | undefined;
3372
+ id?: string | undefined;
3373
+ links?: {
3374
+ about?: string | undefined;
3375
+ } | undefined;
3376
+ meta?: Record<string, unknown> | undefined;
3377
+ title?: string | undefined;
3378
+ detail?: string | undefined;
3379
+ source?: {
3380
+ pointer?: string | undefined;
3381
+ parameter?: string | undefined;
3382
+ } | undefined;
3383
+ }>, "many">;
3384
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
3385
+ }, "strip", z.ZodTypeAny, {
3386
+ errors: {
3387
+ status?: string | undefined;
3388
+ code?: string | undefined;
3389
+ id?: string | undefined;
3390
+ links?: {
3391
+ about?: string | undefined;
3392
+ } | undefined;
3393
+ meta?: Record<string, unknown> | undefined;
3394
+ title?: string | undefined;
3395
+ detail?: string | undefined;
3396
+ source?: {
3397
+ pointer?: string | undefined;
3398
+ parameter?: string | undefined;
3399
+ } | undefined;
3400
+ }[];
3401
+ meta?: Record<string, unknown> | undefined;
3402
+ }, {
3403
+ errors: {
3404
+ status?: string | undefined;
3405
+ code?: string | undefined;
3406
+ id?: string | undefined;
3407
+ links?: {
3408
+ about?: string | undefined;
3409
+ } | undefined;
3410
+ meta?: Record<string, unknown> | undefined;
3411
+ title?: string | undefined;
3412
+ detail?: string | undefined;
3413
+ source?: {
3414
+ pointer?: string | undefined;
3415
+ parameter?: string | undefined;
3416
+ } | undefined;
3417
+ }[];
3418
+ meta?: Record<string, unknown> | undefined;
3419
+ }>;
2429
3420
  404: z.ZodObject<{
2430
3421
  errors: z.ZodArray<z.ZodObject<{
2431
3422
  id: z.ZodOptional<z.ZodString>;
@@ -2698,5 +3689,2633 @@ export declare const commodityDealsRouter: {
2698
3689
  }>;
2699
3690
  };
2700
3691
  };
3692
+ addDealParticipant: {
3693
+ pathParams: z.ZodObject<{
3694
+ organizationId: z.ZodString;
3695
+ id: z.ZodString;
3696
+ }, "strip", z.ZodTypeAny, {
3697
+ id: string;
3698
+ organizationId: string;
3699
+ }, {
3700
+ id: string;
3701
+ organizationId: string;
3702
+ }>;
3703
+ summary: "Add an investor participant to a commodity deal";
3704
+ method: "POST";
3705
+ body: z.ZodObject<{
3706
+ data: z.ZodObject<{
3707
+ type: z.ZodLiteral<"commodity-deal-participants">;
3708
+ attributes: z.ZodObject<{
3709
+ userId: z.ZodString;
3710
+ capitalContributed: z.ZodNumber;
3711
+ }, "strip", z.ZodTypeAny, {
3712
+ userId: string;
3713
+ capitalContributed: number;
3714
+ }, {
3715
+ userId: string;
3716
+ capitalContributed: number;
3717
+ }>;
3718
+ }, "strip", z.ZodTypeAny, {
3719
+ type: "commodity-deal-participants";
3720
+ attributes: {
3721
+ userId: string;
3722
+ capitalContributed: number;
3723
+ };
3724
+ }, {
3725
+ type: "commodity-deal-participants";
3726
+ attributes: {
3727
+ userId: string;
3728
+ capitalContributed: number;
3729
+ };
3730
+ }>;
3731
+ }, "strip", z.ZodTypeAny, {
3732
+ data: {
3733
+ type: "commodity-deal-participants";
3734
+ attributes: {
3735
+ userId: string;
3736
+ capitalContributed: number;
3737
+ };
3738
+ };
3739
+ }, {
3740
+ data: {
3741
+ type: "commodity-deal-participants";
3742
+ attributes: {
3743
+ userId: string;
3744
+ capitalContributed: number;
3745
+ };
3746
+ };
3747
+ }>;
3748
+ path: "/organizations/:organizationId/commodity-deals/:id/participants";
3749
+ responses: {
3750
+ 201: z.ZodObject<{
3751
+ data: z.ZodObject<{
3752
+ type: z.ZodLiteral<string>;
3753
+ id: z.ZodString;
3754
+ attributes: z.ZodObject<{
3755
+ organizationId: z.ZodString;
3756
+ waybillId: z.ZodString;
3757
+ invoiceId: z.ZodNullable<z.ZodString>;
3758
+ handlerUserId: z.ZodNullable<z.ZodString>;
3759
+ waybillNumber: z.ZodNullable<z.ZodString>;
3760
+ invoiceNumber: z.ZodNullable<z.ZodString>;
3761
+ buyerName: z.ZodNullable<z.ZodString>;
3762
+ purchaseCost: z.ZodNumber;
3763
+ transportCost: z.ZodNumber;
3764
+ miscellaneousCost: z.ZodNumber;
3765
+ currency: z.ZodDefault<z.ZodString>;
3766
+ status: z.ZodEnum<["draft", "in_transit", "invoiced", "paid", "cancelled"]>;
3767
+ notes: z.ZodNullable<z.ZodString>;
3768
+ companyCommissionRate: z.ZodNullable<z.ZodNumber>;
3769
+ participants: z.ZodOptional<z.ZodArray<z.ZodObject<{
3770
+ userId: z.ZodString;
3771
+ name: z.ZodOptional<z.ZodString>;
3772
+ email: z.ZodOptional<z.ZodString>;
3773
+ capitalContributed: z.ZodNumber;
3774
+ ownershipPercent: z.ZodNumber;
3775
+ earningsAmount: z.ZodNullable<z.ZodNumber>;
3776
+ }, "strip", z.ZodTypeAny, {
3777
+ userId: string;
3778
+ capitalContributed: number;
3779
+ ownershipPercent: number;
3780
+ earningsAmount: number | null;
3781
+ email?: string | undefined;
3782
+ name?: string | undefined;
3783
+ }, {
3784
+ userId: string;
3785
+ capitalContributed: number;
3786
+ ownershipPercent: number;
3787
+ earningsAmount: number | null;
3788
+ email?: string | undefined;
3789
+ name?: string | undefined;
3790
+ }>, "many">>;
3791
+ computed: z.ZodObject<{
3792
+ totalCost: z.ZodNumber;
3793
+ saleAmount: z.ZodNullable<z.ZodNumber>;
3794
+ grossProfit: z.ZodNullable<z.ZodNumber>;
3795
+ commissionRate: z.ZodNullable<z.ZodNumber>;
3796
+ staffCommissionRate: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
3797
+ commissionAmount: z.ZodNullable<z.ZodNumber>;
3798
+ staffCommissionAmount: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
3799
+ companyNet: z.ZodNullable<z.ZodNumber>;
3800
+ netAfterStaff: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
3801
+ companyCommissionRate: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
3802
+ companyCommissionAmount: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
3803
+ investorPool: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
3804
+ isRealized: z.ZodBoolean;
3805
+ }, "strip", z.ZodTypeAny, {
3806
+ totalCost: number;
3807
+ saleAmount: number | null;
3808
+ grossProfit: number | null;
3809
+ commissionRate: number | null;
3810
+ commissionAmount: number | null;
3811
+ companyNet: number | null;
3812
+ isRealized: boolean;
3813
+ companyCommissionRate?: number | null | undefined;
3814
+ staffCommissionRate?: number | null | undefined;
3815
+ staffCommissionAmount?: number | null | undefined;
3816
+ netAfterStaff?: number | null | undefined;
3817
+ companyCommissionAmount?: number | null | undefined;
3818
+ investorPool?: number | null | undefined;
3819
+ }, {
3820
+ totalCost: number;
3821
+ saleAmount: number | null;
3822
+ grossProfit: number | null;
3823
+ commissionRate: number | null;
3824
+ commissionAmount: number | null;
3825
+ companyNet: number | null;
3826
+ isRealized: boolean;
3827
+ companyCommissionRate?: number | null | undefined;
3828
+ staffCommissionRate?: number | null | undefined;
3829
+ staffCommissionAmount?: number | null | undefined;
3830
+ netAfterStaff?: number | null | undefined;
3831
+ companyCommissionAmount?: number | null | undefined;
3832
+ investorPool?: number | null | undefined;
3833
+ }>;
3834
+ } & {
3835
+ createdAt: z.ZodString;
3836
+ updatedAt: z.ZodString;
3837
+ }, "strip", z.ZodTypeAny, {
3838
+ status: "cancelled" | "paid" | "draft" | "in_transit" | "invoiced";
3839
+ createdAt: string;
3840
+ updatedAt: string;
3841
+ currency: string;
3842
+ notes: string | null;
3843
+ buyerName: string | null;
3844
+ transportCost: number;
3845
+ organizationId: string;
3846
+ companyCommissionRate: number | null;
3847
+ waybillNumber: string | null;
3848
+ purchaseCost: number;
3849
+ miscellaneousCost: number;
3850
+ invoiceNumber: string | null;
3851
+ waybillId: string;
3852
+ invoiceId: string | null;
3853
+ handlerUserId: string | null;
3854
+ computed: {
3855
+ totalCost: number;
3856
+ saleAmount: number | null;
3857
+ grossProfit: number | null;
3858
+ commissionRate: number | null;
3859
+ commissionAmount: number | null;
3860
+ companyNet: number | null;
3861
+ isRealized: boolean;
3862
+ companyCommissionRate?: number | null | undefined;
3863
+ staffCommissionRate?: number | null | undefined;
3864
+ staffCommissionAmount?: number | null | undefined;
3865
+ netAfterStaff?: number | null | undefined;
3866
+ companyCommissionAmount?: number | null | undefined;
3867
+ investorPool?: number | null | undefined;
3868
+ };
3869
+ participants?: {
3870
+ userId: string;
3871
+ capitalContributed: number;
3872
+ ownershipPercent: number;
3873
+ earningsAmount: number | null;
3874
+ email?: string | undefined;
3875
+ name?: string | undefined;
3876
+ }[] | undefined;
3877
+ }, {
3878
+ status: "cancelled" | "paid" | "draft" | "in_transit" | "invoiced";
3879
+ createdAt: string;
3880
+ updatedAt: string;
3881
+ notes: string | null;
3882
+ buyerName: string | null;
3883
+ transportCost: number;
3884
+ organizationId: string;
3885
+ companyCommissionRate: number | null;
3886
+ waybillNumber: string | null;
3887
+ purchaseCost: number;
3888
+ miscellaneousCost: number;
3889
+ invoiceNumber: string | null;
3890
+ waybillId: string;
3891
+ invoiceId: string | null;
3892
+ handlerUserId: string | null;
3893
+ computed: {
3894
+ totalCost: number;
3895
+ saleAmount: number | null;
3896
+ grossProfit: number | null;
3897
+ commissionRate: number | null;
3898
+ commissionAmount: number | null;
3899
+ companyNet: number | null;
3900
+ isRealized: boolean;
3901
+ companyCommissionRate?: number | null | undefined;
3902
+ staffCommissionRate?: number | null | undefined;
3903
+ staffCommissionAmount?: number | null | undefined;
3904
+ netAfterStaff?: number | null | undefined;
3905
+ companyCommissionAmount?: number | null | undefined;
3906
+ investorPool?: number | null | undefined;
3907
+ };
3908
+ currency?: string | undefined;
3909
+ participants?: {
3910
+ userId: string;
3911
+ capitalContributed: number;
3912
+ ownershipPercent: number;
3913
+ earningsAmount: number | null;
3914
+ email?: string | undefined;
3915
+ name?: string | undefined;
3916
+ }[] | undefined;
3917
+ }>;
3918
+ relationships: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
3919
+ links: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
3920
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
3921
+ }, "strip", z.ZodTypeAny, {
3922
+ type: string;
3923
+ id: string;
3924
+ attributes: {
3925
+ status: "cancelled" | "paid" | "draft" | "in_transit" | "invoiced";
3926
+ createdAt: string;
3927
+ updatedAt: string;
3928
+ currency: string;
3929
+ notes: string | null;
3930
+ buyerName: string | null;
3931
+ transportCost: number;
3932
+ organizationId: string;
3933
+ companyCommissionRate: number | null;
3934
+ waybillNumber: string | null;
3935
+ purchaseCost: number;
3936
+ miscellaneousCost: number;
3937
+ invoiceNumber: string | null;
3938
+ waybillId: string;
3939
+ invoiceId: string | null;
3940
+ handlerUserId: string | null;
3941
+ computed: {
3942
+ totalCost: number;
3943
+ saleAmount: number | null;
3944
+ grossProfit: number | null;
3945
+ commissionRate: number | null;
3946
+ commissionAmount: number | null;
3947
+ companyNet: number | null;
3948
+ isRealized: boolean;
3949
+ companyCommissionRate?: number | null | undefined;
3950
+ staffCommissionRate?: number | null | undefined;
3951
+ staffCommissionAmount?: number | null | undefined;
3952
+ netAfterStaff?: number | null | undefined;
3953
+ companyCommissionAmount?: number | null | undefined;
3954
+ investorPool?: number | null | undefined;
3955
+ };
3956
+ participants?: {
3957
+ userId: string;
3958
+ capitalContributed: number;
3959
+ ownershipPercent: number;
3960
+ earningsAmount: number | null;
3961
+ email?: string | undefined;
3962
+ name?: string | undefined;
3963
+ }[] | undefined;
3964
+ };
3965
+ relationships?: Record<string, unknown> | undefined;
3966
+ links?: Record<string, string> | undefined;
3967
+ meta?: Record<string, unknown> | undefined;
3968
+ }, {
3969
+ type: string;
3970
+ id: string;
3971
+ attributes: {
3972
+ status: "cancelled" | "paid" | "draft" | "in_transit" | "invoiced";
3973
+ createdAt: string;
3974
+ updatedAt: string;
3975
+ notes: string | null;
3976
+ buyerName: string | null;
3977
+ transportCost: number;
3978
+ organizationId: string;
3979
+ companyCommissionRate: number | null;
3980
+ waybillNumber: string | null;
3981
+ purchaseCost: number;
3982
+ miscellaneousCost: number;
3983
+ invoiceNumber: string | null;
3984
+ waybillId: string;
3985
+ invoiceId: string | null;
3986
+ handlerUserId: string | null;
3987
+ computed: {
3988
+ totalCost: number;
3989
+ saleAmount: number | null;
3990
+ grossProfit: number | null;
3991
+ commissionRate: number | null;
3992
+ commissionAmount: number | null;
3993
+ companyNet: number | null;
3994
+ isRealized: boolean;
3995
+ companyCommissionRate?: number | null | undefined;
3996
+ staffCommissionRate?: number | null | undefined;
3997
+ staffCommissionAmount?: number | null | undefined;
3998
+ netAfterStaff?: number | null | undefined;
3999
+ companyCommissionAmount?: number | null | undefined;
4000
+ investorPool?: number | null | undefined;
4001
+ };
4002
+ currency?: string | undefined;
4003
+ participants?: {
4004
+ userId: string;
4005
+ capitalContributed: number;
4006
+ ownershipPercent: number;
4007
+ earningsAmount: number | null;
4008
+ email?: string | undefined;
4009
+ name?: string | undefined;
4010
+ }[] | undefined;
4011
+ };
4012
+ relationships?: Record<string, unknown> | undefined;
4013
+ links?: Record<string, string> | undefined;
4014
+ meta?: Record<string, unknown> | undefined;
4015
+ }>;
4016
+ included: z.ZodOptional<z.ZodArray<z.ZodObject<{
4017
+ type: z.ZodString;
4018
+ id: z.ZodString;
4019
+ attributes: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
4020
+ relationships: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
4021
+ links: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
4022
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
4023
+ }, "strip", z.ZodTypeAny, {
4024
+ type: string;
4025
+ id: string;
4026
+ attributes?: Record<string, unknown> | undefined;
4027
+ relationships?: Record<string, unknown> | undefined;
4028
+ links?: Record<string, string> | undefined;
4029
+ meta?: Record<string, unknown> | undefined;
4030
+ }, {
4031
+ type: string;
4032
+ id: string;
4033
+ attributes?: Record<string, unknown> | undefined;
4034
+ relationships?: Record<string, unknown> | undefined;
4035
+ links?: Record<string, string> | undefined;
4036
+ meta?: Record<string, unknown> | undefined;
4037
+ }>, "many">>;
4038
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
4039
+ links: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
4040
+ }, "strip", z.ZodTypeAny, {
4041
+ data: {
4042
+ type: string;
4043
+ id: string;
4044
+ attributes: {
4045
+ status: "cancelled" | "paid" | "draft" | "in_transit" | "invoiced";
4046
+ createdAt: string;
4047
+ updatedAt: string;
4048
+ currency: string;
4049
+ notes: string | null;
4050
+ buyerName: string | null;
4051
+ transportCost: number;
4052
+ organizationId: string;
4053
+ companyCommissionRate: number | null;
4054
+ waybillNumber: string | null;
4055
+ purchaseCost: number;
4056
+ miscellaneousCost: number;
4057
+ invoiceNumber: string | null;
4058
+ waybillId: string;
4059
+ invoiceId: string | null;
4060
+ handlerUserId: string | null;
4061
+ computed: {
4062
+ totalCost: number;
4063
+ saleAmount: number | null;
4064
+ grossProfit: number | null;
4065
+ commissionRate: number | null;
4066
+ commissionAmount: number | null;
4067
+ companyNet: number | null;
4068
+ isRealized: boolean;
4069
+ companyCommissionRate?: number | null | undefined;
4070
+ staffCommissionRate?: number | null | undefined;
4071
+ staffCommissionAmount?: number | null | undefined;
4072
+ netAfterStaff?: number | null | undefined;
4073
+ companyCommissionAmount?: number | null | undefined;
4074
+ investorPool?: number | null | undefined;
4075
+ };
4076
+ participants?: {
4077
+ userId: string;
4078
+ capitalContributed: number;
4079
+ ownershipPercent: number;
4080
+ earningsAmount: number | null;
4081
+ email?: string | undefined;
4082
+ name?: string | undefined;
4083
+ }[] | undefined;
4084
+ };
4085
+ relationships?: Record<string, unknown> | undefined;
4086
+ links?: Record<string, string> | undefined;
4087
+ meta?: Record<string, unknown> | undefined;
4088
+ };
4089
+ links?: Record<string, string> | undefined;
4090
+ meta?: Record<string, unknown> | undefined;
4091
+ included?: {
4092
+ type: string;
4093
+ id: string;
4094
+ attributes?: Record<string, unknown> | undefined;
4095
+ relationships?: Record<string, unknown> | undefined;
4096
+ links?: Record<string, string> | undefined;
4097
+ meta?: Record<string, unknown> | undefined;
4098
+ }[] | undefined;
4099
+ }, {
4100
+ data: {
4101
+ type: string;
4102
+ id: string;
4103
+ attributes: {
4104
+ status: "cancelled" | "paid" | "draft" | "in_transit" | "invoiced";
4105
+ createdAt: string;
4106
+ updatedAt: string;
4107
+ notes: string | null;
4108
+ buyerName: string | null;
4109
+ transportCost: number;
4110
+ organizationId: string;
4111
+ companyCommissionRate: number | null;
4112
+ waybillNumber: string | null;
4113
+ purchaseCost: number;
4114
+ miscellaneousCost: number;
4115
+ invoiceNumber: string | null;
4116
+ waybillId: string;
4117
+ invoiceId: string | null;
4118
+ handlerUserId: string | null;
4119
+ computed: {
4120
+ totalCost: number;
4121
+ saleAmount: number | null;
4122
+ grossProfit: number | null;
4123
+ commissionRate: number | null;
4124
+ commissionAmount: number | null;
4125
+ companyNet: number | null;
4126
+ isRealized: boolean;
4127
+ companyCommissionRate?: number | null | undefined;
4128
+ staffCommissionRate?: number | null | undefined;
4129
+ staffCommissionAmount?: number | null | undefined;
4130
+ netAfterStaff?: number | null | undefined;
4131
+ companyCommissionAmount?: number | null | undefined;
4132
+ investorPool?: number | null | undefined;
4133
+ };
4134
+ currency?: string | undefined;
4135
+ participants?: {
4136
+ userId: string;
4137
+ capitalContributed: number;
4138
+ ownershipPercent: number;
4139
+ earningsAmount: number | null;
4140
+ email?: string | undefined;
4141
+ name?: string | undefined;
4142
+ }[] | undefined;
4143
+ };
4144
+ relationships?: Record<string, unknown> | undefined;
4145
+ links?: Record<string, string> | undefined;
4146
+ meta?: Record<string, unknown> | undefined;
4147
+ };
4148
+ links?: Record<string, string> | undefined;
4149
+ meta?: Record<string, unknown> | undefined;
4150
+ included?: {
4151
+ type: string;
4152
+ id: string;
4153
+ attributes?: Record<string, unknown> | undefined;
4154
+ relationships?: Record<string, unknown> | undefined;
4155
+ links?: Record<string, string> | undefined;
4156
+ meta?: Record<string, unknown> | undefined;
4157
+ }[] | undefined;
4158
+ }>;
4159
+ 400: z.ZodObject<{
4160
+ errors: z.ZodArray<z.ZodObject<{
4161
+ id: z.ZodOptional<z.ZodString>;
4162
+ links: z.ZodOptional<z.ZodObject<{
4163
+ about: z.ZodOptional<z.ZodString>;
4164
+ }, "strip", z.ZodTypeAny, {
4165
+ about?: string | undefined;
4166
+ }, {
4167
+ about?: string | undefined;
4168
+ }>>;
4169
+ status: z.ZodOptional<z.ZodString>;
4170
+ code: z.ZodOptional<z.ZodString>;
4171
+ title: z.ZodOptional<z.ZodString>;
4172
+ detail: z.ZodOptional<z.ZodString>;
4173
+ source: z.ZodOptional<z.ZodObject<{
4174
+ pointer: z.ZodOptional<z.ZodString>;
4175
+ parameter: z.ZodOptional<z.ZodString>;
4176
+ }, "strip", z.ZodTypeAny, {
4177
+ pointer?: string | undefined;
4178
+ parameter?: string | undefined;
4179
+ }, {
4180
+ pointer?: string | undefined;
4181
+ parameter?: string | undefined;
4182
+ }>>;
4183
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
4184
+ }, "strip", z.ZodTypeAny, {
4185
+ status?: string | undefined;
4186
+ code?: string | undefined;
4187
+ id?: string | undefined;
4188
+ links?: {
4189
+ about?: string | undefined;
4190
+ } | undefined;
4191
+ meta?: Record<string, unknown> | undefined;
4192
+ title?: string | undefined;
4193
+ detail?: string | undefined;
4194
+ source?: {
4195
+ pointer?: string | undefined;
4196
+ parameter?: string | undefined;
4197
+ } | undefined;
4198
+ }, {
4199
+ status?: string | undefined;
4200
+ code?: string | undefined;
4201
+ id?: string | undefined;
4202
+ links?: {
4203
+ about?: string | undefined;
4204
+ } | undefined;
4205
+ meta?: Record<string, unknown> | undefined;
4206
+ title?: string | undefined;
4207
+ detail?: string | undefined;
4208
+ source?: {
4209
+ pointer?: string | undefined;
4210
+ parameter?: string | undefined;
4211
+ } | undefined;
4212
+ }>, "many">;
4213
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
4214
+ }, "strip", z.ZodTypeAny, {
4215
+ errors: {
4216
+ status?: string | undefined;
4217
+ code?: string | undefined;
4218
+ id?: string | undefined;
4219
+ links?: {
4220
+ about?: string | undefined;
4221
+ } | undefined;
4222
+ meta?: Record<string, unknown> | undefined;
4223
+ title?: string | undefined;
4224
+ detail?: string | undefined;
4225
+ source?: {
4226
+ pointer?: string | undefined;
4227
+ parameter?: string | undefined;
4228
+ } | undefined;
4229
+ }[];
4230
+ meta?: Record<string, unknown> | undefined;
4231
+ }, {
4232
+ errors: {
4233
+ status?: string | undefined;
4234
+ code?: string | undefined;
4235
+ id?: string | undefined;
4236
+ links?: {
4237
+ about?: string | undefined;
4238
+ } | undefined;
4239
+ meta?: Record<string, unknown> | undefined;
4240
+ title?: string | undefined;
4241
+ detail?: string | undefined;
4242
+ source?: {
4243
+ pointer?: string | undefined;
4244
+ parameter?: string | undefined;
4245
+ } | undefined;
4246
+ }[];
4247
+ meta?: Record<string, unknown> | undefined;
4248
+ }>;
4249
+ 401: z.ZodObject<{
4250
+ errors: z.ZodArray<z.ZodObject<{
4251
+ id: z.ZodOptional<z.ZodString>;
4252
+ links: z.ZodOptional<z.ZodObject<{
4253
+ about: z.ZodOptional<z.ZodString>;
4254
+ }, "strip", z.ZodTypeAny, {
4255
+ about?: string | undefined;
4256
+ }, {
4257
+ about?: string | undefined;
4258
+ }>>;
4259
+ status: z.ZodOptional<z.ZodString>;
4260
+ code: z.ZodOptional<z.ZodString>;
4261
+ title: z.ZodOptional<z.ZodString>;
4262
+ detail: z.ZodOptional<z.ZodString>;
4263
+ source: z.ZodOptional<z.ZodObject<{
4264
+ pointer: z.ZodOptional<z.ZodString>;
4265
+ parameter: z.ZodOptional<z.ZodString>;
4266
+ }, "strip", z.ZodTypeAny, {
4267
+ pointer?: string | undefined;
4268
+ parameter?: string | undefined;
4269
+ }, {
4270
+ pointer?: string | undefined;
4271
+ parameter?: string | undefined;
4272
+ }>>;
4273
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
4274
+ }, "strip", z.ZodTypeAny, {
4275
+ status?: string | undefined;
4276
+ code?: string | undefined;
4277
+ id?: string | undefined;
4278
+ links?: {
4279
+ about?: string | undefined;
4280
+ } | undefined;
4281
+ meta?: Record<string, unknown> | undefined;
4282
+ title?: string | undefined;
4283
+ detail?: string | undefined;
4284
+ source?: {
4285
+ pointer?: string | undefined;
4286
+ parameter?: string | undefined;
4287
+ } | undefined;
4288
+ }, {
4289
+ status?: string | undefined;
4290
+ code?: string | undefined;
4291
+ id?: string | undefined;
4292
+ links?: {
4293
+ about?: string | undefined;
4294
+ } | undefined;
4295
+ meta?: Record<string, unknown> | undefined;
4296
+ title?: string | undefined;
4297
+ detail?: string | undefined;
4298
+ source?: {
4299
+ pointer?: string | undefined;
4300
+ parameter?: string | undefined;
4301
+ } | undefined;
4302
+ }>, "many">;
4303
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
4304
+ }, "strip", z.ZodTypeAny, {
4305
+ errors: {
4306
+ status?: string | undefined;
4307
+ code?: string | undefined;
4308
+ id?: string | undefined;
4309
+ links?: {
4310
+ about?: string | undefined;
4311
+ } | undefined;
4312
+ meta?: Record<string, unknown> | undefined;
4313
+ title?: string | undefined;
4314
+ detail?: string | undefined;
4315
+ source?: {
4316
+ pointer?: string | undefined;
4317
+ parameter?: string | undefined;
4318
+ } | undefined;
4319
+ }[];
4320
+ meta?: Record<string, unknown> | undefined;
4321
+ }, {
4322
+ errors: {
4323
+ status?: string | undefined;
4324
+ code?: string | undefined;
4325
+ id?: string | undefined;
4326
+ links?: {
4327
+ about?: string | undefined;
4328
+ } | undefined;
4329
+ meta?: Record<string, unknown> | undefined;
4330
+ title?: string | undefined;
4331
+ detail?: string | undefined;
4332
+ source?: {
4333
+ pointer?: string | undefined;
4334
+ parameter?: string | undefined;
4335
+ } | undefined;
4336
+ }[];
4337
+ meta?: Record<string, unknown> | undefined;
4338
+ }>;
4339
+ 403: z.ZodObject<{
4340
+ errors: z.ZodArray<z.ZodObject<{
4341
+ id: z.ZodOptional<z.ZodString>;
4342
+ links: z.ZodOptional<z.ZodObject<{
4343
+ about: z.ZodOptional<z.ZodString>;
4344
+ }, "strip", z.ZodTypeAny, {
4345
+ about?: string | undefined;
4346
+ }, {
4347
+ about?: string | undefined;
4348
+ }>>;
4349
+ status: z.ZodOptional<z.ZodString>;
4350
+ code: z.ZodOptional<z.ZodString>;
4351
+ title: z.ZodOptional<z.ZodString>;
4352
+ detail: z.ZodOptional<z.ZodString>;
4353
+ source: z.ZodOptional<z.ZodObject<{
4354
+ pointer: z.ZodOptional<z.ZodString>;
4355
+ parameter: z.ZodOptional<z.ZodString>;
4356
+ }, "strip", z.ZodTypeAny, {
4357
+ pointer?: string | undefined;
4358
+ parameter?: string | undefined;
4359
+ }, {
4360
+ pointer?: string | undefined;
4361
+ parameter?: string | undefined;
4362
+ }>>;
4363
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
4364
+ }, "strip", z.ZodTypeAny, {
4365
+ status?: string | undefined;
4366
+ code?: string | undefined;
4367
+ id?: string | undefined;
4368
+ links?: {
4369
+ about?: string | undefined;
4370
+ } | undefined;
4371
+ meta?: Record<string, unknown> | undefined;
4372
+ title?: string | undefined;
4373
+ detail?: string | undefined;
4374
+ source?: {
4375
+ pointer?: string | undefined;
4376
+ parameter?: string | undefined;
4377
+ } | undefined;
4378
+ }, {
4379
+ status?: string | undefined;
4380
+ code?: string | undefined;
4381
+ id?: string | undefined;
4382
+ links?: {
4383
+ about?: string | undefined;
4384
+ } | undefined;
4385
+ meta?: Record<string, unknown> | undefined;
4386
+ title?: string | undefined;
4387
+ detail?: string | undefined;
4388
+ source?: {
4389
+ pointer?: string | undefined;
4390
+ parameter?: string | undefined;
4391
+ } | undefined;
4392
+ }>, "many">;
4393
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
4394
+ }, "strip", z.ZodTypeAny, {
4395
+ errors: {
4396
+ status?: string | undefined;
4397
+ code?: string | undefined;
4398
+ id?: string | undefined;
4399
+ links?: {
4400
+ about?: string | undefined;
4401
+ } | undefined;
4402
+ meta?: Record<string, unknown> | undefined;
4403
+ title?: string | undefined;
4404
+ detail?: string | undefined;
4405
+ source?: {
4406
+ pointer?: string | undefined;
4407
+ parameter?: string | undefined;
4408
+ } | undefined;
4409
+ }[];
4410
+ meta?: Record<string, unknown> | undefined;
4411
+ }, {
4412
+ errors: {
4413
+ status?: string | undefined;
4414
+ code?: string | undefined;
4415
+ id?: string | undefined;
4416
+ links?: {
4417
+ about?: string | undefined;
4418
+ } | undefined;
4419
+ meta?: Record<string, unknown> | undefined;
4420
+ title?: string | undefined;
4421
+ detail?: string | undefined;
4422
+ source?: {
4423
+ pointer?: string | undefined;
4424
+ parameter?: string | undefined;
4425
+ } | undefined;
4426
+ }[];
4427
+ meta?: Record<string, unknown> | undefined;
4428
+ }>;
4429
+ 404: z.ZodObject<{
4430
+ errors: z.ZodArray<z.ZodObject<{
4431
+ id: z.ZodOptional<z.ZodString>;
4432
+ links: z.ZodOptional<z.ZodObject<{
4433
+ about: z.ZodOptional<z.ZodString>;
4434
+ }, "strip", z.ZodTypeAny, {
4435
+ about?: string | undefined;
4436
+ }, {
4437
+ about?: string | undefined;
4438
+ }>>;
4439
+ status: z.ZodOptional<z.ZodString>;
4440
+ code: z.ZodOptional<z.ZodString>;
4441
+ title: z.ZodOptional<z.ZodString>;
4442
+ detail: z.ZodOptional<z.ZodString>;
4443
+ source: z.ZodOptional<z.ZodObject<{
4444
+ pointer: z.ZodOptional<z.ZodString>;
4445
+ parameter: z.ZodOptional<z.ZodString>;
4446
+ }, "strip", z.ZodTypeAny, {
4447
+ pointer?: string | undefined;
4448
+ parameter?: string | undefined;
4449
+ }, {
4450
+ pointer?: string | undefined;
4451
+ parameter?: string | undefined;
4452
+ }>>;
4453
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
4454
+ }, "strip", z.ZodTypeAny, {
4455
+ status?: string | undefined;
4456
+ code?: string | undefined;
4457
+ id?: string | undefined;
4458
+ links?: {
4459
+ about?: string | undefined;
4460
+ } | undefined;
4461
+ meta?: Record<string, unknown> | undefined;
4462
+ title?: string | undefined;
4463
+ detail?: string | undefined;
4464
+ source?: {
4465
+ pointer?: string | undefined;
4466
+ parameter?: string | undefined;
4467
+ } | undefined;
4468
+ }, {
4469
+ status?: string | undefined;
4470
+ code?: string | undefined;
4471
+ id?: string | undefined;
4472
+ links?: {
4473
+ about?: string | undefined;
4474
+ } | undefined;
4475
+ meta?: Record<string, unknown> | undefined;
4476
+ title?: string | undefined;
4477
+ detail?: string | undefined;
4478
+ source?: {
4479
+ pointer?: string | undefined;
4480
+ parameter?: string | undefined;
4481
+ } | undefined;
4482
+ }>, "many">;
4483
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
4484
+ }, "strip", z.ZodTypeAny, {
4485
+ errors: {
4486
+ status?: string | undefined;
4487
+ code?: string | undefined;
4488
+ id?: string | undefined;
4489
+ links?: {
4490
+ about?: string | undefined;
4491
+ } | undefined;
4492
+ meta?: Record<string, unknown> | undefined;
4493
+ title?: string | undefined;
4494
+ detail?: string | undefined;
4495
+ source?: {
4496
+ pointer?: string | undefined;
4497
+ parameter?: string | undefined;
4498
+ } | undefined;
4499
+ }[];
4500
+ meta?: Record<string, unknown> | undefined;
4501
+ }, {
4502
+ errors: {
4503
+ status?: string | undefined;
4504
+ code?: string | undefined;
4505
+ id?: string | undefined;
4506
+ links?: {
4507
+ about?: string | undefined;
4508
+ } | undefined;
4509
+ meta?: Record<string, unknown> | undefined;
4510
+ title?: string | undefined;
4511
+ detail?: string | undefined;
4512
+ source?: {
4513
+ pointer?: string | undefined;
4514
+ parameter?: string | undefined;
4515
+ } | undefined;
4516
+ }[];
4517
+ meta?: Record<string, unknown> | undefined;
4518
+ }>;
4519
+ 422: z.ZodObject<{
4520
+ errors: z.ZodArray<z.ZodObject<{
4521
+ id: z.ZodOptional<z.ZodString>;
4522
+ links: z.ZodOptional<z.ZodObject<{
4523
+ about: z.ZodOptional<z.ZodString>;
4524
+ }, "strip", z.ZodTypeAny, {
4525
+ about?: string | undefined;
4526
+ }, {
4527
+ about?: string | undefined;
4528
+ }>>;
4529
+ status: z.ZodOptional<z.ZodString>;
4530
+ code: z.ZodOptional<z.ZodString>;
4531
+ title: z.ZodOptional<z.ZodString>;
4532
+ detail: z.ZodOptional<z.ZodString>;
4533
+ source: z.ZodOptional<z.ZodObject<{
4534
+ pointer: z.ZodOptional<z.ZodString>;
4535
+ parameter: z.ZodOptional<z.ZodString>;
4536
+ }, "strip", z.ZodTypeAny, {
4537
+ pointer?: string | undefined;
4538
+ parameter?: string | undefined;
4539
+ }, {
4540
+ pointer?: string | undefined;
4541
+ parameter?: string | undefined;
4542
+ }>>;
4543
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
4544
+ }, "strip", z.ZodTypeAny, {
4545
+ status?: string | undefined;
4546
+ code?: string | undefined;
4547
+ id?: string | undefined;
4548
+ links?: {
4549
+ about?: string | undefined;
4550
+ } | undefined;
4551
+ meta?: Record<string, unknown> | undefined;
4552
+ title?: string | undefined;
4553
+ detail?: string | undefined;
4554
+ source?: {
4555
+ pointer?: string | undefined;
4556
+ parameter?: string | undefined;
4557
+ } | undefined;
4558
+ }, {
4559
+ status?: string | undefined;
4560
+ code?: string | undefined;
4561
+ id?: string | undefined;
4562
+ links?: {
4563
+ about?: string | undefined;
4564
+ } | undefined;
4565
+ meta?: Record<string, unknown> | undefined;
4566
+ title?: string | undefined;
4567
+ detail?: string | undefined;
4568
+ source?: {
4569
+ pointer?: string | undefined;
4570
+ parameter?: string | undefined;
4571
+ } | undefined;
4572
+ }>, "many">;
4573
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
4574
+ }, "strip", z.ZodTypeAny, {
4575
+ errors: {
4576
+ status?: string | undefined;
4577
+ code?: string | undefined;
4578
+ id?: string | undefined;
4579
+ links?: {
4580
+ about?: string | undefined;
4581
+ } | undefined;
4582
+ meta?: Record<string, unknown> | undefined;
4583
+ title?: string | undefined;
4584
+ detail?: string | undefined;
4585
+ source?: {
4586
+ pointer?: string | undefined;
4587
+ parameter?: string | undefined;
4588
+ } | undefined;
4589
+ }[];
4590
+ meta?: Record<string, unknown> | undefined;
4591
+ }, {
4592
+ errors: {
4593
+ status?: string | undefined;
4594
+ code?: string | undefined;
4595
+ id?: string | undefined;
4596
+ links?: {
4597
+ about?: string | undefined;
4598
+ } | undefined;
4599
+ meta?: Record<string, unknown> | undefined;
4600
+ title?: string | undefined;
4601
+ detail?: string | undefined;
4602
+ source?: {
4603
+ pointer?: string | undefined;
4604
+ parameter?: string | undefined;
4605
+ } | undefined;
4606
+ }[];
4607
+ meta?: Record<string, unknown> | undefined;
4608
+ }>;
4609
+ };
4610
+ };
4611
+ updateDealParticipant: {
4612
+ pathParams: z.ZodObject<{
4613
+ organizationId: z.ZodString;
4614
+ id: z.ZodString;
4615
+ participantId: z.ZodString;
4616
+ }, "strip", z.ZodTypeAny, {
4617
+ id: string;
4618
+ organizationId: string;
4619
+ participantId: string;
4620
+ }, {
4621
+ id: string;
4622
+ organizationId: string;
4623
+ participantId: string;
4624
+ }>;
4625
+ summary: "Update capital contributed for a deal participant";
4626
+ method: "PATCH";
4627
+ body: z.ZodObject<{
4628
+ data: z.ZodObject<{
4629
+ type: z.ZodLiteral<"commodity-deal-participants">;
4630
+ id: z.ZodOptional<z.ZodString>;
4631
+ attributes: z.ZodObject<{
4632
+ capitalContributed: z.ZodNumber;
4633
+ }, "strip", z.ZodTypeAny, {
4634
+ capitalContributed: number;
4635
+ }, {
4636
+ capitalContributed: number;
4637
+ }>;
4638
+ }, "strip", z.ZodTypeAny, {
4639
+ type: "commodity-deal-participants";
4640
+ attributes: {
4641
+ capitalContributed: number;
4642
+ };
4643
+ id?: string | undefined;
4644
+ }, {
4645
+ type: "commodity-deal-participants";
4646
+ attributes: {
4647
+ capitalContributed: number;
4648
+ };
4649
+ id?: string | undefined;
4650
+ }>;
4651
+ }, "strip", z.ZodTypeAny, {
4652
+ data: {
4653
+ type: "commodity-deal-participants";
4654
+ attributes: {
4655
+ capitalContributed: number;
4656
+ };
4657
+ id?: string | undefined;
4658
+ };
4659
+ }, {
4660
+ data: {
4661
+ type: "commodity-deal-participants";
4662
+ attributes: {
4663
+ capitalContributed: number;
4664
+ };
4665
+ id?: string | undefined;
4666
+ };
4667
+ }>;
4668
+ path: "/organizations/:organizationId/commodity-deals/:id/participants/:participantId";
4669
+ responses: {
4670
+ 200: z.ZodObject<{
4671
+ data: z.ZodObject<{
4672
+ type: z.ZodLiteral<string>;
4673
+ id: z.ZodString;
4674
+ attributes: z.ZodObject<{
4675
+ organizationId: z.ZodString;
4676
+ waybillId: z.ZodString;
4677
+ invoiceId: z.ZodNullable<z.ZodString>;
4678
+ handlerUserId: z.ZodNullable<z.ZodString>;
4679
+ waybillNumber: z.ZodNullable<z.ZodString>;
4680
+ invoiceNumber: z.ZodNullable<z.ZodString>;
4681
+ buyerName: z.ZodNullable<z.ZodString>;
4682
+ purchaseCost: z.ZodNumber;
4683
+ transportCost: z.ZodNumber;
4684
+ miscellaneousCost: z.ZodNumber;
4685
+ currency: z.ZodDefault<z.ZodString>;
4686
+ status: z.ZodEnum<["draft", "in_transit", "invoiced", "paid", "cancelled"]>;
4687
+ notes: z.ZodNullable<z.ZodString>;
4688
+ companyCommissionRate: z.ZodNullable<z.ZodNumber>;
4689
+ participants: z.ZodOptional<z.ZodArray<z.ZodObject<{
4690
+ userId: z.ZodString;
4691
+ name: z.ZodOptional<z.ZodString>;
4692
+ email: z.ZodOptional<z.ZodString>;
4693
+ capitalContributed: z.ZodNumber;
4694
+ ownershipPercent: z.ZodNumber;
4695
+ earningsAmount: z.ZodNullable<z.ZodNumber>;
4696
+ }, "strip", z.ZodTypeAny, {
4697
+ userId: string;
4698
+ capitalContributed: number;
4699
+ ownershipPercent: number;
4700
+ earningsAmount: number | null;
4701
+ email?: string | undefined;
4702
+ name?: string | undefined;
4703
+ }, {
4704
+ userId: string;
4705
+ capitalContributed: number;
4706
+ ownershipPercent: number;
4707
+ earningsAmount: number | null;
4708
+ email?: string | undefined;
4709
+ name?: string | undefined;
4710
+ }>, "many">>;
4711
+ computed: z.ZodObject<{
4712
+ totalCost: z.ZodNumber;
4713
+ saleAmount: z.ZodNullable<z.ZodNumber>;
4714
+ grossProfit: z.ZodNullable<z.ZodNumber>;
4715
+ commissionRate: z.ZodNullable<z.ZodNumber>;
4716
+ staffCommissionRate: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
4717
+ commissionAmount: z.ZodNullable<z.ZodNumber>;
4718
+ staffCommissionAmount: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
4719
+ companyNet: z.ZodNullable<z.ZodNumber>;
4720
+ netAfterStaff: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
4721
+ companyCommissionRate: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
4722
+ companyCommissionAmount: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
4723
+ investorPool: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
4724
+ isRealized: z.ZodBoolean;
4725
+ }, "strip", z.ZodTypeAny, {
4726
+ totalCost: number;
4727
+ saleAmount: number | null;
4728
+ grossProfit: number | null;
4729
+ commissionRate: number | null;
4730
+ commissionAmount: number | null;
4731
+ companyNet: number | null;
4732
+ isRealized: boolean;
4733
+ companyCommissionRate?: number | null | undefined;
4734
+ staffCommissionRate?: number | null | undefined;
4735
+ staffCommissionAmount?: number | null | undefined;
4736
+ netAfterStaff?: number | null | undefined;
4737
+ companyCommissionAmount?: number | null | undefined;
4738
+ investorPool?: number | null | undefined;
4739
+ }, {
4740
+ totalCost: number;
4741
+ saleAmount: number | null;
4742
+ grossProfit: number | null;
4743
+ commissionRate: number | null;
4744
+ commissionAmount: number | null;
4745
+ companyNet: number | null;
4746
+ isRealized: boolean;
4747
+ companyCommissionRate?: number | null | undefined;
4748
+ staffCommissionRate?: number | null | undefined;
4749
+ staffCommissionAmount?: number | null | undefined;
4750
+ netAfterStaff?: number | null | undefined;
4751
+ companyCommissionAmount?: number | null | undefined;
4752
+ investorPool?: number | null | undefined;
4753
+ }>;
4754
+ } & {
4755
+ createdAt: z.ZodString;
4756
+ updatedAt: z.ZodString;
4757
+ }, "strip", z.ZodTypeAny, {
4758
+ status: "cancelled" | "paid" | "draft" | "in_transit" | "invoiced";
4759
+ createdAt: string;
4760
+ updatedAt: string;
4761
+ currency: string;
4762
+ notes: string | null;
4763
+ buyerName: string | null;
4764
+ transportCost: number;
4765
+ organizationId: string;
4766
+ companyCommissionRate: number | null;
4767
+ waybillNumber: string | null;
4768
+ purchaseCost: number;
4769
+ miscellaneousCost: number;
4770
+ invoiceNumber: string | null;
4771
+ waybillId: string;
4772
+ invoiceId: string | null;
4773
+ handlerUserId: string | null;
4774
+ computed: {
4775
+ totalCost: number;
4776
+ saleAmount: number | null;
4777
+ grossProfit: number | null;
4778
+ commissionRate: number | null;
4779
+ commissionAmount: number | null;
4780
+ companyNet: number | null;
4781
+ isRealized: boolean;
4782
+ companyCommissionRate?: number | null | undefined;
4783
+ staffCommissionRate?: number | null | undefined;
4784
+ staffCommissionAmount?: number | null | undefined;
4785
+ netAfterStaff?: number | null | undefined;
4786
+ companyCommissionAmount?: number | null | undefined;
4787
+ investorPool?: number | null | undefined;
4788
+ };
4789
+ participants?: {
4790
+ userId: string;
4791
+ capitalContributed: number;
4792
+ ownershipPercent: number;
4793
+ earningsAmount: number | null;
4794
+ email?: string | undefined;
4795
+ name?: string | undefined;
4796
+ }[] | undefined;
4797
+ }, {
4798
+ status: "cancelled" | "paid" | "draft" | "in_transit" | "invoiced";
4799
+ createdAt: string;
4800
+ updatedAt: string;
4801
+ notes: string | null;
4802
+ buyerName: string | null;
4803
+ transportCost: number;
4804
+ organizationId: string;
4805
+ companyCommissionRate: number | null;
4806
+ waybillNumber: string | null;
4807
+ purchaseCost: number;
4808
+ miscellaneousCost: number;
4809
+ invoiceNumber: string | null;
4810
+ waybillId: string;
4811
+ invoiceId: string | null;
4812
+ handlerUserId: string | null;
4813
+ computed: {
4814
+ totalCost: number;
4815
+ saleAmount: number | null;
4816
+ grossProfit: number | null;
4817
+ commissionRate: number | null;
4818
+ commissionAmount: number | null;
4819
+ companyNet: number | null;
4820
+ isRealized: boolean;
4821
+ companyCommissionRate?: number | null | undefined;
4822
+ staffCommissionRate?: number | null | undefined;
4823
+ staffCommissionAmount?: number | null | undefined;
4824
+ netAfterStaff?: number | null | undefined;
4825
+ companyCommissionAmount?: number | null | undefined;
4826
+ investorPool?: number | null | undefined;
4827
+ };
4828
+ currency?: string | undefined;
4829
+ participants?: {
4830
+ userId: string;
4831
+ capitalContributed: number;
4832
+ ownershipPercent: number;
4833
+ earningsAmount: number | null;
4834
+ email?: string | undefined;
4835
+ name?: string | undefined;
4836
+ }[] | undefined;
4837
+ }>;
4838
+ relationships: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
4839
+ links: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
4840
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
4841
+ }, "strip", z.ZodTypeAny, {
4842
+ type: string;
4843
+ id: string;
4844
+ attributes: {
4845
+ status: "cancelled" | "paid" | "draft" | "in_transit" | "invoiced";
4846
+ createdAt: string;
4847
+ updatedAt: string;
4848
+ currency: string;
4849
+ notes: string | null;
4850
+ buyerName: string | null;
4851
+ transportCost: number;
4852
+ organizationId: string;
4853
+ companyCommissionRate: number | null;
4854
+ waybillNumber: string | null;
4855
+ purchaseCost: number;
4856
+ miscellaneousCost: number;
4857
+ invoiceNumber: string | null;
4858
+ waybillId: string;
4859
+ invoiceId: string | null;
4860
+ handlerUserId: string | null;
4861
+ computed: {
4862
+ totalCost: number;
4863
+ saleAmount: number | null;
4864
+ grossProfit: number | null;
4865
+ commissionRate: number | null;
4866
+ commissionAmount: number | null;
4867
+ companyNet: number | null;
4868
+ isRealized: boolean;
4869
+ companyCommissionRate?: number | null | undefined;
4870
+ staffCommissionRate?: number | null | undefined;
4871
+ staffCommissionAmount?: number | null | undefined;
4872
+ netAfterStaff?: number | null | undefined;
4873
+ companyCommissionAmount?: number | null | undefined;
4874
+ investorPool?: number | null | undefined;
4875
+ };
4876
+ participants?: {
4877
+ userId: string;
4878
+ capitalContributed: number;
4879
+ ownershipPercent: number;
4880
+ earningsAmount: number | null;
4881
+ email?: string | undefined;
4882
+ name?: string | undefined;
4883
+ }[] | undefined;
4884
+ };
4885
+ relationships?: Record<string, unknown> | undefined;
4886
+ links?: Record<string, string> | undefined;
4887
+ meta?: Record<string, unknown> | undefined;
4888
+ }, {
4889
+ type: string;
4890
+ id: string;
4891
+ attributes: {
4892
+ status: "cancelled" | "paid" | "draft" | "in_transit" | "invoiced";
4893
+ createdAt: string;
4894
+ updatedAt: string;
4895
+ notes: string | null;
4896
+ buyerName: string | null;
4897
+ transportCost: number;
4898
+ organizationId: string;
4899
+ companyCommissionRate: number | null;
4900
+ waybillNumber: string | null;
4901
+ purchaseCost: number;
4902
+ miscellaneousCost: number;
4903
+ invoiceNumber: string | null;
4904
+ waybillId: string;
4905
+ invoiceId: string | null;
4906
+ handlerUserId: string | null;
4907
+ computed: {
4908
+ totalCost: number;
4909
+ saleAmount: number | null;
4910
+ grossProfit: number | null;
4911
+ commissionRate: number | null;
4912
+ commissionAmount: number | null;
4913
+ companyNet: number | null;
4914
+ isRealized: boolean;
4915
+ companyCommissionRate?: number | null | undefined;
4916
+ staffCommissionRate?: number | null | undefined;
4917
+ staffCommissionAmount?: number | null | undefined;
4918
+ netAfterStaff?: number | null | undefined;
4919
+ companyCommissionAmount?: number | null | undefined;
4920
+ investorPool?: number | null | undefined;
4921
+ };
4922
+ currency?: string | undefined;
4923
+ participants?: {
4924
+ userId: string;
4925
+ capitalContributed: number;
4926
+ ownershipPercent: number;
4927
+ earningsAmount: number | null;
4928
+ email?: string | undefined;
4929
+ name?: string | undefined;
4930
+ }[] | undefined;
4931
+ };
4932
+ relationships?: Record<string, unknown> | undefined;
4933
+ links?: Record<string, string> | undefined;
4934
+ meta?: Record<string, unknown> | undefined;
4935
+ }>;
4936
+ included: z.ZodOptional<z.ZodArray<z.ZodObject<{
4937
+ type: z.ZodString;
4938
+ id: z.ZodString;
4939
+ attributes: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
4940
+ relationships: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
4941
+ links: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
4942
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
4943
+ }, "strip", z.ZodTypeAny, {
4944
+ type: string;
4945
+ id: string;
4946
+ attributes?: Record<string, unknown> | undefined;
4947
+ relationships?: Record<string, unknown> | undefined;
4948
+ links?: Record<string, string> | undefined;
4949
+ meta?: Record<string, unknown> | undefined;
4950
+ }, {
4951
+ type: string;
4952
+ id: string;
4953
+ attributes?: Record<string, unknown> | undefined;
4954
+ relationships?: Record<string, unknown> | undefined;
4955
+ links?: Record<string, string> | undefined;
4956
+ meta?: Record<string, unknown> | undefined;
4957
+ }>, "many">>;
4958
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
4959
+ links: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
4960
+ }, "strip", z.ZodTypeAny, {
4961
+ data: {
4962
+ type: string;
4963
+ id: string;
4964
+ attributes: {
4965
+ status: "cancelled" | "paid" | "draft" | "in_transit" | "invoiced";
4966
+ createdAt: string;
4967
+ updatedAt: string;
4968
+ currency: string;
4969
+ notes: string | null;
4970
+ buyerName: string | null;
4971
+ transportCost: number;
4972
+ organizationId: string;
4973
+ companyCommissionRate: number | null;
4974
+ waybillNumber: string | null;
4975
+ purchaseCost: number;
4976
+ miscellaneousCost: number;
4977
+ invoiceNumber: string | null;
4978
+ waybillId: string;
4979
+ invoiceId: string | null;
4980
+ handlerUserId: string | null;
4981
+ computed: {
4982
+ totalCost: number;
4983
+ saleAmount: number | null;
4984
+ grossProfit: number | null;
4985
+ commissionRate: number | null;
4986
+ commissionAmount: number | null;
4987
+ companyNet: number | null;
4988
+ isRealized: boolean;
4989
+ companyCommissionRate?: number | null | undefined;
4990
+ staffCommissionRate?: number | null | undefined;
4991
+ staffCommissionAmount?: number | null | undefined;
4992
+ netAfterStaff?: number | null | undefined;
4993
+ companyCommissionAmount?: number | null | undefined;
4994
+ investorPool?: number | null | undefined;
4995
+ };
4996
+ participants?: {
4997
+ userId: string;
4998
+ capitalContributed: number;
4999
+ ownershipPercent: number;
5000
+ earningsAmount: number | null;
5001
+ email?: string | undefined;
5002
+ name?: string | undefined;
5003
+ }[] | undefined;
5004
+ };
5005
+ relationships?: Record<string, unknown> | undefined;
5006
+ links?: Record<string, string> | undefined;
5007
+ meta?: Record<string, unknown> | undefined;
5008
+ };
5009
+ links?: Record<string, string> | undefined;
5010
+ meta?: Record<string, unknown> | undefined;
5011
+ included?: {
5012
+ type: string;
5013
+ id: string;
5014
+ attributes?: Record<string, unknown> | undefined;
5015
+ relationships?: Record<string, unknown> | undefined;
5016
+ links?: Record<string, string> | undefined;
5017
+ meta?: Record<string, unknown> | undefined;
5018
+ }[] | undefined;
5019
+ }, {
5020
+ data: {
5021
+ type: string;
5022
+ id: string;
5023
+ attributes: {
5024
+ status: "cancelled" | "paid" | "draft" | "in_transit" | "invoiced";
5025
+ createdAt: string;
5026
+ updatedAt: string;
5027
+ notes: string | null;
5028
+ buyerName: string | null;
5029
+ transportCost: number;
5030
+ organizationId: string;
5031
+ companyCommissionRate: number | null;
5032
+ waybillNumber: string | null;
5033
+ purchaseCost: number;
5034
+ miscellaneousCost: number;
5035
+ invoiceNumber: string | null;
5036
+ waybillId: string;
5037
+ invoiceId: string | null;
5038
+ handlerUserId: string | null;
5039
+ computed: {
5040
+ totalCost: number;
5041
+ saleAmount: number | null;
5042
+ grossProfit: number | null;
5043
+ commissionRate: number | null;
5044
+ commissionAmount: number | null;
5045
+ companyNet: number | null;
5046
+ isRealized: boolean;
5047
+ companyCommissionRate?: number | null | undefined;
5048
+ staffCommissionRate?: number | null | undefined;
5049
+ staffCommissionAmount?: number | null | undefined;
5050
+ netAfterStaff?: number | null | undefined;
5051
+ companyCommissionAmount?: number | null | undefined;
5052
+ investorPool?: number | null | undefined;
5053
+ };
5054
+ currency?: string | undefined;
5055
+ participants?: {
5056
+ userId: string;
5057
+ capitalContributed: number;
5058
+ ownershipPercent: number;
5059
+ earningsAmount: number | null;
5060
+ email?: string | undefined;
5061
+ name?: string | undefined;
5062
+ }[] | undefined;
5063
+ };
5064
+ relationships?: Record<string, unknown> | undefined;
5065
+ links?: Record<string, string> | undefined;
5066
+ meta?: Record<string, unknown> | undefined;
5067
+ };
5068
+ links?: Record<string, string> | undefined;
5069
+ meta?: Record<string, unknown> | undefined;
5070
+ included?: {
5071
+ type: string;
5072
+ id: string;
5073
+ attributes?: Record<string, unknown> | undefined;
5074
+ relationships?: Record<string, unknown> | undefined;
5075
+ links?: Record<string, string> | undefined;
5076
+ meta?: Record<string, unknown> | undefined;
5077
+ }[] | undefined;
5078
+ }>;
5079
+ 400: z.ZodObject<{
5080
+ errors: z.ZodArray<z.ZodObject<{
5081
+ id: z.ZodOptional<z.ZodString>;
5082
+ links: z.ZodOptional<z.ZodObject<{
5083
+ about: z.ZodOptional<z.ZodString>;
5084
+ }, "strip", z.ZodTypeAny, {
5085
+ about?: string | undefined;
5086
+ }, {
5087
+ about?: string | undefined;
5088
+ }>>;
5089
+ status: z.ZodOptional<z.ZodString>;
5090
+ code: z.ZodOptional<z.ZodString>;
5091
+ title: z.ZodOptional<z.ZodString>;
5092
+ detail: z.ZodOptional<z.ZodString>;
5093
+ source: z.ZodOptional<z.ZodObject<{
5094
+ pointer: z.ZodOptional<z.ZodString>;
5095
+ parameter: z.ZodOptional<z.ZodString>;
5096
+ }, "strip", z.ZodTypeAny, {
5097
+ pointer?: string | undefined;
5098
+ parameter?: string | undefined;
5099
+ }, {
5100
+ pointer?: string | undefined;
5101
+ parameter?: string | undefined;
5102
+ }>>;
5103
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
5104
+ }, "strip", z.ZodTypeAny, {
5105
+ status?: string | undefined;
5106
+ code?: string | undefined;
5107
+ id?: string | undefined;
5108
+ links?: {
5109
+ about?: string | undefined;
5110
+ } | undefined;
5111
+ meta?: Record<string, unknown> | undefined;
5112
+ title?: string | undefined;
5113
+ detail?: string | undefined;
5114
+ source?: {
5115
+ pointer?: string | undefined;
5116
+ parameter?: string | undefined;
5117
+ } | undefined;
5118
+ }, {
5119
+ status?: string | undefined;
5120
+ code?: string | undefined;
5121
+ id?: string | undefined;
5122
+ links?: {
5123
+ about?: string | undefined;
5124
+ } | undefined;
5125
+ meta?: Record<string, unknown> | undefined;
5126
+ title?: string | undefined;
5127
+ detail?: string | undefined;
5128
+ source?: {
5129
+ pointer?: string | undefined;
5130
+ parameter?: string | undefined;
5131
+ } | undefined;
5132
+ }>, "many">;
5133
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
5134
+ }, "strip", z.ZodTypeAny, {
5135
+ errors: {
5136
+ status?: string | undefined;
5137
+ code?: string | undefined;
5138
+ id?: string | undefined;
5139
+ links?: {
5140
+ about?: string | undefined;
5141
+ } | undefined;
5142
+ meta?: Record<string, unknown> | undefined;
5143
+ title?: string | undefined;
5144
+ detail?: string | undefined;
5145
+ source?: {
5146
+ pointer?: string | undefined;
5147
+ parameter?: string | undefined;
5148
+ } | undefined;
5149
+ }[];
5150
+ meta?: Record<string, unknown> | undefined;
5151
+ }, {
5152
+ errors: {
5153
+ status?: string | undefined;
5154
+ code?: string | undefined;
5155
+ id?: string | undefined;
5156
+ links?: {
5157
+ about?: string | undefined;
5158
+ } | undefined;
5159
+ meta?: Record<string, unknown> | undefined;
5160
+ title?: string | undefined;
5161
+ detail?: string | undefined;
5162
+ source?: {
5163
+ pointer?: string | undefined;
5164
+ parameter?: string | undefined;
5165
+ } | undefined;
5166
+ }[];
5167
+ meta?: Record<string, unknown> | undefined;
5168
+ }>;
5169
+ 401: z.ZodObject<{
5170
+ errors: z.ZodArray<z.ZodObject<{
5171
+ id: z.ZodOptional<z.ZodString>;
5172
+ links: z.ZodOptional<z.ZodObject<{
5173
+ about: z.ZodOptional<z.ZodString>;
5174
+ }, "strip", z.ZodTypeAny, {
5175
+ about?: string | undefined;
5176
+ }, {
5177
+ about?: string | undefined;
5178
+ }>>;
5179
+ status: z.ZodOptional<z.ZodString>;
5180
+ code: z.ZodOptional<z.ZodString>;
5181
+ title: z.ZodOptional<z.ZodString>;
5182
+ detail: z.ZodOptional<z.ZodString>;
5183
+ source: z.ZodOptional<z.ZodObject<{
5184
+ pointer: z.ZodOptional<z.ZodString>;
5185
+ parameter: z.ZodOptional<z.ZodString>;
5186
+ }, "strip", z.ZodTypeAny, {
5187
+ pointer?: string | undefined;
5188
+ parameter?: string | undefined;
5189
+ }, {
5190
+ pointer?: string | undefined;
5191
+ parameter?: string | undefined;
5192
+ }>>;
5193
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
5194
+ }, "strip", z.ZodTypeAny, {
5195
+ status?: string | undefined;
5196
+ code?: string | undefined;
5197
+ id?: string | undefined;
5198
+ links?: {
5199
+ about?: string | undefined;
5200
+ } | undefined;
5201
+ meta?: Record<string, unknown> | undefined;
5202
+ title?: string | undefined;
5203
+ detail?: string | undefined;
5204
+ source?: {
5205
+ pointer?: string | undefined;
5206
+ parameter?: string | undefined;
5207
+ } | undefined;
5208
+ }, {
5209
+ status?: string | undefined;
5210
+ code?: string | undefined;
5211
+ id?: string | undefined;
5212
+ links?: {
5213
+ about?: string | undefined;
5214
+ } | undefined;
5215
+ meta?: Record<string, unknown> | undefined;
5216
+ title?: string | undefined;
5217
+ detail?: string | undefined;
5218
+ source?: {
5219
+ pointer?: string | undefined;
5220
+ parameter?: string | undefined;
5221
+ } | undefined;
5222
+ }>, "many">;
5223
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
5224
+ }, "strip", z.ZodTypeAny, {
5225
+ errors: {
5226
+ status?: string | undefined;
5227
+ code?: string | undefined;
5228
+ id?: string | undefined;
5229
+ links?: {
5230
+ about?: string | undefined;
5231
+ } | undefined;
5232
+ meta?: Record<string, unknown> | undefined;
5233
+ title?: string | undefined;
5234
+ detail?: string | undefined;
5235
+ source?: {
5236
+ pointer?: string | undefined;
5237
+ parameter?: string | undefined;
5238
+ } | undefined;
5239
+ }[];
5240
+ meta?: Record<string, unknown> | undefined;
5241
+ }, {
5242
+ errors: {
5243
+ status?: string | undefined;
5244
+ code?: string | undefined;
5245
+ id?: string | undefined;
5246
+ links?: {
5247
+ about?: string | undefined;
5248
+ } | undefined;
5249
+ meta?: Record<string, unknown> | undefined;
5250
+ title?: string | undefined;
5251
+ detail?: string | undefined;
5252
+ source?: {
5253
+ pointer?: string | undefined;
5254
+ parameter?: string | undefined;
5255
+ } | undefined;
5256
+ }[];
5257
+ meta?: Record<string, unknown> | undefined;
5258
+ }>;
5259
+ 403: z.ZodObject<{
5260
+ errors: z.ZodArray<z.ZodObject<{
5261
+ id: z.ZodOptional<z.ZodString>;
5262
+ links: z.ZodOptional<z.ZodObject<{
5263
+ about: z.ZodOptional<z.ZodString>;
5264
+ }, "strip", z.ZodTypeAny, {
5265
+ about?: string | undefined;
5266
+ }, {
5267
+ about?: string | undefined;
5268
+ }>>;
5269
+ status: z.ZodOptional<z.ZodString>;
5270
+ code: z.ZodOptional<z.ZodString>;
5271
+ title: z.ZodOptional<z.ZodString>;
5272
+ detail: z.ZodOptional<z.ZodString>;
5273
+ source: z.ZodOptional<z.ZodObject<{
5274
+ pointer: z.ZodOptional<z.ZodString>;
5275
+ parameter: z.ZodOptional<z.ZodString>;
5276
+ }, "strip", z.ZodTypeAny, {
5277
+ pointer?: string | undefined;
5278
+ parameter?: string | undefined;
5279
+ }, {
5280
+ pointer?: string | undefined;
5281
+ parameter?: string | undefined;
5282
+ }>>;
5283
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
5284
+ }, "strip", z.ZodTypeAny, {
5285
+ status?: string | undefined;
5286
+ code?: string | undefined;
5287
+ id?: string | undefined;
5288
+ links?: {
5289
+ about?: string | undefined;
5290
+ } | undefined;
5291
+ meta?: Record<string, unknown> | undefined;
5292
+ title?: string | undefined;
5293
+ detail?: string | undefined;
5294
+ source?: {
5295
+ pointer?: string | undefined;
5296
+ parameter?: string | undefined;
5297
+ } | undefined;
5298
+ }, {
5299
+ status?: string | undefined;
5300
+ code?: string | undefined;
5301
+ id?: string | undefined;
5302
+ links?: {
5303
+ about?: string | undefined;
5304
+ } | undefined;
5305
+ meta?: Record<string, unknown> | undefined;
5306
+ title?: string | undefined;
5307
+ detail?: string | undefined;
5308
+ source?: {
5309
+ pointer?: string | undefined;
5310
+ parameter?: string | undefined;
5311
+ } | undefined;
5312
+ }>, "many">;
5313
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
5314
+ }, "strip", z.ZodTypeAny, {
5315
+ errors: {
5316
+ status?: string | undefined;
5317
+ code?: string | undefined;
5318
+ id?: string | undefined;
5319
+ links?: {
5320
+ about?: string | undefined;
5321
+ } | undefined;
5322
+ meta?: Record<string, unknown> | undefined;
5323
+ title?: string | undefined;
5324
+ detail?: string | undefined;
5325
+ source?: {
5326
+ pointer?: string | undefined;
5327
+ parameter?: string | undefined;
5328
+ } | undefined;
5329
+ }[];
5330
+ meta?: Record<string, unknown> | undefined;
5331
+ }, {
5332
+ errors: {
5333
+ status?: string | undefined;
5334
+ code?: string | undefined;
5335
+ id?: string | undefined;
5336
+ links?: {
5337
+ about?: string | undefined;
5338
+ } | undefined;
5339
+ meta?: Record<string, unknown> | undefined;
5340
+ title?: string | undefined;
5341
+ detail?: string | undefined;
5342
+ source?: {
5343
+ pointer?: string | undefined;
5344
+ parameter?: string | undefined;
5345
+ } | undefined;
5346
+ }[];
5347
+ meta?: Record<string, unknown> | undefined;
5348
+ }>;
5349
+ 404: z.ZodObject<{
5350
+ errors: z.ZodArray<z.ZodObject<{
5351
+ id: z.ZodOptional<z.ZodString>;
5352
+ links: z.ZodOptional<z.ZodObject<{
5353
+ about: z.ZodOptional<z.ZodString>;
5354
+ }, "strip", z.ZodTypeAny, {
5355
+ about?: string | undefined;
5356
+ }, {
5357
+ about?: string | undefined;
5358
+ }>>;
5359
+ status: z.ZodOptional<z.ZodString>;
5360
+ code: z.ZodOptional<z.ZodString>;
5361
+ title: z.ZodOptional<z.ZodString>;
5362
+ detail: z.ZodOptional<z.ZodString>;
5363
+ source: z.ZodOptional<z.ZodObject<{
5364
+ pointer: z.ZodOptional<z.ZodString>;
5365
+ parameter: z.ZodOptional<z.ZodString>;
5366
+ }, "strip", z.ZodTypeAny, {
5367
+ pointer?: string | undefined;
5368
+ parameter?: string | undefined;
5369
+ }, {
5370
+ pointer?: string | undefined;
5371
+ parameter?: string | undefined;
5372
+ }>>;
5373
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
5374
+ }, "strip", z.ZodTypeAny, {
5375
+ status?: string | undefined;
5376
+ code?: string | undefined;
5377
+ id?: string | undefined;
5378
+ links?: {
5379
+ about?: string | undefined;
5380
+ } | undefined;
5381
+ meta?: Record<string, unknown> | undefined;
5382
+ title?: string | undefined;
5383
+ detail?: string | undefined;
5384
+ source?: {
5385
+ pointer?: string | undefined;
5386
+ parameter?: string | undefined;
5387
+ } | undefined;
5388
+ }, {
5389
+ status?: string | undefined;
5390
+ code?: string | undefined;
5391
+ id?: string | undefined;
5392
+ links?: {
5393
+ about?: string | undefined;
5394
+ } | undefined;
5395
+ meta?: Record<string, unknown> | undefined;
5396
+ title?: string | undefined;
5397
+ detail?: string | undefined;
5398
+ source?: {
5399
+ pointer?: string | undefined;
5400
+ parameter?: string | undefined;
5401
+ } | undefined;
5402
+ }>, "many">;
5403
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
5404
+ }, "strip", z.ZodTypeAny, {
5405
+ errors: {
5406
+ status?: string | undefined;
5407
+ code?: string | undefined;
5408
+ id?: string | undefined;
5409
+ links?: {
5410
+ about?: string | undefined;
5411
+ } | undefined;
5412
+ meta?: Record<string, unknown> | undefined;
5413
+ title?: string | undefined;
5414
+ detail?: string | undefined;
5415
+ source?: {
5416
+ pointer?: string | undefined;
5417
+ parameter?: string | undefined;
5418
+ } | undefined;
5419
+ }[];
5420
+ meta?: Record<string, unknown> | undefined;
5421
+ }, {
5422
+ errors: {
5423
+ status?: string | undefined;
5424
+ code?: string | undefined;
5425
+ id?: string | undefined;
5426
+ links?: {
5427
+ about?: string | undefined;
5428
+ } | undefined;
5429
+ meta?: Record<string, unknown> | undefined;
5430
+ title?: string | undefined;
5431
+ detail?: string | undefined;
5432
+ source?: {
5433
+ pointer?: string | undefined;
5434
+ parameter?: string | undefined;
5435
+ } | undefined;
5436
+ }[];
5437
+ meta?: Record<string, unknown> | undefined;
5438
+ }>;
5439
+ 422: z.ZodObject<{
5440
+ errors: z.ZodArray<z.ZodObject<{
5441
+ id: z.ZodOptional<z.ZodString>;
5442
+ links: z.ZodOptional<z.ZodObject<{
5443
+ about: z.ZodOptional<z.ZodString>;
5444
+ }, "strip", z.ZodTypeAny, {
5445
+ about?: string | undefined;
5446
+ }, {
5447
+ about?: string | undefined;
5448
+ }>>;
5449
+ status: z.ZodOptional<z.ZodString>;
5450
+ code: z.ZodOptional<z.ZodString>;
5451
+ title: z.ZodOptional<z.ZodString>;
5452
+ detail: z.ZodOptional<z.ZodString>;
5453
+ source: z.ZodOptional<z.ZodObject<{
5454
+ pointer: z.ZodOptional<z.ZodString>;
5455
+ parameter: z.ZodOptional<z.ZodString>;
5456
+ }, "strip", z.ZodTypeAny, {
5457
+ pointer?: string | undefined;
5458
+ parameter?: string | undefined;
5459
+ }, {
5460
+ pointer?: string | undefined;
5461
+ parameter?: string | undefined;
5462
+ }>>;
5463
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
5464
+ }, "strip", z.ZodTypeAny, {
5465
+ status?: string | undefined;
5466
+ code?: string | undefined;
5467
+ id?: string | undefined;
5468
+ links?: {
5469
+ about?: string | undefined;
5470
+ } | undefined;
5471
+ meta?: Record<string, unknown> | undefined;
5472
+ title?: string | undefined;
5473
+ detail?: string | undefined;
5474
+ source?: {
5475
+ pointer?: string | undefined;
5476
+ parameter?: string | undefined;
5477
+ } | undefined;
5478
+ }, {
5479
+ status?: string | undefined;
5480
+ code?: string | undefined;
5481
+ id?: string | undefined;
5482
+ links?: {
5483
+ about?: string | undefined;
5484
+ } | undefined;
5485
+ meta?: Record<string, unknown> | undefined;
5486
+ title?: string | undefined;
5487
+ detail?: string | undefined;
5488
+ source?: {
5489
+ pointer?: string | undefined;
5490
+ parameter?: string | undefined;
5491
+ } | undefined;
5492
+ }>, "many">;
5493
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
5494
+ }, "strip", z.ZodTypeAny, {
5495
+ errors: {
5496
+ status?: string | undefined;
5497
+ code?: string | undefined;
5498
+ id?: string | undefined;
5499
+ links?: {
5500
+ about?: string | undefined;
5501
+ } | undefined;
5502
+ meta?: Record<string, unknown> | undefined;
5503
+ title?: string | undefined;
5504
+ detail?: string | undefined;
5505
+ source?: {
5506
+ pointer?: string | undefined;
5507
+ parameter?: string | undefined;
5508
+ } | undefined;
5509
+ }[];
5510
+ meta?: Record<string, unknown> | undefined;
5511
+ }, {
5512
+ errors: {
5513
+ status?: string | undefined;
5514
+ code?: string | undefined;
5515
+ id?: string | undefined;
5516
+ links?: {
5517
+ about?: string | undefined;
5518
+ } | undefined;
5519
+ meta?: Record<string, unknown> | undefined;
5520
+ title?: string | undefined;
5521
+ detail?: string | undefined;
5522
+ source?: {
5523
+ pointer?: string | undefined;
5524
+ parameter?: string | undefined;
5525
+ } | undefined;
5526
+ }[];
5527
+ meta?: Record<string, unknown> | undefined;
5528
+ }>;
5529
+ };
5530
+ };
5531
+ removeDealParticipant: {
5532
+ pathParams: z.ZodObject<{
5533
+ organizationId: z.ZodString;
5534
+ id: z.ZodString;
5535
+ participantId: z.ZodString;
5536
+ }, "strip", z.ZodTypeAny, {
5537
+ id: string;
5538
+ organizationId: string;
5539
+ participantId: string;
5540
+ }, {
5541
+ id: string;
5542
+ organizationId: string;
5543
+ participantId: string;
5544
+ }>;
5545
+ summary: "Remove a participant from a commodity deal";
5546
+ method: "DELETE";
5547
+ path: "/organizations/:organizationId/commodity-deals/:id/participants/:participantId";
5548
+ responses: {
5549
+ 200: z.ZodObject<{
5550
+ data: z.ZodObject<{
5551
+ type: z.ZodLiteral<string>;
5552
+ id: z.ZodString;
5553
+ attributes: z.ZodObject<{
5554
+ organizationId: z.ZodString;
5555
+ waybillId: z.ZodString;
5556
+ invoiceId: z.ZodNullable<z.ZodString>;
5557
+ handlerUserId: z.ZodNullable<z.ZodString>;
5558
+ waybillNumber: z.ZodNullable<z.ZodString>;
5559
+ invoiceNumber: z.ZodNullable<z.ZodString>;
5560
+ buyerName: z.ZodNullable<z.ZodString>;
5561
+ purchaseCost: z.ZodNumber;
5562
+ transportCost: z.ZodNumber;
5563
+ miscellaneousCost: z.ZodNumber;
5564
+ currency: z.ZodDefault<z.ZodString>;
5565
+ status: z.ZodEnum<["draft", "in_transit", "invoiced", "paid", "cancelled"]>;
5566
+ notes: z.ZodNullable<z.ZodString>;
5567
+ companyCommissionRate: z.ZodNullable<z.ZodNumber>;
5568
+ participants: z.ZodOptional<z.ZodArray<z.ZodObject<{
5569
+ userId: z.ZodString;
5570
+ name: z.ZodOptional<z.ZodString>;
5571
+ email: z.ZodOptional<z.ZodString>;
5572
+ capitalContributed: z.ZodNumber;
5573
+ ownershipPercent: z.ZodNumber;
5574
+ earningsAmount: z.ZodNullable<z.ZodNumber>;
5575
+ }, "strip", z.ZodTypeAny, {
5576
+ userId: string;
5577
+ capitalContributed: number;
5578
+ ownershipPercent: number;
5579
+ earningsAmount: number | null;
5580
+ email?: string | undefined;
5581
+ name?: string | undefined;
5582
+ }, {
5583
+ userId: string;
5584
+ capitalContributed: number;
5585
+ ownershipPercent: number;
5586
+ earningsAmount: number | null;
5587
+ email?: string | undefined;
5588
+ name?: string | undefined;
5589
+ }>, "many">>;
5590
+ computed: z.ZodObject<{
5591
+ totalCost: z.ZodNumber;
5592
+ saleAmount: z.ZodNullable<z.ZodNumber>;
5593
+ grossProfit: z.ZodNullable<z.ZodNumber>;
5594
+ commissionRate: z.ZodNullable<z.ZodNumber>;
5595
+ staffCommissionRate: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
5596
+ commissionAmount: z.ZodNullable<z.ZodNumber>;
5597
+ staffCommissionAmount: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
5598
+ companyNet: z.ZodNullable<z.ZodNumber>;
5599
+ netAfterStaff: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
5600
+ companyCommissionRate: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
5601
+ companyCommissionAmount: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
5602
+ investorPool: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
5603
+ isRealized: z.ZodBoolean;
5604
+ }, "strip", z.ZodTypeAny, {
5605
+ totalCost: number;
5606
+ saleAmount: number | null;
5607
+ grossProfit: number | null;
5608
+ commissionRate: number | null;
5609
+ commissionAmount: number | null;
5610
+ companyNet: number | null;
5611
+ isRealized: boolean;
5612
+ companyCommissionRate?: number | null | undefined;
5613
+ staffCommissionRate?: number | null | undefined;
5614
+ staffCommissionAmount?: number | null | undefined;
5615
+ netAfterStaff?: number | null | undefined;
5616
+ companyCommissionAmount?: number | null | undefined;
5617
+ investorPool?: number | null | undefined;
5618
+ }, {
5619
+ totalCost: number;
5620
+ saleAmount: number | null;
5621
+ grossProfit: number | null;
5622
+ commissionRate: number | null;
5623
+ commissionAmount: number | null;
5624
+ companyNet: number | null;
5625
+ isRealized: boolean;
5626
+ companyCommissionRate?: number | null | undefined;
5627
+ staffCommissionRate?: number | null | undefined;
5628
+ staffCommissionAmount?: number | null | undefined;
5629
+ netAfterStaff?: number | null | undefined;
5630
+ companyCommissionAmount?: number | null | undefined;
5631
+ investorPool?: number | null | undefined;
5632
+ }>;
5633
+ } & {
5634
+ createdAt: z.ZodString;
5635
+ updatedAt: z.ZodString;
5636
+ }, "strip", z.ZodTypeAny, {
5637
+ status: "cancelled" | "paid" | "draft" | "in_transit" | "invoiced";
5638
+ createdAt: string;
5639
+ updatedAt: string;
5640
+ currency: string;
5641
+ notes: string | null;
5642
+ buyerName: string | null;
5643
+ transportCost: number;
5644
+ organizationId: string;
5645
+ companyCommissionRate: number | null;
5646
+ waybillNumber: string | null;
5647
+ purchaseCost: number;
5648
+ miscellaneousCost: number;
5649
+ invoiceNumber: string | null;
5650
+ waybillId: string;
5651
+ invoiceId: string | null;
5652
+ handlerUserId: string | null;
5653
+ computed: {
5654
+ totalCost: number;
5655
+ saleAmount: number | null;
5656
+ grossProfit: number | null;
5657
+ commissionRate: number | null;
5658
+ commissionAmount: number | null;
5659
+ companyNet: number | null;
5660
+ isRealized: boolean;
5661
+ companyCommissionRate?: number | null | undefined;
5662
+ staffCommissionRate?: number | null | undefined;
5663
+ staffCommissionAmount?: number | null | undefined;
5664
+ netAfterStaff?: number | null | undefined;
5665
+ companyCommissionAmount?: number | null | undefined;
5666
+ investorPool?: number | null | undefined;
5667
+ };
5668
+ participants?: {
5669
+ userId: string;
5670
+ capitalContributed: number;
5671
+ ownershipPercent: number;
5672
+ earningsAmount: number | null;
5673
+ email?: string | undefined;
5674
+ name?: string | undefined;
5675
+ }[] | undefined;
5676
+ }, {
5677
+ status: "cancelled" | "paid" | "draft" | "in_transit" | "invoiced";
5678
+ createdAt: string;
5679
+ updatedAt: string;
5680
+ notes: string | null;
5681
+ buyerName: string | null;
5682
+ transportCost: number;
5683
+ organizationId: string;
5684
+ companyCommissionRate: number | null;
5685
+ waybillNumber: string | null;
5686
+ purchaseCost: number;
5687
+ miscellaneousCost: number;
5688
+ invoiceNumber: string | null;
5689
+ waybillId: string;
5690
+ invoiceId: string | null;
5691
+ handlerUserId: string | null;
5692
+ computed: {
5693
+ totalCost: number;
5694
+ saleAmount: number | null;
5695
+ grossProfit: number | null;
5696
+ commissionRate: number | null;
5697
+ commissionAmount: number | null;
5698
+ companyNet: number | null;
5699
+ isRealized: boolean;
5700
+ companyCommissionRate?: number | null | undefined;
5701
+ staffCommissionRate?: number | null | undefined;
5702
+ staffCommissionAmount?: number | null | undefined;
5703
+ netAfterStaff?: number | null | undefined;
5704
+ companyCommissionAmount?: number | null | undefined;
5705
+ investorPool?: number | null | undefined;
5706
+ };
5707
+ currency?: string | undefined;
5708
+ participants?: {
5709
+ userId: string;
5710
+ capitalContributed: number;
5711
+ ownershipPercent: number;
5712
+ earningsAmount: number | null;
5713
+ email?: string | undefined;
5714
+ name?: string | undefined;
5715
+ }[] | undefined;
5716
+ }>;
5717
+ relationships: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
5718
+ links: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
5719
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
5720
+ }, "strip", z.ZodTypeAny, {
5721
+ type: string;
5722
+ id: string;
5723
+ attributes: {
5724
+ status: "cancelled" | "paid" | "draft" | "in_transit" | "invoiced";
5725
+ createdAt: string;
5726
+ updatedAt: string;
5727
+ currency: string;
5728
+ notes: string | null;
5729
+ buyerName: string | null;
5730
+ transportCost: number;
5731
+ organizationId: string;
5732
+ companyCommissionRate: number | null;
5733
+ waybillNumber: string | null;
5734
+ purchaseCost: number;
5735
+ miscellaneousCost: number;
5736
+ invoiceNumber: string | null;
5737
+ waybillId: string;
5738
+ invoiceId: string | null;
5739
+ handlerUserId: string | null;
5740
+ computed: {
5741
+ totalCost: number;
5742
+ saleAmount: number | null;
5743
+ grossProfit: number | null;
5744
+ commissionRate: number | null;
5745
+ commissionAmount: number | null;
5746
+ companyNet: number | null;
5747
+ isRealized: boolean;
5748
+ companyCommissionRate?: number | null | undefined;
5749
+ staffCommissionRate?: number | null | undefined;
5750
+ staffCommissionAmount?: number | null | undefined;
5751
+ netAfterStaff?: number | null | undefined;
5752
+ companyCommissionAmount?: number | null | undefined;
5753
+ investorPool?: number | null | undefined;
5754
+ };
5755
+ participants?: {
5756
+ userId: string;
5757
+ capitalContributed: number;
5758
+ ownershipPercent: number;
5759
+ earningsAmount: number | null;
5760
+ email?: string | undefined;
5761
+ name?: string | undefined;
5762
+ }[] | undefined;
5763
+ };
5764
+ relationships?: Record<string, unknown> | undefined;
5765
+ links?: Record<string, string> | undefined;
5766
+ meta?: Record<string, unknown> | undefined;
5767
+ }, {
5768
+ type: string;
5769
+ id: string;
5770
+ attributes: {
5771
+ status: "cancelled" | "paid" | "draft" | "in_transit" | "invoiced";
5772
+ createdAt: string;
5773
+ updatedAt: string;
5774
+ notes: string | null;
5775
+ buyerName: string | null;
5776
+ transportCost: number;
5777
+ organizationId: string;
5778
+ companyCommissionRate: number | null;
5779
+ waybillNumber: string | null;
5780
+ purchaseCost: number;
5781
+ miscellaneousCost: number;
5782
+ invoiceNumber: string | null;
5783
+ waybillId: string;
5784
+ invoiceId: string | null;
5785
+ handlerUserId: string | null;
5786
+ computed: {
5787
+ totalCost: number;
5788
+ saleAmount: number | null;
5789
+ grossProfit: number | null;
5790
+ commissionRate: number | null;
5791
+ commissionAmount: number | null;
5792
+ companyNet: number | null;
5793
+ isRealized: boolean;
5794
+ companyCommissionRate?: number | null | undefined;
5795
+ staffCommissionRate?: number | null | undefined;
5796
+ staffCommissionAmount?: number | null | undefined;
5797
+ netAfterStaff?: number | null | undefined;
5798
+ companyCommissionAmount?: number | null | undefined;
5799
+ investorPool?: number | null | undefined;
5800
+ };
5801
+ currency?: string | undefined;
5802
+ participants?: {
5803
+ userId: string;
5804
+ capitalContributed: number;
5805
+ ownershipPercent: number;
5806
+ earningsAmount: number | null;
5807
+ email?: string | undefined;
5808
+ name?: string | undefined;
5809
+ }[] | undefined;
5810
+ };
5811
+ relationships?: Record<string, unknown> | undefined;
5812
+ links?: Record<string, string> | undefined;
5813
+ meta?: Record<string, unknown> | undefined;
5814
+ }>;
5815
+ included: z.ZodOptional<z.ZodArray<z.ZodObject<{
5816
+ type: z.ZodString;
5817
+ id: z.ZodString;
5818
+ attributes: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
5819
+ relationships: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
5820
+ links: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
5821
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
5822
+ }, "strip", z.ZodTypeAny, {
5823
+ type: string;
5824
+ id: string;
5825
+ attributes?: Record<string, unknown> | undefined;
5826
+ relationships?: Record<string, unknown> | undefined;
5827
+ links?: Record<string, string> | undefined;
5828
+ meta?: Record<string, unknown> | undefined;
5829
+ }, {
5830
+ type: string;
5831
+ id: string;
5832
+ attributes?: Record<string, unknown> | undefined;
5833
+ relationships?: Record<string, unknown> | undefined;
5834
+ links?: Record<string, string> | undefined;
5835
+ meta?: Record<string, unknown> | undefined;
5836
+ }>, "many">>;
5837
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
5838
+ links: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
5839
+ }, "strip", z.ZodTypeAny, {
5840
+ data: {
5841
+ type: string;
5842
+ id: string;
5843
+ attributes: {
5844
+ status: "cancelled" | "paid" | "draft" | "in_transit" | "invoiced";
5845
+ createdAt: string;
5846
+ updatedAt: string;
5847
+ currency: string;
5848
+ notes: string | null;
5849
+ buyerName: string | null;
5850
+ transportCost: number;
5851
+ organizationId: string;
5852
+ companyCommissionRate: number | null;
5853
+ waybillNumber: string | null;
5854
+ purchaseCost: number;
5855
+ miscellaneousCost: number;
5856
+ invoiceNumber: string | null;
5857
+ waybillId: string;
5858
+ invoiceId: string | null;
5859
+ handlerUserId: string | null;
5860
+ computed: {
5861
+ totalCost: number;
5862
+ saleAmount: number | null;
5863
+ grossProfit: number | null;
5864
+ commissionRate: number | null;
5865
+ commissionAmount: number | null;
5866
+ companyNet: number | null;
5867
+ isRealized: boolean;
5868
+ companyCommissionRate?: number | null | undefined;
5869
+ staffCommissionRate?: number | null | undefined;
5870
+ staffCommissionAmount?: number | null | undefined;
5871
+ netAfterStaff?: number | null | undefined;
5872
+ companyCommissionAmount?: number | null | undefined;
5873
+ investorPool?: number | null | undefined;
5874
+ };
5875
+ participants?: {
5876
+ userId: string;
5877
+ capitalContributed: number;
5878
+ ownershipPercent: number;
5879
+ earningsAmount: number | null;
5880
+ email?: string | undefined;
5881
+ name?: string | undefined;
5882
+ }[] | undefined;
5883
+ };
5884
+ relationships?: Record<string, unknown> | undefined;
5885
+ links?: Record<string, string> | undefined;
5886
+ meta?: Record<string, unknown> | undefined;
5887
+ };
5888
+ links?: Record<string, string> | undefined;
5889
+ meta?: Record<string, unknown> | undefined;
5890
+ included?: {
5891
+ type: string;
5892
+ id: string;
5893
+ attributes?: Record<string, unknown> | undefined;
5894
+ relationships?: Record<string, unknown> | undefined;
5895
+ links?: Record<string, string> | undefined;
5896
+ meta?: Record<string, unknown> | undefined;
5897
+ }[] | undefined;
5898
+ }, {
5899
+ data: {
5900
+ type: string;
5901
+ id: string;
5902
+ attributes: {
5903
+ status: "cancelled" | "paid" | "draft" | "in_transit" | "invoiced";
5904
+ createdAt: string;
5905
+ updatedAt: string;
5906
+ notes: string | null;
5907
+ buyerName: string | null;
5908
+ transportCost: number;
5909
+ organizationId: string;
5910
+ companyCommissionRate: number | null;
5911
+ waybillNumber: string | null;
5912
+ purchaseCost: number;
5913
+ miscellaneousCost: number;
5914
+ invoiceNumber: string | null;
5915
+ waybillId: string;
5916
+ invoiceId: string | null;
5917
+ handlerUserId: string | null;
5918
+ computed: {
5919
+ totalCost: number;
5920
+ saleAmount: number | null;
5921
+ grossProfit: number | null;
5922
+ commissionRate: number | null;
5923
+ commissionAmount: number | null;
5924
+ companyNet: number | null;
5925
+ isRealized: boolean;
5926
+ companyCommissionRate?: number | null | undefined;
5927
+ staffCommissionRate?: number | null | undefined;
5928
+ staffCommissionAmount?: number | null | undefined;
5929
+ netAfterStaff?: number | null | undefined;
5930
+ companyCommissionAmount?: number | null | undefined;
5931
+ investorPool?: number | null | undefined;
5932
+ };
5933
+ currency?: string | undefined;
5934
+ participants?: {
5935
+ userId: string;
5936
+ capitalContributed: number;
5937
+ ownershipPercent: number;
5938
+ earningsAmount: number | null;
5939
+ email?: string | undefined;
5940
+ name?: string | undefined;
5941
+ }[] | undefined;
5942
+ };
5943
+ relationships?: Record<string, unknown> | undefined;
5944
+ links?: Record<string, string> | undefined;
5945
+ meta?: Record<string, unknown> | undefined;
5946
+ };
5947
+ links?: Record<string, string> | undefined;
5948
+ meta?: Record<string, unknown> | undefined;
5949
+ included?: {
5950
+ type: string;
5951
+ id: string;
5952
+ attributes?: Record<string, unknown> | undefined;
5953
+ relationships?: Record<string, unknown> | undefined;
5954
+ links?: Record<string, string> | undefined;
5955
+ meta?: Record<string, unknown> | undefined;
5956
+ }[] | undefined;
5957
+ }>;
5958
+ 400: z.ZodObject<{
5959
+ errors: z.ZodArray<z.ZodObject<{
5960
+ id: z.ZodOptional<z.ZodString>;
5961
+ links: z.ZodOptional<z.ZodObject<{
5962
+ about: z.ZodOptional<z.ZodString>;
5963
+ }, "strip", z.ZodTypeAny, {
5964
+ about?: string | undefined;
5965
+ }, {
5966
+ about?: string | undefined;
5967
+ }>>;
5968
+ status: z.ZodOptional<z.ZodString>;
5969
+ code: z.ZodOptional<z.ZodString>;
5970
+ title: z.ZodOptional<z.ZodString>;
5971
+ detail: z.ZodOptional<z.ZodString>;
5972
+ source: z.ZodOptional<z.ZodObject<{
5973
+ pointer: z.ZodOptional<z.ZodString>;
5974
+ parameter: z.ZodOptional<z.ZodString>;
5975
+ }, "strip", z.ZodTypeAny, {
5976
+ pointer?: string | undefined;
5977
+ parameter?: string | undefined;
5978
+ }, {
5979
+ pointer?: string | undefined;
5980
+ parameter?: string | undefined;
5981
+ }>>;
5982
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
5983
+ }, "strip", z.ZodTypeAny, {
5984
+ status?: string | undefined;
5985
+ code?: string | undefined;
5986
+ id?: string | undefined;
5987
+ links?: {
5988
+ about?: string | undefined;
5989
+ } | undefined;
5990
+ meta?: Record<string, unknown> | undefined;
5991
+ title?: string | undefined;
5992
+ detail?: string | undefined;
5993
+ source?: {
5994
+ pointer?: string | undefined;
5995
+ parameter?: string | undefined;
5996
+ } | undefined;
5997
+ }, {
5998
+ status?: string | undefined;
5999
+ code?: string | undefined;
6000
+ id?: string | undefined;
6001
+ links?: {
6002
+ about?: string | undefined;
6003
+ } | undefined;
6004
+ meta?: Record<string, unknown> | undefined;
6005
+ title?: string | undefined;
6006
+ detail?: string | undefined;
6007
+ source?: {
6008
+ pointer?: string | undefined;
6009
+ parameter?: string | undefined;
6010
+ } | undefined;
6011
+ }>, "many">;
6012
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
6013
+ }, "strip", z.ZodTypeAny, {
6014
+ errors: {
6015
+ status?: string | undefined;
6016
+ code?: string | undefined;
6017
+ id?: string | undefined;
6018
+ links?: {
6019
+ about?: string | undefined;
6020
+ } | undefined;
6021
+ meta?: Record<string, unknown> | undefined;
6022
+ title?: string | undefined;
6023
+ detail?: string | undefined;
6024
+ source?: {
6025
+ pointer?: string | undefined;
6026
+ parameter?: string | undefined;
6027
+ } | undefined;
6028
+ }[];
6029
+ meta?: Record<string, unknown> | undefined;
6030
+ }, {
6031
+ errors: {
6032
+ status?: string | undefined;
6033
+ code?: string | undefined;
6034
+ id?: string | undefined;
6035
+ links?: {
6036
+ about?: string | undefined;
6037
+ } | undefined;
6038
+ meta?: Record<string, unknown> | undefined;
6039
+ title?: string | undefined;
6040
+ detail?: string | undefined;
6041
+ source?: {
6042
+ pointer?: string | undefined;
6043
+ parameter?: string | undefined;
6044
+ } | undefined;
6045
+ }[];
6046
+ meta?: Record<string, unknown> | undefined;
6047
+ }>;
6048
+ 401: z.ZodObject<{
6049
+ errors: z.ZodArray<z.ZodObject<{
6050
+ id: z.ZodOptional<z.ZodString>;
6051
+ links: z.ZodOptional<z.ZodObject<{
6052
+ about: z.ZodOptional<z.ZodString>;
6053
+ }, "strip", z.ZodTypeAny, {
6054
+ about?: string | undefined;
6055
+ }, {
6056
+ about?: string | undefined;
6057
+ }>>;
6058
+ status: z.ZodOptional<z.ZodString>;
6059
+ code: z.ZodOptional<z.ZodString>;
6060
+ title: z.ZodOptional<z.ZodString>;
6061
+ detail: z.ZodOptional<z.ZodString>;
6062
+ source: z.ZodOptional<z.ZodObject<{
6063
+ pointer: z.ZodOptional<z.ZodString>;
6064
+ parameter: z.ZodOptional<z.ZodString>;
6065
+ }, "strip", z.ZodTypeAny, {
6066
+ pointer?: string | undefined;
6067
+ parameter?: string | undefined;
6068
+ }, {
6069
+ pointer?: string | undefined;
6070
+ parameter?: string | undefined;
6071
+ }>>;
6072
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
6073
+ }, "strip", z.ZodTypeAny, {
6074
+ status?: string | undefined;
6075
+ code?: string | undefined;
6076
+ id?: string | undefined;
6077
+ links?: {
6078
+ about?: string | undefined;
6079
+ } | undefined;
6080
+ meta?: Record<string, unknown> | undefined;
6081
+ title?: string | undefined;
6082
+ detail?: string | undefined;
6083
+ source?: {
6084
+ pointer?: string | undefined;
6085
+ parameter?: string | undefined;
6086
+ } | undefined;
6087
+ }, {
6088
+ status?: string | undefined;
6089
+ code?: string | undefined;
6090
+ id?: string | undefined;
6091
+ links?: {
6092
+ about?: string | undefined;
6093
+ } | undefined;
6094
+ meta?: Record<string, unknown> | undefined;
6095
+ title?: string | undefined;
6096
+ detail?: string | undefined;
6097
+ source?: {
6098
+ pointer?: string | undefined;
6099
+ parameter?: string | undefined;
6100
+ } | undefined;
6101
+ }>, "many">;
6102
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
6103
+ }, "strip", z.ZodTypeAny, {
6104
+ errors: {
6105
+ status?: string | undefined;
6106
+ code?: string | undefined;
6107
+ id?: string | undefined;
6108
+ links?: {
6109
+ about?: string | undefined;
6110
+ } | undefined;
6111
+ meta?: Record<string, unknown> | undefined;
6112
+ title?: string | undefined;
6113
+ detail?: string | undefined;
6114
+ source?: {
6115
+ pointer?: string | undefined;
6116
+ parameter?: string | undefined;
6117
+ } | undefined;
6118
+ }[];
6119
+ meta?: Record<string, unknown> | undefined;
6120
+ }, {
6121
+ errors: {
6122
+ status?: string | undefined;
6123
+ code?: string | undefined;
6124
+ id?: string | undefined;
6125
+ links?: {
6126
+ about?: string | undefined;
6127
+ } | undefined;
6128
+ meta?: Record<string, unknown> | undefined;
6129
+ title?: string | undefined;
6130
+ detail?: string | undefined;
6131
+ source?: {
6132
+ pointer?: string | undefined;
6133
+ parameter?: string | undefined;
6134
+ } | undefined;
6135
+ }[];
6136
+ meta?: Record<string, unknown> | undefined;
6137
+ }>;
6138
+ 403: z.ZodObject<{
6139
+ errors: z.ZodArray<z.ZodObject<{
6140
+ id: z.ZodOptional<z.ZodString>;
6141
+ links: z.ZodOptional<z.ZodObject<{
6142
+ about: z.ZodOptional<z.ZodString>;
6143
+ }, "strip", z.ZodTypeAny, {
6144
+ about?: string | undefined;
6145
+ }, {
6146
+ about?: string | undefined;
6147
+ }>>;
6148
+ status: z.ZodOptional<z.ZodString>;
6149
+ code: z.ZodOptional<z.ZodString>;
6150
+ title: z.ZodOptional<z.ZodString>;
6151
+ detail: z.ZodOptional<z.ZodString>;
6152
+ source: z.ZodOptional<z.ZodObject<{
6153
+ pointer: z.ZodOptional<z.ZodString>;
6154
+ parameter: z.ZodOptional<z.ZodString>;
6155
+ }, "strip", z.ZodTypeAny, {
6156
+ pointer?: string | undefined;
6157
+ parameter?: string | undefined;
6158
+ }, {
6159
+ pointer?: string | undefined;
6160
+ parameter?: string | undefined;
6161
+ }>>;
6162
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
6163
+ }, "strip", z.ZodTypeAny, {
6164
+ status?: string | undefined;
6165
+ code?: string | undefined;
6166
+ id?: string | undefined;
6167
+ links?: {
6168
+ about?: string | undefined;
6169
+ } | undefined;
6170
+ meta?: Record<string, unknown> | undefined;
6171
+ title?: string | undefined;
6172
+ detail?: string | undefined;
6173
+ source?: {
6174
+ pointer?: string | undefined;
6175
+ parameter?: string | undefined;
6176
+ } | undefined;
6177
+ }, {
6178
+ status?: string | undefined;
6179
+ code?: string | undefined;
6180
+ id?: string | undefined;
6181
+ links?: {
6182
+ about?: string | undefined;
6183
+ } | undefined;
6184
+ meta?: Record<string, unknown> | undefined;
6185
+ title?: string | undefined;
6186
+ detail?: string | undefined;
6187
+ source?: {
6188
+ pointer?: string | undefined;
6189
+ parameter?: string | undefined;
6190
+ } | undefined;
6191
+ }>, "many">;
6192
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
6193
+ }, "strip", z.ZodTypeAny, {
6194
+ errors: {
6195
+ status?: string | undefined;
6196
+ code?: string | undefined;
6197
+ id?: string | undefined;
6198
+ links?: {
6199
+ about?: string | undefined;
6200
+ } | undefined;
6201
+ meta?: Record<string, unknown> | undefined;
6202
+ title?: string | undefined;
6203
+ detail?: string | undefined;
6204
+ source?: {
6205
+ pointer?: string | undefined;
6206
+ parameter?: string | undefined;
6207
+ } | undefined;
6208
+ }[];
6209
+ meta?: Record<string, unknown> | undefined;
6210
+ }, {
6211
+ errors: {
6212
+ status?: string | undefined;
6213
+ code?: string | undefined;
6214
+ id?: string | undefined;
6215
+ links?: {
6216
+ about?: string | undefined;
6217
+ } | undefined;
6218
+ meta?: Record<string, unknown> | undefined;
6219
+ title?: string | undefined;
6220
+ detail?: string | undefined;
6221
+ source?: {
6222
+ pointer?: string | undefined;
6223
+ parameter?: string | undefined;
6224
+ } | undefined;
6225
+ }[];
6226
+ meta?: Record<string, unknown> | undefined;
6227
+ }>;
6228
+ 404: z.ZodObject<{
6229
+ errors: z.ZodArray<z.ZodObject<{
6230
+ id: z.ZodOptional<z.ZodString>;
6231
+ links: z.ZodOptional<z.ZodObject<{
6232
+ about: z.ZodOptional<z.ZodString>;
6233
+ }, "strip", z.ZodTypeAny, {
6234
+ about?: string | undefined;
6235
+ }, {
6236
+ about?: string | undefined;
6237
+ }>>;
6238
+ status: z.ZodOptional<z.ZodString>;
6239
+ code: z.ZodOptional<z.ZodString>;
6240
+ title: z.ZodOptional<z.ZodString>;
6241
+ detail: z.ZodOptional<z.ZodString>;
6242
+ source: z.ZodOptional<z.ZodObject<{
6243
+ pointer: z.ZodOptional<z.ZodString>;
6244
+ parameter: z.ZodOptional<z.ZodString>;
6245
+ }, "strip", z.ZodTypeAny, {
6246
+ pointer?: string | undefined;
6247
+ parameter?: string | undefined;
6248
+ }, {
6249
+ pointer?: string | undefined;
6250
+ parameter?: string | undefined;
6251
+ }>>;
6252
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
6253
+ }, "strip", z.ZodTypeAny, {
6254
+ status?: string | undefined;
6255
+ code?: string | undefined;
6256
+ id?: string | undefined;
6257
+ links?: {
6258
+ about?: string | undefined;
6259
+ } | undefined;
6260
+ meta?: Record<string, unknown> | undefined;
6261
+ title?: string | undefined;
6262
+ detail?: string | undefined;
6263
+ source?: {
6264
+ pointer?: string | undefined;
6265
+ parameter?: string | undefined;
6266
+ } | undefined;
6267
+ }, {
6268
+ status?: string | undefined;
6269
+ code?: string | undefined;
6270
+ id?: string | undefined;
6271
+ links?: {
6272
+ about?: string | undefined;
6273
+ } | undefined;
6274
+ meta?: Record<string, unknown> | undefined;
6275
+ title?: string | undefined;
6276
+ detail?: string | undefined;
6277
+ source?: {
6278
+ pointer?: string | undefined;
6279
+ parameter?: string | undefined;
6280
+ } | undefined;
6281
+ }>, "many">;
6282
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
6283
+ }, "strip", z.ZodTypeAny, {
6284
+ errors: {
6285
+ status?: string | undefined;
6286
+ code?: string | undefined;
6287
+ id?: string | undefined;
6288
+ links?: {
6289
+ about?: string | undefined;
6290
+ } | undefined;
6291
+ meta?: Record<string, unknown> | undefined;
6292
+ title?: string | undefined;
6293
+ detail?: string | undefined;
6294
+ source?: {
6295
+ pointer?: string | undefined;
6296
+ parameter?: string | undefined;
6297
+ } | undefined;
6298
+ }[];
6299
+ meta?: Record<string, unknown> | undefined;
6300
+ }, {
6301
+ errors: {
6302
+ status?: string | undefined;
6303
+ code?: string | undefined;
6304
+ id?: string | undefined;
6305
+ links?: {
6306
+ about?: string | undefined;
6307
+ } | undefined;
6308
+ meta?: Record<string, unknown> | undefined;
6309
+ title?: string | undefined;
6310
+ detail?: string | undefined;
6311
+ source?: {
6312
+ pointer?: string | undefined;
6313
+ parameter?: string | undefined;
6314
+ } | undefined;
6315
+ }[];
6316
+ meta?: Record<string, unknown> | undefined;
6317
+ }>;
6318
+ };
6319
+ };
2701
6320
  };
2702
6321
  //# sourceMappingURL=commodity-deals.routes.d.ts.map