@wix/auto_sdk_ecom_delivery-solutions 1.0.15 → 1.0.17

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 (130) hide show
  1. package/build/{internal/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.universal.d.ts → gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.universal-Dd0MZRrv.d.mts} +52 -72
  2. package/build/{cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.universal.d.ts → gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.universal-Dd0MZRrv.d.ts} +52 -72
  3. package/build/index.d.mts +18 -0
  4. package/build/index.d.ts +18 -0
  5. package/build/index.js +268 -0
  6. package/build/index.js.map +1 -0
  7. package/build/index.mjs +237 -0
  8. package/build/index.mjs.map +1 -0
  9. package/build/internal/{es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.universal.d.ts → gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.universal-Dd0MZRrv.d.mts} +52 -72
  10. package/build/{es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.universal.d.ts → internal/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.universal-Dd0MZRrv.d.ts} +52 -72
  11. package/build/internal/index.d.mts +18 -0
  12. package/build/internal/index.d.ts +18 -0
  13. package/build/internal/index.js +268 -0
  14. package/build/internal/index.js.map +1 -0
  15. package/build/internal/index.mjs +237 -0
  16. package/build/internal/index.mjs.map +1 -0
  17. package/build/{cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.types.d.ts → internal/meta.d.mts} +55 -156
  18. package/build/{es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.types.d.ts → internal/meta.d.ts} +55 -156
  19. package/build/internal/meta.js +127 -0
  20. package/build/internal/meta.js.map +1 -0
  21. package/build/internal/meta.mjs +100 -0
  22. package/build/internal/meta.mjs.map +1 -0
  23. package/build/{internal/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.types.d.ts → meta.d.mts} +55 -156
  24. package/build/{internal/es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.types.d.ts → meta.d.ts} +55 -156
  25. package/build/meta.js +127 -0
  26. package/build/meta.js.map +1 -0
  27. package/build/meta.mjs +100 -0
  28. package/build/meta.mjs.map +1 -0
  29. package/package.json +12 -11
  30. package/build/cjs/index.d.ts +0 -1
  31. package/build/cjs/index.js +0 -18
  32. package/build/cjs/index.js.map +0 -1
  33. package/build/cjs/index.typings.d.ts +0 -1
  34. package/build/cjs/index.typings.js +0 -18
  35. package/build/cjs/index.typings.js.map +0 -1
  36. package/build/cjs/meta.d.ts +0 -1
  37. package/build/cjs/meta.js +0 -18
  38. package/build/cjs/meta.js.map +0 -1
  39. package/build/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.context.d.ts +0 -5
  40. package/build/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.context.js +0 -15
  41. package/build/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.context.js.map +0 -1
  42. package/build/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.http.d.ts +0 -3
  43. package/build/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.http.js +0 -79
  44. package/build/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.http.js.map +0 -1
  45. package/build/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.meta.d.ts +0 -13
  46. package/build/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.meta.js +0 -47
  47. package/build/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.meta.js.map +0 -1
  48. package/build/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.public.d.ts +0 -16
  49. package/build/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.public.js +0 -20
  50. package/build/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.public.js.map +0 -1
  51. package/build/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.types.js +0 -80
  52. package/build/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.types.js.map +0 -1
  53. package/build/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.universal.js +0 -181
  54. package/build/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.universal.js.map +0 -1
  55. package/build/es/index.d.ts +0 -1
  56. package/build/es/index.js +0 -2
  57. package/build/es/index.js.map +0 -1
  58. package/build/es/index.typings.d.ts +0 -1
  59. package/build/es/index.typings.js +0 -2
  60. package/build/es/index.typings.js.map +0 -1
  61. package/build/es/meta.d.ts +0 -1
  62. package/build/es/meta.js +0 -2
  63. package/build/es/meta.js.map +0 -1
  64. package/build/es/package.json +0 -3
  65. package/build/es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.context.d.ts +0 -5
  66. package/build/es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.context.js +0 -5
  67. package/build/es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.context.js.map +0 -1
  68. package/build/es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.http.d.ts +0 -3
  69. package/build/es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.http.js +0 -75
  70. package/build/es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.http.js.map +0 -1
  71. package/build/es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.meta.d.ts +0 -13
  72. package/build/es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.meta.js +0 -20
  73. package/build/es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.meta.js.map +0 -1
  74. package/build/es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.public.d.ts +0 -16
  75. package/build/es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.public.js +0 -9
  76. package/build/es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.public.js.map +0 -1
  77. package/build/es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.types.js +0 -77
  78. package/build/es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.types.js.map +0 -1
  79. package/build/es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.universal.js +0 -154
  80. package/build/es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.universal.js.map +0 -1
  81. package/build/internal/cjs/index.d.ts +0 -1
  82. package/build/internal/cjs/index.js +0 -18
  83. package/build/internal/cjs/index.js.map +0 -1
  84. package/build/internal/cjs/index.typings.d.ts +0 -1
  85. package/build/internal/cjs/index.typings.js +0 -18
  86. package/build/internal/cjs/index.typings.js.map +0 -1
  87. package/build/internal/cjs/meta.d.ts +0 -1
  88. package/build/internal/cjs/meta.js +0 -18
  89. package/build/internal/cjs/meta.js.map +0 -1
  90. package/build/internal/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.context.d.ts +0 -5
  91. package/build/internal/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.context.js +0 -15
  92. package/build/internal/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.context.js.map +0 -1
  93. package/build/internal/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.http.d.ts +0 -3
  94. package/build/internal/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.http.js +0 -79
  95. package/build/internal/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.http.js.map +0 -1
  96. package/build/internal/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.meta.d.ts +0 -13
  97. package/build/internal/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.meta.js +0 -47
  98. package/build/internal/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.meta.js.map +0 -1
  99. package/build/internal/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.public.d.ts +0 -16
  100. package/build/internal/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.public.js +0 -20
  101. package/build/internal/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.public.js.map +0 -1
  102. package/build/internal/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.types.js +0 -80
  103. package/build/internal/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.types.js.map +0 -1
  104. package/build/internal/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.universal.js +0 -181
  105. package/build/internal/cjs/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.universal.js.map +0 -1
  106. package/build/internal/es/index.d.ts +0 -1
  107. package/build/internal/es/index.js +0 -2
  108. package/build/internal/es/index.js.map +0 -1
  109. package/build/internal/es/index.typings.d.ts +0 -1
  110. package/build/internal/es/index.typings.js +0 -2
  111. package/build/internal/es/index.typings.js.map +0 -1
  112. package/build/internal/es/meta.d.ts +0 -1
  113. package/build/internal/es/meta.js +0 -2
  114. package/build/internal/es/meta.js.map +0 -1
  115. package/build/internal/es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.context.d.ts +0 -5
  116. package/build/internal/es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.context.js +0 -5
  117. package/build/internal/es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.context.js.map +0 -1
  118. package/build/internal/es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.http.d.ts +0 -3
  119. package/build/internal/es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.http.js +0 -75
  120. package/build/internal/es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.http.js.map +0 -1
  121. package/build/internal/es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.meta.d.ts +0 -13
  122. package/build/internal/es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.meta.js +0 -20
  123. package/build/internal/es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.meta.js.map +0 -1
  124. package/build/internal/es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.public.d.ts +0 -16
  125. package/build/internal/es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.public.js +0 -9
  126. package/build/internal/es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.public.js.map +0 -1
  127. package/build/internal/es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.types.js +0 -77
  128. package/build/internal/es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.types.js.map +0 -1
  129. package/build/internal/es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.universal.js +0 -154
  130. package/build/internal/es/src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.universal.js.map +0 -1
