@gofynd/fdk-client-javascript 1.4.15-beta.6 → 1.4.16-beta.1

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 (237) hide show
  1. package/README.md +1 -1
  2. package/package.json +1 -1
  3. package/sdk/application/ApplicationClient.d.ts +2 -0
  4. package/sdk/application/ApplicationClient.js +2 -0
  5. package/sdk/application/Cart/CartApplicationClient.d.ts +68 -48
  6. package/sdk/application/Cart/CartApplicationClient.js +130 -27
  7. package/sdk/application/Catalog/CatalogApplicationClient.d.ts +59 -58
  8. package/sdk/application/Catalog/CatalogApplicationClient.js +30 -29
  9. package/sdk/application/Common/CommonApplicationClient.d.ts +2 -2
  10. package/sdk/application/Common/CommonApplicationClient.js +1 -1
  11. package/sdk/application/Configuration/ConfigurationApplicationClient.d.ts +20 -20
  12. package/sdk/application/Configuration/ConfigurationApplicationClient.js +10 -10
  13. package/sdk/application/Content/ContentApplicationClient.d.ts +19 -30
  14. package/sdk/application/Content/ContentApplicationClient.js +40 -60
  15. package/sdk/application/FileStorage/FileStorageApplicationClient.d.ts +8 -8
  16. package/sdk/application/FileStorage/FileStorageApplicationClient.js +7 -7
  17. package/sdk/application/Finance/FinanceApplicationClient.d.ts +29 -0
  18. package/sdk/application/Finance/FinanceApplicationClient.js +126 -0
  19. package/sdk/application/Lead/LeadApplicationClient.d.ts +2 -2
  20. package/sdk/application/Lead/LeadApplicationClient.js +1 -1
  21. package/sdk/application/Logistic/LogisticApplicationClient.d.ts +35 -15
  22. package/sdk/application/Logistic/LogisticApplicationClient.js +118 -8
  23. package/sdk/application/Order/OrderApplicationClient.d.ts +22 -12
  24. package/sdk/application/Order/OrderApplicationClient.js +62 -8
  25. package/sdk/application/Payment/PaymentApplicationClient.d.ts +87 -87
  26. package/sdk/application/Payment/PaymentApplicationClient.js +65 -46
  27. package/sdk/application/Rewards/RewardsApplicationClient.d.ts +13 -13
  28. package/sdk/application/Rewards/RewardsApplicationClient.js +7 -7
  29. package/sdk/application/Theme/ThemeApplicationClient.d.ts +2 -2
  30. package/sdk/application/Theme/ThemeApplicationClient.js +4 -2
  31. package/sdk/application/User/UserApplicationClient.d.ts +10 -10
  32. package/sdk/application/User/UserApplicationClient.js +6 -6
  33. package/sdk/application/Webhook/WebhookApplicationClient.d.ts +4 -4
  34. package/sdk/application/Webhook/WebhookApplicationClient.js +3 -3
  35. package/sdk/partner/FileStorage/FileStoragePartnerClient.d.ts +86 -12
  36. package/sdk/partner/FileStorage/FileStoragePartnerClient.js +582 -24
  37. package/sdk/partner/FileStorage/FileStoragePartnerModel.d.ts +116 -19
  38. package/sdk/partner/FileStorage/FileStoragePartnerModel.js +121 -14
  39. package/sdk/partner/FileStorage/FileStoragePartnerValidator.d.ts +8 -1
  40. package/sdk/partner/FileStorage/FileStoragePartnerValidator.js +51 -4
  41. package/sdk/partner/Lead/LeadPartnerClient.d.ts +2 -2
  42. package/sdk/partner/Lead/LeadPartnerClient.js +2 -2
  43. package/sdk/partner/Lead/LeadPartnerModel.d.ts +5 -5
  44. package/sdk/partner/Lead/LeadPartnerModel.js +15 -15
  45. package/sdk/partner/Logistics/LogisticsPartnerClient.d.ts +126 -20
  46. package/sdk/partner/Logistics/LogisticsPartnerClient.js +970 -20
  47. package/sdk/partner/Logistics/LogisticsPartnerModel.d.ts +1200 -167
  48. package/sdk/partner/Logistics/LogisticsPartnerModel.js +571 -160
  49. package/sdk/partner/Logistics/LogisticsPartnerValidator.d.ts +10 -0
  50. package/sdk/partner/Logistics/LogisticsPartnerValidator.js +121 -7
  51. package/sdk/partner/Theme/ThemePartnerClient.d.ts +8 -10
  52. package/sdk/partner/Theme/ThemePartnerClient.js +14 -16
  53. package/sdk/partner/Theme/ThemePartnerModel.d.ts +96 -37
  54. package/sdk/partner/Theme/ThemePartnerModel.js +90 -36
  55. package/sdk/partner/Theme/ThemePartnerValidator.js +4 -4
  56. package/sdk/partner/Webhook/WebhookPartnerClient.d.ts +28 -18
  57. package/sdk/partner/Webhook/WebhookPartnerClient.js +103 -18
  58. package/sdk/partner/Webhook/WebhookPartnerModel.d.ts +612 -179
  59. package/sdk/partner/Webhook/WebhookPartnerModel.js +253 -150
  60. package/sdk/partner/Webhook/WebhookPartnerValidator.d.ts +1 -0
  61. package/sdk/partner/Webhook/WebhookPartnerValidator.js +11 -3
  62. package/sdk/platform/Analytics/AnalyticsPlatformApplicationClient.d.ts +5 -4
  63. package/sdk/platform/Analytics/AnalyticsPlatformApplicationClient.js +14 -8
  64. package/sdk/platform/Analytics/AnalyticsPlatformModel.d.ts +59 -9
  65. package/sdk/platform/Analytics/AnalyticsPlatformModel.js +40 -4
  66. package/sdk/platform/AuditTrail/AuditTrailPlatformClient.d.ts +2 -32
  67. package/sdk/platform/AuditTrail/AuditTrailPlatformClient.js +3 -243
  68. package/sdk/platform/AuditTrail/AuditTrailPlatformModel.d.ts +11 -130
  69. package/sdk/platform/AuditTrail/AuditTrailPlatformModel.js +12 -152
  70. package/sdk/platform/AuditTrail/AuditTrailPlatformValidator.d.ts +1 -39
  71. package/sdk/platform/AuditTrail/AuditTrailPlatformValidator.js +0 -35
  72. package/sdk/platform/Billing/BillingPlatformClient.d.ts +12 -12
  73. package/sdk/platform/Billing/BillingPlatformClient.js +15 -15
  74. package/sdk/platform/Billing/BillingPlatformModel.d.ts +443 -388
  75. package/sdk/platform/Billing/BillingPlatformModel.js +280 -263
  76. package/sdk/platform/Billing/BillingPlatformValidator.d.ts +16 -18
  77. package/sdk/platform/Billing/BillingPlatformValidator.js +8 -9
  78. package/sdk/platform/Cart/CartPlatformApplicationClient.d.ts +134 -103
  79. package/sdk/platform/Cart/CartPlatformApplicationClient.js +419 -115
  80. package/sdk/platform/Cart/CartPlatformApplicationValidator.d.ts +121 -65
  81. package/sdk/platform/Cart/CartPlatformApplicationValidator.js +109 -44
  82. package/sdk/platform/Cart/CartPlatformModel.d.ts +5039 -1300
  83. package/sdk/platform/Cart/CartPlatformModel.js +1976 -1217
  84. package/sdk/platform/Catalog/CatalogPlatformApplicationClient.d.ts +209 -183
  85. package/sdk/platform/Catalog/CatalogPlatformApplicationClient.js +452 -395
  86. package/sdk/platform/Catalog/CatalogPlatformApplicationValidator.d.ts +185 -142
  87. package/sdk/platform/Catalog/CatalogPlatformApplicationValidator.js +96 -78
  88. package/sdk/platform/Catalog/CatalogPlatformClient.d.ts +154 -117
  89. package/sdk/platform/Catalog/CatalogPlatformClient.js +292 -172
  90. package/sdk/platform/Catalog/CatalogPlatformModel.d.ts +6941 -2203
  91. package/sdk/platform/Catalog/CatalogPlatformModel.js +3224 -1687
  92. package/sdk/platform/Catalog/CatalogPlatformValidator.d.ts +72 -31
  93. package/sdk/platform/Catalog/CatalogPlatformValidator.js +50 -24
  94. package/sdk/platform/Common/CommonPlatformClient.d.ts +3 -2
  95. package/sdk/platform/Common/CommonPlatformClient.js +3 -2
  96. package/sdk/platform/Common/CommonPlatformModel.d.ts +9 -9
  97. package/sdk/platform/Common/CommonPlatformModel.js +6 -6
  98. package/sdk/platform/Communication/CommunicationPlatformApplicationClient.d.ts +16 -17
  99. package/sdk/platform/Communication/CommunicationPlatformApplicationClient.js +16 -17
  100. package/sdk/platform/Communication/CommunicationPlatformApplicationValidator.d.ts +8 -8
  101. package/sdk/platform/Communication/CommunicationPlatformApplicationValidator.js +8 -8
  102. package/sdk/platform/Communication/CommunicationPlatformModel.d.ts +43 -33
  103. package/sdk/platform/Communication/CommunicationPlatformModel.js +38 -34
  104. package/sdk/platform/CompanyProfile/CompanyProfilePlatformClient.d.ts +46 -42
  105. package/sdk/platform/CompanyProfile/CompanyProfilePlatformClient.js +47 -43
  106. package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.d.ts +223 -223
  107. package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.js +210 -212
  108. package/sdk/platform/CompanyProfile/CompanyProfilePlatformValidator.d.ts +12 -12
  109. package/sdk/platform/CompanyProfile/CompanyProfilePlatformValidator.js +12 -12
  110. package/sdk/platform/Configuration/ConfigurationPlatformApplicationClient.d.ts +46 -33
  111. package/sdk/platform/Configuration/ConfigurationPlatformApplicationClient.js +67 -54
  112. package/sdk/platform/Configuration/ConfigurationPlatformApplicationValidator.d.ts +18 -18
  113. package/sdk/platform/Configuration/ConfigurationPlatformApplicationValidator.js +18 -18
  114. package/sdk/platform/Configuration/ConfigurationPlatformClient.d.ts +45 -24
  115. package/sdk/platform/Configuration/ConfigurationPlatformClient.js +134 -30
  116. package/sdk/platform/Configuration/ConfigurationPlatformModel.d.ts +283 -124
  117. package/sdk/platform/Configuration/ConfigurationPlatformModel.js +219 -94
  118. package/sdk/platform/Configuration/ConfigurationPlatformValidator.d.ts +37 -9
  119. package/sdk/platform/Configuration/ConfigurationPlatformValidator.js +27 -8
  120. package/sdk/platform/Content/ContentPlatformApplicationClient.d.ts +124 -141
  121. package/sdk/platform/Content/ContentPlatformApplicationClient.js +449 -422
  122. package/sdk/platform/Content/ContentPlatformApplicationValidator.d.ts +179 -141
  123. package/sdk/platform/Content/ContentPlatformApplicationValidator.js +168 -130
  124. package/sdk/platform/Content/ContentPlatformClient.d.ts +142 -106
  125. package/sdk/platform/Content/ContentPlatformClient.js +523 -336
  126. package/sdk/platform/Content/ContentPlatformModel.d.ts +1241 -395
  127. package/sdk/platform/Content/ContentPlatformModel.js +521 -390
  128. package/sdk/platform/Content/ContentPlatformValidator.d.ts +168 -117
  129. package/sdk/platform/Content/ContentPlatformValidator.js +162 -108
  130. package/sdk/platform/Discount/DiscountPlatformClient.d.ts +14 -12
  131. package/sdk/platform/Discount/DiscountPlatformClient.js +14 -12
  132. package/sdk/platform/Discount/DiscountPlatformModel.d.ts +13 -13
  133. package/sdk/platform/Discount/DiscountPlatformModel.js +12 -12
  134. package/sdk/platform/Discount/DiscountPlatformValidator.d.ts +2 -2
  135. package/sdk/platform/Discount/DiscountPlatformValidator.js +2 -2
  136. package/sdk/platform/FileStorage/FileStoragePlatformApplicationClient.d.ts +94 -36
  137. package/sdk/platform/FileStorage/FileStoragePlatformApplicationClient.js +462 -60
  138. package/sdk/platform/FileStorage/FileStoragePlatformApplicationValidator.d.ts +62 -15
  139. package/sdk/platform/FileStorage/FileStoragePlatformApplicationValidator.js +75 -13
  140. package/sdk/platform/FileStorage/FileStoragePlatformClient.d.ts +19 -19
  141. package/sdk/platform/FileStorage/FileStoragePlatformClient.js +21 -21
  142. package/sdk/platform/FileStorage/FileStoragePlatformModel.d.ts +370 -101
  143. package/sdk/platform/FileStorage/FileStoragePlatformModel.js +313 -84
  144. package/sdk/platform/FileStorage/FileStoragePlatformValidator.d.ts +6 -6
  145. package/sdk/platform/FileStorage/FileStoragePlatformValidator.js +6 -6
  146. package/sdk/platform/Lead/LeadPlatformClient.d.ts +2 -2
  147. package/sdk/platform/Lead/LeadPlatformClient.js +2 -2
  148. package/sdk/platform/Lead/LeadPlatformModel.d.ts +5 -5
  149. package/sdk/platform/Lead/LeadPlatformModel.js +16 -16
  150. package/sdk/platform/Order/OrderPlatformApplicationClient.d.ts +17 -6
  151. package/sdk/platform/Order/OrderPlatformApplicationClient.js +85 -7
  152. package/sdk/platform/Order/OrderPlatformApplicationValidator.d.ts +95 -24
  153. package/sdk/platform/Order/OrderPlatformApplicationValidator.js +39 -19
  154. package/sdk/platform/Order/OrderPlatformClient.d.ts +153 -96
  155. package/sdk/platform/Order/OrderPlatformClient.js +416 -198
  156. package/sdk/platform/Order/OrderPlatformModel.d.ts +7602 -1269
  157. package/sdk/platform/Order/OrderPlatformModel.js +3926 -1269
  158. package/sdk/platform/Order/OrderPlatformValidator.d.ts +270 -109
  159. package/sdk/platform/Order/OrderPlatformValidator.js +135 -77
  160. package/sdk/platform/Partner/PartnerPlatformApplicationClient.d.ts +6 -4
  161. package/sdk/platform/Partner/PartnerPlatformApplicationClient.js +9 -7
  162. package/sdk/platform/Partner/PartnerPlatformModel.d.ts +9 -9
  163. package/sdk/platform/Partner/PartnerPlatformModel.js +8 -8
  164. package/sdk/platform/Payment/PaymentPlatformApplicationClient.d.ts +93 -105
  165. package/sdk/platform/Payment/PaymentPlatformApplicationClient.js +129 -141
  166. package/sdk/platform/Payment/PaymentPlatformApplicationValidator.d.ts +48 -48
  167. package/sdk/platform/Payment/PaymentPlatformApplicationValidator.js +48 -48
  168. package/sdk/platform/Payment/PaymentPlatformClient.d.ts +20 -20
  169. package/sdk/platform/Payment/PaymentPlatformClient.js +20 -20
  170. package/sdk/platform/Payment/PaymentPlatformModel.d.ts +333 -319
  171. package/sdk/platform/Payment/PaymentPlatformModel.js +288 -278
  172. package/sdk/platform/Payment/PaymentPlatformValidator.d.ts +8 -8
  173. package/sdk/platform/Payment/PaymentPlatformValidator.js +8 -8
  174. package/sdk/platform/PlatformClient.d.ts +0 -2
  175. package/sdk/platform/PlatformClient.js +0 -4
  176. package/sdk/platform/Rewards/RewardsPlatformApplicationClient.d.ts +2 -2
  177. package/sdk/platform/Rewards/RewardsPlatformApplicationClient.js +2 -2
  178. package/sdk/platform/Rewards/RewardsPlatformApplicationValidator.d.ts +2 -2
  179. package/sdk/platform/Rewards/RewardsPlatformApplicationValidator.js +2 -2
  180. package/sdk/platform/Rewards/RewardsPlatformModel.d.ts +9 -9
  181. package/sdk/platform/Rewards/RewardsPlatformModel.js +8 -8
  182. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationClient.d.ts +48 -38
  183. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationClient.js +134 -43
  184. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationValidator.d.ts +46 -17
  185. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationValidator.js +34 -14
  186. package/sdk/platform/Serviceability/ServiceabilityPlatformClient.d.ts +38 -44
  187. package/sdk/platform/Serviceability/ServiceabilityPlatformClient.js +56 -62
  188. package/sdk/platform/Serviceability/ServiceabilityPlatformModel.d.ts +1842 -609
  189. package/sdk/platform/Serviceability/ServiceabilityPlatformModel.js +886 -554
  190. package/sdk/platform/Serviceability/ServiceabilityPlatformValidator.d.ts +42 -46
  191. package/sdk/platform/Serviceability/ServiceabilityPlatformValidator.js +26 -28
  192. package/sdk/platform/Share/SharePlatformApplicationClient.d.ts +2 -2
  193. package/sdk/platform/Share/SharePlatformApplicationClient.js +2 -2
  194. package/sdk/platform/Share/SharePlatformModel.d.ts +36 -5
  195. package/sdk/platform/Share/SharePlatformModel.js +27 -4
  196. package/sdk/platform/Theme/ThemePlatformApplicationClient.d.ts +3 -3
  197. package/sdk/platform/Theme/ThemePlatformApplicationClient.js +8 -4
  198. package/sdk/platform/Theme/ThemePlatformApplicationValidator.d.ts +5 -0
  199. package/sdk/platform/Theme/ThemePlatformApplicationValidator.js +2 -0
  200. package/sdk/platform/Theme/ThemePlatformModel.d.ts +37 -11
  201. package/sdk/platform/Theme/ThemePlatformModel.js +33 -15
  202. package/sdk/platform/User/UserPlatformApplicationClient.d.ts +12 -12
  203. package/sdk/platform/User/UserPlatformApplicationClient.js +12 -12
  204. package/sdk/platform/User/UserPlatformApplicationValidator.d.ts +2 -2
  205. package/sdk/platform/User/UserPlatformApplicationValidator.js +2 -2
  206. package/sdk/platform/User/UserPlatformModel.d.ts +21 -21
  207. package/sdk/platform/User/UserPlatformModel.js +23 -23
  208. package/sdk/platform/Webhook/WebhookPlatformClient.d.ts +25 -78
  209. package/sdk/platform/Webhook/WebhookPlatformClient.js +75 -470
  210. package/sdk/platform/Webhook/WebhookPlatformModel.d.ts +720 -427
  211. package/sdk/platform/Webhook/WebhookPlatformModel.js +410 -386
  212. package/sdk/platform/Webhook/WebhookPlatformValidator.d.ts +10 -55
  213. package/sdk/platform/Webhook/WebhookPlatformValidator.js +12 -72
  214. package/sdk/platform/index.d.ts +0 -1
  215. package/sdk/platform/index.js +0 -2
  216. package/sdk/public/Configuration/ConfigurationPublicClient.d.ts +3 -2
  217. package/sdk/public/Configuration/ConfigurationPublicClient.js +6 -5
  218. package/sdk/public/Configuration/ConfigurationPublicModel.d.ts +9 -9
  219. package/sdk/public/Configuration/ConfigurationPublicModel.js +6 -6
  220. package/sdk/public/Content/ContentPublicClient.d.ts +112 -2
  221. package/sdk/public/Content/ContentPublicClient.js +895 -8
  222. package/sdk/public/Content/ContentPublicModel.d.ts +549 -3
  223. package/sdk/public/Content/ContentPublicModel.js +649 -3
  224. package/sdk/public/Content/ContentPublicValidator.d.ts +69 -3
  225. package/sdk/public/Content/ContentPublicValidator.js +88 -2
  226. package/sdk/public/Webhook/WebhookPublicClient.d.ts +8 -8
  227. package/sdk/public/Webhook/WebhookPublicClient.js +8 -8
  228. package/sdk/public/Webhook/WebhookPublicModel.d.ts +21 -21
  229. package/sdk/public/Webhook/WebhookPublicModel.js +15 -15
  230. package/sdk/public/Webhook/WebhookPublicValidator.d.ts +4 -4
  231. package/sdk/public/Webhook/WebhookPublicValidator.js +4 -4
  232. package/sdk/platform/Finance/FinancePlatformClient.d.ts +0 -320
  233. package/sdk/platform/Finance/FinancePlatformClient.js +0 -2333
  234. package/sdk/platform/Finance/FinancePlatformModel.d.ts +0 -2890
  235. package/sdk/platform/Finance/FinancePlatformModel.js +0 -2148
  236. package/sdk/platform/Finance/FinancePlatformValidator.d.ts +0 -284
  237. package/sdk/platform/Finance/FinancePlatformValidator.js +0 -354
