controlresell 2.2.6 → 2.2.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +2 -2
- package/src/com/controlresell/models/application/RabbitMQRoutingKey.d.ts +1 -1
- package/src/com/controlresell/models/application/RabbitMQRoutingKey.js +1 -1
- package/src/com/controlresell/models/application/RabbitMQRoutingKey.ts +1 -1
- package/src/com/controlresell/models/items/CreatedItems.d.ts +205 -7
- package/src/com/controlresell/models/items/Item.d.ts +163 -5
- package/src/com/controlresell/models/items/ItemsWithFilters.d.ts +205 -7
- package/src/com/controlresell/models/items/UpdatedItem.d.ts +205 -7
- package/src/com/controlresell/models/items/history/CreateItemHistoryPayload.d.ts +121 -3
- package/src/com/controlresell/models/items/history/CreateItemHistoryPayload.js +2 -1
- package/src/com/controlresell/models/items/history/CreateItemHistoryPayload.ts +2 -1
- package/src/com/controlresell/models/items/history/ItemHistory.d.ts +121 -3
- package/src/com/controlresell/models/items/history/ItemHistory.js +2 -1
- package/src/com/controlresell/models/items/history/ItemHistory.ts +2 -1
- package/src/com/controlresell/models/items/history/ItemHistoryDecodedPayload.d.ts +81 -0
- package/src/com/controlresell/models/items/history/ItemHistoryDecodedPayload.js +24 -0
- package/src/com/controlresell/models/items/history/ItemHistoryDecodedPayload.ts +24 -0
- package/src/com/controlresell/models/items/history/data/ItemHistoryBuyerPaidPayload.d.ts +15 -0
- package/src/com/controlresell/models/items/history/data/ItemHistoryBuyerPaidPayload.js +9 -0
- package/src/com/controlresell/models/items/history/data/ItemHistoryBuyerPaidPayload.ts +8 -0
- package/src/com/controlresell/models/items/history/data/ItemHistoryDeliveredPayload.d.ts +15 -0
- package/src/com/controlresell/models/items/history/data/ItemHistoryDeliveredPayload.js +9 -0
- package/src/com/controlresell/models/items/history/data/ItemHistoryDeliveredPayload.ts +8 -0
- package/src/com/controlresell/models/items/platforms/PriceDropRequest.d.ts +42 -0
- package/src/com/controlresell/models/items/platforms/PriceDropRequest.js +9 -0
- package/src/com/controlresell/models/items/platforms/PriceDropRequest.ts +8 -0
- package/src/com/controlresell/models/items/platforms/RepublishRequest.d.ts +82 -0
- package/src/com/controlresell/models/items/platforms/RepublishRequest.js +9 -0
- package/src/com/controlresell/models/items/platforms/RepublishRequest.ts +8 -0
- package/src/com/controlresell/models/platforms/favorites/CreateFavoritePayload.d.ts +15 -0
- package/src/com/controlresell/models/platforms/favorites/CreateFavoritePayload.js +9 -0
- package/src/com/controlresell/models/platforms/favorites/CreateFavoritePayload.ts +8 -0
- package/src/com/controlresell/models/platforms/favorites/Favorite.d.ts +559 -0
- package/src/com/controlresell/models/platforms/favorites/Favorite.js +15 -0
- package/src/com/controlresell/models/platforms/favorites/Favorite.ts +14 -0
- package/src/com/controlresell/models/platforms/favorites/FavoriteOnPlatformUpdateRequest.d.ts +52 -0
- package/src/com/controlresell/models/platforms/favorites/FavoriteOnPlatformUpdateRequest.js +10 -0
- package/src/com/controlresell/models/platforms/favorites/FavoriteOnPlatformUpdateRequest.ts +9 -0
- package/src/com/controlresell/models/platforms/favorites/UpdateFavoritePayload.d.ts +12 -0
- package/src/com/controlresell/models/platforms/favorites/UpdateFavoritePayload.js +8 -0
- package/src/com/controlresell/models/platforms/favorites/UpdateFavoritePayload.ts +7 -0
- package/src/com/controlresell/models/platforms/orders/items/OrderWithItems.d.ts +205 -7
- package/src/com/controlresell/models/platforms/transactions/items/TransactionWithItems.d.ts +205 -7
- package/src/com/controlresell/models/preferences/CreatePreferencePayload.d.ts +3 -3
- package/src/com/controlresell/models/preferences/Preference.d.ts +29 -299
- package/src/com/controlresell/models/preferences/PreferenceFilter.d.ts +205 -7
- package/src/com/controlresell/models/preferences/PreferenceType.d.ts +1 -1
- package/src/com/controlresell/models/preferences/PreferenceType.js +1 -1
- package/src/com/controlresell/models/preferences/PreferenceType.ts +1 -1
- package/src/com/controlresell/models/preferences/PreferenceWithCase.d.ts +83 -893
- package/src/com/controlresell/models/preferences/cases/CreatePreferenceCasePayload.d.ts +22 -260
- package/src/com/controlresell/models/preferences/cases/PartialPreferenceCasePayload.d.ts +22 -260
- package/src/com/controlresell/models/preferences/cases/PreferenceCase.d.ts +22 -260
- package/src/com/controlresell/models/preferences/payloads/actions/PreferenceActionPayload.d.ts +6 -116
- package/src/com/controlresell/models/preferences/payloads/actions/PreferenceActionPayload.js +2 -1
- package/src/com/controlresell/models/preferences/payloads/actions/PreferenceActionPayload.ts +2 -1
- package/src/com/controlresell/models/preferences/payloads/actions/PreferenceActionPayloadDecodedPayload.d.ts +0 -79
- package/src/com/controlresell/models/preferences/payloads/actions/PreferenceActionPayloadDecodedPayload.js +0 -5
- package/src/com/controlresell/models/preferences/payloads/actions/PreferenceActionPayloadDecodedPayload.ts +0 -5
- package/src/com/controlresell/models/preferences/payloads/actions/PreferenceActionPayloadType.d.ts +1 -1
- package/src/com/controlresell/models/preferences/payloads/actions/PreferenceActionPayloadType.js +1 -1
- package/src/com/controlresell/models/preferences/payloads/actions/PreferenceActionPayloadType.ts +1 -1
- package/src/com/controlresell/models/preferences/payloads/actions/PreferenceActionsPayload.d.ts +10 -152
- package/src/com/controlresell/models/preferences/payloads/vision/TryVisionPayload.d.ts +82 -0
- package/src/com/controlresell/models/preferences/payloads/vision/TryVisionPayload.js +9 -0
- package/src/com/controlresell/models/preferences/payloads/vision/TryVisionPayload.ts +8 -0
- package/src/com/controlresell/models/preferences/queue/PreferenceNextActionPayload.d.ts +213 -0
- package/src/com/controlresell/models/preferences/queue/PreferenceNextActionPayload.js +13 -0
- package/src/com/controlresell/models/preferences/queue/PreferenceNextActionPayload.ts +12 -0
- package/src/com/controlresell/models/preferences/queue/PreferenceNextActionPayloadType.d.ts +3 -0
- package/src/com/controlresell/models/preferences/queue/PreferenceNextActionPayloadType.js +7 -0
- package/src/com/controlresell/models/preferences/queue/PreferenceNextActionPayloadType.ts +6 -0
- package/src/com/controlresell/models/preferences/variables/PreferenceVariable.d.ts +3 -3
- package/src/com/controlresell/models/preferences/variables/PreferenceVariableName.d.ts +1 -1
- package/src/com/controlresell/models/preferences/variables/PreferenceVariableName.js +1 -1
- package/src/com/controlresell/models/preferences/variables/PreferenceVariableName.ts +1 -1
- package/src/com/controlresell/models/preferences/variants/PartialPreferenceCaseVariantPayload.d.ts +18 -224
- package/src/com/controlresell/models/preferences/variants/PreferenceCaseVariant.d.ts +18 -224
- package/src/com/controlresell/models/preferences/variants/PreferenceCaseVariantDecodedPayload.d.ts +14 -188
- package/src/com/controlresell/models/preferences/variants/PreferenceCaseVariantPayload.d.ts +18 -224
- package/src/index.d.ts +12 -3
- package/src/index.js +27 -9
- package/src/index.ts +12 -3
- package/src/com/controlresell/models/platforms/preferences/CreatePlatformPreferencePayload.d.ts +0 -36
- package/src/com/controlresell/models/platforms/preferences/CreatePlatformPreferencePayload.js +0 -17
- package/src/com/controlresell/models/platforms/preferences/CreatePlatformPreferencePayload.ts +0 -16
- package/src/com/controlresell/models/platforms/preferences/PlatformPreference.d.ts +0 -42
- package/src/com/controlresell/models/platforms/preferences/PlatformPreference.js +0 -20
- package/src/com/controlresell/models/platforms/preferences/PlatformPreference.ts +0 -19
- package/src/com/controlresell/models/platforms/preferences/UpdatePlatformPreferencePayload.d.ts +0 -30
- package/src/com/controlresell/models/platforms/preferences/UpdatePlatformPreferencePayload.js +0 -14
- package/src/com/controlresell/models/platforms/preferences/UpdatePlatformPreferencePayload.ts +0 -13
|
@@ -3,19 +3,137 @@ export declare const ItemHistorySchema: z.ZodObject<{
|
|
|
3
3
|
id: z.ZodString;
|
|
4
4
|
itemId: z.ZodUnion<[z.ZodNumber, z.ZodString]>;
|
|
5
5
|
type: z.ZodEnum<["IMPORTED", "PUBLISHED", "FAILED_TO_PUBLISH", "SCHEDULED", "UPDATED", "DELETED", "TO_BE_SENT", "IN_TRANSIT", "BUYER_PAID", "DELIVERED", "RECEIVED", "FINALIZED", "RETURN", "REFUND"]>;
|
|
6
|
-
data: z.ZodOptional<z.ZodNullable<z.
|
|
6
|
+
data: z.ZodOptional<z.ZodNullable<z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
|
|
7
|
+
type: z.ZodLiteral<"EMPTY">;
|
|
8
|
+
}, "strip", z.ZodTypeAny, {
|
|
9
|
+
type: "EMPTY";
|
|
10
|
+
}, {
|
|
11
|
+
type: "EMPTY";
|
|
12
|
+
}>, z.ZodObject<{
|
|
13
|
+
type: z.ZodLiteral<"SCHEDULED">;
|
|
14
|
+
data: z.ZodObject<{
|
|
15
|
+
platform: z.ZodEnum<["VINTED", "SHOPIFY"]>;
|
|
16
|
+
publishingDate: z.ZodOptional<z.ZodNullable<z.ZodDate>>;
|
|
17
|
+
}, "strip", z.ZodTypeAny, {
|
|
18
|
+
platform: "VINTED" | "SHOPIFY";
|
|
19
|
+
publishingDate?: Date | null | undefined;
|
|
20
|
+
}, {
|
|
21
|
+
platform: "VINTED" | "SHOPIFY";
|
|
22
|
+
publishingDate?: Date | null | undefined;
|
|
23
|
+
}>;
|
|
24
|
+
}, "strip", z.ZodTypeAny, {
|
|
25
|
+
type: "SCHEDULED";
|
|
26
|
+
data: {
|
|
27
|
+
platform: "VINTED" | "SHOPIFY";
|
|
28
|
+
publishingDate?: Date | null | undefined;
|
|
29
|
+
};
|
|
30
|
+
}, {
|
|
31
|
+
type: "SCHEDULED";
|
|
32
|
+
data: {
|
|
33
|
+
platform: "VINTED" | "SHOPIFY";
|
|
34
|
+
publishingDate?: Date | null | undefined;
|
|
35
|
+
};
|
|
36
|
+
}>, z.ZodObject<{
|
|
37
|
+
type: z.ZodLiteral<"FAILED_TO_PUBLISH">;
|
|
38
|
+
data: z.ZodObject<{
|
|
39
|
+
platform: z.ZodEnum<["VINTED", "SHOPIFY"]>;
|
|
40
|
+
}, "strip", z.ZodTypeAny, {
|
|
41
|
+
platform: "VINTED" | "SHOPIFY";
|
|
42
|
+
}, {
|
|
43
|
+
platform: "VINTED" | "SHOPIFY";
|
|
44
|
+
}>;
|
|
45
|
+
}, "strip", z.ZodTypeAny, {
|
|
46
|
+
type: "FAILED_TO_PUBLISH";
|
|
47
|
+
data: {
|
|
48
|
+
platform: "VINTED" | "SHOPIFY";
|
|
49
|
+
};
|
|
50
|
+
}, {
|
|
51
|
+
type: "FAILED_TO_PUBLISH";
|
|
52
|
+
data: {
|
|
53
|
+
platform: "VINTED" | "SHOPIFY";
|
|
54
|
+
};
|
|
55
|
+
}>, z.ZodObject<{
|
|
56
|
+
type: z.ZodLiteral<"BUYER_PAID">;
|
|
57
|
+
data: z.ZodObject<{
|
|
58
|
+
soldAccountId: z.ZodString;
|
|
59
|
+
soldOrderId: z.ZodString;
|
|
60
|
+
soldConversationId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
61
|
+
}, "strip", z.ZodTypeAny, {
|
|
62
|
+
soldAccountId: string;
|
|
63
|
+
soldOrderId: string;
|
|
64
|
+
soldConversationId?: string | null | undefined;
|
|
65
|
+
}, {
|
|
66
|
+
soldAccountId: string;
|
|
67
|
+
soldOrderId: string;
|
|
68
|
+
soldConversationId?: string | null | undefined;
|
|
69
|
+
}>;
|
|
70
|
+
}, "strip", z.ZodTypeAny, {
|
|
71
|
+
type: "BUYER_PAID";
|
|
72
|
+
data: {
|
|
73
|
+
soldAccountId: string;
|
|
74
|
+
soldOrderId: string;
|
|
75
|
+
soldConversationId?: string | null | undefined;
|
|
76
|
+
};
|
|
77
|
+
}, {
|
|
78
|
+
type: "BUYER_PAID";
|
|
79
|
+
data: {
|
|
80
|
+
soldAccountId: string;
|
|
81
|
+
soldOrderId: string;
|
|
82
|
+
soldConversationId?: string | null | undefined;
|
|
83
|
+
};
|
|
84
|
+
}>]>>>;
|
|
7
85
|
createdAt: z.ZodDate;
|
|
8
86
|
}, "strip", z.ZodTypeAny, {
|
|
9
87
|
type: "IMPORTED" | "PUBLISHED" | "FAILED_TO_PUBLISH" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT" | "BUYER_PAID" | "DELIVERED" | "RECEIVED" | "FINALIZED" | "RETURN" | "REFUND";
|
|
10
88
|
id: string;
|
|
11
89
|
createdAt: Date;
|
|
12
90
|
itemId: string | number;
|
|
13
|
-
data?:
|
|
91
|
+
data?: {
|
|
92
|
+
type: "EMPTY";
|
|
93
|
+
} | {
|
|
94
|
+
type: "SCHEDULED";
|
|
95
|
+
data: {
|
|
96
|
+
platform: "VINTED" | "SHOPIFY";
|
|
97
|
+
publishingDate?: Date | null | undefined;
|
|
98
|
+
};
|
|
99
|
+
} | {
|
|
100
|
+
type: "FAILED_TO_PUBLISH";
|
|
101
|
+
data: {
|
|
102
|
+
platform: "VINTED" | "SHOPIFY";
|
|
103
|
+
};
|
|
104
|
+
} | {
|
|
105
|
+
type: "BUYER_PAID";
|
|
106
|
+
data: {
|
|
107
|
+
soldAccountId: string;
|
|
108
|
+
soldOrderId: string;
|
|
109
|
+
soldConversationId?: string | null | undefined;
|
|
110
|
+
};
|
|
111
|
+
} | null | undefined;
|
|
14
112
|
}, {
|
|
15
113
|
type: "IMPORTED" | "PUBLISHED" | "FAILED_TO_PUBLISH" | "SCHEDULED" | "UPDATED" | "DELETED" | "TO_BE_SENT" | "IN_TRANSIT" | "BUYER_PAID" | "DELIVERED" | "RECEIVED" | "FINALIZED" | "RETURN" | "REFUND";
|
|
16
114
|
id: string;
|
|
17
115
|
createdAt: Date;
|
|
18
116
|
itemId: string | number;
|
|
19
|
-
data?:
|
|
117
|
+
data?: {
|
|
118
|
+
type: "EMPTY";
|
|
119
|
+
} | {
|
|
120
|
+
type: "SCHEDULED";
|
|
121
|
+
data: {
|
|
122
|
+
platform: "VINTED" | "SHOPIFY";
|
|
123
|
+
publishingDate?: Date | null | undefined;
|
|
124
|
+
};
|
|
125
|
+
} | {
|
|
126
|
+
type: "FAILED_TO_PUBLISH";
|
|
127
|
+
data: {
|
|
128
|
+
platform: "VINTED" | "SHOPIFY";
|
|
129
|
+
};
|
|
130
|
+
} | {
|
|
131
|
+
type: "BUYER_PAID";
|
|
132
|
+
data: {
|
|
133
|
+
soldAccountId: string;
|
|
134
|
+
soldOrderId: string;
|
|
135
|
+
soldConversationId?: string | null | undefined;
|
|
136
|
+
};
|
|
137
|
+
} | null | undefined;
|
|
20
138
|
}>;
|
|
21
139
|
export type ItemHistory = z.infer<typeof ItemHistorySchema>;
|
|
@@ -4,10 +4,11 @@ exports.ItemHistorySchema = void 0;
|
|
|
4
4
|
const zod_1 = require("zod");
|
|
5
5
|
const zodable_idschema_1 = require("zodable-idschema");
|
|
6
6
|
const ItemHistoryType_1 = require("./ItemHistoryType");
|
|
7
|
+
const ItemHistoryDecodedPayload_1 = require("./ItemHistoryDecodedPayload");
|
|
7
8
|
exports.ItemHistorySchema = zod_1.z.object({
|
|
8
9
|
id: zod_1.z.string().uuid(),
|
|
9
10
|
itemId: zodable_idschema_1.IdSchema,
|
|
10
11
|
type: ItemHistoryType_1.ItemHistoryTypeSchema,
|
|
11
|
-
data:
|
|
12
|
+
data: ItemHistoryDecodedPayload_1.ItemHistoryDecodedPayloadSchema.nullish(),
|
|
12
13
|
createdAt: zod_1.z.coerce.date()
|
|
13
14
|
});
|
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
import {z} from "zod"
|
|
2
2
|
import {IdSchema} from "zodable-idschema"
|
|
3
3
|
import {ItemHistoryTypeSchema} from "./ItemHistoryType"
|
|
4
|
+
import {ItemHistoryDecodedPayloadSchema} from "./ItemHistoryDecodedPayload"
|
|
4
5
|
|
|
5
6
|
export const ItemHistorySchema = z.object({
|
|
6
7
|
id: z.string().uuid(),
|
|
7
8
|
itemId: IdSchema,
|
|
8
9
|
type: ItemHistoryTypeSchema,
|
|
9
|
-
data:
|
|
10
|
+
data: ItemHistoryDecodedPayloadSchema.nullish(),
|
|
10
11
|
createdAt: z.coerce.date()
|
|
11
12
|
})
|
|
12
13
|
export type ItemHistory = z.infer<typeof ItemHistorySchema>
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
export declare const ItemHistoryDecodedPayloadSchema: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
|
|
3
|
+
type: z.ZodLiteral<"EMPTY">;
|
|
4
|
+
}, "strip", z.ZodTypeAny, {
|
|
5
|
+
type: "EMPTY";
|
|
6
|
+
}, {
|
|
7
|
+
type: "EMPTY";
|
|
8
|
+
}>, z.ZodObject<{
|
|
9
|
+
type: z.ZodLiteral<"SCHEDULED">;
|
|
10
|
+
data: z.ZodObject<{
|
|
11
|
+
platform: z.ZodEnum<["VINTED", "SHOPIFY"]>;
|
|
12
|
+
publishingDate: z.ZodOptional<z.ZodNullable<z.ZodDate>>;
|
|
13
|
+
}, "strip", z.ZodTypeAny, {
|
|
14
|
+
platform: "VINTED" | "SHOPIFY";
|
|
15
|
+
publishingDate?: Date | null | undefined;
|
|
16
|
+
}, {
|
|
17
|
+
platform: "VINTED" | "SHOPIFY";
|
|
18
|
+
publishingDate?: Date | null | undefined;
|
|
19
|
+
}>;
|
|
20
|
+
}, "strip", z.ZodTypeAny, {
|
|
21
|
+
type: "SCHEDULED";
|
|
22
|
+
data: {
|
|
23
|
+
platform: "VINTED" | "SHOPIFY";
|
|
24
|
+
publishingDate?: Date | null | undefined;
|
|
25
|
+
};
|
|
26
|
+
}, {
|
|
27
|
+
type: "SCHEDULED";
|
|
28
|
+
data: {
|
|
29
|
+
platform: "VINTED" | "SHOPIFY";
|
|
30
|
+
publishingDate?: Date | null | undefined;
|
|
31
|
+
};
|
|
32
|
+
}>, z.ZodObject<{
|
|
33
|
+
type: z.ZodLiteral<"FAILED_TO_PUBLISH">;
|
|
34
|
+
data: z.ZodObject<{
|
|
35
|
+
platform: z.ZodEnum<["VINTED", "SHOPIFY"]>;
|
|
36
|
+
}, "strip", z.ZodTypeAny, {
|
|
37
|
+
platform: "VINTED" | "SHOPIFY";
|
|
38
|
+
}, {
|
|
39
|
+
platform: "VINTED" | "SHOPIFY";
|
|
40
|
+
}>;
|
|
41
|
+
}, "strip", z.ZodTypeAny, {
|
|
42
|
+
type: "FAILED_TO_PUBLISH";
|
|
43
|
+
data: {
|
|
44
|
+
platform: "VINTED" | "SHOPIFY";
|
|
45
|
+
};
|
|
46
|
+
}, {
|
|
47
|
+
type: "FAILED_TO_PUBLISH";
|
|
48
|
+
data: {
|
|
49
|
+
platform: "VINTED" | "SHOPIFY";
|
|
50
|
+
};
|
|
51
|
+
}>, z.ZodObject<{
|
|
52
|
+
type: z.ZodLiteral<"BUYER_PAID">;
|
|
53
|
+
data: z.ZodObject<{
|
|
54
|
+
soldAccountId: z.ZodString;
|
|
55
|
+
soldOrderId: z.ZodString;
|
|
56
|
+
soldConversationId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
57
|
+
}, "strip", z.ZodTypeAny, {
|
|
58
|
+
soldAccountId: string;
|
|
59
|
+
soldOrderId: string;
|
|
60
|
+
soldConversationId?: string | null | undefined;
|
|
61
|
+
}, {
|
|
62
|
+
soldAccountId: string;
|
|
63
|
+
soldOrderId: string;
|
|
64
|
+
soldConversationId?: string | null | undefined;
|
|
65
|
+
}>;
|
|
66
|
+
}, "strip", z.ZodTypeAny, {
|
|
67
|
+
type: "BUYER_PAID";
|
|
68
|
+
data: {
|
|
69
|
+
soldAccountId: string;
|
|
70
|
+
soldOrderId: string;
|
|
71
|
+
soldConversationId?: string | null | undefined;
|
|
72
|
+
};
|
|
73
|
+
}, {
|
|
74
|
+
type: "BUYER_PAID";
|
|
75
|
+
data: {
|
|
76
|
+
soldAccountId: string;
|
|
77
|
+
soldOrderId: string;
|
|
78
|
+
soldConversationId?: string | null | undefined;
|
|
79
|
+
};
|
|
80
|
+
}>]>;
|
|
81
|
+
export type ItemHistoryDecodedPayload = z.infer<typeof ItemHistoryDecodedPayloadSchema>;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ItemHistoryDecodedPayloadSchema = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const ItemHistoryScheduledPayload_1 = require("./data/ItemHistoryScheduledPayload");
|
|
6
|
+
const ItemHistoryFailedToPublishPayload_1 = require("./data/ItemHistoryFailedToPublishPayload");
|
|
7
|
+
const ItemHistoryBuyerPaidPayload_1 = require("./data/ItemHistoryBuyerPaidPayload");
|
|
8
|
+
exports.ItemHistoryDecodedPayloadSchema = zod_1.z.discriminatedUnion("type", [
|
|
9
|
+
zod_1.z.object({
|
|
10
|
+
type: zod_1.z.literal("EMPTY"),
|
|
11
|
+
}),
|
|
12
|
+
zod_1.z.object({
|
|
13
|
+
type: zod_1.z.literal("SCHEDULED"),
|
|
14
|
+
data: ItemHistoryScheduledPayload_1.ItemHistoryScheduledPayloadSchema,
|
|
15
|
+
}),
|
|
16
|
+
zod_1.z.object({
|
|
17
|
+
type: zod_1.z.literal("FAILED_TO_PUBLISH"),
|
|
18
|
+
data: ItemHistoryFailedToPublishPayload_1.ItemHistoryFailedToPublishPayloadSchema,
|
|
19
|
+
}),
|
|
20
|
+
zod_1.z.object({
|
|
21
|
+
type: zod_1.z.literal("BUYER_PAID"),
|
|
22
|
+
data: ItemHistoryBuyerPaidPayload_1.ItemHistoryBuyerPaidPayloadSchema,
|
|
23
|
+
}),
|
|
24
|
+
]);
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import {z} from "zod"
|
|
2
|
+
|
|
3
|
+
import {ItemHistoryScheduledPayloadSchema} from "./data/ItemHistoryScheduledPayload"
|
|
4
|
+
import {ItemHistoryFailedToPublishPayloadSchema} from "./data/ItemHistoryFailedToPublishPayload"
|
|
5
|
+
import {ItemHistoryBuyerPaidPayloadSchema} from "./data/ItemHistoryBuyerPaidPayload"
|
|
6
|
+
|
|
7
|
+
export const ItemHistoryDecodedPayloadSchema = z.discriminatedUnion("type", [
|
|
8
|
+
z.object({
|
|
9
|
+
type: z.literal("EMPTY"),
|
|
10
|
+
}),
|
|
11
|
+
z.object({
|
|
12
|
+
type: z.literal("SCHEDULED"),
|
|
13
|
+
data: ItemHistoryScheduledPayloadSchema,
|
|
14
|
+
}),
|
|
15
|
+
z.object({
|
|
16
|
+
type: z.literal("FAILED_TO_PUBLISH"),
|
|
17
|
+
data: ItemHistoryFailedToPublishPayloadSchema,
|
|
18
|
+
}),
|
|
19
|
+
z.object({
|
|
20
|
+
type: z.literal("BUYER_PAID"),
|
|
21
|
+
data: ItemHistoryBuyerPaidPayloadSchema,
|
|
22
|
+
}),
|
|
23
|
+
])
|
|
24
|
+
export type ItemHistoryDecodedPayload = z.infer<typeof ItemHistoryDecodedPayloadSchema>
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
export declare const ItemHistoryBuyerPaidPayloadSchema: z.ZodObject<{
|
|
3
|
+
soldAccountId: z.ZodString;
|
|
4
|
+
soldOrderId: z.ZodString;
|
|
5
|
+
soldConversationId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
6
|
+
}, "strip", z.ZodTypeAny, {
|
|
7
|
+
soldAccountId: string;
|
|
8
|
+
soldOrderId: string;
|
|
9
|
+
soldConversationId?: string | null | undefined;
|
|
10
|
+
}, {
|
|
11
|
+
soldAccountId: string;
|
|
12
|
+
soldOrderId: string;
|
|
13
|
+
soldConversationId?: string | null | undefined;
|
|
14
|
+
}>;
|
|
15
|
+
export type ItemHistoryBuyerPaidPayload = z.infer<typeof ItemHistoryBuyerPaidPayloadSchema>;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ItemHistoryBuyerPaidPayloadSchema = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
exports.ItemHistoryBuyerPaidPayloadSchema = zod_1.z.object({
|
|
6
|
+
soldAccountId: zod_1.z.string().uuid(),
|
|
7
|
+
soldOrderId: zod_1.z.string().uuid(),
|
|
8
|
+
soldConversationId: zod_1.z.string().uuid().nullish()
|
|
9
|
+
});
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import {z} from "zod"
|
|
2
|
+
|
|
3
|
+
export const ItemHistoryBuyerPaidPayloadSchema = z.object({
|
|
4
|
+
soldAccountId: z.string().uuid(),
|
|
5
|
+
soldOrderId: z.string().uuid(),
|
|
6
|
+
soldConversationId: z.string().uuid().nullish()
|
|
7
|
+
})
|
|
8
|
+
export type ItemHistoryBuyerPaidPayload = z.infer<typeof ItemHistoryBuyerPaidPayloadSchema>
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
export declare const ItemHistoryDeliveredPayloadSchema: z.ZodObject<{
|
|
3
|
+
soldAccountId: z.ZodString;
|
|
4
|
+
soldOrderId: z.ZodString;
|
|
5
|
+
soldConversationId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
6
|
+
}, "strip", z.ZodTypeAny, {
|
|
7
|
+
soldAccountId: string;
|
|
8
|
+
soldOrderId: string;
|
|
9
|
+
soldConversationId?: string | null | undefined;
|
|
10
|
+
}, {
|
|
11
|
+
soldAccountId: string;
|
|
12
|
+
soldOrderId: string;
|
|
13
|
+
soldConversationId?: string | null | undefined;
|
|
14
|
+
}>;
|
|
15
|
+
export type ItemHistoryDeliveredPayload = z.infer<typeof ItemHistoryDeliveredPayloadSchema>;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ItemHistoryDeliveredPayloadSchema = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
exports.ItemHistoryDeliveredPayloadSchema = zod_1.z.object({
|
|
6
|
+
soldAccountId: zod_1.z.string().uuid(),
|
|
7
|
+
soldOrderId: zod_1.z.string().uuid(),
|
|
8
|
+
soldConversationId: zod_1.z.string().uuid().nullish()
|
|
9
|
+
});
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import {z} from "zod"
|
|
2
|
+
|
|
3
|
+
export const ItemHistoryDeliveredPayloadSchema = z.object({
|
|
4
|
+
soldAccountId: z.string().uuid(),
|
|
5
|
+
soldOrderId: z.string().uuid(),
|
|
6
|
+
soldConversationId: z.string().uuid().nullish()
|
|
7
|
+
})
|
|
8
|
+
export type ItemHistoryDeliveredPayload = z.infer<typeof ItemHistoryDeliveredPayloadSchema>
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
export declare const PriceDropRequestSchema: z.ZodObject<{
|
|
3
|
+
pricePayload: z.ZodObject<{
|
|
4
|
+
type: z.ZodEnum<["PERCENTAGE", "ABSOLUTE"]>;
|
|
5
|
+
value: z.ZodNumber;
|
|
6
|
+
roundType: z.ZodOptional<z.ZodNullable<z.ZodEnum<["NEAREST", "UP", "DOWN", "CUSTOM"]>>>;
|
|
7
|
+
roundStep: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
8
|
+
negotiationProfile: z.ZodOptional<z.ZodNullable<z.ZodEnum<["AUTO", "MODERATE", "CONSERVATIVE"]>>>;
|
|
9
|
+
}, "strip", z.ZodTypeAny, {
|
|
10
|
+
value: number;
|
|
11
|
+
type: "PERCENTAGE" | "ABSOLUTE";
|
|
12
|
+
roundType?: "NEAREST" | "UP" | "DOWN" | "CUSTOM" | null | undefined;
|
|
13
|
+
roundStep?: number | null | undefined;
|
|
14
|
+
negotiationProfile?: "AUTO" | "MODERATE" | "CONSERVATIVE" | null | undefined;
|
|
15
|
+
}, {
|
|
16
|
+
value: number;
|
|
17
|
+
type: "PERCENTAGE" | "ABSOLUTE";
|
|
18
|
+
roundType?: "NEAREST" | "UP" | "DOWN" | "CUSTOM" | null | undefined;
|
|
19
|
+
roundStep?: number | null | undefined;
|
|
20
|
+
negotiationProfile?: "AUTO" | "MODERATE" | "CONSERVATIVE" | null | undefined;
|
|
21
|
+
}>;
|
|
22
|
+
accountsId: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodString, "many">>>;
|
|
23
|
+
}, "strip", z.ZodTypeAny, {
|
|
24
|
+
pricePayload: {
|
|
25
|
+
value: number;
|
|
26
|
+
type: "PERCENTAGE" | "ABSOLUTE";
|
|
27
|
+
roundType?: "NEAREST" | "UP" | "DOWN" | "CUSTOM" | null | undefined;
|
|
28
|
+
roundStep?: number | null | undefined;
|
|
29
|
+
negotiationProfile?: "AUTO" | "MODERATE" | "CONSERVATIVE" | null | undefined;
|
|
30
|
+
};
|
|
31
|
+
accountsId?: string[] | null | undefined;
|
|
32
|
+
}, {
|
|
33
|
+
pricePayload: {
|
|
34
|
+
value: number;
|
|
35
|
+
type: "PERCENTAGE" | "ABSOLUTE";
|
|
36
|
+
roundType?: "NEAREST" | "UP" | "DOWN" | "CUSTOM" | null | undefined;
|
|
37
|
+
roundStep?: number | null | undefined;
|
|
38
|
+
negotiationProfile?: "AUTO" | "MODERATE" | "CONSERVATIVE" | null | undefined;
|
|
39
|
+
};
|
|
40
|
+
accountsId?: string[] | null | undefined;
|
|
41
|
+
}>;
|
|
42
|
+
export type PriceDropRequest = z.infer<typeof PriceDropRequestSchema>;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.PriceDropRequestSchema = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const PreferencePricePayload_1 = require("../../preferences/payloads/prices/PreferencePricePayload");
|
|
6
|
+
exports.PriceDropRequestSchema = zod_1.z.object({
|
|
7
|
+
pricePayload: PreferencePricePayload_1.PreferencePricePayloadSchema,
|
|
8
|
+
accountsId: zod_1.z.array(zod_1.z.string().uuid()).nullish()
|
|
9
|
+
});
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import {z} from "zod"
|
|
2
|
+
import {PreferencePricePayloadSchema} from "../../preferences/payloads/prices/PreferencePricePayload"
|
|
3
|
+
|
|
4
|
+
export const PriceDropRequestSchema = z.object({
|
|
5
|
+
pricePayload: PreferencePricePayloadSchema,
|
|
6
|
+
accountsId: z.array(z.string().uuid()).nullish()
|
|
7
|
+
})
|
|
8
|
+
export type PriceDropRequest = z.infer<typeof PriceDropRequestSchema>
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
export declare const RepublishRequestSchema: z.ZodObject<{
|
|
3
|
+
visionPayload: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
4
|
+
doRemoveBackground: z.ZodBoolean;
|
|
5
|
+
doSmartCrop: z.ZodBoolean;
|
|
6
|
+
doChangeBackground: z.ZodBoolean;
|
|
7
|
+
doRotate: z.ZodBoolean;
|
|
8
|
+
doAddBorders: z.ZodBoolean;
|
|
9
|
+
shadow: z.ZodBoolean;
|
|
10
|
+
targetWidth: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
11
|
+
targetHeight: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
12
|
+
newBackgroundColor: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
13
|
+
newBackgroundUrl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
14
|
+
rotationAngle: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
15
|
+
borderSize: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
16
|
+
borderColor: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
17
|
+
}, "strip", z.ZodTypeAny, {
|
|
18
|
+
doRemoveBackground: boolean;
|
|
19
|
+
doSmartCrop: boolean;
|
|
20
|
+
doChangeBackground: boolean;
|
|
21
|
+
doRotate: boolean;
|
|
22
|
+
doAddBorders: boolean;
|
|
23
|
+
shadow: boolean;
|
|
24
|
+
targetWidth?: number | null | undefined;
|
|
25
|
+
targetHeight?: number | null | undefined;
|
|
26
|
+
newBackgroundColor?: string | null | undefined;
|
|
27
|
+
newBackgroundUrl?: string | null | undefined;
|
|
28
|
+
rotationAngle?: number | null | undefined;
|
|
29
|
+
borderSize?: number | null | undefined;
|
|
30
|
+
borderColor?: string | null | undefined;
|
|
31
|
+
}, {
|
|
32
|
+
doRemoveBackground: boolean;
|
|
33
|
+
doSmartCrop: boolean;
|
|
34
|
+
doChangeBackground: boolean;
|
|
35
|
+
doRotate: boolean;
|
|
36
|
+
doAddBorders: boolean;
|
|
37
|
+
shadow: boolean;
|
|
38
|
+
targetWidth?: number | null | undefined;
|
|
39
|
+
targetHeight?: number | null | undefined;
|
|
40
|
+
newBackgroundColor?: string | null | undefined;
|
|
41
|
+
newBackgroundUrl?: string | null | undefined;
|
|
42
|
+
rotationAngle?: number | null | undefined;
|
|
43
|
+
borderSize?: number | null | undefined;
|
|
44
|
+
borderColor?: string | null | undefined;
|
|
45
|
+
}>>>;
|
|
46
|
+
accountsId: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodString, "many">>>;
|
|
47
|
+
}, "strip", z.ZodTypeAny, {
|
|
48
|
+
accountsId?: string[] | null | undefined;
|
|
49
|
+
visionPayload?: {
|
|
50
|
+
doRemoveBackground: boolean;
|
|
51
|
+
doSmartCrop: boolean;
|
|
52
|
+
doChangeBackground: boolean;
|
|
53
|
+
doRotate: boolean;
|
|
54
|
+
doAddBorders: boolean;
|
|
55
|
+
shadow: boolean;
|
|
56
|
+
targetWidth?: number | null | undefined;
|
|
57
|
+
targetHeight?: number | null | undefined;
|
|
58
|
+
newBackgroundColor?: string | null | undefined;
|
|
59
|
+
newBackgroundUrl?: string | null | undefined;
|
|
60
|
+
rotationAngle?: number | null | undefined;
|
|
61
|
+
borderSize?: number | null | undefined;
|
|
62
|
+
borderColor?: string | null | undefined;
|
|
63
|
+
} | null | undefined;
|
|
64
|
+
}, {
|
|
65
|
+
accountsId?: string[] | null | undefined;
|
|
66
|
+
visionPayload?: {
|
|
67
|
+
doRemoveBackground: boolean;
|
|
68
|
+
doSmartCrop: boolean;
|
|
69
|
+
doChangeBackground: boolean;
|
|
70
|
+
doRotate: boolean;
|
|
71
|
+
doAddBorders: boolean;
|
|
72
|
+
shadow: boolean;
|
|
73
|
+
targetWidth?: number | null | undefined;
|
|
74
|
+
targetHeight?: number | null | undefined;
|
|
75
|
+
newBackgroundColor?: string | null | undefined;
|
|
76
|
+
newBackgroundUrl?: string | null | undefined;
|
|
77
|
+
rotationAngle?: number | null | undefined;
|
|
78
|
+
borderSize?: number | null | undefined;
|
|
79
|
+
borderColor?: string | null | undefined;
|
|
80
|
+
} | null | undefined;
|
|
81
|
+
}>;
|
|
82
|
+
export type RepublishRequest = z.infer<typeof RepublishRequestSchema>;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.RepublishRequestSchema = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const PreferenceVisionPayload_1 = require("../../preferences/payloads/vision/PreferenceVisionPayload");
|
|
6
|
+
exports.RepublishRequestSchema = zod_1.z.object({
|
|
7
|
+
visionPayload: PreferenceVisionPayload_1.PreferenceVisionPayloadSchema.nullish(),
|
|
8
|
+
accountsId: zod_1.z.array(zod_1.z.string().uuid()).nullish()
|
|
9
|
+
});
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import {z} from "zod"
|
|
2
|
+
import {PreferenceVisionPayloadSchema} from "../../preferences/payloads/vision/PreferenceVisionPayload"
|
|
3
|
+
|
|
4
|
+
export const RepublishRequestSchema = z.object({
|
|
5
|
+
visionPayload: PreferenceVisionPayloadSchema.nullish(),
|
|
6
|
+
accountsId: z.array(z.string().uuid()).nullish()
|
|
7
|
+
})
|
|
8
|
+
export type RepublishRequest = z.infer<typeof RepublishRequestSchema>
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
export declare const CreateFavoritePayloadSchema: z.ZodObject<{
|
|
3
|
+
platformFavoriteId: z.ZodString;
|
|
4
|
+
conversationId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
5
|
+
updatedAt: z.ZodDate;
|
|
6
|
+
}, "strip", z.ZodTypeAny, {
|
|
7
|
+
updatedAt: Date;
|
|
8
|
+
platformFavoriteId: string;
|
|
9
|
+
conversationId?: string | null | undefined;
|
|
10
|
+
}, {
|
|
11
|
+
updatedAt: Date;
|
|
12
|
+
platformFavoriteId: string;
|
|
13
|
+
conversationId?: string | null | undefined;
|
|
14
|
+
}>;
|
|
15
|
+
export type CreateFavoritePayload = z.infer<typeof CreateFavoritePayloadSchema>;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.CreateFavoritePayloadSchema = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
exports.CreateFavoritePayloadSchema = zod_1.z.object({
|
|
6
|
+
platformFavoriteId: zod_1.z.string(),
|
|
7
|
+
conversationId: zod_1.z.string().uuid().nullish(),
|
|
8
|
+
updatedAt: zod_1.z.coerce.date()
|
|
9
|
+
});
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import {z} from "zod"
|
|
2
|
+
|
|
3
|
+
export const CreateFavoritePayloadSchema = z.object({
|
|
4
|
+
platformFavoriteId: z.string(),
|
|
5
|
+
conversationId: z.string().uuid().nullish(),
|
|
6
|
+
updatedAt: z.coerce.date()
|
|
7
|
+
})
|
|
8
|
+
export type CreateFavoritePayload = z.infer<typeof CreateFavoritePayloadSchema>
|