@wix/auto_sdk_ecom_order-payment-requests 1.0.70 → 1.0.72

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.
@@ -20,6 +20,22 @@ import { transformRESTTimestampToSDKTimestamp } from "@wix/sdk-runtime/transform
20
20
  import { transformSDKFieldMaskToRESTFieldMask } from "@wix/sdk-runtime/transformations/field-mask";
21
21
  import { transformPaths } from "@wix/sdk-runtime/transformations/transform-paths";
22
22
  import { resolveUrl } from "@wix/sdk-runtime/rest-modules";
23
+ var TRANSFORM_PATHS_0 = [
24
+ { path: "orderPaymentRequest.expirationDate" },
25
+ { path: "orderPaymentRequest.createdDate" },
26
+ { path: "orderPaymentRequest.updatedDate" }
27
+ ];
28
+ var TRANSFORM_PATHS_1 = [
29
+ { path: "orderPaymentRequests.expirationDate" },
30
+ { path: "orderPaymentRequests.createdDate" },
31
+ { path: "orderPaymentRequests.updatedDate" }
32
+ ];
33
+ var TRANSFORM_PATHS_2 = [
34
+ { path: "results.item.orderPaymentRequest.expirationDate" },
35
+ { path: "results.item.orderPaymentRequest.createdDate" },
36
+ { path: "results.item.orderPaymentRequest.updatedDate" }
37
+ ];
38
+ var TRANSFORM_PATHS_3 = [{ path: "fieldMask" }];
23
39
  function resolveWixEcomOrderPaymentRequestApiV1OrderPaymentRequestsServiceUrl(opts) {
24
40
  const domainToMappings = {
25
41
  "api._api_base_domain_": [
@@ -67,11 +83,7 @@ function createOrderPaymentRequest(payload) {
67
83
  const serializedData = transformPaths(payload, [
68
84
  {
69
85
  transformFn: transformSDKTimestampToRESTTimestamp,
70
- paths: [
71
- { path: "orderPaymentRequest.expirationDate" },
72
- { path: "orderPaymentRequest.createdDate" },
73
- { path: "orderPaymentRequest.updatedDate" }
74
- ]
86
+ paths: TRANSFORM_PATHS_0
75
87
  }
76
88
  ]);
77
89
  const metadata = {
@@ -89,11 +101,7 @@ function createOrderPaymentRequest(payload) {
89
101
  transformResponse: (payload2) => transformPaths(payload2, [
90
102
  {
91
103
  transformFn: transformRESTTimestampToSDKTimestamp,
92
- paths: [
93
- { path: "orderPaymentRequest.expirationDate" },
94
- { path: "orderPaymentRequest.createdDate" },
95
- { path: "orderPaymentRequest.updatedDate" }
96
- ]
104
+ paths: TRANSFORM_PATHS_0
97
105
  }
98
106
  ])
99
107
  };
@@ -106,11 +114,7 @@ function bulkCreateOrderPaymentRequests(payload) {
106
114
  const serializedData = transformPaths(payload, [
107
115
  {
108
116
  transformFn: transformSDKTimestampToRESTTimestamp,
109
- paths: [
110
- { path: "orderPaymentRequests.expirationDate" },
111
- { path: "orderPaymentRequests.createdDate" },
112
- { path: "orderPaymentRequests.updatedDate" }
113
- ]
117
+ paths: TRANSFORM_PATHS_1
114
118
  }
115
119
  ]);
116
120
  const metadata = {
@@ -132,11 +136,7 @@ function bulkCreateOrderPaymentRequests(payload) {
132
136
  transformResponse: (payload2) => transformPaths(payload2, [
133
137
  {
134
138
  transformFn: transformRESTTimestampToSDKTimestamp,
135
- paths: [
136
- { path: "results.item.orderPaymentRequest.expirationDate" },
137
- { path: "results.item.orderPaymentRequest.createdDate" },
138
- { path: "results.item.orderPaymentRequest.updatedDate" }
139
- ]
139
+ paths: TRANSFORM_PATHS_2
140
140
  }
141
141
  ])
142
142
  };
@@ -165,11 +165,7 @@ function getOrderPaymentRequest(payload) {
165
165
  transformResponse: (payload2) => transformPaths(payload2, [
166
166
  {
167
167
  transformFn: transformRESTTimestampToSDKTimestamp,
168
- paths: [
169
- { path: "orderPaymentRequest.expirationDate" },
170
- { path: "orderPaymentRequest.createdDate" },
171
- { path: "orderPaymentRequest.updatedDate" }
172
- ]
168
+ paths: TRANSFORM_PATHS_0
173
169
  }
174
170
  ])
175
171
  };
@@ -182,15 +178,11 @@ function updateOrderPaymentRequest(payload) {
182
178
  const serializedData = transformPaths(payload, [
183
179
  {
184
180
  transformFn: transformSDKFieldMaskToRESTFieldMask,
185
- paths: [{ path: "fieldMask" }]
181
+ paths: TRANSFORM_PATHS_3
186
182
  },
187
183
  {
188
184
  transformFn: transformSDKTimestampToRESTTimestamp,
189
- paths: [
190
- { path: "orderPaymentRequest.expirationDate" },
191
- { path: "orderPaymentRequest.createdDate" },
192
- { path: "orderPaymentRequest.updatedDate" }
193
- ]
185
+ paths: TRANSFORM_PATHS_0
194
186
  }
195
187
  ]);
196
188
  const metadata = {
@@ -212,11 +204,7 @@ function updateOrderPaymentRequest(payload) {
212
204
  transformResponse: (payload2) => transformPaths(payload2, [
213
205
  {
214
206
  transformFn: transformRESTTimestampToSDKTimestamp,
215
- paths: [
216
- { path: "orderPaymentRequest.expirationDate" },
217
- { path: "orderPaymentRequest.createdDate" },
218
- { path: "orderPaymentRequest.updatedDate" }
219
- ]
207
+ paths: TRANSFORM_PATHS_0
220
208
  }
221
209
  ])
222
210
  };
@@ -264,11 +252,7 @@ function queryOrderPaymentRequests(payload) {
264
252
  transformResponse: (payload2) => transformPaths(payload2, [
265
253
  {
266
254
  transformFn: transformRESTTimestampToSDKTimestamp,
267
- paths: [
268
- { path: "orderPaymentRequests.expirationDate" },
269
- { path: "orderPaymentRequests.createdDate" },
270
- { path: "orderPaymentRequests.updatedDate" }
271
- ]
255
+ paths: TRANSFORM_PATHS_1
272
256
  }
273
257
  ])
274
258
  };
@@ -316,11 +300,7 @@ function updateExtendedFields(payload) {
316
300
  transformResponse: (payload2) => transformPaths(payload2, [
317
301
  {
318
302
  transformFn: transformRESTTimestampToSDKTimestamp,
319
- paths: [
320
- { path: "orderPaymentRequest.expirationDate" },
321
- { path: "orderPaymentRequest.createdDate" },
322
- { path: "orderPaymentRequest.updatedDate" }
323
- ]
303
+ paths: TRANSFORM_PATHS_0
324
304
  }
325
305
  ])
326
306
  };
@@ -372,6 +352,9 @@ import { transformSDKImageToRESTImage } from "@wix/sdk-runtime/transformations/i
372
352
  import { transformRESTImageToSDKImage } from "@wix/sdk-runtime/transformations/image";
373
353
  import { transformPaths as transformPaths2 } from "@wix/sdk-runtime/transformations/transform-paths";
374
354
  import { createQueryUtils } from "@wix/sdk-runtime/query-builder-utils";
355
+ var TRANSFORM_PATHS_02 = [{ path: "orderPaymentRequest.image" }];
356
+ var TRANSFORM_PATHS_12 = [{ path: "orderPaymentRequests.image" }];
357
+ var TRANSFORM_PATHS_22 = [{ path: "results.item.orderPaymentRequest.image" }];
375
358
  var Status = /* @__PURE__ */ ((Status2) => {
376
359
  Status2["UNPAID"] = "UNPAID";
377
360
  Status2["PAID"] = "PAID";
@@ -405,7 +388,7 @@ async function createOrderPaymentRequest2(options) {
405
388
  [
406
389
  {
407
390
  transformFn: transformSDKImageToRESTImage,
408
- paths: [{ path: "orderPaymentRequest.image" }]
391
+ paths: TRANSFORM_PATHS_02
409
392
  }
410
393
  ]
411
394
  );
@@ -418,7 +401,7 @@ async function createOrderPaymentRequest2(options) {
418
401
  transformPaths2(result.data, [
419
402
  {
420
403
  transformFn: transformRESTImageToSDKImage,
421
- paths: [{ path: "orderPaymentRequest.image" }]
404
+ paths: TRANSFORM_PATHS_02
422
405
  }
423
406
  ])
424
407
  )?.orderPaymentRequest;
@@ -448,7 +431,7 @@ async function bulkCreateOrderPaymentRequests2(orderPaymentRequests, options) {
448
431
  [
449
432
  {
450
433
  transformFn: transformSDKImageToRESTImage,
451
- paths: [{ path: "orderPaymentRequests.image" }]
434
+ paths: TRANSFORM_PATHS_12
452
435
  }
453
436
  ]
454
437
  );
@@ -463,7 +446,7 @@ async function bulkCreateOrderPaymentRequests2(orderPaymentRequests, options) {
463
446
  transformPaths2(result.data, [
464
447
  {
465
448
  transformFn: transformRESTImageToSDKImage,
466
- paths: [{ path: "results.item.orderPaymentRequest.image" }]
449
+ paths: TRANSFORM_PATHS_22
467
450
  }
468
451
  ])
469
452
  );
@@ -498,7 +481,7 @@ async function getOrderPaymentRequest2(orderPaymentRequestId) {
498
481
  transformPaths2(result.data, [
499
482
  {
500
483
  transformFn: transformRESTImageToSDKImage,
501
- paths: [{ path: "orderPaymentRequest.image" }]
484
+ paths: TRANSFORM_PATHS_02
502
485
  }
503
486
  ])
504
487
  )?.orderPaymentRequest;
@@ -525,7 +508,7 @@ async function updateOrderPaymentRequest2(_id, orderPaymentRequest) {
525
508
  [
526
509
  {
527
510
  transformFn: transformSDKImageToRESTImage,
528
- paths: [{ path: "orderPaymentRequest.image" }]
511
+ paths: TRANSFORM_PATHS_02
529
512
  }
530
513
  ]
531
514
  );
@@ -538,7 +521,7 @@ async function updateOrderPaymentRequest2(_id, orderPaymentRequest) {
538
521
  transformPaths2(result.data, [
539
522
  {
540
523
  transformFn: transformRESTImageToSDKImage,
541
- paths: [{ path: "orderPaymentRequest.image" }]
524
+ paths: TRANSFORM_PATHS_02
542
525
  }
543
526
  ])
544
527
  )?.orderPaymentRequest;
@@ -612,7 +595,7 @@ function queryOrderPaymentRequests2() {
612
595
  transformPaths2(data, [
613
596
  {
614
597
  transformFn: transformRESTImageToSDKImage,
615
- paths: [{ path: "orderPaymentRequests.image" }]
598
+ paths: TRANSFORM_PATHS_12
616
599
  }
617
600
  ])
618
601
  );
@@ -645,7 +628,7 @@ async function typedQueryOrderPaymentRequests(query) {
645
628
  transformPaths2(result.data, [
646
629
  {
647
630
  transformFn: transformRESTImageToSDKImage,
648
- paths: [{ path: "orderPaymentRequests.image" }]
631
+ paths: TRANSFORM_PATHS_12
649
632
  }
650
633
  ])
651
634
  );
@@ -707,7 +690,7 @@ async function updateExtendedFields2(_id, namespace, options) {
707
690
  transformPaths2(result.data, [
708
691
  {
709
692
  transformFn: transformRESTImageToSDKImage,
710
- paths: [{ path: "orderPaymentRequest.image" }]
693
+ paths: TRANSFORM_PATHS_02
711
694
  }
712
695
  ])
713
696
  );
@@ -785,6 +768,20 @@ async function chargeOrderPaymentRequest2(orderPaymentRequestId, options) {
785
768
  }
786
769
 
787
770
  // src/ecom-v1-order-payment-request-order-payment-requests.public.ts
771
+ var TRANSFORM_PATHS_03 = [
772
+ { path: "entity.expirationDate" },
773
+ { path: "entity.createdDate" },
774
+ { path: "entity.updatedDate" },
775
+ { path: "metadata.eventTime" }
776
+ ];
777
+ var TRANSFORM_PATHS_13 = [{ path: "entity.image" }];
778
+ var TRANSFORM_PATHS_23 = [
779
+ { path: "data.orderPaymentRequest.expirationDate" },
780
+ { path: "data.orderPaymentRequest.createdDate" },
781
+ { path: "data.orderPaymentRequest.updatedDate" },
782
+ { path: "metadata.eventTime" }
783
+ ];
784
+ var TRANSFORM_PATHS_32 = [{ path: "data.orderPaymentRequest.image" }];
788
785
  function createOrderPaymentRequest3(httpClient) {
789
786
  return (options) => createOrderPaymentRequest2(
790
787
  options,
@@ -873,16 +870,11 @@ var onOrderPaymentRequestCreated = /* @__PURE__ */ EventDefinition(
873
870
  transformPaths3(event, [
874
871
  {
875
872
  transformFn: transformRESTTimestampToSDKTimestamp2,
876
- paths: [
877
- { path: "entity.expirationDate" },
878
- { path: "entity.createdDate" },
879
- { path: "entity.updatedDate" },
880
- { path: "metadata.eventTime" }
881
- ]
873
+ paths: TRANSFORM_PATHS_03
882
874
  },
883
875
  {
884
876
  transformFn: transformRESTImageToSDKImage2,
885
- paths: [{ path: "entity.image" }]
877
+ paths: TRANSFORM_PATHS_13
886
878
  }
887
879
  ])
888
880
  )
@@ -894,16 +886,11 @@ var onOrderPaymentRequestDeleted = /* @__PURE__ */ EventDefinition(
894
886
  transformPaths3(event, [
895
887
  {
896
888
  transformFn: transformRESTTimestampToSDKTimestamp2,
897
- paths: [
898
- { path: "entity.expirationDate" },
899
- { path: "entity.createdDate" },
900
- { path: "entity.updatedDate" },
901
- { path: "metadata.eventTime" }
902
- ]
889
+ paths: TRANSFORM_PATHS_03
903
890
  },
904
891
  {
905
892
  transformFn: transformRESTImageToSDKImage2,
906
- paths: [{ path: "entity.image" }]
893
+ paths: TRANSFORM_PATHS_13
907
894
  }
908
895
  ])
909
896
  )
@@ -915,16 +902,11 @@ var onOrderPaymentRequestExpired = /* @__PURE__ */ EventDefinition(
915
902
  transformPaths3(event, [
916
903
  {
917
904
  transformFn: transformRESTTimestampToSDKTimestamp2,
918
- paths: [
919
- { path: "data.orderPaymentRequest.expirationDate" },
920
- { path: "data.orderPaymentRequest.createdDate" },
921
- { path: "data.orderPaymentRequest.updatedDate" },
922
- { path: "metadata.eventTime" }
923
- ]
905
+ paths: TRANSFORM_PATHS_23
924
906
  },
925
907
  {
926
908
  transformFn: transformRESTImageToSDKImage2,
927
- paths: [{ path: "data.orderPaymentRequest.image" }]
909
+ paths: TRANSFORM_PATHS_32
928
910
  }
929
911
  ])
930
912
  )
@@ -936,16 +918,11 @@ var onOrderPaymentRequestPaid = /* @__PURE__ */ EventDefinition(
936
918
  transformPaths3(event, [
937
919
  {
938
920
  transformFn: transformRESTTimestampToSDKTimestamp2,
939
- paths: [
940
- { path: "data.orderPaymentRequest.expirationDate" },
941
- { path: "data.orderPaymentRequest.createdDate" },
942
- { path: "data.orderPaymentRequest.updatedDate" },
943
- { path: "metadata.eventTime" }
944
- ]
921
+ paths: TRANSFORM_PATHS_23
945
922
  },
946
923
  {
947
924
  transformFn: transformRESTImageToSDKImage2,
948
- paths: [{ path: "data.orderPaymentRequest.image" }]
925
+ paths: TRANSFORM_PATHS_32
949
926
  }
950
927
  ])
951
928
  )
@@ -957,16 +934,11 @@ var onOrderPaymentRequestUpdated = /* @__PURE__ */ EventDefinition(
957
934
  transformPaths3(event, [
958
935
  {
959
936
  transformFn: transformRESTTimestampToSDKTimestamp2,
960
- paths: [
961
- { path: "entity.expirationDate" },
962
- { path: "entity.createdDate" },
963
- { path: "entity.updatedDate" },
964
- { path: "metadata.eventTime" }
965
- ]
937
+ paths: TRANSFORM_PATHS_03
966
938
  },
967
939
  {
968
940
  transformFn: transformRESTImageToSDKImage2,
969
- paths: [{ path: "entity.image" }]
941
+ paths: TRANSFORM_PATHS_13
970
942
  }
971
943
  ])
972
944
  )
@@ -978,16 +950,11 @@ var onOrderPaymentRequestVoided = /* @__PURE__ */ EventDefinition(
978
950
  transformPaths3(event, [
979
951
  {
980
952
  transformFn: transformRESTTimestampToSDKTimestamp2,
981
- paths: [
982
- { path: "data.orderPaymentRequest.expirationDate" },
983
- { path: "data.orderPaymentRequest.createdDate" },
984
- { path: "data.orderPaymentRequest.updatedDate" },
985
- { path: "metadata.eventTime" }
986
- ]
953
+ paths: TRANSFORM_PATHS_23
987
954
  },
988
955
  {
989
956
  transformFn: transformRESTImageToSDKImage2,
990
- paths: [{ path: "data.orderPaymentRequest.image" }]
957
+ paths: TRANSFORM_PATHS_32
991
958
  }
992
959
  ])
993
960
  )