controlresell 2.2.12 → 2.3.2
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/catalogs/Catalog.d.ts +3 -6
- package/src/com/controlresell/models/catalogs/Catalog.js +2 -3
- package/src/com/controlresell/models/catalogs/Catalog.ts +2 -3
- package/src/com/controlresell/models/catalogs/CatalogRoot.d.ts +5 -10
- package/src/com/controlresell/models/items/CreatedItems.d.ts +139 -130
- package/src/com/controlresell/models/items/Item.d.ts +111 -104
- package/src/com/controlresell/models/items/ItemsWithFilters.d.ts +139 -130
- package/src/com/controlresell/models/items/UpdatedItem.d.ts +139 -130
- package/src/com/controlresell/models/items/history/CreateItemHistoryPayload.d.ts +71 -71
- package/src/com/controlresell/models/items/history/ItemHistory.d.ts +78 -78
- package/src/com/controlresell/models/items/history/ItemHistoryDecodedPayload.d.ts +156 -18
- package/src/com/controlresell/models/items/history/ItemHistoryDecodedPayload.js +32 -26
- package/src/com/controlresell/models/items/history/ItemHistoryDecodedPayload.ts +43 -26
- package/src/com/controlresell/models/items/platforms/ItemOnPlatform.d.ts +5 -0
- package/src/com/controlresell/models/items/platforms/ItemOnPlatformUpdateRequest.d.ts +5 -0
- package/src/com/controlresell/models/items/platforms/ItemOnPlatformsRequest.d.ts +2 -2
- package/src/com/controlresell/models/items/platforms/ItemOnPlatformsRequestWithItem.d.ts +4 -4
- package/src/com/controlresell/models/platforms/conversations/Conversation.d.ts +15 -0
- package/src/com/controlresell/models/platforms/conversations/ConversationOnPlatformUpdateRequest.d.ts +5 -0
- package/src/com/controlresell/models/platforms/conversations/UserConversations.d.ts +21 -0
- package/src/com/controlresell/models/platforms/conversations/messages/ConversationMessage.d.ts +6 -0
- package/src/com/controlresell/models/platforms/conversations/messages/ConversationMessage.js +4 -0
- package/src/com/controlresell/models/platforms/conversations/messages/ConversationMessage.ts +4 -0
- package/src/com/controlresell/models/platforms/conversations/messages/ConversationMessageRequest.d.ts +6 -0
- package/src/com/controlresell/models/platforms/conversations/messages/ConversationMessageRequest.js +4 -1
- package/src/com/controlresell/models/platforms/conversations/messages/ConversationMessageRequest.ts +4 -1
- package/src/com/controlresell/models/platforms/conversations/messages/ConversationMessageStatus.d.ts +3 -0
- package/src/com/controlresell/models/platforms/conversations/messages/ConversationMessageStatus.js +7 -0
- package/src/com/controlresell/models/platforms/conversations/messages/ConversationMessageStatus.ts +6 -0
- package/src/com/controlresell/models/platforms/conversations/messages/CreateConversationMessagePayload.d.ts +6 -0
- package/src/com/controlresell/models/platforms/conversations/messages/CreateConversationMessagePayload.js +4 -0
- package/src/com/controlresell/models/platforms/conversations/messages/CreateConversationMessagePayload.ts +4 -0
- package/src/com/controlresell/models/platforms/conversations/messages/PaginatedConversationMessages.d.ts +10 -0
- package/src/com/controlresell/models/platforms/conversations/messages/UpdateConversationMessagePayload.d.ts +6 -0
- package/src/com/controlresell/models/platforms/conversations/messages/UpdateConversationMessagePayload.js +4 -0
- package/src/com/controlresell/models/platforms/conversations/messages/UpdateConversationMessagePayload.ts +4 -0
- package/src/com/controlresell/models/platforms/favorites/Favorite.d.ts +26 -0
- package/src/com/controlresell/models/platforms/favorites/FavoriteOnPlatformUpdateRequest.d.ts +5 -0
- package/src/com/controlresell/models/platforms/orders/Order.d.ts +9 -0
- package/src/com/controlresell/models/platforms/orders/OrderOnPlatformUpdateRequest.d.ts +5 -0
- package/src/com/controlresell/models/platforms/orders/items/ItemInOrder.d.ts +7 -0
- package/src/com/controlresell/models/platforms/orders/items/OrderWithItems.d.ts +150 -130
- package/src/com/controlresell/models/platforms/transactions/Transaction.d.ts +9 -0
- package/src/com/controlresell/models/platforms/transactions/items/ItemInTransaction.d.ts +7 -0
- package/src/com/controlresell/models/platforms/transactions/items/TransactionWithItems.d.ts +150 -130
- package/src/com/controlresell/models/preferences/Preference.d.ts +356 -356
- package/src/com/controlresell/models/preferences/PreferenceFilter.d.ts +144 -130
- package/src/com/controlresell/models/preferences/PreferenceWithCase.d.ts +1121 -1121
- package/src/com/controlresell/models/preferences/PreferenceWithChildren.d.ts +815 -815
- package/src/com/controlresell/models/preferences/cases/CreatePreferenceCasePayload.d.ts +275 -275
- package/src/com/controlresell/models/preferences/cases/PartialPreferenceCasePayload.d.ts +276 -276
- package/src/com/controlresell/models/preferences/cases/PreferenceCase.d.ts +286 -286
- package/src/com/controlresell/models/preferences/payloads/actions/PreferenceActionPayload.d.ts +31 -31
- package/src/com/controlresell/models/preferences/payloads/actions/PreferenceActionPayloadDecodedPayload.d.ts +96 -5
- package/src/com/controlresell/models/preferences/payloads/actions/PreferenceActionPayloadDecodedPayload.js +20 -16
- package/src/com/controlresell/models/preferences/payloads/actions/PreferenceActionPayloadDecodedPayload.ts +27 -16
- package/src/com/controlresell/models/preferences/payloads/actions/PreferenceActionsPayload.d.ts +41 -41
- package/src/com/controlresell/models/preferences/queue/PreferenceNextActionPayload.d.ts +3476 -41
- package/src/com/controlresell/models/preferences/queue/PreferenceNextActionPayload.js +3 -1
- package/src/com/controlresell/models/preferences/queue/PreferenceNextActionPayload.ts +3 -1
- package/src/com/controlresell/models/preferences/variants/PartialPreferenceCaseVariantPayload.d.ts +229 -229
- package/src/com/controlresell/models/preferences/variants/PreferenceCaseVariant.d.ts +232 -232
- package/src/com/controlresell/models/preferences/variants/PreferenceCaseVariantDecodedPayload.d.ts +541 -83
- package/src/com/controlresell/models/preferences/variants/PreferenceCaseVariantDecodedPayload.js +33 -27
- package/src/com/controlresell/models/preferences/variants/PreferenceCaseVariantDecodedPayload.ts +44 -27
- package/src/com/controlresell/models/preferences/variants/PreferenceCaseVariantPayload.d.ts +229 -229
- package/src/com/controlresell/models/users/platforms/PlatformAuthRequest.d.ts +5 -0
- package/src/com/controlresell/models/users/platforms/PlatformJobUpdate.d.ts +5 -0
- package/src/com/controlresell/models/users/platforms/UpdateUserOnPlatformPayload.d.ts +3 -0
- package/src/com/controlresell/models/users/platforms/UpdateUserOnPlatformPayload.js +1 -0
- package/src/com/controlresell/models/users/platforms/UpdateUserOnPlatformPayload.ts +1 -0
- package/src/com/controlresell/models/users/platforms/UserOnPlatform.d.ts +3 -0
- package/src/com/controlresell/models/users/platforms/UserOnPlatform.js +1 -0
- package/src/com/controlresell/models/users/platforms/UserOnPlatform.ts +1 -0
- package/src/com/controlresell/models/users/ws/UserWsPayload.d.ts +1205 -0
- package/src/com/controlresell/models/users/ws/UserWsPayload.js +34 -0
- package/src/com/controlresell/models/users/ws/UserWsPayload.ts +43 -0
- package/src/index.d.ts +2 -0
- package/src/index.js +7 -3
- package/src/index.ts +2 -0
|
@@ -502,6 +502,7 @@ export declare const ConversationOnPlatformUpdateRequestSchema: z.ZodObject<{
|
|
|
502
502
|
accountId: z.ZodString;
|
|
503
503
|
platform: z.ZodEnum<["VINTED", "SHOPIFY"]>;
|
|
504
504
|
name: z.ZodString;
|
|
505
|
+
locale: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
505
506
|
status: z.ZodEnum<["CONNECTED", "DISCONNECTED", "ERROR"]>;
|
|
506
507
|
}, "strip", z.ZodTypeAny, {
|
|
507
508
|
status: "ERROR" | "CONNECTED" | "DISCONNECTED";
|
|
@@ -509,12 +510,14 @@ export declare const ConversationOnPlatformUpdateRequestSchema: z.ZodObject<{
|
|
|
509
510
|
name: string;
|
|
510
511
|
platform: "VINTED" | "SHOPIFY";
|
|
511
512
|
accountId: string;
|
|
513
|
+
locale?: string | null | undefined;
|
|
512
514
|
}, {
|
|
513
515
|
status: "ERROR" | "CONNECTED" | "DISCONNECTED";
|
|
514
516
|
userId: string | number;
|
|
515
517
|
name: string;
|
|
516
518
|
platform: "VINTED" | "SHOPIFY";
|
|
517
519
|
accountId: string;
|
|
520
|
+
locale?: string | null | undefined;
|
|
518
521
|
}>;
|
|
519
522
|
}, "strip", z.ZodTypeAny, {
|
|
520
523
|
account: {
|
|
@@ -523,6 +526,7 @@ export declare const ConversationOnPlatformUpdateRequestSchema: z.ZodObject<{
|
|
|
523
526
|
name: string;
|
|
524
527
|
platform: "VINTED" | "SHOPIFY";
|
|
525
528
|
accountId: string;
|
|
529
|
+
locale?: string | null | undefined;
|
|
526
530
|
};
|
|
527
531
|
conversation: {
|
|
528
532
|
id: string;
|
|
@@ -626,6 +630,7 @@ export declare const ConversationOnPlatformUpdateRequestSchema: z.ZodObject<{
|
|
|
626
630
|
name: string;
|
|
627
631
|
platform: "VINTED" | "SHOPIFY";
|
|
628
632
|
accountId: string;
|
|
633
|
+
locale?: string | null | undefined;
|
|
629
634
|
};
|
|
630
635
|
conversation: {
|
|
631
636
|
id: string;
|
|
@@ -12,6 +12,7 @@ export declare const UserConversationsSchema: z.ZodObject<{
|
|
|
12
12
|
accountId: z.ZodString;
|
|
13
13
|
platform: z.ZodEnum<["VINTED", "SHOPIFY"]>;
|
|
14
14
|
name: z.ZodString;
|
|
15
|
+
locale: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
15
16
|
status: z.ZodEnum<["CONNECTED", "DISCONNECTED", "ERROR"]>;
|
|
16
17
|
}, "strip", z.ZodTypeAny, {
|
|
17
18
|
status: "ERROR" | "CONNECTED" | "DISCONNECTED";
|
|
@@ -19,12 +20,14 @@ export declare const UserConversationsSchema: z.ZodObject<{
|
|
|
19
20
|
name: string;
|
|
20
21
|
platform: "VINTED" | "SHOPIFY";
|
|
21
22
|
accountId: string;
|
|
23
|
+
locale?: string | null | undefined;
|
|
22
24
|
}, {
|
|
23
25
|
status: "ERROR" | "CONNECTED" | "DISCONNECTED";
|
|
24
26
|
userId: string | number;
|
|
25
27
|
name: string;
|
|
26
28
|
platform: "VINTED" | "SHOPIFY";
|
|
27
29
|
accountId: string;
|
|
30
|
+
locale?: string | null | undefined;
|
|
28
31
|
}>>>;
|
|
29
32
|
lastMessage: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
30
33
|
id: z.ZodString;
|
|
@@ -32,6 +35,8 @@ export declare const UserConversationsSchema: z.ZodObject<{
|
|
|
32
35
|
conversationUserId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
33
36
|
platformMessageId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
34
37
|
type: z.ZodEnum<["MESSAGE", "STATUS_MESSAGE", "ACTION_MESSAGE", "OFFER_REQUEST_MESSAGE", "OFFER_MESSAGE"]>;
|
|
38
|
+
status: z.ZodEnum<["NEEDS_VALIDATION", "SENDING", "FAILED_TO_SEND", "SENT"]>;
|
|
39
|
+
associatedPreferenceType: z.ZodOptional<z.ZodNullable<z.ZodEnum<["NEGOTIATION", "REPUBLISH", "VISION", "TITLE", "DESCRIPTION", "LIFECYCLE", "FEES", "MESSAGES_QUESTIONS", "MESSAGES_STREAM", "MESSAGES_STREAM__ON_FAVORITE", "MESSAGES_STREAM__ON_FAVORITES", "MESSAGES_STREAM__ON_LOW_OFFER", "MESSAGES_STREAM__ON_CORRECT_OFFER", "MESSAGES_STREAM__ON_OFFER_REJECTED", "MESSAGES_STREAM__ON_NO_ANSWER", "MESSAGES_STREAM__ON_BUYER_PAID", "MESSAGES_STREAM__ON_ITEM_DELIVERED", "MESSAGES_STREAM__ON_ITEM_NO_LONGER_AVAILABLE"]>>>;
|
|
35
40
|
body: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
36
41
|
createdAt: z.ZodDate;
|
|
37
42
|
offer: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
@@ -120,6 +125,7 @@ export declare const UserConversationsSchema: z.ZodObject<{
|
|
|
120
125
|
}>, "many">>>;
|
|
121
126
|
}, "strip", z.ZodTypeAny, {
|
|
122
127
|
type: "MESSAGE" | "STATUS_MESSAGE" | "ACTION_MESSAGE" | "OFFER_REQUEST_MESSAGE" | "OFFER_MESSAGE";
|
|
128
|
+
status: "NEEDS_VALIDATION" | "SENDING" | "FAILED_TO_SEND" | "SENT";
|
|
123
129
|
id: string;
|
|
124
130
|
createdAt: Date;
|
|
125
131
|
conversationId: string;
|
|
@@ -147,6 +153,7 @@ export declare const UserConversationsSchema: z.ZodObject<{
|
|
|
147
153
|
}[] | null | undefined;
|
|
148
154
|
conversationUserId?: string | null | undefined;
|
|
149
155
|
platformMessageId?: string | null | undefined;
|
|
156
|
+
associatedPreferenceType?: "TITLE" | "DESCRIPTION" | "NEGOTIATION" | "REPUBLISH" | "VISION" | "LIFECYCLE" | "FEES" | "MESSAGES_QUESTIONS" | "MESSAGES_STREAM" | "MESSAGES_STREAM__ON_FAVORITE" | "MESSAGES_STREAM__ON_FAVORITES" | "MESSAGES_STREAM__ON_LOW_OFFER" | "MESSAGES_STREAM__ON_CORRECT_OFFER" | "MESSAGES_STREAM__ON_OFFER_REJECTED" | "MESSAGES_STREAM__ON_NO_ANSWER" | "MESSAGES_STREAM__ON_BUYER_PAID" | "MESSAGES_STREAM__ON_ITEM_DELIVERED" | "MESSAGES_STREAM__ON_ITEM_NO_LONGER_AVAILABLE" | null | undefined;
|
|
150
157
|
translation?: {
|
|
151
158
|
body: string;
|
|
152
159
|
messageId: string;
|
|
@@ -154,6 +161,7 @@ export declare const UserConversationsSchema: z.ZodObject<{
|
|
|
154
161
|
} | null | undefined;
|
|
155
162
|
}, {
|
|
156
163
|
type: "MESSAGE" | "STATUS_MESSAGE" | "ACTION_MESSAGE" | "OFFER_REQUEST_MESSAGE" | "OFFER_MESSAGE";
|
|
164
|
+
status: "NEEDS_VALIDATION" | "SENDING" | "FAILED_TO_SEND" | "SENT";
|
|
157
165
|
id: string;
|
|
158
166
|
createdAt: Date;
|
|
159
167
|
conversationId: string;
|
|
@@ -181,6 +189,7 @@ export declare const UserConversationsSchema: z.ZodObject<{
|
|
|
181
189
|
}[] | null | undefined;
|
|
182
190
|
conversationUserId?: string | null | undefined;
|
|
183
191
|
platformMessageId?: string | null | undefined;
|
|
192
|
+
associatedPreferenceType?: "TITLE" | "DESCRIPTION" | "NEGOTIATION" | "REPUBLISH" | "VISION" | "LIFECYCLE" | "FEES" | "MESSAGES_QUESTIONS" | "MESSAGES_STREAM" | "MESSAGES_STREAM__ON_FAVORITE" | "MESSAGES_STREAM__ON_FAVORITES" | "MESSAGES_STREAM__ON_LOW_OFFER" | "MESSAGES_STREAM__ON_CORRECT_OFFER" | "MESSAGES_STREAM__ON_OFFER_REJECTED" | "MESSAGES_STREAM__ON_NO_ANSWER" | "MESSAGES_STREAM__ON_BUYER_PAID" | "MESSAGES_STREAM__ON_ITEM_DELIVERED" | "MESSAGES_STREAM__ON_ITEM_NO_LONGER_AVAILABLE" | null | undefined;
|
|
184
193
|
translation?: {
|
|
185
194
|
body: string;
|
|
186
195
|
messageId: string;
|
|
@@ -259,6 +268,7 @@ export declare const UserConversationsSchema: z.ZodObject<{
|
|
|
259
268
|
name: string;
|
|
260
269
|
platform: "VINTED" | "SHOPIFY";
|
|
261
270
|
accountId: string;
|
|
271
|
+
locale?: string | null | undefined;
|
|
262
272
|
} | null | undefined;
|
|
263
273
|
users?: {
|
|
264
274
|
id: string;
|
|
@@ -279,6 +289,7 @@ export declare const UserConversationsSchema: z.ZodObject<{
|
|
|
279
289
|
}[] | null | undefined;
|
|
280
290
|
lastMessage?: {
|
|
281
291
|
type: "MESSAGE" | "STATUS_MESSAGE" | "ACTION_MESSAGE" | "OFFER_REQUEST_MESSAGE" | "OFFER_MESSAGE";
|
|
292
|
+
status: "NEEDS_VALIDATION" | "SENDING" | "FAILED_TO_SEND" | "SENT";
|
|
282
293
|
id: string;
|
|
283
294
|
createdAt: Date;
|
|
284
295
|
conversationId: string;
|
|
@@ -306,6 +317,7 @@ export declare const UserConversationsSchema: z.ZodObject<{
|
|
|
306
317
|
}[] | null | undefined;
|
|
307
318
|
conversationUserId?: string | null | undefined;
|
|
308
319
|
platformMessageId?: string | null | undefined;
|
|
320
|
+
associatedPreferenceType?: "TITLE" | "DESCRIPTION" | "NEGOTIATION" | "REPUBLISH" | "VISION" | "LIFECYCLE" | "FEES" | "MESSAGES_QUESTIONS" | "MESSAGES_STREAM" | "MESSAGES_STREAM__ON_FAVORITE" | "MESSAGES_STREAM__ON_FAVORITES" | "MESSAGES_STREAM__ON_LOW_OFFER" | "MESSAGES_STREAM__ON_CORRECT_OFFER" | "MESSAGES_STREAM__ON_OFFER_REJECTED" | "MESSAGES_STREAM__ON_NO_ANSWER" | "MESSAGES_STREAM__ON_BUYER_PAID" | "MESSAGES_STREAM__ON_ITEM_DELIVERED" | "MESSAGES_STREAM__ON_ITEM_NO_LONGER_AVAILABLE" | null | undefined;
|
|
309
321
|
translation?: {
|
|
310
322
|
body: string;
|
|
311
323
|
messageId: string;
|
|
@@ -323,6 +335,7 @@ export declare const UserConversationsSchema: z.ZodObject<{
|
|
|
323
335
|
name: string;
|
|
324
336
|
platform: "VINTED" | "SHOPIFY";
|
|
325
337
|
accountId: string;
|
|
338
|
+
locale?: string | null | undefined;
|
|
326
339
|
} | null | undefined;
|
|
327
340
|
users?: {
|
|
328
341
|
id: string;
|
|
@@ -343,6 +356,7 @@ export declare const UserConversationsSchema: z.ZodObject<{
|
|
|
343
356
|
}[] | null | undefined;
|
|
344
357
|
lastMessage?: {
|
|
345
358
|
type: "MESSAGE" | "STATUS_MESSAGE" | "ACTION_MESSAGE" | "OFFER_REQUEST_MESSAGE" | "OFFER_MESSAGE";
|
|
359
|
+
status: "NEEDS_VALIDATION" | "SENDING" | "FAILED_TO_SEND" | "SENT";
|
|
346
360
|
id: string;
|
|
347
361
|
createdAt: Date;
|
|
348
362
|
conversationId: string;
|
|
@@ -370,6 +384,7 @@ export declare const UserConversationsSchema: z.ZodObject<{
|
|
|
370
384
|
}[] | null | undefined;
|
|
371
385
|
conversationUserId?: string | null | undefined;
|
|
372
386
|
platformMessageId?: string | null | undefined;
|
|
387
|
+
associatedPreferenceType?: "TITLE" | "DESCRIPTION" | "NEGOTIATION" | "REPUBLISH" | "VISION" | "LIFECYCLE" | "FEES" | "MESSAGES_QUESTIONS" | "MESSAGES_STREAM" | "MESSAGES_STREAM__ON_FAVORITE" | "MESSAGES_STREAM__ON_FAVORITES" | "MESSAGES_STREAM__ON_LOW_OFFER" | "MESSAGES_STREAM__ON_CORRECT_OFFER" | "MESSAGES_STREAM__ON_OFFER_REJECTED" | "MESSAGES_STREAM__ON_NO_ANSWER" | "MESSAGES_STREAM__ON_BUYER_PAID" | "MESSAGES_STREAM__ON_ITEM_DELIVERED" | "MESSAGES_STREAM__ON_ITEM_NO_LONGER_AVAILABLE" | null | undefined;
|
|
373
388
|
translation?: {
|
|
374
389
|
body: string;
|
|
375
390
|
messageId: string;
|
|
@@ -392,6 +407,7 @@ export declare const UserConversationsSchema: z.ZodObject<{
|
|
|
392
407
|
name: string;
|
|
393
408
|
platform: "VINTED" | "SHOPIFY";
|
|
394
409
|
accountId: string;
|
|
410
|
+
locale?: string | null | undefined;
|
|
395
411
|
} | null | undefined;
|
|
396
412
|
users?: {
|
|
397
413
|
id: string;
|
|
@@ -412,6 +428,7 @@ export declare const UserConversationsSchema: z.ZodObject<{
|
|
|
412
428
|
}[] | null | undefined;
|
|
413
429
|
lastMessage?: {
|
|
414
430
|
type: "MESSAGE" | "STATUS_MESSAGE" | "ACTION_MESSAGE" | "OFFER_REQUEST_MESSAGE" | "OFFER_MESSAGE";
|
|
431
|
+
status: "NEEDS_VALIDATION" | "SENDING" | "FAILED_TO_SEND" | "SENT";
|
|
415
432
|
id: string;
|
|
416
433
|
createdAt: Date;
|
|
417
434
|
conversationId: string;
|
|
@@ -439,6 +456,7 @@ export declare const UserConversationsSchema: z.ZodObject<{
|
|
|
439
456
|
}[] | null | undefined;
|
|
440
457
|
conversationUserId?: string | null | undefined;
|
|
441
458
|
platformMessageId?: string | null | undefined;
|
|
459
|
+
associatedPreferenceType?: "TITLE" | "DESCRIPTION" | "NEGOTIATION" | "REPUBLISH" | "VISION" | "LIFECYCLE" | "FEES" | "MESSAGES_QUESTIONS" | "MESSAGES_STREAM" | "MESSAGES_STREAM__ON_FAVORITE" | "MESSAGES_STREAM__ON_FAVORITES" | "MESSAGES_STREAM__ON_LOW_OFFER" | "MESSAGES_STREAM__ON_CORRECT_OFFER" | "MESSAGES_STREAM__ON_OFFER_REJECTED" | "MESSAGES_STREAM__ON_NO_ANSWER" | "MESSAGES_STREAM__ON_BUYER_PAID" | "MESSAGES_STREAM__ON_ITEM_DELIVERED" | "MESSAGES_STREAM__ON_ITEM_NO_LONGER_AVAILABLE" | null | undefined;
|
|
442
460
|
translation?: {
|
|
443
461
|
body: string;
|
|
444
462
|
messageId: string;
|
|
@@ -462,6 +480,7 @@ export declare const UserConversationsSchema: z.ZodObject<{
|
|
|
462
480
|
name: string;
|
|
463
481
|
platform: "VINTED" | "SHOPIFY";
|
|
464
482
|
accountId: string;
|
|
483
|
+
locale?: string | null | undefined;
|
|
465
484
|
} | null | undefined;
|
|
466
485
|
users?: {
|
|
467
486
|
id: string;
|
|
@@ -482,6 +501,7 @@ export declare const UserConversationsSchema: z.ZodObject<{
|
|
|
482
501
|
}[] | null | undefined;
|
|
483
502
|
lastMessage?: {
|
|
484
503
|
type: "MESSAGE" | "STATUS_MESSAGE" | "ACTION_MESSAGE" | "OFFER_REQUEST_MESSAGE" | "OFFER_MESSAGE";
|
|
504
|
+
status: "NEEDS_VALIDATION" | "SENDING" | "FAILED_TO_SEND" | "SENT";
|
|
485
505
|
id: string;
|
|
486
506
|
createdAt: Date;
|
|
487
507
|
conversationId: string;
|
|
@@ -509,6 +529,7 @@ export declare const UserConversationsSchema: z.ZodObject<{
|
|
|
509
529
|
}[] | null | undefined;
|
|
510
530
|
conversationUserId?: string | null | undefined;
|
|
511
531
|
platformMessageId?: string | null | undefined;
|
|
532
|
+
associatedPreferenceType?: "TITLE" | "DESCRIPTION" | "NEGOTIATION" | "REPUBLISH" | "VISION" | "LIFECYCLE" | "FEES" | "MESSAGES_QUESTIONS" | "MESSAGES_STREAM" | "MESSAGES_STREAM__ON_FAVORITE" | "MESSAGES_STREAM__ON_FAVORITES" | "MESSAGES_STREAM__ON_LOW_OFFER" | "MESSAGES_STREAM__ON_CORRECT_OFFER" | "MESSAGES_STREAM__ON_OFFER_REJECTED" | "MESSAGES_STREAM__ON_NO_ANSWER" | "MESSAGES_STREAM__ON_BUYER_PAID" | "MESSAGES_STREAM__ON_ITEM_DELIVERED" | "MESSAGES_STREAM__ON_ITEM_NO_LONGER_AVAILABLE" | null | undefined;
|
|
512
533
|
translation?: {
|
|
513
534
|
body: string;
|
|
514
535
|
messageId: string;
|
package/src/com/controlresell/models/platforms/conversations/messages/ConversationMessage.d.ts
CHANGED
|
@@ -5,6 +5,8 @@ export declare const ConversationMessageSchema: z.ZodObject<{
|
|
|
5
5
|
conversationUserId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
6
6
|
platformMessageId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
7
7
|
type: z.ZodEnum<["MESSAGE", "STATUS_MESSAGE", "ACTION_MESSAGE", "OFFER_REQUEST_MESSAGE", "OFFER_MESSAGE"]>;
|
|
8
|
+
status: z.ZodEnum<["NEEDS_VALIDATION", "SENDING", "FAILED_TO_SEND", "SENT"]>;
|
|
9
|
+
associatedPreferenceType: z.ZodOptional<z.ZodNullable<z.ZodEnum<["NEGOTIATION", "REPUBLISH", "VISION", "TITLE", "DESCRIPTION", "LIFECYCLE", "FEES", "MESSAGES_QUESTIONS", "MESSAGES_STREAM", "MESSAGES_STREAM__ON_FAVORITE", "MESSAGES_STREAM__ON_FAVORITES", "MESSAGES_STREAM__ON_LOW_OFFER", "MESSAGES_STREAM__ON_CORRECT_OFFER", "MESSAGES_STREAM__ON_OFFER_REJECTED", "MESSAGES_STREAM__ON_NO_ANSWER", "MESSAGES_STREAM__ON_BUYER_PAID", "MESSAGES_STREAM__ON_ITEM_DELIVERED", "MESSAGES_STREAM__ON_ITEM_NO_LONGER_AVAILABLE"]>>>;
|
|
8
10
|
body: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
9
11
|
createdAt: z.ZodDate;
|
|
10
12
|
offer: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
@@ -93,6 +95,7 @@ export declare const ConversationMessageSchema: z.ZodObject<{
|
|
|
93
95
|
}>, "many">>>;
|
|
94
96
|
}, "strip", z.ZodTypeAny, {
|
|
95
97
|
type: "MESSAGE" | "STATUS_MESSAGE" | "ACTION_MESSAGE" | "OFFER_REQUEST_MESSAGE" | "OFFER_MESSAGE";
|
|
98
|
+
status: "NEEDS_VALIDATION" | "SENDING" | "FAILED_TO_SEND" | "SENT";
|
|
96
99
|
id: string;
|
|
97
100
|
createdAt: Date;
|
|
98
101
|
conversationId: string;
|
|
@@ -120,6 +123,7 @@ export declare const ConversationMessageSchema: z.ZodObject<{
|
|
|
120
123
|
}[] | null | undefined;
|
|
121
124
|
conversationUserId?: string | null | undefined;
|
|
122
125
|
platformMessageId?: string | null | undefined;
|
|
126
|
+
associatedPreferenceType?: "TITLE" | "DESCRIPTION" | "NEGOTIATION" | "REPUBLISH" | "VISION" | "LIFECYCLE" | "FEES" | "MESSAGES_QUESTIONS" | "MESSAGES_STREAM" | "MESSAGES_STREAM__ON_FAVORITE" | "MESSAGES_STREAM__ON_FAVORITES" | "MESSAGES_STREAM__ON_LOW_OFFER" | "MESSAGES_STREAM__ON_CORRECT_OFFER" | "MESSAGES_STREAM__ON_OFFER_REJECTED" | "MESSAGES_STREAM__ON_NO_ANSWER" | "MESSAGES_STREAM__ON_BUYER_PAID" | "MESSAGES_STREAM__ON_ITEM_DELIVERED" | "MESSAGES_STREAM__ON_ITEM_NO_LONGER_AVAILABLE" | null | undefined;
|
|
123
127
|
translation?: {
|
|
124
128
|
body: string;
|
|
125
129
|
messageId: string;
|
|
@@ -127,6 +131,7 @@ export declare const ConversationMessageSchema: z.ZodObject<{
|
|
|
127
131
|
} | null | undefined;
|
|
128
132
|
}, {
|
|
129
133
|
type: "MESSAGE" | "STATUS_MESSAGE" | "ACTION_MESSAGE" | "OFFER_REQUEST_MESSAGE" | "OFFER_MESSAGE";
|
|
134
|
+
status: "NEEDS_VALIDATION" | "SENDING" | "FAILED_TO_SEND" | "SENT";
|
|
130
135
|
id: string;
|
|
131
136
|
createdAt: Date;
|
|
132
137
|
conversationId: string;
|
|
@@ -154,6 +159,7 @@ export declare const ConversationMessageSchema: z.ZodObject<{
|
|
|
154
159
|
}[] | null | undefined;
|
|
155
160
|
conversationUserId?: string | null | undefined;
|
|
156
161
|
platformMessageId?: string | null | undefined;
|
|
162
|
+
associatedPreferenceType?: "TITLE" | "DESCRIPTION" | "NEGOTIATION" | "REPUBLISH" | "VISION" | "LIFECYCLE" | "FEES" | "MESSAGES_QUESTIONS" | "MESSAGES_STREAM" | "MESSAGES_STREAM__ON_FAVORITE" | "MESSAGES_STREAM__ON_FAVORITES" | "MESSAGES_STREAM__ON_LOW_OFFER" | "MESSAGES_STREAM__ON_CORRECT_OFFER" | "MESSAGES_STREAM__ON_OFFER_REJECTED" | "MESSAGES_STREAM__ON_NO_ANSWER" | "MESSAGES_STREAM__ON_BUYER_PAID" | "MESSAGES_STREAM__ON_ITEM_DELIVERED" | "MESSAGES_STREAM__ON_ITEM_NO_LONGER_AVAILABLE" | null | undefined;
|
|
157
163
|
translation?: {
|
|
158
164
|
body: string;
|
|
159
165
|
messageId: string;
|
package/src/com/controlresell/models/platforms/conversations/messages/ConversationMessage.js
CHANGED
|
@@ -3,6 +3,8 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.ConversationMessageSchema = void 0;
|
|
4
4
|
const zod_1 = require("zod");
|
|
5
5
|
const controlresell_connector_1 = require("controlresell-connector");
|
|
6
|
+
const ConversationMessageStatus_1 = require("./ConversationMessageStatus");
|
|
7
|
+
const PreferenceType_1 = require("../../../preferences/PreferenceType");
|
|
6
8
|
const ConversationMessageOffer_1 = require("./offers/ConversationMessageOffer");
|
|
7
9
|
const TranslatedMessage_1 = require("./translations/TranslatedMessage");
|
|
8
10
|
const ConversationMessageFile_1 = require("./files/ConversationMessageFile");
|
|
@@ -12,6 +14,8 @@ exports.ConversationMessageSchema = zod_1.z.object({
|
|
|
12
14
|
conversationUserId: zod_1.z.string().uuid().nullish(),
|
|
13
15
|
platformMessageId: zod_1.z.string().nullish(),
|
|
14
16
|
type: controlresell_connector_1.JobConversationMessageTypeSchema,
|
|
17
|
+
status: ConversationMessageStatus_1.ConversationMessageStatusSchema,
|
|
18
|
+
associatedPreferenceType: PreferenceType_1.PreferenceTypeSchema.nullish(),
|
|
15
19
|
body: zod_1.z.string().nullish(),
|
|
16
20
|
createdAt: zod_1.z.coerce.date(),
|
|
17
21
|
offer: ConversationMessageOffer_1.ConversationMessageOfferSchema.nullish(),
|
package/src/com/controlresell/models/platforms/conversations/messages/ConversationMessage.ts
CHANGED
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import {z} from "zod"
|
|
2
2
|
import {JobConversationMessageTypeSchema} from "controlresell-connector"
|
|
3
|
+
import {ConversationMessageStatusSchema} from "./ConversationMessageStatus"
|
|
4
|
+
import {PreferenceTypeSchema} from "../../../preferences/PreferenceType"
|
|
3
5
|
import {ConversationMessageOfferSchema} from "./offers/ConversationMessageOffer"
|
|
4
6
|
import {TranslatedMessageSchema} from "./translations/TranslatedMessage"
|
|
5
7
|
import {ConversationMessageFileSchema} from "./files/ConversationMessageFile"
|
|
@@ -10,6 +12,8 @@ export const ConversationMessageSchema = z.object({
|
|
|
10
12
|
conversationUserId: z.string().uuid().nullish(),
|
|
11
13
|
platformMessageId: z.string().nullish(),
|
|
12
14
|
type: JobConversationMessageTypeSchema,
|
|
15
|
+
status: ConversationMessageStatusSchema,
|
|
16
|
+
associatedPreferenceType: PreferenceTypeSchema.nullish(),
|
|
13
17
|
body: z.string().nullish(),
|
|
14
18
|
createdAt: z.coerce.date(),
|
|
15
19
|
offer: ConversationMessageOfferSchema.nullish(),
|
|
@@ -2,11 +2,17 @@ import { z } from "zod";
|
|
|
2
2
|
export declare const ConversationMessageRequestSchema: z.ZodObject<{
|
|
3
3
|
message: z.ZodString;
|
|
4
4
|
filesId: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodString, "many">>>;
|
|
5
|
+
isTestMode: z.ZodBoolean;
|
|
6
|
+
associatedPreferenceType: z.ZodOptional<z.ZodNullable<z.ZodEnum<["NEGOTIATION", "REPUBLISH", "VISION", "TITLE", "DESCRIPTION", "LIFECYCLE", "FEES", "MESSAGES_QUESTIONS", "MESSAGES_STREAM", "MESSAGES_STREAM__ON_FAVORITE", "MESSAGES_STREAM__ON_FAVORITES", "MESSAGES_STREAM__ON_LOW_OFFER", "MESSAGES_STREAM__ON_CORRECT_OFFER", "MESSAGES_STREAM__ON_OFFER_REJECTED", "MESSAGES_STREAM__ON_NO_ANSWER", "MESSAGES_STREAM__ON_BUYER_PAID", "MESSAGES_STREAM__ON_ITEM_DELIVERED", "MESSAGES_STREAM__ON_ITEM_NO_LONGER_AVAILABLE"]>>>;
|
|
5
7
|
}, "strip", z.ZodTypeAny, {
|
|
6
8
|
message: string;
|
|
9
|
+
isTestMode: boolean;
|
|
7
10
|
filesId?: string[] | null | undefined;
|
|
11
|
+
associatedPreferenceType?: "TITLE" | "DESCRIPTION" | "NEGOTIATION" | "REPUBLISH" | "VISION" | "LIFECYCLE" | "FEES" | "MESSAGES_QUESTIONS" | "MESSAGES_STREAM" | "MESSAGES_STREAM__ON_FAVORITE" | "MESSAGES_STREAM__ON_FAVORITES" | "MESSAGES_STREAM__ON_LOW_OFFER" | "MESSAGES_STREAM__ON_CORRECT_OFFER" | "MESSAGES_STREAM__ON_OFFER_REJECTED" | "MESSAGES_STREAM__ON_NO_ANSWER" | "MESSAGES_STREAM__ON_BUYER_PAID" | "MESSAGES_STREAM__ON_ITEM_DELIVERED" | "MESSAGES_STREAM__ON_ITEM_NO_LONGER_AVAILABLE" | null | undefined;
|
|
8
12
|
}, {
|
|
9
13
|
message: string;
|
|
14
|
+
isTestMode: boolean;
|
|
10
15
|
filesId?: string[] | null | undefined;
|
|
16
|
+
associatedPreferenceType?: "TITLE" | "DESCRIPTION" | "NEGOTIATION" | "REPUBLISH" | "VISION" | "LIFECYCLE" | "FEES" | "MESSAGES_QUESTIONS" | "MESSAGES_STREAM" | "MESSAGES_STREAM__ON_FAVORITE" | "MESSAGES_STREAM__ON_FAVORITES" | "MESSAGES_STREAM__ON_LOW_OFFER" | "MESSAGES_STREAM__ON_CORRECT_OFFER" | "MESSAGES_STREAM__ON_OFFER_REJECTED" | "MESSAGES_STREAM__ON_NO_ANSWER" | "MESSAGES_STREAM__ON_BUYER_PAID" | "MESSAGES_STREAM__ON_ITEM_DELIVERED" | "MESSAGES_STREAM__ON_ITEM_NO_LONGER_AVAILABLE" | null | undefined;
|
|
11
17
|
}>;
|
|
12
18
|
export type ConversationMessageRequest = z.infer<typeof ConversationMessageRequestSchema>;
|
package/src/com/controlresell/models/platforms/conversations/messages/ConversationMessageRequest.js
CHANGED
|
@@ -2,7 +2,10 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.ConversationMessageRequestSchema = void 0;
|
|
4
4
|
const zod_1 = require("zod");
|
|
5
|
+
const PreferenceType_1 = require("../../../preferences/PreferenceType");
|
|
5
6
|
exports.ConversationMessageRequestSchema = zod_1.z.object({
|
|
6
7
|
message: zod_1.z.string(),
|
|
7
|
-
filesId: zod_1.z.array(zod_1.z.string().uuid()).nullish()
|
|
8
|
+
filesId: zod_1.z.array(zod_1.z.string().uuid()).nullish(),
|
|
9
|
+
isTestMode: zod_1.z.boolean(),
|
|
10
|
+
associatedPreferenceType: PreferenceType_1.PreferenceTypeSchema.nullish()
|
|
8
11
|
});
|
package/src/com/controlresell/models/platforms/conversations/messages/ConversationMessageRequest.ts
CHANGED
|
@@ -1,7 +1,10 @@
|
|
|
1
1
|
import {z} from "zod"
|
|
2
|
+
import {PreferenceTypeSchema} from "../../../preferences/PreferenceType"
|
|
2
3
|
|
|
3
4
|
export const ConversationMessageRequestSchema = z.object({
|
|
4
5
|
message: z.string(),
|
|
5
|
-
filesId: z.array(z.string().uuid()).nullish()
|
|
6
|
+
filesId: z.array(z.string().uuid()).nullish(),
|
|
7
|
+
isTestMode: z.boolean(),
|
|
8
|
+
associatedPreferenceType: PreferenceTypeSchema.nullish()
|
|
6
9
|
})
|
|
7
10
|
export type ConversationMessageRequest = z.infer<typeof ConversationMessageRequestSchema>
|
package/src/com/controlresell/models/platforms/conversations/messages/ConversationMessageStatus.js
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ConversationMessageStatusSchema = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
exports.ConversationMessageStatusSchema = zod_1.z.enum([
|
|
6
|
+
"NEEDS_VALIDATION", "SENDING", "FAILED_TO_SEND", "SENT"
|
|
7
|
+
]);
|
|
@@ -3,19 +3,25 @@ export declare const CreateConversationMessagePayloadSchema: z.ZodObject<{
|
|
|
3
3
|
conversationUserId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
4
4
|
platformMessageId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
5
5
|
type: z.ZodEnum<["MESSAGE", "STATUS_MESSAGE", "ACTION_MESSAGE", "OFFER_REQUEST_MESSAGE", "OFFER_MESSAGE"]>;
|
|
6
|
+
status: z.ZodEnum<["NEEDS_VALIDATION", "SENDING", "FAILED_TO_SEND", "SENT"]>;
|
|
7
|
+
associatedPreferenceType: z.ZodOptional<z.ZodNullable<z.ZodEnum<["NEGOTIATION", "REPUBLISH", "VISION", "TITLE", "DESCRIPTION", "LIFECYCLE", "FEES", "MESSAGES_QUESTIONS", "MESSAGES_STREAM", "MESSAGES_STREAM__ON_FAVORITE", "MESSAGES_STREAM__ON_FAVORITES", "MESSAGES_STREAM__ON_LOW_OFFER", "MESSAGES_STREAM__ON_CORRECT_OFFER", "MESSAGES_STREAM__ON_OFFER_REJECTED", "MESSAGES_STREAM__ON_NO_ANSWER", "MESSAGES_STREAM__ON_BUYER_PAID", "MESSAGES_STREAM__ON_ITEM_DELIVERED", "MESSAGES_STREAM__ON_ITEM_NO_LONGER_AVAILABLE"]>>>;
|
|
6
8
|
body: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
7
9
|
createdAt: z.ZodOptional<z.ZodNullable<z.ZodDate>>;
|
|
8
10
|
}, "strip", z.ZodTypeAny, {
|
|
9
11
|
type: "MESSAGE" | "STATUS_MESSAGE" | "ACTION_MESSAGE" | "OFFER_REQUEST_MESSAGE" | "OFFER_MESSAGE";
|
|
12
|
+
status: "NEEDS_VALIDATION" | "SENDING" | "FAILED_TO_SEND" | "SENT";
|
|
10
13
|
createdAt?: Date | null | undefined;
|
|
11
14
|
body?: string | null | undefined;
|
|
12
15
|
conversationUserId?: string | null | undefined;
|
|
13
16
|
platformMessageId?: string | null | undefined;
|
|
17
|
+
associatedPreferenceType?: "TITLE" | "DESCRIPTION" | "NEGOTIATION" | "REPUBLISH" | "VISION" | "LIFECYCLE" | "FEES" | "MESSAGES_QUESTIONS" | "MESSAGES_STREAM" | "MESSAGES_STREAM__ON_FAVORITE" | "MESSAGES_STREAM__ON_FAVORITES" | "MESSAGES_STREAM__ON_LOW_OFFER" | "MESSAGES_STREAM__ON_CORRECT_OFFER" | "MESSAGES_STREAM__ON_OFFER_REJECTED" | "MESSAGES_STREAM__ON_NO_ANSWER" | "MESSAGES_STREAM__ON_BUYER_PAID" | "MESSAGES_STREAM__ON_ITEM_DELIVERED" | "MESSAGES_STREAM__ON_ITEM_NO_LONGER_AVAILABLE" | null | undefined;
|
|
14
18
|
}, {
|
|
15
19
|
type: "MESSAGE" | "STATUS_MESSAGE" | "ACTION_MESSAGE" | "OFFER_REQUEST_MESSAGE" | "OFFER_MESSAGE";
|
|
20
|
+
status: "NEEDS_VALIDATION" | "SENDING" | "FAILED_TO_SEND" | "SENT";
|
|
16
21
|
createdAt?: Date | null | undefined;
|
|
17
22
|
body?: string | null | undefined;
|
|
18
23
|
conversationUserId?: string | null | undefined;
|
|
19
24
|
platformMessageId?: string | null | undefined;
|
|
25
|
+
associatedPreferenceType?: "TITLE" | "DESCRIPTION" | "NEGOTIATION" | "REPUBLISH" | "VISION" | "LIFECYCLE" | "FEES" | "MESSAGES_QUESTIONS" | "MESSAGES_STREAM" | "MESSAGES_STREAM__ON_FAVORITE" | "MESSAGES_STREAM__ON_FAVORITES" | "MESSAGES_STREAM__ON_LOW_OFFER" | "MESSAGES_STREAM__ON_CORRECT_OFFER" | "MESSAGES_STREAM__ON_OFFER_REJECTED" | "MESSAGES_STREAM__ON_NO_ANSWER" | "MESSAGES_STREAM__ON_BUYER_PAID" | "MESSAGES_STREAM__ON_ITEM_DELIVERED" | "MESSAGES_STREAM__ON_ITEM_NO_LONGER_AVAILABLE" | null | undefined;
|
|
20
26
|
}>;
|
|
21
27
|
export type CreateConversationMessagePayload = z.infer<typeof CreateConversationMessagePayloadSchema>;
|
|
@@ -3,10 +3,14 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.CreateConversationMessagePayloadSchema = void 0;
|
|
4
4
|
const zod_1 = require("zod");
|
|
5
5
|
const controlresell_connector_1 = require("controlresell-connector");
|
|
6
|
+
const ConversationMessageStatus_1 = require("./ConversationMessageStatus");
|
|
7
|
+
const PreferenceType_1 = require("../../../preferences/PreferenceType");
|
|
6
8
|
exports.CreateConversationMessagePayloadSchema = zod_1.z.object({
|
|
7
9
|
conversationUserId: zod_1.z.string().uuid().nullish(),
|
|
8
10
|
platformMessageId: zod_1.z.string().nullish(),
|
|
9
11
|
type: controlresell_connector_1.JobConversationMessageTypeSchema,
|
|
12
|
+
status: ConversationMessageStatus_1.ConversationMessageStatusSchema,
|
|
13
|
+
associatedPreferenceType: PreferenceType_1.PreferenceTypeSchema.nullish(),
|
|
10
14
|
body: zod_1.z.string().nullish(),
|
|
11
15
|
createdAt: zod_1.z.coerce.date().nullish()
|
|
12
16
|
});
|
|
@@ -1,10 +1,14 @@
|
|
|
1
1
|
import {z} from "zod"
|
|
2
2
|
import {JobConversationMessageTypeSchema} from "controlresell-connector"
|
|
3
|
+
import {ConversationMessageStatusSchema} from "./ConversationMessageStatus"
|
|
4
|
+
import {PreferenceTypeSchema} from "../../../preferences/PreferenceType"
|
|
3
5
|
|
|
4
6
|
export const CreateConversationMessagePayloadSchema = z.object({
|
|
5
7
|
conversationUserId: z.string().uuid().nullish(),
|
|
6
8
|
platformMessageId: z.string().nullish(),
|
|
7
9
|
type: JobConversationMessageTypeSchema,
|
|
10
|
+
status: ConversationMessageStatusSchema,
|
|
11
|
+
associatedPreferenceType: PreferenceTypeSchema.nullish(),
|
|
8
12
|
body: z.string().nullish(),
|
|
9
13
|
createdAt: z.coerce.date().nullish()
|
|
10
14
|
})
|
|
@@ -7,6 +7,8 @@ export declare const PaginatedConversationMessagesSchema: z.ZodObject<{
|
|
|
7
7
|
conversationUserId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
8
8
|
platformMessageId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
9
9
|
type: z.ZodEnum<["MESSAGE", "STATUS_MESSAGE", "ACTION_MESSAGE", "OFFER_REQUEST_MESSAGE", "OFFER_MESSAGE"]>;
|
|
10
|
+
status: z.ZodEnum<["NEEDS_VALIDATION", "SENDING", "FAILED_TO_SEND", "SENT"]>;
|
|
11
|
+
associatedPreferenceType: z.ZodOptional<z.ZodNullable<z.ZodEnum<["NEGOTIATION", "REPUBLISH", "VISION", "TITLE", "DESCRIPTION", "LIFECYCLE", "FEES", "MESSAGES_QUESTIONS", "MESSAGES_STREAM", "MESSAGES_STREAM__ON_FAVORITE", "MESSAGES_STREAM__ON_FAVORITES", "MESSAGES_STREAM__ON_LOW_OFFER", "MESSAGES_STREAM__ON_CORRECT_OFFER", "MESSAGES_STREAM__ON_OFFER_REJECTED", "MESSAGES_STREAM__ON_NO_ANSWER", "MESSAGES_STREAM__ON_BUYER_PAID", "MESSAGES_STREAM__ON_ITEM_DELIVERED", "MESSAGES_STREAM__ON_ITEM_NO_LONGER_AVAILABLE"]>>>;
|
|
10
12
|
body: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
11
13
|
createdAt: z.ZodDate;
|
|
12
14
|
offer: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
@@ -95,6 +97,7 @@ export declare const PaginatedConversationMessagesSchema: z.ZodObject<{
|
|
|
95
97
|
}>, "many">>>;
|
|
96
98
|
}, "strip", z.ZodTypeAny, {
|
|
97
99
|
type: "MESSAGE" | "STATUS_MESSAGE" | "ACTION_MESSAGE" | "OFFER_REQUEST_MESSAGE" | "OFFER_MESSAGE";
|
|
100
|
+
status: "NEEDS_VALIDATION" | "SENDING" | "FAILED_TO_SEND" | "SENT";
|
|
98
101
|
id: string;
|
|
99
102
|
createdAt: Date;
|
|
100
103
|
conversationId: string;
|
|
@@ -122,6 +125,7 @@ export declare const PaginatedConversationMessagesSchema: z.ZodObject<{
|
|
|
122
125
|
}[] | null | undefined;
|
|
123
126
|
conversationUserId?: string | null | undefined;
|
|
124
127
|
platformMessageId?: string | null | undefined;
|
|
128
|
+
associatedPreferenceType?: "TITLE" | "DESCRIPTION" | "NEGOTIATION" | "REPUBLISH" | "VISION" | "LIFECYCLE" | "FEES" | "MESSAGES_QUESTIONS" | "MESSAGES_STREAM" | "MESSAGES_STREAM__ON_FAVORITE" | "MESSAGES_STREAM__ON_FAVORITES" | "MESSAGES_STREAM__ON_LOW_OFFER" | "MESSAGES_STREAM__ON_CORRECT_OFFER" | "MESSAGES_STREAM__ON_OFFER_REJECTED" | "MESSAGES_STREAM__ON_NO_ANSWER" | "MESSAGES_STREAM__ON_BUYER_PAID" | "MESSAGES_STREAM__ON_ITEM_DELIVERED" | "MESSAGES_STREAM__ON_ITEM_NO_LONGER_AVAILABLE" | null | undefined;
|
|
125
129
|
translation?: {
|
|
126
130
|
body: string;
|
|
127
131
|
messageId: string;
|
|
@@ -129,6 +133,7 @@ export declare const PaginatedConversationMessagesSchema: z.ZodObject<{
|
|
|
129
133
|
} | null | undefined;
|
|
130
134
|
}, {
|
|
131
135
|
type: "MESSAGE" | "STATUS_MESSAGE" | "ACTION_MESSAGE" | "OFFER_REQUEST_MESSAGE" | "OFFER_MESSAGE";
|
|
136
|
+
status: "NEEDS_VALIDATION" | "SENDING" | "FAILED_TO_SEND" | "SENT";
|
|
132
137
|
id: string;
|
|
133
138
|
createdAt: Date;
|
|
134
139
|
conversationId: string;
|
|
@@ -156,6 +161,7 @@ export declare const PaginatedConversationMessagesSchema: z.ZodObject<{
|
|
|
156
161
|
}[] | null | undefined;
|
|
157
162
|
conversationUserId?: string | null | undefined;
|
|
158
163
|
platformMessageId?: string | null | undefined;
|
|
164
|
+
associatedPreferenceType?: "TITLE" | "DESCRIPTION" | "NEGOTIATION" | "REPUBLISH" | "VISION" | "LIFECYCLE" | "FEES" | "MESSAGES_QUESTIONS" | "MESSAGES_STREAM" | "MESSAGES_STREAM__ON_FAVORITE" | "MESSAGES_STREAM__ON_FAVORITES" | "MESSAGES_STREAM__ON_LOW_OFFER" | "MESSAGES_STREAM__ON_CORRECT_OFFER" | "MESSAGES_STREAM__ON_OFFER_REJECTED" | "MESSAGES_STREAM__ON_NO_ANSWER" | "MESSAGES_STREAM__ON_BUYER_PAID" | "MESSAGES_STREAM__ON_ITEM_DELIVERED" | "MESSAGES_STREAM__ON_ITEM_NO_LONGER_AVAILABLE" | null | undefined;
|
|
159
165
|
translation?: {
|
|
160
166
|
body: string;
|
|
161
167
|
messageId: string;
|
|
@@ -168,6 +174,7 @@ export declare const PaginatedConversationMessagesSchema: z.ZodObject<{
|
|
|
168
174
|
count: number;
|
|
169
175
|
rows: {
|
|
170
176
|
type: "MESSAGE" | "STATUS_MESSAGE" | "ACTION_MESSAGE" | "OFFER_REQUEST_MESSAGE" | "OFFER_MESSAGE";
|
|
177
|
+
status: "NEEDS_VALIDATION" | "SENDING" | "FAILED_TO_SEND" | "SENT";
|
|
171
178
|
id: string;
|
|
172
179
|
createdAt: Date;
|
|
173
180
|
conversationId: string;
|
|
@@ -195,6 +202,7 @@ export declare const PaginatedConversationMessagesSchema: z.ZodObject<{
|
|
|
195
202
|
}[] | null | undefined;
|
|
196
203
|
conversationUserId?: string | null | undefined;
|
|
197
204
|
platformMessageId?: string | null | undefined;
|
|
205
|
+
associatedPreferenceType?: "TITLE" | "DESCRIPTION" | "NEGOTIATION" | "REPUBLISH" | "VISION" | "LIFECYCLE" | "FEES" | "MESSAGES_QUESTIONS" | "MESSAGES_STREAM" | "MESSAGES_STREAM__ON_FAVORITE" | "MESSAGES_STREAM__ON_FAVORITES" | "MESSAGES_STREAM__ON_LOW_OFFER" | "MESSAGES_STREAM__ON_CORRECT_OFFER" | "MESSAGES_STREAM__ON_OFFER_REJECTED" | "MESSAGES_STREAM__ON_NO_ANSWER" | "MESSAGES_STREAM__ON_BUYER_PAID" | "MESSAGES_STREAM__ON_ITEM_DELIVERED" | "MESSAGES_STREAM__ON_ITEM_NO_LONGER_AVAILABLE" | null | undefined;
|
|
198
206
|
translation?: {
|
|
199
207
|
body: string;
|
|
200
208
|
messageId: string;
|
|
@@ -207,6 +215,7 @@ export declare const PaginatedConversationMessagesSchema: z.ZodObject<{
|
|
|
207
215
|
count: number;
|
|
208
216
|
rows: {
|
|
209
217
|
type: "MESSAGE" | "STATUS_MESSAGE" | "ACTION_MESSAGE" | "OFFER_REQUEST_MESSAGE" | "OFFER_MESSAGE";
|
|
218
|
+
status: "NEEDS_VALIDATION" | "SENDING" | "FAILED_TO_SEND" | "SENT";
|
|
210
219
|
id: string;
|
|
211
220
|
createdAt: Date;
|
|
212
221
|
conversationId: string;
|
|
@@ -234,6 +243,7 @@ export declare const PaginatedConversationMessagesSchema: z.ZodObject<{
|
|
|
234
243
|
}[] | null | undefined;
|
|
235
244
|
conversationUserId?: string | null | undefined;
|
|
236
245
|
platformMessageId?: string | null | undefined;
|
|
246
|
+
associatedPreferenceType?: "TITLE" | "DESCRIPTION" | "NEGOTIATION" | "REPUBLISH" | "VISION" | "LIFECYCLE" | "FEES" | "MESSAGES_QUESTIONS" | "MESSAGES_STREAM" | "MESSAGES_STREAM__ON_FAVORITE" | "MESSAGES_STREAM__ON_FAVORITES" | "MESSAGES_STREAM__ON_LOW_OFFER" | "MESSAGES_STREAM__ON_CORRECT_OFFER" | "MESSAGES_STREAM__ON_OFFER_REJECTED" | "MESSAGES_STREAM__ON_NO_ANSWER" | "MESSAGES_STREAM__ON_BUYER_PAID" | "MESSAGES_STREAM__ON_ITEM_DELIVERED" | "MESSAGES_STREAM__ON_ITEM_NO_LONGER_AVAILABLE" | null | undefined;
|
|
237
247
|
translation?: {
|
|
238
248
|
body: string;
|
|
239
249
|
messageId: string;
|
|
@@ -1,12 +1,18 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
2
|
export declare const UpdateConversationMessagePayloadSchema: z.ZodObject<{
|
|
3
3
|
platformMessageId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
4
|
+
status: z.ZodOptional<z.ZodNullable<z.ZodEnum<["NEEDS_VALIDATION", "SENDING", "FAILED_TO_SEND", "SENT"]>>>;
|
|
5
|
+
associatedPreferenceType: z.ZodOptional<z.ZodNullable<z.ZodEnum<["NEGOTIATION", "REPUBLISH", "VISION", "TITLE", "DESCRIPTION", "LIFECYCLE", "FEES", "MESSAGES_QUESTIONS", "MESSAGES_STREAM", "MESSAGES_STREAM__ON_FAVORITE", "MESSAGES_STREAM__ON_FAVORITES", "MESSAGES_STREAM__ON_LOW_OFFER", "MESSAGES_STREAM__ON_CORRECT_OFFER", "MESSAGES_STREAM__ON_OFFER_REJECTED", "MESSAGES_STREAM__ON_NO_ANSWER", "MESSAGES_STREAM__ON_BUYER_PAID", "MESSAGES_STREAM__ON_ITEM_DELIVERED", "MESSAGES_STREAM__ON_ITEM_NO_LONGER_AVAILABLE"]>>>;
|
|
4
6
|
body: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
5
7
|
}, "strip", z.ZodTypeAny, {
|
|
8
|
+
status?: "NEEDS_VALIDATION" | "SENDING" | "FAILED_TO_SEND" | "SENT" | null | undefined;
|
|
6
9
|
body?: string | null | undefined;
|
|
7
10
|
platformMessageId?: string | null | undefined;
|
|
11
|
+
associatedPreferenceType?: "TITLE" | "DESCRIPTION" | "NEGOTIATION" | "REPUBLISH" | "VISION" | "LIFECYCLE" | "FEES" | "MESSAGES_QUESTIONS" | "MESSAGES_STREAM" | "MESSAGES_STREAM__ON_FAVORITE" | "MESSAGES_STREAM__ON_FAVORITES" | "MESSAGES_STREAM__ON_LOW_OFFER" | "MESSAGES_STREAM__ON_CORRECT_OFFER" | "MESSAGES_STREAM__ON_OFFER_REJECTED" | "MESSAGES_STREAM__ON_NO_ANSWER" | "MESSAGES_STREAM__ON_BUYER_PAID" | "MESSAGES_STREAM__ON_ITEM_DELIVERED" | "MESSAGES_STREAM__ON_ITEM_NO_LONGER_AVAILABLE" | null | undefined;
|
|
8
12
|
}, {
|
|
13
|
+
status?: "NEEDS_VALIDATION" | "SENDING" | "FAILED_TO_SEND" | "SENT" | null | undefined;
|
|
9
14
|
body?: string | null | undefined;
|
|
10
15
|
platformMessageId?: string | null | undefined;
|
|
16
|
+
associatedPreferenceType?: "TITLE" | "DESCRIPTION" | "NEGOTIATION" | "REPUBLISH" | "VISION" | "LIFECYCLE" | "FEES" | "MESSAGES_QUESTIONS" | "MESSAGES_STREAM" | "MESSAGES_STREAM__ON_FAVORITE" | "MESSAGES_STREAM__ON_FAVORITES" | "MESSAGES_STREAM__ON_LOW_OFFER" | "MESSAGES_STREAM__ON_CORRECT_OFFER" | "MESSAGES_STREAM__ON_OFFER_REJECTED" | "MESSAGES_STREAM__ON_NO_ANSWER" | "MESSAGES_STREAM__ON_BUYER_PAID" | "MESSAGES_STREAM__ON_ITEM_DELIVERED" | "MESSAGES_STREAM__ON_ITEM_NO_LONGER_AVAILABLE" | null | undefined;
|
|
11
17
|
}>;
|
|
12
18
|
export type UpdateConversationMessagePayload = z.infer<typeof UpdateConversationMessagePayloadSchema>;
|
|
@@ -2,7 +2,11 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.UpdateConversationMessagePayloadSchema = void 0;
|
|
4
4
|
const zod_1 = require("zod");
|
|
5
|
+
const ConversationMessageStatus_1 = require("./ConversationMessageStatus");
|
|
6
|
+
const PreferenceType_1 = require("../../../preferences/PreferenceType");
|
|
5
7
|
exports.UpdateConversationMessagePayloadSchema = zod_1.z.object({
|
|
6
8
|
platformMessageId: zod_1.z.string().nullish(),
|
|
9
|
+
status: ConversationMessageStatus_1.ConversationMessageStatusSchema.nullish(),
|
|
10
|
+
associatedPreferenceType: PreferenceType_1.PreferenceTypeSchema.nullish(),
|
|
7
11
|
body: zod_1.z.string().nullish()
|
|
8
12
|
});
|
|
@@ -1,7 +1,11 @@
|
|
|
1
1
|
import {z} from "zod"
|
|
2
|
+
import {ConversationMessageStatusSchema} from "./ConversationMessageStatus"
|
|
3
|
+
import {PreferenceTypeSchema} from "../../../preferences/PreferenceType"
|
|
2
4
|
|
|
3
5
|
export const UpdateConversationMessagePayloadSchema = z.object({
|
|
4
6
|
platformMessageId: z.string().nullish(),
|
|
7
|
+
status: ConversationMessageStatusSchema.nullish(),
|
|
8
|
+
associatedPreferenceType: PreferenceTypeSchema.nullish(),
|
|
5
9
|
body: z.string().nullish()
|
|
6
10
|
})
|
|
7
11
|
export type UpdateConversationMessagePayload = z.infer<typeof UpdateConversationMessagePayloadSchema>
|