controlresell 2.9.4 → 2.9.6

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.
Files changed (72) hide show
  1. package/package.json +2 -2
  2. package/src/com/controlresell/api/requests/items/cancel/CancelRequest.d.ts +16 -0
  3. package/src/com/controlresell/api/requests/items/cancel/CancelRequest.d.ts.map +1 -0
  4. package/src/com/controlresell/api/requests/items/cancel/CancelRequest.js +8 -0
  5. package/src/com/controlresell/api/requests/items/cancel/CancelRequest.js.map +1 -0
  6. package/src/com/controlresell/api/requests/items/cancel/CancelRequest.ts +9 -0
  7. package/src/com/controlresell/api/requests/items/cancel/CancelRequestAction.d.ts +4 -0
  8. package/src/com/controlresell/api/requests/items/cancel/CancelRequestAction.d.ts.map +1 -0
  9. package/src/com/controlresell/api/requests/items/cancel/CancelRequestAction.js +5 -0
  10. package/src/com/controlresell/api/requests/items/cancel/CancelRequestAction.js.map +1 -0
  11. package/src/com/controlresell/api/requests/items/cancel/CancelRequestAction.ts +6 -0
  12. package/src/com/controlresell/api/requests/items/publish/PublishRequest.d.ts +3 -0
  13. package/src/com/controlresell/api/requests/items/publish/PublishRequest.d.ts.map +1 -1
  14. package/src/com/controlresell/api/requests/items/publish/PublishRequest.js +1 -0
  15. package/src/com/controlresell/api/requests/items/publish/PublishRequest.js.map +1 -1
  16. package/src/com/controlresell/api/requests/items/publish/PublishRequest.ts +1 -0
  17. package/src/com/controlresell/api/requests/items/republish/RepublishRequest.d.ts +3 -0
  18. package/src/com/controlresell/api/requests/items/republish/RepublishRequest.d.ts.map +1 -1
  19. package/src/com/controlresell/api/requests/items/republish/RepublishRequest.js +1 -0
  20. package/src/com/controlresell/api/requests/items/republish/RepublishRequest.js.map +1 -1
  21. package/src/com/controlresell/api/requests/items/republish/RepublishRequest.ts +1 -0
  22. package/src/com/controlresell/api/responses/items/ItemActions.d.ts +10 -0
  23. package/src/com/controlresell/api/responses/items/ItemActions.d.ts.map +1 -0
  24. package/src/com/controlresell/api/responses/items/ItemActions.js +6 -0
  25. package/src/com/controlresell/api/responses/items/ItemActions.js.map +1 -0
  26. package/src/com/controlresell/api/responses/items/ItemActions.ts +7 -0
  27. package/src/com/controlresell/api/responses/items/ItemsWithFilters.d.ts +68 -5
  28. package/src/com/controlresell/api/responses/items/ItemsWithFilters.d.ts.map +1 -1
  29. package/src/com/controlresell/api/responses/items/ListedItem.d.ts +52 -3
  30. package/src/com/controlresell/api/responses/items/ListedItem.d.ts.map +1 -1
  31. package/src/com/controlresell/api/responses/items/ListedItem.js +2 -2
  32. package/src/com/controlresell/api/responses/items/ListedItem.js.map +1 -1
  33. package/src/com/controlresell/api/responses/items/ListedItem.ts +2 -2
  34. package/src/com/controlresell/api/responses/subscriptions/SubscriptionStatus.d.ts +2 -2
  35. package/src/com/controlresell/inbox/models/transactions/items/TransactionWithItems.d.ts +2235 -338
  36. package/src/com/controlresell/inbox/models/transactions/items/TransactionWithItems.d.ts.map +1 -1
  37. package/src/com/controlresell/inventory/models/items/CreatedItems.d.ts +2250 -353
  38. package/src/com/controlresell/inventory/models/items/CreatedItems.d.ts.map +1 -1
  39. package/src/com/controlresell/inventory/models/items/Item.d.ts +1701 -142
  40. package/src/com/controlresell/inventory/models/items/Item.d.ts.map +1 -1
  41. package/src/com/controlresell/inventory/models/items/Item.js +1 -0
  42. package/src/com/controlresell/inventory/models/items/Item.js.map +1 -1
  43. package/src/com/controlresell/inventory/models/items/Item.ts +1 -0
  44. package/src/com/controlresell/inventory/models/items/ItemUpdate.d.ts +2250 -353
  45. package/src/com/controlresell/inventory/models/items/ItemUpdate.d.ts.map +1 -1
  46. package/src/com/controlresell/inventory/models/items/UpdatedItem.d.ts +2250 -353
  47. package/src/com/controlresell/inventory/models/items/UpdatedItem.d.ts.map +1 -1
  48. package/src/com/controlresell/inventory/models/items/history/CreateItemHistoryPayload.d.ts +29 -0
  49. package/src/com/controlresell/inventory/models/items/history/CreateItemHistoryPayload.d.ts.map +1 -1
  50. package/src/com/controlresell/inventory/models/items/history/ItemHistory.d.ts +29 -0
  51. package/src/com/controlresell/inventory/models/items/history/ItemHistory.d.ts.map +1 -1
  52. package/src/com/controlresell/inventory/models/items/history/ItemHistoryDecodedPayload.d.ts +40 -0
  53. package/src/com/controlresell/inventory/models/items/history/ItemHistoryDecodedPayload.d.ts.map +1 -1
  54. package/src/com/controlresell/inventory/models/items/history/ItemHistoryDecodedPayload.js +6 -0
  55. package/src/com/controlresell/inventory/models/items/history/ItemHistoryDecodedPayload.js.map +1 -1
  56. package/src/com/controlresell/inventory/models/items/history/ItemHistoryDecodedPayload.ts +8 -0
  57. package/src/com/controlresell/inventory/models/items/history/data/ItemHistoryPublishedPayload.d.ts +10 -0
  58. package/src/com/controlresell/inventory/models/items/history/data/ItemHistoryPublishedPayload.d.ts.map +1 -0
  59. package/src/com/controlresell/inventory/models/items/history/data/ItemHistoryPublishedPayload.js +6 -0
  60. package/src/com/controlresell/inventory/models/items/history/data/ItemHistoryPublishedPayload.js.map +1 -0
  61. package/src/com/controlresell/inventory/models/items/history/data/ItemHistoryPublishedPayload.ts +7 -0
  62. package/src/com/controlresell/models/platforms/orders/UserOrders.d.ts +2766 -531
  63. package/src/com/controlresell/models/platforms/orders/UserOrders.d.ts.map +1 -1
  64. package/src/com/controlresell/models/platforms/orders/items/OrderWithItems.d.ts +2190 -293
  65. package/src/com/controlresell/models/platforms/orders/items/OrderWithItems.d.ts.map +1 -1
  66. package/src/com/controlresell/models/users/ws/UserWsPayload.d.ts +7057 -3263
  67. package/src/com/controlresell/models/users/ws/UserWsPayload.d.ts.map +1 -1
  68. package/src/index.d.ts +4 -0
  69. package/src/index.d.ts.map +1 -1
  70. package/src/index.js +4 -0
  71. package/src/index.js.map +1 -1
  72. package/src/index.ts +4 -0
@@ -769,6 +769,25 @@ export declare const CreatedItemsSchema: z.ZodObject<{
769
769
  accountId: string;
770
770
  caseId: string;
771
771
  };