@@ -15,6 +15,7 @@ class Cart {
15
15
  addItems: "/service/application/cart/v1.0/detail",
16
16
  applyCoupon: "/service/application/cart/v1.0/coupon",
17
17
  applyRewardPoints: "/service/application/cart/v1.0/redeem/points/",
18
+ checkoutCart: "/service/application/cart/v1.0/checkout",
18
19
  checkoutCartV2: "/service/application/cart/v2.0/checkout",
19
20
  deleteCart: "/service/application/cart/v1.0/cart_archive",
20
21
  getAddressById: "/service/application/cart/v1.0/address/{id}",
@@ -30,6 +31,7 @@ class Cart {
30
31
  getPromotionOffers: "/service/application/cart/v1.0/available-promotions",
31
32
  getPromotionPaymentOffers:
32
33
  "/service/application/cart/v1.0/available-payment-offers",
34
+ getPromotions: "/service/application/cart/v1.0/promotion",
33
35
  getShipments: "/service/application/cart/v1.0/shipment",
34
36
  removeAddress: "/service/application/cart/v1.0/address/{id}",
35
37
  removeCoupon: "/service/application/cart/v1.0/coupon",
@@ -62,7 +64,7 @@ class Cart {
62
64
  /**
63
65
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
64
66
  * @param {import("../ApplicationAPIClient").Options} - Options
65
- * @returns {Promise<SaveAddressResponse>} - Success response
67
+ * @returns {Promise<SaveAddressResult>} - Success response
66
68
  * @name addAddress
67
69
  * @summary: Creates a new address for a customer
68
70
  * @description: Add a new address to their cart to save details such as name, email, contact information, and address. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/cart/addAddress/).
@@ -107,7 +109,7 @@ class Cart {
107
109
  /**
108
110
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
109
111
  * @param {import("../ApplicationAPIClient").Options} - Options
110
- * @returns {Promise<AddCartDetailResponse>} - Success response
112
+ * @returns {Promise<AddCartDetailResult>} - Success response
111
113
  * @name addItems
112
114
  * @summary: Add items to a cart
113
115
  * @description: Add product items to the customer's existing shopping cart. If there is no existing cart associated with the customer, it creates a new one and adds the items to it. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/cart/addItems/).
@@ -160,7 +162,7 @@ class Cart {
160
162
  /**
161
163
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
162
164
  * @param {import("../ApplicationAPIClient").Options} - Options
163
- * @returns {Promise<CartDetailResponse>} - Success response
165
+ * @returns {Promise<CartDetailResult>} - Success response
164
166
  * @name applyCoupon
165
167
  * @summary: Apply coupon
166
168
  * @description: Apply a coupon code to the cart to trigger discounts on eligible items. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/cart/applyCoupon/).
@@ -213,7 +215,7 @@ class Cart {
213
215
  /**
214
216
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
215
217
  * @param {import("../ApplicationAPIClient").Options} - Options
216
- * @returns {Promise<CartDetailResponse>} - Success response
218
+ * @returns {Promise<CartDetailResult>} - Success response
217
219
  * @name applyRewardPoints
218
220
  * @summary: Use reward points
219
221
  * @description: Users can redeem their accumulated reward points and apply them to the items in their cart, thereby availing discounts on their current purchases. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/cart/applyRewardPoints/).
@@ -262,7 +264,54 @@ class Cart {
262
264
  /**
263
265
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
264
266
  * @param {import("../ApplicationAPIClient").Options} - Options
265
- * @returns {Promise<CartCheckoutResponse>} - Success response
267
+ * @returns {Promise<CartCheckoutResult>} - Success response
268
+ * @name checkoutCart
269
+ * @summary: Checkout cart
270
+ * @description: The checkout cart initiates the order creation process based on the selected address and payment method. It revalidates the cart details to ensure safe and seamless order placement. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/cart/checkoutCart/).
271
+ */
272
+ async checkoutCart(
273
+ { body, buyNow, cartType, requestHeaders } = { requestHeaders: {} },
274
+ { responseHeaders } = { responseHeaders: false }
275
+ ) {
276
+ let invalidInput = [];
277
+ if (invalidInput.length) {
278
+ const error = new Error();
279
+ error.message = "Missing required field";
280
+ error.details = invalidInput;
281
+ return Promise.reject(new FDKClientValidationError(error));
282
+ }
283
+
284
+ const query_params = {};
285
+ query_params["buy_now"] = buyNow;
286
+ query_params["cart_type"] = cartType;
287
+
288
+ const xHeaders = {};
289
+
290
+ const response = await ApplicationAPIClient.execute(
291
+ this._conf,
292
+ "post",
293
+ constructUrl({
294
+ url: this._urls["checkoutCart"],
295
+ params: {},
296
+ }),
297
+ query_params,
298
+ body,
299
+ { ...xHeaders, ...requestHeaders },
300
+ { responseHeaders }
301
+ );
302
+
303
+ let responseData = response;
304
+ if (responseHeaders) {
305
+ responseData = response[0];
306
+ }
307
+
308
+ return response;
309
+ }
310
+
311
+ /**
312
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
313
+ * @param {import("../ApplicationAPIClient").Options} - Options
314
+ * @returns {Promise<CartCheckoutResult>} - Success response
266
315
  * @name checkoutCartV2
267
316
  * @summary: Checkout cart
268
317
  * @description: The checkout cart initiates the order creation process based on the items in the user’s cart, their selected address, and chosen payment methods. It also supports multiple payment method options and revalidates the cart details to ensure a secure and seamless order placement. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/cart/checkoutCartV2/).
@@ -309,7 +358,7 @@ class Cart {
309
358
  /**
310
359
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
311
360
  * @param {import("../ApplicationAPIClient").Options} - Options
312
- * @returns {Promise<DeleteCartDetailResponse>} - Success response
361
+ * @returns {Promise<DeleteCartDetailResult>} - Success response
313
362
  * @name deleteCart
314
363
  * @summary: Delete a cart
315
364
  * @description: Delete all items from the user's cart and resets it to its initial state, providing a clean slate for new selections. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/cart/deleteCart/).
@@ -422,7 +471,7 @@ class Cart {
422
471
  /**
423
472
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
424
473
  * @param {import("../ApplicationAPIClient").Options} - Options
425
- * @returns {Promise<GetAddressesResponse>} - Success response
474
+ * @returns {Promise<GetAddressesResult>} - Success response
426
475
  * @name getAddresses
427
476
  * @summary: Get a list of addresses for a customer
428
477
  * @description: List all addresses saved by the customer, simplifying the checkout process by offering pre-saved address options for delivery. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/cart/getAddresses/).
@@ -481,7 +530,7 @@ class Cart {
481
530
  /**
482
531
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
483
532
  * @param {import("../ApplicationAPIClient").Options} - Options
484
- * @returns {Promise<BulkPriceResponse>} - Success response
533
+ * @returns {Promise<BulkPriceResult>} - Success response
485
534
  * @name getBulkDiscountOffers
486
535
  * @summary: List bulk discounts
487
536
  * @description: List offer discounts with information about quantity and seller. One offer is marked with a "best" flag, indicating it as the best offer among the list. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/cart/getBulkDiscountOffers/).
@@ -530,7 +579,7 @@ class Cart {
530
579
  /**
531
580
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
532
581
  * @param {import("../ApplicationAPIClient").Options} - Options
533
- * @returns {Promise<CartDetailResponse>} - Success response
582
+ * @returns {Promise<CartDetailResult>} - Success response
534
583
  * @name getCart
535
584
  * @summary: Get a cart
536
585
  * @description: Get details of a cart linked to a specific customer using a unique cart ID. It offers an overview of the items, quantities, prices, and other relevant information associated with the cart. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/cart/getCart/).
@@ -639,7 +688,7 @@ class Cart {
639
688
  /**
640
689
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
641
690
  * @param {import("../ApplicationAPIClient").Options} - Options
642
- * @returns {Promise<GetShareCartLinkResponse>} - Success response
691
+ * @returns {Promise<GetShareCartLinkResult>} - Success response
643
692
  * @name getCartShareLink
644
693
  * @summary: Create share cart link
645
694
  * @description: Generate a unique shareable link for the customer's cart for a specific sales channel. This link enables easy sharing of the cart contents with other users, facilitating collaborative shopping experiences. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/cart/getCartShareLink/).
@@ -684,7 +733,7 @@ class Cart {
684
733
  /**
685
734
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
686
735
  * @param {import("../ApplicationAPIClient").Options} - Options
687
- * @returns {Promise<SharedCartResponse>} - Success response
736
+ * @returns {Promise<SharedCartResult>} - Success response
688
737
  * @name getCartSharedItems
689
738
  * @summary: List shared cart items
690
739
  * @description: Get cart items from the shared cart link based on unique token. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/cart/getCartSharedItems/).
@@ -736,7 +785,7 @@ class Cart {
736
785
  /**
737
786
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
738
787
  * @param {import("../ApplicationAPIClient").Options} - Options
739
- * @returns {Promise<GetCouponResponse>} - Success response
788
+ * @returns {Promise<GetCouponResult>} - Success response
740
789
  * @name getCoupons
741
790
  * @summary: List available coupons
742
791
  * @description: List all available coupons that customer can apply to their carts. It provides details about each coupon, including its code, discount amount, and applicable conditions. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/cart/getCoupons/).
@@ -785,7 +834,7 @@ class Cart {
785
834
  /**
786
835
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
787
836
  * @param {import("../ApplicationAPIClient").Options} - Options
788
- * @returns {Promise<CartItemCountResponse>} - Success response
837
+ * @returns {Promise<CartItemCountResult>} - Success response
789
838
  * @name getItemCount
790
839
  * @summary: Get a cart items count
791
840
  * @description: Get total count of items currently present in the customer's cart. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/cart/getItemCount/).
@@ -890,15 +939,21 @@ class Cart {
890
939
  /**
891
940
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
892
941
  * @param {import("../ApplicationAPIClient").Options} - Options
893
- * @returns {Promise<PromotionOffersResponse>} - Success response
942
+ * @returns {Promise<PromotionOffersResult>} - Success response
894
943
  * @name getPromotionOffers
895
944
  * @summary: List available promotion offers
896
945
  * @description: List all promotional offers available for the items in the cart, including details such as offer text, unique promotion ID, and validity period. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/cart/getPromotionOffers/).
897
946
  */
898
947
  async getPromotionOffers(
899
- { slug, pageSize, promotionGroup, storeId, cartType, requestHeaders } = {
900
- requestHeaders: {},
901
- },
948
+ {
949
+ slug,
950
+ pageSize,
951
+ promotionGroup,
952
+ storeId,
953
+ cartType,
954
+ sortBy,
955
+ requestHeaders,
956
+ } = { requestHeaders: {} },
902
957
  { responseHeaders } = { responseHeaders: false }
903
958
  ) {
904
959
  let invalidInput = [];
@@ -915,6 +970,7 @@ class Cart {
915
970
  query_params["promotion_group"] = promotionGroup;
916
971
  query_params["store_id"] = storeId;
917
972
  query_params["cart_type"] = cartType;
973
+ query_params["sort_by"] = sortBy;
918
974
 
919
975
  const xHeaders = {};
920
976
 
@@ -942,7 +998,7 @@ class Cart {
942
998
  /**
943
999
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
944
1000
  * @param {import("../ApplicationAPIClient").Options} - Options
945
- * @returns {Promise<PromotionPaymentOffersResponse>} - Success response
1001
+ * @returns {Promise<PromotionPaymentOffersResult>} - Success response
946
1002
  * @name getPromotionPaymentOffers
947
1003
  * @summary: Fetch available promotions payment offers
948
1004
  * @description: Use this API to get top 5 payment offers available for current product. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/cart/getPromotionPaymentOffers/).
@@ -989,7 +1045,54 @@ class Cart {
989
1045
  /**
990
1046
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
991
1047
  * @param {import("../ApplicationAPIClient").Options} - Options
992
- * @returns {Promise<CartShipmentsResponse>} - Success response
1048
+ * @returns {Promise<Promotions>} - Success response
1049
+ * @name getPromotions
1050
+ * @summary: List all available promotions of the sales channel
1051
+ * @description: List all promotional offers available for the sales channel, including details such as offer text, unique promotion ID, and validity period. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/cart/getPromotions/).
1052
+ */
1053
+ async getPromotions(
1054
+ { pageSize, pageNo, requestHeaders } = { requestHeaders: {} },
1055
+ { responseHeaders } = { responseHeaders: false }
1056
+ ) {
1057
+ let invalidInput = [];
1058
+ if (invalidInput.length) {
1059
+ const error = new Error();
1060
+ error.message = "Missing required field";
1061
+ error.details = invalidInput;
1062
+ return Promise.reject(new FDKClientValidationError(error));
1063
+ }
1064
+
1065
+ const query_params = {};
1066
+ query_params["page_size"] = pageSize;
1067
+ query_params["page_no"] = pageNo;
1068
+
1069
+ const xHeaders = {};
1070
+
1071
+ const response = await ApplicationAPIClient.execute(
1072
+ this._conf,
1073
+ "get",
1074
+ constructUrl({
1075
+ url: this._urls["getPromotions"],
1076
+ params: {},
1077
+ }),
1078
+ query_params,
1079
+ undefined,
1080
+ { ...xHeaders, ...requestHeaders },
1081
+ { responseHeaders }
1082
+ );
1083
+
1084
+ let responseData = response;
1085
+ if (responseHeaders) {
1086
+ responseData = response[0];
1087
+ }
1088
+
1089
+ return response;
1090
+ }
1091
+
1092
+ /**
1093
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
1094
+ * @param {import("../ApplicationAPIClient").Options} - Options
1095
+ * @returns {Promise<CartShipmentsResult>} - Success response
993
1096
  * @name getShipments
994
1097
  * @summary: List shipments
995
1098
  * @description: Get shipment details for the items in a cart, specific to the selected address. Shipment details include delivery promises, seller information, item details, and other relevant information. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/cart/getShipments/).
@@ -1042,7 +1145,7 @@ class Cart {
1042
1145
  /**
1043
1146
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
1044
1147
  * @param {import("../ApplicationAPIClient").Options} - Options
1045
- * @returns {Promise<DeleteAddressResponse>} - Success response
1148
+ * @returns {Promise<DeleteAddressResult>} - Success response
1046
1149
  * @name removeAddress
1047
1150
  * @summary: Removes an address from a customer's address list
1048
1151
  * @description: Delete an existing customer address from the system. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/cart/removeAddress/).
@@ -1094,7 +1197,7 @@ class Cart {
1094
1197
  /**
1095
1198
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
1096
1199
  * @param {import("../ApplicationAPIClient").Options} - Options
1097
- * @returns {Promise<CartDetailResponse>} - Success response
1200
+ * @returns {Promise<CartDetailResult>} - Success response
1098
1201
  * @name removeCoupon
1099
1202
  * @summary: Remove coupon
1100
1203
  * @description: Remove an applied coupon from the customer's cart, thereby removing the associated discount from the cart total. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/cart/removeCoupon/).
@@ -1141,7 +1244,7 @@ class Cart {
1141
1244
  /**
1142
1245
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
1143
1246
  * @param {import("../ApplicationAPIClient").Options} - Options
1144
- * @returns {Promise<CartDetailResponse>} - Success response
1247
+ * @returns {Promise<CartDetailResult>} - Success response
1145
1248
  * @name selectAddress
1146
1249
  * @summary: Select customer address for order processing
1147
1250
  * @description: Select an address from the saved customer addresses and validates the availability of items in the cart. Additionally, it verifies and updates the delivery promise based on the selected address. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/cart/selectAddress/).
@@ -1190,7 +1293,7 @@ class Cart {
1190
1293
  /**
1191
1294
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
1192
1295
  * @param {import("../ApplicationAPIClient").Options} - Options
1193
- * @returns {Promise<CartDetailResponse>} - Success response
1296
+ * @returns {Promise<CartDetailResult>} - Success response
1194
1297
  * @name selectPaymentMode
1195
1298
  * @summary: Select payment mode
1196
1299
  * @description: Select a preferred payment mode from available options during the cart checkout process to securely and efficiently complete their transaction. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/cart/selectPaymentMode/).
@@ -1237,7 +1340,7 @@ class Cart {
1237
1340
  /**
1238
1341
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
1239
1342
  * @param {import("../ApplicationAPIClient").Options} - Options
1240
- * @returns {Promise<UpdateAddressResponse>} - Success response
1343
+ * @returns {Promise<UpdateAddressResult>} - Success response
1241
1344
  * @name updateAddress
1242
1345
  * @summary: Updates an existing customer address
1243
1346
  * @description: Customer can modify the details of a previously saved addresses. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/cart/updateAddress/).
@@ -1289,7 +1392,7 @@ class Cart {
1289
1392
  /**
1290
1393
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
1291
1394
  * @param {import("../ApplicationAPIClient").Options} - Options
1292
- * @returns {Promise<UpdateCartDetailResponse>} - Success response
1395
+ * @returns {Promise<UpdateCartDetailResult>} - Success response
1293
1396
  * @name updateCart
1294
1397
  * @summary: Update cart items
1295
1398
  * @description: Update cart. Customers can modify added product attributes such as quantity and size, as well as remove items from the cart. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/cart/updateCart/).
@@ -1351,7 +1454,7 @@ class Cart {
1351
1454
  /**
1352
1455
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
1353
1456
  * @param {import("../ApplicationAPIClient").Options} - Options
1354
- * @returns {Promise<CartMetaResponse>} - Success response
1457
+ * @returns {Promise<CartMetaResult>} - Success response
1355
1458
  * @name updateCartMeta
1356
1459
  * @summary: Update cart metadata
1357
1460
  * @description: Update metadata associated with a cart, which includes customer preferences, delivery instructions, or any special requirements related to the cart items. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/cart/updateCartMeta/).
@@ -1398,7 +1501,7 @@ class Cart {
1398
1501
  /**
1399
1502
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
1400
1503
  * @param {import("../ApplicationAPIClient").Options} - Options
1401
- * @returns {Promise<SharedCartResponse>} - Success response
1504
+ * @returns {Promise<SharedCartResult>} - Success response
1402
1505
  * @name updateCartWithSharedItems
1403
1506
  * @summary: Update with shared items
1404
1507
  * @description: Merge or replace shared cart items with existing cart. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/cart/updateCartWithSharedItems/).