@voyantjs/distribution 0.2.0 → 0.3.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/routes.d.ts +17 -17
- package/dist/schema-automation.d.ts +680 -0
- package/dist/schema-automation.d.ts.map +1 -0
- package/dist/schema-automation.js +73 -0
- package/dist/schema-core.d.ts +1113 -0
- package/dist/schema-core.d.ts.map +1 -0
- package/dist/schema-core.js +116 -0
- package/dist/schema-finance.d.ts +1372 -0
- package/dist/schema-finance.d.ts.map +1 -0
- package/dist/schema-finance.js +147 -0
- package/dist/schema-inventory.d.ts +855 -0
- package/dist/schema-inventory.d.ts.map +1 -0
- package/dist/schema-inventory.js +105 -0
- package/dist/schema-relations.d.ts +99 -0
- package/dist/schema-relations.d.ts.map +1 -0
- package/dist/schema-relations.js +220 -0
- package/dist/schema-shared.d.ts +24 -0
- package/dist/schema-shared.d.ts.map +1 -0
- package/dist/schema-shared.js +122 -0
- package/dist/schema.d.ts +6 -4137
- package/dist/schema.d.ts.map +1 -1
- package/dist/schema.js +6 -760
- package/dist/service.d.ts +16 -16
- package/dist/validation.d.ts +10 -10
- package/package.json +8 -8
package/dist/service.d.ts
CHANGED
|
@@ -212,7 +212,7 @@ export declare const distributionService: {
|
|
|
212
212
|
id: string;
|
|
213
213
|
channelId: string;
|
|
214
214
|
supplierId: string | null;
|
|
215
|
-
status: "
|
|
215
|
+
status: "draft" | "active" | "expired" | "terminated";
|
|
216
216
|
startsAt: string;
|
|
217
217
|
endsAt: string | null;
|
|
218
218
|
paymentOwner: "operator" | "channel" | "split";
|
|
@@ -230,7 +230,7 @@ export declare const distributionService: {
|
|
|
230
230
|
id: string;
|
|
231
231
|
channelId: string;
|
|
232
232
|
supplierId: string | null;
|
|
233
|
-
status: "
|
|
233
|
+
status: "draft" | "active" | "expired" | "terminated";
|
|
234
234
|
startsAt: string;
|
|
235
235
|
endsAt: string | null;
|
|
236
236
|
paymentOwner: "operator" | "channel" | "split";
|
|
@@ -246,11 +246,11 @@ export declare const distributionService: {
|
|
|
246
246
|
updatedAt: Date;
|
|
247
247
|
notes: string | null;
|
|
248
248
|
id: string;
|
|
249
|
-
|
|
250
|
-
endsAt: string | null;
|
|
251
|
-
status: "active" | "draft" | "expired" | "terminated";
|
|
249
|
+
status: "draft" | "active" | "expired" | "terminated";
|
|
252
250
|
supplierId: string | null;
|
|
253
251
|
channelId: string;
|
|
252
|
+
startsAt: string;
|
|
253
|
+
endsAt: string | null;
|
|
254
254
|
cancellationOwner: "operator" | "channel" | "mixed";
|
|
255
255
|
settlementTerms: string | null;
|
|
256
256
|
} | undefined>;
|
|
@@ -258,7 +258,7 @@ export declare const distributionService: {
|
|
|
258
258
|
id: string;
|
|
259
259
|
channelId: string;
|
|
260
260
|
supplierId: string | null;
|
|
261
|
-
status: "
|
|
261
|
+
status: "draft" | "active" | "expired" | "terminated";
|
|
262
262
|
startsAt: string;
|
|
263
263
|
endsAt: string | null;
|
|
264
264
|
paymentOwner: "operator" | "channel" | "split";
|
|
@@ -370,8 +370,8 @@ export declare const distributionService: {
|
|
|
370
370
|
createdAt: Date;
|
|
371
371
|
updatedAt: Date;
|
|
372
372
|
id: string;
|
|
373
|
-
productId: string;
|
|
374
373
|
active: boolean;
|
|
374
|
+
productId: string;
|
|
375
375
|
channelId: string;
|
|
376
376
|
externalRateId: string | null;
|
|
377
377
|
externalCategoryId: string | null;
|
|
@@ -545,15 +545,15 @@ export declare const distributionService: {
|
|
|
545
545
|
updatedAt: Date;
|
|
546
546
|
notes: string | null;
|
|
547
547
|
id: string;
|
|
548
|
+
active: boolean;
|
|
548
549
|
productId: string;
|
|
549
550
|
optionId: string | null;
|
|
550
|
-
maxCapacity: number | null;
|
|
551
|
-
active: boolean;
|
|
552
|
-
startTimeId: string | null;
|
|
553
551
|
validFrom: string | null;
|
|
554
552
|
validTo: string | null;
|
|
555
553
|
channelId: string;
|
|
556
554
|
contractId: string | null;
|
|
555
|
+
maxCapacity: number | null;
|
|
556
|
+
startTimeId: string | null;
|
|
557
557
|
guaranteedCapacity: number | null;
|
|
558
558
|
} | undefined>;
|
|
559
559
|
updateInventoryAllotment(db: PostgresJsDatabase, id: string, data: UpdateChannelInventoryAllotmentInput): Promise<{
|
|
@@ -612,8 +612,8 @@ export declare const distributionService: {
|
|
|
612
612
|
createdAt: Date;
|
|
613
613
|
updatedAt: Date;
|
|
614
614
|
id: string;
|
|
615
|
-
maxCapacity: number | null;
|
|
616
615
|
active: boolean;
|
|
616
|
+
maxCapacity: number | null;
|
|
617
617
|
startTimeId: string | null;
|
|
618
618
|
dateLocal: string | null;
|
|
619
619
|
slotId: string | null;
|
|
@@ -696,7 +696,7 @@ export declare const distributionService: {
|
|
|
696
696
|
id: string;
|
|
697
697
|
channelId: string;
|
|
698
698
|
contractId: string | null;
|
|
699
|
-
status: "void" | "
|
|
699
|
+
status: "void" | "draft" | "open" | "posted" | "paid";
|
|
700
700
|
currencyCode: string | null;
|
|
701
701
|
periodStart: string | null;
|
|
702
702
|
periodEnd: string | null;
|
|
@@ -717,7 +717,7 @@ export declare const distributionService: {
|
|
|
717
717
|
id: string;
|
|
718
718
|
channelId: string;
|
|
719
719
|
contractId: string | null;
|
|
720
|
-
status: "void" | "
|
|
720
|
+
status: "void" | "draft" | "open" | "posted" | "paid";
|
|
721
721
|
currencyCode: string | null;
|
|
722
722
|
periodStart: string | null;
|
|
723
723
|
periodEnd: string | null;
|
|
@@ -736,7 +736,7 @@ export declare const distributionService: {
|
|
|
736
736
|
notes: string | null;
|
|
737
737
|
metadata: Record<string, unknown> | null;
|
|
738
738
|
id: string;
|
|
739
|
-
status: "void" | "
|
|
739
|
+
status: "void" | "draft" | "open" | "posted" | "paid";
|
|
740
740
|
channelId: string;
|
|
741
741
|
contractId: string | null;
|
|
742
742
|
currencyCode: string | null;
|
|
@@ -751,7 +751,7 @@ export declare const distributionService: {
|
|
|
751
751
|
id: string;
|
|
752
752
|
channelId: string;
|
|
753
753
|
contractId: string | null;
|
|
754
|
-
status: "void" | "
|
|
754
|
+
status: "void" | "draft" | "open" | "posted" | "paid";
|
|
755
755
|
currencyCode: string | null;
|
|
756
756
|
periodStart: string | null;
|
|
757
757
|
periodEnd: string | null;
|
|
@@ -1089,12 +1089,12 @@ export declare const distributionService: {
|
|
|
1089
1089
|
active: boolean;
|
|
1090
1090
|
channelId: string;
|
|
1091
1091
|
contractId: string | null;
|
|
1092
|
-
currencyCode: string | null;
|
|
1093
1092
|
frequency: "manual" | "daily" | "weekly" | "monthly";
|
|
1094
1093
|
autoGenerate: boolean;
|
|
1095
1094
|
approvalRequired: boolean;
|
|
1096
1095
|
remittanceDaysAfterPeriodEnd: number | null;
|
|
1097
1096
|
minimumPayoutAmountCents: number | null;
|
|
1097
|
+
currencyCode: string | null;
|
|
1098
1098
|
} | undefined>;
|
|
1099
1099
|
updateSettlementPolicy(db: PostgresJsDatabase, id: string, data: UpdateChannelSettlementPolicyInput): Promise<{
|
|
1100
1100
|
id: string;
|
package/dist/validation.d.ts
CHANGED
|
@@ -14,8 +14,8 @@ export declare const channelStatusSchema: z.ZodEnum<{
|
|
|
14
14
|
pending: "pending";
|
|
15
15
|
}>;
|
|
16
16
|
export declare const channelContractStatusSchema: z.ZodEnum<{
|
|
17
|
-
active: "active";
|
|
18
17
|
draft: "draft";
|
|
18
|
+
active: "active";
|
|
19
19
|
expired: "expired";
|
|
20
20
|
terminated: "terminated";
|
|
21
21
|
}>;
|
|
@@ -56,8 +56,8 @@ export declare const channelAllotmentUnsoldActionSchema: z.ZodEnum<{
|
|
|
56
56
|
}>;
|
|
57
57
|
export declare const channelSettlementRunStatusSchema: z.ZodEnum<{
|
|
58
58
|
void: "void";
|
|
59
|
-
open: "open";
|
|
60
59
|
draft: "draft";
|
|
60
|
+
open: "open";
|
|
61
61
|
posted: "posted";
|
|
62
62
|
paid: "paid";
|
|
63
63
|
}>;
|
|
@@ -220,8 +220,8 @@ export declare const channelContractCoreSchema: z.ZodObject<{
|
|
|
220
220
|
channelId: z.ZodString;
|
|
221
221
|
supplierId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
222
222
|
status: z.ZodDefault<z.ZodEnum<{
|
|
223
|
-
active: "active";
|
|
224
223
|
draft: "draft";
|
|
224
|
+
active: "active";
|
|
225
225
|
expired: "expired";
|
|
226
226
|
terminated: "terminated";
|
|
227
227
|
}>>;
|
|
@@ -244,8 +244,8 @@ export declare const insertChannelContractSchema: z.ZodObject<{
|
|
|
244
244
|
channelId: z.ZodString;
|
|
245
245
|
supplierId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
246
246
|
status: z.ZodDefault<z.ZodEnum<{
|
|
247
|
-
active: "active";
|
|
248
247
|
draft: "draft";
|
|
248
|
+
active: "active";
|
|
249
249
|
expired: "expired";
|
|
250
250
|
terminated: "terminated";
|
|
251
251
|
}>>;
|
|
@@ -268,8 +268,8 @@ export declare const updateChannelContractSchema: z.ZodObject<{
|
|
|
268
268
|
channelId: z.ZodOptional<z.ZodString>;
|
|
269
269
|
supplierId: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
|
|
270
270
|
status: z.ZodOptional<z.ZodDefault<z.ZodEnum<{
|
|
271
|
-
active: "active";
|
|
272
271
|
draft: "draft";
|
|
272
|
+
active: "active";
|
|
273
273
|
expired: "expired";
|
|
274
274
|
terminated: "terminated";
|
|
275
275
|
}>>>;
|
|
@@ -294,8 +294,8 @@ export declare const channelContractListQuerySchema: z.ZodObject<{
|
|
|
294
294
|
channelId: z.ZodOptional<z.ZodString>;
|
|
295
295
|
supplierId: z.ZodOptional<z.ZodString>;
|
|
296
296
|
status: z.ZodOptional<z.ZodEnum<{
|
|
297
|
-
active: "active";
|
|
298
297
|
draft: "draft";
|
|
298
|
+
active: "active";
|
|
299
299
|
expired: "expired";
|
|
300
300
|
terminated: "terminated";
|
|
301
301
|
}>>;
|
|
@@ -659,8 +659,8 @@ export declare const channelSettlementRunCoreSchema: z.ZodObject<{
|
|
|
659
659
|
contractId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
660
660
|
status: z.ZodDefault<z.ZodEnum<{
|
|
661
661
|
void: "void";
|
|
662
|
-
open: "open";
|
|
663
662
|
draft: "draft";
|
|
663
|
+
open: "open";
|
|
664
664
|
posted: "posted";
|
|
665
665
|
paid: "paid";
|
|
666
666
|
}>>;
|
|
@@ -679,8 +679,8 @@ export declare const insertChannelSettlementRunSchema: z.ZodObject<{
|
|
|
679
679
|
contractId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
680
680
|
status: z.ZodDefault<z.ZodEnum<{
|
|
681
681
|
void: "void";
|
|
682
|
-
open: "open";
|
|
683
682
|
draft: "draft";
|
|
683
|
+
open: "open";
|
|
684
684
|
posted: "posted";
|
|
685
685
|
paid: "paid";
|
|
686
686
|
}>>;
|
|
@@ -699,8 +699,8 @@ export declare const updateChannelSettlementRunSchema: z.ZodObject<{
|
|
|
699
699
|
contractId: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
|
|
700
700
|
status: z.ZodOptional<z.ZodDefault<z.ZodEnum<{
|
|
701
701
|
void: "void";
|
|
702
|
-
open: "open";
|
|
703
702
|
draft: "draft";
|
|
703
|
+
open: "open";
|
|
704
704
|
posted: "posted";
|
|
705
705
|
paid: "paid";
|
|
706
706
|
}>>>;
|
|
@@ -721,8 +721,8 @@ export declare const channelSettlementRunListQuerySchema: z.ZodObject<{
|
|
|
721
721
|
contractId: z.ZodOptional<z.ZodString>;
|
|
722
722
|
status: z.ZodOptional<z.ZodEnum<{
|
|
723
723
|
void: "void";
|
|
724
|
-
open: "open";
|
|
725
724
|
draft: "draft";
|
|
725
|
+
open: "open";
|
|
726
726
|
posted: "posted";
|
|
727
727
|
paid: "paid";
|
|
728
728
|
}>>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@voyantjs/distribution",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.3.1",
|
|
4
4
|
"license": "FSL-1.1-Apache-2.0",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"exports": {
|
|
@@ -29,13 +29,13 @@
|
|
|
29
29
|
"drizzle-orm": "^0.45.2",
|
|
30
30
|
"hono": "^4.12.10",
|
|
31
31
|
"zod": "^4.3.6",
|
|
32
|
-
"@voyantjs/availability": "0.
|
|
33
|
-
"@voyantjs/core": "0.
|
|
34
|
-
"@voyantjs/db": "0.
|
|
35
|
-
"@voyantjs/hono": "0.
|
|
36
|
-
"@voyantjs/identity": "0.
|
|
37
|
-
"@voyantjs/products": "0.
|
|
38
|
-
"@voyantjs/suppliers": "0.
|
|
32
|
+
"@voyantjs/availability": "0.3.1",
|
|
33
|
+
"@voyantjs/core": "0.3.1",
|
|
34
|
+
"@voyantjs/db": "0.3.1",
|
|
35
|
+
"@voyantjs/hono": "0.3.1",
|
|
36
|
+
"@voyantjs/identity": "0.3.1",
|
|
37
|
+
"@voyantjs/products": "0.3.1",
|
|
38
|
+
"@voyantjs/suppliers": "0.3.1"
|
|
39
39
|
},
|
|
40
40
|
"devDependencies": {
|
|
41
41
|
"typescript": "^6.0.2",
|