@mamindom/contracts 1.0.192 → 1.0.200

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 (75) hide show
  1. package/dist/events/auth/user-authenticated.interface.d.ts +2 -0
  2. package/dist/events/orders/index.d.ts +1 -0
  3. package/dist/events/orders/index.js +1 -0
  4. package/dist/events/orders/order-side-effects.interface.d.ts +67 -0
  5. package/dist/events/orders/order-side-effects.interface.js +2 -0
  6. package/dist/gen/banner.d.ts +18 -27
  7. package/dist/gen/calculation.d.ts +21 -10
  8. package/dist/gen/calculation.js +1 -1
  9. package/dist/gen/cart.d.ts +31 -0
  10. package/dist/gen/cart.js +1 -0
  11. package/dist/gen/coupon.d.ts +1 -0
  12. package/dist/gen/delivery_settings.d.ts +0 -3
  13. package/dist/gen/notification.d.ts +33 -2
  14. package/dist/gen/notification.js +18 -1
  15. package/dist/gen/order.d.ts +29 -1
  16. package/dist/gen/order.js +1 -0
  17. package/dist/gen/payment.d.ts +10 -4
  18. package/dist/gen/payment.js +1 -0
  19. package/dist/gen/pickup.d.ts +7 -0
  20. package/dist/gen/post.d.ts +3 -0
  21. package/dist/gen/post_comment.d.ts +1 -0
  22. package/dist/gen/product.d.ts +0 -13
  23. package/dist/gen/promotion.d.ts +2 -0
  24. package/dist/gen/shop_filters.d.ts +0 -1
  25. package/dist/gen/site_settings.d.ts +4 -0
  26. package/dist/proto/banner.proto +8 -29
  27. package/dist/proto/calculation.proto +39 -8
  28. package/dist/proto/cart.proto +47 -0
  29. package/dist/proto/coupon.proto +3 -0
  30. package/dist/proto/delivery_settings.proto +3 -3
  31. package/dist/proto/notification.proto +39 -2
  32. package/dist/proto/order.proto +43 -1
  33. package/dist/proto/payment.proto +17 -2
  34. package/dist/proto/pickup.proto +7 -0
  35. package/dist/proto/post.proto +5 -0
  36. package/dist/proto/post_comment.proto +5 -2
  37. package/dist/proto/product.proto +4 -11
  38. package/dist/proto/promotion.proto +4 -0
  39. package/dist/proto/shop_filters.proto +1 -1
  40. package/dist/proto/site_settings.proto +6 -0
  41. package/events/auth/otp-requested.interface.ts +3 -4
  42. package/events/auth/user-authenticated.interface.ts +3 -0
  43. package/events/orders/index.ts +1 -0
  44. package/events/orders/order-side-effects.interface.ts +82 -0
  45. package/gen/banner.ts +16 -29
  46. package/gen/calculation.ts +26 -14
  47. package/gen/cart.ts +38 -0
  48. package/gen/coupon.ts +1 -0
  49. package/gen/delivery_settings.ts +0 -3
  50. package/gen/notification.ts +63 -2
  51. package/gen/order.ts +38 -1
  52. package/gen/payment.ts +16 -4
  53. package/gen/pickup.ts +7 -0
  54. package/gen/post.ts +3 -0
  55. package/gen/post_comment.ts +1 -0
  56. package/gen/product.ts +1 -16
  57. package/gen/promotion.ts +2 -0
  58. package/gen/shop_filters.ts +1 -4
  59. package/gen/site_settings.ts +4 -0
  60. package/package.json +1 -1
  61. package/proto/banner.proto +8 -29
  62. package/proto/calculation.proto +39 -8
  63. package/proto/cart.proto +47 -0
  64. package/proto/coupon.proto +3 -0
  65. package/proto/delivery_settings.proto +3 -3
  66. package/proto/notification.proto +39 -2
  67. package/proto/order.proto +43 -1
  68. package/proto/payment.proto +17 -2
  69. package/proto/pickup.proto +7 -0
  70. package/proto/post.proto +5 -0
  71. package/proto/post_comment.proto +5 -2
  72. package/proto/product.proto +4 -11
  73. package/proto/promotion.proto +4 -0
  74. package/proto/shop_filters.proto +1 -1
  75. package/proto/site_settings.proto +6 -0