@@ -1,20 +1,6 @@
1
- export interface DeliveryRatesGateway {
2
- /**
3
- * @format GUID
4
- * @readonly
5
- */
6
- id?: string | null;
7
- }
8
- export interface MissingDefaultDeliveryProfileEvent {
9
- /**
10
- * The meta site ID where the missing default delivery profile error occurred
11
- * @format GUID
12
- */
13
- metaSiteId?: string;
14
- /** Timestamp when the error occurred */
15
- occurredAt?: Date | null;
16
- }
17
- export interface GetDeliverySolutionsRequest {
1
+ import { d as GetDeliverySolutionsRequest$1, a as GetDeliverySolutionsResponse$1 } from './gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.universal-Dd0MZRrv.js';
2
+
3
+ interface GetDeliverySolutionsRequest {
18
4
  /**
19
5
  * list of items to delivery that each of them points to delivery profile and delivery rule.
20
6
  * @minSize 1
@@ -55,7 +41,7 @@ export interface GetDeliverySolutionsRequest {
55
41
  */
56
42
  externalReferences?: ExternalReference[];
57
43
  }
58
- export interface DeliverableItem {
44
+ interface DeliverableItem {
59
45
  /**
60
46
  * The ID of the line item.
61
47
  * @minLength 1
@@ -109,7 +95,7 @@ export interface DeliverableItem {
109
95
  taxIncludedInPrice?: boolean | null;
110
96
  }
111
97
  /** Used for grouping line items. Sent when an item is added to a cart, checkout, or order. */
112
- export interface CatalogReference {
98
+ interface CatalogReference {
113
99
  /**
114
100
  * ID of the item within the catalog it belongs to.
115
101
  * @minLength 1
@@ -135,7 +121,7 @@ export interface CatalogReference {
135
121
  */
136
122
  options?: Record<string, any> | null;
137
123
  }
138
- export interface PhysicalProperties {
124
+ interface PhysicalProperties {
139
125
  /** Line item weight. Measurement unit matches the weight unit specified in `weightUnit` in the request. */
140
126
  weight?: number | null;
141
127
  /**
@@ -147,7 +133,7 @@ export interface PhysicalProperties {
147
133
  shippable?: boolean;
148
134
  }
149
135
  /** Physical address */
150
- export interface Address extends AddressStreetOneOf {
136
+ interface Address extends AddressStreetOneOf {
151
137
  /** Street name and number. */
152
138
  streetAddress?: StreetAddress;
153
139
  /** Main address line, usually street and number as free text. */
@@ -167,49 +153,20 @@ export interface Address extends AddressStreetOneOf {
167
153
  addressLine2?: string | null;
168
154
  }
169
155
  /** @oneof */
170
- export interface AddressStreetOneOf {
156
+ interface AddressStreetOneOf {
171
157
  /** Street name and number. */
172
158
  streetAddress?: StreetAddress;
173
159
  /** Main address line, usually street and number as free text. */
174
160
  addressLine?: string | null;
175
161
  }
176
- export interface StreetAddress {
162
+ interface StreetAddress {
177
163
  /** Street number. */
178
164
  number?: string;
179
165
  /** Street name. */
180
166
  name?: string;
181
167
  }
182
- export interface AddressLocation {
183
- /** Address latitude. */
184
- latitude?: number | null;
185
- /** Address longitude. */
186
- longitude?: number | null;
187
- }
188
- export interface Subdivision {
189
- /** Short subdivision code. */
190
- code?: string;
191
- /** Subdivision full name. */
192
- name?: string;
193
- }
194
- export declare enum SubdivisionType {
195
- UNKNOWN_SUBDIVISION_TYPE = "UNKNOWN_SUBDIVISION_TYPE",
196
- /** State */
197
- ADMINISTRATIVE_AREA_LEVEL_1 = "ADMINISTRATIVE_AREA_LEVEL_1",
198
- /** County */
199
- ADMINISTRATIVE_AREA_LEVEL_2 = "ADMINISTRATIVE_AREA_LEVEL_2",
200
- /** City/town */
201
- ADMINISTRATIVE_AREA_LEVEL_3 = "ADMINISTRATIVE_AREA_LEVEL_3",
202
- /** Neighborhood/quarter */
203
- ADMINISTRATIVE_AREA_LEVEL_4 = "ADMINISTRATIVE_AREA_LEVEL_4",
204
- /** Street/block */
205
- ADMINISTRATIVE_AREA_LEVEL_5 = "ADMINISTRATIVE_AREA_LEVEL_5",
206
- /** ADMINISTRATIVE_AREA_LEVEL_0. Indicates the national political entity, and is typically the highest order type returned by the Geocoder. */
207
- COUNTRY = "COUNTRY"
208
- }
209
- /** @enumType */
210
- export type SubdivisionTypeWithLiterals = SubdivisionType | 'UNKNOWN_SUBDIVISION_TYPE' | 'ADMINISTRATIVE_AREA_LEVEL_1' | 'ADMINISTRATIVE_AREA_LEVEL_2' | 'ADMINISTRATIVE_AREA_LEVEL_3' | 'ADMINISTRATIVE_AREA_LEVEL_4' | 'ADMINISTRATIVE_AREA_LEVEL_5' | 'COUNTRY';
211
168
  /** Full contact details for an address */
212
- export interface FullAddressContactDetails {
169
+ interface FullAddressContactDetails {
213
170
  /** Contact's first name. */
214
171
  firstName?: string | null;
215
172
  /** Contact's last name. */
@@ -229,7 +186,7 @@ export interface FullAddressContactDetails {
229
186
  /** Tax info. Currently usable only in Brazil. */
230
187
  vatId?: VatId;
231
188
  }
232
- export interface VatId {
189
+ interface VatId {
233
190
  /** Customer's tax ID. */
234
191
  id?: string;
235
192
  /**
@@ -242,7 +199,7 @@ export interface VatId {
242
199
  type?: VatTypeWithLiterals;
243
200
  }
244
201
  /** tax info types */
245
- export declare enum VatType {
202
+ declare enum VatType {
246
203
  UNSPECIFIED = "UNSPECIFIED",
247
204
  /** CPF - for individual tax payers. */
248
205
  CPF = "CPF",
@@ -250,8 +207,8 @@ export declare enum VatType {
250
207
  CNPJ = "CNPJ"
251
208
  }
252
209
  /** @enumType */
253
- export type VatTypeWithLiterals = VatType | 'UNSPECIFIED' | 'CPF' | 'CNPJ';
254
- export declare enum WeightUnit {
210
+ type VatTypeWithLiterals = VatType | 'UNSPECIFIED' | 'CPF' | 'CNPJ';
211
+ declare enum WeightUnit {
255
212
  /** Weight unit can't be classified due to an error. */
256
213
  UNSPECIFIED_WEIGHT_UNIT = "UNSPECIFIED_WEIGHT_UNIT",
257
214
  /** Kilograms. */
@@ -260,8 +217,8 @@ export declare enum WeightUnit {
260
217
  LB = "LB"
261
218
  }
262
219
  /** @enumType */
263
- export type WeightUnitWithLiterals = WeightUnit | 'UNSPECIFIED_WEIGHT_UNIT' | 'KG' | 'LB';
264
- export interface UserPreference {
220
+ type WeightUnitWithLiterals = WeightUnit | 'UNSPECIFIED_WEIGHT_UNIT' | 'KG' | 'LB';
221
+ interface UserPreference {
265
222
  /**
266
223
  * The delivery carrier app id
267
224
  * @format GUID
@@ -273,7 +230,7 @@ export interface UserPreference {
273
230
  */
274
231
  code?: string;
275
232
  }
276
- export interface ExternalReference {
233
+ interface ExternalReference {
277
234
  /**
278
235
  * ID of the app associated with the purchase flow.
279
236
  * For example, the Wix Pay Links app ID.
@@ -294,7 +251,7 @@ export interface ExternalReference {
294
251
  * Each delivery option has a list of items that can be delivered by it - the chosen one
295
252
  * on Errors throw a business error from TC to catch and trigger destination completion
296
253
  */
297
- export interface GetDeliverySolutionsResponse {
254
+ interface GetDeliverySolutionsResponse {
298
255
  /**
299
256
  * Delivery Options with their associated items
300
257
  * @maxSize 300
@@ -306,7 +263,7 @@ export interface GetDeliverySolutionsResponse {
306
263
  */
307
264
  errors?: DeliveryCarrierError[];
308
265
  }
309
- export interface DeliverySolution {
266
+ interface DeliverySolution {
310
267
  /**
311
268
  * Unique code that acts as an ID for a shipping rate. For example, `"usps_std_overnight"`.
312
269
  * @maxLength 250
@@ -330,7 +287,7 @@ export interface DeliverySolution {
330
287
  /** If the delivery solution is a partial and doesn't apply to all items. */
331
288
  partial?: boolean | null;
332
289
  }
333
- export interface DeliveryLogistics {
290
+ interface DeliveryLogistics {
334
291
  /**
335
292
  * When the item is expected to be delivered in free text. For example, `"3-5 business days"`.
336
293
  * @maxLength 1000
@@ -346,7 +303,7 @@ export interface DeliveryLogistics {
346
303
  /** Date and Time of the delivery option */
347
304
  deliveryTimeSlot?: DeliveryTimeSlot;
348
305
  }
349
- export interface PickupDetails {
306
+ interface PickupDetails {
350
307
  /** Pickup address. */
351
308
  address?: Address;
352
309
  /**
@@ -358,20 +315,20 @@ export interface PickupDetails {
358
315
  */
359
316
  pickupMethod?: PickupMethodWithLiterals;
360
317
  }
361
- export declare enum PickupMethod {
318
+ declare enum PickupMethod {
362
319
  UNKNOWN_METHOD = "UNKNOWN_METHOD",
363
320
  STORE_PICKUP = "STORE_PICKUP",
364
321
  PICKUP_POINT = "PICKUP_POINT"
365
322
  }
366
323
  /** @enumType */
367
- export type PickupMethodWithLiterals = PickupMethod | 'UNKNOWN_METHOD' | 'STORE_PICKUP' | 'PICKUP_POINT';
368
- export interface DeliveryTimeSlot {
324
+ type PickupMethodWithLiterals = PickupMethod | 'UNKNOWN_METHOD' | 'STORE_PICKUP' | 'PICKUP_POINT';
325
+ interface DeliveryTimeSlot {
369
326
  /** starting time of the delivery time slot */
370
327
  from?: Date | null;
371
328
  /** ending time of the delivery time slot */
372
329
  to?: Date | null;
373
330
  }
374
- export interface DeliveryCost {
331
+ interface DeliveryCost {
375
332
  /**
376
333
  * The shipping rate's price. Must align with the [currency's decimal separator](https://en.wikipedia.org/wiki/ISO_4217#Active_codes).
377
334
  * @format DECIMAL_VALUE
@@ -389,7 +346,7 @@ export interface DeliveryCost {
389
346
  */
390
347
  additionalCharges?: AdditionalCharge[];
391
348
  }
392
- export interface AdditionalCharge {
349
+ interface AdditionalCharge {
393
350
  /** Additional charge type. */
394
351
  type?: ChargeTypeWithLiterals;
395
352
  /**
@@ -404,12 +361,12 @@ export interface AdditionalCharge {
404
361
  */
405
362
  price?: string;
406
363
  }
407
- export declare enum ChargeType {
364
+ declare enum ChargeType {
408
365
  HANDLING_FEE = "HANDLING_FEE"
409
366
  }
410
367
  /** @enumType */
411
- export type ChargeTypeWithLiterals = ChargeType | 'HANDLING_FEE';
412
- export interface DeliveryAllocation {
368
+ type ChargeTypeWithLiterals = ChargeType | 'HANDLING_FEE';
369
+ interface DeliveryAllocation {
413
370
  /** The delivery option's carrier details, could be multiple if the delivery option is a combination of multiple carriers */
414
371
  deliveryCarrier?: Carrier;
415
372
  /** The delivery region that are relevant for this delivery solution. */
@@ -417,7 +374,7 @@ export interface DeliveryAllocation {
417
374
  /** Populated if the delivery solution is a partially supplied by this carrier. */
418
375
  applicableLineItems?: ApplicableLineItems;
419
376
  }
420
- export interface Carrier {
377
+ interface Carrier {
421
378
  /**
422
379
  * The carrier app id
423
380
  * @format GUID
@@ -429,7 +386,7 @@ export interface Carrier {
429
386
  */
430
387
  code?: string;
431
388
  }
432
- export interface Region {
389
+ interface Region {
433
390
  /**
434
391
  * The delivery region id.
435
392
  * @format GUID
@@ -441,7 +398,7 @@ export interface Region {
441
398
  */
442
399
  name?: string | null;
443
400
  }
444
- export interface ApplicableLineItems {
401
+ interface ApplicableLineItems {
445
402
  /**
446
403
  * Line items that the delivery solution is for.
447
404
  * @maxSize 300
@@ -450,7 +407,7 @@ export interface ApplicableLineItems {
450
407
  */
451
408
  lineItemIds?: string[];
452
409
  }
453
- export interface DeliveryCarrierError {
410
+ interface DeliveryCarrierError {
454
411
  /**
455
412
  * The carrier app id
456
413
  * @format GUID
@@ -459,7 +416,7 @@ export interface DeliveryCarrierError {
459
416
  /** The error details */
460
417
  errorDetails?: Details;
461
418
  }
462
- export interface Details extends DetailsKindOneOf {
419
+ interface Details extends DetailsKindOneOf {
463
420
  applicationError?: ApplicationError;
464
421
  validationError?: ValidationError;
465
422
  systemError?: SystemError;
@@ -470,12 +427,12 @@ export interface Details extends DetailsKindOneOf {
470
427
  tracing?: Record<string, string>;
471
428
  }
472
429
  /** @oneof */
473
- export interface DetailsKindOneOf {
430
+ interface DetailsKindOneOf {
474
431
  applicationError?: ApplicationError;
475
432
  validationError?: ValidationError;
476
433
  systemError?: SystemError;
477
434
  }
478
- export interface ApplicationError {
435
+ interface ApplicationError {
479
436
  /** Error code. */
480
437
  code?: string;
481
438
  /** Description of the error. */
@@ -515,10 +472,10 @@ export interface ApplicationError {
515
472
  * ]
516
473
  * }
517
474
  */
518
- export interface ValidationError {
475
+ interface ValidationError {
519
476
  fieldViolations?: FieldViolation[];
520
477
  }
521
- export declare enum RuleType {
478
+ declare enum RuleType {
522
479
  VALIDATION = "VALIDATION",
523
480
  OTHER = "OTHER",
524
481
  MAX = "MAX",
@@ -542,8 +499,8 @@ export declare enum RuleType {
542
499
  REQUIRED_ONE_OF_FIELD = "REQUIRED_ONE_OF_FIELD"
543
500
  }
544
501
  /** @enumType */
545
- export type RuleTypeWithLiterals = RuleType | 'VALIDATION' | 'OTHER' | 'MAX' | 'MIN' | 'MAX_LENGTH' | 'MIN_LENGTH' | 'MAX_SIZE' | 'MIN_SIZE' | 'FORMAT' | 'DECIMAL_LTE' | 'DECIMAL_GTE' | 'DECIMAL_LT' | 'DECIMAL_GT' | 'DECIMAL_MAX_SCALE' | 'INVALID_ENUM_VALUE' | 'REQUIRED_FIELD' | 'FIELD_NOT_ALLOWED' | 'ONE_OF_ALIGNMENT' | 'EXACT_LENGTH' | 'EXACT_SIZE' | 'REQUIRED_ONE_OF_FIELD';
546
- export interface FieldViolation {
502
+ type RuleTypeWithLiterals = RuleType | 'VALIDATION' | 'OTHER' | 'MAX' | 'MIN' | 'MAX_LENGTH' | 'MIN_LENGTH' | 'MAX_SIZE' | 'MIN_SIZE' | 'FORMAT' | 'DECIMAL_LTE' | 'DECIMAL_GTE' | 'DECIMAL_LT' | 'DECIMAL_GT' | 'DECIMAL_MAX_SCALE' | 'INVALID_ENUM_VALUE' | 'REQUIRED_FIELD' | 'FIELD_NOT_ALLOWED' | 'ONE_OF_ALIGNMENT' | 'EXACT_LENGTH' | 'EXACT_SIZE' | 'REQUIRED_ONE_OF_FIELD';
503
+ interface FieldViolation {
547
504
  field?: string;
548
505
  description?: string;
549
506
  violatedRule?: RuleTypeWithLiterals;
@@ -551,79 +508,21 @@ export interface FieldViolation {
551
508
  ruleName?: string | null;
552
509
  data?: Record<string, any> | null;
553
510
  }
554
- export interface SystemError {
511
+ interface SystemError {
555
512
  /** Error code. */
556
513
  errorCode?: string | null;
557
514
  }
558
- export interface MessageEnvelope {
559
- /**
560
- * App instance ID.
561
- * @format GUID
562
- */
563
- instanceId?: string | null;
564
- /**
565
- * Event type.
566
- * @maxLength 150
567
- */
568
- eventType?: string;
569
- /** The identification type and identity data. */
570
- identity?: IdentificationData;
571
- /** Stringify payload. */
572
- data?: string;
573
- }
574
- export interface IdentificationData extends IdentificationDataIdOneOf {
575
- /**
576
- * ID of a site visitor that has not logged in to the site.
577
- * @format GUID
578
- */
579
- anonymousVisitorId?: string;
580
- /**
581
- * ID of a site visitor that has logged in to the site.
582
- * @format GUID
583
- */
584
- memberId?: string;
585
- /**
586
- * ID of a Wix user (site owner, contributor, etc.).
587
- * @format GUID
588
- */
589
- wixUserId?: string;
590
- /**
591
- * ID of an app.
592
- * @format GUID
593
- */
594
- appId?: string;
595
- /** @readonly */
596
- identityType?: WebhookIdentityTypeWithLiterals;
597
- }
598
- /** @oneof */
599
- export interface IdentificationDataIdOneOf {
600
- /**
601
- * ID of a site visitor that has not logged in to the site.
602
- * @format GUID
603
- */
604
- anonymousVisitorId?: string;
605
- /**
606
- * ID of a site visitor that has logged in to the site.
607
- * @format GUID
608
- */
609
- memberId?: string;
610
- /**
611
- * ID of a Wix user (site owner, contributor, etc.).
612
- * @format GUID
613
- */
614
- wixUserId?: string;
615
- /**
616
- * ID of an app.
617
- * @format GUID
618
- */
619
- appId?: string;
620
- }
621
- export declare enum WebhookIdentityType {
622
- UNKNOWN = "UNKNOWN",
623
- ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR",
624
- MEMBER = "MEMBER",
625
- WIX_USER = "WIX_USER",
626
- APP = "APP"
627
- }
628
- /** @enumType */
629
- export type WebhookIdentityTypeWithLiterals = WebhookIdentityType | 'UNKNOWN' | 'ANONYMOUS_VISITOR' | 'MEMBER' | 'WIX_USER' | 'APP';
515
+
516
+ type __PublicMethodMetaInfo<K = string, M = unknown, T = unknown, S = unknown, Q = unknown, R = unknown> = {
517
+ getUrl: (context: any) => string;
518
+ httpMethod: K;
519
+ path: string;
520
+ pathParams: M;
521
+ __requestType: T;
522
+ __originalRequestType: S;
523
+ __responseType: Q;
524
+ __originalResponseType: R;
525
+ };
526
+ declare function getDeliverySolutions(): __PublicMethodMetaInfo<'POST', {}, GetDeliverySolutionsRequest$1, GetDeliverySolutionsRequest, GetDeliverySolutionsResponse$1, GetDeliverySolutionsResponse>;
527
+
528
+ export { type __PublicMethodMetaInfo, getDeliverySolutions };
package/build/meta.js ADDED
@@ -0,0 +1,127 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __export = (target, all) => {
7
+ for (var name in all)
8
+ __defProp(target, name, { get: all[name], enumerable: true });
9
+ };
10
+ var __copyProps = (to, from, except, desc) => {
11
+ if (from && typeof from === "object" || typeof from === "function") {
12
+ for (let key of __getOwnPropNames(from))
13
+ if (!__hasOwnProp.call(to, key) && key !== except)
14
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
15
+ }
16
+ return to;
17
+ };
18
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
+
20
+ // meta.ts
21
+ var meta_exports = {};
22
+ __export(meta_exports, {
23
+ getDeliverySolutions: () => getDeliverySolutions2
24
+ });
25
+ module.exports = __toCommonJS(meta_exports);
26
+
27
+ // src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.http.ts
28
+ var import_float = require("@wix/sdk-runtime/transformations/float");
29
+ var import_float2 = require("@wix/sdk-runtime/transformations/float");
30
+ var import_timestamp = require("@wix/sdk-runtime/transformations/timestamp");
31
+ var import_transform_paths = require("@wix/sdk-runtime/transformations/transform-paths");
32
+ var import_rest_modules = require("@wix/sdk-runtime/rest-modules");
33
+ function resolveWixEcomDeliveryprofileV1DeliveryRatesUrl(opts) {
34
+ const domainToMappings = {
35
+ "api._api_base_domain_": [
36
+ {
37
+ srcPath: "/delivery-rates",
38
+ destPath: ""
39
+ }
40
+ ],
41
+ _: [
42
+ {
43
+ srcPath: "/_api/delivery-rates",
44
+ destPath: ""
45
+ }
46
+ ]
47
+ };
48
+ return (0, import_rest_modules.resolveUrl)(Object.assign(opts, { domainToMappings }));
49
+ }
50
+ var PACKAGE_NAME = "@wix/auto_sdk_ecom_delivery-solutions";
51
+ function getDeliverySolutions(payload) {
52
+ function __getDeliverySolutions({ host }) {
53
+ const serializedData = (0, import_transform_paths.transformPaths)(payload, [
54
+ {
55
+ transformFn: import_float.transformSDKFloatToRESTFloat,
56
+ paths: [
57
+ { path: "lineItems.physicalProperties.weight" },
58
+ { path: "destination.geocode.latitude" },
59
+ { path: "destination.geocode.longitude" },
60
+ { path: "origin.geocode.latitude" },
61
+ { path: "origin.geocode.longitude" }
62
+ ]
63
+ }
64
+ ]);
65
+ const metadata = {
66
+ entityFqdn: "wix.gateways.ecom.v1.delivery_rates_gateway",
67
+ method: "POST",
68
+ methodFqn: "wix.ecom.deliveryprofile.v1.DeliveryRates.GetDeliverySolutions",
69
+ packageName: PACKAGE_NAME,
70
+ url: resolveWixEcomDeliveryprofileV1DeliveryRatesUrl({
71
+ protoPath: "/v1/get-delivery-solutions",
72
+ data: serializedData,
73
+ host
74
+ }),
75
+ data: serializedData,
76
+ transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
77
+ {
78
+ transformFn: import_float2.transformRESTFloatToSDKFloat,
79
+ paths: [
80
+ {
81
+ path: "deliverySolutions.logistics.pickupDetails.address.geocode.latitude"
82
+ },
83
+ {
84
+ path: "deliverySolutions.logistics.pickupDetails.address.geocode.longitude"
85
+ }
86
+ ]
87
+ },
88
+ {
89
+ transformFn: import_timestamp.transformRESTTimestampToSDKTimestamp,
90
+ paths: [
91
+ { path: "deliverySolutions.logistics.deliveryTimeSlot.from" },
92
+ { path: "deliverySolutions.logistics.deliveryTimeSlot.to" }
93
+ ]
94
+ }
95
+ ])
96
+ };
97
+ return metadata;
98
+ }
99
+ return __getDeliverySolutions;
100
+ }
101
+
102
+ // src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.meta.ts
103
+ function getDeliverySolutions2() {
104
+ const payload = {};
105
+ const getRequestOptions = getDeliverySolutions(
106
+ payload
107
+ );
108
+ const getUrl = (context) => {
109
+ const { url } = getRequestOptions(context);
110
+ return url;
111
+ };
112
+ return {
113
+ getUrl,
114
+ httpMethod: "POST",
115
+ path: "/v1/get-delivery-solutions",
116
+ pathParams: {},
117
+ __requestType: null,
118
+ __originalRequestType: null,
119
+ __responseType: null,
120
+ __originalResponseType: null
121
+ };
122
+ }
123
+ // Annotate the CommonJS export names for ESM import in node:
124
+ 0 && (module.exports = {
125
+ getDeliverySolutions
126
+ });
127
+ //# sourceMappingURL=meta.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../meta.ts","../src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.http.ts","../src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.meta.ts"],"sourcesContent":["export * from './src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.meta.js';\n","import { transformSDKFloatToRESTFloat } from '@wix/sdk-runtime/transformations/float';\nimport { transformRESTFloatToSDKFloat } from '@wix/sdk-runtime/transformations/float';\nimport { transformRESTTimestampToSDKTimestamp } from '@wix/sdk-runtime/transformations/timestamp';\nimport { transformPaths } from '@wix/sdk-runtime/transformations/transform-paths';\nimport { resolveUrl } from '@wix/sdk-runtime/rest-modules';\nimport { ResolveUrlOpts } from '@wix/sdk-runtime/rest-modules';\nimport { RequestOptionsFactory } from '@wix/sdk-types';\n\nfunction resolveWixEcomDeliveryprofileV1DeliveryRatesUrl(\n opts: Omit<ResolveUrlOpts, 'domainToMappings'>\n) {\n const domainToMappings = {\n 'api._api_base_domain_': [\n {\n srcPath: '/delivery-rates',\n destPath: '',\n },\n ],\n _: [\n {\n srcPath: '/_api/delivery-rates',\n destPath: '',\n },\n ],\n };\n\n return resolveUrl(Object.assign(opts, { domainToMappings }));\n}\n\nconst PACKAGE_NAME = '@wix/auto_sdk_ecom_delivery-solutions';\n\n/** Get Delivery Solutions for the given line items from all relevant delivery carriers */\nexport function getDeliverySolutions(\n payload: object\n): RequestOptionsFactory<any> {\n function __getDeliverySolutions({ host }: any) {\n const serializedData = transformPaths(payload, [\n {\n transformFn: transformSDKFloatToRESTFloat,\n paths: [\n { path: 'lineItems.physicalProperties.weight' },\n { path: 'destination.geocode.latitude' },\n { path: 'destination.geocode.longitude' },\n { path: 'origin.geocode.latitude' },\n { path: 'origin.geocode.longitude' },\n ],\n },\n ]);\n const metadata = {\n entityFqdn: 'wix.gateways.ecom.v1.delivery_rates_gateway',\n method: 'POST' as any,\n methodFqn:\n 'wix.ecom.deliveryprofile.v1.DeliveryRates.GetDeliverySolutions',\n packageName: PACKAGE_NAME,\n url: resolveWixEcomDeliveryprofileV1DeliveryRatesUrl({\n protoPath: '/v1/get-delivery-solutions',\n data: serializedData,\n host,\n }),\n data: serializedData,\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTFloatToSDKFloat,\n paths: [\n {\n path: 'deliverySolutions.logistics.pickupDetails.address.geocode.latitude',\n },\n {\n path: 'deliverySolutions.logistics.pickupDetails.address.geocode.longitude',\n },\n ],\n },\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'deliverySolutions.logistics.deliveryTimeSlot.from' },\n { path: 'deliverySolutions.logistics.deliveryTimeSlot.to' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __getDeliverySolutions;\n}\n","import * as ambassadorWixGatewaysEcomV1DeliveryRatesGateway from './gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.http.js';\nimport * as ambassadorWixGatewaysEcomV1DeliveryRatesGatewayTypes from './gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.types.js';\nimport * as ambassadorWixGatewaysEcomV1DeliveryRatesGatewayUniversalTypes from './gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.universal.js';\n\nexport type __PublicMethodMetaInfo<\n K = string,\n M = unknown,\n T = unknown,\n S = unknown,\n Q = unknown,\n R = unknown\n> = {\n getUrl: (context: any) => string;\n httpMethod: K;\n path: string;\n pathParams: M;\n __requestType: T;\n __originalRequestType: S;\n __responseType: Q;\n __originalResponseType: R;\n};\n\nexport function getDeliverySolutions(): __PublicMethodMetaInfo<\n 'POST',\n {},\n ambassadorWixGatewaysEcomV1DeliveryRatesGatewayUniversalTypes.GetDeliverySolutionsRequest,\n ambassadorWixGatewaysEcomV1DeliveryRatesGatewayTypes.GetDeliverySolutionsRequest,\n ambassadorWixGatewaysEcomV1DeliveryRatesGatewayUniversalTypes.GetDeliverySolutionsResponse,\n ambassadorWixGatewaysEcomV1DeliveryRatesGatewayTypes.GetDeliverySolutionsResponse\n> {\n const payload = {} as any;\n\n const getRequestOptions =\n ambassadorWixGatewaysEcomV1DeliveryRatesGateway.getDeliverySolutions(\n payload\n );\n\n const getUrl = (context: any): string => {\n const { url } = getRequestOptions(context);\n return url!;\n };\n\n return {\n getUrl,\n httpMethod: 'POST',\n path: '/v1/get-delivery-solutions',\n pathParams: {},\n __requestType: null as any,\n __originalRequestType: null as any,\n __responseType: null as any,\n __originalResponseType: null as any,\n };\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA,8BAAAA;AAAA;AAAA;;;ACAA,mBAA6C;AAC7C,IAAAC,gBAA6C;AAC7C,uBAAqD;AACrD,6BAA+B;AAC/B,0BAA2B;AAI3B,SAAS,gDACP,MACA;AACA,QAAM,mBAAmB;AAAA,IACvB,yBAAyB;AAAA,MACvB;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,GAAG;AAAA,MACD;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,EACF;AAEA,aAAO,gCAAW,OAAO,OAAO,MAAM,EAAE,iBAAiB,CAAC,CAAC;AAC7D;AAEA,IAAM,eAAe;AAGd,SAAS,qBACd,SAC4B;AAC5B,WAAS,uBAAuB,EAAE,KAAK,GAAQ;AAC7C,UAAM,qBAAiB,uCAAe,SAAS;AAAA,MAC7C;AAAA,QACE,aAAa;AAAA,QACb,OAAO;AAAA,UACL,EAAE,MAAM,sCAAsC;AAAA,UAC9C,EAAE,MAAM,+BAA+B;AAAA,UACvC,EAAE,MAAM,gCAAgC;AAAA,UACxC,EAAE,MAAM,0BAA0B;AAAA,UAClC,EAAE,MAAM,2BAA2B;AAAA,QACrC;AAAA,MACF;AAAA,IACF,CAAC;AACD,UAAM,WAAW;AAAA,MACf,YAAY;AAAA,MACZ,QAAQ;AAAA,MACR,WACE;AAAA,MACF,aAAa;AAAA,MACb,KAAK,gDAAgD;AAAA,QACnD,WAAW;AAAA,QACX,MAAM;AAAA,QACN;AAAA,MACF,CAAC;AAAA,MACD,MAAM;AAAA,MACN,mBAAmB,CAACC,iBAClB,uCAAeA,UAAS;AAAA,QACtB;AAAA,UACE,aAAa;AAAA,UACb,OAAO;AAAA,YACL;AAAA,cACE,MAAM;AAAA,YACR;AAAA,YACA;AAAA,cACE,MAAM;AAAA,YACR;AAAA,UACF;AAAA,QACF;AAAA,QACA;AAAA,UACE,aAAa;AAAA,UACb,OAAO;AAAA,YACL,EAAE,MAAM,oDAAoD;AAAA,YAC5D,EAAE,MAAM,kDAAkD;AAAA,UAC5D;AAAA,QACF;AAAA,MACF,CAAC;AAAA,IACL;AAEA,WAAO;AAAA,EACT;AAEA,SAAO;AACT;;;ACjEO,SAASC,wBAOd;AACA,QAAM,UAAU,CAAC;AAEjB,QAAM,oBAC4C;AAAA,IAC9C;AAAA,EACF;AAEF,QAAM,SAAS,CAAC,YAAyB;AACvC,UAAM,EAAE,IAAI,IAAI,kBAAkB,OAAO;AACzC,WAAO;AAAA,EACT;AAEA,SAAO;AAAA,IACL;AAAA,IACA,YAAY;AAAA,IACZ,MAAM;AAAA,IACN,YAAY,CAAC;AAAA,IACb,eAAe;AAAA,IACf,uBAAuB;AAAA,IACvB,gBAAgB;AAAA,IAChB,wBAAwB;AAAA,EAC1B;AACF;","names":["getDeliverySolutions","import_float","payload","getDeliverySolutions"]}
package/build/meta.mjs ADDED
@@ -0,0 +1,100 @@
1
+ // src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.http.ts
2
+ import { transformSDKFloatToRESTFloat } from "@wix/sdk-runtime/transformations/float";
3
+ import { transformRESTFloatToSDKFloat } from "@wix/sdk-runtime/transformations/float";
4
+ import { transformRESTTimestampToSDKTimestamp } from "@wix/sdk-runtime/transformations/timestamp";
5
+ import { transformPaths } from "@wix/sdk-runtime/transformations/transform-paths";
6
+ import { resolveUrl } from "@wix/sdk-runtime/rest-modules";
7
+ function resolveWixEcomDeliveryprofileV1DeliveryRatesUrl(opts) {
8
+ const domainToMappings = {
9
+ "api._api_base_domain_": [
10
+ {
11
+ srcPath: "/delivery-rates",
12
+ destPath: ""
13
+ }
14
+ ],
15
+ _: [
16
+ {
17
+ srcPath: "/_api/delivery-rates",
18
+ destPath: ""
19
+ }
20
+ ]
21
+ };
22
+ return resolveUrl(Object.assign(opts, { domainToMappings }));
23
+ }
24
+ var PACKAGE_NAME = "@wix/auto_sdk_ecom_delivery-solutions";
25
+ function getDeliverySolutions(payload) {
26
+ function __getDeliverySolutions({ host }) {
27
+ const serializedData = transformPaths(payload, [
28
+ {
29
+ transformFn: transformSDKFloatToRESTFloat,
30
+ paths: [
31
+ { path: "lineItems.physicalProperties.weight" },
32
+ { path: "destination.geocode.latitude" },
33
+ { path: "destination.geocode.longitude" },
34
+ { path: "origin.geocode.latitude" },
35
+ { path: "origin.geocode.longitude" }
36
+ ]
37
+ }
38
+ ]);
39
+ const metadata = {
40
+ entityFqdn: "wix.gateways.ecom.v1.delivery_rates_gateway",
41
+ method: "POST",
42
+ methodFqn: "wix.ecom.deliveryprofile.v1.DeliveryRates.GetDeliverySolutions",
43
+ packageName: PACKAGE_NAME,
44
+ url: resolveWixEcomDeliveryprofileV1DeliveryRatesUrl({
45
+ protoPath: "/v1/get-delivery-solutions",
46
+ data: serializedData,
47
+ host
48
+ }),
49
+ data: serializedData,
50
+ transformResponse: (payload2) => transformPaths(payload2, [
51
+ {
52
+ transformFn: transformRESTFloatToSDKFloat,
53
+ paths: [
54
+ {
55
+ path: "deliverySolutions.logistics.pickupDetails.address.geocode.latitude"
56
+ },
57
+ {
58
+ path: "deliverySolutions.logistics.pickupDetails.address.geocode.longitude"
59
+ }
60
+ ]
61
+ },
62
+ {
63
+ transformFn: transformRESTTimestampToSDKTimestamp,
64
+ paths: [
65
+ { path: "deliverySolutions.logistics.deliveryTimeSlot.from" },
66
+ { path: "deliverySolutions.logistics.deliveryTimeSlot.to" }
67
+ ]
68
+ }
69
+ ])
70
+ };
71
+ return metadata;
72
+ }
73
+ return __getDeliverySolutions;
74
+ }
75
+
76
+ // src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.meta.ts
77
+ function getDeliverySolutions2() {
78
+ const payload = {};
79
+ const getRequestOptions = getDeliverySolutions(
80
+ payload
81
+ );
82
+ const getUrl = (context) => {
83
+ const { url } = getRequestOptions(context);
84
+ return url;
85
+ };
86
+ return {
87
+ getUrl,
88
+ httpMethod: "POST",
89
+ path: "/v1/get-delivery-solutions",
90
+ pathParams: {},
91
+ __requestType: null,
92
+ __originalRequestType: null,
93
+ __responseType: null,
94
+ __originalResponseType: null
95
+ };
96
+ }
97
+ export {
98
+ getDeliverySolutions2 as getDeliverySolutions
99
+ };
100
+ //# sourceMappingURL=meta.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.http.ts","../src/gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.meta.ts"],"sourcesContent":["import { transformSDKFloatToRESTFloat } from '@wix/sdk-runtime/transformations/float';\nimport { transformRESTFloatToSDKFloat } from '@wix/sdk-runtime/transformations/float';\nimport { transformRESTTimestampToSDKTimestamp } from '@wix/sdk-runtime/transformations/timestamp';\nimport { transformPaths } from '@wix/sdk-runtime/transformations/transform-paths';\nimport { resolveUrl } from '@wix/sdk-runtime/rest-modules';\nimport { ResolveUrlOpts } from '@wix/sdk-runtime/rest-modules';\nimport { RequestOptionsFactory } from '@wix/sdk-types';\n\nfunction resolveWixEcomDeliveryprofileV1DeliveryRatesUrl(\n opts: Omit<ResolveUrlOpts, 'domainToMappings'>\n) {\n const domainToMappings = {\n 'api._api_base_domain_': [\n {\n srcPath: '/delivery-rates',\n destPath: '',\n },\n ],\n _: [\n {\n srcPath: '/_api/delivery-rates',\n destPath: '',\n },\n ],\n };\n\n return resolveUrl(Object.assign(opts, { domainToMappings }));\n}\n\nconst PACKAGE_NAME = '@wix/auto_sdk_ecom_delivery-solutions';\n\n/** Get Delivery Solutions for the given line items from all relevant delivery carriers */\nexport function getDeliverySolutions(\n payload: object\n): RequestOptionsFactory<any> {\n function __getDeliverySolutions({ host }: any) {\n const serializedData = transformPaths(payload, [\n {\n transformFn: transformSDKFloatToRESTFloat,\n paths: [\n { path: 'lineItems.physicalProperties.weight' },\n { path: 'destination.geocode.latitude' },\n { path: 'destination.geocode.longitude' },\n { path: 'origin.geocode.latitude' },\n { path: 'origin.geocode.longitude' },\n ],\n },\n ]);\n const metadata = {\n entityFqdn: 'wix.gateways.ecom.v1.delivery_rates_gateway',\n method: 'POST' as any,\n methodFqn:\n 'wix.ecom.deliveryprofile.v1.DeliveryRates.GetDeliverySolutions',\n packageName: PACKAGE_NAME,\n url: resolveWixEcomDeliveryprofileV1DeliveryRatesUrl({\n protoPath: '/v1/get-delivery-solutions',\n data: serializedData,\n host,\n }),\n data: serializedData,\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTFloatToSDKFloat,\n paths: [\n {\n path: 'deliverySolutions.logistics.pickupDetails.address.geocode.latitude',\n },\n {\n path: 'deliverySolutions.logistics.pickupDetails.address.geocode.longitude',\n },\n ],\n },\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'deliverySolutions.logistics.deliveryTimeSlot.from' },\n { path: 'deliverySolutions.logistics.deliveryTimeSlot.to' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __getDeliverySolutions;\n}\n","import * as ambassadorWixGatewaysEcomV1DeliveryRatesGateway from './gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.http.js';\nimport * as ambassadorWixGatewaysEcomV1DeliveryRatesGatewayTypes from './gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.types.js';\nimport * as ambassadorWixGatewaysEcomV1DeliveryRatesGatewayUniversalTypes from './gateways-ecom-v1-delivery-rates-gateway-delivery-solutions.universal.js';\n\nexport type __PublicMethodMetaInfo<\n K = string,\n M = unknown,\n T = unknown,\n S = unknown,\n Q = unknown,\n R = unknown\n> = {\n getUrl: (context: any) => string;\n httpMethod: K;\n path: string;\n pathParams: M;\n __requestType: T;\n __originalRequestType: S;\n __responseType: Q;\n __originalResponseType: R;\n};\n\nexport function getDeliverySolutions(): __PublicMethodMetaInfo<\n 'POST',\n {},\n ambassadorWixGatewaysEcomV1DeliveryRatesGatewayUniversalTypes.GetDeliverySolutionsRequest,\n ambassadorWixGatewaysEcomV1DeliveryRatesGatewayTypes.GetDeliverySolutionsRequest,\n ambassadorWixGatewaysEcomV1DeliveryRatesGatewayUniversalTypes.GetDeliverySolutionsResponse,\n ambassadorWixGatewaysEcomV1DeliveryRatesGatewayTypes.GetDeliverySolutionsResponse\n> {\n const payload = {} as any;\n\n const getRequestOptions =\n ambassadorWixGatewaysEcomV1DeliveryRatesGateway.getDeliverySolutions(\n payload\n );\n\n const getUrl = (context: any): string => {\n const { url } = getRequestOptions(context);\n return url!;\n };\n\n return {\n getUrl,\n httpMethod: 'POST',\n path: '/v1/get-delivery-solutions',\n pathParams: {},\n __requestType: null as any,\n __originalRequestType: null as any,\n __responseType: null as any,\n __originalResponseType: null as any,\n };\n}\n"],"mappings":";AAAA,SAAS,oCAAoC;AAC7C,SAAS,oCAAoC;AAC7C,SAAS,4CAA4C;AACrD,SAAS,sBAAsB;AAC/B,SAAS,kBAAkB;AAI3B,SAAS,gDACP,MACA;AACA,QAAM,mBAAmB;AAAA,IACvB,yBAAyB;AAAA,MACvB;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,GAAG;AAAA,MACD;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,EACF;AAEA,SAAO,WAAW,OAAO,OAAO,MAAM,EAAE,iBAAiB,CAAC,CAAC;AAC7D;AAEA,IAAM,eAAe;AAGd,SAAS,qBACd,SAC4B;AAC5B,WAAS,uBAAuB,EAAE,KAAK,GAAQ;AAC7C,UAAM,iBAAiB,eAAe,SAAS;AAAA,MAC7C;AAAA,QACE,aAAa;AAAA,QACb,OAAO;AAAA,UACL,EAAE,MAAM,sCAAsC;AAAA,UAC9C,EAAE,MAAM,+BAA+B;AAAA,UACvC,EAAE,MAAM,gCAAgC;AAAA,UACxC,EAAE,MAAM,0BAA0B;AAAA,UAClC,EAAE,MAAM,2BAA2B;AAAA,QACrC;AAAA,MACF;AAAA,IACF,CAAC;AACD,UAAM,WAAW;AAAA,MACf,YAAY;AAAA,MACZ,QAAQ;AAAA,MACR,WACE;AAAA,MACF,aAAa;AAAA,MACb,KAAK,gDAAgD;AAAA,QACnD,WAAW;AAAA,QACX,MAAM;AAAA,QACN;AAAA,MACF,CAAC;AAAA,MACD,MAAM;AAAA,MACN,mBAAmB,CAACA,aAClB,eAAeA,UAAS;AAAA,QACtB;AAAA,UACE,aAAa;AAAA,UACb,OAAO;AAAA,YACL;AAAA,cACE,MAAM;AAAA,YACR;AAAA,YACA;AAAA,cACE,MAAM;AAAA,YACR;AAAA,UACF;AAAA,QACF;AAAA,QACA;AAAA,UACE,aAAa;AAAA,UACb,OAAO;AAAA,YACL,EAAE,MAAM,oDAAoD;AAAA,YAC5D,EAAE,MAAM,kDAAkD;AAAA,UAC5D;AAAA,QACF;AAAA,MACF,CAAC;AAAA,IACL;AAEA,WAAO;AAAA,EACT;AAEA,SAAO;AACT;;;ACjEO,SAASC,wBAOd;AACA,QAAM,UAAU,CAAC;AAEjB,QAAM,oBAC4C;AAAA,IAC9C;AAAA,EACF;AAEF,QAAM,SAAS,CAAC,YAAyB;AACvC,UAAM,EAAE,IAAI,IAAI,kBAAkB,OAAO;AACzC,WAAO;AAAA,EACT;AAEA,SAAO;AAAA,IACL;AAAA,IACA,YAAY;AAAA,IACZ,MAAM;AAAA,IACN,YAAY,CAAC;AAAA,IACb,eAAe;AAAA,IACf,uBAAuB;AAAA,IACvB,gBAAgB;AAAA,IAChB,wBAAwB;AAAA,EAC1B;AACF;","names":["payload","getDeliverySolutions"]}