772
+ }>, z.ZodObject<{
773
+ data: z.ZodObject<{
774
+ platform: z.ZodEnum<["ETSY", "SHOPIFY", "VINTED"]>;
775
+ }, "strip", z.ZodTypeAny, {
776
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
777
+ }, {
778
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
779
+ }>;
780
+ type: z.ZodLiteral<"PUBLISHED">;
781
+ }, "strip", z.ZodTypeAny, {
782
+ type: "PUBLISHED";
783
+ data: {
784
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
785
+ };
786
+ }, {
787
+ type: "PUBLISHED";
788
+ data: {
789
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
790
+ };
772
791
  }>, z.ZodObject<{
773
792
  data: z.ZodObject<{
774
793
  platform: z.ZodEnum<["ETSY", "SHOPIFY", "VINTED"]>;
@@ -1168,6 +1187,11 @@ export declare const CreatedItemsSchema: z.ZodObject<{
1168
1187
  accountId: string;
1169
1188
  caseId: string;
1170
1189
  };
1190
+ } | {
1191
+ type: "PUBLISHED";
1192
+ data: {
1193
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
1194
+ };
1171
1195
  } | {
1172
1196
  type: "REPUBLISHING";
1173
1197
  data: {
@@ -1326,6 +1350,11 @@ export declare const CreatedItemsSchema: z.ZodObject<{
1326
1350
  accountId: string;
1327
1351
  caseId: string;
1328
1352
  };
1353
+ } | {
1354
+ type: "PUBLISHED";
1355
+ data: {
1356
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
1357
+ };
1329
1358
  } | {
1330
1359
  type: "REPUBLISHING";
1331
1360
  data: {
@@ -1509,125 +1538,135 @@ export declare const CreatedItemsSchema: z.ZodObject<{
1509
1538
  viewsCount?: number | null | undefined;
1510
1539
  favoritesCount?: number | null | undefined;
1511
1540
  }>, "many">>>;
1512
- createdAt: z.ZodDate;
1513
- updatedAt: z.ZodDate;
1514
- }, "strip", z.ZodTypeAny, {
1515
- userId: string | number;
1516
- id: string | number;
1517
- updatedAt: Date;
1518
- name: string;
1519
- createdAt: Date;
1520
- sold: boolean;
1521
- state?: number | null | undefined;
1522
- colorIds?: number[] | null | undefined;
1523
- description?: string | null | undefined;
1524
- packageSizeId?: number | null | undefined;
1525
- sizeId?: number | null | undefined;
1526
- labels?: {
1527
- itemId: string | number;
1528
- labelId: string | number;
1529
- label?: {
1530
- id: string | number;
1531
- name: string;
1532
- createdAt: Date;
1533
- isUserLabel: boolean;
1534
- userId?: string | number | null | undefined;
1535
- itemCount?: number | null | undefined;
1536
- parentId?: unknown;
1537
- } | null | undefined;
1538
- }[] | null | undefined;
1539
- files?: {
1540
- itemId: string | number;
1541
- fileId: string;
1542
- index?: number | null | undefined;
1543
- file?: {
1544
- path: string;
1545
- userId: string | number;
1546
- id: string;
1547
- createdAt: Date;
1548
- signedUrl: string;
1549
- } | null | undefined;
1550
- }[] | null | undefined;
1551
- fields?: {
1552
- value: string;
1553
- itemId: string | number;
1554
- fieldId: string | number;
1555
- }[] | null | undefined;
1556
- sku?: string | null | undefined;
1557
- categoryId?: number | null | undefined;
1558
- brandId?: string | number | null | undefined;
1559
- sex?: string | null | undefined;
1560
- purchasePrice?: number | null | undefined;
1561
- purchaseDate?: Date | null | undefined;
1562
- purchasePlaceId?: string | number | null | undefined;
1563
- purchased?: boolean | null | undefined;
1564
- sellingPrice?: number | null | undefined;
1565
- sellingDate?: Date | null | undefined;
1566
- sellingPlaceId?: string | number | null | undefined;
1567
- estimatedPrice?: number | null | undefined;
1568
- fees?: {
1569
- value: number;
1570
- type: string;
1571
- userId: string | number;
1572
- id: string | number;
1573
- updatedAt: Date;
1574
- name: string;
1575
- createdAt: Date;
1576
- recurrence: "UNIQUE" | "MONTHLY" | "YEARLY";
1577
- startDate: Date;
1578
- active: boolean;
1579
- description?: string | null | undefined;
1580
- itemId?: string | number | null | undefined;
1581
- endDate?: Date | null | undefined;
1582
- parentFeeId?: string | number | null | undefined;
1583
- }[] | null | undefined;
1584
- feesSum?: number | null | undefined;
1585
- customerId?: string | number | null | undefined;
1586
- customer?: {
1587
- userId: string | number;
1588
- id: string | number;
1589
- email: string;
1590
- firstName: string;
1591
- lastName: string;
1592
- birthDate: Date;
1593
- idNumber: string;
1594
- phone: string;
1595
- iban: string;
1596
- bic: string;
1597
- phoneVerified: boolean;
1598
- } | null | undefined;
1599
- customerType?: string | null | undefined;
1600
- customerPaid?: boolean | null | undefined;
1601
- customerPaidDate?: Date | null | undefined;
1602
- customerPaidType?: string | null | undefined;
1603
- contractId?: string | number | null | undefined;
1604
- lastHistory?: {
1605
- type: "CANCELED" | "SCHEDULED" | "DELETED" | "ARCHIVED" | "DISPUTE" | "IMPORTED" | "UNARCHIVED" | "PUBLISHED" | "FAILED_TO_PUBLISH" | "SCHEDULED_RETRY" | "REPUBLISHING_RETRY" | "PUBLISH_CANCELED" | "REPUBLISHING" | "IMAGE_PROCESSING_DONE" | "REPUBLISHED" | "REPUBLISH_CANCELED" | "UPDATING" | "UPDATED" | "UPDATE_CANCELED" | "DELETING" | "TO_BE_SENT" | "IN_TRANSIT" | "BUYER_PAID" | "DELIVERED" | "RECEIVED" | "FINALIZED" | "RETURN" | "REFUND" | "LIFECYCLE_STARTED" | "LIFECYCLE_COMPLETED" | "LIFECYCLE_CANCELED";
1606
- id: string;
1607
- createdAt: Date;
1608
- itemId: string | number;
1609
- data?: {
1541
+ history: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
1542
+ id: z.ZodString;
1543
+ itemId: z.ZodUnion<[z.ZodNumber, z.ZodString]>;
1544
+ type: z.ZodEnum<["IMPORTED", "ARCHIVED", "UNARCHIVED", "PUBLISHED", "FAILED_TO_PUBLISH", "SCHEDULED_RETRY", "REPUBLISHING_RETRY", "PUBLISH_CANCELED", "SCHEDULED", "REPUBLISHING", "IMAGE_PROCESSING_DONE", "REPUBLISHED", "REPUBLISH_CANCELED", "UPDATING", "UPDATED", "UPDATE_CANCELED", "CANCELED", "DISPUTE", "DELETING", "DELETED", "TO_BE_SENT", "IN_TRANSIT", "BUYER_PAID", "DELIVERED", "RECEIVED", "FINALIZED", "RETURN", "REFUND", "LIFECYCLE_STARTED", "LIFECYCLE_COMPLETED", "LIFECYCLE_CANCELED"]>;
1545
+ data: z.ZodOptional<z.ZodNullable<z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
1546
+ data: z.ZodObject<{
1547
+ targetItemHistoryId: z.ZodString;
1548
+ }, "strip", z.ZodTypeAny, {
1549
+ targetItemHistoryId: string;
1550
+ }, {
1551
+ targetItemHistoryId: string;
1552
+ }>;
1553
+ type: z.ZodLiteral<"ACTION_CANCELED">;
1554
+ }, "strip", z.ZodTypeAny, {
1610
1555
  type: "ACTION_CANCELED";
1611
1556
  data: {
1612
1557
  targetItemHistoryId: string;
1613
1558
  };
1614
- } | {
1559
+ }, {
1560
+ type: "ACTION_CANCELED";
1561
+ data: {
1562
+ targetItemHistoryId: string;
1563
+ };
1564
+ }>, z.ZodObject<{
1565
+ data: z.ZodObject<{
1566
+ soldAccountId: z.ZodString;
1567
+ soldOrderId: z.ZodString;
1568
+ soldConversationId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1569
+ }, "strip", z.ZodTypeAny, {
1570
+ soldAccountId: string;
1571
+ soldOrderId: string;
1572
+ soldConversationId?: string | null | undefined;
1573
+ }, {
1574
+ soldAccountId: string;
1575
+ soldOrderId: string;
1576
+ soldConversationId?: string | null | undefined;
1577
+ }>;
1578
+ type: z.ZodLiteral<"BUYER_PAID">;
1579
+ }, "strip", z.ZodTypeAny, {
1615
1580
  type: "BUYER_PAID";
1616
1581
  data: {
1617
1582
  soldAccountId: string;
1618
1583
  soldOrderId: string;
1619
1584
  soldConversationId?: string | null | undefined;
1620
1585
  };
1621
- } | {
1586
+ }, {
1587
+ type: "BUYER_PAID";
1588
+ data: {
1589
+ soldAccountId: string;
1590
+ soldOrderId: string;
1591
+ soldConversationId?: string | null | undefined;
1592
+ };
1593
+ }>, z.ZodObject<{
1594
+ data: z.ZodObject<{
1595
+ soldAccountId: z.ZodString;
1596
+ soldOrderId: z.ZodString;
1597
+ soldConversationId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1598
+ }, "strip", z.ZodTypeAny, {
1599
+ soldAccountId: string;
1600
+ soldOrderId: string;
1601
+ soldConversationId?: string | null | undefined;
1602
+ }, {
1603
+ soldAccountId: string;
1604
+ soldOrderId: string;
1605
+ soldConversationId?: string | null | undefined;
1606
+ }>;
1607
+ type: z.ZodLiteral<"DELIVERED">;
1608
+ }, "strip", z.ZodTypeAny, {
1622
1609
  type: "DELIVERED";
1623
1610
  data: {
1624
1611
  soldAccountId: string;
1625
1612
  soldOrderId: string;
1626
1613
  soldConversationId?: string | null | undefined;
1627
1614
  };
1628
- } | {
1615
+ }, {
1616
+ type: "DELIVERED";
1617
+ data: {
1618
+ soldAccountId: string;
1619
+ soldOrderId: string;
1620
+ soldConversationId?: string | null | undefined;
1621
+ };
1622
+ }>, z.ZodObject<{
1623
+ type: z.ZodLiteral<"EMPTY">;
1624
+ }, "strip", z.ZodTypeAny, {
1629
1625
  type: "EMPTY";
1630
- } | {
1626
+ }, {
1627
+ type: "EMPTY";
1628
+ }>, z.ZodObject<{
1629
+ data: z.ZodObject<{
1630
+ platform: z.ZodEnum<["ETSY", "SHOPIFY", "VINTED"]>;
1631
+ accountId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1632
+ reason: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1633
+ fields: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
1634
+ field: z.ZodEnum<["TITLE", "DESCRIPTION", "SIZE", "BRAND", "STATUS", "PRICE", "PACKAGE_SIZE", "COLOR", "CATALOG", "PHOTOS", "UNKNOWN"]>;
1635
+ autoFixable: z.ZodBoolean;
1636
+ error: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1637
+ }, "strip", z.ZodTypeAny, {
1638
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
1639
+ autoFixable: boolean;
1640
+ error?: string | null | undefined;
1641
+ }, {
1642
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
1643
+ autoFixable: boolean;
1644
+ error?: string | null | undefined;
1645
+ }>, "many">>>;
1646
+ itemHistoryId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1647
+ }, "strip", z.ZodTypeAny, {
1648
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
1649
+ accountId?: string | null | undefined;
1650
+ reason?: string | null | undefined;
1651
+ fields?: {
1652
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
1653
+ autoFixable: boolean;
1654
+ error?: string | null | undefined;
1655
+ }[] | null | undefined;
1656
+ itemHistoryId?: string | null | undefined;
1657
+ }, {
1658
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
1659
+ accountId?: string | null | undefined;
1660
+ reason?: string | null | undefined;
1661
+ fields?: {
1662
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
1663
+ autoFixable: boolean;
1664
+ error?: string | null | undefined;
1665
+ }[] | null | undefined;
1666
+ itemHistoryId?: string | null | undefined;
1667
+ }>;
1668
+ type: z.ZodLiteral<"FAILED_TO_PUBLISH">;
1669
+ }, "strip", z.ZodTypeAny, {
1631
1670
  type: "FAILED_TO_PUBLISH";
1632
1671
  data: {
1633
1672
  platform: "ETSY" | "SHOPIFY" | "VINTED";
@@ -1640,19 +1679,1843 @@ export declare const CreatedItemsSchema: z.ZodObject<{
1640
1679
  }[] | null | undefined;
1641
1680
  itemHistoryId?: string | null | undefined;
1642
1681
  };
1643
- } | {
1644
- type: "IMAGE_PROCESSING_DONE";
1682
+ }, {
1683
+ type: "FAILED_TO_PUBLISH";
1645
1684
  data: {
1646
1685
  platform: "ETSY" | "SHOPIFY" | "VINTED";
1647
- variations?: {
1648
- fileId: string;
1649
- seed: number;
1650
- phash: string;
1651
- distanceOriginal: number;
1652
- originalImageUrl: string;
1653
- originalPhash: string;
1686
+ accountId?: string | null | undefined;
1687
+ reason?: string | null | undefined;
1688
+ fields?: {
1689
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
1690
+ autoFixable: boolean;
1691
+ error?: string | null | undefined;
1654
1692
  }[] | null | undefined;
1655
- originalPhashes?: string[] | null | undefined;
1693
+ itemHistoryId?: string | null | undefined;
1694
+ };
1695
+ }>, z.ZodObject<{
1696
+ data: z.ZodObject<{
1697
+ platform: z.ZodEnum<["ETSY", "SHOPIFY", "VINTED"]>;
1698
+ variations: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
1699
+ fileId: z.ZodString;
1700
+ seed: z.ZodNumber;
1701
+ phash: z.ZodString;
1702
+ distanceOriginal: z.ZodNumber;
1703
+ originalImageUrl: z.ZodString;
1704
+ originalPhash: z.ZodString;
1705
+ }, "strip", z.ZodTypeAny, {
1706
+ fileId: string;
1707
+ seed: number;
1708
+ phash: string;
1709
+ distanceOriginal: number;
1710
+ originalImageUrl: string;
1711
+ originalPhash: string;
1712
+ }, {
1713
+ fileId: string;
1714
+ seed: number;
1715
+ phash: string;
1716
+ distanceOriginal: number;
1717
+ originalImageUrl: string;
1718
+ originalPhash: string;
1719
+ }>, "many">>>;
1720
+ originalPhashes: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodString, "many">>>;
1721
+ }, "strip", z.ZodTypeAny, {
1722
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
1723
+ variations?: {
1724
+ fileId: string;
1725
+ seed: number;
1726
+ phash: string;
1727
+ distanceOriginal: number;
1728
+ originalImageUrl: string;
1729
+ originalPhash: string;
1730
+ }[] | null | undefined;
1731
+ originalPhashes?: string[] | null | undefined;
1732
+ }, {
1733
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
1734
+ variations?: {
1735
+ fileId: string;
1736
+ seed: number;
1737
+ phash: string;
1738
+ distanceOriginal: number;
1739
+ originalImageUrl: string;
1740
+ originalPhash: string;
1741
+ }[] | null | undefined;
1742
+ originalPhashes?: string[] | null | undefined;
1743
+ }>;
1744
+ type: z.ZodLiteral<"IMAGE_PROCESSING_DONE">;
1745
+ }, "strip", z.ZodTypeAny, {
1746
+ type: "IMAGE_PROCESSING_DONE";
1747
+ data: {
1748
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
1749
+ variations?: {
1750
+ fileId: string;
1751
+ seed: number;
1752
+ phash: string;
1753
+ distanceOriginal: number;
1754
+ originalImageUrl: string;
1755
+ originalPhash: string;
1756
+ }[] | null | undefined;
1757
+ originalPhashes?: string[] | null | undefined;
1758
+ };
1759
+ }, {
1760
+ type: "IMAGE_PROCESSING_DONE";
1761
+ data: {
1762
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
1763
+ variations?: {
1764
+ fileId: string;
1765
+ seed: number;
1766
+ phash: string;
1767
+ distanceOriginal: number;
1768
+ originalImageUrl: string;
1769
+ originalPhash: string;
1770
+ }[] | null | undefined;
1771
+ originalPhashes?: string[] | null | undefined;
1772
+ };
1773
+ }>, z.ZodObject<{
1774
+ data: z.ZodObject<{
1775
+ post: z.ZodObject<{
1776
+ platformId: z.ZodString;
1777
+ platformUrl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1778
+ createdAt: z.ZodOptional<z.ZodNullable<z.ZodDate>>;
1779
+ post: z.ZodObject<{
1780
+ brand: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1781
+ catalog: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1782
+ catalogId: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
1783
+ colors: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodString, "many">>>;
1784
+ colorIds: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodNumber, "many">>>;
1785
+ description: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1786
+ measurementLength: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
1787
+ measurementWidth: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
1788
+ packageSizeId: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
1789
+ photoUrls: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodString, "many">>>;
1790
+ price: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
1791
+ currency: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1792
+ size: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1793
+ sizeId: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
1794
+ status: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1795
+ statusId: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
1796
+ title: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1797
+ isDraft: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
1798
+ isArchived: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
1799
+ availableQuantity: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
1800
+ material: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodNumber, "many">>>;
1801
+ manufacturerLabelling: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1802
+ labels: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodString, "many">>>;
1803
+ }, "strip", z.ZodTypeAny, {
1804
+ status?: string | null | undefined;
1805
+ price?: number | null | undefined;
1806
+ currency?: string | null | undefined;
1807
+ brand?: string | null | undefined;
1808
+ catalog?: string | null | undefined;
1809
+ catalogId?: number | null | undefined;
1810
+ colors?: string[] | null | undefined;
1811
+ colorIds?: number[] | null | undefined;
1812
+ description?: string | null | undefined;
1813
+ measurementLength?: number | null | undefined;
1814
+ measurementWidth?: number | null | undefined;
1815
+ packageSizeId?: number | null | undefined;
1816
+ photoUrls?: string[] | null | undefined;
1817
+ size?: string | null | undefined;
1818
+ sizeId?: number | null | undefined;
1819
+ statusId?: number | null | undefined;
1820
+ title?: string | null | undefined;
1821
+ isDraft?: boolean | null | undefined;
1822
+ isArchived?: boolean | null | undefined;
1823
+ availableQuantity?: number | null | undefined;
1824
+ material?: number[] | null | undefined;
1825
+ manufacturerLabelling?: string | null | undefined;
1826
+ labels?: string[] | null | undefined;
1827
+ }, {
1828
+ status?: string | null | undefined;
1829
+ price?: number | null | undefined;
1830
+ currency?: string | null | undefined;
1831
+ brand?: string | null | undefined;
1832
+ catalog?: string | null | undefined;
1833
+ catalogId?: number | null | undefined;
1834
+ colors?: string[] | null | undefined;
1835
+ colorIds?: number[] | null | undefined;
1836
+ description?: string | null | undefined;
1837
+ measurementLength?: number | null | undefined;
1838
+ measurementWidth?: number | null | undefined;
1839
+ packageSizeId?: number | null | undefined;
1840
+ photoUrls?: string[] | null | undefined;
1841
+ size?: string | null | undefined;
1842
+ sizeId?: number | null | undefined;
1843
+ statusId?: number | null | undefined;
1844
+ title?: string | null | undefined;
1845
+ isDraft?: boolean | null | undefined;
1846
+ isArchived?: boolean | null | undefined;
1847
+ availableQuantity?: number | null | undefined;
1848
+ material?: number[] | null | undefined;
1849
+ manufacturerLabelling?: string | null | undefined;
1850
+ labels?: string[] | null | undefined;
1851
+ }>;
1852
+ }, "strip", z.ZodTypeAny, {
1853
+ platformId: string;
1854
+ post: {
1855
+ status?: string | null | undefined;
1856
+ price?: number | null | undefined;
1857
+ currency?: string | null | undefined;
1858
+ brand?: string | null | undefined;
1859
+ catalog?: string | null | undefined;
1860
+ catalogId?: number | null | undefined;
1861
+ colors?: string[] | null | undefined;
1862
+ colorIds?: number[] | null | undefined;
1863
+ description?: string | null | undefined;
1864
+ measurementLength?: number | null | undefined;
1865
+ measurementWidth?: number | null | undefined;
1866
+ packageSizeId?: number | null | undefined;
1867
+ photoUrls?: string[] | null | undefined;
1868
+ size?: string | null | undefined;
1869
+ sizeId?: number | null | undefined;
1870
+ statusId?: number | null | undefined;
1871
+ title?: string | null | undefined;
1872
+ isDraft?: boolean | null | undefined;
1873
+ isArchived?: boolean | null | undefined;
1874
+ availableQuantity?: number | null | undefined;
1875
+ material?: number[] | null | undefined;
1876
+ manufacturerLabelling?: string | null | undefined;
1877
+ labels?: string[] | null | undefined;
1878
+ };
1879
+ createdAt?: Date | null | undefined;
1880
+ platformUrl?: string | null | undefined;
1881
+ }, {
1882
+ platformId: string;
1883
+ post: {
1884
+ status?: string | null | undefined;
1885
+ price?: number | null | undefined;
1886
+ currency?: string | null | undefined;
1887
+ brand?: string | null | undefined;
1888
+ catalog?: string | null | undefined;
1889
+ catalogId?: number | null | undefined;
1890
+ colors?: string[] | null | undefined;
1891
+ colorIds?: number[] | null | undefined;
1892
+ description?: string | null | undefined;
1893
+ measurementLength?: number | null | undefined;
1894
+ measurementWidth?: number | null | undefined;
1895
+ packageSizeId?: number | null | undefined;
1896
+ photoUrls?: string[] | null | undefined;
1897
+ size?: string | null | undefined;
1898
+ sizeId?: number | null | undefined;
1899
+ statusId?: number | null | undefined;
1900
+ title?: string | null | undefined;
1901
+ isDraft?: boolean | null | undefined;
1902
+ isArchived?: boolean | null | undefined;
1903
+ availableQuantity?: number | null | undefined;
1904
+ material?: number[] | null | undefined;
1905
+ manufacturerLabelling?: string | null | undefined;
1906
+ labels?: string[] | null | undefined;
1907
+ };
1908
+ createdAt?: Date | null | undefined;
1909
+ platformUrl?: string | null | undefined;
1910
+ }>;
1911
+ }, "strip", z.ZodTypeAny, {
1912
+ post: {
1913
+ platformId: string;
1914
+ post: {
1915
+ status?: string | null | undefined;
1916
+ price?: number | null | undefined;
1917
+ currency?: string | null | undefined;
1918
+ brand?: string | null | undefined;
1919
+ catalog?: string | null | undefined;
1920
+ catalogId?: number | null | undefined;
1921
+ colors?: string[] | null | undefined;
1922
+ colorIds?: number[] | null | undefined;
1923
+ description?: string | null | undefined;
1924
+ measurementLength?: number | null | undefined;
1925
+ measurementWidth?: number | null | undefined;
1926
+ packageSizeId?: number | null | undefined;
1927
+ photoUrls?: string[] | null | undefined;
1928
+ size?: string | null | undefined;
1929
+ sizeId?: number | null | undefined;
1930
+ statusId?: number | null | undefined;
1931
+ title?: string | null | undefined;
1932
+ isDraft?: boolean | null | undefined;
1933
+ isArchived?: boolean | null | undefined;
1934
+ availableQuantity?: number | null | undefined;
1935
+ material?: number[] | null | undefined;
1936
+ manufacturerLabelling?: string | null | undefined;
1937
+ labels?: string[] | null | undefined;
1938
+ };
1939
+ createdAt?: Date | null | undefined;
1940
+ platformUrl?: string | null | undefined;
1941
+ };
1942
+ }, {
1943
+ post: {
1944
+ platformId: string;
1945
+ post: {
1946
+ status?: string | null | undefined;
1947
+ price?: number | null | undefined;
1948
+ currency?: string | null | undefined;
1949
+ brand?: string | null | undefined;
1950
+ catalog?: string | null | undefined;
1951
+ catalogId?: number | null | undefined;
1952
+ colors?: string[] | null | undefined;
1953
+ colorIds?: number[] | null | undefined;
1954
+ description?: string | null | undefined;
1955
+ measurementLength?: number | null | undefined;
1956
+ measurementWidth?: number | null | undefined;
1957
+ packageSizeId?: number | null | undefined;
1958
+ photoUrls?: string[] | null | undefined;
1959
+ size?: string | null | undefined;
1960
+ sizeId?: number | null | undefined;
1961
+ statusId?: number | null | undefined;
1962
+ title?: string | null | undefined;
1963
+ isDraft?: boolean | null | undefined;
1964
+ isArchived?: boolean | null | undefined;
1965
+ availableQuantity?: number | null | undefined;
1966
+ material?: number[] | null | undefined;
1967
+ manufacturerLabelling?: string | null | undefined;
1968
+ labels?: string[] | null | undefined;
1969
+ };
1970
+ createdAt?: Date | null | undefined;
1971
+ platformUrl?: string | null | undefined;
1972
+ };
1973
+ }>;
1974
+ type: z.ZodLiteral<"IMPORTED">;
1975
+ }, "strip", z.ZodTypeAny, {
1976
+ type: "IMPORTED";
1977
+ data: {
1978
+ post: {
1979
+ platformId: string;
1980
+ post: {
1981
+ status?: string | null | undefined;
1982
+ price?: number | null | undefined;
1983
+ currency?: string | null | undefined;
1984
+ brand?: string | null | undefined;
1985
+ catalog?: string | null | undefined;
1986
+ catalogId?: number | null | undefined;
1987
+ colors?: string[] | null | undefined;
1988
+ colorIds?: number[] | null | undefined;
1989
+ description?: string | null | undefined;
1990
+ measurementLength?: number | null | undefined;
1991
+ measurementWidth?: number | null | undefined;
1992
+ packageSizeId?: number | null | undefined;
1993
+ photoUrls?: string[] | null | undefined;
1994
+ size?: string | null | undefined;
1995
+ sizeId?: number | null | undefined;
1996
+ statusId?: number | null | undefined;
1997
+ title?: string | null | undefined;
1998
+ isDraft?: boolean | null | undefined;
1999
+ isArchived?: boolean | null | undefined;
2000
+ availableQuantity?: number | null | undefined;
2001
+ material?: number[] | null | undefined;
2002
+ manufacturerLabelling?: string | null | undefined;
2003
+ labels?: string[] | null | undefined;
2004
+ };
2005
+ createdAt?: Date | null | undefined;
2006
+ platformUrl?: string | null | undefined;
2007
+ };
2008
+ };
2009
+ }, {
2010
+ type: "IMPORTED";
2011
+ data: {
2012
+ post: {
2013
+ platformId: string;
2014
+ post: {
2015
+ status?: string | null | undefined;
2016
+ price?: number | null | undefined;
2017
+ currency?: string | null | undefined;
2018
+ brand?: string | null | undefined;
2019
+ catalog?: string | null | undefined;
2020
+ catalogId?: number | null | undefined;
2021
+ colors?: string[] | null | undefined;
2022
+ colorIds?: number[] | null | undefined;
2023
+ description?: string | null | undefined;
2024
+ measurementLength?: number | null | undefined;
2025
+ measurementWidth?: number | null | undefined;
2026
+ packageSizeId?: number | null | undefined;
2027
+ photoUrls?: string[] | null | undefined;
2028
+ size?: string | null | undefined;
2029
+ sizeId?: number | null | undefined;
2030
+ statusId?: number | null | undefined;
2031
+ title?: string | null | undefined;
2032
+ isDraft?: boolean | null | undefined;
2033
+ isArchived?: boolean | null | undefined;
2034
+ availableQuantity?: number | null | undefined;
2035
+ material?: number[] | null | undefined;
2036
+ manufacturerLabelling?: string | null | undefined;
2037
+ labels?: string[] | null | undefined;
2038
+ };
2039
+ createdAt?: Date | null | undefined;
2040
+ platformUrl?: string | null | undefined;
2041
+ };
2042
+ };
2043
+ }>, z.ZodObject<{
2044
+ data: z.ZodObject<{
2045
+ accountId: z.ZodString;
2046
+ }, "strip", z.ZodTypeAny, {
2047
+ accountId: string;
2048
+ }, {
2049
+ accountId: string;
2050
+ }>;
2051
+ type: z.ZodLiteral<"LIFECYCLE_COMPLETED">;
2052
+ }, "strip", z.ZodTypeAny, {
2053
+ type: "LIFECYCLE_COMPLETED";
2054
+ data: {
2055
+ accountId: string;
2056
+ };
2057
+ }, {
2058
+ type: "LIFECYCLE_COMPLETED";
2059
+ data: {
2060
+ accountId: string;
2061
+ };
2062
+ }>, z.ZodObject<{
2063
+ data: z.ZodObject<{
2064
+ accountId: z.ZodString;
2065
+ caseId: z.ZodString;
2066
+ }, "strip", z.ZodTypeAny, {
2067
+ accountId: string;
2068
+ caseId: string;
2069
+ }, {
2070
+ accountId: string;
2071
+ caseId: string;
2072
+ }>;
2073
+ type: z.ZodLiteral<"LIFECYCLE_STARTED">;
2074
+ }, "strip", z.ZodTypeAny, {
2075
+ type: "LIFECYCLE_STARTED";
2076
+ data: {
2077
+ accountId: string;
2078
+ caseId: string;
2079
+ };
2080
+ }, {
2081
+ type: "LIFECYCLE_STARTED";
2082
+ data: {
2083
+ accountId: string;
2084
+ caseId: string;
2085
+ };
2086
+ }>, z.ZodObject<{
2087
+ data: z.ZodObject<{
2088
+ platform: z.ZodEnum<["ETSY", "SHOPIFY", "VINTED"]>;
2089
+ }, "strip", z.ZodTypeAny, {
2090
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2091
+ }, {
2092
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2093
+ }>;
2094
+ type: z.ZodLiteral<"PUBLISHED">;
2095
+ }, "strip", z.ZodTypeAny, {
2096
+ type: "PUBLISHED";
2097
+ data: {
2098
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2099
+ };
2100
+ }, {
2101
+ type: "PUBLISHED";
2102
+ data: {
2103
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2104
+ };
2105
+ }>, z.ZodObject<{
2106
+ data: z.ZodObject<{
2107
+ platform: z.ZodEnum<["ETSY", "SHOPIFY", "VINTED"]>;
2108
+ publishingDate: z.ZodOptional<z.ZodNullable<z.ZodDate>>;
2109
+ priceDropPayload: z.ZodOptional<z.ZodNullable<z.ZodObject<{
2110
+ type: z.ZodEnum<["PERCENTAGE", "ABSOLUTE"]>;
2111
+ value: z.ZodNumber;
2112
+ roundType: z.ZodOptional<z.ZodNullable<z.ZodEnum<["NEAREST", "UP", "DOWN", "CUSTOM"]>>>;
2113
+ roundStep: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
2114
+ maxRounds: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
2115
+ }, "strip", z.ZodTypeAny, {
2116
+ value: number;
2117
+ type: "PERCENTAGE" | "ABSOLUTE";
2118
+ roundType?: "NEAREST" | "UP" | "DOWN" | "CUSTOM" | null | undefined;
2119
+ roundStep?: number | null | undefined;
2120
+ maxRounds?: number | null | undefined;
2121
+ }, {
2122
+ value: number;
2123
+ type: "PERCENTAGE" | "ABSOLUTE";
2124
+ roundType?: "NEAREST" | "UP" | "DOWN" | "CUSTOM" | null | undefined;
2125
+ roundStep?: number | null | undefined;
2126
+ maxRounds?: number | null | undefined;
2127
+ }>>>;
2128
+ isTransfer: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
2129
+ targetAccountId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
2130
+ }, "strip", z.ZodTypeAny, {
2131
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2132
+ publishingDate?: Date | null | undefined;
2133
+ priceDropPayload?: {
2134
+ value: number;
2135
+ type: "PERCENTAGE" | "ABSOLUTE";
2136
+ roundType?: "NEAREST" | "UP" | "DOWN" | "CUSTOM" | null | undefined;
2137
+ roundStep?: number | null | undefined;
2138
+ maxRounds?: number | null | undefined;
2139
+ } | null | undefined;
2140
+ isTransfer?: boolean | null | undefined;
2141
+ targetAccountId?: string | null | undefined;
2142
+ }, {
2143
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2144
+ publishingDate?: Date | null | undefined;
2145
+ priceDropPayload?: {
2146
+ value: number;
2147
+ type: "PERCENTAGE" | "ABSOLUTE";
2148
+ roundType?: "NEAREST" | "UP" | "DOWN" | "CUSTOM" | null | undefined;
2149
+ roundStep?: number | null | undefined;
2150
+ maxRounds?: number | null | undefined;
2151
+ } | null | undefined;
2152
+ isTransfer?: boolean | null | undefined;
2153
+ targetAccountId?: string | null | undefined;
2154
+ }>;
2155
+ type: z.ZodLiteral<"REPUBLISHING">;
2156
+ }, "strip", z.ZodTypeAny, {
2157
+ type: "REPUBLISHING";
2158
+ data: {
2159
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2160
+ publishingDate?: Date | null | undefined;
2161
+ priceDropPayload?: {
2162
+ value: number;
2163
+ type: "PERCENTAGE" | "ABSOLUTE";
2164
+ roundType?: "NEAREST" | "UP" | "DOWN" | "CUSTOM" | null | undefined;
2165
+ roundStep?: number | null | undefined;
2166
+ maxRounds?: number | null | undefined;
2167
+ } | null | undefined;
2168
+ isTransfer?: boolean | null | undefined;
2169
+ targetAccountId?: string | null | undefined;
2170
+ };
2171
+ }, {
2172
+ type: "REPUBLISHING";
2173
+ data: {
2174
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2175
+ publishingDate?: Date | null | undefined;
2176
+ priceDropPayload?: {
2177
+ value: number;
2178
+ type: "PERCENTAGE" | "ABSOLUTE";
2179
+ roundType?: "NEAREST" | "UP" | "DOWN" | "CUSTOM" | null | undefined;
2180
+ roundStep?: number | null | undefined;
2181
+ maxRounds?: number | null | undefined;
2182
+ } | null | undefined;
2183
+ isTransfer?: boolean | null | undefined;
2184
+ targetAccountId?: string | null | undefined;
2185
+ };
2186
+ }>, z.ZodObject<{
2187
+ data: z.ZodObject<{
2188
+ platform: z.ZodEnum<["ETSY", "SHOPIFY", "VINTED"]>;
2189
+ attemptNumber: z.ZodNumber;
2190
+ maxAttempts: z.ZodNumber;
2191
+ previousHistoryId: z.ZodString;
2192
+ originalFailureDate: z.ZodDate;
2193
+ fields: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
2194
+ field: z.ZodEnum<["TITLE", "DESCRIPTION", "SIZE", "BRAND", "STATUS", "PRICE", "PACKAGE_SIZE", "COLOR", "CATALOG", "PHOTOS", "UNKNOWN"]>;
2195
+ autoFixable: z.ZodBoolean;
2196
+ error: z.ZodOptional<z.ZodNullable<z.ZodString>>;
2197
+ }, "strip", z.ZodTypeAny, {
2198
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
2199
+ autoFixable: boolean;
2200
+ error?: string | null | undefined;
2201
+ }, {
2202
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
2203
+ autoFixable: boolean;
2204
+ error?: string | null | undefined;
2205
+ }>, "many">>>;
2206
+ priceDropPayload: z.ZodOptional<z.ZodNullable<z.ZodObject<{
2207
+ type: z.ZodEnum<["PERCENTAGE", "ABSOLUTE"]>;
2208
+ value: z.ZodNumber;
2209
+ roundType: z.ZodOptional<z.ZodNullable<z.ZodEnum<["NEAREST", "UP", "DOWN", "CUSTOM"]>>>;
2210
+ roundStep: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
2211
+ maxRounds: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
2212
+ }, "strip", z.ZodTypeAny, {
2213
+ value: number;
2214
+ type: "PERCENTAGE" | "ABSOLUTE";
2215
+ roundType?: "NEAREST" | "UP" | "DOWN" | "CUSTOM" | null | undefined;
2216
+ roundStep?: number | null | undefined;
2217
+ maxRounds?: number | null | undefined;
2218
+ }, {
2219
+ value: number;
2220
+ type: "PERCENTAGE" | "ABSOLUTE";
2221
+ roundType?: "NEAREST" | "UP" | "DOWN" | "CUSTOM" | null | undefined;
2222
+ roundStep?: number | null | undefined;
2223
+ maxRounds?: number | null | undefined;
2224
+ }>>>;
2225
+ }, "strip", z.ZodTypeAny, {
2226
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2227
+ attemptNumber: number;
2228
+ maxAttempts: number;
2229
+ previousHistoryId: string;
2230
+ originalFailureDate: Date;
2231
+ fields?: {
2232
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
2233
+ autoFixable: boolean;
2234
+ error?: string | null | undefined;
2235
+ }[] | null | undefined;
2236
+ priceDropPayload?: {
2237
+ value: number;
2238
+ type: "PERCENTAGE" | "ABSOLUTE";
2239
+ roundType?: "NEAREST" | "UP" | "DOWN" | "CUSTOM" | null | undefined;
2240
+ roundStep?: number | null | undefined;
2241
+ maxRounds?: number | null | undefined;
2242
+ } | null | undefined;
2243
+ }, {
2244
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2245
+ attemptNumber: number;
2246
+ maxAttempts: number;
2247
+ previousHistoryId: string;
2248
+ originalFailureDate: Date;
2249
+ fields?: {
2250
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
2251
+ autoFixable: boolean;
2252
+ error?: string | null | undefined;
2253
+ }[] | null | undefined;
2254
+ priceDropPayload?: {
2255
+ value: number;
2256
+ type: "PERCENTAGE" | "ABSOLUTE";
2257
+ roundType?: "NEAREST" | "UP" | "DOWN" | "CUSTOM" | null | undefined;
2258
+ roundStep?: number | null | undefined;
2259
+ maxRounds?: number | null | undefined;
2260
+ } | null | undefined;
2261
+ }>;
2262
+ type: z.ZodLiteral<"REPUBLISHING_RETRY">;
2263
+ }, "strip", z.ZodTypeAny, {
2264
+ type: "REPUBLISHING_RETRY";
2265
+ data: {
2266
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2267
+ attemptNumber: number;
2268
+ maxAttempts: number;
2269
+ previousHistoryId: string;
2270
+ originalFailureDate: Date;
2271
+ fields?: {
2272
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
2273
+ autoFixable: boolean;
2274
+ error?: string | null | undefined;
2275
+ }[] | null | undefined;
2276
+ priceDropPayload?: {
2277
+ value: number;
2278
+ type: "PERCENTAGE" | "ABSOLUTE";
2279
+ roundType?: "NEAREST" | "UP" | "DOWN" | "CUSTOM" | null | undefined;
2280
+ roundStep?: number | null | undefined;
2281
+ maxRounds?: number | null | undefined;
2282
+ } | null | undefined;
2283
+ };
2284
+ }, {
2285
+ type: "REPUBLISHING_RETRY";
2286
+ data: {
2287
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2288
+ attemptNumber: number;
2289
+ maxAttempts: number;
2290
+ previousHistoryId: string;
2291
+ originalFailureDate: Date;
2292
+ fields?: {
2293
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
2294
+ autoFixable: boolean;
2295
+ error?: string | null | undefined;
2296
+ }[] | null | undefined;
2297
+ priceDropPayload?: {
2298
+ value: number;
2299
+ type: "PERCENTAGE" | "ABSOLUTE";
2300
+ roundType?: "NEAREST" | "UP" | "DOWN" | "CUSTOM" | null | undefined;
2301
+ roundStep?: number | null | undefined;
2302
+ maxRounds?: number | null | undefined;
2303
+ } | null | undefined;
2304
+ };
2305
+ }>, z.ZodObject<{
2306
+ data: z.ZodObject<{
2307
+ platform: z.ZodEnum<["ETSY", "SHOPIFY", "VINTED"]>;
2308
+ publishingDate: z.ZodOptional<z.ZodNullable<z.ZodDate>>;
2309
+ }, "strip", z.ZodTypeAny, {
2310
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2311
+ publishingDate?: Date | null | undefined;
2312
+ }, {
2313
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2314
+ publishingDate?: Date | null | undefined;
2315
+ }>;
2316
+ type: z.ZodLiteral<"SCHEDULED">;
2317
+ }, "strip", z.ZodTypeAny, {
2318
+ type: "SCHEDULED";
2319
+ data: {
2320
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2321
+ publishingDate?: Date | null | undefined;
2322
+ };
2323
+ }, {
2324
+ type: "SCHEDULED";
2325
+ data: {
2326
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2327
+ publishingDate?: Date | null | undefined;
2328
+ };
2329
+ }>, z.ZodObject<{
2330
+ data: z.ZodObject<{
2331
+ platform: z.ZodEnum<["ETSY", "SHOPIFY", "VINTED"]>;
2332
+ attemptNumber: z.ZodNumber;
2333
+ maxAttempts: z.ZodNumber;
2334
+ previousHistoryId: z.ZodString;
2335
+ originalFailureDate: z.ZodDate;
2336
+ fields: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
2337
+ field: z.ZodEnum<["TITLE", "DESCRIPTION", "SIZE", "BRAND", "STATUS", "PRICE", "PACKAGE_SIZE", "COLOR", "CATALOG", "PHOTOS", "UNKNOWN"]>;
2338
+ autoFixable: z.ZodBoolean;
2339
+ error: z.ZodOptional<z.ZodNullable<z.ZodString>>;
2340
+ }, "strip", z.ZodTypeAny, {
2341
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
2342
+ autoFixable: boolean;
2343
+ error?: string | null | undefined;
2344
+ }, {
2345
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
2346
+ autoFixable: boolean;
2347
+ error?: string | null | undefined;
2348
+ }>, "many">>>;
2349
+ }, "strip", z.ZodTypeAny, {
2350
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2351
+ attemptNumber: number;
2352
+ maxAttempts: number;
2353
+ previousHistoryId: string;
2354
+ originalFailureDate: Date;
2355
+ fields?: {
2356
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
2357
+ autoFixable: boolean;
2358
+ error?: string | null | undefined;
2359
+ }[] | null | undefined;
2360
+ }, {
2361
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2362
+ attemptNumber: number;
2363
+ maxAttempts: number;
2364
+ previousHistoryId: string;
2365
+ originalFailureDate: Date;
2366
+ fields?: {
2367
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
2368
+ autoFixable: boolean;
2369
+ error?: string | null | undefined;
2370
+ }[] | null | undefined;
2371
+ }>;
2372
+ type: z.ZodLiteral<"SCHEDULED_RETRY">;
2373
+ }, "strip", z.ZodTypeAny, {
2374
+ type: "SCHEDULED_RETRY";
2375
+ data: {
2376
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2377
+ attemptNumber: number;
2378
+ maxAttempts: number;
2379
+ previousHistoryId: string;
2380
+ originalFailureDate: Date;
2381
+ fields?: {
2382
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
2383
+ autoFixable: boolean;
2384
+ error?: string | null | undefined;
2385
+ }[] | null | undefined;
2386
+ };
2387
+ }, {
2388
+ type: "SCHEDULED_RETRY";
2389
+ data: {
2390
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2391
+ attemptNumber: number;
2392
+ maxAttempts: number;
2393
+ previousHistoryId: string;
2394
+ originalFailureDate: Date;
2395
+ fields?: {
2396
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
2397
+ autoFixable: boolean;
2398
+ error?: string | null | undefined;
2399
+ }[] | null | undefined;
2400
+ };
2401
+ }>]>>>;
2402
+ createdAt: z.ZodDate;
2403
+ targetDate: z.ZodOptional<z.ZodNullable<z.ZodDate>>;
2404
+ accountId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
2405
+ requestId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
2406
+ }, "strip", z.ZodTypeAny, {
2407
+ type: "CANCELED" | "SCHEDULED" | "DELETED" | "ARCHIVED" | "DISPUTE" | "IMPORTED" | "UNARCHIVED" | "PUBLISHED" | "FAILED_TO_PUBLISH" | "SCHEDULED_RETRY" | "REPUBLISHING_RETRY" | "PUBLISH_CANCELED" | "REPUBLISHING" | "IMAGE_PROCESSING_DONE" | "REPUBLISHED" | "REPUBLISH_CANCELED" | "UPDATING" | "UPDATED" | "UPDATE_CANCELED" | "DELETING" | "TO_BE_SENT" | "IN_TRANSIT" | "BUYER_PAID" | "DELIVERED" | "RECEIVED" | "FINALIZED" | "RETURN" | "REFUND" | "LIFECYCLE_STARTED" | "LIFECYCLE_COMPLETED" | "LIFECYCLE_CANCELED";
2408
+ id: string;
2409
+ createdAt: Date;
2410
+ itemId: string | number;
2411
+ data?: {
2412
+ type: "ACTION_CANCELED";
2413
+ data: {
2414
+ targetItemHistoryId: string;
2415
+ };
2416
+ } | {
2417
+ type: "BUYER_PAID";
2418
+ data: {
2419
+ soldAccountId: string;
2420
+ soldOrderId: string;
2421
+ soldConversationId?: string | null | undefined;
2422
+ };
2423
+ } | {
2424
+ type: "DELIVERED";
2425
+ data: {
2426
+ soldAccountId: string;
2427
+ soldOrderId: string;
2428
+ soldConversationId?: string | null | undefined;
2429
+ };
2430
+ } | {
2431
+ type: "EMPTY";
2432
+ } | {
2433
+ type: "FAILED_TO_PUBLISH";
2434
+ data: {
2435
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2436
+ accountId?: string | null | undefined;
2437
+ reason?: string | null | undefined;
2438
+ fields?: {
2439
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
2440
+ autoFixable: boolean;
2441
+ error?: string | null | undefined;
2442
+ }[] | null | undefined;
2443
+ itemHistoryId?: string | null | undefined;
2444
+ };
2445
+ } | {
2446
+ type: "IMAGE_PROCESSING_DONE";
2447
+ data: {
2448
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2449
+ variations?: {
2450
+ fileId: string;
2451
+ seed: number;
2452
+ phash: string;
2453
+ distanceOriginal: number;
2454
+ originalImageUrl: string;
2455
+ originalPhash: string;
2456
+ }[] | null | undefined;
2457
+ originalPhashes?: string[] | null | undefined;
2458
+ };
2459
+ } | {
2460
+ type: "IMPORTED";
2461
+ data: {
2462
+ post: {
2463
+ platformId: string;
2464
+ post: {
2465
+ status?: string | null | undefined;
2466
+ price?: number | null | undefined;
2467
+ currency?: string | null | undefined;
2468
+ brand?: string | null | undefined;
2469
+ catalog?: string | null | undefined;
2470
+ catalogId?: number | null | undefined;
2471
+ colors?: string[] | null | undefined;
2472
+ colorIds?: number[] | null | undefined;
2473
+ description?: string | null | undefined;
2474
+ measurementLength?: number | null | undefined;
2475
+ measurementWidth?: number | null | undefined;
2476
+ packageSizeId?: number | null | undefined;
2477
+ photoUrls?: string[] | null | undefined;
2478
+ size?: string | null | undefined;
2479
+ sizeId?: number | null | undefined;
2480
+ statusId?: number | null | undefined;
2481
+ title?: string | null | undefined;
2482
+ isDraft?: boolean | null | undefined;
2483
+ isArchived?: boolean | null | undefined;
2484
+ availableQuantity?: number | null | undefined;
2485
+ material?: number[] | null | undefined;
2486
+ manufacturerLabelling?: string | null | undefined;
2487
+ labels?: string[] | null | undefined;
2488
+ };
2489
+ createdAt?: Date | null | undefined;
2490
+ platformUrl?: string | null | undefined;
2491
+ };
2492
+ };
2493
+ } | {
2494
+ type: "LIFECYCLE_COMPLETED";
2495
+ data: {
2496
+ accountId: string;
2497
+ };
2498
+ } | {
2499
+ type: "LIFECYCLE_STARTED";
2500
+ data: {
2501
+ accountId: string;
2502
+ caseId: string;
2503
+ };
2504
+ } | {
2505
+ type: "PUBLISHED";
2506
+ data: {
2507
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2508
+ };
2509
+ } | {
2510
+ type: "REPUBLISHING";
2511
+ data: {
2512
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2513
+ publishingDate?: Date | null | undefined;
2514
+ priceDropPayload?: {
2515
+ value: number;
2516
+ type: "PERCENTAGE" | "ABSOLUTE";
2517
+ roundType?: "NEAREST" | "UP" | "DOWN" | "CUSTOM" | null | undefined;
2518
+ roundStep?: number | null | undefined;
2519
+ maxRounds?: number | null | undefined;
2520
+ } | null | undefined;
2521
+ isTransfer?: boolean | null | undefined;
2522
+ targetAccountId?: string | null | undefined;
2523
+ };
2524
+ } | {
2525
+ type: "REPUBLISHING_RETRY";
2526
+ data: {
2527
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2528
+ attemptNumber: number;
2529
+ maxAttempts: number;
2530
+ previousHistoryId: string;
2531
+ originalFailureDate: Date;
2532
+ fields?: {
2533
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
2534
+ autoFixable: boolean;
2535
+ error?: string | null | undefined;
2536
+ }[] | null | undefined;
2537
+ priceDropPayload?: {
2538
+ value: number;
2539
+ type: "PERCENTAGE" | "ABSOLUTE";
2540
+ roundType?: "NEAREST" | "UP" | "DOWN" | "CUSTOM" | null | undefined;
2541
+ roundStep?: number | null | undefined;
2542
+ maxRounds?: number | null | undefined;
2543
+ } | null | undefined;
2544
+ };
2545
+ } | {
2546
+ type: "SCHEDULED";
2547
+ data: {
2548
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2549
+ publishingDate?: Date | null | undefined;
2550
+ };
2551
+ } | {
2552
+ type: "SCHEDULED_RETRY";
2553
+ data: {
2554
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2555
+ attemptNumber: number;
2556
+ maxAttempts: number;
2557
+ previousHistoryId: string;
2558
+ originalFailureDate: Date;
2559
+ fields?: {
2560
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
2561
+ autoFixable: boolean;
2562
+ error?: string | null | undefined;
2563
+ }[] | null | undefined;
2564
+ };
2565
+ } | null | undefined;
2566
+ accountId?: string | null | undefined;
2567
+ requestId?: string | null | undefined;
2568
+ targetDate?: Date | null | undefined;
2569
+ }, {
2570
+ type: "CANCELED" | "SCHEDULED" | "DELETED" | "ARCHIVED" | "DISPUTE" | "IMPORTED" | "UNARCHIVED" | "PUBLISHED" | "FAILED_TO_PUBLISH" | "SCHEDULED_RETRY" | "REPUBLISHING_RETRY" | "PUBLISH_CANCELED" | "REPUBLISHING" | "IMAGE_PROCESSING_DONE" | "REPUBLISHED" | "REPUBLISH_CANCELED" | "UPDATING" | "UPDATED" | "UPDATE_CANCELED" | "DELETING" | "TO_BE_SENT" | "IN_TRANSIT" | "BUYER_PAID" | "DELIVERED" | "RECEIVED" | "FINALIZED" | "RETURN" | "REFUND" | "LIFECYCLE_STARTED" | "LIFECYCLE_COMPLETED" | "LIFECYCLE_CANCELED";
2571
+ id: string;
2572
+ createdAt: Date;
2573
+ itemId: string | number;
2574
+ data?: {
2575
+ type: "ACTION_CANCELED";
2576
+ data: {
2577
+ targetItemHistoryId: string;
2578
+ };
2579
+ } | {
2580
+ type: "BUYER_PAID";
2581
+ data: {
2582
+ soldAccountId: string;
2583
+ soldOrderId: string;
2584
+ soldConversationId?: string | null | undefined;
2585
+ };
2586
+ } | {
2587
+ type: "DELIVERED";
2588
+ data: {
2589
+ soldAccountId: string;
2590
+ soldOrderId: string;
2591
+ soldConversationId?: string | null | undefined;
2592
+ };
2593
+ } | {
2594
+ type: "EMPTY";
2595
+ } | {
2596
+ type: "FAILED_TO_PUBLISH";
2597
+ data: {
2598
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2599
+ accountId?: string | null | undefined;
2600
+ reason?: string | null | undefined;
2601
+ fields?: {
2602
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
2603
+ autoFixable: boolean;
2604
+ error?: string | null | undefined;
2605
+ }[] | null | undefined;
2606
+ itemHistoryId?: string | null | undefined;
2607
+ };
2608
+ } | {
2609
+ type: "IMAGE_PROCESSING_DONE";
2610
+ data: {
2611
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2612
+ variations?: {
2613
+ fileId: string;
2614
+ seed: number;
2615
+ phash: string;
2616
+ distanceOriginal: number;
2617
+ originalImageUrl: string;
2618
+ originalPhash: string;
2619
+ }[] | null | undefined;
2620
+ originalPhashes?: string[] | null | undefined;
2621
+ };
2622
+ } | {
2623
+ type: "IMPORTED";
2624
+ data: {
2625
+ post: {
2626
+ platformId: string;
2627
+ post: {
2628
+ status?: string | null | undefined;
2629
+ price?: number | null | undefined;
2630
+ currency?: string | null | undefined;
2631
+ brand?: string | null | undefined;
2632
+ catalog?: string | null | undefined;
2633
+ catalogId?: number | null | undefined;
2634
+ colors?: string[] | null | undefined;
2635
+ colorIds?: number[] | null | undefined;
2636
+ description?: string | null | undefined;
2637
+ measurementLength?: number | null | undefined;
2638
+ measurementWidth?: number | null | undefined;
2639
+ packageSizeId?: number | null | undefined;
2640
+ photoUrls?: string[] | null | undefined;
2641
+ size?: string | null | undefined;
2642
+ sizeId?: number | null | undefined;
2643
+ statusId?: number | null | undefined;
2644
+ title?: string | null | undefined;
2645
+ isDraft?: boolean | null | undefined;
2646
+ isArchived?: boolean | null | undefined;
2647
+ availableQuantity?: number | null | undefined;
2648
+ material?: number[] | null | undefined;
2649
+ manufacturerLabelling?: string | null | undefined;
2650
+ labels?: string[] | null | undefined;
2651
+ };
2652
+ createdAt?: Date | null | undefined;
2653
+ platformUrl?: string | null | undefined;
2654
+ };
2655
+ };
2656
+ } | {
2657
+ type: "LIFECYCLE_COMPLETED";
2658
+ data: {
2659
+ accountId: string;
2660
+ };
2661
+ } | {
2662
+ type: "LIFECYCLE_STARTED";
2663
+ data: {
2664
+ accountId: string;
2665
+ caseId: string;
2666
+ };
2667
+ } | {
2668
+ type: "PUBLISHED";
2669
+ data: {
2670
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2671
+ };
2672
+ } | {
2673
+ type: "REPUBLISHING";
2674
+ data: {
2675
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2676
+ publishingDate?: Date | null | undefined;
2677
+ priceDropPayload?: {
2678
+ value: number;
2679
+ type: "PERCENTAGE" | "ABSOLUTE";
2680
+ roundType?: "NEAREST" | "UP" | "DOWN" | "CUSTOM" | null | undefined;
2681
+ roundStep?: number | null | undefined;
2682
+ maxRounds?: number | null | undefined;
2683
+ } | null | undefined;
2684
+ isTransfer?: boolean | null | undefined;
2685
+ targetAccountId?: string | null | undefined;
2686
+ };
2687
+ } | {
2688
+ type: "REPUBLISHING_RETRY";
2689
+ data: {
2690
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2691
+ attemptNumber: number;
2692
+ maxAttempts: number;
2693
+ previousHistoryId: string;
2694
+ originalFailureDate: Date;
2695
+ fields?: {
2696
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
2697
+ autoFixable: boolean;
2698
+ error?: string | null | undefined;
2699
+ }[] | null | undefined;
2700
+ priceDropPayload?: {
2701
+ value: number;
2702
+ type: "PERCENTAGE" | "ABSOLUTE";
2703
+ roundType?: "NEAREST" | "UP" | "DOWN" | "CUSTOM" | null | undefined;
2704
+ roundStep?: number | null | undefined;
2705
+ maxRounds?: number | null | undefined;
2706
+ } | null | undefined;
2707
+ };
2708
+ } | {
2709
+ type: "SCHEDULED";
2710
+ data: {
2711
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2712
+ publishingDate?: Date | null | undefined;
2713
+ };
2714
+ } | {
2715
+ type: "SCHEDULED_RETRY";
2716
+ data: {
2717
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2718
+ attemptNumber: number;
2719
+ maxAttempts: number;
2720
+ previousHistoryId: string;
2721
+ originalFailureDate: Date;
2722
+ fields?: {
2723
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
2724
+ autoFixable: boolean;
2725
+ error?: string | null | undefined;
2726
+ }[] | null | undefined;
2727
+ };
2728
+ } | null | undefined;
2729
+ accountId?: string | null | undefined;
2730
+ requestId?: string | null | undefined;
2731
+ targetDate?: Date | null | undefined;
2732
+ }>, "many">>>;
2733
+ createdAt: z.ZodDate;
2734
+ updatedAt: z.ZodDate;
2735
+ }, "strip", z.ZodTypeAny, {
2736
+ userId: string | number;
2737
+ id: string | number;
2738
+ updatedAt: Date;
2739
+ name: string;
2740
+ createdAt: Date;
2741
+ sold: boolean;
2742
+ state?: number | null | undefined;
2743
+ colorIds?: number[] | null | undefined;
2744
+ description?: string | null | undefined;
2745
+ packageSizeId?: number | null | undefined;
2746
+ sizeId?: number | null | undefined;
2747
+ labels?: {
2748
+ itemId: string | number;
2749
+ labelId: string | number;
2750
+ label?: {
2751
+ id: string | number;
2752
+ name: string;
2753
+ createdAt: Date;
2754
+ isUserLabel: boolean;
2755
+ userId?: string | number | null | undefined;
2756
+ itemCount?: number | null | undefined;
2757
+ parentId?: unknown;
2758
+ } | null | undefined;
2759
+ }[] | null | undefined;
2760
+ files?: {
2761
+ itemId: string | number;
2762
+ fileId: string;
2763
+ index?: number | null | undefined;
2764
+ file?: {
2765
+ path: string;
2766
+ userId: string | number;
2767
+ id: string;
2768
+ createdAt: Date;
2769
+ signedUrl: string;
2770
+ } | null | undefined;
2771
+ }[] | null | undefined;
2772
+ fields?: {
2773
+ value: string;
2774
+ itemId: string | number;
2775
+ fieldId: string | number;
2776
+ }[] | null | undefined;
2777
+ sku?: string | null | undefined;
2778
+ categoryId?: number | null | undefined;
2779
+ brandId?: string | number | null | undefined;
2780
+ sex?: string | null | undefined;
2781
+ purchasePrice?: number | null | undefined;
2782
+ purchaseDate?: Date | null | undefined;
2783
+ purchasePlaceId?: string | number | null | undefined;
2784
+ purchased?: boolean | null | undefined;
2785
+ sellingPrice?: number | null | undefined;
2786
+ sellingDate?: Date | null | undefined;
2787
+ sellingPlaceId?: string | number | null | undefined;
2788
+ estimatedPrice?: number | null | undefined;
2789
+ fees?: {
2790
+ value: number;
2791
+ type: string;
2792
+ userId: string | number;
2793
+ id: string | number;
2794
+ updatedAt: Date;
2795
+ name: string;
2796
+ createdAt: Date;
2797
+ recurrence: "UNIQUE" | "MONTHLY" | "YEARLY";
2798
+ startDate: Date;
2799
+ active: boolean;
2800
+ description?: string | null | undefined;
2801
+ itemId?: string | number | null | undefined;
2802
+ endDate?: Date | null | undefined;
2803
+ parentFeeId?: string | number | null | undefined;
2804
+ }[] | null | undefined;
2805
+ feesSum?: number | null | undefined;
2806
+ customerId?: string | number | null | undefined;
2807
+ customer?: {
2808
+ userId: string | number;
2809
+ id: string | number;
2810
+ email: string;
2811
+ firstName: string;
2812
+ lastName: string;
2813
+ birthDate: Date;
2814
+ idNumber: string;
2815
+ phone: string;
2816
+ iban: string;
2817
+ bic: string;
2818
+ phoneVerified: boolean;
2819
+ } | null | undefined;
2820
+ customerType?: string | null | undefined;
2821
+ customerPaid?: boolean | null | undefined;
2822
+ customerPaidDate?: Date | null | undefined;
2823
+ customerPaidType?: string | null | undefined;
2824
+ contractId?: string | number | null | undefined;
2825
+ lastHistory?: {
2826
+ type: "CANCELED" | "SCHEDULED" | "DELETED" | "ARCHIVED" | "DISPUTE" | "IMPORTED" | "UNARCHIVED" | "PUBLISHED" | "FAILED_TO_PUBLISH" | "SCHEDULED_RETRY" | "REPUBLISHING_RETRY" | "PUBLISH_CANCELED" | "REPUBLISHING" | "IMAGE_PROCESSING_DONE" | "REPUBLISHED" | "REPUBLISH_CANCELED" | "UPDATING" | "UPDATED" | "UPDATE_CANCELED" | "DELETING" | "TO_BE_SENT" | "IN_TRANSIT" | "BUYER_PAID" | "DELIVERED" | "RECEIVED" | "FINALIZED" | "RETURN" | "REFUND" | "LIFECYCLE_STARTED" | "LIFECYCLE_COMPLETED" | "LIFECYCLE_CANCELED";
2827
+ id: string;
2828
+ createdAt: Date;
2829
+ itemId: string | number;
2830
+ data?: {
2831
+ type: "ACTION_CANCELED";
2832
+ data: {
2833
+ targetItemHistoryId: string;
2834
+ };
2835
+ } | {
2836
+ type: "BUYER_PAID";
2837
+ data: {
2838
+ soldAccountId: string;
2839
+ soldOrderId: string;
2840
+ soldConversationId?: string | null | undefined;
2841
+ };
2842
+ } | {
2843
+ type: "DELIVERED";
2844
+ data: {
2845
+ soldAccountId: string;
2846
+ soldOrderId: string;
2847
+ soldConversationId?: string | null | undefined;
2848
+ };
2849
+ } | {
2850
+ type: "EMPTY";
2851
+ } | {
2852
+ type: "FAILED_TO_PUBLISH";
2853
+ data: {
2854
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2855
+ accountId?: string | null | undefined;
2856
+ reason?: string | null | undefined;
2857
+ fields?: {
2858
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
2859
+ autoFixable: boolean;
2860
+ error?: string | null | undefined;
2861
+ }[] | null | undefined;
2862
+ itemHistoryId?: string | null | undefined;
2863
+ };
2864
+ } | {
2865
+ type: "IMAGE_PROCESSING_DONE";
2866
+ data: {
2867
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2868
+ variations?: {
2869
+ fileId: string;
2870
+ seed: number;
2871
+ phash: string;
2872
+ distanceOriginal: number;
2873
+ originalImageUrl: string;
2874
+ originalPhash: string;
2875
+ }[] | null | undefined;
2876
+ originalPhashes?: string[] | null | undefined;
2877
+ };
2878
+ } | {
2879
+ type: "IMPORTED";
2880
+ data: {
2881
+ post: {
2882
+ platformId: string;
2883
+ post: {
2884
+ status?: string | null | undefined;
2885
+ price?: number | null | undefined;
2886
+ currency?: string | null | undefined;
2887
+ brand?: string | null | undefined;
2888
+ catalog?: string | null | undefined;
2889
+ catalogId?: number | null | undefined;
2890
+ colors?: string[] | null | undefined;
2891
+ colorIds?: number[] | null | undefined;
2892
+ description?: string | null | undefined;
2893
+ measurementLength?: number | null | undefined;
2894
+ measurementWidth?: number | null | undefined;
2895
+ packageSizeId?: number | null | undefined;
2896
+ photoUrls?: string[] | null | undefined;
2897
+ size?: string | null | undefined;
2898
+ sizeId?: number | null | undefined;
2899
+ statusId?: number | null | undefined;
2900
+ title?: string | null | undefined;
2901
+ isDraft?: boolean | null | undefined;
2902
+ isArchived?: boolean | null | undefined;
2903
+ availableQuantity?: number | null | undefined;
2904
+ material?: number[] | null | undefined;
2905
+ manufacturerLabelling?: string | null | undefined;
2906
+ labels?: string[] | null | undefined;
2907
+ };
2908
+ createdAt?: Date | null | undefined;
2909
+ platformUrl?: string | null | undefined;
2910
+ };
2911
+ };
2912
+ } | {
2913
+ type: "LIFECYCLE_COMPLETED";
2914
+ data: {
2915
+ accountId: string;
2916
+ };
2917
+ } | {
2918
+ type: "LIFECYCLE_STARTED";
2919
+ data: {
2920
+ accountId: string;
2921
+ caseId: string;
2922
+ };
2923
+ } | {
2924
+ type: "PUBLISHED";
2925
+ data: {
2926
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2927
+ };
2928
+ } | {
2929
+ type: "REPUBLISHING";
2930
+ data: {
2931
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2932
+ publishingDate?: Date | null | undefined;
2933
+ priceDropPayload?: {
2934
+ value: number;
2935
+ type: "PERCENTAGE" | "ABSOLUTE";
2936
+ roundType?: "NEAREST" | "UP" | "DOWN" | "CUSTOM" | null | undefined;
2937
+ roundStep?: number | null | undefined;
2938
+ maxRounds?: number | null | undefined;
2939
+ } | null | undefined;
2940
+ isTransfer?: boolean | null | undefined;
2941
+ targetAccountId?: string | null | undefined;
2942
+ };
2943
+ } | {
2944
+ type: "REPUBLISHING_RETRY";
2945
+ data: {
2946
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2947
+ attemptNumber: number;
2948
+ maxAttempts: number;
2949
+ previousHistoryId: string;
2950
+ originalFailureDate: Date;
2951
+ fields?: {
2952
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
2953
+ autoFixable: boolean;
2954
+ error?: string | null | undefined;
2955
+ }[] | null | undefined;
2956
+ priceDropPayload?: {
2957
+ value: number;
2958
+ type: "PERCENTAGE" | "ABSOLUTE";
2959
+ roundType?: "NEAREST" | "UP" | "DOWN" | "CUSTOM" | null | undefined;
2960
+ roundStep?: number | null | undefined;
2961
+ maxRounds?: number | null | undefined;
2962
+ } | null | undefined;
2963
+ };
2964
+ } | {
2965
+ type: "SCHEDULED";
2966
+ data: {
2967
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2968
+ publishingDate?: Date | null | undefined;
2969
+ };
2970
+ } | {
2971
+ type: "SCHEDULED_RETRY";
2972
+ data: {
2973
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
2974
+ attemptNumber: number;
2975
+ maxAttempts: number;
2976
+ previousHistoryId: string;
2977
+ originalFailureDate: Date;
2978
+ fields?: {
2979
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
2980
+ autoFixable: boolean;
2981
+ error?: string | null | undefined;
2982
+ }[] | null | undefined;
2983
+ };
2984
+ } | null | undefined;
2985
+ accountId?: string | null | undefined;
2986
+ requestId?: string | null | undefined;
2987
+ targetDate?: Date | null | undefined;
2988
+ } | null | undefined;
2989
+ platforms?: {
2990
+ status: "DRAFT" | "PENDING" | "ERROR" | "ONLINE" | "DELETED" | "ARCHIVED" | "SOLD" | "SOLD_ELSEWHERE" | "HIDDEN" | "DISPUTE";
2991
+ id: string;
2992
+ updatedAt: Date;
2993
+ createdAt: Date;
2994
+ accountId: string;
2995
+ itemId: string | number;
2996
+ platformId: string;
2997
+ platformUrl: string;
2998
+ platformPrice: number;
2999
+ publishedAt: Date;
3000
+ conversationId?: string | null | undefined;
3001
+ account?: {
3002
+ status: "CONNECTED" | "DISCONNECTED" | "ERROR" | "LOCKED";
3003
+ userId: string | number;
3004
+ name: string;
3005
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
3006
+ accountId: string;
3007
+ locale?: string | null | undefined;
3008
+ night?: {
3009
+ startsAt: Date;
3010
+ endsAt: Date;
3011
+ } | null | undefined;
3012
+ favoritesMaxDelay?: number | null | undefined;
3013
+ ordersMaxDelay?: number | null | undefined;
3014
+ conversationsMaxDelay?: number | null | undefined;
3015
+ } | null | undefined;
3016
+ viewsCount?: number | null | undefined;
3017
+ favoritesCount?: number | null | undefined;
3018
+ }[] | null | undefined;
3019
+ history?: {
3020
+ type: "CANCELED" | "SCHEDULED" | "DELETED" | "ARCHIVED" | "DISPUTE" | "IMPORTED" | "UNARCHIVED" | "PUBLISHED" | "FAILED_TO_PUBLISH" | "SCHEDULED_RETRY" | "REPUBLISHING_RETRY" | "PUBLISH_CANCELED" | "REPUBLISHING" | "IMAGE_PROCESSING_DONE" | "REPUBLISHED" | "REPUBLISH_CANCELED" | "UPDATING" | "UPDATED" | "UPDATE_CANCELED" | "DELETING" | "TO_BE_SENT" | "IN_TRANSIT" | "BUYER_PAID" | "DELIVERED" | "RECEIVED" | "FINALIZED" | "RETURN" | "REFUND" | "LIFECYCLE_STARTED" | "LIFECYCLE_COMPLETED" | "LIFECYCLE_CANCELED";
3021
+ id: string;
3022
+ createdAt: Date;
3023
+ itemId: string | number;
3024
+ data?: {
3025
+ type: "ACTION_CANCELED";
3026
+ data: {
3027
+ targetItemHistoryId: string;
3028
+ };
3029
+ } | {
3030
+ type: "BUYER_PAID";
3031
+ data: {
3032
+ soldAccountId: string;
3033
+ soldOrderId: string;
3034
+ soldConversationId?: string | null | undefined;
3035
+ };
3036
+ } | {
3037
+ type: "DELIVERED";
3038
+ data: {
3039
+ soldAccountId: string;
3040
+ soldOrderId: string;
3041
+ soldConversationId?: string | null | undefined;
3042
+ };
3043
+ } | {
3044
+ type: "EMPTY";
3045
+ } | {
3046
+ type: "FAILED_TO_PUBLISH";
3047
+ data: {
3048
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
3049
+ accountId?: string | null | undefined;
3050
+ reason?: string | null | undefined;
3051
+ fields?: {
3052
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
3053
+ autoFixable: boolean;
3054
+ error?: string | null | undefined;
3055
+ }[] | null | undefined;
3056
+ itemHistoryId?: string | null | undefined;
3057
+ };
3058
+ } | {
3059
+ type: "IMAGE_PROCESSING_DONE";
3060
+ data: {
3061
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
3062
+ variations?: {
3063
+ fileId: string;
3064
+ seed: number;
3065
+ phash: string;
3066
+ distanceOriginal: number;
3067
+ originalImageUrl: string;
3068
+ originalPhash: string;
3069
+ }[] | null | undefined;
3070
+ originalPhashes?: string[] | null | undefined;
3071
+ };
3072
+ } | {
3073
+ type: "IMPORTED";
3074
+ data: {
3075
+ post: {
3076
+ platformId: string;
3077
+ post: {
3078
+ status?: string | null | undefined;
3079
+ price?: number | null | undefined;
3080
+ currency?: string | null | undefined;
3081
+ brand?: string | null | undefined;
3082
+ catalog?: string | null | undefined;
3083
+ catalogId?: number | null | undefined;
3084
+ colors?: string[] | null | undefined;
3085
+ colorIds?: number[] | null | undefined;
3086
+ description?: string | null | undefined;
3087
+ measurementLength?: number | null | undefined;
3088
+ measurementWidth?: number | null | undefined;
3089
+ packageSizeId?: number | null | undefined;
3090
+ photoUrls?: string[] | null | undefined;
3091
+ size?: string | null | undefined;
3092
+ sizeId?: number | null | undefined;
3093
+ statusId?: number | null | undefined;
3094
+ title?: string | null | undefined;
3095
+ isDraft?: boolean | null | undefined;
3096
+ isArchived?: boolean | null | undefined;
3097
+ availableQuantity?: number | null | undefined;
3098
+ material?: number[] | null | undefined;
3099
+ manufacturerLabelling?: string | null | undefined;
3100
+ labels?: string[] | null | undefined;
3101
+ };
3102
+ createdAt?: Date | null | undefined;
3103
+ platformUrl?: string | null | undefined;
3104
+ };
3105
+ };
3106
+ } | {
3107
+ type: "LIFECYCLE_COMPLETED";
3108
+ data: {
3109
+ accountId: string;
3110
+ };
3111
+ } | {
3112
+ type: "LIFECYCLE_STARTED";
3113
+ data: {
3114
+ accountId: string;
3115
+ caseId: string;
3116
+ };
3117
+ } | {
3118
+ type: "PUBLISHED";
3119
+ data: {
3120
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
3121
+ };
3122
+ } | {
3123
+ type: "REPUBLISHING";
3124
+ data: {
3125
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
3126
+ publishingDate?: Date | null | undefined;
3127
+ priceDropPayload?: {
3128
+ value: number;
3129
+ type: "PERCENTAGE" | "ABSOLUTE";
3130
+ roundType?: "NEAREST" | "UP" | "DOWN" | "CUSTOM" | null | undefined;
3131
+ roundStep?: number | null | undefined;
3132
+ maxRounds?: number | null | undefined;
3133
+ } | null | undefined;
3134
+ isTransfer?: boolean | null | undefined;
3135
+ targetAccountId?: string | null | undefined;
3136
+ };
3137
+ } | {
3138
+ type: "REPUBLISHING_RETRY";
3139
+ data: {
3140
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
3141
+ attemptNumber: number;
3142
+ maxAttempts: number;
3143
+ previousHistoryId: string;
3144
+ originalFailureDate: Date;
3145
+ fields?: {
3146
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
3147
+ autoFixable: boolean;
3148
+ error?: string | null | undefined;
3149
+ }[] | null | undefined;
3150
+ priceDropPayload?: {
3151
+ value: number;
3152
+ type: "PERCENTAGE" | "ABSOLUTE";
3153
+ roundType?: "NEAREST" | "UP" | "DOWN" | "CUSTOM" | null | undefined;
3154
+ roundStep?: number | null | undefined;
3155
+ maxRounds?: number | null | undefined;
3156
+ } | null | undefined;
3157
+ };
3158
+ } | {
3159
+ type: "SCHEDULED";
3160
+ data: {
3161
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
3162
+ publishingDate?: Date | null | undefined;
3163
+ };
3164
+ } | {
3165
+ type: "SCHEDULED_RETRY";
3166
+ data: {
3167
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
3168
+ attemptNumber: number;
3169
+ maxAttempts: number;
3170
+ previousHistoryId: string;
3171
+ originalFailureDate: Date;
3172
+ fields?: {
3173
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
3174
+ autoFixable: boolean;
3175
+ error?: string | null | undefined;
3176
+ }[] | null | undefined;
3177
+ };
3178
+ } | null | undefined;
3179
+ accountId?: string | null | undefined;
3180
+ requestId?: string | null | undefined;
3181
+ targetDate?: Date | null | undefined;
3182
+ }[] | null | undefined;
3183
+ }, {
3184
+ userId: string | number;
3185
+ id: string | number;
3186
+ updatedAt: Date;
3187
+ name: string;
3188
+ createdAt: Date;
3189
+ sold: boolean;
3190
+ state?: number | null | undefined;
3191
+ colorIds?: number[] | null | undefined;
3192
+ description?: string | null | undefined;
3193
+ packageSizeId?: number | null | undefined;
3194
+ sizeId?: number | null | undefined;
3195
+ labels?: {
3196
+ itemId: string | number;
3197
+ labelId: string | number;
3198
+ label?: {
3199
+ id: string | number;
3200
+ name: string;
3201
+ createdAt: Date;
3202
+ isUserLabel: boolean;
3203
+ userId?: string | number | null | undefined;
3204
+ itemCount?: number | null | undefined;
3205
+ parentId?: unknown;
3206
+ } | null | undefined;
3207
+ }[] | null | undefined;
3208
+ files?: {
3209
+ itemId: string | number;
3210
+ fileId: string;
3211
+ index?: number | null | undefined;
3212
+ file?: {
3213
+ path: string;
3214
+ userId: string | number;
3215
+ id: string;
3216
+ createdAt: Date;
3217
+ signedUrl: string;
3218
+ } | null | undefined;
3219
+ }[] | null | undefined;
3220
+ fields?: {
3221
+ value: string;
3222
+ itemId: string | number;
3223
+ fieldId: string | number;
3224
+ }[] | null | undefined;
3225
+ sku?: string | null | undefined;
3226
+ categoryId?: number | null | undefined;
3227
+ brandId?: string | number | null | undefined;
3228
+ sex?: string | null | undefined;
3229
+ purchasePrice?: number | null | undefined;
3230
+ purchaseDate?: Date | null | undefined;
3231
+ purchasePlaceId?: string | number | null | undefined;
3232
+ purchased?: boolean | null | undefined;
3233
+ sellingPrice?: number | null | undefined;
3234
+ sellingDate?: Date | null | undefined;
3235
+ sellingPlaceId?: string | number | null | undefined;
3236
+ estimatedPrice?: number | null | undefined;
3237
+ fees?: {
3238
+ value: number;
3239
+ type: string;
3240
+ userId: string | number;
3241
+ id: string | number;
3242
+ updatedAt: Date;
3243
+ name: string;
3244
+ createdAt: Date;
3245
+ recurrence: "UNIQUE" | "MONTHLY" | "YEARLY";
3246
+ startDate: Date;
3247
+ active: boolean;
3248
+ description?: string | null | undefined;
3249
+ itemId?: string | number | null | undefined;
3250
+ endDate?: Date | null | undefined;
3251
+ parentFeeId?: string | number | null | undefined;
3252
+ }[] | null | undefined;
3253
+ feesSum?: number | null | undefined;
3254
+ customerId?: string | number | null | undefined;
3255
+ customer?: {
3256
+ userId: string | number;
3257
+ id: string | number;
3258
+ email: string;
3259
+ firstName: string;
3260
+ lastName: string;
3261
+ birthDate: Date;
3262
+ idNumber: string;
3263
+ phone: string;
3264
+ iban: string;
3265
+ bic: string;
3266
+ phoneVerified: boolean;
3267
+ } | null | undefined;
3268
+ customerType?: string | null | undefined;
3269
+ customerPaid?: boolean | null | undefined;
3270
+ customerPaidDate?: Date | null | undefined;
3271
+ customerPaidType?: string | null | undefined;
3272
+ contractId?: string | number | null | undefined;
3273
+ lastHistory?: {
3274
+ type: "CANCELED" | "SCHEDULED" | "DELETED" | "ARCHIVED" | "DISPUTE" | "IMPORTED" | "UNARCHIVED" | "PUBLISHED" | "FAILED_TO_PUBLISH" | "SCHEDULED_RETRY" | "REPUBLISHING_RETRY" | "PUBLISH_CANCELED" | "REPUBLISHING" | "IMAGE_PROCESSING_DONE" | "REPUBLISHED" | "REPUBLISH_CANCELED" | "UPDATING" | "UPDATED" | "UPDATE_CANCELED" | "DELETING" | "TO_BE_SENT" | "IN_TRANSIT" | "BUYER_PAID" | "DELIVERED" | "RECEIVED" | "FINALIZED" | "RETURN" | "REFUND" | "LIFECYCLE_STARTED" | "LIFECYCLE_COMPLETED" | "LIFECYCLE_CANCELED";
3275
+ id: string;
3276
+ createdAt: Date;
3277
+ itemId: string | number;
3278
+ data?: {
3279
+ type: "ACTION_CANCELED";
3280
+ data: {
3281
+ targetItemHistoryId: string;
3282
+ };
3283
+ } | {
3284
+ type: "BUYER_PAID";
3285
+ data: {
3286
+ soldAccountId: string;
3287
+ soldOrderId: string;
3288
+ soldConversationId?: string | null | undefined;
3289
+ };
3290
+ } | {
3291
+ type: "DELIVERED";
3292
+ data: {
3293
+ soldAccountId: string;
3294
+ soldOrderId: string;
3295
+ soldConversationId?: string | null | undefined;
3296
+ };
3297
+ } | {
3298
+ type: "EMPTY";
3299
+ } | {
3300
+ type: "FAILED_TO_PUBLISH";
3301
+ data: {
3302
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
3303
+ accountId?: string | null | undefined;
3304
+ reason?: string | null | undefined;
3305
+ fields?: {
3306
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
3307
+ autoFixable: boolean;
3308
+ error?: string | null | undefined;
3309
+ }[] | null | undefined;
3310
+ itemHistoryId?: string | null | undefined;
3311
+ };
3312
+ } | {
3313
+ type: "IMAGE_PROCESSING_DONE";
3314
+ data: {
3315
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
3316
+ variations?: {
3317
+ fileId: string;
3318
+ seed: number;
3319
+ phash: string;
3320
+ distanceOriginal: number;
3321
+ originalImageUrl: string;
3322
+ originalPhash: string;
3323
+ }[] | null | undefined;
3324
+ originalPhashes?: string[] | null | undefined;
3325
+ };
3326
+ } | {
3327
+ type: "IMPORTED";
3328
+ data: {
3329
+ post: {
3330
+ platformId: string;
3331
+ post: {
3332
+ status?: string | null | undefined;
3333
+ price?: number | null | undefined;
3334
+ currency?: string | null | undefined;
3335
+ brand?: string | null | undefined;
3336
+ catalog?: string | null | undefined;
3337
+ catalogId?: number | null | undefined;
3338
+ colors?: string[] | null | undefined;
3339
+ colorIds?: number[] | null | undefined;
3340
+ description?: string | null | undefined;
3341
+ measurementLength?: number | null | undefined;
3342
+ measurementWidth?: number | null | undefined;
3343
+ packageSizeId?: number | null | undefined;
3344
+ photoUrls?: string[] | null | undefined;
3345
+ size?: string | null | undefined;
3346
+ sizeId?: number | null | undefined;
3347
+ statusId?: number | null | undefined;
3348
+ title?: string | null | undefined;
3349
+ isDraft?: boolean | null | undefined;
3350
+ isArchived?: boolean | null | undefined;
3351
+ availableQuantity?: number | null | undefined;
3352
+ material?: number[] | null | undefined;
3353
+ manufacturerLabelling?: string | null | undefined;
3354
+ labels?: string[] | null | undefined;
3355
+ };
3356
+ createdAt?: Date | null | undefined;
3357
+ platformUrl?: string | null | undefined;
3358
+ };
3359
+ };
3360
+ } | {
3361
+ type: "LIFECYCLE_COMPLETED";
3362
+ data: {
3363
+ accountId: string;
3364
+ };
3365
+ } | {
3366
+ type: "LIFECYCLE_STARTED";
3367
+ data: {
3368
+ accountId: string;
3369
+ caseId: string;
3370
+ };
3371
+ } | {
3372
+ type: "PUBLISHED";
3373
+ data: {
3374
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
3375
+ };
3376
+ } | {
3377
+ type: "REPUBLISHING";
3378
+ data: {
3379
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
3380
+ publishingDate?: Date | null | undefined;
3381
+ priceDropPayload?: {
3382
+ value: number;
3383
+ type: "PERCENTAGE" | "ABSOLUTE";
3384
+ roundType?: "NEAREST" | "UP" | "DOWN" | "CUSTOM" | null | undefined;
3385
+ roundStep?: number | null | undefined;
3386
+ maxRounds?: number | null | undefined;
3387
+ } | null | undefined;
3388
+ isTransfer?: boolean | null | undefined;
3389
+ targetAccountId?: string | null | undefined;
3390
+ };
3391
+ } | {
3392
+ type: "REPUBLISHING_RETRY";
3393
+ data: {
3394
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
3395
+ attemptNumber: number;
3396
+ maxAttempts: number;
3397
+ previousHistoryId: string;
3398
+ originalFailureDate: Date;
3399
+ fields?: {
3400
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
3401
+ autoFixable: boolean;
3402
+ error?: string | null | undefined;
3403
+ }[] | null | undefined;
3404
+ priceDropPayload?: {
3405
+ value: number;
3406
+ type: "PERCENTAGE" | "ABSOLUTE";
3407
+ roundType?: "NEAREST" | "UP" | "DOWN" | "CUSTOM" | null | undefined;
3408
+ roundStep?: number | null | undefined;
3409
+ maxRounds?: number | null | undefined;
3410
+ } | null | undefined;
3411
+ };
3412
+ } | {
3413
+ type: "SCHEDULED";
3414
+ data: {
3415
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
3416
+ publishingDate?: Date | null | undefined;
3417
+ };
3418
+ } | {
3419
+ type: "SCHEDULED_RETRY";
3420
+ data: {
3421
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
3422
+ attemptNumber: number;
3423
+ maxAttempts: number;
3424
+ previousHistoryId: string;
3425
+ originalFailureDate: Date;
3426
+ fields?: {
3427
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
3428
+ autoFixable: boolean;
3429
+ error?: string | null | undefined;
3430
+ }[] | null | undefined;
3431
+ };
3432
+ } | null | undefined;
3433
+ accountId?: string | null | undefined;
3434
+ requestId?: string | null | undefined;
3435
+ targetDate?: Date | null | undefined;
3436
+ } | null | undefined;
3437
+ platforms?: {
3438
+ status: "DRAFT" | "PENDING" | "ERROR" | "ONLINE" | "DELETED" | "ARCHIVED" | "SOLD" | "SOLD_ELSEWHERE" | "HIDDEN" | "DISPUTE";
3439
+ id: string;
3440
+ updatedAt: Date;
3441
+ createdAt: Date;
3442
+ accountId: string;
3443
+ itemId: string | number;
3444
+ platformId: string;
3445
+ platformUrl: string;
3446
+ platformPrice: number;
3447
+ publishedAt: Date;
3448
+ conversationId?: string | null | undefined;
3449
+ account?: {
3450
+ status: "CONNECTED" | "DISCONNECTED" | "ERROR" | "LOCKED";
3451
+ userId: string | number;
3452
+ name: string;
3453
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
3454
+ accountId: string;
3455
+ locale?: string | null | undefined;
3456
+ night?: {
3457
+ startsAt: Date;
3458
+ endsAt: Date;
3459
+ } | null | undefined;
3460
+ favoritesMaxDelay?: number | null | undefined;
3461
+ ordersMaxDelay?: number | null | undefined;
3462
+ conversationsMaxDelay?: number | null | undefined;
3463
+ } | null | undefined;
3464
+ viewsCount?: number | null | undefined;
3465
+ favoritesCount?: number | null | undefined;
3466
+ }[] | null | undefined;
3467
+ history?: {
3468
+ type: "CANCELED" | "SCHEDULED" | "DELETED" | "ARCHIVED" | "DISPUTE" | "IMPORTED" | "UNARCHIVED" | "PUBLISHED" | "FAILED_TO_PUBLISH" | "SCHEDULED_RETRY" | "REPUBLISHING_RETRY" | "PUBLISH_CANCELED" | "REPUBLISHING" | "IMAGE_PROCESSING_DONE" | "REPUBLISHED" | "REPUBLISH_CANCELED" | "UPDATING" | "UPDATED" | "UPDATE_CANCELED" | "DELETING" | "TO_BE_SENT" | "IN_TRANSIT" | "BUYER_PAID" | "DELIVERED" | "RECEIVED" | "FINALIZED" | "RETURN" | "REFUND" | "LIFECYCLE_STARTED" | "LIFECYCLE_COMPLETED" | "LIFECYCLE_CANCELED";
3469
+ id: string;
3470
+ createdAt: Date;
3471
+ itemId: string | number;
3472
+ data?: {
3473
+ type: "ACTION_CANCELED";
3474
+ data: {
3475
+ targetItemHistoryId: string;
3476
+ };
3477
+ } | {
3478
+ type: "BUYER_PAID";
3479
+ data: {
3480
+ soldAccountId: string;
3481
+ soldOrderId: string;
3482
+ soldConversationId?: string | null | undefined;
3483
+ };
3484
+ } | {
3485
+ type: "DELIVERED";
3486
+ data: {
3487
+ soldAccountId: string;
3488
+ soldOrderId: string;
3489
+ soldConversationId?: string | null | undefined;
3490
+ };
3491
+ } | {
3492
+ type: "EMPTY";
3493
+ } | {
3494
+ type: "FAILED_TO_PUBLISH";
3495
+ data: {
3496
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
3497
+ accountId?: string | null | undefined;
3498
+ reason?: string | null | undefined;
3499
+ fields?: {
3500
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
3501
+ autoFixable: boolean;
3502
+ error?: string | null | undefined;
3503
+ }[] | null | undefined;
3504
+ itemHistoryId?: string | null | undefined;
3505
+ };
3506
+ } | {
3507
+ type: "IMAGE_PROCESSING_DONE";
3508
+ data: {
3509
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
3510
+ variations?: {
3511
+ fileId: string;
3512
+ seed: number;
3513
+ phash: string;
3514
+ distanceOriginal: number;
3515
+ originalImageUrl: string;
3516
+ originalPhash: string;
3517
+ }[] | null | undefined;
3518
+ originalPhashes?: string[] | null | undefined;
1656
3519
  };
1657
3520
  } | {
1658
3521
  type: "IMPORTED";
@@ -1699,6 +3562,11 @@ export declare const CreatedItemsSchema: z.ZodObject<{
1699
3562
  accountId: string;
1700
3563
  caseId: string;
1701
3564
  };
3565
+ } | {
3566
+ type: "PUBLISHED";
3567
+ data: {
3568
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
3569
+ };
1702
3570
  } | {
1703
3571
  type: "REPUBLISHING";
1704
3572
  data: {
@@ -1759,38 +3627,35 @@ export declare const CreatedItemsSchema: z.ZodObject<{
1759
3627
  accountId?: string | null | undefined;
1760
3628
  requestId?: string | null | undefined;
1761
3629
  targetDate?: Date | null | undefined;
1762
- } | null | undefined;
1763
- platforms?: {
1764
- status: "DRAFT" | "PENDING" | "ERROR" | "ONLINE" | "DELETED" | "ARCHIVED" | "SOLD" | "SOLD_ELSEWHERE" | "HIDDEN" | "DISPUTE";
1765
- id: string;
1766
- updatedAt: Date;
1767
- createdAt: Date;
1768
- accountId: string;
1769
- itemId: string | number;
1770
- platformId: string;
1771
- platformUrl: string;
1772
- platformPrice: number;
1773
- publishedAt: Date;
1774
- conversationId?: string | null | undefined;
1775
- account?: {
1776
- status: "CONNECTED" | "DISCONNECTED" | "ERROR" | "LOCKED";
1777
- userId: string | number;
1778
- name: string;
1779
- platform: "ETSY" | "SHOPIFY" | "VINTED";
1780
- accountId: string;
1781
- locale?: string | null | undefined;
1782
- night?: {
1783
- startsAt: Date;
1784
- endsAt: Date;
1785
- } | null | undefined;
1786
- favoritesMaxDelay?: number | null | undefined;
1787
- ordersMaxDelay?: number | null | undefined;
1788
- conversationsMaxDelay?: number | null | undefined;
1789
- } | null | undefined;
1790
- viewsCount?: number | null | undefined;
1791
- favoritesCount?: number | null | undefined;
1792
3630
  }[] | null | undefined;
3631
+ }>, "many">;
3632
+ newUserLabels: z.ZodArray<z.ZodObject<{
3633
+ id: z.ZodUnion<[z.ZodNumber, z.ZodString]>;
3634
+ name: z.ZodString;
3635
+ userId: z.ZodOptional<z.ZodNullable<z.ZodUnion<[z.ZodNumber, z.ZodString]>>>;
3636
+ isUserLabel: z.ZodBoolean;
3637
+ createdAt: z.ZodDate;
3638
+ itemCount: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
3639
+ parentId: z.ZodUnknown;
3640
+ }, "strip", z.ZodTypeAny, {
3641
+ id: string | number;
3642
+ name: string;
3643
+ createdAt: Date;
3644
+ isUserLabel: boolean;
3645
+ userId?: string | number | null | undefined;
3646
+ itemCount?: number | null | undefined;
3647
+ parentId?: unknown;
1793
3648
  }, {
3649
+ id: string | number;
3650
+ name: string;
3651
+ createdAt: Date;
3652
+ isUserLabel: boolean;
3653
+ userId?: string | number | null | undefined;
3654
+ itemCount?: number | null | undefined;
3655
+ parentId?: unknown;
3656
+ }>, "many">;
3657
+ }, "strip", z.ZodTypeAny, {
3658
+ items: {
1794
3659
  userId: string | number;
1795
3660
  id: string | number;
1796
3661
  updatedAt: Date;
@@ -1850,37 +3715,231 @@ export declare const CreatedItemsSchema: z.ZodObject<{
1850
3715
  userId: string | number;
1851
3716
  id: string | number;
1852
3717
  updatedAt: Date;
1853
- name: string;
3718
+ name: string;
3719
+ createdAt: Date;
3720
+ recurrence: "UNIQUE" | "MONTHLY" | "YEARLY";
3721
+ startDate: Date;
3722
+ active: boolean;
3723
+ description?: string | null | undefined;
3724
+ itemId?: string | number | null | undefined;
3725
+ endDate?: Date | null | undefined;
3726
+ parentFeeId?: string | number | null | undefined;
3727
+ }[] | null | undefined;
3728
+ feesSum?: number | null | undefined;
3729
+ customerId?: string | number | null | undefined;
3730
+ customer?: {
3731
+ userId: string | number;
3732
+ id: string | number;
3733
+ email: string;
3734
+ firstName: string;
3735
+ lastName: string;
3736
+ birthDate: Date;
3737
+ idNumber: string;
3738
+ phone: string;
3739
+ iban: string;
3740
+ bic: string;
3741
+ phoneVerified: boolean;
3742
+ } | null | undefined;
3743
+ customerType?: string | null | undefined;
3744
+ customerPaid?: boolean | null | undefined;
3745
+ customerPaidDate?: Date | null | undefined;
3746
+ customerPaidType?: string | null | undefined;
3747
+ contractId?: string | number | null | undefined;
3748
+ lastHistory?: {
3749
+ type: "CANCELED" | "SCHEDULED" | "DELETED" | "ARCHIVED" | "DISPUTE" | "IMPORTED" | "UNARCHIVED" | "PUBLISHED" | "FAILED_TO_PUBLISH" | "SCHEDULED_RETRY" | "REPUBLISHING_RETRY" | "PUBLISH_CANCELED" | "REPUBLISHING" | "IMAGE_PROCESSING_DONE" | "REPUBLISHED" | "REPUBLISH_CANCELED" | "UPDATING" | "UPDATED" | "UPDATE_CANCELED" | "DELETING" | "TO_BE_SENT" | "IN_TRANSIT" | "BUYER_PAID" | "DELIVERED" | "RECEIVED" | "FINALIZED" | "RETURN" | "REFUND" | "LIFECYCLE_STARTED" | "LIFECYCLE_COMPLETED" | "LIFECYCLE_CANCELED";
3750
+ id: string;
3751
+ createdAt: Date;
3752
+ itemId: string | number;
3753
+ data?: {
3754
+ type: "ACTION_CANCELED";
3755
+ data: {
3756
+ targetItemHistoryId: string;
3757
+ };
3758
+ } | {
3759
+ type: "BUYER_PAID";
3760
+ data: {
3761
+ soldAccountId: string;
3762
+ soldOrderId: string;
3763
+ soldConversationId?: string | null | undefined;
3764
+ };
3765
+ } | {
3766
+ type: "DELIVERED";
3767
+ data: {
3768
+ soldAccountId: string;
3769
+ soldOrderId: string;
3770
+ soldConversationId?: string | null | undefined;
3771
+ };
3772
+ } | {
3773
+ type: "EMPTY";
3774
+ } | {
3775
+ type: "FAILED_TO_PUBLISH";
3776
+ data: {
3777
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
3778
+ accountId?: string | null | undefined;
3779
+ reason?: string | null | undefined;
3780
+ fields?: {
3781
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
3782
+ autoFixable: boolean;
3783
+ error?: string | null | undefined;
3784
+ }[] | null | undefined;
3785
+ itemHistoryId?: string | null | undefined;
3786
+ };
3787
+ } | {
3788
+ type: "IMAGE_PROCESSING_DONE";
3789
+ data: {
3790
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
3791
+ variations?: {
3792
+ fileId: string;
3793
+ seed: number;
3794
+ phash: string;
3795
+ distanceOriginal: number;
3796
+ originalImageUrl: string;
3797
+ originalPhash: string;
3798
+ }[] | null | undefined;
3799
+ originalPhashes?: string[] | null | undefined;
3800
+ };
3801
+ } | {
3802
+ type: "IMPORTED";
3803
+ data: {
3804
+ post: {
3805
+ platformId: string;
3806
+ post: {
3807
+ status?: string | null | undefined;
3808
+ price?: number | null | undefined;
3809
+ currency?: string | null | undefined;
3810
+ brand?: string | null | undefined;
3811
+ catalog?: string | null | undefined;
3812
+ catalogId?: number | null | undefined;
3813
+ colors?: string[] | null | undefined;
3814
+ colorIds?: number[] | null | undefined;
3815
+ description?: string | null | undefined;
3816
+ measurementLength?: number | null | undefined;
3817
+ measurementWidth?: number | null | undefined;
3818
+ packageSizeId?: number | null | undefined;
3819
+ photoUrls?: string[] | null | undefined;
3820
+ size?: string | null | undefined;
3821
+ sizeId?: number | null | undefined;
3822
+ statusId?: number | null | undefined;
3823
+ title?: string | null | undefined;
3824
+ isDraft?: boolean | null | undefined;
3825
+ isArchived?: boolean | null | undefined;
3826
+ availableQuantity?: number | null | undefined;
3827
+ material?: number[] | null | undefined;
3828
+ manufacturerLabelling?: string | null | undefined;
3829
+ labels?: string[] | null | undefined;
3830
+ };
3831
+ createdAt?: Date | null | undefined;
3832
+ platformUrl?: string | null | undefined;
3833
+ };
3834
+ };
3835
+ } | {
3836
+ type: "LIFECYCLE_COMPLETED";
3837
+ data: {
3838
+ accountId: string;
3839
+ };
3840
+ } | {
3841
+ type: "LIFECYCLE_STARTED";
3842
+ data: {
3843
+ accountId: string;
3844
+ caseId: string;
3845
+ };
3846
+ } | {
3847
+ type: "PUBLISHED";
3848
+ data: {
3849
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
3850
+ };
3851
+ } | {
3852
+ type: "REPUBLISHING";
3853
+ data: {
3854
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
3855
+ publishingDate?: Date | null | undefined;
3856
+ priceDropPayload?: {
3857
+ value: number;
3858
+ type: "PERCENTAGE" | "ABSOLUTE";
3859
+ roundType?: "NEAREST" | "UP" | "DOWN" | "CUSTOM" | null | undefined;
3860
+ roundStep?: number | null | undefined;
3861
+ maxRounds?: number | null | undefined;
3862
+ } | null | undefined;
3863
+ isTransfer?: boolean | null | undefined;
3864
+ targetAccountId?: string | null | undefined;
3865
+ };
3866
+ } | {
3867
+ type: "REPUBLISHING_RETRY";
3868
+ data: {
3869
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
3870
+ attemptNumber: number;
3871
+ maxAttempts: number;
3872
+ previousHistoryId: string;
3873
+ originalFailureDate: Date;
3874
+ fields?: {
3875
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
3876
+ autoFixable: boolean;
3877
+ error?: string | null | undefined;
3878
+ }[] | null | undefined;
3879
+ priceDropPayload?: {
3880
+ value: number;
3881
+ type: "PERCENTAGE" | "ABSOLUTE";
3882
+ roundType?: "NEAREST" | "UP" | "DOWN" | "CUSTOM" | null | undefined;
3883
+ roundStep?: number | null | undefined;
3884
+ maxRounds?: number | null | undefined;
3885
+ } | null | undefined;
3886
+ };
3887
+ } | {
3888
+ type: "SCHEDULED";
3889
+ data: {
3890
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
3891
+ publishingDate?: Date | null | undefined;
3892
+ };
3893
+ } | {
3894
+ type: "SCHEDULED_RETRY";
3895
+ data: {
3896
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
3897
+ attemptNumber: number;
3898
+ maxAttempts: number;
3899
+ previousHistoryId: string;
3900
+ originalFailureDate: Date;
3901
+ fields?: {
3902
+ field: "TITLE" | "DESCRIPTION" | "UNKNOWN" | "SIZE" | "BRAND" | "STATUS" | "PRICE" | "PACKAGE_SIZE" | "COLOR" | "CATALOG" | "PHOTOS";
3903
+ autoFixable: boolean;
3904
+ error?: string | null | undefined;
3905
+ }[] | null | undefined;
3906
+ };
3907
+ } | null | undefined;
3908
+ accountId?: string | null | undefined;
3909
+ requestId?: string | null | undefined;
3910
+ targetDate?: Date | null | undefined;
3911
+ } | null | undefined;
3912
+ platforms?: {
3913
+ status: "DRAFT" | "PENDING" | "ERROR" | "ONLINE" | "DELETED" | "ARCHIVED" | "SOLD" | "SOLD_ELSEWHERE" | "HIDDEN" | "DISPUTE";
3914
+ id: string;
3915
+ updatedAt: Date;
1854
3916
  createdAt: Date;
1855
- recurrence: "UNIQUE" | "MONTHLY" | "YEARLY";
1856
- startDate: Date;
1857
- active: boolean;
1858
- description?: string | null | undefined;
1859
- itemId?: string | number | null | undefined;
1860
- endDate?: Date | null | undefined;
1861
- parentFeeId?: string | number | null | undefined;
3917
+ accountId: string;
3918
+ itemId: string | number;
3919
+ platformId: string;
3920
+ platformUrl: string;
3921
+ platformPrice: number;
3922
+ publishedAt: Date;
3923
+ conversationId?: string | null | undefined;
3924
+ account?: {
3925
+ status: "CONNECTED" | "DISCONNECTED" | "ERROR" | "LOCKED";
3926
+ userId: string | number;
3927
+ name: string;
3928
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
3929
+ accountId: string;
3930
+ locale?: string | null | undefined;
3931
+ night?: {
3932
+ startsAt: Date;
3933
+ endsAt: Date;
3934
+ } | null | undefined;
3935
+ favoritesMaxDelay?: number | null | undefined;
3936
+ ordersMaxDelay?: number | null | undefined;
3937
+ conversationsMaxDelay?: number | null | undefined;
3938
+ } | null | undefined;
3939
+ viewsCount?: number | null | undefined;
3940
+ favoritesCount?: number | null | undefined;
1862
3941
  }[] | null | undefined;
1863
- feesSum?: number | null | undefined;
1864
- customerId?: string | number | null | undefined;
1865
- customer?: {
1866
- userId: string | number;
1867
- id: string | number;
1868
- email: string;
1869
- firstName: string;
1870
- lastName: string;
1871
- birthDate: Date;
1872
- idNumber: string;
1873
- phone: string;
1874
- iban: string;
1875
- bic: string;
1876
- phoneVerified: boolean;
1877
- } | null | undefined;
1878
- customerType?: string | null | undefined;
1879
- customerPaid?: boolean | null | undefined;
1880
- customerPaidDate?: Date | null | undefined;
1881
- customerPaidType?: string | null | undefined;
1882
- contractId?: string | number | null | undefined;
1883
- lastHistory?: {
3942
+ history?: {
1884
3943
  type: "CANCELED" | "SCHEDULED" | "DELETED" | "ARCHIVED" | "DISPUTE" | "IMPORTED" | "UNARCHIVED" | "PUBLISHED" | "FAILED_TO_PUBLISH" | "SCHEDULED_RETRY" | "REPUBLISHING_RETRY" | "PUBLISH_CANCELED" | "REPUBLISHING" | "IMAGE_PROCESSING_DONE" | "REPUBLISHED" | "REPUBLISH_CANCELED" | "UPDATING" | "UPDATED" | "UPDATE_CANCELED" | "DELETING" | "TO_BE_SENT" | "IN_TRANSIT" | "BUYER_PAID" | "DELIVERED" | "RECEIVED" | "FINALIZED" | "RETURN" | "REFUND" | "LIFECYCLE_STARTED" | "LIFECYCLE_COMPLETED" | "LIFECYCLE_CANCELED";
1885
3944
  id: string;
1886
3945
  createdAt: Date;
@@ -1978,6 +4037,11 @@ export declare const CreatedItemsSchema: z.ZodObject<{
1978
4037
  accountId: string;
1979
4038
  caseId: string;
1980
4039
  };
4040
+ } | {
4041
+ type: "PUBLISHED";
4042
+ data: {
4043
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
4044
+ };
1981
4045
  } | {
1982
4046
  type: "REPUBLISHING";
1983
4047
  data: {
@@ -2038,55 +4102,9 @@ export declare const CreatedItemsSchema: z.ZodObject<{
2038
4102
  accountId?: string | null | undefined;
2039
4103
  requestId?: string | null | undefined;
2040
4104
  targetDate?: Date | null | undefined;
2041
- } | null | undefined;
2042
- platforms?: {
2043
- status: "DRAFT" | "PENDING" | "ERROR" | "ONLINE" | "DELETED" | "ARCHIVED" | "SOLD" | "SOLD_ELSEWHERE" | "HIDDEN" | "DISPUTE";
2044
- id: string;
2045
- updatedAt: Date;
2046
- createdAt: Date;
2047
- accountId: string;
2048
- itemId: string | number;
2049
- platformId: string;
2050
- platformUrl: string;
2051
- platformPrice: number;
2052
- publishedAt: Date;
2053
- conversationId?: string | null | undefined;
2054
- account?: {
2055
- status: "CONNECTED" | "DISCONNECTED" | "ERROR" | "LOCKED";
2056
- userId: string | number;
2057
- name: string;
2058
- platform: "ETSY" | "SHOPIFY" | "VINTED";
2059
- accountId: string;
2060
- locale?: string | null | undefined;
2061
- night?: {
2062
- startsAt: Date;
2063
- endsAt: Date;
2064
- } | null | undefined;
2065
- favoritesMaxDelay?: number | null | undefined;
2066
- ordersMaxDelay?: number | null | undefined;
2067
- conversationsMaxDelay?: number | null | undefined;
2068
- } | null | undefined;
2069
- viewsCount?: number | null | undefined;
2070
- favoritesCount?: number | null | undefined;
2071
4105
  }[] | null | undefined;
2072
- }>, "many">;
2073
- newUserLabels: z.ZodArray<z.ZodObject<{
2074
- id: z.ZodUnion<[z.ZodNumber, z.ZodString]>;
2075
- name: z.ZodString;
2076
- userId: z.ZodOptional<z.ZodNullable<z.ZodUnion<[z.ZodNumber, z.ZodString]>>>;
2077
- isUserLabel: z.ZodBoolean;
2078
- createdAt: z.ZodDate;
2079
- itemCount: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
2080
- parentId: z.ZodUnknown;
2081
- }, "strip", z.ZodTypeAny, {
2082
- id: string | number;
2083
- name: string;
2084
- createdAt: Date;
2085
- isUserLabel: boolean;
2086
- userId?: string | number | null | undefined;
2087
- itemCount?: number | null | undefined;
2088
- parentId?: unknown;
2089
- }, {
4106
+ }[];
4107
+ newUserLabels: {
2090
4108
  id: string | number;
2091
4109
  name: string;
2092
4110
  createdAt: Date;
@@ -2094,8 +4112,8 @@ export declare const CreatedItemsSchema: z.ZodObject<{
2094
4112
  userId?: string | number | null | undefined;
2095
4113
  itemCount?: number | null | undefined;
2096
4114
  parentId?: unknown;
2097
- }>, "many">;
2098
- }, "strip", z.ZodTypeAny, {
4115
+ }[];
4116
+ }, {
2099
4117
  items: {
2100
4118
  userId: string | number;
2101
4119
  id: string | number;
@@ -2284,6 +4302,11 @@ export declare const CreatedItemsSchema: z.ZodObject<{
2284
4302
  accountId: string;
2285
4303
  caseId: string;
2286
4304
  };
4305
+ } | {
4306
+ type: "PUBLISHED";
4307
+ data: {
4308
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
4309
+ };
2287
4310
  } | {
2288
4311
  type: "REPUBLISHING";
2289
4312
  data: {
@@ -2375,108 +4398,7 @@ export declare const CreatedItemsSchema: z.ZodObject<{
2375
4398
  viewsCount?: number | null | undefined;
2376
4399
  favoritesCount?: number | null | undefined;
2377
4400
  }[] | null | undefined;
2378
- }[];
2379
- newUserLabels: {
2380
- id: string | number;
2381
- name: string;
2382
- createdAt: Date;
2383
- isUserLabel: boolean;
2384
- userId?: string | number | null | undefined;
2385
- itemCount?: number | null | undefined;
2386
- parentId?: unknown;
2387
- }[];
2388
- }, {
2389
- items: {
2390
- userId: string | number;
2391
- id: string | number;
2392
- updatedAt: Date;
2393
- name: string;
2394
- createdAt: Date;
2395
- sold: boolean;
2396
- state?: number | null | undefined;
2397
- colorIds?: number[] | null | undefined;
2398
- description?: string | null | undefined;
2399
- packageSizeId?: number | null | undefined;
2400
- sizeId?: number | null | undefined;
2401
- labels?: {
2402
- itemId: string | number;
2403
- labelId: string | number;
2404
- label?: {
2405
- id: string | number;
2406
- name: string;
2407
- createdAt: Date;
2408
- isUserLabel: boolean;
2409
- userId?: string | number | null | undefined;
2410
- itemCount?: number | null | undefined;
2411
- parentId?: unknown;
2412
- } | null | undefined;
2413
- }[] | null | undefined;
2414
- files?: {
2415
- itemId: string | number;
2416
- fileId: string;
2417
- index?: number | null | undefined;
2418
- file?: {
2419
- path: string;
2420
- userId: string | number;
2421
- id: string;
2422
- createdAt: Date;
2423
- signedUrl: string;
2424
- } | null | undefined;
2425
- }[] | null | undefined;
2426
- fields?: {
2427
- value: string;
2428
- itemId: string | number;
2429
- fieldId: string | number;
2430
- }[] | null | undefined;
2431
- sku?: string | null | undefined;
2432
- categoryId?: number | null | undefined;
2433
- brandId?: string | number | null | undefined;
2434
- sex?: string | null | undefined;
2435
- purchasePrice?: number | null | undefined;
2436
- purchaseDate?: Date | null | undefined;
2437
- purchasePlaceId?: string | number | null | undefined;
2438
- purchased?: boolean | null | undefined;
2439
- sellingPrice?: number | null | undefined;
2440
- sellingDate?: Date | null | undefined;
2441
- sellingPlaceId?: string | number | null | undefined;
2442
- estimatedPrice?: number | null | undefined;
2443
- fees?: {
2444
- value: number;
2445
- type: string;
2446
- userId: string | number;
2447
- id: string | number;
2448
- updatedAt: Date;
2449
- name: string;
2450
- createdAt: Date;
2451
- recurrence: "UNIQUE" | "MONTHLY" | "YEARLY";
2452
- startDate: Date;
2453
- active: boolean;
2454
- description?: string | null | undefined;
2455
- itemId?: string | number | null | undefined;
2456
- endDate?: Date | null | undefined;
2457
- parentFeeId?: string | number | null | undefined;
2458
- }[] | null | undefined;
2459
- feesSum?: number | null | undefined;
2460
- customerId?: string | number | null | undefined;
2461
- customer?: {
2462
- userId: string | number;
2463
- id: string | number;
2464
- email: string;
2465
- firstName: string;
2466
- lastName: string;
2467
- birthDate: Date;
2468
- idNumber: string;
2469
- phone: string;
2470
- iban: string;
2471
- bic: string;
2472
- phoneVerified: boolean;
2473
- } | null | undefined;
2474
- customerType?: string | null | undefined;
2475
- customerPaid?: boolean | null | undefined;
2476
- customerPaidDate?: Date | null | undefined;
2477
- customerPaidType?: string | null | undefined;
2478
- contractId?: string | number | null | undefined;
2479
- lastHistory?: {
4401
+ history?: {
2480
4402
  type: "CANCELED" | "SCHEDULED" | "DELETED" | "ARCHIVED" | "DISPUTE" | "IMPORTED" | "UNARCHIVED" | "PUBLISHED" | "FAILED_TO_PUBLISH" | "SCHEDULED_RETRY" | "REPUBLISHING_RETRY" | "PUBLISH_CANCELED" | "REPUBLISHING" | "IMAGE_PROCESSING_DONE" | "REPUBLISHED" | "REPUBLISH_CANCELED" | "UPDATING" | "UPDATED" | "UPDATE_CANCELED" | "DELETING" | "TO_BE_SENT" | "IN_TRANSIT" | "BUYER_PAID" | "DELIVERED" | "RECEIVED" | "FINALIZED" | "RETURN" | "REFUND" | "LIFECYCLE_STARTED" | "LIFECYCLE_COMPLETED" | "LIFECYCLE_CANCELED";
2481
4403
  id: string;
2482
4404
  createdAt: Date;
@@ -2574,6 +4496,11 @@ export declare const CreatedItemsSchema: z.ZodObject<{
2574
4496
  accountId: string;
2575
4497
  caseId: string;
2576
4498
  };
4499
+ } | {
4500
+ type: "PUBLISHED";
4501
+ data: {
4502
+ platform: "ETSY" | "SHOPIFY" | "VINTED";
4503
+ };
2577
4504
  } | {
2578
4505
  type: "REPUBLISHING";
2579
4506
  data: {
@@ -2634,36 +4561,6 @@ export declare const CreatedItemsSchema: z.ZodObject<{
2634
4561
  accountId?: string | null | undefined;
2635
4562
  requestId?: string | null | undefined;
2636
4563
  targetDate?: Date | null | undefined;
2637
- } | null | undefined;
2638
- platforms?: {
2639
- status: "DRAFT" | "PENDING" | "ERROR" | "ONLINE" | "DELETED" | "ARCHIVED" | "SOLD" | "SOLD_ELSEWHERE" | "HIDDEN" | "DISPUTE";
2640
- id: string;
2641
- updatedAt: Date;
2642
- createdAt: Date;
2643
- accountId: string;
2644
- itemId: string | number;
2645
- platformId: string;
2646
- platformUrl: string;
2647
- platformPrice: number;
2648
- publishedAt: Date;
2649
- conversationId?: string | null | undefined;
2650
- account?: {
2651
- status: "CONNECTED" | "DISCONNECTED" | "ERROR" | "LOCKED";
2652
- userId: string | number;
2653
- name: string;
2654
- platform: "ETSY" | "SHOPIFY" | "VINTED";
2655
- accountId: string;
2656
- locale?: string | null | undefined;
2657
- night?: {
2658
- startsAt: Date;
2659
- endsAt: Date;
2660
- } | null | undefined;
2661
- favoritesMaxDelay?: number | null | undefined;
2662
- ordersMaxDelay?: number | null | undefined;
2663
- conversationsMaxDelay?: number | null | undefined;
2664
- } | null | undefined;
2665
- viewsCount?: number | null | undefined;
2666
- favoritesCount?: number | null | undefined;
2667
4564
  }[] | null | undefined;
2668
4565
  }[];
2669
4566
  newUserLabels: {