@@ -1,13 +1,12 @@
1
1
  export interface OtpRequestedEvent {
2
- // Target: email або phone (визначається за наявності '@').
3
2
  target: string
4
- // Категорія: 'login' | 'verify' | 'password_reset'.
3
+
5
4
  purpose: string
6
5
  code: string
7
- // TTL (ms epoch).
6
+
8
7
  expiresAt: number
9
8
  userId?: string
10
- // Backward-compat: deprecated alias для target.
9
+
11
10
  identifier?: string
12
11
  type?: string
13
12
  }
@@ -2,4 +2,7 @@ export interface UserAuthenticatedEvent {
2
2
  userId: string
3
3
  email?: string
4
4
  phone?: string
5
+
6
+ isEmailVerified?: boolean
7
+ isPhoneVerified?: boolean
5
8
  }
@@ -1,4 +1,5 @@
1
1
  export * from './order-cancelled.interface'
2
2
  export * from './order-created.interface'
3
+ export * from './order-side-effects.interface'
3
4
  export * from './order-status-changed.interface'
4
5
  export * from './order-crm.interface'
@@ -0,0 +1,82 @@
1
+ export interface PaymentCaptureRequestedEvent {
2
+ orderId: string
3
+ orderNumber: string
4
+ providerInvoiceId?: string | null
5
+
6
+ amount: string
7
+ }
8
+
9
+ export interface PaymentCancelRequestedEvent {
10
+ orderId: string
11
+ orderNumber: string
12
+ providerInvoiceId?: string | null
13
+ }
14
+
15
+ export interface PaymentRefundRequestedEvent {
16
+ orderId: string
17
+ orderNumber: string
18
+ providerInvoiceId?: string | null
19
+
20
+ amount?: string
21
+ reason?: string
22
+ }
23
+
24
+ export interface DeliveryShipmentRequestedEvent {
25
+ orderId: string
26
+ orderNumber: string
27
+ method: string
28
+
29
+ cityRef?: string
30
+ warehouseRef?: string
31
+ address?: string
32
+ recipientName: string
33
+ recipientPhone: string
34
+ items: Array<{
35
+ sku: string
36
+ name: string
37
+ quantity: number
38
+ price: string
39
+
40
+ weightKg?: number
41
+ }>
42
+ }
43
+
44
+ export interface PromotionApplyRequestedEvent {
45
+ orderId: string
46
+ userId: string
47
+
48
+ couponCodes?: Array<{
49
+ code: string
50
+ discountAmount: string
51
+ }>
52
+
53
+ couponCode?: string
54
+ couponDiscount?: string
55
+
56
+ promotions?: Array<{
57
+ promotionId: string
58
+ discountAmount: string
59
+ }>
60
+ }
61
+
62
+ export interface OrderTotalsRecalculatedEvent {
63
+ orderId: string
64
+ orderNumber: string
65
+ userId?: string
66
+ source: string
67
+ actorId?: string
68
+
69
+ itemsSubtotal: string
70
+ shippingCost: string
71
+ promoDiscount: string
72
+ couponDiscount: string
73
+
74
+ bonusesBefore: string
75
+ bonusesAfter: string
76
+ certificateBefore: string
77
+ certificateAfter: string
78
+ grandTotalBefore: string
79
+ grandTotalAfter: string
80
+
81
+ recalculatedAt: number
82
+ }
package/gen/banner.ts CHANGED
@@ -216,6 +216,8 @@ export interface UpdateBannerSlideRequest {
216
216
  linksLayout?: string | undefined;
217
217
  styling?: string | undefined;
218
218
  sortOrder?: number | undefined;
219
+ clearButtons: boolean;
220
+ clearLinks: boolean;
219
221
  }
220
222
 
