controlresell 0.0.48 → 0.0.49
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/package.json +2 -2
- package/src/com/controlresell/models/items/CreatedItems.d.ts +120 -7
- package/src/com/controlresell/models/items/Item.d.ts +88 -5
- package/src/com/controlresell/models/items/Item.js +2 -0
- package/src/com/controlresell/models/items/Item.ts +2 -0
- package/src/com/controlresell/models/items/ItemsWithFilters.d.ts +120 -7
- package/src/com/controlresell/models/items/UpdatedItem.d.ts +120 -7
- package/src/com/controlresell/models/items/history/CreateItemHistoryPayload.d.ts +3 -3
- package/src/com/controlresell/models/items/history/CreateItemHistoryPayload.js +1 -1
- package/src/com/controlresell/models/items/history/CreateItemHistoryPayload.ts +1 -1
- package/src/com/controlresell/models/items/history/ItemHistory.d.ts +3 -3
- package/src/com/controlresell/models/items/history/ItemHistory.js +1 -1
- package/src/com/controlresell/models/items/history/ItemHistory.ts +1 -1
- package/src/com/controlresell/models/items/platforms/ItemOnPlatformsRequestWithItem.d.ts +120 -7
- package/src/com/controlresell/models/platforms/orders/CreateOrderPayload.d.ts +3 -3
- package/src/com/controlresell/models/platforms/orders/Order.d.ts +3 -3
- package/src/com/controlresell/models/platforms/orders/UpdateOrderPayload.d.ts +3 -3
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "controlresell",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.49",
|
|
4
4
|
"main": "src/index.js",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"test": "echo \"Error: no test specified\" && exit 1"
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
"typescript": "^5.8.2"
|
|
18
18
|
},
|
|
19
19
|
"dependencies": {
|
|
20
|
-
"controlresell-connector": "^0.0.
|
|
20
|
+
"controlresell-connector": "^0.0.18",
|
|
21
21
|
"zod": "^3.24.2",
|
|
22
22
|
"zodable-idschema": "^1.0.0"
|
|
23
23
|
}
|
|
@@ -212,21 +212,74 @@ export declare const CreatedItemsSchema: z.ZodObject<{
|
|
|
212
212
|
id: z.ZodString;
|
|
213
213
|
itemId: z.ZodUnion<[z.ZodNumber, z.ZodString]>;
|
|
214
214
|
type: z.ZodEnum<["IMPORTED", "PUBLISHED", "SCHEDULED", "UPDATED", "DELETED", "TO_BE_SENT", "IN_TRANSIT"]>;
|
|
215
|
-
data: z.ZodString
|
|
215
|
+
data: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
216
216
|
createdAt: z.ZodDate;
|
|
217
217
|
}, "strip", z.ZodTypeAny, {
|
|
218
218
|
type: "IMPORTED" | "PUBLISHED" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT";
|
|
219
219
|
id: string;
|
|
220
|
-
data: string;
|
|
221
220
|
createdAt: Date;
|
|
222
221
|
itemId: string | number;
|
|
222
|
+
data?: string | null | undefined;
|
|
223
223
|
}, {
|
|
224
224
|
type: "IMPORTED" | "PUBLISHED" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT";
|
|
225
225
|
id: string;
|
|
226
|
-
data: string;
|
|
227
226
|
createdAt: Date;
|
|
228
227
|
itemId: string | number;
|
|
228
|
+
data?: string | null | undefined;
|
|
229
229
|
}>>>;
|
|
230
|
+
itemOnPlatforms: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
|
|
231
|
+
id: z.ZodString;
|
|
232
|
+
itemId: z.ZodUnion<[z.ZodNumber, z.ZodString]>;
|
|
233
|
+
accountId: z.ZodString;
|
|
234
|
+
platformId: z.ZodString;
|
|
235
|
+
platformUrl: z.ZodString;
|
|
236
|
+
platformPrice: z.ZodNumber;
|
|
237
|
+
status: z.ZodEnum<["ONLINE", "DRAFT", "DELETED", "SOLD", "HIDDEN", "PENDING", "ERROR", "DISPUTE"]>;
|
|
238
|
+
account: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
239
|
+
userId: z.ZodUnion<[z.ZodNumber, z.ZodString]>;
|
|
240
|
+
accountId: z.ZodString;
|
|
241
|
+
platform: z.ZodEnum<["VINTED", "SHOPIFY"]>;
|
|
242
|
+
name: z.ZodString;
|
|
243
|
+
}, "strip", z.ZodTypeAny, {
|
|
244
|
+
platform: "VINTED" | "SHOPIFY";
|
|
245
|
+
accountId: string;
|
|
246
|
+
userId: string | number;
|
|
247
|
+
name: string;
|
|
248
|
+
}, {
|
|
249
|
+
platform: "VINTED" | "SHOPIFY";
|
|
250
|
+
accountId: string;
|
|
251
|
+
userId: string | number;
|
|
252
|
+
name: string;
|
|
253
|
+
}>>>;
|
|
254
|
+
}, "strip", z.ZodTypeAny, {
|
|
255
|
+
status: "DELETED" | "ONLINE" | "DRAFT" | "SOLD" | "HIDDEN" | "PENDING" | "ERROR" | "DISPUTE";
|
|
256
|
+
id: string;
|
|
257
|
+
accountId: string;
|
|
258
|
+
itemId: string | number;
|
|
259
|
+
platformId: string;
|
|
260
|
+
platformUrl: string;
|
|
261
|
+
platformPrice: number;
|
|
262
|
+
account?: {
|
|
263
|
+
platform: "VINTED" | "SHOPIFY";
|
|
264
|
+
accountId: string;
|
|
265
|
+
userId: string | number;
|
|
266
|
+
name: string;
|
|
267
|
+
} | null | undefined;
|
|
268
|
+
}, {
|
|
269
|
+
status: "DELETED" | "ONLINE" | "DRAFT" | "SOLD" | "HIDDEN" | "PENDING" | "ERROR" | "DISPUTE";
|
|
270
|
+
id: string;
|
|
271
|
+
accountId: string;
|
|
272
|
+
itemId: string | number;
|
|
273
|
+
platformId: string;
|
|
274
|
+
platformUrl: string;
|
|
275
|
+
platformPrice: number;
|
|
276
|
+
account?: {
|
|
277
|
+
platform: "VINTED" | "SHOPIFY";
|
|
278
|
+
accountId: string;
|
|
279
|
+
userId: string | number;
|
|
280
|
+
name: string;
|
|
281
|
+
} | null | undefined;
|
|
282
|
+
}>, "many">>>;
|
|
230
283
|
createdAt: z.ZodDate;
|
|
231
284
|
updatedAt: z.ZodDate;
|
|
232
285
|
}, "strip", z.ZodTypeAny, {
|
|
@@ -318,10 +371,25 @@ export declare const CreatedItemsSchema: z.ZodObject<{
|
|
|
318
371
|
lastHistory?: {
|
|
319
372
|
type: "IMPORTED" | "PUBLISHED" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT";
|
|
320
373
|
id: string;
|
|
321
|
-
data: string;
|
|
322
374
|
createdAt: Date;
|
|
323
375
|
itemId: string | number;
|
|
376
|
+
data?: string | null | undefined;
|
|
324
377
|
} | null | undefined;
|
|
378
|
+
itemOnPlatforms?: {
|
|
379
|
+
status: "DELETED" | "ONLINE" | "DRAFT" | "SOLD" | "HIDDEN" | "PENDING" | "ERROR" | "DISPUTE";
|
|
380
|
+
id: string;
|
|
381
|
+
accountId: string;
|
|
382
|
+
itemId: string | number;
|
|
383
|
+
platformId: string;
|
|
384
|
+
platformUrl: string;
|
|
385
|
+
platformPrice: number;
|
|
386
|
+
account?: {
|
|
387
|
+
platform: "VINTED" | "SHOPIFY";
|
|
388
|
+
accountId: string;
|
|
389
|
+
userId: string | number;
|
|
390
|
+
name: string;
|
|
391
|
+
} | null | undefined;
|
|
392
|
+
}[] | null | undefined;
|
|
325
393
|
}, {
|
|
326
394
|
id: string | number;
|
|
327
395
|
userId: string | number;
|
|
@@ -411,10 +479,25 @@ export declare const CreatedItemsSchema: z.ZodObject<{
|
|
|
411
479
|
lastHistory?: {
|
|
412
480
|
type: "IMPORTED" | "PUBLISHED" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT";
|
|
413
481
|
id: string;
|
|
414
|
-
data: string;
|
|
415
482
|
createdAt: Date;
|
|
416
483
|
itemId: string | number;
|
|
484
|
+
data?: string | null | undefined;
|
|
417
485
|
} | null | undefined;
|
|
486
|
+
itemOnPlatforms?: {
|
|
487
|
+
status: "DELETED" | "ONLINE" | "DRAFT" | "SOLD" | "HIDDEN" | "PENDING" | "ERROR" | "DISPUTE";
|
|
488
|
+
id: string;
|
|
489
|
+
accountId: string;
|
|
490
|
+
itemId: string | number;
|
|
491
|
+
platformId: string;
|
|
492
|
+
platformUrl: string;
|
|
493
|
+
platformPrice: number;
|
|
494
|
+
account?: {
|
|
495
|
+
platform: "VINTED" | "SHOPIFY";
|
|
496
|
+
accountId: string;
|
|
497
|
+
userId: string | number;
|
|
498
|
+
name: string;
|
|
499
|
+
} | null | undefined;
|
|
500
|
+
}[] | null | undefined;
|
|
418
501
|
}>, "many">;
|
|
419
502
|
newUserLabels: z.ZodArray<z.ZodObject<{
|
|
420
503
|
id: z.ZodUnion<[z.ZodNumber, z.ZodString]>;
|
|
@@ -522,10 +605,25 @@ export declare const CreatedItemsSchema: z.ZodObject<{
|
|
|
522
605
|
lastHistory?: {
|
|
523
606
|
type: "IMPORTED" | "PUBLISHED" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT";
|
|
524
607
|
id: string;
|
|
525
|
-
data: string;
|
|
526
608
|
createdAt: Date;
|
|
527
609
|
itemId: string | number;
|
|
610
|
+
data?: string | null | undefined;
|
|
528
611
|
} | null | undefined;
|
|
612
|
+
itemOnPlatforms?: {
|
|
613
|
+
status: "DELETED" | "ONLINE" | "DRAFT" | "SOLD" | "HIDDEN" | "PENDING" | "ERROR" | "DISPUTE";
|
|
614
|
+
id: string;
|
|
615
|
+
accountId: string;
|
|
616
|
+
itemId: string | number;
|
|
617
|
+
platformId: string;
|
|
618
|
+
platformUrl: string;
|
|
619
|
+
platformPrice: number;
|
|
620
|
+
account?: {
|
|
621
|
+
platform: "VINTED" | "SHOPIFY";
|
|
622
|
+
accountId: string;
|
|
623
|
+
userId: string | number;
|
|
624
|
+
name: string;
|
|
625
|
+
} | null | undefined;
|
|
626
|
+
}[] | null | undefined;
|
|
529
627
|
}[];
|
|
530
628
|
newUserLabels: {
|
|
531
629
|
id: string | number;
|
|
@@ -623,10 +721,25 @@ export declare const CreatedItemsSchema: z.ZodObject<{
|
|
|
623
721
|
lastHistory?: {
|
|
624
722
|
type: "IMPORTED" | "PUBLISHED" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT";
|
|
625
723
|
id: string;
|
|
626
|
-
data: string;
|
|
627
724
|
createdAt: Date;
|
|
628
725
|
itemId: string | number;
|
|
726
|
+
data?: string | null | undefined;
|
|
629
727
|
} | null | undefined;
|
|
728
|
+
itemOnPlatforms?: {
|
|
729
|
+
status: "DELETED" | "ONLINE" | "DRAFT" | "SOLD" | "HIDDEN" | "PENDING" | "ERROR" | "DISPUTE";
|
|
730
|
+
id: string;
|
|
731
|
+
accountId: string;
|
|
732
|
+
itemId: string | number;
|
|
733
|
+
platformId: string;
|
|
734
|
+
platformUrl: string;
|
|
735
|
+
platformPrice: number;
|
|
736
|
+
account?: {
|
|
737
|
+
platform: "VINTED" | "SHOPIFY";
|
|
738
|
+
accountId: string;
|
|
739
|
+
userId: string | number;
|
|
740
|
+
name: string;
|
|
741
|
+
} | null | undefined;
|
|
742
|
+
}[] | null | undefined;
|
|
630
743
|
}[];
|
|
631
744
|
newUserLabels: {
|
|
632
745
|
id: string | number;
|
|
@@ -211,21 +211,74 @@ export declare const ItemSchema: z.ZodObject<{
|
|
|
211
211
|
id: z.ZodString;
|
|
212
212
|
itemId: z.ZodUnion<[z.ZodNumber, z.ZodString]>;
|
|
213
213
|
type: z.ZodEnum<["IMPORTED", "PUBLISHED", "SCHEDULED", "UPDATED", "DELETED", "TO_BE_SENT", "IN_TRANSIT"]>;
|
|
214
|
-
data: z.ZodString
|
|
214
|
+
data: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
215
215
|
createdAt: z.ZodDate;
|
|
216
216
|
}, "strip", z.ZodTypeAny, {
|
|
217
217
|
type: "IMPORTED" | "PUBLISHED" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT";
|
|
218
218
|
id: string;
|
|
219
|
-
data: string;
|
|
220
219
|
createdAt: Date;
|
|
221
220
|
itemId: string | number;
|
|
221
|
+
data?: string | null | undefined;
|
|
222
222
|
}, {
|
|
223
223
|
type: "IMPORTED" | "PUBLISHED" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT";
|
|
224
224
|
id: string;
|
|
225
|
-
data: string;
|
|
226
225
|
createdAt: Date;
|
|
227
226
|
itemId: string | number;
|
|
227
|
+
data?: string | null | undefined;
|
|
228
228
|
}>>>;
|
|
229
|
+
itemOnPlatforms: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
|
|
230
|
+
id: z.ZodString;
|
|
231
|
+
itemId: z.ZodUnion<[z.ZodNumber, z.ZodString]>;
|
|
232
|
+
accountId: z.ZodString;
|
|
233
|
+
platformId: z.ZodString;
|
|
234
|
+
platformUrl: z.ZodString;
|
|
235
|
+
platformPrice: z.ZodNumber;
|
|
236
|
+
status: z.ZodEnum<["ONLINE", "DRAFT", "DELETED", "SOLD", "HIDDEN", "PENDING", "ERROR", "DISPUTE"]>;
|
|
237
|
+
account: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
238
|
+
userId: z.ZodUnion<[z.ZodNumber, z.ZodString]>;
|
|
239
|
+
accountId: z.ZodString;
|
|
240
|
+
platform: z.ZodEnum<["VINTED", "SHOPIFY"]>;
|
|
241
|
+
name: z.ZodString;
|
|
242
|
+
}, "strip", z.ZodTypeAny, {
|
|
243
|
+
platform: "VINTED" | "SHOPIFY";
|
|
244
|
+
accountId: string;
|
|
245
|
+
userId: string | number;
|
|
246
|
+
name: string;
|
|
247
|
+
}, {
|
|
248
|
+
platform: "VINTED" | "SHOPIFY";
|
|
249
|
+
accountId: string;
|
|
250
|
+
userId: string | number;
|
|
251
|
+
name: string;
|
|
252
|
+
}>>>;
|
|
253
|
+
}, "strip", z.ZodTypeAny, {
|
|
254
|
+
status: "DELETED" | "ONLINE" | "DRAFT" | "SOLD" | "HIDDEN" | "PENDING" | "ERROR" | "DISPUTE";
|
|
255
|
+
id: string;
|
|
256
|
+
accountId: string;
|
|
257
|
+
itemId: string | number;
|
|
258
|
+
platformId: string;
|
|
259
|
+
platformUrl: string;
|
|
260
|
+
platformPrice: number;
|
|
261
|
+
account?: {
|
|
262
|
+
platform: "VINTED" | "SHOPIFY";
|
|
263
|
+
accountId: string;
|
|
264
|
+
userId: string | number;
|
|
265
|
+
name: string;
|
|
266
|
+
} | null | undefined;
|
|
267
|
+
}, {
|
|
268
|
+
status: "DELETED" | "ONLINE" | "DRAFT" | "SOLD" | "HIDDEN" | "PENDING" | "ERROR" | "DISPUTE";
|
|
269
|
+
id: string;
|
|
270
|
+
accountId: string;
|
|
271
|
+
itemId: string | number;
|
|
272
|
+
platformId: string;
|
|
273
|
+
platformUrl: string;
|
|
274
|
+
platformPrice: number;
|
|
275
|
+
account?: {
|
|
276
|
+
platform: "VINTED" | "SHOPIFY";
|
|
277
|
+
accountId: string;
|
|
278
|
+
userId: string | number;
|
|
279
|
+
name: string;
|
|
280
|
+
} | null | undefined;
|
|
281
|
+
}>, "many">>>;
|
|
229
282
|
createdAt: z.ZodDate;
|
|
230
283
|
updatedAt: z.ZodDate;
|
|
231
284
|
}, "strip", z.ZodTypeAny, {
|
|
@@ -317,10 +370,25 @@ export declare const ItemSchema: z.ZodObject<{
|
|
|
317
370
|
lastHistory?: {
|
|
318
371
|
type: "IMPORTED" | "PUBLISHED" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT";
|
|
319
372
|
id: string;
|
|
320
|
-
data: string;
|
|
321
373
|
createdAt: Date;
|
|
322
374
|
itemId: string | number;
|
|
375
|
+
data?: string | null | undefined;
|
|
323
376
|
} | null | undefined;
|
|
377
|
+
itemOnPlatforms?: {
|
|
378
|
+
status: "DELETED" | "ONLINE" | "DRAFT" | "SOLD" | "HIDDEN" | "PENDING" | "ERROR" | "DISPUTE";
|
|
379
|
+
id: string;
|
|
380
|
+
accountId: string;
|
|
381
|
+
itemId: string | number;
|
|
382
|
+
platformId: string;
|
|
383
|
+
platformUrl: string;
|
|
384
|
+
platformPrice: number;
|
|
385
|
+
account?: {
|
|
386
|
+
platform: "VINTED" | "SHOPIFY";
|
|
387
|
+
accountId: string;
|
|
388
|
+
userId: string | number;
|
|
389
|
+
name: string;
|
|
390
|
+
} | null | undefined;
|
|
391
|
+
}[] | null | undefined;
|
|
324
392
|
}, {
|
|
325
393
|
id: string | number;
|
|
326
394
|
userId: string | number;
|
|
@@ -410,9 +478,24 @@ export declare const ItemSchema: z.ZodObject<{
|
|
|
410
478
|
lastHistory?: {
|
|
411
479
|
type: "IMPORTED" | "PUBLISHED" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT";
|
|
412
480
|
id: string;
|
|
413
|
-
data: string;
|
|
414
481
|
createdAt: Date;
|
|
415
482
|
itemId: string | number;
|
|
483
|
+
data?: string | null | undefined;
|
|
416
484
|
} | null | undefined;
|
|
485
|
+
itemOnPlatforms?: {
|
|
486
|
+
status: "DELETED" | "ONLINE" | "DRAFT" | "SOLD" | "HIDDEN" | "PENDING" | "ERROR" | "DISPUTE";
|
|
487
|
+
id: string;
|
|
488
|
+
accountId: string;
|
|
489
|
+
itemId: string | number;
|
|
490
|
+
platformId: string;
|
|
491
|
+
platformUrl: string;
|
|
492
|
+
platformPrice: number;
|
|
493
|
+
account?: {
|
|
494
|
+
platform: "VINTED" | "SHOPIFY";
|
|
495
|
+
accountId: string;
|
|
496
|
+
userId: string | number;
|
|
497
|
+
name: string;
|
|
498
|
+
} | null | undefined;
|
|
499
|
+
}[] | null | undefined;
|
|
417
500
|
}>;
|
|
418
501
|
export type Item = z.infer<typeof ItemSchema>;
|
|
@@ -9,6 +9,7 @@ const ItemLabel_1 = require("./labels/ItemLabel");
|
|
|
9
9
|
const Customer_1 = require("../customers/Customer");
|
|
10
10
|
const ItemField_1 = require("./fields/ItemField");
|
|
11
11
|
const ItemHistory_1 = require("./history/ItemHistory");
|
|
12
|
+
const ItemOnPlatform_1 = require("./platforms/ItemOnPlatform");
|
|
12
13
|
exports.ItemSchema = zod_1.z.object({
|
|
13
14
|
id: zodable_idschema_1.IdSchema,
|
|
14
15
|
userId: zodable_idschema_1.IdSchema,
|
|
@@ -43,6 +44,7 @@ exports.ItemSchema = zod_1.z.object({
|
|
|
43
44
|
contractId: zodable_idschema_1.IdSchema.nullish(),
|
|
44
45
|
fields: zod_1.z.array(ItemField_1.ItemFieldSchema).nullish(),
|
|
45
46
|
lastHistory: ItemHistory_1.ItemHistorySchema.nullish(),
|
|
47
|
+
itemOnPlatforms: zod_1.z.array(ItemOnPlatform_1.ItemOnPlatformSchema).nullish(),
|
|
46
48
|
createdAt: zod_1.z.coerce.date(),
|
|
47
49
|
updatedAt: zod_1.z.coerce.date()
|
|
48
50
|
});
|
|
@@ -6,6 +6,7 @@ import {ItemLabelSchema} from "./labels/ItemLabel"
|
|
|
6
6
|
import {CustomerSchema} from "../customers/Customer"
|
|
7
7
|
import {ItemFieldSchema} from "./fields/ItemField"
|
|
8
8
|
import {ItemHistorySchema} from "./history/ItemHistory"
|
|
9
|
+
import {ItemOnPlatformSchema} from "./platforms/ItemOnPlatform"
|
|
9
10
|
|
|
10
11
|
export const ItemSchema = z.object({
|
|
11
12
|
id: IdSchema,
|
|
@@ -41,6 +42,7 @@ export const ItemSchema = z.object({
|
|
|
41
42
|
contractId: IdSchema.nullish(),
|
|
42
43
|
fields: z.array(ItemFieldSchema).nullish(),
|
|
43
44
|
lastHistory: ItemHistorySchema.nullish(),
|
|
45
|
+
itemOnPlatforms: z.array(ItemOnPlatformSchema).nullish(),
|
|
44
46
|
createdAt: z.coerce.date(),
|
|
45
47
|
updatedAt: z.coerce.date()
|
|
46
48
|
})
|
|
@@ -214,21 +214,74 @@ export declare const ItemsWithFiltersSchema: z.ZodObject<{
|
|
|
214
214
|
id: z.ZodString;
|
|
215
215
|
itemId: z.ZodUnion<[z.ZodNumber, z.ZodString]>;
|
|
216
216
|
type: z.ZodEnum<["IMPORTED", "PUBLISHED", "SCHEDULED", "UPDATED", "DELETED", "TO_BE_SENT", "IN_TRANSIT"]>;
|
|
217
|
-
data: z.ZodString
|
|
217
|
+
data: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
218
218
|
createdAt: z.ZodDate;
|
|
219
219
|
}, "strip", z.ZodTypeAny, {
|
|
220
220
|
type: "IMPORTED" | "PUBLISHED" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT";
|
|
221
221
|
id: string;
|
|
222
|
-
data: string;
|
|
223
222
|
createdAt: Date;
|
|
224
223
|
itemId: string | number;
|
|
224
|
+
data?: string | null | undefined;
|
|
225
225
|
}, {
|
|
226
226
|
type: "IMPORTED" | "PUBLISHED" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT";
|
|
227
227
|
id: string;
|
|
228
|
-
data: string;
|
|
229
228
|
createdAt: Date;
|
|
230
229
|
itemId: string | number;
|
|
230
|
+
data?: string | null | undefined;
|
|
231
231
|
}>>>;
|
|
232
|
+
itemOnPlatforms: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
|
|
233
|
+
id: z.ZodString;
|
|
234
|
+
itemId: z.ZodUnion<[z.ZodNumber, z.ZodString]>;
|
|
235
|
+
accountId: z.ZodString;
|
|
236
|
+
platformId: z.ZodString;
|
|
237
|
+
platformUrl: z.ZodString;
|
|
238
|
+
platformPrice: z.ZodNumber;
|
|
239
|
+
status: z.ZodEnum<["ONLINE", "DRAFT", "DELETED", "SOLD", "HIDDEN", "PENDING", "ERROR", "DISPUTE"]>;
|
|
240
|
+
account: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
241
|
+
userId: z.ZodUnion<[z.ZodNumber, z.ZodString]>;
|
|
242
|
+
accountId: z.ZodString;
|
|
243
|
+
platform: z.ZodEnum<["VINTED", "SHOPIFY"]>;
|
|
244
|
+
name: z.ZodString;
|
|
245
|
+
}, "strip", z.ZodTypeAny, {
|
|
246
|
+
platform: "VINTED" | "SHOPIFY";
|
|
247
|
+
accountId: string;
|
|
248
|
+
userId: string | number;
|
|
249
|
+
name: string;
|
|
250
|
+
}, {
|
|
251
|
+
platform: "VINTED" | "SHOPIFY";
|
|
252
|
+
accountId: string;
|
|
253
|
+
userId: string | number;
|
|
254
|
+
name: string;
|
|
255
|
+
}>>>;
|
|
256
|
+
}, "strip", z.ZodTypeAny, {
|
|
257
|
+
status: "DELETED" | "ONLINE" | "DRAFT" | "SOLD" | "HIDDEN" | "PENDING" | "ERROR" | "DISPUTE";
|
|
258
|
+
id: string;
|
|
259
|
+
accountId: string;
|
|
260
|
+
itemId: string | number;
|
|
261
|
+
platformId: string;
|
|
262
|
+
platformUrl: string;
|
|
263
|
+
platformPrice: number;
|
|
264
|
+
account?: {
|
|
265
|
+
platform: "VINTED" | "SHOPIFY";
|
|
266
|
+
accountId: string;
|
|
267
|
+
userId: string | number;
|
|
268
|
+
name: string;
|
|
269
|
+
} | null | undefined;
|
|
270
|
+
}, {
|
|
271
|
+
status: "DELETED" | "ONLINE" | "DRAFT" | "SOLD" | "HIDDEN" | "PENDING" | "ERROR" | "DISPUTE";
|
|
272
|
+
id: string;
|
|
273
|
+
accountId: string;
|
|
274
|
+
itemId: string | number;
|
|
275
|
+
platformId: string;
|
|
276
|
+
platformUrl: string;
|
|
277
|
+
platformPrice: number;
|
|
278
|
+
account?: {
|
|
279
|
+
platform: "VINTED" | "SHOPIFY";
|
|
280
|
+
accountId: string;
|
|
281
|
+
userId: string | number;
|
|
282
|
+
name: string;
|
|
283
|
+
} | null | undefined;
|
|
284
|
+
}>, "many">>>;
|
|
232
285
|
createdAt: z.ZodDate;
|
|
233
286
|
updatedAt: z.ZodDate;
|
|
234
287
|
}, "strip", z.ZodTypeAny, {
|
|
@@ -320,10 +373,25 @@ export declare const ItemsWithFiltersSchema: z.ZodObject<{
|
|
|
320
373
|
lastHistory?: {
|
|
321
374
|
type: "IMPORTED" | "PUBLISHED" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT";
|
|
322
375
|
id: string;
|
|
323
|
-
data: string;
|
|
324
376
|
createdAt: Date;
|
|
325
377
|
itemId: string | number;
|
|
378
|
+
data?: string | null | undefined;
|
|
326
379
|
} | null | undefined;
|
|
380
|
+
itemOnPlatforms?: {
|
|
381
|
+
status: "DELETED" | "ONLINE" | "DRAFT" | "SOLD" | "HIDDEN" | "PENDING" | "ERROR" | "DISPUTE";
|
|
382
|
+
id: string;
|
|
383
|
+
accountId: string;
|
|
384
|
+
itemId: string | number;
|
|
385
|
+
platformId: string;
|
|
386
|
+
platformUrl: string;
|
|
387
|
+
platformPrice: number;
|
|
388
|
+
account?: {
|
|
389
|
+
platform: "VINTED" | "SHOPIFY";
|
|
390
|
+
accountId: string;
|
|
391
|
+
userId: string | number;
|
|
392
|
+
name: string;
|
|
393
|
+
} | null | undefined;
|
|
394
|
+
}[] | null | undefined;
|
|
327
395
|
}, {
|
|
328
396
|
id: string | number;
|
|
329
397
|
userId: string | number;
|
|
@@ -413,10 +481,25 @@ export declare const ItemsWithFiltersSchema: z.ZodObject<{
|
|
|
413
481
|
lastHistory?: {
|
|
414
482
|
type: "IMPORTED" | "PUBLISHED" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT";
|
|
415
483
|
id: string;
|
|
416
|
-
data: string;
|
|
417
484
|
createdAt: Date;
|
|
418
485
|
itemId: string | number;
|
|
486
|
+
data?: string | null | undefined;
|
|
419
487
|
} | null | undefined;
|
|
488
|
+
itemOnPlatforms?: {
|
|
489
|
+
status: "DELETED" | "ONLINE" | "DRAFT" | "SOLD" | "HIDDEN" | "PENDING" | "ERROR" | "DISPUTE";
|
|
490
|
+
id: string;
|
|
491
|
+
accountId: string;
|
|
492
|
+
itemId: string | number;
|
|
493
|
+
platformId: string;
|
|
494
|
+
platformUrl: string;
|
|
495
|
+
platformPrice: number;
|
|
496
|
+
account?: {
|
|
497
|
+
platform: "VINTED" | "SHOPIFY";
|
|
498
|
+
accountId: string;
|
|
499
|
+
userId: string | number;
|
|
500
|
+
name: string;
|
|
501
|
+
} | null | undefined;
|
|
502
|
+
}[] | null | undefined;
|
|
420
503
|
}>, "many">;
|
|
421
504
|
currentPage: z.ZodNumber;
|
|
422
505
|
totalPages: z.ZodNumber;
|
|
@@ -566,10 +649,25 @@ export declare const ItemsWithFiltersSchema: z.ZodObject<{
|
|
|
566
649
|
lastHistory?: {
|
|
567
650
|
type: "IMPORTED" | "PUBLISHED" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT";
|
|
568
651
|
id: string;
|
|
569
|
-
data: string;
|
|
570
652
|
createdAt: Date;
|
|
571
653
|
itemId: string | number;
|
|
654
|
+
data?: string | null | undefined;
|
|
572
655
|
} | null | undefined;
|
|
656
|
+
itemOnPlatforms?: {
|
|
657
|
+
status: "DELETED" | "ONLINE" | "DRAFT" | "SOLD" | "HIDDEN" | "PENDING" | "ERROR" | "DISPUTE";
|
|
658
|
+
id: string;
|
|
659
|
+
accountId: string;
|
|
660
|
+
itemId: string | number;
|
|
661
|
+
platformId: string;
|
|
662
|
+
platformUrl: string;
|
|
663
|
+
platformPrice: number;
|
|
664
|
+
account?: {
|
|
665
|
+
platform: "VINTED" | "SHOPIFY";
|
|
666
|
+
accountId: string;
|
|
667
|
+
userId: string | number;
|
|
668
|
+
name: string;
|
|
669
|
+
} | null | undefined;
|
|
670
|
+
}[] | null | undefined;
|
|
573
671
|
}[];
|
|
574
672
|
currentPage: number;
|
|
575
673
|
totalPages: number;
|
|
@@ -682,10 +780,25 @@ export declare const ItemsWithFiltersSchema: z.ZodObject<{
|
|
|
682
780
|
lastHistory?: {
|
|
683
781
|
type: "IMPORTED" | "PUBLISHED" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT";
|
|
684
782
|
id: string;
|
|
685
|
-
data: string;
|
|
686
783
|
createdAt: Date;
|
|
687
784
|
itemId: string | number;
|
|
785
|
+
data?: string | null | undefined;
|
|
688
786
|
} | null | undefined;
|
|
787
|
+
itemOnPlatforms?: {
|
|
788
|
+
status: "DELETED" | "ONLINE" | "DRAFT" | "SOLD" | "HIDDEN" | "PENDING" | "ERROR" | "DISPUTE";
|
|
789
|
+
id: string;
|
|
790
|
+
accountId: string;
|
|
791
|
+
itemId: string | number;
|
|
792
|
+
platformId: string;
|
|
793
|
+
platformUrl: string;
|
|
794
|
+
platformPrice: number;
|
|
795
|
+
account?: {
|
|
796
|
+
platform: "VINTED" | "SHOPIFY";
|
|
797
|
+
accountId: string;
|
|
798
|
+
userId: string | number;
|
|
799
|
+
name: string;
|
|
800
|
+
} | null | undefined;
|
|
801
|
+
}[] | null | undefined;
|
|
689
802
|
}[];
|
|
690
803
|
currentPage: number;
|
|
691
804
|
totalPages: number;
|
|
@@ -212,21 +212,74 @@ export declare const UpdatedItemSchema: z.ZodObject<{
|
|
|
212
212
|
id: z.ZodString;
|
|
213
213
|
itemId: z.ZodUnion<[z.ZodNumber, z.ZodString]>;
|
|
214
214
|
type: z.ZodEnum<["IMPORTED", "PUBLISHED", "SCHEDULED", "UPDATED", "DELETED", "TO_BE_SENT", "IN_TRANSIT"]>;
|
|
215
|
-
data: z.ZodString
|
|
215
|
+
data: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
216
216
|
createdAt: z.ZodDate;
|
|
217
217
|
}, "strip", z.ZodTypeAny, {
|
|
218
218
|
type: "IMPORTED" | "PUBLISHED" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT";
|
|
219
219
|
id: string;
|
|
220
|
-
data: string;
|
|
221
220
|
createdAt: Date;
|
|
222
221
|
itemId: string | number;
|
|
222
|
+
data?: string | null | undefined;
|
|
223
223
|
}, {
|
|
224
224
|
type: "IMPORTED" | "PUBLISHED" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT";
|
|
225
225
|
id: string;
|
|
226
|
-
data: string;
|
|
227
226
|
createdAt: Date;
|
|
228
227
|
itemId: string | number;
|
|
228
|
+
data?: string | null | undefined;
|
|
229
229
|
}>>>;
|
|
230
|
+
itemOnPlatforms: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
|
|
231
|
+
id: z.ZodString;
|
|
232
|
+
itemId: z.ZodUnion<[z.ZodNumber, z.ZodString]>;
|
|
233
|
+
accountId: z.ZodString;
|
|
234
|
+
platformId: z.ZodString;
|
|
235
|
+
platformUrl: z.ZodString;
|
|
236
|
+
platformPrice: z.ZodNumber;
|
|
237
|
+
status: z.ZodEnum<["ONLINE", "DRAFT", "DELETED", "SOLD", "HIDDEN", "PENDING", "ERROR", "DISPUTE"]>;
|
|
238
|
+
account: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
239
|
+
userId: z.ZodUnion<[z.ZodNumber, z.ZodString]>;
|
|
240
|
+
accountId: z.ZodString;
|
|
241
|
+
platform: z.ZodEnum<["VINTED", "SHOPIFY"]>;
|
|
242
|
+
name: z.ZodString;
|
|
243
|
+
}, "strip", z.ZodTypeAny, {
|
|
244
|
+
platform: "VINTED" | "SHOPIFY";
|
|
245
|
+
accountId: string;
|
|
246
|
+
userId: string | number;
|
|
247
|
+
name: string;
|
|
248
|
+
}, {
|
|
249
|
+
platform: "VINTED" | "SHOPIFY";
|
|
250
|
+
accountId: string;
|
|
251
|
+
userId: string | number;
|
|
252
|
+
name: string;
|
|
253
|
+
}>>>;
|
|
254
|
+
}, "strip", z.ZodTypeAny, {
|
|
255
|
+
status: "DELETED" | "ONLINE" | "DRAFT" | "SOLD" | "HIDDEN" | "PENDING" | "ERROR" | "DISPUTE";
|
|
256
|
+
id: string;
|
|
257
|
+
accountId: string;
|
|
258
|
+
itemId: string | number;
|
|
259
|
+
platformId: string;
|
|
260
|
+
platformUrl: string;
|
|
261
|
+
platformPrice: number;
|
|
262
|
+
account?: {
|
|
263
|
+
platform: "VINTED" | "SHOPIFY";
|
|
264
|
+
accountId: string;
|
|
265
|
+
userId: string | number;
|
|
266
|
+
name: string;
|
|
267
|
+
} | null | undefined;
|
|
268
|
+
}, {
|
|
269
|
+
status: "DELETED" | "ONLINE" | "DRAFT" | "SOLD" | "HIDDEN" | "PENDING" | "ERROR" | "DISPUTE";
|
|
270
|
+
id: string;
|
|
271
|
+
accountId: string;
|
|
272
|
+
itemId: string | number;
|
|
273
|
+
platformId: string;
|
|
274
|
+
platformUrl: string;
|
|
275
|
+
platformPrice: number;
|
|
276
|
+
account?: {
|
|
277
|
+
platform: "VINTED" | "SHOPIFY";
|
|
278
|
+
accountId: string;
|
|
279
|
+
userId: string | number;
|
|
280
|
+
name: string;
|
|
281
|
+
} | null | undefined;
|
|
282
|
+
}>, "many">>>;
|
|
230
283
|
createdAt: z.ZodDate;
|
|
231
284
|
updatedAt: z.ZodDate;
|
|
232
285
|
}, "strip", z.ZodTypeAny, {
|
|
@@ -318,10 +371,25 @@ export declare const UpdatedItemSchema: z.ZodObject<{
|
|
|
318
371
|
lastHistory?: {
|
|
319
372
|
type: "IMPORTED" | "PUBLISHED" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT";
|
|
320
373
|
id: string;
|
|
321
|
-
data: string;
|
|
322
374
|
createdAt: Date;
|
|
323
375
|
itemId: string | number;
|
|
376
|
+
data?: string | null | undefined;
|
|
324
377
|
} | null | undefined;
|
|
378
|
+
itemOnPlatforms?: {
|
|
379
|
+
status: "DELETED" | "ONLINE" | "DRAFT" | "SOLD" | "HIDDEN" | "PENDING" | "ERROR" | "DISPUTE";
|
|
380
|
+
id: string;
|
|
381
|
+
accountId: string;
|
|
382
|
+
itemId: string | number;
|
|
383
|
+
platformId: string;
|
|
384
|
+
platformUrl: string;
|
|
385
|
+
platformPrice: number;
|
|
386
|
+
account?: {
|
|
387
|
+
platform: "VINTED" | "SHOPIFY";
|
|
388
|
+
accountId: string;
|
|
389
|
+
userId: string | number;
|
|
390
|
+
name: string;
|
|
391
|
+
} | null | undefined;
|
|
392
|
+
}[] | null | undefined;
|
|
325
393
|
}, {
|
|
326
394
|
id: string | number;
|
|
327
395
|
userId: string | number;
|
|
@@ -411,10 +479,25 @@ export declare const UpdatedItemSchema: z.ZodObject<{
|
|
|
411
479
|
lastHistory?: {
|
|
412
480
|
type: "IMPORTED" | "PUBLISHED" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT";
|
|
413
481
|
id: string;
|
|
414
|
-
data: string;
|
|
415
482
|
createdAt: Date;
|
|
416
483
|
itemId: string | number;
|
|
484
|
+
data?: string | null | undefined;
|
|
417
485
|
} | null | undefined;
|
|
486
|
+
itemOnPlatforms?: {
|
|
487
|
+
status: "DELETED" | "ONLINE" | "DRAFT" | "SOLD" | "HIDDEN" | "PENDING" | "ERROR" | "DISPUTE";
|
|
488
|
+
id: string;
|
|
489
|
+
accountId: string;
|
|
490
|
+
itemId: string | number;
|
|
491
|
+
platformId: string;
|
|
492
|
+
platformUrl: string;
|
|
493
|
+
platformPrice: number;
|
|
494
|
+
account?: {
|
|
495
|
+
platform: "VINTED" | "SHOPIFY";
|
|
496
|
+
accountId: string;
|
|
497
|
+
userId: string | number;
|
|
498
|
+
name: string;
|
|
499
|
+
} | null | undefined;
|
|
500
|
+
}[] | null | undefined;
|
|
418
501
|
}>;
|
|
419
502
|
newUserLabels: z.ZodArray<z.ZodObject<{
|
|
420
503
|
id: z.ZodUnion<[z.ZodNumber, z.ZodString]>;
|
|
@@ -528,10 +611,25 @@ export declare const UpdatedItemSchema: z.ZodObject<{
|
|
|
528
611
|
lastHistory?: {
|
|
529
612
|
type: "IMPORTED" | "PUBLISHED" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT";
|
|
530
613
|
id: string;
|
|
531
|
-
data: string;
|
|
532
614
|
createdAt: Date;
|
|
533
615
|
itemId: string | number;
|
|
616
|
+
data?: string | null | undefined;
|
|
534
617
|
} | null | undefined;
|
|
618
|
+
itemOnPlatforms?: {
|
|
619
|
+
status: "DELETED" | "ONLINE" | "DRAFT" | "SOLD" | "HIDDEN" | "PENDING" | "ERROR" | "DISPUTE";
|
|
620
|
+
id: string;
|
|
621
|
+
accountId: string;
|
|
622
|
+
itemId: string | number;
|
|
623
|
+
platformId: string;
|
|
624
|
+
platformUrl: string;
|
|
625
|
+
platformPrice: number;
|
|
626
|
+
account?: {
|
|
627
|
+
platform: "VINTED" | "SHOPIFY";
|
|
628
|
+
accountId: string;
|
|
629
|
+
userId: string | number;
|
|
630
|
+
name: string;
|
|
631
|
+
} | null | undefined;
|
|
632
|
+
}[] | null | undefined;
|
|
535
633
|
};
|
|
536
634
|
}, {
|
|
537
635
|
newUserLabels: {
|
|
@@ -629,10 +727,25 @@ export declare const UpdatedItemSchema: z.ZodObject<{
|
|
|
629
727
|
lastHistory?: {
|
|
630
728
|
type: "IMPORTED" | "PUBLISHED" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT";
|
|
631
729
|
id: string;
|
|
632
|
-
data: string;
|
|
633
730
|
createdAt: Date;
|
|
634
731
|
itemId: string | number;
|
|
732
|
+
data?: string | null | undefined;
|
|
635
733
|
} | null | undefined;
|
|
734
|
+
itemOnPlatforms?: {
|
|
735
|
+
status: "DELETED" | "ONLINE" | "DRAFT" | "SOLD" | "HIDDEN" | "PENDING" | "ERROR" | "DISPUTE";
|
|
736
|
+
id: string;
|
|
737
|
+
accountId: string;
|
|
738
|
+
itemId: string | number;
|
|
739
|
+
platformId: string;
|
|
740
|
+
platformUrl: string;
|
|
741
|
+
platformPrice: number;
|
|
742
|
+
account?: {
|
|
743
|
+
platform: "VINTED" | "SHOPIFY";
|
|
744
|
+
accountId: string;
|
|
745
|
+
userId: string | number;
|
|
746
|
+
name: string;
|
|
747
|
+
} | null | undefined;
|
|
748
|
+
}[] | null | undefined;
|
|
636
749
|
};
|
|
637
750
|
}>;
|
|
638
751
|
export type UpdatedItem = z.infer<typeof UpdatedItemSchema>;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
2
|
export declare const CreateItemHistoryPayloadSchema: z.ZodObject<{
|
|
3
3
|
type: z.ZodEnum<["IMPORTED", "PUBLISHED", "SCHEDULED", "UPDATED", "DELETED", "TO_BE_SENT", "IN_TRANSIT"]>;
|
|
4
|
-
data: z.ZodString
|
|
4
|
+
data: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
5
5
|
}, "strip", z.ZodTypeAny, {
|
|
6
6
|
type: "IMPORTED" | "PUBLISHED" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT";
|
|
7
|
-
data
|
|
7
|
+
data?: string | null | undefined;
|
|
8
8
|
}, {
|
|
9
9
|
type: "IMPORTED" | "PUBLISHED" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT";
|
|
10
|
-
data
|
|
10
|
+
data?: string | null | undefined;
|
|
11
11
|
}>;
|
|
12
12
|
export type CreateItemHistoryPayload = z.infer<typeof CreateItemHistoryPayloadSchema>;
|
|
@@ -3,6 +3,6 @@ import {ItemHistoryTypeSchema} from "./ItemHistoryType"
|
|
|
3
3
|
|
|
4
4
|
export const CreateItemHistoryPayloadSchema = z.object({
|
|
5
5
|
type: ItemHistoryTypeSchema,
|
|
6
|
-
data: z.string()
|
|
6
|
+
data: z.string().nullish()
|
|
7
7
|
})
|
|
8
8
|
export type CreateItemHistoryPayload = z.infer<typeof CreateItemHistoryPayloadSchema>
|
|
@@ -3,19 +3,19 @@ export declare const ItemHistorySchema: z.ZodObject<{
|
|
|
3
3
|
id: z.ZodString;
|
|
4
4
|
itemId: z.ZodUnion<[z.ZodNumber, z.ZodString]>;
|
|
5
5
|
type: z.ZodEnum<["IMPORTED", "PUBLISHED", "SCHEDULED", "UPDATED", "DELETED", "TO_BE_SENT", "IN_TRANSIT"]>;
|
|
6
|
-
data: z.ZodString
|
|
6
|
+
data: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
7
7
|
createdAt: z.ZodDate;
|
|
8
8
|
}, "strip", z.ZodTypeAny, {
|
|
9
9
|
type: "IMPORTED" | "PUBLISHED" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT";
|
|
10
10
|
id: string;
|
|
11
|
-
data: string;
|
|
12
11
|
createdAt: Date;
|
|
13
12
|
itemId: string | number;
|
|
13
|
+
data?: string | null | undefined;
|
|
14
14
|
}, {
|
|
15
15
|
type: "IMPORTED" | "PUBLISHED" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT";
|
|
16
16
|
id: string;
|
|
17
|
-
data: string;
|
|
18
17
|
createdAt: Date;
|
|
19
18
|
itemId: string | number;
|
|
19
|
+
data?: string | null | undefined;
|
|
20
20
|
}>;
|
|
21
21
|
export type ItemHistory = z.infer<typeof ItemHistorySchema>;
|
|
@@ -8,6 +8,6 @@ exports.ItemHistorySchema = zod_1.z.object({
|
|
|
8
8
|
id: zod_1.z.string().uuid(),
|
|
9
9
|
itemId: zodable_idschema_1.IdSchema,
|
|
10
10
|
type: ItemHistoryType_1.ItemHistoryTypeSchema,
|
|
11
|
-
data: zod_1.z.string(),
|
|
11
|
+
data: zod_1.z.string().nullish(),
|
|
12
12
|
createdAt: zod_1.z.coerce.date()
|
|
13
13
|
});
|
|
@@ -6,7 +6,7 @@ export const ItemHistorySchema = z.object({
|
|
|
6
6
|
id: z.string().uuid(),
|
|
7
7
|
itemId: IdSchema,
|
|
8
8
|
type: ItemHistoryTypeSchema,
|
|
9
|
-
data: z.string(),
|
|
9
|
+
data: z.string().nullish(),
|
|
10
10
|
createdAt: z.coerce.date()
|
|
11
11
|
})
|
|
12
12
|
export type ItemHistory = z.infer<typeof ItemHistorySchema>
|
|
@@ -222,21 +222,74 @@ export declare const ItemOnPlatformsRequestWithItemSchema: z.ZodObject<{
|
|
|
222
222
|
id: z.ZodString;
|
|
223
223
|
itemId: z.ZodUnion<[z.ZodNumber, z.ZodString]>;
|
|
224
224
|
type: z.ZodEnum<["IMPORTED", "PUBLISHED", "SCHEDULED", "UPDATED", "DELETED", "TO_BE_SENT", "IN_TRANSIT"]>;
|
|
225
|
-
data: z.ZodString
|
|
225
|
+
data: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
226
226
|
createdAt: z.ZodDate;
|
|
227
227
|
}, "strip", z.ZodTypeAny, {
|
|
228
228
|
type: "IMPORTED" | "PUBLISHED" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT";
|
|
229
229
|
id: string;
|
|
230
|
-
data: string;
|
|
231
230
|
createdAt: Date;
|
|
232
231
|
itemId: string | number;
|
|
232
|
+
data?: string | null | undefined;
|
|
233
233
|
}, {
|
|
234
234
|
type: "IMPORTED" | "PUBLISHED" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT";
|
|
235
235
|
id: string;
|
|
236
|
-
data: string;
|
|
237
236
|
createdAt: Date;
|
|
238
237
|
itemId: string | number;
|
|
238
|
+
data?: string | null | undefined;
|
|
239
239
|
}>>>;
|
|
240
|
+
itemOnPlatforms: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
|
|
241
|
+
id: z.ZodString;
|
|
242
|
+
itemId: z.ZodUnion<[z.ZodNumber, z.ZodString]>;
|
|
243
|
+
accountId: z.ZodString;
|
|
244
|
+
platformId: z.ZodString;
|
|
245
|
+
platformUrl: z.ZodString;
|
|
246
|
+
platformPrice: z.ZodNumber;
|
|
247
|
+
status: z.ZodEnum<["ONLINE", "DRAFT", "DELETED", "SOLD", "HIDDEN", "PENDING", "ERROR", "DISPUTE"]>;
|
|
248
|
+
account: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
249
|
+
userId: z.ZodUnion<[z.ZodNumber, z.ZodString]>;
|
|
250
|
+
accountId: z.ZodString;
|
|
251
|
+
platform: z.ZodEnum<["VINTED", "SHOPIFY"]>;
|
|
252
|
+
name: z.ZodString;
|
|
253
|
+
}, "strip", z.ZodTypeAny, {
|
|
254
|
+
platform: "VINTED" | "SHOPIFY";
|
|
255
|
+
accountId: string;
|
|
256
|
+
userId: string | number;
|
|
257
|
+
name: string;
|
|
258
|
+
}, {
|
|
259
|
+
platform: "VINTED" | "SHOPIFY";
|
|
260
|
+
accountId: string;
|
|
261
|
+
userId: string | number;
|
|
262
|
+
name: string;
|
|
263
|
+
}>>>;
|
|
264
|
+
}, "strip", z.ZodTypeAny, {
|
|
265
|
+
status: "DELETED" | "ONLINE" | "DRAFT" | "SOLD" | "HIDDEN" | "PENDING" | "ERROR" | "DISPUTE";
|
|
266
|
+
id: string;
|
|
267
|
+
accountId: string;
|
|
268
|
+
itemId: string | number;
|
|
269
|
+
platformId: string;
|
|
270
|
+
platformUrl: string;
|
|
271
|
+
platformPrice: number;
|
|
272
|
+
account?: {
|
|
273
|
+
platform: "VINTED" | "SHOPIFY";
|
|
274
|
+
accountId: string;
|
|
275
|
+
userId: string | number;
|
|
276
|
+
name: string;
|
|
277
|
+
} | null | undefined;
|
|
278
|
+
}, {
|
|
279
|
+
status: "DELETED" | "ONLINE" | "DRAFT" | "SOLD" | "HIDDEN" | "PENDING" | "ERROR" | "DISPUTE";
|
|
280
|
+
id: string;
|
|
281
|
+
accountId: string;
|
|
282
|
+
itemId: string | number;
|
|
283
|
+
platformId: string;
|
|
284
|
+
platformUrl: string;
|
|
285
|
+
platformPrice: number;
|
|
286
|
+
account?: {
|
|
287
|
+
platform: "VINTED" | "SHOPIFY";
|
|
288
|
+
accountId: string;
|
|
289
|
+
userId: string | number;
|
|
290
|
+
name: string;
|
|
291
|
+
} | null | undefined;
|
|
292
|
+
}>, "many">>>;
|
|
240
293
|
createdAt: z.ZodDate;
|
|
241
294
|
updatedAt: z.ZodDate;
|
|
242
295
|
}, "strip", z.ZodTypeAny, {
|
|
@@ -328,10 +381,25 @@ export declare const ItemOnPlatformsRequestWithItemSchema: z.ZodObject<{
|
|
|
328
381
|
lastHistory?: {
|
|
329
382
|
type: "IMPORTED" | "PUBLISHED" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT";
|
|
330
383
|
id: string;
|
|
331
|
-
data: string;
|
|
332
384
|
createdAt: Date;
|
|
333
385
|
itemId: string | number;
|
|
386
|
+
data?: string | null | undefined;
|
|
334
387
|
} | null | undefined;
|
|
388
|
+
itemOnPlatforms?: {
|
|
389
|
+
status: "DELETED" | "ONLINE" | "DRAFT" | "SOLD" | "HIDDEN" | "PENDING" | "ERROR" | "DISPUTE";
|
|
390
|
+
id: string;
|
|
391
|
+
accountId: string;
|
|
392
|
+
itemId: string | number;
|
|
393
|
+
platformId: string;
|
|
394
|
+
platformUrl: string;
|
|
395
|
+
platformPrice: number;
|
|
396
|
+
account?: {
|
|
397
|
+
platform: "VINTED" | "SHOPIFY";
|
|
398
|
+
accountId: string;
|
|
399
|
+
userId: string | number;
|
|
400
|
+
name: string;
|
|
401
|
+
} | null | undefined;
|
|
402
|
+
}[] | null | undefined;
|
|
335
403
|
}, {
|
|
336
404
|
id: string | number;
|
|
337
405
|
userId: string | number;
|
|
@@ -421,10 +489,25 @@ export declare const ItemOnPlatformsRequestWithItemSchema: z.ZodObject<{
|
|
|
421
489
|
lastHistory?: {
|
|
422
490
|
type: "IMPORTED" | "PUBLISHED" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT";
|
|
423
491
|
id: string;
|
|
424
|
-
data: string;
|
|
425
492
|
createdAt: Date;
|
|
426
493
|
itemId: string | number;
|
|
494
|
+
data?: string | null | undefined;
|
|
427
495
|
} | null | undefined;
|
|
496
|
+
itemOnPlatforms?: {
|
|
497
|
+
status: "DELETED" | "ONLINE" | "DRAFT" | "SOLD" | "HIDDEN" | "PENDING" | "ERROR" | "DISPUTE";
|
|
498
|
+
id: string;
|
|
499
|
+
accountId: string;
|
|
500
|
+
itemId: string | number;
|
|
501
|
+
platformId: string;
|
|
502
|
+
platformUrl: string;
|
|
503
|
+
platformPrice: number;
|
|
504
|
+
account?: {
|
|
505
|
+
platform: "VINTED" | "SHOPIFY";
|
|
506
|
+
accountId: string;
|
|
507
|
+
userId: string | number;
|
|
508
|
+
name: string;
|
|
509
|
+
} | null | undefined;
|
|
510
|
+
}[] | null | undefined;
|
|
428
511
|
}>;
|
|
429
512
|
}, "strip", z.ZodTypeAny, {
|
|
430
513
|
item: {
|
|
@@ -516,10 +599,25 @@ export declare const ItemOnPlatformsRequestWithItemSchema: z.ZodObject<{
|
|
|
516
599
|
lastHistory?: {
|
|
517
600
|
type: "IMPORTED" | "PUBLISHED" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT";
|
|
518
601
|
id: string;
|
|
519
|
-
data: string;
|
|
520
602
|
createdAt: Date;
|
|
521
603
|
itemId: string | number;
|
|
604
|
+
data?: string | null | undefined;
|
|
522
605
|
} | null | undefined;
|
|
606
|
+
itemOnPlatforms?: {
|
|
607
|
+
status: "DELETED" | "ONLINE" | "DRAFT" | "SOLD" | "HIDDEN" | "PENDING" | "ERROR" | "DISPUTE";
|
|
608
|
+
id: string;
|
|
609
|
+
accountId: string;
|
|
610
|
+
itemId: string | number;
|
|
611
|
+
platformId: string;
|
|
612
|
+
platformUrl: string;
|
|
613
|
+
platformPrice: number;
|
|
614
|
+
account?: {
|
|
615
|
+
platform: "VINTED" | "SHOPIFY";
|
|
616
|
+
accountId: string;
|
|
617
|
+
userId: string | number;
|
|
618
|
+
name: string;
|
|
619
|
+
} | null | undefined;
|
|
620
|
+
}[] | null | undefined;
|
|
523
621
|
};
|
|
524
622
|
request: {
|
|
525
623
|
accountsId: string[];
|
|
@@ -615,10 +713,25 @@ export declare const ItemOnPlatformsRequestWithItemSchema: z.ZodObject<{
|
|
|
615
713
|
lastHistory?: {
|
|
616
714
|
type: "IMPORTED" | "PUBLISHED" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT";
|
|
617
715
|
id: string;
|
|
618
|
-
data: string;
|
|
619
716
|
createdAt: Date;
|
|
620
717
|
itemId: string | number;
|
|
718
|
+
data?: string | null | undefined;
|
|
621
719
|
} | null | undefined;
|
|
720
|
+
itemOnPlatforms?: {
|
|
721
|
+
status: "DELETED" | "ONLINE" | "DRAFT" | "SOLD" | "HIDDEN" | "PENDING" | "ERROR" | "DISPUTE";
|
|
722
|
+
id: string;
|
|
723
|
+
accountId: string;
|
|
724
|
+
itemId: string | number;
|
|
725
|
+
platformId: string;
|
|
726
|
+
platformUrl: string;
|
|
727
|
+
platformPrice: number;
|
|
728
|
+
account?: {
|
|
729
|
+
platform: "VINTED" | "SHOPIFY";
|
|
730
|
+
accountId: string;
|
|
731
|
+
userId: string | number;
|
|
732
|
+
name: string;
|
|
733
|
+
} | null | undefined;
|
|
734
|
+
}[] | null | undefined;
|
|
622
735
|
};
|
|
623
736
|
request: {
|
|
624
737
|
accountsId: string[];
|
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
2
|
export declare const CreateOrderPayloadSchema: z.ZodObject<{
|
|
3
3
|
platformOrderId: z.ZodString;
|
|
4
|
-
status: z.ZodEnum<["PAYMENT_VALIDATED", "SHIPPING_LABEL_SENT_TO_SELLER"]>;
|
|
4
|
+
status: z.ZodEnum<["PAYMENT_VALIDATED", "SHIPPING_LABEL_SENT_TO_SELLER", "ORDER_SHIPPED", "DELIVERED_TO_POST_OFFICE_OR_PICKUP_POINT", "ORDER_FINALIZED", "RETURN_INITIATED", "REFUND_DONE", "UNKNOWN"]>;
|
|
5
5
|
conversationId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
6
6
|
price: z.ZodNumber;
|
|
7
7
|
date: z.ZodDate;
|
|
8
8
|
}, "strip", z.ZodTypeAny, {
|
|
9
|
-
status: "PAYMENT_VALIDATED" | "SHIPPING_LABEL_SENT_TO_SELLER";
|
|
9
|
+
status: "PAYMENT_VALIDATED" | "SHIPPING_LABEL_SENT_TO_SELLER" | "ORDER_SHIPPED" | "DELIVERED_TO_POST_OFFICE_OR_PICKUP_POINT" | "ORDER_FINALIZED" | "RETURN_INITIATED" | "REFUND_DONE" | "UNKNOWN";
|
|
10
10
|
date: Date;
|
|
11
11
|
price: number;
|
|
12
12
|
platformOrderId: string;
|
|
13
13
|
conversationId?: string | null | undefined;
|
|
14
14
|
}, {
|
|
15
|
-
status: "PAYMENT_VALIDATED" | "SHIPPING_LABEL_SENT_TO_SELLER";
|
|
15
|
+
status: "PAYMENT_VALIDATED" | "SHIPPING_LABEL_SENT_TO_SELLER" | "ORDER_SHIPPED" | "DELIVERED_TO_POST_OFFICE_OR_PICKUP_POINT" | "ORDER_FINALIZED" | "RETURN_INITIATED" | "REFUND_DONE" | "UNKNOWN";
|
|
16
16
|
date: Date;
|
|
17
17
|
price: number;
|
|
18
18
|
platformOrderId: string;
|
|
@@ -3,7 +3,7 @@ export declare const OrderSchema: z.ZodObject<{
|
|
|
3
3
|
id: z.ZodString;
|
|
4
4
|
accountId: z.ZodString;
|
|
5
5
|
platformOrderId: z.ZodString;
|
|
6
|
-
status: z.ZodEnum<["PAYMENT_VALIDATED", "SHIPPING_LABEL_SENT_TO_SELLER"]>;
|
|
6
|
+
status: z.ZodEnum<["PAYMENT_VALIDATED", "SHIPPING_LABEL_SENT_TO_SELLER", "ORDER_SHIPPED", "DELIVERED_TO_POST_OFFICE_OR_PICKUP_POINT", "ORDER_FINALIZED", "RETURN_INITIATED", "REFUND_DONE", "UNKNOWN"]>;
|
|
7
7
|
conversationId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
8
8
|
price: z.ZodNumber;
|
|
9
9
|
date: z.ZodDate;
|
|
@@ -183,7 +183,7 @@ export declare const OrderSchema: z.ZodObject<{
|
|
|
183
183
|
} | null | undefined;
|
|
184
184
|
}>, "many">>>;
|
|
185
185
|
}, "strip", z.ZodTypeAny, {
|
|
186
|
-
status: "PAYMENT_VALIDATED" | "SHIPPING_LABEL_SENT_TO_SELLER";
|
|
186
|
+
status: "PAYMENT_VALIDATED" | "SHIPPING_LABEL_SENT_TO_SELLER" | "ORDER_SHIPPED" | "DELIVERED_TO_POST_OFFICE_OR_PICKUP_POINT" | "ORDER_FINALIZED" | "RETURN_INITIATED" | "REFUND_DONE" | "UNKNOWN";
|
|
187
187
|
id: string;
|
|
188
188
|
date: Date;
|
|
189
189
|
accountId: string;
|
|
@@ -230,7 +230,7 @@ export declare const OrderSchema: z.ZodObject<{
|
|
|
230
230
|
} | null | undefined;
|
|
231
231
|
}[] | null | undefined;
|
|
232
232
|
}, {
|
|
233
|
-
status: "PAYMENT_VALIDATED" | "SHIPPING_LABEL_SENT_TO_SELLER";
|
|
233
|
+
status: "PAYMENT_VALIDATED" | "SHIPPING_LABEL_SENT_TO_SELLER" | "ORDER_SHIPPED" | "DELIVERED_TO_POST_OFFICE_OR_PICKUP_POINT" | "ORDER_FINALIZED" | "RETURN_INITIATED" | "REFUND_DONE" | "UNKNOWN";
|
|
234
234
|
id: string;
|
|
235
235
|
date: Date;
|
|
236
236
|
accountId: string;
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
2
|
export declare const UpdateOrderPayloadSchema: z.ZodObject<{
|
|
3
|
-
status: z.ZodOptional<z.ZodNullable<z.ZodEnum<["PAYMENT_VALIDATED", "SHIPPING_LABEL_SENT_TO_SELLER"]>>>;
|
|
3
|
+
status: z.ZodOptional<z.ZodNullable<z.ZodEnum<["PAYMENT_VALIDATED", "SHIPPING_LABEL_SENT_TO_SELLER", "ORDER_SHIPPED", "DELIVERED_TO_POST_OFFICE_OR_PICKUP_POINT", "ORDER_FINALIZED", "RETURN_INITIATED", "REFUND_DONE", "UNKNOWN"]>>>;
|
|
4
4
|
conversationId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
5
5
|
price: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
6
6
|
date: z.ZodOptional<z.ZodNullable<z.ZodDate>>;
|
|
7
7
|
}, "strip", z.ZodTypeAny, {
|
|
8
|
-
status?: "PAYMENT_VALIDATED" | "SHIPPING_LABEL_SENT_TO_SELLER" | null | undefined;
|
|
8
|
+
status?: "PAYMENT_VALIDATED" | "SHIPPING_LABEL_SENT_TO_SELLER" | "ORDER_SHIPPED" | "DELIVERED_TO_POST_OFFICE_OR_PICKUP_POINT" | "ORDER_FINALIZED" | "RETURN_INITIATED" | "REFUND_DONE" | "UNKNOWN" | null | undefined;
|
|
9
9
|
date?: Date | null | undefined;
|
|
10
10
|
conversationId?: string | null | undefined;
|
|
11
11
|
price?: number | null | undefined;
|
|
12
12
|
}, {
|
|
13
|
-
status?: "PAYMENT_VALIDATED" | "SHIPPING_LABEL_SENT_TO_SELLER" | null | undefined;
|
|
13
|
+
status?: "PAYMENT_VALIDATED" | "SHIPPING_LABEL_SENT_TO_SELLER" | "ORDER_SHIPPED" | "DELIVERED_TO_POST_OFFICE_OR_PICKUP_POINT" | "ORDER_FINALIZED" | "RETURN_INITIATED" | "REFUND_DONE" | "UNKNOWN" | null | undefined;
|
|
14
14
|
date?: Date | null | undefined;
|
|
15
15
|
conversationId?: string | null | undefined;
|
|
16
16
|
price?: number | null | undefined;
|