@tonytang99/integration-canonical 1.0.0 → 1.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +414 -1
- package/dist/index.d.ts +5 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +80 -15
- package/dist/index.js.map +1 -1
- package/dist/schemas/customer.d.ts +746 -0
- package/dist/schemas/customer.d.ts.map +1 -0
- package/dist/schemas/customer.js +282 -0
- package/dist/schemas/customer.js.map +1 -0
- package/dist/schemas/index.d.ts +13 -0
- package/dist/schemas/index.d.ts.map +1 -0
- package/dist/schemas/index.js +33 -0
- package/dist/schemas/index.js.map +1 -0
- package/dist/schemas/inventory.d.ts +1642 -0
- package/dist/schemas/inventory.d.ts.map +1 -0
- package/dist/schemas/inventory.js +302 -0
- package/dist/schemas/inventory.js.map +1 -0
- package/dist/schemas/order.d.ts +1339 -0
- package/dist/schemas/order.d.ts.map +1 -0
- package/dist/schemas/order.js +310 -0
- package/dist/schemas/order.js.map +1 -0
- package/dist/schemas/product.d.ts +717 -0
- package/dist/schemas/product.d.ts.map +1 -0
- package/dist/schemas/product.js +303 -0
- package/dist/schemas/product.js.map +1 -0
- package/dist/slots.d.ts +572 -0
- package/dist/slots.d.ts.map +1 -0
- package/dist/slots.js +20 -0
- package/dist/slots.js.map +1 -0
- package/dist/types/common.d.ts +284 -0
- package/dist/types/common.d.ts.map +1 -0
- package/dist/types/common.js +401 -0
- package/dist/types/common.js.map +1 -0
- package/dist/types/enrichments.d.ts +378 -0
- package/dist/types/enrichments.d.ts.map +1 -0
- package/dist/types/enrichments.js +96 -0
- package/dist/types/enrichments.js.map +1 -0
- package/package.json +2 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"common.js","sourceRoot":"","sources":["../../src/types/common.ts"],"names":[],"mappings":";;;AAAA,yCAAyC;AACzC,6BAAwB;AAExB,+EAA+E;AAC/E,eAAe;AACf,+EAA+E;AAE/E;;;G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AAI,EAAE,qBAAa;CACpB,CAAC,CAAC"}
|
|
@@ -0,0 +1,378 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
export declare const InventoryEnrichmentSchema: z.ZodObject<{
|
|
3
|
+
sku: z.ZodString;
|
|
4
|
+
available: z.ZodNumber;
|
|
5
|
+
reserved: z.ZodDefault<z.ZodNumber>;
|
|
6
|
+
incoming: z.ZodDefault<z.ZodNumber>;
|
|
7
|
+
locations: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
8
|
+
name: z.ZodString;
|
|
9
|
+
quantity: z.ZodNumber;
|
|
10
|
+
locationId: z.ZodOptional<z.ZodString>;
|
|
11
|
+
}, "strip", z.ZodTypeAny, {
|
|
12
|
+
name: string;
|
|
13
|
+
quantity: number;
|
|
14
|
+
locationId?: string | undefined;
|
|
15
|
+
}, {
|
|
16
|
+
name: string;
|
|
17
|
+
quantity: number;
|
|
18
|
+
locationId?: string | undefined;
|
|
19
|
+
}>, "many">>;
|
|
20
|
+
fetchedAt: z.ZodDate;
|
|
21
|
+
}, "strip", z.ZodTypeAny, {
|
|
22
|
+
available: number;
|
|
23
|
+
sku: string;
|
|
24
|
+
reserved: number;
|
|
25
|
+
incoming: number;
|
|
26
|
+
fetchedAt: Date;
|
|
27
|
+
locations?: {
|
|
28
|
+
name: string;
|
|
29
|
+
quantity: number;
|
|
30
|
+
locationId?: string | undefined;
|
|
31
|
+
}[] | undefined;
|
|
32
|
+
}, {
|
|
33
|
+
available: number;
|
|
34
|
+
sku: string;
|
|
35
|
+
fetchedAt: Date;
|
|
36
|
+
locations?: {
|
|
37
|
+
name: string;
|
|
38
|
+
quantity: number;
|
|
39
|
+
locationId?: string | undefined;
|
|
40
|
+
}[] | undefined;
|
|
41
|
+
reserved?: number | undefined;
|
|
42
|
+
incoming?: number | undefined;
|
|
43
|
+
}>;
|
|
44
|
+
export type InventoryEnrichment = z.infer<typeof InventoryEnrichmentSchema>;
|
|
45
|
+
export declare const PricingEnrichmentSchema: z.ZodObject<{
|
|
46
|
+
sku: z.ZodString;
|
|
47
|
+
costPrice: z.ZodOptional<z.ZodObject<{
|
|
48
|
+
amount: z.ZodNumber;
|
|
49
|
+
currency: z.ZodEnum<["USD", "EUR", "GBP", "AUD", "CAD", "NZD", "JPY", "CNY", "INR", "SGD", "HKD", "MXN", "BRL", "ZAR"]>;
|
|
50
|
+
}, "strip", z.ZodTypeAny, {
|
|
51
|
+
amount: number;
|
|
52
|
+
currency: "USD" | "EUR" | "GBP" | "AUD" | "CAD" | "NZD" | "JPY" | "CNY" | "INR" | "SGD" | "HKD" | "MXN" | "BRL" | "ZAR";
|
|
53
|
+
}, {
|
|
54
|
+
amount: number;
|
|
55
|
+
currency: "USD" | "EUR" | "GBP" | "AUD" | "CAD" | "NZD" | "JPY" | "CNY" | "INR" | "SGD" | "HKD" | "MXN" | "BRL" | "ZAR";
|
|
56
|
+
}>>;
|
|
57
|
+
retailPrice: z.ZodObject<{
|
|
58
|
+
amount: z.ZodNumber;
|
|
59
|
+
currency: z.ZodEnum<["USD", "EUR", "GBP", "AUD", "CAD", "NZD", "JPY", "CNY", "INR", "SGD", "HKD", "MXN", "BRL", "ZAR"]>;
|
|
60
|
+
}, "strip", z.ZodTypeAny, {
|
|
61
|
+
amount: number;
|
|
62
|
+
currency: "USD" | "EUR" | "GBP" | "AUD" | "CAD" | "NZD" | "JPY" | "CNY" | "INR" | "SGD" | "HKD" | "MXN" | "BRL" | "ZAR";
|
|
63
|
+
}, {
|
|
64
|
+
amount: number;
|
|
65
|
+
currency: "USD" | "EUR" | "GBP" | "AUD" | "CAD" | "NZD" | "JPY" | "CNY" | "INR" | "SGD" | "HKD" | "MXN" | "BRL" | "ZAR";
|
|
66
|
+
}>;
|
|
67
|
+
salePrice: z.ZodOptional<z.ZodObject<{
|
|
68
|
+
amount: z.ZodNumber;
|
|
69
|
+
currency: z.ZodEnum<["USD", "EUR", "GBP", "AUD", "CAD", "NZD", "JPY", "CNY", "INR", "SGD", "HKD", "MXN", "BRL", "ZAR"]>;
|
|
70
|
+
}, "strip", z.ZodTypeAny, {
|
|
71
|
+
amount: number;
|
|
72
|
+
currency: "USD" | "EUR" | "GBP" | "AUD" | "CAD" | "NZD" | "JPY" | "CNY" | "INR" | "SGD" | "HKD" | "MXN" | "BRL" | "ZAR";
|
|
73
|
+
}, {
|
|
74
|
+
amount: number;
|
|
75
|
+
currency: "USD" | "EUR" | "GBP" | "AUD" | "CAD" | "NZD" | "JPY" | "CNY" | "INR" | "SGD" | "HKD" | "MXN" | "BRL" | "ZAR";
|
|
76
|
+
}>>;
|
|
77
|
+
mapPrice: z.ZodOptional<z.ZodObject<{
|
|
78
|
+
amount: z.ZodNumber;
|
|
79
|
+
currency: z.ZodEnum<["USD", "EUR", "GBP", "AUD", "CAD", "NZD", "JPY", "CNY", "INR", "SGD", "HKD", "MXN", "BRL", "ZAR"]>;
|
|
80
|
+
}, "strip", z.ZodTypeAny, {
|
|
81
|
+
amount: number;
|
|
82
|
+
currency: "USD" | "EUR" | "GBP" | "AUD" | "CAD" | "NZD" | "JPY" | "CNY" | "INR" | "SGD" | "HKD" | "MXN" | "BRL" | "ZAR";
|
|
83
|
+
}, {
|
|
84
|
+
amount: number;
|
|
85
|
+
currency: "USD" | "EUR" | "GBP" | "AUD" | "CAD" | "NZD" | "JPY" | "CNY" | "INR" | "SGD" | "HKD" | "MXN" | "BRL" | "ZAR";
|
|
86
|
+
}>>;
|
|
87
|
+
margin: z.ZodOptional<z.ZodNumber>;
|
|
88
|
+
markupPercentage: z.ZodOptional<z.ZodNumber>;
|
|
89
|
+
priceRules: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
90
|
+
name: z.ZodString;
|
|
91
|
+
discount: z.ZodNumber;
|
|
92
|
+
type: z.ZodEnum<["fixed", "percent"]>;
|
|
93
|
+
customerGroup: z.ZodOptional<z.ZodString>;
|
|
94
|
+
}, "strip", z.ZodTypeAny, {
|
|
95
|
+
type: "percent" | "fixed";
|
|
96
|
+
name: string;
|
|
97
|
+
discount: number;
|
|
98
|
+
customerGroup?: string | undefined;
|
|
99
|
+
}, {
|
|
100
|
+
type: "percent" | "fixed";
|
|
101
|
+
name: string;
|
|
102
|
+
discount: number;
|
|
103
|
+
customerGroup?: string | undefined;
|
|
104
|
+
}>, "many">>;
|
|
105
|
+
fetchedAt: z.ZodDate;
|
|
106
|
+
}, "strip", z.ZodTypeAny, {
|
|
107
|
+
sku: string;
|
|
108
|
+
fetchedAt: Date;
|
|
109
|
+
retailPrice: {
|
|
110
|
+
amount: number;
|
|
111
|
+
currency: "USD" | "EUR" | "GBP" | "AUD" | "CAD" | "NZD" | "JPY" | "CNY" | "INR" | "SGD" | "HKD" | "MXN" | "BRL" | "ZAR";
|
|
112
|
+
};
|
|
113
|
+
costPrice?: {
|
|
114
|
+
amount: number;
|
|
115
|
+
currency: "USD" | "EUR" | "GBP" | "AUD" | "CAD" | "NZD" | "JPY" | "CNY" | "INR" | "SGD" | "HKD" | "MXN" | "BRL" | "ZAR";
|
|
116
|
+
} | undefined;
|
|
117
|
+
salePrice?: {
|
|
118
|
+
amount: number;
|
|
119
|
+
currency: "USD" | "EUR" | "GBP" | "AUD" | "CAD" | "NZD" | "JPY" | "CNY" | "INR" | "SGD" | "HKD" | "MXN" | "BRL" | "ZAR";
|
|
120
|
+
} | undefined;
|
|
121
|
+
mapPrice?: {
|
|
122
|
+
amount: number;
|
|
123
|
+
currency: "USD" | "EUR" | "GBP" | "AUD" | "CAD" | "NZD" | "JPY" | "CNY" | "INR" | "SGD" | "HKD" | "MXN" | "BRL" | "ZAR";
|
|
124
|
+
} | undefined;
|
|
125
|
+
margin?: number | undefined;
|
|
126
|
+
markupPercentage?: number | undefined;
|
|
127
|
+
priceRules?: {
|
|
128
|
+
type: "percent" | "fixed";
|
|
129
|
+
name: string;
|
|
130
|
+
discount: number;
|
|
131
|
+
customerGroup?: string | undefined;
|
|
132
|
+
}[] | undefined;
|
|
133
|
+
}, {
|
|
134
|
+
sku: string;
|
|
135
|
+
fetchedAt: Date;
|
|
136
|
+
retailPrice: {
|
|
137
|
+
amount: number;
|
|
138
|
+
currency: "USD" | "EUR" | "GBP" | "AUD" | "CAD" | "NZD" | "JPY" | "CNY" | "INR" | "SGD" | "HKD" | "MXN" | "BRL" | "ZAR";
|
|
139
|
+
};
|
|
140
|
+
costPrice?: {
|
|
141
|
+
amount: number;
|
|
142
|
+
currency: "USD" | "EUR" | "GBP" | "AUD" | "CAD" | "NZD" | "JPY" | "CNY" | "INR" | "SGD" | "HKD" | "MXN" | "BRL" | "ZAR";
|
|
143
|
+
} | undefined;
|
|
144
|
+
salePrice?: {
|
|
145
|
+
amount: number;
|
|
146
|
+
currency: "USD" | "EUR" | "GBP" | "AUD" | "CAD" | "NZD" | "JPY" | "CNY" | "INR" | "SGD" | "HKD" | "MXN" | "BRL" | "ZAR";
|
|
147
|
+
} | undefined;
|
|
148
|
+
mapPrice?: {
|
|
149
|
+
amount: number;
|
|
150
|
+
currency: "USD" | "EUR" | "GBP" | "AUD" | "CAD" | "NZD" | "JPY" | "CNY" | "INR" | "SGD" | "HKD" | "MXN" | "BRL" | "ZAR";
|
|
151
|
+
} | undefined;
|
|
152
|
+
margin?: number | undefined;
|
|
153
|
+
markupPercentage?: number | undefined;
|
|
154
|
+
priceRules?: {
|
|
155
|
+
type: "percent" | "fixed";
|
|
156
|
+
name: string;
|
|
157
|
+
discount: number;
|
|
158
|
+
customerGroup?: string | undefined;
|
|
159
|
+
}[] | undefined;
|
|
160
|
+
}>;
|
|
161
|
+
export type PricingEnrichment = z.infer<typeof PricingEnrichmentSchema>;
|
|
162
|
+
export declare const CategoryEnrichmentSchema: z.ZodObject<{
|
|
163
|
+
categories: z.ZodArray<z.ZodObject<{
|
|
164
|
+
id: z.ZodString;
|
|
165
|
+
code: z.ZodOptional<z.ZodString>;
|
|
166
|
+
name: z.ZodString;
|
|
167
|
+
path: z.ZodArray<z.ZodString, "many">;
|
|
168
|
+
level: z.ZodNumber;
|
|
169
|
+
}, "strip", z.ZodTypeAny, {
|
|
170
|
+
path: string[];
|
|
171
|
+
id: string;
|
|
172
|
+
name: string;
|
|
173
|
+
level: number;
|
|
174
|
+
code?: string | undefined;
|
|
175
|
+
}, {
|
|
176
|
+
path: string[];
|
|
177
|
+
id: string;
|
|
178
|
+
name: string;
|
|
179
|
+
level: number;
|
|
180
|
+
code?: string | undefined;
|
|
181
|
+
}>, "many">;
|
|
182
|
+
primaryCategory: z.ZodOptional<z.ZodString>;
|
|
183
|
+
fetchedAt: z.ZodDate;
|
|
184
|
+
}, "strip", z.ZodTypeAny, {
|
|
185
|
+
categories: {
|
|
186
|
+
path: string[];
|
|
187
|
+
id: string;
|
|
188
|
+
name: string;
|
|
189
|
+
level: number;
|
|
190
|
+
code?: string | undefined;
|
|
191
|
+
}[];
|
|
192
|
+
fetchedAt: Date;
|
|
193
|
+
primaryCategory?: string | undefined;
|
|
194
|
+
}, {
|
|
195
|
+
categories: {
|
|
196
|
+
path: string[];
|
|
197
|
+
id: string;
|
|
198
|
+
name: string;
|
|
199
|
+
level: number;
|
|
200
|
+
code?: string | undefined;
|
|
201
|
+
}[];
|
|
202
|
+
fetchedAt: Date;
|
|
203
|
+
primaryCategory?: string | undefined;
|
|
204
|
+
}>;
|
|
205
|
+
export type CategoryEnrichment = z.infer<typeof CategoryEnrichmentSchema>;
|
|
206
|
+
export declare const ImageEnrichmentSchema: z.ZodObject<{
|
|
207
|
+
images: z.ZodArray<z.ZodObject<{
|
|
208
|
+
url: z.ZodString;
|
|
209
|
+
optimizedUrl: z.ZodOptional<z.ZodString>;
|
|
210
|
+
thumbnailUrl: z.ZodOptional<z.ZodString>;
|
|
211
|
+
alt: z.ZodOptional<z.ZodString>;
|
|
212
|
+
width: z.ZodOptional<z.ZodNumber>;
|
|
213
|
+
height: z.ZodOptional<z.ZodNumber>;
|
|
214
|
+
fileSize: z.ZodOptional<z.ZodNumber>;
|
|
215
|
+
type: z.ZodOptional<z.ZodString>;
|
|
216
|
+
}, "strip", z.ZodTypeAny, {
|
|
217
|
+
url: string;
|
|
218
|
+
type?: string | undefined;
|
|
219
|
+
width?: number | undefined;
|
|
220
|
+
height?: number | undefined;
|
|
221
|
+
optimizedUrl?: string | undefined;
|
|
222
|
+
thumbnailUrl?: string | undefined;
|
|
223
|
+
alt?: string | undefined;
|
|
224
|
+
fileSize?: number | undefined;
|
|
225
|
+
}, {
|
|
226
|
+
url: string;
|
|
227
|
+
type?: string | undefined;
|
|
228
|
+
width?: number | undefined;
|
|
229
|
+
height?: number | undefined;
|
|
230
|
+
optimizedUrl?: string | undefined;
|
|
231
|
+
thumbnailUrl?: string | undefined;
|
|
232
|
+
alt?: string | undefined;
|
|
233
|
+
fileSize?: number | undefined;
|
|
234
|
+
}>, "many">;
|
|
235
|
+
processedAt: z.ZodDate;
|
|
236
|
+
}, "strip", z.ZodTypeAny, {
|
|
237
|
+
images: {
|
|
238
|
+
url: string;
|
|
239
|
+
type?: string | undefined;
|
|
240
|
+
width?: number | undefined;
|
|
241
|
+
height?: number | undefined;
|
|
242
|
+
optimizedUrl?: string | undefined;
|
|
243
|
+
thumbnailUrl?: string | undefined;
|
|
244
|
+
alt?: string | undefined;
|
|
245
|
+
fileSize?: number | undefined;
|
|
246
|
+
}[];
|
|
247
|
+
processedAt: Date;
|
|
248
|
+
}, {
|
|
249
|
+
images: {
|
|
250
|
+
url: string;
|
|
251
|
+
type?: string | undefined;
|
|
252
|
+
width?: number | undefined;
|
|
253
|
+
height?: number | undefined;
|
|
254
|
+
optimizedUrl?: string | undefined;
|
|
255
|
+
thumbnailUrl?: string | undefined;
|
|
256
|
+
alt?: string | undefined;
|
|
257
|
+
fileSize?: number | undefined;
|
|
258
|
+
}[];
|
|
259
|
+
processedAt: Date;
|
|
260
|
+
}>;
|
|
261
|
+
export type ImageEnrichment = z.infer<typeof ImageEnrichmentSchema>;
|
|
262
|
+
export declare const ShippingEnrichmentSchema: z.ZodObject<{
|
|
263
|
+
weight: z.ZodOptional<z.ZodObject<{
|
|
264
|
+
value: z.ZodNumber;
|
|
265
|
+
unit: z.ZodEnum<["g", "kg", "oz", "lb"]>;
|
|
266
|
+
}, "strip", z.ZodTypeAny, {
|
|
267
|
+
value: number;
|
|
268
|
+
unit: "g" | "kg" | "oz" | "lb";
|
|
269
|
+
}, {
|
|
270
|
+
value: number;
|
|
271
|
+
unit: "g" | "kg" | "oz" | "lb";
|
|
272
|
+
}>>;
|
|
273
|
+
dimensions: z.ZodOptional<z.ZodObject<{
|
|
274
|
+
length: z.ZodNumber;
|
|
275
|
+
width: z.ZodNumber;
|
|
276
|
+
height: z.ZodNumber;
|
|
277
|
+
unit: z.ZodEnum<["cm", "m", "mm", "in", "ft"]>;
|
|
278
|
+
}, "strip", z.ZodTypeAny, {
|
|
279
|
+
length: number;
|
|
280
|
+
unit: "cm" | "m" | "mm" | "in" | "ft";
|
|
281
|
+
width: number;
|
|
282
|
+
height: number;
|
|
283
|
+
}, {
|
|
284
|
+
length: number;
|
|
285
|
+
unit: "cm" | "m" | "mm" | "in" | "ft";
|
|
286
|
+
width: number;
|
|
287
|
+
height: number;
|
|
288
|
+
}>>;
|
|
289
|
+
shippingClass: z.ZodOptional<z.ZodString>;
|
|
290
|
+
estimatedCost: z.ZodOptional<z.ZodObject<{
|
|
291
|
+
amount: z.ZodNumber;
|
|
292
|
+
currency: z.ZodEnum<["USD", "EUR", "GBP", "AUD", "CAD", "NZD", "JPY", "CNY", "INR", "SGD", "HKD", "MXN", "BRL", "ZAR"]>;
|
|
293
|
+
}, "strip", z.ZodTypeAny, {
|
|
294
|
+
amount: number;
|
|
295
|
+
currency: "USD" | "EUR" | "GBP" | "AUD" | "CAD" | "NZD" | "JPY" | "CNY" | "INR" | "SGD" | "HKD" | "MXN" | "BRL" | "ZAR";
|
|
296
|
+
}, {
|
|
297
|
+
amount: number;
|
|
298
|
+
currency: "USD" | "EUR" | "GBP" | "AUD" | "CAD" | "NZD" | "JPY" | "CNY" | "INR" | "SGD" | "HKD" | "MXN" | "BRL" | "ZAR";
|
|
299
|
+
}>>;
|
|
300
|
+
restrictions: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
301
|
+
fetchedAt: z.ZodDate;
|
|
302
|
+
}, "strip", z.ZodTypeAny, {
|
|
303
|
+
fetchedAt: Date;
|
|
304
|
+
weight?: {
|
|
305
|
+
value: number;
|
|
306
|
+
unit: "g" | "kg" | "oz" | "lb";
|
|
307
|
+
} | undefined;
|
|
308
|
+
dimensions?: {
|
|
309
|
+
length: number;
|
|
310
|
+
unit: "cm" | "m" | "mm" | "in" | "ft";
|
|
311
|
+
width: number;
|
|
312
|
+
height: number;
|
|
313
|
+
} | undefined;
|
|
314
|
+
shippingClass?: string | undefined;
|
|
315
|
+
estimatedCost?: {
|
|
316
|
+
amount: number;
|
|
317
|
+
currency: "USD" | "EUR" | "GBP" | "AUD" | "CAD" | "NZD" | "JPY" | "CNY" | "INR" | "SGD" | "HKD" | "MXN" | "BRL" | "ZAR";
|
|
318
|
+
} | undefined;
|
|
319
|
+
restrictions?: string[] | undefined;
|
|
320
|
+
}, {
|
|
321
|
+
fetchedAt: Date;
|
|
322
|
+
weight?: {
|
|
323
|
+
value: number;
|
|
324
|
+
unit: "g" | "kg" | "oz" | "lb";
|
|
325
|
+
} | undefined;
|
|
326
|
+
dimensions?: {
|
|
327
|
+
length: number;
|
|
328
|
+
unit: "cm" | "m" | "mm" | "in" | "ft";
|
|
329
|
+
width: number;
|
|
330
|
+
height: number;
|
|
331
|
+
} | undefined;
|
|
332
|
+
shippingClass?: string | undefined;
|
|
333
|
+
estimatedCost?: {
|
|
334
|
+
amount: number;
|
|
335
|
+
currency: "USD" | "EUR" | "GBP" | "AUD" | "CAD" | "NZD" | "JPY" | "CNY" | "INR" | "SGD" | "HKD" | "MXN" | "BRL" | "ZAR";
|
|
336
|
+
} | undefined;
|
|
337
|
+
restrictions?: string[] | undefined;
|
|
338
|
+
}>;
|
|
339
|
+
export type ShippingEnrichment = z.infer<typeof ShippingEnrichmentSchema>;
|
|
340
|
+
export declare const TaxEnrichmentSchema: z.ZodObject<{
|
|
341
|
+
taxable: z.ZodBoolean;
|
|
342
|
+
taxCode: z.ZodOptional<z.ZodString>;
|
|
343
|
+
taxRate: z.ZodOptional<z.ZodNumber>;
|
|
344
|
+
taxAmount: z.ZodOptional<z.ZodObject<{
|
|
345
|
+
amount: z.ZodNumber;
|
|
346
|
+
currency: z.ZodEnum<["USD", "EUR", "GBP", "AUD", "CAD", "NZD", "JPY", "CNY", "INR", "SGD", "HKD", "MXN", "BRL", "ZAR"]>;
|
|
347
|
+
}, "strip", z.ZodTypeAny, {
|
|
348
|
+
amount: number;
|
|
349
|
+
currency: "USD" | "EUR" | "GBP" | "AUD" | "CAD" | "NZD" | "JPY" | "CNY" | "INR" | "SGD" | "HKD" | "MXN" | "BRL" | "ZAR";
|
|
350
|
+
}, {
|
|
351
|
+
amount: number;
|
|
352
|
+
currency: "USD" | "EUR" | "GBP" | "AUD" | "CAD" | "NZD" | "JPY" | "CNY" | "INR" | "SGD" | "HKD" | "MXN" | "BRL" | "ZAR";
|
|
353
|
+
}>>;
|
|
354
|
+
jurisdiction: z.ZodOptional<z.ZodString>;
|
|
355
|
+
fetchedAt: z.ZodDate;
|
|
356
|
+
}, "strip", z.ZodTypeAny, {
|
|
357
|
+
taxable: boolean;
|
|
358
|
+
fetchedAt: Date;
|
|
359
|
+
taxCode?: string | undefined;
|
|
360
|
+
taxAmount?: {
|
|
361
|
+
amount: number;
|
|
362
|
+
currency: "USD" | "EUR" | "GBP" | "AUD" | "CAD" | "NZD" | "JPY" | "CNY" | "INR" | "SGD" | "HKD" | "MXN" | "BRL" | "ZAR";
|
|
363
|
+
} | undefined;
|
|
364
|
+
jurisdiction?: string | undefined;
|
|
365
|
+
taxRate?: number | undefined;
|
|
366
|
+
}, {
|
|
367
|
+
taxable: boolean;
|
|
368
|
+
fetchedAt: Date;
|
|
369
|
+
taxCode?: string | undefined;
|
|
370
|
+
taxAmount?: {
|
|
371
|
+
amount: number;
|
|
372
|
+
currency: "USD" | "EUR" | "GBP" | "AUD" | "CAD" | "NZD" | "JPY" | "CNY" | "INR" | "SGD" | "HKD" | "MXN" | "BRL" | "ZAR";
|
|
373
|
+
} | undefined;
|
|
374
|
+
jurisdiction?: string | undefined;
|
|
375
|
+
taxRate?: number | undefined;
|
|
376
|
+
}>;
|
|
377
|
+
export type TaxEnrichment = z.infer<typeof TaxEnrichmentSchema>;
|
|
378
|
+
//# sourceMappingURL=enrichments.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"enrichments.d.ts","sourceRoot":"","sources":["../../src/types/enrichments.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAWxB,eAAO,MAAM,yBAAyB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAWpC,CAAC;AAEH,MAAM,MAAM,mBAAmB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,yBAAyB,CAAC,CAAC;AAM5E,eAAO,MAAM,uBAAuB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAmBlC,CAAC;AAEH,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,uBAAuB,CAAC,CAAC;AAMxE,eAAO,MAAM,wBAAwB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAUnC,CAAC;AAEH,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,wBAAwB,CAAC,CAAC;AAM1E,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAYhC,CAAC;AAEH,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,qBAAqB,CAAC,CAAC;AAMpE,eAAO,MAAM,wBAAwB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAOnC,CAAC;AAEH,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,wBAAwB,CAAC,CAAC;AAM1E,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAO9B,CAAC;AAEH,MAAM,MAAM,aAAa,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC"}
|
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.TaxEnrichmentSchema = exports.ShippingEnrichmentSchema = exports.ImageEnrichmentSchema = exports.CategoryEnrichmentSchema = exports.PricingEnrichmentSchema = exports.InventoryEnrichmentSchema = void 0;
|
|
4
|
+
// ============================================================================
|
|
5
|
+
// packages/canonical/src/types/enrichments.ts
|
|
6
|
+
// ============================================================================
|
|
7
|
+
const zod_1 = require("zod");
|
|
8
|
+
const common_1 = require("./common");
|
|
9
|
+
// ============================================================================
|
|
10
|
+
// INVENTORY ENRICHMENT
|
|
11
|
+
// ============================================================================
|
|
12
|
+
exports.InventoryEnrichmentSchema = zod_1.z.object({
|
|
13
|
+
sku: zod_1.z.string(),
|
|
14
|
+
available: zod_1.z.number().int(),
|
|
15
|
+
reserved: zod_1.z.number().int().default(0),
|
|
16
|
+
incoming: zod_1.z.number().int().default(0),
|
|
17
|
+
locations: zod_1.z.array(zod_1.z.object({
|
|
18
|
+
name: zod_1.z.string(),
|
|
19
|
+
quantity: zod_1.z.number().int(),
|
|
20
|
+
locationId: zod_1.z.string().optional(),
|
|
21
|
+
})).optional(),
|
|
22
|
+
fetchedAt: zod_1.z.date(),
|
|
23
|
+
});
|
|
24
|
+
// ============================================================================
|
|
25
|
+
// PRICING ENRICHMENT
|
|
26
|
+
// ============================================================================
|
|
27
|
+
exports.PricingEnrichmentSchema = zod_1.z.object({
|
|
28
|
+
sku: zod_1.z.string(),
|
|
29
|
+
costPrice: common_1.MoneySchema.optional(),
|
|
30
|
+
retailPrice: common_1.MoneySchema,
|
|
31
|
+
salePrice: common_1.MoneySchema.optional(),
|
|
32
|
+
mapPrice: common_1.MoneySchema.optional(), // Minimum Advertised Price
|
|
33
|
+
// Calculated fields
|
|
34
|
+
margin: zod_1.z.number().optional(), // e.g., 0.45 for 45%
|
|
35
|
+
markupPercentage: zod_1.z.number().optional(),
|
|
36
|
+
priceRules: zod_1.z.array(zod_1.z.object({
|
|
37
|
+
name: zod_1.z.string(),
|
|
38
|
+
discount: zod_1.z.number(), // e.g., 10.00 or percentage 0.10
|
|
39
|
+
type: zod_1.z.enum(['fixed', 'percent']),
|
|
40
|
+
customerGroup: zod_1.z.string().optional(),
|
|
41
|
+
})).optional(),
|
|
42
|
+
fetchedAt: zod_1.z.date(),
|
|
43
|
+
});
|
|
44
|
+
// ============================================================================
|
|
45
|
+
// CATEGORY ENRICHMENT
|
|
46
|
+
// ============================================================================
|
|
47
|
+
exports.CategoryEnrichmentSchema = zod_1.z.object({
|
|
48
|
+
categories: zod_1.z.array(zod_1.z.object({
|
|
49
|
+
id: zod_1.z.string(),
|
|
50
|
+
code: zod_1.z.string().optional(),
|
|
51
|
+
name: zod_1.z.string(),
|
|
52
|
+
path: zod_1.z.array(zod_1.z.string()), // ['Mens', 'Shoes', 'Running']
|
|
53
|
+
level: zod_1.z.number().int(),
|
|
54
|
+
})),
|
|
55
|
+
primaryCategory: zod_1.z.string().optional(), // ID of primary category
|
|
56
|
+
fetchedAt: zod_1.z.date(),
|
|
57
|
+
});
|
|
58
|
+
// ============================================================================
|
|
59
|
+
// IMAGE ENRICHMENT
|
|
60
|
+
// ============================================================================
|
|
61
|
+
exports.ImageEnrichmentSchema = zod_1.z.object({
|
|
62
|
+
images: zod_1.z.array(zod_1.z.object({
|
|
63
|
+
url: zod_1.z.string().url(),
|
|
64
|
+
optimizedUrl: zod_1.z.string().url().optional(),
|
|
65
|
+
thumbnailUrl: zod_1.z.string().url().optional(),
|
|
66
|
+
alt: zod_1.z.string().optional(),
|
|
67
|
+
width: zod_1.z.number().int().optional(),
|
|
68
|
+
height: zod_1.z.number().int().optional(),
|
|
69
|
+
fileSize: zod_1.z.number().int().optional(), // in bytes
|
|
70
|
+
type: zod_1.z.string().optional(), // mime type
|
|
71
|
+
})),
|
|
72
|
+
processedAt: zod_1.z.date(),
|
|
73
|
+
});
|
|
74
|
+
// ============================================================================
|
|
75
|
+
// SHIPPING ENRICHMENT
|
|
76
|
+
// ============================================================================
|
|
77
|
+
exports.ShippingEnrichmentSchema = zod_1.z.object({
|
|
78
|
+
weight: common_1.WeightSchema.optional(),
|
|
79
|
+
dimensions: common_1.DimensionsSchema.optional(),
|
|
80
|
+
shippingClass: zod_1.z.string().optional(),
|
|
81
|
+
estimatedCost: common_1.MoneySchema.optional(),
|
|
82
|
+
restrictions: zod_1.z.array(zod_1.z.string()).optional(), // e.g. "no-air-freight"
|
|
83
|
+
fetchedAt: zod_1.z.date(),
|
|
84
|
+
});
|
|
85
|
+
// ============================================================================
|
|
86
|
+
// TAX ENRICHMENT
|
|
87
|
+
// ============================================================================
|
|
88
|
+
exports.TaxEnrichmentSchema = zod_1.z.object({
|
|
89
|
+
taxable: zod_1.z.boolean(),
|
|
90
|
+
taxCode: zod_1.z.string().optional(), // Avalara/Vertex tax code
|
|
91
|
+
taxRate: zod_1.z.number().optional(), // 0.0825
|
|
92
|
+
taxAmount: common_1.MoneySchema.optional(),
|
|
93
|
+
jurisdiction: zod_1.z.string().optional(),
|
|
94
|
+
fetchedAt: zod_1.z.date(),
|
|
95
|
+
});
|
|
96
|
+
//# sourceMappingURL=enrichments.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"enrichments.js","sourceRoot":"","sources":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M,CAAC;IAC1C,OAAO,EAAE,OAAC,CAAC,OAAO,EAAE;IACpB,OAAO,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,EAAE,0BAA0B;IAC1D,OAAO,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,EAAE,SAAS;IACzC,SAAS,EAAE,oBAAW,CAAC,QAAQ,EAAE;IACjC,YAAY,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACnC,SAAS,EAAE,OAAC,CAAC,IAAI,EAAE;CACpB,CAAC,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tonytang99/integration-canonical",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.2.0",
|
|
4
4
|
"description": "Canonical data models for integration platform",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -14,6 +14,7 @@
|
|
|
14
14
|
"author": "tonytang99",
|
|
15
15
|
"license": "MIT",
|
|
16
16
|
"dependencies": {
|
|
17
|
+
"@tonytang99/integration-core": "^1.2.0",
|
|
17
18
|
"zod": "^3.22.0"
|
|
18
19
|
},
|
|
19
20
|
"devDependencies": {
|