221
223
  export interface UpdateBannerSlideRequest_TitleEntry {
@@ -245,7 +247,6 @@ export interface UpdateSlideOrderRequest {
245
247
  export interface GetBannersByPlacementRequest {
246
248
  placement: BannerPlacement;
247
249
  categoryId?: string | undefined;
248
- lang?: string | undefined;
249
250
  }
250
251
 
251
252
  export interface PublicBannerResponse {
@@ -258,16 +259,26 @@ export interface PublicBannerResponse {
258
259
  export interface PublicSlideResponse {
259
260
  image: string;
260
261
  mobileImage?: string | undefined;
261
- title?: string | undefined;
262
- subtitle?: string | undefined;
263
- buttons: PublicBannerSlideButton[];
262
+ title: { [key: string]: string };
263
+ subtitle: { [key: string]: string };
264
+ buttons: BannerSlideButton[];
264
265
  buttonsPosition?: ElementPosition | undefined;
265
- links: PublicBannerSlideLink[];
266
+ links: BannerSlideLink[];
266
267
  linksPosition?: ElementPosition | undefined;
267
268
  linksLayout?: string | undefined;
268
269
  styling: string;
269
270
  }
270
271
 
272
+ export interface PublicSlideResponse_TitleEntry {
273
+ key: string;
274
+ value: string;
275
+ }
276
+
277
+ export interface PublicSlideResponse_SubtitleEntry {
278
+ key: string;
279
+ value: string;
280
+ }
281
+
271
282
  export interface GetBannersByPlacementResponse {
272
283
  items: PublicBannerResponse[];
273
284
  }
@@ -312,30 +323,6 @@ export interface BannerSlideLink_TextEntry {
312
323
  value: string;
313
324
  }
314
325
 
315
- export interface PublicBannerSlideButton {
316
- text: string;
317
- href: string;
318
- variant?: string | undefined;
319
- backgroundColor?: string | undefined;
320
- textColor?: string | undefined;
321
- borderColor?: string | undefined;
322
- borderRadius?: string | undefined;
323
- fontSize?: string | undefined;
324
- paddingX?: string | undefined;
325
- paddingY?: string | undefined;
326
- fontSizeMobile?: string | undefined;
327
- paddingXMobile?: string | undefined;
328
- paddingYMobile?: string | undefined;
329
- textAlign?: string | undefined;
330
- textAlignMobile?: string | undefined;
331
- }
332
-
333
- export interface PublicBannerSlideLink {
334
- text: string;
335
- href: string;
336
- categoryId?: string | undefined;
337
- }
338
-
339
326
  export const CONTENT_V1_PACKAGE_NAME = "content.v1";
340
327
 
341
328
  export interface BannerServiceClient {
@@ -7,16 +7,34 @@
7
7
  /* eslint-disable */
8
8
  import { GrpcMethod, GrpcStreamMethod } from "@nestjs/microservices";
9
9
  import { Observable } from "rxjs";
10
- import { SuccessResponse } from "./common_promo";
11
10
 
12
11
  export const protobufPackage = "promo.v1";
13
12
 
13
+ export interface ValidateCouponRequest {
14
+ code: string;
15
+ userId: string;
16
+ items: CartItem[];
17
+ orderTotal: number;
18
+ isFirstOrder: boolean;
19
+ orderCount: number;
20
+ userGroups: string[];
21
+ }
22
+
23
+ export interface ValidateCouponResponse {
24
+ usable: boolean;
25
+ reason: string;
26
+ permanent: boolean;
27
+ discountAmount: number;
28
+ minOrderAmount: number;
29
+ }
30
+
14
31
  export interface CartItem {
15
32
  productId: string;
16
33
  categoryId: string;
17
34
  brandId: string;
18
35
  quantity: number;
19
36
  price: number;
37
+ categoryIds: string[];
20
38
  }
21
39
 
22
40
  export interface ValidateAndCalculateRequest {
@@ -38,7 +56,9 @@ export interface ValidateAndCalculateResponse {
38
56
  appliedCoupon?: AppliedCoupon | undefined;
39
57
  errorMessage?: string | undefined;
40
58
  couponError?: string | undefined;
59
+ couponErrorReason?: string | undefined;
41
60
  giftSuggestions: GiftSuggestion[];
61
+ appliedCoupons: AppliedCoupon[];
42
62
  }
43
63
 
44
64
  export interface GiftSuggestion {
@@ -62,20 +82,12 @@ export interface AppliedCoupon {
62
82
  discountAmount: number;
63
83
  }
64
84
 
65
- export interface ApplyPromotionRequest {
66
- userId: string;
67
- orderId: string;
68
- discountAmount: number;
69
- couponCode?: string | undefined;
70
- promotionIds: string[];
71
- }
72
-
73
85
  export const PROMO_V1_PACKAGE_NAME = "promo.v1";
74
86
 
75
87
  export interface PromoCalculationServiceClient {
76
88
  validateAndCalculate(request: ValidateAndCalculateRequest): Observable<ValidateAndCalculateResponse>;
77
89
 
78
- applyPromotion(request: ApplyPromotionRequest): Observable<SuccessResponse>;
90
+ validateCoupon(request: ValidateCouponRequest): Observable<ValidateCouponResponse>;
79
91
  }
80
92
 
81
93
  export interface PromoCalculationServiceController {
@@ -83,14 +95,14 @@ export interface PromoCalculationServiceController {
83
95
  request: ValidateAndCalculateRequest,
84
96
  ): Promise<ValidateAndCalculateResponse> | Observable<ValidateAndCalculateResponse> | ValidateAndCalculateResponse;
85
97
 
86
- applyPromotion(
87
- request: ApplyPromotionRequest,
88
- ): Promise<SuccessResponse> | Observable<SuccessResponse> | SuccessResponse;
98
+ validateCoupon(
99
+ request: ValidateCouponRequest,
100
+ ): Promise<ValidateCouponResponse> | Observable<ValidateCouponResponse> | ValidateCouponResponse;
89
101
  }
90
102
 
91
103
  export function PromoCalculationServiceControllerMethods() {
92
104
  return function (constructor: Function) {
93
- const grpcMethods: string[] = ["validateAndCalculate", "applyPromotion"];
105
+ const grpcMethods: string[] = ["validateAndCalculate", "validateCoupon"];
94
106
  for (const method of grpcMethods) {
95
107
  const descriptor: any = Reflect.getOwnPropertyDescriptor(constructor.prototype, method);
96
108
  GrpcMethod("PromoCalculationService", method)(constructor.prototype[method], method, descriptor);
package/gen/cart.ts CHANGED
@@ -28,6 +28,8 @@ export interface CartItem {
28
28
  lineDiscount: number;
29
29
  lineTotal: number;
30
30
  size: string;
31
+ unavailable: boolean;
32
+ availableStock: number;
31
33
  }
32
34
 
33
35
  export interface AppliedPromotion {
@@ -55,6 +57,7 @@ export interface AppliedCertificate {
55
57
  export interface AppliedBonuses {
56
58
  available: number;
57
59
  applied: number;
60
+ requested: number;
58
61
  }
59
62
 
60
63
  export interface Recipient {
@@ -136,6 +139,8 @@ export interface WishlistItem {
136
139
 
137
140
  export interface WishlistResponse {
138
141
  items: WishlistItem[];
142
+ ok: boolean;
143
+ errorMessage: string;
139
144
  }
140
145
 
141
146
  export interface CartOwner {
@@ -163,6 +168,32 @@ export interface AddItemRequest {
163
168
  quantity: number;
164
169
  }
165
170
 
171
+ export interface AddItemInput {
172
+ productId: string;
173
+ variantId: string;
174
+ quantity: number;
175
+ }
176
+
177
+ export interface AddItemsRequest {
178
+ owner: CartOwner | undefined;
179
+ items: AddItemInput[];
180
+ }
181
+
182
+ export interface AddItemResult {
183
+ productId: string;
184
+ variantId: string;
185
+ ok: boolean;
186
+ reason: string;
187
+ }
188
+
189
+ export interface AddItemsResponse {
190
+ ok: boolean;
191
+ cart: Cart | undefined;
192
+ errorMessage: string;
193
+ results: AddItemResult[];
194
+ errorCode: string;
195
+ }
196
+
166
197
  export interface UpdateItemQtyRequest {
167
198
  owner: CartOwner | undefined;
168
199
  variantId: string;
@@ -234,6 +265,7 @@ export interface SetCheckoutDraftRequest {
234
265
  hasDelivery: boolean;
235
266
  hasPayment: boolean;
236
267
  hasComment: boolean;
268
+ hasDoNotCall: boolean;
237
269
  }
238
270
 
239
271
  export interface RecalculateRequest {
@@ -259,6 +291,7 @@ export interface CartResponse {
259
291
  ok: boolean;
260
292
  cart: Cart | undefined;
261
293
  errorMessage: string;
294
+ errorCode: string;
262
295
  }
263
296
 
264
297
  export interface SuccessResponse {
@@ -272,6 +305,8 @@ export interface CartServiceClient {
272
305
 
273
306
  addItem(request: AddItemRequest): Observable<CartResponse>;
274
307
 
308
+ addItems(request: AddItemsRequest): Observable<AddItemsResponse>;
309
+
275
310
  updateItemQty(request: UpdateItemQtyRequest): Observable<CartResponse>;
276
311
 
277
312
  removeItem(request: RemoveItemRequest): Observable<CartResponse>;
@@ -318,6 +353,8 @@ export interface CartServiceController {
318
353
 
319
354
  addItem(request: AddItemRequest): Promise<CartResponse> | Observable<CartResponse> | CartResponse;
320
355
 
356
+ addItems(request: AddItemsRequest): Promise<AddItemsResponse> | Observable<AddItemsResponse> | AddItemsResponse;
357
+
321
358
  updateItemQty(request: UpdateItemQtyRequest): Promise<CartResponse> | Observable<CartResponse> | CartResponse;
322
359
 
323
360
  removeItem(request: RemoveItemRequest): Promise<CartResponse> | Observable<CartResponse> | CartResponse;
@@ -372,6 +409,7 @@ export function CartServiceControllerMethods() {
372
409
  const grpcMethods: string[] = [
373
410
  "getCart",
374
411
  "addItem",
412
+ "addItems",
375
413
  "updateItemQty",
376
414
  "removeItem",
377
415
  "clearCart",
package/gen/coupon.ts CHANGED
@@ -68,6 +68,7 @@ export interface GenerateCouponsRequest {
68
68
  randomLength?: number | undefined;
69
69
  usageLimitPerUser?: number | undefined;
70
70
  expiresAt?: string | undefined;
71
+ usageLimitTotal?: number | undefined;
71
72
  }
72
73
 
73
74
  export interface GenerateCouponsResponse {
@@ -14,7 +14,6 @@ export interface DeliverySettingsResponse {
14
14
  defaultItemWeightKg: number;
15
15
  freeShippingThreshold: number;
16
16
  defaultDeclaredValue: number;
17
- npSenderWarehouseRef?: string | undefined;
18
17
  updatedAt: string;
19
18
  }
20
19
 
@@ -25,8 +24,6 @@ export interface UpdateDeliverySettingsRequest {
25
24
  defaultItemWeightKg?: number | undefined;
26
25
  freeShippingThreshold?: number | undefined;
27
26
  defaultDeclaredValue?: number | undefined;
28
- npSenderWarehouseRef?: string | undefined;
29
- clearNpSenderWarehouseRef: boolean;
30
27
  }
31
28
 
32
29
  export interface ListCarriersRequest {
@@ -28,6 +28,7 @@ export enum CampaignRecipientStatusEnum {
28
28
  RECIPIENT_FAILED = 3,
29
29
  RECIPIENT_SKIPPED_OPT_OUT = 4,
30
30
  RECIPIENT_SKIPPED_NO_CONTACT = 5,
31
+ RECIPIENT_SENDING = 6,
31
32
  UNRECOGNIZED = -1,
32
33
  }
33
34
 
@@ -98,6 +99,29 @@ export interface SendToCustomerResponse {
98
99
  logId: string;
99
100
  }
100
101
 
102
+ export interface VerifyUnsubscribeTokenRequest {
103
+ token: string;
104
+ }
105
+
106
+ export interface VerifyUnsubscribeTokenResponse {
107
+ ok: boolean;
108
+ errorMessage: string;
109
+ email?: string | undefined;
110
+ userId?: string | undefined;
111
+ unsubscribedFrom: string[];
112
+ }
113
+
114
+ export interface ApplyUnsubscribeRequest {
115
+ token: string;
116
+ categories: string[];
117
+ }
118
+
119
+ export interface ApplyUnsubscribeResponse {
120
+ ok: boolean;
121
+ errorMessage: string;
122
+ categories: string[];
123
+ }
124
+
101
125
  export interface EnqueueRecipientsRequest {
102
126
  campaignId: string;
103
127
  recipients: CampaignResolvedRecipient[];
@@ -327,6 +351,7 @@ export interface UpsertTemplateRequest {
327
351
  bodyText: string;
328
352
  variablesJson: string;
329
353
  isActive: boolean;
354
+ actorId?: string | undefined;
330
355
  }
331
356
 
332
357
  export interface UpdateTemplateRequest {
@@ -334,8 +359,8 @@ export interface UpdateTemplateRequest {
334
359
  title?: string | undefined;
335
360
  subject?: string | undefined;
336
361
  contentJson?: string | undefined;
337
- bodyHtml: string;
338
- bodyText: string;
362
+ bodyHtml?: string | undefined;
363
+ bodyText?: string | undefined;
339
364
  variablesJson?: string | undefined;
340
365
  isActive?: boolean | undefined;
341
366
  actorId?: string | undefined;
@@ -597,6 +622,42 @@ export function NotificationLogsServiceControllerMethods() {
597
622
 
598
623
  export const NOTIFICATION_LOGS_SERVICE_NAME = "NotificationLogsService";
599
624
 
625
+ export interface NotificationConsentServiceClient {
626
+ verifyUnsubscribeToken(request: VerifyUnsubscribeTokenRequest): Observable<VerifyUnsubscribeTokenResponse>;
627
+
628
+ applyUnsubscribe(request: ApplyUnsubscribeRequest): Observable<ApplyUnsubscribeResponse>;
629
+ }
630
+
631
+ export interface NotificationConsentServiceController {
632
+ verifyUnsubscribeToken(
633
+ request: VerifyUnsubscribeTokenRequest,
634
+ ):
635
+ | Promise<VerifyUnsubscribeTokenResponse>
636
+ | Observable<VerifyUnsubscribeTokenResponse>
637
+ | VerifyUnsubscribeTokenResponse;
638
+
639
+ applyUnsubscribe(
640
+ request: ApplyUnsubscribeRequest,
641
+ ): Promise<ApplyUnsubscribeResponse> | Observable<ApplyUnsubscribeResponse> | ApplyUnsubscribeResponse;
642
+ }
643
+
644
+ export function NotificationConsentServiceControllerMethods() {
645
+ return function (constructor: Function) {
646
+ const grpcMethods: string[] = ["verifyUnsubscribeToken", "applyUnsubscribe"];
647
+ for (const method of grpcMethods) {
648
+ const descriptor: any = Reflect.getOwnPropertyDescriptor(constructor.prototype, method);
649
+ GrpcMethod("NotificationConsentService", method)(constructor.prototype[method], method, descriptor);
650
+ }
651
+ const grpcStreamMethods: string[] = [];
652
+ for (const method of grpcStreamMethods) {
653
+ const descriptor: any = Reflect.getOwnPropertyDescriptor(constructor.prototype, method);
654
+ GrpcStreamMethod("NotificationConsentService", method)(constructor.prototype[method], method, descriptor);
655
+ }
656
+ };
657
+ }
658
+
659
+ export const NOTIFICATION_CONSENT_SERVICE_NAME = "NotificationConsentService";
660
+
600
661
  export interface TelegramChatsServiceClient {
601
662
  listChats(request: ListChatsRequest): Observable<ListChatsResponse>;
602
663
 
package/gen/order.ts CHANGED
@@ -212,7 +212,7 @@ export interface Order {
212
212
  delivery: OrderDelivery | undefined;
213
213
  payment: OrderPayment | undefined;
214
214
  totals: OrderTotals | undefined;
215
- promoCode: string;
215
+ promoCodes: string[];
216
216
  certificateCode: string;
217
217
  doNotCall: boolean;
218
218
  comment: string;
@@ -368,6 +368,28 @@ export interface EditItemsRequest {
368
368
  id: string;
369
369
  items: OrderItemInput[];
370
370
  actorId: string;
371
+ acceptDiscountChange: boolean;
372
+ }
373
+
374
+ export interface PreviewRecalculationRequest {
375
+ id: string;
376
+ items: OrderItemInput[];
377
+ }
378
+
379
+ export interface DiscountChange {
380
+ kind: string;
381
+ name: string;
382
+ before: number;
383
+ after: number;
384
+ }
385
+
386
+ export interface PreviewRecalculationResponse {
387
+ ok: boolean;
388
+ errorMessage: string;
389
+ before: OrderTotals | undefined;
390
+ after: OrderTotals | undefined;
391
+ discountChanges: DiscountChange[];
392
+ discountsDecreased: boolean;
371
393
  }
372
394
 
373
395
  export interface ApplyRecalculationRequest {
@@ -381,6 +403,7 @@ export interface ApplyRecalculationRequest {
381
403
  bonusesUsed: number;
382
404
  shippingCost: number;
383
405
  grandTotal: number;
406
+ idempotencyKey: string;
384
407
  }
385
408
 
386
409
  export interface SetTrackingNumberRequest {
@@ -395,12 +418,19 @@ export interface ReorderOrderRequest {
395
418
  userId: string;
396
419
  }
397
420
 
421
+ export interface ReorderSkippedItem {
422
+ productId: string;
423
+ variantId: string;
424
+ reason: string;
425
+ }
426
+
398
427
  export interface ReorderResponse {
399
428
  ok: boolean;
400
429
  cartId: string;
401
430
  added: number;
402
431
  skipped: number;
403
432
  error: string;
433
+ skippedItems: ReorderSkippedItem[];
404
434
  }
405
435
 
406
436
  export interface ListHistoryRequest {
@@ -450,6 +480,8 @@ export interface OrderServiceClient {
450
480
 
451
481
  editItems(request: EditItemsRequest): Observable<OrderResponse>;
452
482
 
483
+ previewRecalculation(request: PreviewRecalculationRequest): Observable<PreviewRecalculationResponse>;
484
+
453
485
  setTrackingNumber(request: SetTrackingNumberRequest): Observable<OrderResponse>;
454
486
 
455
487
  applyRecalculation(request: ApplyRecalculationRequest): Observable<OrderResponse>;
@@ -506,6 +538,10 @@ export interface OrderServiceController {
506
538
 
507
539
  editItems(request: EditItemsRequest): Promise<OrderResponse> | Observable<OrderResponse> | OrderResponse;
508
540
 
541
+ previewRecalculation(
542
+ request: PreviewRecalculationRequest,
543
+ ): Promise<PreviewRecalculationResponse> | Observable<PreviewRecalculationResponse> | PreviewRecalculationResponse;
544
+
509
545
  setTrackingNumber(
510
546
  request: SetTrackingNumberRequest,
511
547
  ): Promise<OrderResponse> | Observable<OrderResponse> | OrderResponse;
@@ -549,6 +585,7 @@ export function OrderServiceControllerMethods() {
549
585
  "addTag",
550
586
  "removeTag",
551
587
  "editItems",
588
+ "previewRecalculation",
552
589
  "setTrackingNumber",
553
590
  "applyRecalculation",
554
591
  "setCrmOrderId",
package/gen/payment.ts CHANGED
@@ -29,6 +29,8 @@ export interface Payment {
29
29
  capturedAt: number;
30
30
  cancelledAt: number;
31
31
  refundedAt: number;
32
+ captureSource: string;
33
+ captureNote: string;
32
34
  }
33
35
 
34
36
  export interface PaymentProviderInfo {
@@ -38,10 +40,6 @@ export interface PaymentProviderInfo {
38
40
  supportsInstallment: boolean;
39
41
  description: string;
40
42
  configured: boolean;
41
- /**
42
- * Для installment-провайдерів — максимум частин оплати (з конфігу `parts`).
43
- * 0 для звичайних провайдерів. Фронт показує «до N платежів» без env-синхронізації.
44
- */
45
43
  installmentMaxParts: number;
46
44
  }
47
45
 
@@ -96,6 +94,13 @@ export interface CaptureRequest {
96
94
  actorId: string;
97
95
  }
98
96
 
97
+ export interface MarkPaidOfflineRequest {
98
+ id: string;
99
+ amount: number;
100
+ note: string;
101
+ actorId: string;
102
+ }
103
+
99
104
  export interface CancelRequest {
100
105
  id: string;
101
106
  reason: string;
@@ -188,6 +193,8 @@ export interface PaymentServiceClient {
188
193
 
189
194
  capture(request: CaptureRequest): Observable<PaymentResponse>;
190
195
 
196
+ markPaidOffline(request: MarkPaidOfflineRequest): Observable<PaymentResponse>;
197
+
191
198
  cancel(request: CancelRequest): Observable<PaymentResponse>;
192
199
 
193
200
  refund(request: RefundRequest): Observable<PaymentResponse>;
@@ -222,6 +229,10 @@ export interface PaymentServiceController {
222
229
 
223
230
  capture(request: CaptureRequest): Promise<PaymentResponse> | Observable<PaymentResponse> | PaymentResponse;
224
231
 
232
+ markPaidOffline(
233
+ request: MarkPaidOfflineRequest,
234
+ ): Promise<PaymentResponse> | Observable<PaymentResponse> | PaymentResponse;
235
+
225
236
  cancel(request: CancelRequest): Promise<PaymentResponse> | Observable<PaymentResponse> | PaymentResponse;
226
237
 
227
238
  refund(request: RefundRequest): Promise<PaymentResponse> | Observable<PaymentResponse> | PaymentResponse;
@@ -257,6 +268,7 @@ export function PaymentServiceControllerMethods() {
257
268
  "getPaymentByOrder",
258
269
  "listPayments",
259
270
  "capture",
271
+ "markPaidOffline",
260
272
  "cancel",
261
273
  "refund",
262
274
  "syncStatus",
package/gen/pickup.ts CHANGED
@@ -23,12 +23,15 @@ export interface PickupPointResponse {
23
23
  code1c?: string | undefined;
24
24
  schedule?: string | undefined;
25
25
  showOnContacts: boolean;
26
+ isPickup: boolean;
27
+ sortOrder: number;
26
28
  }
27
29
 
28
30
  export interface GetPickupPointsRequest {
29
31
  isActive?: boolean | undefined;
30
32
  city?: string | undefined;
31
33
  showOnContacts?: boolean | undefined;
34
+ isPickup?: boolean | undefined;
32
35
  }
33
36
 
34
37
  export interface GetPickupPointsResponse {
@@ -50,6 +53,8 @@ export interface CreatePickupPointRequest {
50
53
  code1c?: string | undefined;
51
54
  schedule?: string | undefined;
52
55
  showOnContacts?: boolean | undefined;
56
+ isPickup?: boolean | undefined;
57
+ sortOrder?: number | undefined;
53
58
  }
54
59
 
55
60
  export interface UpdatePickupPointRequest {
@@ -64,6 +69,8 @@ export interface UpdatePickupPointRequest {
64
69
  code1c?: string | undefined;
65
70
  schedule?: string | undefined;
66
71
  showOnContacts?: boolean | undefined;
72
+ isPickup?: boolean | undefined;
73
+ sortOrder?: number | undefined;
67
74
  }
68
75
 
69
76
  export interface DeletePickupPointRequest {
package/gen/post.ts CHANGED
@@ -242,6 +242,9 @@ export interface UpdatePostRequest {
242
242
  tagIds: string[];
243
243
  images: PostImagePayload[];
244
244
  updatedById: string;
245
+ clearCategories: boolean;
246
+ clearTags: boolean;
247
+ clearImages: boolean;
245
248
  }
246
249
 
247
250
  export interface UpdatePostRequest_TitleEntry {