@gofynd/fdk-client-javascript 1.6.4 → 3.0.0-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 (298) hide show
  1. package/README.md +1 -1
  2. package/package.json +1 -1
  3. package/sdk/application/ApplicationClient.d.ts +0 -2
  4. package/sdk/application/ApplicationClient.js +0 -2
  5. package/sdk/application/Cart/CartApplicationClient.d.ts +113 -93
  6. package/sdk/application/Cart/CartApplicationClient.js +270 -139
  7. package/sdk/application/Catalog/CatalogApplicationClient.d.ts +110 -110
  8. package/sdk/application/Catalog/CatalogApplicationClient.js +122 -138
  9. package/sdk/application/Common/CommonApplicationClient.d.ts +4 -4
  10. package/sdk/application/Common/CommonApplicationClient.js +3 -3
  11. package/sdk/application/Communication/CommunicationApplicationClient.d.ts +43 -3
  12. package/sdk/application/Communication/CommunicationApplicationClient.js +190 -3
  13. package/sdk/application/Configuration/ConfigurationApplicationClient.d.ts +71 -36
  14. package/sdk/application/Configuration/ConfigurationApplicationClient.js +103 -29
  15. package/sdk/application/Content/ContentApplicationClient.d.ts +51 -21
  16. package/sdk/application/Content/ContentApplicationClient.js +197 -36
  17. package/sdk/application/FileStorage/FileStorageApplicationClient.d.ts +6 -6
  18. package/sdk/application/FileStorage/FileStorageApplicationClient.js +3 -3
  19. package/sdk/application/Lead/LeadApplicationClient.d.ts +3 -3
  20. package/sdk/application/Lead/LeadApplicationClient.js +3 -3
  21. package/sdk/application/Logistic/LogisticApplicationClient.d.ts +79 -64
  22. package/sdk/application/Logistic/LogisticApplicationClient.js +246 -264
  23. package/sdk/application/Order/OrderApplicationClient.d.ts +44 -24
  24. package/sdk/application/Order/OrderApplicationClient.js +140 -21
  25. package/sdk/application/Payment/PaymentApplicationClient.d.ts +211 -111
  26. package/sdk/application/Payment/PaymentApplicationClient.js +610 -109
  27. package/sdk/application/Rewards/RewardsApplicationClient.d.ts +13 -13
  28. package/sdk/application/Rewards/RewardsApplicationClient.js +7 -7
  29. package/sdk/application/Share/ShareApplicationClient.d.ts +7 -7
  30. package/sdk/application/Share/ShareApplicationClient.js +14 -14
  31. package/sdk/application/Theme/ThemeApplicationClient.d.ts +23 -3
  32. package/sdk/application/Theme/ThemeApplicationClient.js +103 -5
  33. package/sdk/application/User/UserApplicationClient.d.ts +13 -23
  34. package/sdk/application/User/UserApplicationClient.js +9 -57
  35. package/sdk/application/Webhook/WebhookApplicationClient.d.ts +4 -4
  36. package/sdk/application/Webhook/WebhookApplicationClient.js +3 -3
  37. package/sdk/partner/Authorization/AuthorizationPartnerClient.d.ts +66 -0
  38. package/sdk/partner/Authorization/AuthorizationPartnerClient.js +431 -0
  39. package/sdk/partner/Authorization/AuthorizationPartnerModel.d.ts +231 -0
  40. package/sdk/partner/Authorization/AuthorizationPartnerModel.js +152 -0
  41. package/sdk/partner/Authorization/AuthorizationPartnerValidator.d.ts +8 -0
  42. package/sdk/partner/Authorization/AuthorizationPartnerValidator.js +39 -0
  43. package/sdk/partner/Catalog/CatalogPartnerClient.d.ts +26 -0
  44. package/sdk/partner/Catalog/CatalogPartnerClient.js +173 -0
  45. package/sdk/partner/Catalog/CatalogPartnerModel.d.ts +238 -0
  46. package/sdk/partner/Catalog/CatalogPartnerModel.js +248 -0
  47. package/sdk/partner/Catalog/CatalogPartnerValidator.d.ts +5 -0
  48. package/sdk/partner/Catalog/CatalogPartnerValidator.js +19 -0
  49. package/sdk/partner/FileStorage/FileStoragePartnerClient.d.ts +12 -22
  50. package/sdk/partner/FileStorage/FileStoragePartnerClient.js +12 -87
  51. package/sdk/partner/FileStorage/FileStoragePartnerModel.d.ts +33 -99
  52. package/sdk/partner/FileStorage/FileStoragePartnerModel.js +25 -84
  53. package/sdk/partner/FileStorage/FileStoragePartnerValidator.d.ts +0 -1
  54. package/sdk/partner/FileStorage/FileStoragePartnerValidator.js +4 -10
  55. package/sdk/partner/Lead/LeadPartnerClient.d.ts +5 -5
  56. package/sdk/partner/Lead/LeadPartnerClient.js +4 -4
  57. package/sdk/partner/Lead/LeadPartnerModel.d.ts +100 -49
  58. package/sdk/partner/Lead/LeadPartnerModel.js +100 -74
  59. package/sdk/partner/Lead/LeadPartnerValidator.js +1 -1
  60. package/sdk/partner/Logistics/LogisticsPartnerClient.d.ts +33 -160
  61. package/sdk/partner/Logistics/LogisticsPartnerClient.js +66 -1180
  62. package/sdk/partner/Logistics/LogisticsPartnerModel.d.ts +288 -1685
  63. package/sdk/partner/Logistics/LogisticsPartnerModel.js +226 -824
  64. package/sdk/partner/Logistics/LogisticsPartnerValidator.d.ts +1 -13
  65. package/sdk/partner/Logistics/LogisticsPartnerValidator.js +14 -141
  66. package/sdk/partner/PartnerClient.d.ts +6 -0
  67. package/sdk/partner/PartnerClient.js +9 -0
  68. package/sdk/partner/Payment/PaymentPartnerClient.d.ts +116 -0
  69. package/sdk/partner/Payment/PaymentPartnerClient.js +857 -0
  70. package/sdk/partner/Payment/PaymentPartnerModel.d.ts +388 -0
  71. package/sdk/partner/Payment/PaymentPartnerModel.js +442 -0
  72. package/sdk/partner/Payment/PaymentPartnerValidator.d.ts +14 -0
  73. package/sdk/partner/Payment/PaymentPartnerValidator.js +74 -0
  74. package/sdk/partner/Theme/ThemePartnerClient.d.ts +63 -21
  75. package/sdk/partner/Theme/ThemePartnerClient.js +396 -71
  76. package/sdk/partner/Theme/ThemePartnerModel.d.ts +104 -72
  77. package/sdk/partner/Theme/ThemePartnerModel.js +101 -75
  78. package/sdk/partner/Theme/ThemePartnerValidator.d.ts +5 -1
  79. package/sdk/partner/Theme/ThemePartnerValidator.js +42 -12
  80. package/sdk/partner/Webhook/WebhookPartnerClient.d.ts +18 -18
  81. package/sdk/partner/Webhook/WebhookPartnerClient.js +18 -18
  82. package/sdk/partner/Webhook/WebhookPartnerModel.d.ts +191 -670
  83. package/sdk/partner/Webhook/WebhookPartnerModel.js +159 -268
  84. package/sdk/partner/Webhook/WebhookPartnerValidator.js +3 -3
  85. package/sdk/partner/index.d.ts +3 -0
  86. package/sdk/partner/index.js +6 -0
  87. package/sdk/platform/Analytics/AnalyticsPlatformApplicationValidator.d.ts +1 -4
  88. package/sdk/platform/Analytics/AnalyticsPlatformApplicationValidator.js +1 -1
  89. package/sdk/platform/Analytics/AnalyticsPlatformModel.d.ts +5 -0
  90. package/sdk/platform/Analytics/AnalyticsPlatformModel.js +3 -1
  91. package/sdk/platform/AuditTrail/AuditTrailPlatformClient.d.ts +32 -2
  92. package/sdk/platform/AuditTrail/AuditTrailPlatformClient.js +243 -3
  93. package/sdk/platform/AuditTrail/AuditTrailPlatformModel.d.ts +145 -49
  94. package/sdk/platform/AuditTrail/AuditTrailPlatformModel.js +171 -20
  95. package/sdk/platform/AuditTrail/AuditTrailPlatformValidator.d.ts +39 -1
  96. package/sdk/platform/AuditTrail/AuditTrailPlatformValidator.js +35 -0
  97. package/sdk/platform/Billing/BillingPlatformClient.d.ts +406 -15
  98. package/sdk/platform/Billing/BillingPlatformClient.js +3214 -76
  99. package/sdk/platform/Billing/BillingPlatformModel.d.ts +3798 -459
  100. package/sdk/platform/Billing/BillingPlatformModel.js +2577 -342
  101. package/sdk/platform/Billing/BillingPlatformValidator.d.ts +465 -24
  102. package/sdk/platform/Billing/BillingPlatformValidator.js +490 -14
  103. package/sdk/platform/Cart/CartPlatformApplicationClient.d.ts +284 -205
  104. package/sdk/platform/Cart/CartPlatformApplicationClient.js +671 -553
  105. package/sdk/platform/Cart/CartPlatformApplicationValidator.d.ts +165 -165
  106. package/sdk/platform/Cart/CartPlatformApplicationValidator.js +108 -132
  107. package/sdk/platform/Cart/CartPlatformModel.d.ts +3136 -4788
  108. package/sdk/platform/Cart/CartPlatformModel.js +2850 -2031
  109. package/sdk/platform/Catalog/CatalogPlatformApplicationClient.d.ts +1015 -419
  110. package/sdk/platform/Catalog/CatalogPlatformApplicationClient.js +6450 -2010
  111. package/sdk/platform/Catalog/CatalogPlatformApplicationValidator.d.ts +1121 -230
  112. package/sdk/platform/Catalog/CatalogPlatformApplicationValidator.js +919 -127
  113. package/sdk/platform/Catalog/CatalogPlatformClient.d.ts +372 -574
  114. package/sdk/platform/Catalog/CatalogPlatformClient.js +1238 -1317
  115. package/sdk/platform/Catalog/CatalogPlatformModel.d.ts +8351 -9825
  116. package/sdk/platform/Catalog/CatalogPlatformModel.js +9662 -6881
  117. package/sdk/platform/Catalog/CatalogPlatformValidator.d.ts +288 -235
  118. package/sdk/platform/Catalog/CatalogPlatformValidator.js +241 -183
  119. package/sdk/platform/Common/CommonPlatformClient.d.ts +5 -6
  120. package/sdk/platform/Common/CommonPlatformClient.js +5 -6
  121. package/sdk/platform/Common/CommonPlatformModel.d.ts +9 -9
  122. package/sdk/platform/Common/CommonPlatformModel.js +6 -6
  123. package/sdk/platform/Communication/CommunicationPlatformApplicationClient.d.ts +374 -234
  124. package/sdk/platform/Communication/CommunicationPlatformApplicationClient.js +875 -583
  125. package/sdk/platform/Communication/CommunicationPlatformApplicationValidator.d.ts +170 -139
  126. package/sdk/platform/Communication/CommunicationPlatformApplicationValidator.js +145 -126
  127. package/sdk/platform/Communication/CommunicationPlatformClient.d.ts +56 -3
  128. package/sdk/platform/Communication/CommunicationPlatformClient.js +307 -4
  129. package/sdk/platform/Communication/CommunicationPlatformModel.d.ts +424 -252
  130. package/sdk/platform/Communication/CommunicationPlatformModel.js +540 -320
  131. package/sdk/platform/Communication/CommunicationPlatformValidator.d.ts +62 -3
  132. package/sdk/platform/Communication/CommunicationPlatformValidator.js +48 -2
  133. package/sdk/platform/CompanyProfile/CompanyProfilePlatformClient.d.ts +68 -99
  134. package/sdk/platform/CompanyProfile/CompanyProfilePlatformClient.js +84 -140
  135. package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.d.ts +238 -256
  136. package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.js +222 -244
  137. package/sdk/platform/CompanyProfile/CompanyProfilePlatformValidator.d.ts +20 -20
  138. package/sdk/platform/CompanyProfile/CompanyProfilePlatformValidator.js +20 -20
  139. package/sdk/platform/Configuration/ConfigurationPlatformApplicationClient.d.ts +333 -118
  140. package/sdk/platform/Configuration/ConfigurationPlatformApplicationClient.js +1470 -409
  141. package/sdk/platform/Configuration/ConfigurationPlatformApplicationValidator.d.ts +158 -55
  142. package/sdk/platform/Configuration/ConfigurationPlatformApplicationValidator.js +163 -41
  143. package/sdk/platform/Configuration/ConfigurationPlatformClient.d.ts +151 -61
  144. package/sdk/platform/Configuration/ConfigurationPlatformClient.js +595 -101
  145. package/sdk/platform/Configuration/ConfigurationPlatformModel.d.ts +1199 -462
  146. package/sdk/platform/Configuration/ConfigurationPlatformModel.js +1008 -321
  147. package/sdk/platform/Configuration/ConfigurationPlatformValidator.d.ts +80 -34
  148. package/sdk/platform/Configuration/ConfigurationPlatformValidator.js +79 -24
  149. package/sdk/platform/Content/ContentPlatformApplicationClient.d.ts +253 -140
  150. package/sdk/platform/Content/ContentPlatformApplicationClient.js +1087 -458
  151. package/sdk/platform/Content/ContentPlatformApplicationValidator.d.ts +221 -178
  152. package/sdk/platform/Content/ContentPlatformApplicationValidator.js +220 -157
  153. package/sdk/platform/Content/ContentPlatformClient.d.ts +124 -123
  154. package/sdk/platform/Content/ContentPlatformClient.js +459 -379
  155. package/sdk/platform/Content/ContentPlatformModel.d.ts +833 -1307
  156. package/sdk/platform/Content/ContentPlatformModel.js +893 -582
  157. package/sdk/platform/Content/ContentPlatformValidator.d.ts +140 -150
  158. package/sdk/platform/Content/ContentPlatformValidator.js +131 -135
  159. package/sdk/platform/Discount/DiscountPlatformClient.d.ts +60 -36
  160. package/sdk/platform/Discount/DiscountPlatformClient.js +85 -36
  161. package/sdk/platform/Discount/DiscountPlatformModel.d.ts +46 -47
  162. package/sdk/platform/Discount/DiscountPlatformModel.js +42 -46
  163. package/sdk/platform/Discount/DiscountPlatformValidator.d.ts +2 -2
  164. package/sdk/platform/Discount/DiscountPlatformValidator.js +2 -2
  165. package/sdk/platform/FileStorage/FileStoragePlatformApplicationClient.d.ts +18 -15
  166. package/sdk/platform/FileStorage/FileStoragePlatformApplicationClient.js +24 -22
  167. package/sdk/platform/FileStorage/FileStoragePlatformApplicationValidator.d.ts +4 -4
  168. package/sdk/platform/FileStorage/FileStoragePlatformApplicationValidator.js +4 -4
  169. package/sdk/platform/FileStorage/FileStoragePlatformClient.d.ts +8 -8
  170. package/sdk/platform/FileStorage/FileStoragePlatformClient.js +8 -8
  171. package/sdk/platform/FileStorage/FileStoragePlatformModel.d.ts +75 -86
  172. package/sdk/platform/FileStorage/FileStoragePlatformModel.js +60 -74
  173. package/sdk/platform/FileStorage/FileStoragePlatformValidator.d.ts +6 -6
  174. package/sdk/platform/FileStorage/FileStoragePlatformValidator.js +6 -6
  175. package/sdk/platform/Finance/FinancePlatformClient.d.ts +320 -0
  176. package/sdk/platform/Finance/FinancePlatformClient.js +2333 -0
  177. package/sdk/platform/Finance/FinancePlatformModel.d.ts +2895 -0
  178. package/sdk/platform/Finance/FinancePlatformModel.js +2150 -0
  179. package/sdk/platform/Finance/FinancePlatformValidator.d.ts +284 -0
  180. package/sdk/platform/Finance/FinancePlatformValidator.js +354 -0
  181. package/sdk/platform/Lead/LeadPlatformApplicationClient.d.ts +17 -17
  182. package/sdk/platform/Lead/LeadPlatformApplicationClient.js +33 -33
  183. package/sdk/platform/Lead/LeadPlatformApplicationValidator.d.ts +19 -19
  184. package/sdk/platform/Lead/LeadPlatformApplicationValidator.js +14 -14
  185. package/sdk/platform/Lead/LeadPlatformClient.d.ts +4 -24
  186. package/sdk/platform/Lead/LeadPlatformClient.js +4 -160
  187. package/sdk/platform/Lead/LeadPlatformModel.d.ts +142 -57
  188. package/sdk/platform/Lead/LeadPlatformModel.js +162 -79
  189. package/sdk/platform/Lead/LeadPlatformValidator.d.ts +3 -29
  190. package/sdk/platform/Lead/LeadPlatformValidator.js +2 -28
  191. package/sdk/platform/Order/OrderPlatformApplicationClient.d.ts +94 -25
  192. package/sdk/platform/Order/OrderPlatformApplicationClient.js +600 -57
  193. package/sdk/platform/Order/OrderPlatformApplicationValidator.d.ts +115 -115
  194. package/sdk/platform/Order/OrderPlatformApplicationValidator.js +120 -43
  195. package/sdk/platform/Order/OrderPlatformClient.d.ts +502 -293
  196. package/sdk/platform/Order/OrderPlatformClient.js +1466 -913
  197. package/sdk/platform/Order/OrderPlatformModel.d.ts +4103 -9109
  198. package/sdk/platform/Order/OrderPlatformModel.js +3198 -4245
  199. package/sdk/platform/Order/OrderPlatformValidator.d.ts +445 -612
  200. package/sdk/platform/Order/OrderPlatformValidator.js +316 -326
  201. package/sdk/platform/Partner/PartnerPlatformApplicationClient.d.ts +4 -6
  202. package/sdk/platform/Partner/PartnerPlatformApplicationClient.js +7 -9
  203. package/sdk/platform/Partner/PartnerPlatformModel.d.ts +9 -9
  204. package/sdk/platform/Partner/PartnerPlatformModel.js +7 -7
  205. package/sdk/platform/Payment/PaymentPlatformApplicationClient.d.ts +382 -135
  206. package/sdk/platform/Payment/PaymentPlatformApplicationClient.js +2453 -935
  207. package/sdk/platform/Payment/PaymentPlatformApplicationValidator.d.ts +306 -93
  208. package/sdk/platform/Payment/PaymentPlatformApplicationValidator.js +305 -70
  209. package/sdk/platform/Payment/PaymentPlatformClient.d.ts +66 -56
  210. package/sdk/platform/Payment/PaymentPlatformClient.js +269 -124
  211. package/sdk/platform/Payment/PaymentPlatformModel.d.ts +3525 -1313
  212. package/sdk/platform/Payment/PaymentPlatformModel.js +3813 -1511
  213. package/sdk/platform/Payment/PaymentPlatformValidator.d.ts +64 -35
  214. package/sdk/platform/Payment/PaymentPlatformValidator.js +60 -34
  215. package/sdk/platform/PlatformClient.d.ts +2 -0
  216. package/sdk/platform/PlatformClient.js +4 -0
  217. package/sdk/platform/Rewards/RewardsPlatformApplicationClient.d.ts +2 -2
  218. package/sdk/platform/Rewards/RewardsPlatformApplicationClient.js +2 -2
  219. package/sdk/platform/Rewards/RewardsPlatformApplicationValidator.d.ts +2 -2
  220. package/sdk/platform/Rewards/RewardsPlatformApplicationValidator.js +2 -2
  221. package/sdk/platform/Rewards/RewardsPlatformModel.d.ts +14 -9
  222. package/sdk/platform/Rewards/RewardsPlatformModel.js +10 -8
  223. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationClient.d.ts +344 -56
  224. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationClient.js +2180 -302
  225. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationValidator.d.ts +380 -54
  226. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationValidator.js +336 -37
  227. package/sdk/platform/Serviceability/ServiceabilityPlatformClient.d.ts +127 -213
  228. package/sdk/platform/Serviceability/ServiceabilityPlatformClient.js +538 -1306
  229. package/sdk/platform/Serviceability/ServiceabilityPlatformModel.d.ts +3429 -2979
  230. package/sdk/platform/Serviceability/ServiceabilityPlatformModel.js +3642 -1785
  231. package/sdk/platform/Serviceability/ServiceabilityPlatformValidator.d.ts +218 -392
  232. package/sdk/platform/Serviceability/ServiceabilityPlatformValidator.js +151 -290
  233. package/sdk/platform/Share/SharePlatformApplicationClient.d.ts +4 -16
  234. package/sdk/platform/Share/SharePlatformApplicationClient.js +8 -86
  235. package/sdk/platform/Share/SharePlatformApplicationValidator.d.ts +6 -23
  236. package/sdk/platform/Share/SharePlatformApplicationValidator.js +3 -16
  237. package/sdk/platform/Share/SharePlatformModel.d.ts +6 -50
  238. package/sdk/platform/Share/SharePlatformModel.js +3 -43
  239. package/sdk/platform/Theme/ThemePlatformApplicationClient.d.ts +26 -4
  240. package/sdk/platform/Theme/ThemePlatformApplicationClient.js +157 -10
  241. package/sdk/platform/Theme/ThemePlatformApplicationValidator.d.ts +21 -10
  242. package/sdk/platform/Theme/ThemePlatformApplicationValidator.js +23 -6
  243. package/sdk/platform/Theme/ThemePlatformClient.d.ts +18 -8
  244. package/sdk/platform/Theme/ThemePlatformClient.js +85 -8
  245. package/sdk/platform/Theme/ThemePlatformModel.d.ts +425 -17
  246. package/sdk/platform/Theme/ThemePlatformModel.js +329 -23
  247. package/sdk/platform/Theme/ThemePlatformValidator.d.ts +7 -3
  248. package/sdk/platform/Theme/ThemePlatformValidator.js +9 -2
  249. package/sdk/platform/User/UserPlatformApplicationClient.d.ts +18 -71
  250. package/sdk/platform/User/UserPlatformApplicationClient.js +27 -412
  251. package/sdk/platform/User/UserPlatformApplicationValidator.d.ts +10 -114
  252. package/sdk/platform/User/UserPlatformApplicationValidator.js +7 -80
  253. package/sdk/platform/User/UserPlatformModel.d.ts +216 -264
  254. package/sdk/platform/User/UserPlatformModel.js +209 -216
  255. package/sdk/platform/Webhook/WebhookPlatformClient.d.ts +78 -25
  256. package/sdk/platform/Webhook/WebhookPlatformClient.js +470 -75
  257. package/sdk/platform/Webhook/WebhookPlatformModel.d.ts +428 -810
  258. package/sdk/platform/Webhook/WebhookPlatformModel.js +395 -444
  259. package/sdk/platform/Webhook/WebhookPlatformValidator.d.ts +55 -10
  260. package/sdk/platform/Webhook/WebhookPlatformValidator.js +72 -12
  261. package/sdk/platform/index.d.ts +1 -0
  262. package/sdk/platform/index.js +2 -0
  263. package/sdk/public/Billing/BillingPublicClient.d.ts +56 -0
  264. package/sdk/public/Billing/BillingPublicClient.js +397 -0
  265. package/sdk/public/Billing/BillingPublicModel.d.ts +919 -0
  266. package/sdk/public/Billing/BillingPublicModel.js +560 -0
  267. package/sdk/public/Billing/BillingPublicValidator.d.ts +43 -0
  268. package/sdk/public/Billing/BillingPublicValidator.js +50 -0
  269. package/sdk/public/Configuration/ConfigurationPublicClient.d.ts +14 -4
  270. package/sdk/public/Configuration/ConfigurationPublicClient.js +97 -9
  271. package/sdk/public/Configuration/ConfigurationPublicModel.d.ts +102 -40
  272. package/sdk/public/Configuration/ConfigurationPublicModel.js +111 -29
  273. package/sdk/public/Configuration/ConfigurationPublicValidator.d.ts +11 -1
  274. package/sdk/public/Configuration/ConfigurationPublicValidator.js +12 -0
  275. package/sdk/public/Content/ContentPublicClient.d.ts +22 -0
  276. package/sdk/public/Content/ContentPublicClient.js +183 -0
  277. package/sdk/public/Content/ContentPublicModel.d.ts +38 -1
  278. package/sdk/public/Content/ContentPublicModel.js +47 -1
  279. package/sdk/public/Content/ContentPublicValidator.d.ts +17 -1
  280. package/sdk/public/Content/ContentPublicValidator.js +19 -0
  281. package/sdk/public/PublicClient.d.ts +2 -2
  282. package/sdk/public/PublicClient.js +2 -2
  283. package/sdk/public/Webhook/WebhookPublicClient.d.ts +8 -8
  284. package/sdk/public/Webhook/WebhookPublicClient.js +8 -8
  285. package/sdk/public/Webhook/WebhookPublicModel.d.ts +67 -215
  286. package/sdk/public/Webhook/WebhookPublicModel.js +61 -66
  287. package/sdk/public/Webhook/WebhookPublicValidator.d.ts +4 -4
  288. package/sdk/public/Webhook/WebhookPublicValidator.js +4 -4
  289. package/sdk/public/index.d.ts +1 -1
  290. package/sdk/public/index.js +1 -1
  291. package/sdk/application/Finance/FinanceApplicationClient.d.ts +0 -29
  292. package/sdk/application/Finance/FinanceApplicationClient.js +0 -126
  293. package/sdk/public/Catalog/CatalogPublicClient.d.ts +0 -22
  294. package/sdk/public/Catalog/CatalogPublicClient.js +0 -138
  295. package/sdk/public/Catalog/CatalogPublicModel.d.ts +0 -155
  296. package/sdk/public/Catalog/CatalogPublicModel.js +0 -116
  297. package/sdk/public/Catalog/CatalogPublicValidator.d.ts +0 -55
  298. package/sdk/public/Catalog/CatalogPublicValidator.js +0 -35
@@ -16,25 +16,23 @@ class Serviceability {
16
16
  }
17
17
 
18
18
  /**
19
- * @param {ServiceabilityPlatformApplicationValidator.CreateCourierPartnerRuleParam} arg
19
+ * @param {ServiceabilityPlatformApplicationValidator.CreateBulkExportParam} arg
20
20
  * - Arg object
21
21
  *
22
22
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
23
23
  * @param {import("../PlatformAPIClient").Options} - Options
24
- * @returns {Promise<ServiceabilityPlatformModel.CourierPartnerRuleResult>}
25
- * - Success response
26
- *
27
- * @name createCourierPartnerRule
28
- * @summary: Create courier rule
29
- * @description: Creates a rule within the delivery configuration. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/createCourierPartnerRule/).
24
+ * @returns {Promise<ServiceabilityPlatformModel.ZoneBulkExport>} - Success response
25
+ * @name createBulkExport
26
+ * @summary: Create Bulk Export of Zones
27
+ * @description: Export zones defined at the application level. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/createBulkExport/).
30
28
  */
31
- async createCourierPartnerRule(
29
+ async createBulkExport(
32
30
  { body, requestHeaders } = { requestHeaders: {} },
33
31
  { responseHeaders } = { responseHeaders: false }
34
32
  ) {
35
33
  const {
36
34
  error,
37
- } = ServiceabilityPlatformApplicationValidator.createCourierPartnerRule().validate(
35
+ } = ServiceabilityPlatformApplicationValidator.createBulkExport().validate(
38
36
  {
39
37
  body,
40
38
  },
@@ -47,7 +45,7 @@ class Serviceability {
47
45
  // Showing warrnings if extra unknown parameters are found
48
46
  const {
49
47
  error: warrning,
50
- } = ServiceabilityPlatformApplicationValidator.createCourierPartnerRule().validate(
48
+ } = ServiceabilityPlatformApplicationValidator.createBulkExport().validate(
51
49
  {
52
50
  body,
53
51
  },
@@ -56,7 +54,7 @@ class Serviceability {
56
54
  if (warrning) {
57
55
  Logger({
58
56
  level: "WARN",
59
- message: `Parameter Validation warrnings for platform > Serviceability > createCourierPartnerRule \n ${warrning}`,
57
+ message: `Parameter Validation warrnings for platform > Serviceability > createBulkExport \n ${warrning}`,
60
58
  });
61
59
  }
62
60
 
@@ -65,7 +63,7 @@ class Serviceability {
65
63
  const response = await PlatformAPIClient.execute(
66
64
  this.config,
67
65
  "post",
68
- `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/courier-partner/rules`,
66
+ `/service/platform/logistics/v2.0/company/${this.config.companyId}/application/${this.applicationId}/zones/bulk/export`,
69
67
  query_params,
70
68
  body,
71
69
  requestHeaders,
@@ -79,10 +77,10 @@ class Serviceability {
79
77
 
80
78
  const {
81
79
  error: res_error,
82
- } = ServiceabilityPlatformModel.CourierPartnerRuleResult().validate(
83
- responseData,
84
- { abortEarly: false, allowUnknown: true }
85
- );
80
+ } = ServiceabilityPlatformModel.ZoneBulkExport().validate(responseData, {
81
+ abortEarly: false,
82
+ allowUnknown: true,
83
+ });
86
84
 
87
85
  if (res_error) {
88
86
  if (this.config.options.strictResponseCheck === true) {
@@ -90,7 +88,7 @@ class Serviceability {
90
88
  } else {
91
89
  Logger({
92
90
  level: "WARN",
93
- message: `Response Validation Warnings for platform > Serviceability > createCourierPartnerRule \n ${res_error}`,
91
+ message: `Response Validation Warnings for platform > Serviceability > createBulkExport \n ${res_error}`,
94
92
  });
95
93
  }
96
94
  }
@@ -99,24 +97,24 @@ class Serviceability {
99
97
  }
100
98
 
101
99
  /**
102
- * @param {ServiceabilityPlatformApplicationValidator.CreateStoreRulesParam} arg
100
+ * @param {ServiceabilityPlatformApplicationValidator.CreateBulkGeoAreaParam} arg
103
101
  * - Arg object
104
102
  *
105
103
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
106
104
  * @param {import("../PlatformAPIClient").Options} - Options
107
- * @returns {Promise<ServiceabilityPlatformModel.StoreRuleResultSchema>} -
105
+ * @returns {Promise<ServiceabilityPlatformModel.BulkGeoAreaResult>} -
108
106
  * Success response
109
- * @name createStoreRules
110
- * @summary: Create store rule
111
- * @description: Create a rule within the order routing rules - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/createStoreRules/).
107
+ * @name createBulkGeoArea
108
+ * @summary: Bulk Creation of GeoArea Regions
109
+ * @description: Allows to create and manage GeoAreas, representing groups of geographic regions in bulk. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/createBulkGeoArea/).
112
110
  */
113
- async createStoreRules(
111
+ async createBulkGeoArea(
114
112
  { body, requestHeaders } = { requestHeaders: {} },
115
113
  { responseHeaders } = { responseHeaders: false }
116
114
  ) {
117
115
  const {
118
116
  error,
119
- } = ServiceabilityPlatformApplicationValidator.createStoreRules().validate(
117
+ } = ServiceabilityPlatformApplicationValidator.createBulkGeoArea().validate(
120
118
  {
121
119
  body,
122
120
  },
@@ -129,7 +127,7 @@ class Serviceability {
129
127
  // Showing warrnings if extra unknown parameters are found
130
128
  const {
131
129
  error: warrning,
132
- } = ServiceabilityPlatformApplicationValidator.createStoreRules().validate(
130
+ } = ServiceabilityPlatformApplicationValidator.createBulkGeoArea().validate(
133
131
  {
134
132
  body,
135
133
  },
@@ -138,7 +136,7 @@ class Serviceability {
138
136
  if (warrning) {
139
137
  Logger({
140
138
  level: "WARN",
141
- message: `Parameter Validation warrnings for platform > Serviceability > createStoreRules \n ${warrning}`,
139
+ message: `Parameter Validation warrnings for platform > Serviceability > createBulkGeoArea \n ${warrning}`,
142
140
  });
143
141
  }
144
142
 
@@ -147,7 +145,7 @@ class Serviceability {
147
145
  const response = await PlatformAPIClient.execute(
148
146
  this.config,
149
147
  "post",
150
- `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/store/rules`,
148
+ `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/geoareas/regions/bulk`,
151
149
  query_params,
152
150
  body,
153
151
  requestHeaders,
@@ -161,10 +159,10 @@ class Serviceability {
161
159
 
162
160
  const {
163
161
  error: res_error,
164
- } = ServiceabilityPlatformModel.StoreRuleResultSchema().validate(
165
- responseData,
166
- { abortEarly: false, allowUnknown: true }
167
- );
162
+ } = ServiceabilityPlatformModel.BulkGeoAreaResult().validate(responseData, {
163
+ abortEarly: false,
164
+ allowUnknown: true,
165
+ });
168
166
 
169
167
  if (res_error) {
170
168
  if (this.config.options.strictResponseCheck === true) {
@@ -172,7 +170,7 @@ class Serviceability {
172
170
  } else {
173
171
  Logger({
174
172
  level: "WARN",
175
- message: `Response Validation Warnings for platform > Serviceability > createStoreRules \n ${res_error}`,
173
+ message: `Response Validation Warnings for platform > Serviceability > createBulkGeoArea \n ${res_error}`,
176
174
  });
177
175
  }
178
176
  }
@@ -181,25 +179,27 @@ class Serviceability {
181
179
  }
182
180
 
183
181
  /**
184
- * @param {ServiceabilityPlatformApplicationValidator.GetApplicationConfigParam} arg
182
+ * @param {ServiceabilityPlatformApplicationValidator.CreateBulkZoneParam} arg
185
183
  * - Arg object
186
184
  *
187
185
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
188
186
  * @param {import("../PlatformAPIClient").Options} - Options
189
- * @returns {Promise<ServiceabilityPlatformModel.StoreRuleConfigData>} -
187
+ * @returns {Promise<ServiceabilityPlatformModel.CreateBulkZoneResponse>} -
190
188
  * Success response
191
- * @name getApplicationConfig
192
- * @summary: Get store rule configuration
193
- * @description: Retrieves information about the order routing setup for a single application - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/getApplicationConfig/).
189
+ * @name createBulkZone
190
+ * @summary: Create bulk zones.
191
+ * @description: Creates bulk zones defined at the application level. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/createBulkZone/).
194
192
  */
195
- async getApplicationConfig(
196
- { requestHeaders } = { requestHeaders: {} },
193
+ async createBulkZone(
194
+ { body, requestHeaders } = { requestHeaders: {} },
197
195
  { responseHeaders } = { responseHeaders: false }
198
196
  ) {
199
197
  const {
200
198
  error,
201
- } = ServiceabilityPlatformApplicationValidator.getApplicationConfig().validate(
202
- {},
199
+ } = ServiceabilityPlatformApplicationValidator.createBulkZone().validate(
200
+ {
201
+ body,
202
+ },
203
203
  { abortEarly: false, allowUnknown: true }
204
204
  );
205
205
  if (error) {
@@ -209,14 +209,16 @@ class Serviceability {
209
209
  // Showing warrnings if extra unknown parameters are found
210
210
  const {
211
211
  error: warrning,
212
- } = ServiceabilityPlatformApplicationValidator.getApplicationConfig().validate(
213
- {},
212
+ } = ServiceabilityPlatformApplicationValidator.createBulkZone().validate(
213
+ {
214
+ body,
215
+ },
214
216
  { abortEarly: false, allowUnknown: false }
215
217
  );
216
218
  if (warrning) {
217
219
  Logger({
218
220
  level: "WARN",
219
- message: `Parameter Validation warrnings for platform > Serviceability > getApplicationConfig \n ${warrning}`,
221
+ message: `Parameter Validation warrnings for platform > Serviceability > createBulkZone \n ${warrning}`,
220
222
  });
221
223
  }
222
224
 
@@ -224,10 +226,10 @@ class Serviceability {
224
226
 
225
227
  const response = await PlatformAPIClient.execute(
226
228
  this.config,
227
- "get",
228
- `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/store/configuration`,
229
+ "post",
230
+ `/service/platform/logistics/v2.0/company/${this.config.companyId}/application/${this.applicationId}/zones/bulk`,
229
231
  query_params,
230
- undefined,
232
+ body,
231
233
  requestHeaders,
232
234
  { responseHeaders }
233
235
  );
@@ -239,7 +241,7 @@ class Serviceability {
239
241
 
240
242
  const {
241
243
  error: res_error,
242
- } = ServiceabilityPlatformModel.StoreRuleConfigData().validate(
244
+ } = ServiceabilityPlatformModel.CreateBulkZoneResponse().validate(
243
245
  responseData,
244
246
  { abortEarly: false, allowUnknown: true }
245
247
  );
@@ -250,7 +252,7 @@ class Serviceability {
250
252
  } else {
251
253
  Logger({
252
254
  level: "WARN",
253
- message: `Response Validation Warnings for platform > Serviceability > getApplicationConfig \n ${res_error}`,
255
+ message: `Response Validation Warnings for platform > Serviceability > createBulkZone \n ${res_error}`,
254
256
  });
255
257
  }
256
258
  }
@@ -259,25 +261,28 @@ class Serviceability {
259
261
  }
260
262
 
261
263
  /**
262
- * @param {ServiceabilityPlatformApplicationValidator.GetApplicationConfigurationParam} arg
264
+ * @param {ServiceabilityPlatformApplicationValidator.CreateCourierPartnerRuleParam} arg
263
265
  * - Arg object
264
266
  *
265
267
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
266
268
  * @param {import("../PlatformAPIClient").Options} - Options
267
- * @returns {Promise<ServiceabilityPlatformModel.ApplicationConfig>} -
268
- * Success response
269
- * @name getApplicationConfiguration
270
- * @summary: Get delivery configuration
271
- * @description: Retrieves information about the delivery setup for an application - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/getApplicationConfiguration/).
269
+ * @returns {Promise<ServiceabilityPlatformModel.CourierPartnerRuleResponseSchema>}
270
+ * - Success response
271
+ *
272
+ * @name createCourierPartnerRule
273
+ * @summary: Create courier rule
274
+ * @description: Creates a rule within the delivery configuration. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/createCourierPartnerRule/).
272
275
  */
273
- async getApplicationConfiguration(
274
- { requestHeaders } = { requestHeaders: {} },
276
+ async createCourierPartnerRule(
277
+ { body, requestHeaders } = { requestHeaders: {} },
275
278
  { responseHeaders } = { responseHeaders: false }
276
279
  ) {
277
280
  const {
278
281
  error,
279
- } = ServiceabilityPlatformApplicationValidator.getApplicationConfiguration().validate(
280
- {},
282
+ } = ServiceabilityPlatformApplicationValidator.createCourierPartnerRule().validate(
283
+ {
284
+ body,
285
+ },
281
286
  { abortEarly: false, allowUnknown: true }
282
287
  );
283
288
  if (error) {
@@ -287,14 +292,16 @@ class Serviceability {
287
292
  // Showing warrnings if extra unknown parameters are found
288
293
  const {
289
294
  error: warrning,
290
- } = ServiceabilityPlatformApplicationValidator.getApplicationConfiguration().validate(
291
- {},
295
+ } = ServiceabilityPlatformApplicationValidator.createCourierPartnerRule().validate(
296
+ {
297
+ body,
298
+ },
292
299
  { abortEarly: false, allowUnknown: false }
293
300
  );
294
301
  if (warrning) {
295
302
  Logger({
296
303
  level: "WARN",
297
- message: `Parameter Validation warrnings for platform > Serviceability > getApplicationConfiguration \n ${warrning}`,
304
+ message: `Parameter Validation warrnings for platform > Serviceability > createCourierPartnerRule \n ${warrning}`,
298
305
  });
299
306
  }
300
307
 
@@ -302,10 +309,10 @@ class Serviceability {
302
309
 
303
310
  const response = await PlatformAPIClient.execute(
304
311
  this.config,
305
- "get",
306
- `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/configuration`,
312
+ "post",
313
+ `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/courier-partner/rules`,
307
314
  query_params,
308
- undefined,
315
+ body,
309
316
  requestHeaders,
310
317
  { responseHeaders }
311
318
  );
@@ -317,10 +324,10 @@ class Serviceability {
317
324
 
318
325
  const {
319
326
  error: res_error,
320
- } = ServiceabilityPlatformModel.ApplicationConfig().validate(responseData, {
321
- abortEarly: false,
322
- allowUnknown: true,
323
- });
327
+ } = ServiceabilityPlatformModel.CourierPartnerRuleResponseSchema().validate(
328
+ responseData,
329
+ { abortEarly: false, allowUnknown: true }
330
+ );
324
331
 
325
332
  if (res_error) {
326
333
  if (this.config.options.strictResponseCheck === true) {
@@ -328,7 +335,7 @@ class Serviceability {
328
335
  } else {
329
336
  Logger({
330
337
  level: "WARN",
331
- message: `Response Validation Warnings for platform > Serviceability > getApplicationConfiguration \n ${res_error}`,
338
+ message: `Response Validation Warnings for platform > Serviceability > createCourierPartnerRule \n ${res_error}`,
332
339
  });
333
340
  }
334
341
  }
@@ -337,26 +344,27 @@ class Serviceability {
337
344
  }
338
345
 
339
346
  /**
340
- * @param {ServiceabilityPlatformApplicationValidator.GetApplicationServiceabilitySelfShipmentParam} arg
347
+ * @param {ServiceabilityPlatformApplicationValidator.CreateGeoAreaParam} arg
341
348
  * - Arg object
342
349
  *
343
350
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
344
351
  * @param {import("../PlatformAPIClient").Options} - Options
345
- * @returns {Promise<ServiceabilityPlatformModel.ApplicationSelfShipConfigResult>}
346
- * - Success response
347
- *
348
- * @name getApplicationServiceabilitySelfShipment
349
- * @summary: Get self ship configuration
350
- * @description: Retrieves the self ship setup for a single application - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/getApplicationServiceabilitySelfShipment/).
352
+ * @returns {Promise<ServiceabilityPlatformModel.GeoAreaResponseBody>} -
353
+ * Success response
354
+ * @name createGeoArea
355
+ * @summary: Creation of GeoArea
356
+ * @description: Allows to create and manage GeoAreas, representing groups of geographic regions. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/createGeoArea/).
351
357
  */
352
- async getApplicationServiceabilitySelfShipment(
353
- { requestHeaders } = { requestHeaders: {} },
358
+ async createGeoArea(
359
+ { body, requestHeaders } = { requestHeaders: {} },
354
360
  { responseHeaders } = { responseHeaders: false }
355
361
  ) {
356
362
  const {
357
363
  error,
358
- } = ServiceabilityPlatformApplicationValidator.getApplicationServiceabilitySelfShipment().validate(
359
- {},
364
+ } = ServiceabilityPlatformApplicationValidator.createGeoArea().validate(
365
+ {
366
+ body,
367
+ },
360
368
  { abortEarly: false, allowUnknown: true }
361
369
  );
362
370
  if (error) {
@@ -366,14 +374,16 @@ class Serviceability {
366
374
  // Showing warrnings if extra unknown parameters are found
367
375
  const {
368
376
  error: warrning,
369
- } = ServiceabilityPlatformApplicationValidator.getApplicationServiceabilitySelfShipment().validate(
370
- {},
377
+ } = ServiceabilityPlatformApplicationValidator.createGeoArea().validate(
378
+ {
379
+ body,
380
+ },
371
381
  { abortEarly: false, allowUnknown: false }
372
382
  );
373
383
  if (warrning) {
374
384
  Logger({
375
385
  level: "WARN",
376
- message: `Parameter Validation warrnings for platform > Serviceability > getApplicationServiceabilitySelfShipment \n ${warrning}`,
386
+ message: `Parameter Validation warrnings for platform > Serviceability > createGeoArea \n ${warrning}`,
377
387
  });
378
388
  }
379
389
 
@@ -381,10 +391,10 @@ class Serviceability {
381
391
 
382
392
  const response = await PlatformAPIClient.execute(
383
393
  this.config,
384
- "get",
385
- `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/selfship`,
394
+ "post",
395
+ `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/geoareas`,
386
396
  query_params,
387
- undefined,
397
+ body,
388
398
  requestHeaders,
389
399
  { responseHeaders }
390
400
  );
@@ -396,7 +406,7 @@ class Serviceability {
396
406
 
397
407
  const {
398
408
  error: res_error,
399
- } = ServiceabilityPlatformModel.ApplicationSelfShipConfigResult().validate(
409
+ } = ServiceabilityPlatformModel.GeoAreaResponseBody().validate(
400
410
  responseData,
401
411
  { abortEarly: false, allowUnknown: true }
402
412
  );
@@ -407,7 +417,7 @@ class Serviceability {
407
417
  } else {
408
418
  Logger({
409
419
  level: "WARN",
410
- message: `Response Validation Warnings for platform > Serviceability > getApplicationServiceabilitySelfShipment \n ${res_error}`,
420
+ message: `Response Validation Warnings for platform > Serviceability > createGeoArea \n ${res_error}`,
411
421
  });
412
422
  }
413
423
  }
@@ -416,27 +426,27 @@ class Serviceability {
416
426
  }
417
427
 
418
428
  /**
419
- * @param {ServiceabilityPlatformApplicationValidator.GetCourierPartnerRuleParam} arg
429
+ * @param {ServiceabilityPlatformApplicationValidator.CreateGeoAreaExportJobParam} arg
420
430
  * - Arg object
421
431
  *
422
432
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
423
433
  * @param {import("../PlatformAPIClient").Options} - Options
424
- * @returns {Promise<ServiceabilityPlatformModel.CourierPartnerRuleResult>}
434
+ * @returns {Promise<ServiceabilityPlatformModel.GeoAreaBulkCreationResult>}
425
435
  * - Success response
426
436
  *
427
- * @name getCourierPartnerRule
428
- * @summary: Get courier rule
429
- * @description: Retrieves a single rule within the delivery configuration. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/getCourierPartnerRule/).
437
+ * @name createGeoAreaExportJob
438
+ * @summary: Create job for exporting Geoarea regions
439
+ * @description: Create the job for exporting the regions in Geoarea in CSV format. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/createGeoAreaExportJob/).
430
440
  */
431
- async getCourierPartnerRule(
432
- { ruleId, requestHeaders } = { requestHeaders: {} },
441
+ async createGeoAreaExportJob(
442
+ { geoareaId, requestHeaders } = { requestHeaders: {} },
433
443
  { responseHeaders } = { responseHeaders: false }
434
444
  ) {
435
445
  const {
436
446
  error,
437
- } = ServiceabilityPlatformApplicationValidator.getCourierPartnerRule().validate(
447
+ } = ServiceabilityPlatformApplicationValidator.createGeoAreaExportJob().validate(
438
448
  {
439
- ruleId,
449
+ geoareaId,
440
450
  },
441
451
  { abortEarly: false, allowUnknown: true }
442
452
  );
@@ -447,16 +457,16 @@ class Serviceability {
447
457
  // Showing warrnings if extra unknown parameters are found
448
458
  const {
449
459
  error: warrning,
450
- } = ServiceabilityPlatformApplicationValidator.getCourierPartnerRule().validate(
460
+ } = ServiceabilityPlatformApplicationValidator.createGeoAreaExportJob().validate(
451
461
  {
452
- ruleId,
462
+ geoareaId,
453
463
  },
454
464
  { abortEarly: false, allowUnknown: false }
455
465
  );
456
466
  if (warrning) {
457
467
  Logger({
458
468
  level: "WARN",
459
- message: `Parameter Validation warrnings for platform > Serviceability > getCourierPartnerRule \n ${warrning}`,
469
+ message: `Parameter Validation warrnings for platform > Serviceability > createGeoAreaExportJob \n ${warrning}`,
460
470
  });
461
471
  }
462
472
 
@@ -464,8 +474,8 @@ class Serviceability {
464
474
 
465
475
  const response = await PlatformAPIClient.execute(
466
476
  this.config,
467
- "get",
468
- `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/courier-partner/rules/${ruleId}`,
477
+ "post",
478
+ `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/geoareas/bulk/export/${geoareaId}`,
469
479
  query_params,
470
480
  undefined,
471
481
  requestHeaders,
@@ -479,7 +489,7 @@ class Serviceability {
479
489
 
480
490
  const {
481
491
  error: res_error,
482
- } = ServiceabilityPlatformModel.CourierPartnerRuleResult().validate(
492
+ } = ServiceabilityPlatformModel.GeoAreaBulkCreationResult().validate(
483
493
  responseData,
484
494
  { abortEarly: false, allowUnknown: true }
485
495
  );
@@ -490,7 +500,7 @@ class Serviceability {
490
500
  } else {
491
501
  Logger({
492
502
  level: "WARN",
493
- message: `Response Validation Warnings for platform > Serviceability > getCourierPartnerRule \n ${res_error}`,
503
+ message: `Response Validation Warnings for platform > Serviceability > createGeoAreaExportJob \n ${res_error}`,
494
504
  });
495
505
  }
496
506
  }
@@ -499,29 +509,27 @@ class Serviceability {
499
509
  }
500
510
 
501
511
  /**
502
- * @param {ServiceabilityPlatformApplicationValidator.GetCourierPartnerRulesParam} arg
512
+ * @param {ServiceabilityPlatformApplicationValidator.CreateStoreRulesParam} arg
503
513
  * - Arg object
504
514
  *
505
515
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
506
516
  * @param {import("../PlatformAPIClient").Options} - Options
507
- * @returns {Promise<ServiceabilityPlatformModel.CourierPartnerRulesListResult>}
517
+ * @returns {Promise<ServiceabilityPlatformModel.StoreRuleResponseSchema>}
508
518
  * - Success response
509
519
  *
510
- * @name getCourierPartnerRules
511
- * @summary: Get courier rules
512
- * @description: Retrieve a list of rules within the delivery configuration. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/getCourierPartnerRules/).
520
+ * @name createStoreRules
521
+ * @summary: Create store rule
522
+ * @description: Create a rule within the order routing rules - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/createStoreRules/).
513
523
  */
514
- async getCourierPartnerRules(
515
- { pageNo, pageSize, status, requestHeaders } = { requestHeaders: {} },
524
+ async createStoreRules(
525
+ { body, requestHeaders } = { requestHeaders: {} },
516
526
  { responseHeaders } = { responseHeaders: false }
517
527
  ) {
518
528
  const {
519
529
  error,
520
- } = ServiceabilityPlatformApplicationValidator.getCourierPartnerRules().validate(
530
+ } = ServiceabilityPlatformApplicationValidator.createStoreRules().validate(
521
531
  {
522
- pageNo,
523
- pageSize,
524
- status,
532
+ body,
525
533
  },
526
534
  { abortEarly: false, allowUnknown: true }
527
535
  );
@@ -532,32 +540,27 @@ class Serviceability {
532
540
  // Showing warrnings if extra unknown parameters are found
533
541
  const {
534
542
  error: warrning,
535
- } = ServiceabilityPlatformApplicationValidator.getCourierPartnerRules().validate(
543
+ } = ServiceabilityPlatformApplicationValidator.createStoreRules().validate(
536
544
  {
537
- pageNo,
538
- pageSize,
539
- status,
545
+ body,
540
546
  },
541
547
  { abortEarly: false, allowUnknown: false }
542
548
  );
543
549
  if (warrning) {
544
550
  Logger({
545
551
  level: "WARN",
546
- message: `Parameter Validation warrnings for platform > Serviceability > getCourierPartnerRules \n ${warrning}`,
552
+ message: `Parameter Validation warrnings for platform > Serviceability > createStoreRules \n ${warrning}`,
547
553
  });
548
554
  }
549
555
 
550
556
  const query_params = {};
551
- query_params["page_no"] = pageNo;
552
- query_params["page_size"] = pageSize;
553
- query_params["status"] = status;
554
557
 
555
558
  const response = await PlatformAPIClient.execute(
556
559
  this.config,
557
- "get",
558
- `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/courier-partner/rules`,
560
+ "post",
561
+ `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/store/rules`,
559
562
  query_params,
560
- undefined,
563
+ body,
561
564
  requestHeaders,
562
565
  { responseHeaders }
563
566
  );
@@ -569,7 +572,7 @@ class Serviceability {
569
572
 
570
573
  const {
571
574
  error: res_error,
572
- } = ServiceabilityPlatformModel.CourierPartnerRulesListResult().validate(
575
+ } = ServiceabilityPlatformModel.StoreRuleResponseSchema().validate(
573
576
  responseData,
574
577
  { abortEarly: false, allowUnknown: true }
575
578
  );
@@ -580,7 +583,7 @@ class Serviceability {
580
583
  } else {
581
584
  Logger({
582
585
  level: "WARN",
583
- message: `Response Validation Warnings for platform > Serviceability > getCourierPartnerRules \n ${res_error}`,
586
+ message: `Response Validation Warnings for platform > Serviceability > createStoreRules \n ${res_error}`,
584
587
  });
585
588
  }
586
589
  }
@@ -589,25 +592,23 @@ class Serviceability {
589
592
  }
590
593
 
591
594
  /**
592
- * @param {ServiceabilityPlatformApplicationValidator.GetCourierPartnersParam} arg
595
+ * @param {ServiceabilityPlatformApplicationValidator.CreateZoneParam} arg
593
596
  * - Arg object
594
597
  *
595
598
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
596
599
  * @param {import("../PlatformAPIClient").Options} - Options
597
- * @returns {Promise<ServiceabilityPlatformModel.ShipmentCourierPartnerResult>}
598
- * - Success response
599
- *
600
- * @name getCourierPartners
601
- * @summary: Serviceable Courier Partners.
602
- * @description: Get all the serviceable courier partners of a destination and the shipments. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/getCourierPartners/).
600
+ * @returns {Promise<ServiceabilityPlatformModel.ZoneResponseV2>} - Success response
601
+ * @name createZone
602
+ * @summary: Create zone
603
+ * @description: Creates a delivery zone. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/createZone/).
603
604
  */
604
- async getCourierPartners(
605
+ async createZone(
605
606
  { body, requestHeaders } = { requestHeaders: {} },
606
607
  { responseHeaders } = { responseHeaders: false }
607
608
  ) {
608
609
  const {
609
610
  error,
610
- } = ServiceabilityPlatformApplicationValidator.getCourierPartners().validate(
611
+ } = ServiceabilityPlatformApplicationValidator.createZone().validate(
611
612
  {
612
613
  body,
613
614
  },
@@ -620,7 +621,7 @@ class Serviceability {
620
621
  // Showing warrnings if extra unknown parameters are found
621
622
  const {
622
623
  error: warrning,
623
- } = ServiceabilityPlatformApplicationValidator.getCourierPartners().validate(
624
+ } = ServiceabilityPlatformApplicationValidator.createZone().validate(
624
625
  {
625
626
  body,
626
627
  },
@@ -629,7 +630,7 @@ class Serviceability {
629
630
  if (warrning) {
630
631
  Logger({
631
632
  level: "WARN",
632
- message: `Parameter Validation warrnings for platform > Serviceability > getCourierPartners \n ${warrning}`,
633
+ message: `Parameter Validation warrnings for platform > Serviceability > createZone \n ${warrning}`,
633
634
  });
634
635
  }
635
636
 
@@ -638,7 +639,7 @@ class Serviceability {
638
639
  const response = await PlatformAPIClient.execute(
639
640
  this.config,
640
641
  "post",
641
- `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/shipment/courier-partners`,
642
+ `/service/platform/logistics/v2.0/company/${this.config.companyId}/application/${this.applicationId}/zones`,
642
643
  query_params,
643
644
  body,
644
645
  requestHeaders,
@@ -652,10 +653,10 @@ class Serviceability {
652
653
 
653
654
  const {
654
655
  error: res_error,
655
- } = ServiceabilityPlatformModel.ShipmentCourierPartnerResult().validate(
656
- responseData,
657
- { abortEarly: false, allowUnknown: true }
658
- );
656
+ } = ServiceabilityPlatformModel.ZoneResponseV2().validate(responseData, {
657
+ abortEarly: false,
658
+ allowUnknown: true,
659
+ });
659
660
 
660
661
  if (res_error) {
661
662
  if (this.config.options.strictResponseCheck === true) {
@@ -663,7 +664,7 @@ class Serviceability {
663
664
  } else {
664
665
  Logger({
665
666
  level: "WARN",
666
- message: `Response Validation Warnings for platform > Serviceability > getCourierPartners \n ${res_error}`,
667
+ message: `Response Validation Warnings for platform > Serviceability > createZone \n ${res_error}`,
667
668
  });
668
669
  }
669
670
  }
@@ -672,26 +673,27 @@ class Serviceability {
672
673
  }
673
674
 
674
675
  /**
675
- * @param {ServiceabilityPlatformApplicationValidator.GetStoreRuleParam} arg
676
+ * @param {ServiceabilityPlatformApplicationValidator.DeleteZoneParam} arg
676
677
  * - Arg object
677
678
  *
678
679
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
679
680
  * @param {import("../PlatformAPIClient").Options} - Options
680
- * @returns {Promise<ServiceabilityPlatformModel.StoreRuleDataSchema>} -
681
- * Success response
682
- * @name getStoreRule
683
- * @summary: Get store rule
684
- * @description: Retrieves a single rule within the order routing rules - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/getStoreRule/).
681
+ * @returns {Promise<ServiceabilityPlatformModel.ZoneDeleteSuccessResponse>}
682
+ * - Success response
683
+ *
684
+ * @name deleteZone
685
+ * @summary: Delete a Specific Zone
686
+ * @description: Delete a Zone under that application. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/deleteZone/).
685
687
  */
686
- async getStoreRule(
687
- { ruleUid, requestHeaders } = { requestHeaders: {} },
688
+ async deleteZone(
689
+ { zoneId, requestHeaders } = { requestHeaders: {} },
688
690
  { responseHeaders } = { responseHeaders: false }
689
691
  ) {
690
692
  const {
691
693
  error,
692
- } = ServiceabilityPlatformApplicationValidator.getStoreRule().validate(
694
+ } = ServiceabilityPlatformApplicationValidator.deleteZone().validate(
693
695
  {
694
- ruleUid,
696
+ zoneId,
695
697
  },
696
698
  { abortEarly: false, allowUnknown: true }
697
699
  );
@@ -702,16 +704,16 @@ class Serviceability {
702
704
  // Showing warrnings if extra unknown parameters are found
703
705
  const {
704
706
  error: warrning,
705
- } = ServiceabilityPlatformApplicationValidator.getStoreRule().validate(
707
+ } = ServiceabilityPlatformApplicationValidator.deleteZone().validate(
706
708
  {
707
- ruleUid,
709
+ zoneId,
708
710
  },
709
711
  { abortEarly: false, allowUnknown: false }
710
712
  );
711
713
  if (warrning) {
712
714
  Logger({
713
715
  level: "WARN",
714
- message: `Parameter Validation warrnings for platform > Serviceability > getStoreRule \n ${warrning}`,
716
+ message: `Parameter Validation warrnings for platform > Serviceability > deleteZone \n ${warrning}`,
715
717
  });
716
718
  }
717
719
 
@@ -719,8 +721,8 @@ class Serviceability {
719
721
 
720
722
  const response = await PlatformAPIClient.execute(
721
723
  this.config,
722
- "get",
723
- `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/store/rules/${ruleUid}`,
724
+ "delete",
725
+ `/service/platform/logistics/v2.0/company/${this.config.companyId}/application/${this.applicationId}/zones/${zoneId}`,
724
726
  query_params,
725
727
  undefined,
726
728
  requestHeaders,
@@ -734,7 +736,7 @@ class Serviceability {
734
736
 
735
737
  const {
736
738
  error: res_error,
737
- } = ServiceabilityPlatformModel.StoreRuleDataSchema().validate(
739
+ } = ServiceabilityPlatformModel.ZoneDeleteSuccessResponse().validate(
738
740
  responseData,
739
741
  { abortEarly: false, allowUnknown: true }
740
742
  );
@@ -745,7 +747,7 @@ class Serviceability {
745
747
  } else {
746
748
  Logger({
747
749
  level: "WARN",
748
- message: `Response Validation Warnings for platform > Serviceability > getStoreRule \n ${res_error}`,
750
+ message: `Response Validation Warnings for platform > Serviceability > deleteZone \n ${res_error}`,
749
751
  });
750
752
  }
751
753
  }
@@ -754,29 +756,24 @@ class Serviceability {
754
756
  }
755
757
 
756
758
  /**
757
- * @param {ServiceabilityPlatformApplicationValidator.GetStoreRulesParam} arg
759
+ * @param {ServiceabilityPlatformApplicationValidator.DownloadGeoareaSampleFileParam} arg
758
760
  * - Arg object
759
761
  *
760
762
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
761
763
  * @param {import("../PlatformAPIClient").Options} - Options
762
- * @returns {Promise<ServiceabilityPlatformModel.GetStoreRulesApiResult>} -
763
- * Success response
764
- * @name getStoreRules
765
- * @summary: Get store rules
766
- * @description: Retrieves an existing order routing setup for a single application - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/getStoreRules/).
764
+ * @returns {Promise<string>} - Success response
765
+ * @name downloadGeoareaSampleFile
766
+ * @summary: Download geoarea sample file.
767
+ * @description: Download a sample file for geoarea data. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/downloadGeoareaSampleFile/).
767
768
  */
768
- async getStoreRules(
769
- { pageNo, pageSize, status, requestHeaders } = { requestHeaders: {} },
769
+ async downloadGeoareaSampleFile(
770
+ { requestHeaders } = { requestHeaders: {} },
770
771
  { responseHeaders } = { responseHeaders: false }
771
772
  ) {
772
773
  const {
773
774
  error,
774
- } = ServiceabilityPlatformApplicationValidator.getStoreRules().validate(
775
- {
776
- pageNo,
777
- pageSize,
778
- status,
779
- },
775
+ } = ServiceabilityPlatformApplicationValidator.downloadGeoareaSampleFile().validate(
776
+ {},
780
777
  { abortEarly: false, allowUnknown: true }
781
778
  );
782
779
  if (error) {
@@ -786,30 +783,23 @@ class Serviceability {
786
783
  // Showing warrnings if extra unknown parameters are found
787
784
  const {
788
785
  error: warrning,
789
- } = ServiceabilityPlatformApplicationValidator.getStoreRules().validate(
790
- {
791
- pageNo,
792
- pageSize,
793
- status,
794
- },
786
+ } = ServiceabilityPlatformApplicationValidator.downloadGeoareaSampleFile().validate(
787
+ {},
795
788
  { abortEarly: false, allowUnknown: false }
796
789
  );
797
790
  if (warrning) {
798
791
  Logger({
799
792
  level: "WARN",
800
- message: `Parameter Validation warrnings for platform > Serviceability > getStoreRules \n ${warrning}`,
793
+ message: `Parameter Validation warrnings for platform > Serviceability > downloadGeoareaSampleFile \n ${warrning}`,
801
794
  });
802
795
  }
803
796
 
804
797
  const query_params = {};
805
- query_params["page_no"] = pageNo;
806
- query_params["page_size"] = pageSize;
807
- query_params["status"] = status;
808
798
 
809
799
  const response = await PlatformAPIClient.execute(
810
800
  this.config,
811
801
  "get",
812
- `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/store/rules`,
802
+ `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/geoareas/regions/bulk/sample`,
813
803
  query_params,
814
804
  undefined,
815
805
  requestHeaders,
@@ -821,12 +811,9 @@ class Serviceability {
821
811
  responseData = response[0];
822
812
  }
823
813
 
824
- const {
825
- error: res_error,
826
- } = ServiceabilityPlatformModel.GetStoreRulesApiResult().validate(
827
- responseData,
828
- { abortEarly: false, allowUnknown: true }
829
- );
814
+ const { error: res_error } = Joi.string()
815
+ .allow("")
816
+ .validate(responseData, { abortEarly: false, allowUnknown: true });
830
817
 
831
818
  if (res_error) {
832
819
  if (this.config.options.strictResponseCheck === true) {
@@ -834,7 +821,7 @@ class Serviceability {
834
821
  } else {
835
822
  Logger({
836
823
  level: "WARN",
837
- message: `Response Validation Warnings for platform > Serviceability > getStoreRules \n ${res_error}`,
824
+ message: `Response Validation Warnings for platform > Serviceability > downloadGeoareaSampleFile \n ${res_error}`,
838
825
  });
839
826
  }
840
827
  }
@@ -843,24 +830,1751 @@ class Serviceability {
843
830
  }
844
831
 
845
832
  /**
846
- * @param {ServiceabilityPlatformApplicationValidator.InsertApplicationConfigParam} arg
833
+ * @param {ServiceabilityPlatformApplicationValidator.DownloadZoneSampleFileParam} arg
847
834
  * - Arg object
848
835
  *
849
836
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
850
837
  * @param {import("../PlatformAPIClient").Options} - Options
851
- * @returns {Promise<ServiceabilityPlatformModel.StoreRuleConfigData>} -
852
- * Success response
853
- * @name insertApplicationConfig
854
- * @summary: Create store rule configuration
855
- * @description: Creates a order routing setup for an application, which involves updating sorting settings or rule priorities. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/insertApplicationConfig/).
838
+ * @returns {Promise<string>} - Success response
839
+ * @name downloadZoneSampleFile
840
+ * @summary: Download Sample Delivery Zone Product Type file.
841
+ * @description: Download a sample file for Delivery Zone with specified product type column (i.e. category, department, Item IDs or tags). - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/downloadZoneSampleFile/).
842
+ */
843
+ async downloadZoneSampleFile(
844
+ { productType, requestHeaders } = { requestHeaders: {} },
845
+ { responseHeaders } = { responseHeaders: false }
846
+ ) {
847
+ const {
848
+ error,
849
+ } = ServiceabilityPlatformApplicationValidator.downloadZoneSampleFile().validate(
850
+ {
851
+ productType,
852
+ },
853
+ { abortEarly: false, allowUnknown: true }
854
+ );
855
+ if (error) {
856
+ return Promise.reject(new FDKClientValidationError(error));
857
+ }
858
+
859
+ // Showing warrnings if extra unknown parameters are found
860
+ const {
861
+ error: warrning,
862
+ } = ServiceabilityPlatformApplicationValidator.downloadZoneSampleFile().validate(
863
+ {
864
+ productType,
865
+ },
866
+ { abortEarly: false, allowUnknown: false }
867
+ );
868
+ if (warrning) {
869
+ Logger({
870
+ level: "WARN",
871
+ message: `Parameter Validation warrnings for platform > Serviceability > downloadZoneSampleFile \n ${warrning}`,
872
+ });
873
+ }
874
+
875
+ const query_params = {};
876
+
877
+ const response = await PlatformAPIClient.execute(
878
+ this.config,
879
+ "get",
880
+ `/service/platform/logistics/v2.0/company/${this.config.companyId}/application/${this.applicationId}/zones/bulk/sample/${productType}`,
881
+ query_params,
882
+ undefined,
883
+ requestHeaders,
884
+ { responseHeaders }
885
+ );
886
+
887
+ let responseData = response;
888
+ if (responseHeaders) {
889
+ responseData = response[0];
890
+ }
891
+
892
+ const { error: res_error } = Joi.string()
893
+ .allow("")
894
+ .validate(responseData, { abortEarly: false, allowUnknown: true });
895
+
896
+ if (res_error) {
897
+ if (this.config.options.strictResponseCheck === true) {
898
+ return Promise.reject(new FDKResponseValidationError(res_error));
899
+ } else {
900
+ Logger({
901
+ level: "WARN",
902
+ message: `Response Validation Warnings for platform > Serviceability > downloadZoneSampleFile \n ${res_error}`,
903
+ });
904
+ }
905
+ }
906
+
907
+ return response;
908
+ }
909
+
910
+ /**
911
+ * @param {ServiceabilityPlatformApplicationValidator.GetApplicationConfigParam} arg
912
+ * - Arg object
913
+ *
914
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
915
+ * @param {import("../PlatformAPIClient").Options} - Options
916
+ * @returns {Promise<ServiceabilityPlatformModel.StoreRuleConfigData>} -
917
+ * Success response
918
+ * @name getApplicationConfig
919
+ * @summary: Get store rule configuration
920
+ * @description: Retrieves information about the order routing setup for a single application - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/getApplicationConfig/).
921
+ */
922
+ async getApplicationConfig(
923
+ { requestHeaders } = { requestHeaders: {} },
924
+ { responseHeaders } = { responseHeaders: false }
925
+ ) {
926
+ const {
927
+ error,
928
+ } = ServiceabilityPlatformApplicationValidator.getApplicationConfig().validate(
929
+ {},
930
+ { abortEarly: false, allowUnknown: true }
931
+ );
932
+ if (error) {
933
+ return Promise.reject(new FDKClientValidationError(error));
934
+ }
935
+
936
+ // Showing warrnings if extra unknown parameters are found
937
+ const {
938
+ error: warrning,
939
+ } = ServiceabilityPlatformApplicationValidator.getApplicationConfig().validate(
940
+ {},
941
+ { abortEarly: false, allowUnknown: false }
942
+ );
943
+ if (warrning) {
944
+ Logger({
945
+ level: "WARN",
946
+ message: `Parameter Validation warrnings for platform > Serviceability > getApplicationConfig \n ${warrning}`,
947
+ });
948
+ }
949
+
950
+ const query_params = {};
951
+
952
+ const response = await PlatformAPIClient.execute(
953
+ this.config,
954
+ "get",
955
+ `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/store/configuration`,
956
+ query_params,
957
+ undefined,
958
+ requestHeaders,
959
+ { responseHeaders }
960
+ );
961
+
962
+ let responseData = response;
963
+ if (responseHeaders) {
964
+ responseData = response[0];
965
+ }
966
+
967
+ const {
968
+ error: res_error,
969
+ } = ServiceabilityPlatformModel.StoreRuleConfigData().validate(
970
+ responseData,
971
+ { abortEarly: false, allowUnknown: true }
972
+ );
973
+
974
+ if (res_error) {
975
+ if (this.config.options.strictResponseCheck === true) {
976
+ return Promise.reject(new FDKResponseValidationError(res_error));
977
+ } else {
978
+ Logger({
979
+ level: "WARN",
980
+ message: `Response Validation Warnings for platform > Serviceability > getApplicationConfig \n ${res_error}`,
981
+ });
982
+ }
983
+ }
984
+
985
+ return response;
986
+ }
987
+
988
+ /**
989
+ * @param {ServiceabilityPlatformApplicationValidator.GetApplicationConfigurationParam} arg
990
+ * - Arg object
991
+ *
992
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
993
+ * @param {import("../PlatformAPIClient").Options} - Options
994
+ * @returns {Promise<ServiceabilityPlatformModel.ApplicationConfigGetResponse>}
995
+ * - Success response
996
+ *
997
+ * @name getApplicationConfiguration
998
+ * @summary: Get delivery configuration
999
+ * @description: This API returns all the Application config that has been applied to the given company and application. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/getApplicationConfiguration/).
1000
+ */
1001
+ async getApplicationConfiguration(
1002
+ { requestHeaders } = { requestHeaders: {} },
1003
+ { responseHeaders } = { responseHeaders: false }
1004
+ ) {
1005
+ const {
1006
+ error,
1007
+ } = ServiceabilityPlatformApplicationValidator.getApplicationConfiguration().validate(
1008
+ {},
1009
+ { abortEarly: false, allowUnknown: true }
1010
+ );
1011
+ if (error) {
1012
+ return Promise.reject(new FDKClientValidationError(error));
1013
+ }
1014
+
1015
+ // Showing warrnings if extra unknown parameters are found
1016
+ const {
1017
+ error: warrning,
1018
+ } = ServiceabilityPlatformApplicationValidator.getApplicationConfiguration().validate(
1019
+ {},
1020
+ { abortEarly: false, allowUnknown: false }
1021
+ );
1022
+ if (warrning) {
1023
+ Logger({
1024
+ level: "WARN",
1025
+ message: `Parameter Validation warrnings for platform > Serviceability > getApplicationConfiguration \n ${warrning}`,
1026
+ });
1027
+ }
1028
+
1029
+ const query_params = {};
1030
+
1031
+ const response = await PlatformAPIClient.execute(
1032
+ this.config,
1033
+ "get",
1034
+ `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/configuration`,
1035
+ query_params,
1036
+ undefined,
1037
+ requestHeaders,
1038
+ { responseHeaders }
1039
+ );
1040
+
1041
+ let responseData = response;
1042
+ if (responseHeaders) {
1043
+ responseData = response[0];
1044
+ }
1045
+
1046
+ const {
1047
+ error: res_error,
1048
+ } = ServiceabilityPlatformModel.ApplicationConfigGetResponse().validate(
1049
+ responseData,
1050
+ { abortEarly: false, allowUnknown: true }
1051
+ );
1052
+
1053
+ if (res_error) {
1054
+ if (this.config.options.strictResponseCheck === true) {
1055
+ return Promise.reject(new FDKResponseValidationError(res_error));
1056
+ } else {
1057
+ Logger({
1058
+ level: "WARN",
1059
+ message: `Response Validation Warnings for platform > Serviceability > getApplicationConfiguration \n ${res_error}`,
1060
+ });
1061
+ }
1062
+ }
1063
+
1064
+ return response;
1065
+ }
1066
+
1067
+ /**
1068
+ * @param {ServiceabilityPlatformApplicationValidator.GetBulkExportParam} arg
1069
+ * - Arg object
1070
+ *
1071
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
1072
+ * @param {import("../PlatformAPIClient").Options} - Options
1073
+ * @returns {Promise<ServiceabilityPlatformModel.GetZoneBulkExport>} -
1074
+ * Success response
1075
+ * @name getBulkExport
1076
+ * @summary: Get Bulk Export of Zones
1077
+ * @description: Get specific zone which is exported at the application level. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/getBulkExport/).
1078
+ */
1079
+ async getBulkExport(
1080
+ { batchId, requestHeaders } = { requestHeaders: {} },
1081
+ { responseHeaders } = { responseHeaders: false }
1082
+ ) {
1083
+ const {
1084
+ error,
1085
+ } = ServiceabilityPlatformApplicationValidator.getBulkExport().validate(
1086
+ {
1087
+ batchId,
1088
+ },
1089
+ { abortEarly: false, allowUnknown: true }
1090
+ );
1091
+ if (error) {
1092
+ return Promise.reject(new FDKClientValidationError(error));
1093
+ }
1094
+
1095
+ // Showing warrnings if extra unknown parameters are found
1096
+ const {
1097
+ error: warrning,
1098
+ } = ServiceabilityPlatformApplicationValidator.getBulkExport().validate(
1099
+ {
1100
+ batchId,
1101
+ },
1102
+ { abortEarly: false, allowUnknown: false }
1103
+ );
1104
+ if (warrning) {
1105
+ Logger({
1106
+ level: "WARN",
1107
+ message: `Parameter Validation warrnings for platform > Serviceability > getBulkExport \n ${warrning}`,
1108
+ });
1109
+ }
1110
+
1111
+ const query_params = {};
1112
+
1113
+ const response = await PlatformAPIClient.execute(
1114
+ this.config,
1115
+ "get",
1116
+ `/service/platform/logistics/v2.0/company/${this.config.companyId}/application/${this.applicationId}/zones/bulk/export/${batchId}`,
1117
+ query_params,
1118
+ undefined,
1119
+ requestHeaders,
1120
+ { responseHeaders }
1121
+ );
1122
+
1123
+ let responseData = response;
1124
+ if (responseHeaders) {
1125
+ responseData = response[0];
1126
+ }
1127
+
1128
+ const {
1129
+ error: res_error,
1130
+ } = ServiceabilityPlatformModel.GetZoneBulkExport().validate(responseData, {
1131
+ abortEarly: false,
1132
+ allowUnknown: true,
1133
+ });
1134
+
1135
+ if (res_error) {
1136
+ if (this.config.options.strictResponseCheck === true) {
1137
+ return Promise.reject(new FDKResponseValidationError(res_error));
1138
+ } else {
1139
+ Logger({
1140
+ level: "WARN",
1141
+ message: `Response Validation Warnings for platform > Serviceability > getBulkExport \n ${res_error}`,
1142
+ });
1143
+ }
1144
+ }
1145
+
1146
+ return response;
1147
+ }
1148
+
1149
+ /**
1150
+ * @param {ServiceabilityPlatformApplicationValidator.GetBulkGeoAreaParam} arg
1151
+ * - Arg object
1152
+ *
1153
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
1154
+ * @param {import("../PlatformAPIClient").Options} - Options
1155
+ * @returns {Promise<ServiceabilityPlatformModel.BulkGeoAreaGetResponse>} -
1156
+ * Success response
1157
+ * @name getBulkGeoArea
1158
+ * @summary: Get status of GeoAreas created in bulk
1159
+ * @description: Allows to Get GeoArea status which is created, representing groups of geographic regions in bulk. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/getBulkGeoArea/).
1160
+ */
1161
+ async getBulkGeoArea(
1162
+ { geoareaId, requestHeaders } = { requestHeaders: {} },
1163
+ { responseHeaders } = { responseHeaders: false }
1164
+ ) {
1165
+ const {
1166
+ error,
1167
+ } = ServiceabilityPlatformApplicationValidator.getBulkGeoArea().validate(
1168
+ {
1169
+ geoareaId,
1170
+ },
1171
+ { abortEarly: false, allowUnknown: true }
1172
+ );
1173
+ if (error) {
1174
+ return Promise.reject(new FDKClientValidationError(error));
1175
+ }
1176
+
1177
+ // Showing warrnings if extra unknown parameters are found
1178
+ const {
1179
+ error: warrning,
1180
+ } = ServiceabilityPlatformApplicationValidator.getBulkGeoArea().validate(
1181
+ {
1182
+ geoareaId,
1183
+ },
1184
+ { abortEarly: false, allowUnknown: false }
1185
+ );
1186
+ if (warrning) {
1187
+ Logger({
1188
+ level: "WARN",
1189
+ message: `Parameter Validation warrnings for platform > Serviceability > getBulkGeoArea \n ${warrning}`,
1190
+ });
1191
+ }
1192
+
1193
+ const query_params = {};
1194
+
1195
+ const response = await PlatformAPIClient.execute(
1196
+ this.config,
1197
+ "get",
1198
+ `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/geoareas/regions/bulk/${geoareaId}`,
1199
+ query_params,
1200
+ undefined,
1201
+ requestHeaders,
1202
+ { responseHeaders }
1203
+ );
1204
+
1205
+ let responseData = response;
1206
+ if (responseHeaders) {
1207
+ responseData = response[0];
1208
+ }
1209
+
1210
+ const {
1211
+ error: res_error,
1212
+ } = ServiceabilityPlatformModel.BulkGeoAreaGetResponse().validate(
1213
+ responseData,
1214
+ { abortEarly: false, allowUnknown: true }
1215
+ );
1216
+
1217
+ if (res_error) {
1218
+ if (this.config.options.strictResponseCheck === true) {
1219
+ return Promise.reject(new FDKResponseValidationError(res_error));
1220
+ } else {
1221
+ Logger({
1222
+ level: "WARN",
1223
+ message: `Response Validation Warnings for platform > Serviceability > getBulkGeoArea \n ${res_error}`,
1224
+ });
1225
+ }
1226
+ }
1227
+
1228
+ return response;
1229
+ }
1230
+
1231
+ /**
1232
+ * @param {ServiceabilityPlatformApplicationValidator.GetBulkZoneParam} arg
1233
+ * - Arg object
1234
+ *
1235
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
1236
+ * @param {import("../PlatformAPIClient").Options} - Options
1237
+ * @returns {Promise<ServiceabilityPlatformModel.GetBulkZoneHistory>} -
1238
+ * Success response
1239
+ * @name getBulkZone
1240
+ * @summary: Get bulk zones.
1241
+ * @description: Fetch bulk zones created at the application level. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/getBulkZone/).
1242
+ */
1243
+ async getBulkZone(
1244
+ { requestHeaders } = { requestHeaders: {} },
1245
+ { responseHeaders } = { responseHeaders: false }
1246
+ ) {
1247
+ const {
1248
+ error,
1249
+ } = ServiceabilityPlatformApplicationValidator.getBulkZone().validate(
1250
+ {},
1251
+ { abortEarly: false, allowUnknown: true }
1252
+ );
1253
+ if (error) {
1254
+ return Promise.reject(new FDKClientValidationError(error));
1255
+ }
1256
+
1257
+ // Showing warrnings if extra unknown parameters are found
1258
+ const {
1259
+ error: warrning,
1260
+ } = ServiceabilityPlatformApplicationValidator.getBulkZone().validate(
1261
+ {},
1262
+ { abortEarly: false, allowUnknown: false }
1263
+ );
1264
+ if (warrning) {
1265
+ Logger({
1266
+ level: "WARN",
1267
+ message: `Parameter Validation warrnings for platform > Serviceability > getBulkZone \n ${warrning}`,
1268
+ });
1269
+ }
1270
+
1271
+ const query_params = {};
1272
+
1273
+ const response = await PlatformAPIClient.execute(
1274
+ this.config,
1275
+ "get",
1276
+ `/service/platform/logistics/v2.0/company/${this.config.companyId}/application/${this.applicationId}/zones/bulk/history`,
1277
+ query_params,
1278
+ undefined,
1279
+ requestHeaders,
1280
+ { responseHeaders }
1281
+ );
1282
+
1283
+ let responseData = response;
1284
+ if (responseHeaders) {
1285
+ responseData = response[0];
1286
+ }
1287
+
1288
+ const {
1289
+ error: res_error,
1290
+ } = ServiceabilityPlatformModel.GetBulkZoneHistory().validate(
1291
+ responseData,
1292
+ { abortEarly: false, allowUnknown: true }
1293
+ );
1294
+
1295
+ if (res_error) {
1296
+ if (this.config.options.strictResponseCheck === true) {
1297
+ return Promise.reject(new FDKResponseValidationError(res_error));
1298
+ } else {
1299
+ Logger({
1300
+ level: "WARN",
1301
+ message: `Response Validation Warnings for platform > Serviceability > getBulkZone \n ${res_error}`,
1302
+ });
1303
+ }
1304
+ }
1305
+
1306
+ return response;
1307
+ }
1308
+
1309
+ /**
1310
+ * @param {ServiceabilityPlatformApplicationValidator.GetCourierPartnerRuleParam} arg
1311
+ * - Arg object
1312
+ *
1313
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
1314
+ * @param {import("../PlatformAPIClient").Options} - Options
1315
+ * @returns {Promise<ServiceabilityPlatformModel.CourierPartnerRuleResponseSchema>}
1316
+ * - Success response
1317
+ *
1318
+ * @name getCourierPartnerRule
1319
+ * @summary: Get courier rule
1320
+ * @description: Retrieves a single rule within the delivery configuration. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/getCourierPartnerRule/).
1321
+ */
1322
+ async getCourierPartnerRule(
1323
+ { ruleUid, requestHeaders } = { requestHeaders: {} },
1324
+ { responseHeaders } = { responseHeaders: false }
1325
+ ) {
1326
+ const {
1327
+ error,
1328
+ } = ServiceabilityPlatformApplicationValidator.getCourierPartnerRule().validate(
1329
+ {
1330
+ ruleUid,
1331
+ },
1332
+ { abortEarly: false, allowUnknown: true }
1333
+ );
1334
+ if (error) {
1335
+ return Promise.reject(new FDKClientValidationError(error));
1336
+ }
1337
+
1338
+ // Showing warrnings if extra unknown parameters are found
1339
+ const {
1340
+ error: warrning,
1341
+ } = ServiceabilityPlatformApplicationValidator.getCourierPartnerRule().validate(
1342
+ {
1343
+ ruleUid,
1344
+ },
1345
+ { abortEarly: false, allowUnknown: false }
1346
+ );
1347
+ if (warrning) {
1348
+ Logger({
1349
+ level: "WARN",
1350
+ message: `Parameter Validation warrnings for platform > Serviceability > getCourierPartnerRule \n ${warrning}`,
1351
+ });
1352
+ }
1353
+
1354
+ const query_params = {};
1355
+
1356
+ const response = await PlatformAPIClient.execute(
1357
+ this.config,
1358
+ "get",
1359
+ `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/courier-partner/rules/${ruleUid}`,
1360
+ query_params,
1361
+ undefined,
1362
+ requestHeaders,
1363
+ { responseHeaders }
1364
+ );
1365
+
1366
+ let responseData = response;
1367
+ if (responseHeaders) {
1368
+ responseData = response[0];
1369
+ }
1370
+
1371
+ const {
1372
+ error: res_error,
1373
+ } = ServiceabilityPlatformModel.CourierPartnerRuleResponseSchema().validate(
1374
+ responseData,
1375
+ { abortEarly: false, allowUnknown: true }
1376
+ );
1377
+
1378
+ if (res_error) {
1379
+ if (this.config.options.strictResponseCheck === true) {
1380
+ return Promise.reject(new FDKResponseValidationError(res_error));
1381
+ } else {
1382
+ Logger({
1383
+ level: "WARN",
1384
+ message: `Response Validation Warnings for platform > Serviceability > getCourierPartnerRule \n ${res_error}`,
1385
+ });
1386
+ }
1387
+ }
1388
+
1389
+ return response;
1390
+ }
1391
+
1392
+ /**
1393
+ * @param {ServiceabilityPlatformApplicationValidator.GetCourierPartnerRuleDetailsParam} arg
1394
+ * - Arg object
1395
+ *
1396
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
1397
+ * @param {import("../PlatformAPIClient").Options} - Options
1398
+ * @returns {Promise<ServiceabilityPlatformModel.CourierPartnerRuleResponseDetailSchema>}
1399
+ * - Success response
1400
+ *
1401
+ * @name getCourierPartnerRuleDetails
1402
+ * @summary: Get courier rule
1403
+ * @description: Retrieves details for a courier partner rule. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/getCourierPartnerRuleDetails/).
1404
+ */
1405
+ async getCourierPartnerRuleDetails(
1406
+ { ruleUid, requestHeaders } = { requestHeaders: {} },
1407
+ { responseHeaders } = { responseHeaders: false }
1408
+ ) {
1409
+ const {
1410
+ error,
1411
+ } = ServiceabilityPlatformApplicationValidator.getCourierPartnerRuleDetails().validate(
1412
+ {
1413
+ ruleUid,
1414
+ },
1415
+ { abortEarly: false, allowUnknown: true }
1416
+ );
1417
+ if (error) {
1418
+ return Promise.reject(new FDKClientValidationError(error));
1419
+ }
1420
+
1421
+ // Showing warrnings if extra unknown parameters are found
1422
+ const {
1423
+ error: warrning,
1424
+ } = ServiceabilityPlatformApplicationValidator.getCourierPartnerRuleDetails().validate(
1425
+ {
1426
+ ruleUid,
1427
+ },
1428
+ { abortEarly: false, allowUnknown: false }
1429
+ );
1430
+ if (warrning) {
1431
+ Logger({
1432
+ level: "WARN",
1433
+ message: `Parameter Validation warrnings for platform > Serviceability > getCourierPartnerRuleDetails \n ${warrning}`,
1434
+ });
1435
+ }
1436
+
1437
+ const query_params = {};
1438
+
1439
+ const response = await PlatformAPIClient.execute(
1440
+ this.config,
1441
+ "get",
1442
+ `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/courier-partner/rules/${ruleUid}/details`,
1443
+ query_params,
1444
+ undefined,
1445
+ requestHeaders,
1446
+ { responseHeaders }
1447
+ );
1448
+
1449
+ let responseData = response;
1450
+ if (responseHeaders) {
1451
+ responseData = response[0];
1452
+ }
1453
+
1454
+ const {
1455
+ error: res_error,
1456
+ } = ServiceabilityPlatformModel.CourierPartnerRuleResponseDetailSchema().validate(
1457
+ responseData,
1458
+ { abortEarly: false, allowUnknown: true }
1459
+ );
1460
+
1461
+ if (res_error) {
1462
+ if (this.config.options.strictResponseCheck === true) {
1463
+ return Promise.reject(new FDKResponseValidationError(res_error));
1464
+ } else {
1465
+ Logger({
1466
+ level: "WARN",
1467
+ message: `Response Validation Warnings for platform > Serviceability > getCourierPartnerRuleDetails \n ${res_error}`,
1468
+ });
1469
+ }
1470
+ }
1471
+
1472
+ return response;
1473
+ }
1474
+
1475
+ /**
1476
+ * @param {ServiceabilityPlatformApplicationValidator.GetCourierPartnerRulesParam} arg
1477
+ * - Arg object
1478
+ *
1479
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
1480
+ * @param {import("../PlatformAPIClient").Options} - Options
1481
+ * @returns {Promise<ServiceabilityPlatformModel.CourierPartnerRulesListResponse>}
1482
+ * - Success response
1483
+ *
1484
+ * @name getCourierPartnerRules
1485
+ * @summary: Get courier rules
1486
+ * @description: Retrieve a list of rules within the delivery configuration. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/getCourierPartnerRules/).
1487
+ */
1488
+ async getCourierPartnerRules(
1489
+ { pageNo, pageSize, status, requestHeaders } = { requestHeaders: {} },
1490
+ { responseHeaders } = { responseHeaders: false }
1491
+ ) {
1492
+ const {
1493
+ error,
1494
+ } = ServiceabilityPlatformApplicationValidator.getCourierPartnerRules().validate(
1495
+ {
1496
+ pageNo,
1497
+ pageSize,
1498
+ status,
1499
+ },
1500
+ { abortEarly: false, allowUnknown: true }
1501
+ );
1502
+ if (error) {
1503
+ return Promise.reject(new FDKClientValidationError(error));
1504
+ }
1505
+
1506
+ // Showing warrnings if extra unknown parameters are found
1507
+ const {
1508
+ error: warrning,
1509
+ } = ServiceabilityPlatformApplicationValidator.getCourierPartnerRules().validate(
1510
+ {
1511
+ pageNo,
1512
+ pageSize,
1513
+ status,
1514
+ },
1515
+ { abortEarly: false, allowUnknown: false }
1516
+ );
1517
+ if (warrning) {
1518
+ Logger({
1519
+ level: "WARN",
1520
+ message: `Parameter Validation warrnings for platform > Serviceability > getCourierPartnerRules \n ${warrning}`,
1521
+ });
1522
+ }
1523
+
1524
+ const query_params = {};
1525
+ query_params["page_no"] = pageNo;
1526
+ query_params["page_size"] = pageSize;
1527
+ query_params["status"] = status;
1528
+
1529
+ const response = await PlatformAPIClient.execute(
1530
+ this.config,
1531
+ "get",
1532
+ `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/courier-partner/rules`,
1533
+ query_params,
1534
+ undefined,
1535
+ requestHeaders,
1536
+ { responseHeaders }
1537
+ );
1538
+
1539
+ let responseData = response;
1540
+ if (responseHeaders) {
1541
+ responseData = response[0];
1542
+ }
1543
+
1544
+ const {
1545
+ error: res_error,
1546
+ } = ServiceabilityPlatformModel.CourierPartnerRulesListResponse().validate(
1547
+ responseData,
1548
+ { abortEarly: false, allowUnknown: true }
1549
+ );
1550
+
1551
+ if (res_error) {
1552
+ if (this.config.options.strictResponseCheck === true) {
1553
+ return Promise.reject(new FDKResponseValidationError(res_error));
1554
+ } else {
1555
+ Logger({
1556
+ level: "WARN",
1557
+ message: `Response Validation Warnings for platform > Serviceability > getCourierPartnerRules \n ${res_error}`,
1558
+ });
1559
+ }
1560
+ }
1561
+
1562
+ return response;
1563
+ }
1564
+
1565
+ /**
1566
+ * @param {ServiceabilityPlatformApplicationValidator.GetGeoAreaParam} arg
1567
+ * - Arg object
1568
+ *
1569
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
1570
+ * @param {import("../PlatformAPIClient").Options} - Options
1571
+ * @returns {Promise<ServiceabilityPlatformModel.GeoAreaResponse>} - Success response
1572
+ * @name getGeoArea
1573
+ * @summary: Get details of the specific geoarea
1574
+ * @description: This API Returns the data of the specific GeoArea which exists on the platform. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/getGeoArea/).
1575
+ */
1576
+ async getGeoArea(
1577
+ { geoareaId, requestHeaders } = { requestHeaders: {} },
1578
+ { responseHeaders } = { responseHeaders: false }
1579
+ ) {
1580
+ const {
1581
+ error,
1582
+ } = ServiceabilityPlatformApplicationValidator.getGeoArea().validate(
1583
+ {
1584
+ geoareaId,
1585
+ },
1586
+ { abortEarly: false, allowUnknown: true }
1587
+ );
1588
+ if (error) {
1589
+ return Promise.reject(new FDKClientValidationError(error));
1590
+ }
1591
+
1592
+ // Showing warrnings if extra unknown parameters are found
1593
+ const {
1594
+ error: warrning,
1595
+ } = ServiceabilityPlatformApplicationValidator.getGeoArea().validate(
1596
+ {
1597
+ geoareaId,
1598
+ },
1599
+ { abortEarly: false, allowUnknown: false }
1600
+ );
1601
+ if (warrning) {
1602
+ Logger({
1603
+ level: "WARN",
1604
+ message: `Parameter Validation warrnings for platform > Serviceability > getGeoArea \n ${warrning}`,
1605
+ });
1606
+ }
1607
+
1608
+ const query_params = {};
1609
+
1610
+ const response = await PlatformAPIClient.execute(
1611
+ this.config,
1612
+ "get",
1613
+ `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/geoareas/${geoareaId}`,
1614
+ query_params,
1615
+ undefined,
1616
+ requestHeaders,
1617
+ { responseHeaders }
1618
+ );
1619
+
1620
+ let responseData = response;
1621
+ if (responseHeaders) {
1622
+ responseData = response[0];
1623
+ }
1624
+
1625
+ const {
1626
+ error: res_error,
1627
+ } = ServiceabilityPlatformModel.GeoAreaResponse().validate(responseData, {
1628
+ abortEarly: false,
1629
+ allowUnknown: true,
1630
+ });
1631
+
1632
+ if (res_error) {
1633
+ if (this.config.options.strictResponseCheck === true) {
1634
+ return Promise.reject(new FDKResponseValidationError(res_error));
1635
+ } else {
1636
+ Logger({
1637
+ level: "WARN",
1638
+ message: `Response Validation Warnings for platform > Serviceability > getGeoArea \n ${res_error}`,
1639
+ });
1640
+ }
1641
+ }
1642
+
1643
+ return response;
1644
+ }
1645
+
1646
+ /**
1647
+ * @param {ServiceabilityPlatformApplicationValidator.GetGeoAreaExportJobStatusParam} arg
1648
+ * - Arg object
1649
+ *
1650
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
1651
+ * @param {import("../PlatformAPIClient").Options} - Options
1652
+ * @returns {Promise<ServiceabilityPlatformModel.GeoAreaBulkExportResult>}
1653
+ * - Success response
1654
+ *
1655
+ * @name getGeoAreaExportJobStatus
1656
+ * @summary: Get status of Geoarea export job
1657
+ * @description: Get the status and details of the Geoarea bulk export process. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/getGeoAreaExportJobStatus/).
1658
+ */
1659
+ async getGeoAreaExportJobStatus(
1660
+ { geoareaId, requestHeaders } = { requestHeaders: {} },
1661
+ { responseHeaders } = { responseHeaders: false }
1662
+ ) {
1663
+ const {
1664
+ error,
1665
+ } = ServiceabilityPlatformApplicationValidator.getGeoAreaExportJobStatus().validate(
1666
+ {
1667
+ geoareaId,
1668
+ },
1669
+ { abortEarly: false, allowUnknown: true }
1670
+ );
1671
+ if (error) {
1672
+ return Promise.reject(new FDKClientValidationError(error));
1673
+ }
1674
+
1675
+ // Showing warrnings if extra unknown parameters are found
1676
+ const {
1677
+ error: warrning,
1678
+ } = ServiceabilityPlatformApplicationValidator.getGeoAreaExportJobStatus().validate(
1679
+ {
1680
+ geoareaId,
1681
+ },
1682
+ { abortEarly: false, allowUnknown: false }
1683
+ );
1684
+ if (warrning) {
1685
+ Logger({
1686
+ level: "WARN",
1687
+ message: `Parameter Validation warrnings for platform > Serviceability > getGeoAreaExportJobStatus \n ${warrning}`,
1688
+ });
1689
+ }
1690
+
1691
+ const query_params = {};
1692
+
1693
+ const response = await PlatformAPIClient.execute(
1694
+ this.config,
1695
+ "get",
1696
+ `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/geoareas/bulk/export/${geoareaId}`,
1697
+ query_params,
1698
+ undefined,
1699
+ requestHeaders,
1700
+ { responseHeaders }
1701
+ );
1702
+
1703
+ let responseData = response;
1704
+ if (responseHeaders) {
1705
+ responseData = response[0];
1706
+ }
1707
+
1708
+ const {
1709
+ error: res_error,
1710
+ } = ServiceabilityPlatformModel.GeoAreaBulkExportResult().validate(
1711
+ responseData,
1712
+ { abortEarly: false, allowUnknown: true }
1713
+ );
1714
+
1715
+ if (res_error) {
1716
+ if (this.config.options.strictResponseCheck === true) {
1717
+ return Promise.reject(new FDKResponseValidationError(res_error));
1718
+ } else {
1719
+ Logger({
1720
+ level: "WARN",
1721
+ message: `Response Validation Warnings for platform > Serviceability > getGeoAreaExportJobStatus \n ${res_error}`,
1722
+ });
1723
+ }
1724
+ }
1725
+
1726
+ return response;
1727
+ }
1728
+
1729
+ /**
1730
+ * @param {ServiceabilityPlatformApplicationValidator.GetGeoAreasParam} arg
1731
+ * - Arg object
1732
+ *
1733
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
1734
+ * @param {import("../PlatformAPIClient").Options} - Options
1735
+ * @returns {Promise<ServiceabilityPlatformModel.GeoAreaGetResponseBody>} -
1736
+ * Success response
1737
+ * @name getGeoAreas
1738
+ * @summary: Get all geoareas in the current application.
1739
+ * @description: Retrieves a listing view of created GeoAreas. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/getGeoAreas/).
1740
+ */
1741
+ async getGeoAreas(
1742
+ {
1743
+ pageSize,
1744
+ isActive,
1745
+ pageNo,
1746
+ type,
1747
+ q,
1748
+ countryIsoCode,
1749
+ state,
1750
+ city,
1751
+ pincode,
1752
+ sector,
1753
+ requestHeaders,
1754
+ } = { requestHeaders: {} },
1755
+ { responseHeaders } = { responseHeaders: false }
1756
+ ) {
1757
+ const {
1758
+ error,
1759
+ } = ServiceabilityPlatformApplicationValidator.getGeoAreas().validate(
1760
+ {
1761
+ pageSize,
1762
+ isActive,
1763
+ pageNo,
1764
+ type,
1765
+ q,
1766
+ countryIsoCode,
1767
+ state,
1768
+ city,
1769
+ pincode,
1770
+ sector,
1771
+ },
1772
+ { abortEarly: false, allowUnknown: true }
1773
+ );
1774
+ if (error) {
1775
+ return Promise.reject(new FDKClientValidationError(error));
1776
+ }
1777
+
1778
+ // Showing warrnings if extra unknown parameters are found
1779
+ const {
1780
+ error: warrning,
1781
+ } = ServiceabilityPlatformApplicationValidator.getGeoAreas().validate(
1782
+ {
1783
+ pageSize,
1784
+ isActive,
1785
+ pageNo,
1786
+ type,
1787
+ q,
1788
+ countryIsoCode,
1789
+ state,
1790
+ city,
1791
+ pincode,
1792
+ sector,
1793
+ },
1794
+ { abortEarly: false, allowUnknown: false }
1795
+ );
1796
+ if (warrning) {
1797
+ Logger({
1798
+ level: "WARN",
1799
+ message: `Parameter Validation warrnings for platform > Serviceability > getGeoAreas \n ${warrning}`,
1800
+ });
1801
+ }
1802
+
1803
+ const query_params = {};
1804
+ query_params["page_size"] = pageSize;
1805
+ query_params["is_active"] = isActive;
1806
+ query_params["page_no"] = pageNo;
1807
+ query_params["type"] = type;
1808
+ query_params["q"] = q;
1809
+ query_params["country_iso_code"] = countryIsoCode;
1810
+ query_params["state"] = state;
1811
+ query_params["city"] = city;
1812
+ query_params["pincode"] = pincode;
1813
+ query_params["sector"] = sector;
1814
+
1815
+ const response = await PlatformAPIClient.execute(
1816
+ this.config,
1817
+ "get",
1818
+ `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/geoareas`,
1819
+ query_params,
1820
+ undefined,
1821
+ requestHeaders,
1822
+ { responseHeaders }
1823
+ );
1824
+
1825
+ let responseData = response;
1826
+ if (responseHeaders) {
1827
+ responseData = response[0];
1828
+ }
1829
+
1830
+ const {
1831
+ error: res_error,
1832
+ } = ServiceabilityPlatformModel.GeoAreaGetResponseBody().validate(
1833
+ responseData,
1834
+ { abortEarly: false, allowUnknown: true }
1835
+ );
1836
+
1837
+ if (res_error) {
1838
+ if (this.config.options.strictResponseCheck === true) {
1839
+ return Promise.reject(new FDKResponseValidationError(res_error));
1840
+ } else {
1841
+ Logger({
1842
+ level: "WARN",
1843
+ message: `Response Validation Warnings for platform > Serviceability > getGeoAreas \n ${res_error}`,
1844
+ });
1845
+ }
1846
+ }
1847
+
1848
+ return response;
1849
+ }
1850
+
1851
+ /**
1852
+ * @param {ServiceabilityPlatformApplicationValidator.GetStoreRuleParam} arg
1853
+ * - Arg object
1854
+ *
1855
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
1856
+ * @param {import("../PlatformAPIClient").Options} - Options
1857
+ * @returns {Promise<ServiceabilityPlatformModel.StoreRuleDataSchema>} -
1858
+ * Success response
1859
+ * @name getStoreRule
1860
+ * @summary: Get store rule
1861
+ * @description: Retrieves a single rule within the order routing rules - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/getStoreRule/).
1862
+ */
1863
+ async getStoreRule(
1864
+ { ruleUid, requestHeaders } = { requestHeaders: {} },
1865
+ { responseHeaders } = { responseHeaders: false }
1866
+ ) {
1867
+ const {
1868
+ error,
1869
+ } = ServiceabilityPlatformApplicationValidator.getStoreRule().validate(
1870
+ {
1871
+ ruleUid,
1872
+ },
1873
+ { abortEarly: false, allowUnknown: true }
1874
+ );
1875
+ if (error) {
1876
+ return Promise.reject(new FDKClientValidationError(error));
1877
+ }
1878
+
1879
+ // Showing warrnings if extra unknown parameters are found
1880
+ const {
1881
+ error: warrning,
1882
+ } = ServiceabilityPlatformApplicationValidator.getStoreRule().validate(
1883
+ {
1884
+ ruleUid,
1885
+ },
1886
+ { abortEarly: false, allowUnknown: false }
1887
+ );
1888
+ if (warrning) {
1889
+ Logger({
1890
+ level: "WARN",
1891
+ message: `Parameter Validation warrnings for platform > Serviceability > getStoreRule \n ${warrning}`,
1892
+ });
1893
+ }
1894
+
1895
+ const query_params = {};
1896
+
1897
+ const response = await PlatformAPIClient.execute(
1898
+ this.config,
1899
+ "get",
1900
+ `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/store/rules/${ruleUid}`,
1901
+ query_params,
1902
+ undefined,
1903
+ requestHeaders,
1904
+ { responseHeaders }
1905
+ );
1906
+
1907
+ let responseData = response;
1908
+ if (responseHeaders) {
1909
+ responseData = response[0];
1910
+ }
1911
+
1912
+ const {
1913
+ error: res_error,
1914
+ } = ServiceabilityPlatformModel.StoreRuleDataSchema().validate(
1915
+ responseData,
1916
+ { abortEarly: false, allowUnknown: true }
1917
+ );
1918
+
1919
+ if (res_error) {
1920
+ if (this.config.options.strictResponseCheck === true) {
1921
+ return Promise.reject(new FDKResponseValidationError(res_error));
1922
+ } else {
1923
+ Logger({
1924
+ level: "WARN",
1925
+ message: `Response Validation Warnings for platform > Serviceability > getStoreRule \n ${res_error}`,
1926
+ });
1927
+ }
1928
+ }
1929
+
1930
+ return response;
1931
+ }
1932
+
1933
+ /**
1934
+ * @param {ServiceabilityPlatformApplicationValidator.GetStoreRuleDetailsParam} arg
1935
+ * - Arg object
1936
+ *
1937
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
1938
+ * @param {import("../PlatformAPIClient").Options} - Options
1939
+ * @returns {Promise<ServiceabilityPlatformModel.StoreRuleDataDetailsSchema>}
1940
+ * - Success response
1941
+ *
1942
+ * @name getStoreRuleDetails
1943
+ * @summary: Get store rule Details
1944
+ * @description: Retrieves details of a order routing rule. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/getStoreRuleDetails/).
1945
+ */
1946
+ async getStoreRuleDetails(
1947
+ { ruleUid, requestHeaders } = { requestHeaders: {} },
1948
+ { responseHeaders } = { responseHeaders: false }
1949
+ ) {
1950
+ const {
1951
+ error,
1952
+ } = ServiceabilityPlatformApplicationValidator.getStoreRuleDetails().validate(
1953
+ {
1954
+ ruleUid,
1955
+ },
1956
+ { abortEarly: false, allowUnknown: true }
1957
+ );
1958
+ if (error) {
1959
+ return Promise.reject(new FDKClientValidationError(error));
1960
+ }
1961
+
1962
+ // Showing warrnings if extra unknown parameters are found
1963
+ const {
1964
+ error: warrning,
1965
+ } = ServiceabilityPlatformApplicationValidator.getStoreRuleDetails().validate(
1966
+ {
1967
+ ruleUid,
1968
+ },
1969
+ { abortEarly: false, allowUnknown: false }
1970
+ );
1971
+ if (warrning) {
1972
+ Logger({
1973
+ level: "WARN",
1974
+ message: `Parameter Validation warrnings for platform > Serviceability > getStoreRuleDetails \n ${warrning}`,
1975
+ });
1976
+ }
1977
+
1978
+ const query_params = {};
1979
+
1980
+ const response = await PlatformAPIClient.execute(
1981
+ this.config,
1982
+ "get",
1983
+ `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/store/rules/${ruleUid}/details`,
1984
+ query_params,
1985
+ undefined,
1986
+ requestHeaders,
1987
+ { responseHeaders }
1988
+ );
1989
+
1990
+ let responseData = response;
1991
+ if (responseHeaders) {
1992
+ responseData = response[0];
1993
+ }
1994
+
1995
+ const {
1996
+ error: res_error,
1997
+ } = ServiceabilityPlatformModel.StoreRuleDataDetailsSchema().validate(
1998
+ responseData,
1999
+ { abortEarly: false, allowUnknown: true }
2000
+ );
2001
+
2002
+ if (res_error) {
2003
+ if (this.config.options.strictResponseCheck === true) {
2004
+ return Promise.reject(new FDKResponseValidationError(res_error));
2005
+ } else {
2006
+ Logger({
2007
+ level: "WARN",
2008
+ message: `Response Validation Warnings for platform > Serviceability > getStoreRuleDetails \n ${res_error}`,
2009
+ });
2010
+ }
2011
+ }
2012
+
2013
+ return response;
2014
+ }
2015
+
2016
+ /**
2017
+ * @param {ServiceabilityPlatformApplicationValidator.GetStoreRulesParam} arg
2018
+ * - Arg object
2019
+ *
2020
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
2021
+ * @param {import("../PlatformAPIClient").Options} - Options
2022
+ * @returns {Promise<ServiceabilityPlatformModel.GetStoreRulesApiResponse>}
2023
+ * - Success response
2024
+ *
2025
+ * @name getStoreRules
2026
+ * @summary: Get store rules
2027
+ * @description: Retrieves an existing order routing setup for a single application - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/getStoreRules/).
2028
+ */
2029
+ async getStoreRules(
2030
+ { pageNo, pageSize, status, requestHeaders } = { requestHeaders: {} },
2031
+ { responseHeaders } = { responseHeaders: false }
2032
+ ) {
2033
+ const {
2034
+ error,
2035
+ } = ServiceabilityPlatformApplicationValidator.getStoreRules().validate(
2036
+ {
2037
+ pageNo,
2038
+ pageSize,
2039
+ status,
2040
+ },
2041
+ { abortEarly: false, allowUnknown: true }
2042
+ );
2043
+ if (error) {
2044
+ return Promise.reject(new FDKClientValidationError(error));
2045
+ }
2046
+
2047
+ // Showing warrnings if extra unknown parameters are found
2048
+ const {
2049
+ error: warrning,
2050
+ } = ServiceabilityPlatformApplicationValidator.getStoreRules().validate(
2051
+ {
2052
+ pageNo,
2053
+ pageSize,
2054
+ status,
2055
+ },
2056
+ { abortEarly: false, allowUnknown: false }
2057
+ );
2058
+ if (warrning) {
2059
+ Logger({
2060
+ level: "WARN",
2061
+ message: `Parameter Validation warrnings for platform > Serviceability > getStoreRules \n ${warrning}`,
2062
+ });
2063
+ }
2064
+
2065
+ const query_params = {};
2066
+ query_params["page_no"] = pageNo;
2067
+ query_params["page_size"] = pageSize;
2068
+ query_params["status"] = status;
2069
+
2070
+ const response = await PlatformAPIClient.execute(
2071
+ this.config,
2072
+ "get",
2073
+ `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/store/rules`,
2074
+ query_params,
2075
+ undefined,
2076
+ requestHeaders,
2077
+ { responseHeaders }
2078
+ );
2079
+
2080
+ let responseData = response;
2081
+ if (responseHeaders) {
2082
+ responseData = response[0];
2083
+ }
2084
+
2085
+ const {
2086
+ error: res_error,
2087
+ } = ServiceabilityPlatformModel.GetStoreRulesApiResponse().validate(
2088
+ responseData,
2089
+ { abortEarly: false, allowUnknown: true }
2090
+ );
2091
+
2092
+ if (res_error) {
2093
+ if (this.config.options.strictResponseCheck === true) {
2094
+ return Promise.reject(new FDKResponseValidationError(res_error));
2095
+ } else {
2096
+ Logger({
2097
+ level: "WARN",
2098
+ message: `Response Validation Warnings for platform > Serviceability > getStoreRules \n ${res_error}`,
2099
+ });
2100
+ }
2101
+ }
2102
+
2103
+ return response;
2104
+ }
2105
+
2106
+ /**
2107
+ * @param {ServiceabilityPlatformApplicationValidator.GetZoneParam} arg - Arg object
2108
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
2109
+ * @param {import("../PlatformAPIClient").Options} - Options
2110
+ * @returns {Promise<ServiceabilityPlatformModel.GetZoneByIdSchema>} -
2111
+ * Success response
2112
+ * @name getZone
2113
+ * @summary: Get zone details
2114
+ * @description: Retrieves a single delivery zone - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/getZone/).
2115
+ */
2116
+ async getZone(
2117
+ { zoneId, requestHeaders } = { requestHeaders: {} },
2118
+ { responseHeaders } = { responseHeaders: false }
2119
+ ) {
2120
+ const {
2121
+ error,
2122
+ } = ServiceabilityPlatformApplicationValidator.getZone().validate(
2123
+ {
2124
+ zoneId,
2125
+ },
2126
+ { abortEarly: false, allowUnknown: true }
2127
+ );
2128
+ if (error) {
2129
+ return Promise.reject(new FDKClientValidationError(error));
2130
+ }
2131
+
2132
+ // Showing warrnings if extra unknown parameters are found
2133
+ const {
2134
+ error: warrning,
2135
+ } = ServiceabilityPlatformApplicationValidator.getZone().validate(
2136
+ {
2137
+ zoneId,
2138
+ },
2139
+ { abortEarly: false, allowUnknown: false }
2140
+ );
2141
+ if (warrning) {
2142
+ Logger({
2143
+ level: "WARN",
2144
+ message: `Parameter Validation warrnings for platform > Serviceability > getZone \n ${warrning}`,
2145
+ });
2146
+ }
2147
+
2148
+ const query_params = {};
2149
+
2150
+ const response = await PlatformAPIClient.execute(
2151
+ this.config,
2152
+ "get",
2153
+ `/service/platform/logistics/v2.0/company/${this.config.companyId}/application/${this.applicationId}/zones/${zoneId}`,
2154
+ query_params,
2155
+ undefined,
2156
+ requestHeaders,
2157
+ { responseHeaders }
2158
+ );
2159
+
2160
+ let responseData = response;
2161
+ if (responseHeaders) {
2162
+ responseData = response[0];
2163
+ }
2164
+
2165
+ const {
2166
+ error: res_error,
2167
+ } = ServiceabilityPlatformModel.GetZoneByIdSchema().validate(responseData, {
2168
+ abortEarly: false,
2169
+ allowUnknown: true,
2170
+ });
2171
+
2172
+ if (res_error) {
2173
+ if (this.config.options.strictResponseCheck === true) {
2174
+ return Promise.reject(new FDKResponseValidationError(res_error));
2175
+ } else {
2176
+ Logger({
2177
+ level: "WARN",
2178
+ message: `Response Validation Warnings for platform > Serviceability > getZone \n ${res_error}`,
2179
+ });
2180
+ }
2181
+ }
2182
+
2183
+ return response;
2184
+ }
2185
+
2186
+ /**
2187
+ * @param {ServiceabilityPlatformApplicationValidator.GetZoneDetailsParam} arg
2188
+ * - Arg object
2189
+ *
2190
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
2191
+ * @param {import("../PlatformAPIClient").Options} - Options
2192
+ * @returns {Promise<ServiceabilityPlatformModel.GetZoneByIdDetailsSchema>}
2193
+ * - Success response
2194
+ *
2195
+ * @name getZoneDetails
2196
+ * @summary: Get details of a delivery zone
2197
+ * @description: Get details of a single delivery zone along with product, store and region details. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/getZoneDetails/).
2198
+ */
2199
+ async getZoneDetails(
2200
+ { zoneId, requestHeaders } = { requestHeaders: {} },
2201
+ { responseHeaders } = { responseHeaders: false }
2202
+ ) {
2203
+ const {
2204
+ error,
2205
+ } = ServiceabilityPlatformApplicationValidator.getZoneDetails().validate(
2206
+ {
2207
+ zoneId,
2208
+ },
2209
+ { abortEarly: false, allowUnknown: true }
2210
+ );
2211
+ if (error) {
2212
+ return Promise.reject(new FDKClientValidationError(error));
2213
+ }
2214
+
2215
+ // Showing warrnings if extra unknown parameters are found
2216
+ const {
2217
+ error: warrning,
2218
+ } = ServiceabilityPlatformApplicationValidator.getZoneDetails().validate(
2219
+ {
2220
+ zoneId,
2221
+ },
2222
+ { abortEarly: false, allowUnknown: false }
2223
+ );
2224
+ if (warrning) {
2225
+ Logger({
2226
+ level: "WARN",
2227
+ message: `Parameter Validation warrnings for platform > Serviceability > getZoneDetails \n ${warrning}`,
2228
+ });
2229
+ }
2230
+
2231
+ const query_params = {};
2232
+
2233
+ const response = await PlatformAPIClient.execute(
2234
+ this.config,
2235
+ "get",
2236
+ `/service/platform/logistics/v2.0/company/${this.config.companyId}/application/${this.applicationId}/zones/${zoneId}/details`,
2237
+ query_params,
2238
+ undefined,
2239
+ requestHeaders,
2240
+ { responseHeaders }
2241
+ );
2242
+
2243
+ let responseData = response;
2244
+ if (responseHeaders) {
2245
+ responseData = response[0];
2246
+ }
2247
+
2248
+ const {
2249
+ error: res_error,
2250
+ } = ServiceabilityPlatformModel.GetZoneByIdDetailsSchema().validate(
2251
+ responseData,
2252
+ { abortEarly: false, allowUnknown: true }
2253
+ );
2254
+
2255
+ if (res_error) {
2256
+ if (this.config.options.strictResponseCheck === true) {
2257
+ return Promise.reject(new FDKResponseValidationError(res_error));
2258
+ } else {
2259
+ Logger({
2260
+ level: "WARN",
2261
+ message: `Response Validation Warnings for platform > Serviceability > getZoneDetails \n ${res_error}`,
2262
+ });
2263
+ }
2264
+ }
2265
+
2266
+ return response;
2267
+ }
2268
+
2269
+ /**
2270
+ * @param {ServiceabilityPlatformApplicationValidator.GetZonesParam} arg - Arg object
2271
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
2272
+ * @param {import("../PlatformAPIClient").Options} - Options
2273
+ * @returns {Promise<ServiceabilityPlatformModel.ListViewResponseV2>} -
2274
+ * Success response
2275
+ * @name getZones
2276
+ * @summary: Get zones
2277
+ * @description: Retrieves a list of delivery zones. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/getZones/).
2278
+ */
2279
+ async getZones(
2280
+ {
2281
+ stage,
2282
+ type,
2283
+ pageSize,
2284
+ pageNo,
2285
+ isActive,
2286
+ q,
2287
+ countryIsoCode,
2288
+ pincode,
2289
+ state,
2290
+ city,
2291
+ sector,
2292
+ requestHeaders,
2293
+ } = { requestHeaders: {} },
2294
+ { responseHeaders } = { responseHeaders: false }
2295
+ ) {
2296
+ const {
2297
+ error,
2298
+ } = ServiceabilityPlatformApplicationValidator.getZones().validate(
2299
+ {
2300
+ stage,
2301
+ type,
2302
+ pageSize,
2303
+ pageNo,
2304
+ isActive,
2305
+ q,
2306
+ countryIsoCode,
2307
+ pincode,
2308
+ state,
2309
+ city,
2310
+ sector,
2311
+ },
2312
+ { abortEarly: false, allowUnknown: true }
2313
+ );
2314
+ if (error) {
2315
+ return Promise.reject(new FDKClientValidationError(error));
2316
+ }
2317
+
2318
+ // Showing warrnings if extra unknown parameters are found
2319
+ const {
2320
+ error: warrning,
2321
+ } = ServiceabilityPlatformApplicationValidator.getZones().validate(
2322
+ {
2323
+ stage,
2324
+ type,
2325
+ pageSize,
2326
+ pageNo,
2327
+ isActive,
2328
+ q,
2329
+ countryIsoCode,
2330
+ pincode,
2331
+ state,
2332
+ city,
2333
+ sector,
2334
+ },
2335
+ { abortEarly: false, allowUnknown: false }
2336
+ );
2337
+ if (warrning) {
2338
+ Logger({
2339
+ level: "WARN",
2340
+ message: `Parameter Validation warrnings for platform > Serviceability > getZones \n ${warrning}`,
2341
+ });
2342
+ }
2343
+
2344
+ const query_params = {};
2345
+ query_params["stage"] = stage;
2346
+ query_params["type"] = type;
2347
+ query_params["page_size"] = pageSize;
2348
+ query_params["page_no"] = pageNo;
2349
+ query_params["is_active"] = isActive;
2350
+ query_params["q"] = q;
2351
+ query_params["country_iso_code"] = countryIsoCode;
2352
+ query_params["pincode"] = pincode;
2353
+ query_params["state"] = state;
2354
+ query_params["city"] = city;
2355
+ query_params["sector"] = sector;
2356
+
2357
+ const response = await PlatformAPIClient.execute(
2358
+ this.config,
2359
+ "get",
2360
+ `/service/platform/logistics/v2.0/company/${this.config.companyId}/application/${this.applicationId}/zones`,
2361
+ query_params,
2362
+ undefined,
2363
+ requestHeaders,
2364
+ { responseHeaders }
2365
+ );
2366
+
2367
+ let responseData = response;
2368
+ if (responseHeaders) {
2369
+ responseData = response[0];
2370
+ }
2371
+
2372
+ const {
2373
+ error: res_error,
2374
+ } = ServiceabilityPlatformModel.ListViewResponseV2().validate(
2375
+ responseData,
2376
+ { abortEarly: false, allowUnknown: true }
2377
+ );
2378
+
2379
+ if (res_error) {
2380
+ if (this.config.options.strictResponseCheck === true) {
2381
+ return Promise.reject(new FDKResponseValidationError(res_error));
2382
+ } else {
2383
+ Logger({
2384
+ level: "WARN",
2385
+ message: `Response Validation Warnings for platform > Serviceability > getZones \n ${res_error}`,
2386
+ });
2387
+ }
2388
+ }
2389
+
2390
+ return response;
2391
+ }
2392
+
2393
+ /**
2394
+ * @param {ServiceabilityPlatformApplicationValidator.InsertApplicationConfigParam} arg
2395
+ * - Arg object
2396
+ *
2397
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
2398
+ * @param {import("../PlatformAPIClient").Options} - Options
2399
+ * @returns {Promise<ServiceabilityPlatformModel.StoreRuleConfigData>} -
2400
+ * Success response
2401
+ * @name insertApplicationConfig
2402
+ * @summary: Create store rule configuration
2403
+ * @description: Creates a order routing setup for an application, which involves updating sorting settings or rule priorities. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/insertApplicationConfig/).
2404
+ */
2405
+ async insertApplicationConfig(
2406
+ { body, requestHeaders } = { requestHeaders: {} },
2407
+ { responseHeaders } = { responseHeaders: false }
2408
+ ) {
2409
+ const {
2410
+ error,
2411
+ } = ServiceabilityPlatformApplicationValidator.insertApplicationConfig().validate(
2412
+ {
2413
+ body,
2414
+ },
2415
+ { abortEarly: false, allowUnknown: true }
2416
+ );
2417
+ if (error) {
2418
+ return Promise.reject(new FDKClientValidationError(error));
2419
+ }
2420
+
2421
+ // Showing warrnings if extra unknown parameters are found
2422
+ const {
2423
+ error: warrning,
2424
+ } = ServiceabilityPlatformApplicationValidator.insertApplicationConfig().validate(
2425
+ {
2426
+ body,
2427
+ },
2428
+ { abortEarly: false, allowUnknown: false }
2429
+ );
2430
+ if (warrning) {
2431
+ Logger({
2432
+ level: "WARN",
2433
+ message: `Parameter Validation warrnings for platform > Serviceability > insertApplicationConfig \n ${warrning}`,
2434
+ });
2435
+ }
2436
+
2437
+ const query_params = {};
2438
+
2439
+ const response = await PlatformAPIClient.execute(
2440
+ this.config,
2441
+ "post",
2442
+ `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/store/configuration`,
2443
+ query_params,
2444
+ body,
2445
+ requestHeaders,
2446
+ { responseHeaders }
2447
+ );
2448
+
2449
+ let responseData = response;
2450
+ if (responseHeaders) {
2451
+ responseData = response[0];
2452
+ }
2453
+
2454
+ const {
2455
+ error: res_error,
2456
+ } = ServiceabilityPlatformModel.StoreRuleConfigData().validate(
2457
+ responseData,
2458
+ { abortEarly: false, allowUnknown: true }
2459
+ );
2460
+
2461
+ if (res_error) {
2462
+ if (this.config.options.strictResponseCheck === true) {
2463
+ return Promise.reject(new FDKResponseValidationError(res_error));
2464
+ } else {
2465
+ Logger({
2466
+ level: "WARN",
2467
+ message: `Response Validation Warnings for platform > Serviceability > insertApplicationConfig \n ${res_error}`,
2468
+ });
2469
+ }
2470
+ }
2471
+
2472
+ return response;
2473
+ }
2474
+
2475
+ /**
2476
+ * @param {ServiceabilityPlatformApplicationValidator.PatchApplicationConfigurationParam} arg
2477
+ * - Arg object
2478
+ *
2479
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
2480
+ * @param {import("../PlatformAPIClient").Options} - Options
2481
+ * @returns {Promise<ServiceabilityPlatformModel.ApplicationConfigPatchResponse>}
2482
+ * - Success response
2483
+ *
2484
+ * @name patchApplicationConfiguration
2485
+ * @summary: To patch any config which can be applied to application.
2486
+ * @description: Apply configs to application. Supports patching for buybox rule config and promise config. For reference, refer to examples - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/patchApplicationConfiguration/).
2487
+ */
2488
+ async patchApplicationConfiguration(
2489
+ { body, requestHeaders } = { requestHeaders: {} },
2490
+ { responseHeaders } = { responseHeaders: false }
2491
+ ) {
2492
+ const {
2493
+ error,
2494
+ } = ServiceabilityPlatformApplicationValidator.patchApplicationConfiguration().validate(
2495
+ {
2496
+ body,
2497
+ },
2498
+ { abortEarly: false, allowUnknown: true }
2499
+ );
2500
+ if (error) {
2501
+ return Promise.reject(new FDKClientValidationError(error));
2502
+ }
2503
+
2504
+ // Showing warrnings if extra unknown parameters are found
2505
+ const {
2506
+ error: warrning,
2507
+ } = ServiceabilityPlatformApplicationValidator.patchApplicationConfiguration().validate(
2508
+ {
2509
+ body,
2510
+ },
2511
+ { abortEarly: false, allowUnknown: false }
2512
+ );
2513
+ if (warrning) {
2514
+ Logger({
2515
+ level: "WARN",
2516
+ message: `Parameter Validation warrnings for platform > Serviceability > patchApplicationConfiguration \n ${warrning}`,
2517
+ });
2518
+ }
2519
+
2520
+ const query_params = {};
2521
+
2522
+ const response = await PlatformAPIClient.execute(
2523
+ this.config,
2524
+ "patch",
2525
+ `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/configuration`,
2526
+ query_params,
2527
+ body,
2528
+ requestHeaders,
2529
+ { responseHeaders }
2530
+ );
2531
+
2532
+ let responseData = response;
2533
+ if (responseHeaders) {
2534
+ responseData = response[0];
2535
+ }
2536
+
2537
+ const {
2538
+ error: res_error,
2539
+ } = ServiceabilityPlatformModel.ApplicationConfigPatchResponse().validate(
2540
+ responseData,
2541
+ { abortEarly: false, allowUnknown: true }
2542
+ );
2543
+
2544
+ if (res_error) {
2545
+ if (this.config.options.strictResponseCheck === true) {
2546
+ return Promise.reject(new FDKResponseValidationError(res_error));
2547
+ } else {
2548
+ Logger({
2549
+ level: "WARN",
2550
+ message: `Response Validation Warnings for platform > Serviceability > patchApplicationConfiguration \n ${res_error}`,
2551
+ });
2552
+ }
2553
+ }
2554
+
2555
+ return response;
2556
+ }
2557
+
2558
+ /**
2559
+ * @param {ServiceabilityPlatformApplicationValidator.UpdateApplicationConfigurationParam} arg
2560
+ * - Arg object
2561
+ *
2562
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
2563
+ * @param {import("../PlatformAPIClient").Options} - Options
2564
+ * @returns {Promise<ServiceabilityPlatformModel.ApplicationConfigPutResponse>}
2565
+ * - Success response
2566
+ *
2567
+ * @name updateApplicationConfiguration
2568
+ * @summary: Apply configuration to an application
2569
+ * @description: Apply configuration to application to set DP rules and Zone configuration - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/updateApplicationConfiguration/).
856
2570
  */
857
- async insertApplicationConfig(
2571
+ async updateApplicationConfiguration(
858
2572
  { body, requestHeaders } = { requestHeaders: {} },
859
2573
  { responseHeaders } = { responseHeaders: false }
860
2574
  ) {
861
2575
  const {
862
2576
  error,
863
- } = ServiceabilityPlatformApplicationValidator.insertApplicationConfig().validate(
2577
+ } = ServiceabilityPlatformApplicationValidator.updateApplicationConfiguration().validate(
864
2578
  {
865
2579
  body,
866
2580
  },
@@ -873,7 +2587,7 @@ class Serviceability {
873
2587
  // Showing warrnings if extra unknown parameters are found
874
2588
  const {
875
2589
  error: warrning,
876
- } = ServiceabilityPlatformApplicationValidator.insertApplicationConfig().validate(
2590
+ } = ServiceabilityPlatformApplicationValidator.updateApplicationConfiguration().validate(
877
2591
  {
878
2592
  body,
879
2593
  },
@@ -882,7 +2596,7 @@ class Serviceability {
882
2596
  if (warrning) {
883
2597
  Logger({
884
2598
  level: "WARN",
885
- message: `Parameter Validation warrnings for platform > Serviceability > insertApplicationConfig \n ${warrning}`,
2599
+ message: `Parameter Validation warrnings for platform > Serviceability > updateApplicationConfiguration \n ${warrning}`,
886
2600
  });
887
2601
  }
888
2602
 
@@ -890,8 +2604,8 @@ class Serviceability {
890
2604
 
891
2605
  const response = await PlatformAPIClient.execute(
892
2606
  this.config,
893
- "post",
894
- `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/store/configuration`,
2607
+ "put",
2608
+ `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/configuration`,
895
2609
  query_params,
896
2610
  body,
897
2611
  requestHeaders,
@@ -905,7 +2619,7 @@ class Serviceability {
905
2619
 
906
2620
  const {
907
2621
  error: res_error,
908
- } = ServiceabilityPlatformModel.StoreRuleConfigData().validate(
2622
+ } = ServiceabilityPlatformModel.ApplicationConfigPutResponse().validate(
909
2623
  responseData,
910
2624
  { abortEarly: false, allowUnknown: true }
911
2625
  );
@@ -916,7 +2630,7 @@ class Serviceability {
916
2630
  } else {
917
2631
  Logger({
918
2632
  level: "WARN",
919
- message: `Response Validation Warnings for platform > Serviceability > insertApplicationConfig \n ${res_error}`,
2633
+ message: `Response Validation Warnings for platform > Serviceability > updateApplicationConfiguration \n ${res_error}`,
920
2634
  });
921
2635
  }
922
2636
  }
@@ -925,26 +2639,26 @@ class Serviceability {
925
2639
  }
926
2640
 
927
2641
  /**
928
- * @param {ServiceabilityPlatformApplicationValidator.PatchApplicationServiceabilitySelfShipmentParam} arg
2642
+ * @param {ServiceabilityPlatformApplicationValidator.UpdateBulkGeoAreaParam} arg
929
2643
  * - Arg object
930
2644
  *
931
2645
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
932
2646
  * @param {import("../PlatformAPIClient").Options} - Options
933
- * @returns {Promise<ServiceabilityPlatformModel.ApplicationSelfShipConfigResult>}
934
- * - Success response
935
- *
936
- * @name patchApplicationServiceabilitySelfShipment
937
- * @summary: Update self ship configuration
938
- * @description: Updates self ship setup for an existing application - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/patchApplicationServiceabilitySelfShipment/).
2647
+ * @returns {Promise<ServiceabilityPlatformModel.BulkGeoAreaResult>} -
2648
+ * Success response
2649
+ * @name updateBulkGeoArea
2650
+ * @summary: Update geoareas and their associated regions in bulk.
2651
+ * @description: Update geoarea details and their associated regions through a CSV file in bulk. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/updateBulkGeoArea/).
939
2652
  */
940
- async patchApplicationServiceabilitySelfShipment(
941
- { body, requestHeaders } = { requestHeaders: {} },
2653
+ async updateBulkGeoArea(
2654
+ { geoareaId, body, requestHeaders } = { requestHeaders: {} },
942
2655
  { responseHeaders } = { responseHeaders: false }
943
2656
  ) {
944
2657
  const {
945
2658
  error,
946
- } = ServiceabilityPlatformApplicationValidator.patchApplicationServiceabilitySelfShipment().validate(
2659
+ } = ServiceabilityPlatformApplicationValidator.updateBulkGeoArea().validate(
947
2660
  {
2661
+ geoareaId,
948
2662
  body,
949
2663
  },
950
2664
  { abortEarly: false, allowUnknown: true }
@@ -956,8 +2670,9 @@ class Serviceability {
956
2670
  // Showing warrnings if extra unknown parameters are found
957
2671
  const {
958
2672
  error: warrning,
959
- } = ServiceabilityPlatformApplicationValidator.patchApplicationServiceabilitySelfShipment().validate(
2673
+ } = ServiceabilityPlatformApplicationValidator.updateBulkGeoArea().validate(
960
2674
  {
2675
+ geoareaId,
961
2676
  body,
962
2677
  },
963
2678
  { abortEarly: false, allowUnknown: false }
@@ -965,7 +2680,7 @@ class Serviceability {
965
2680
  if (warrning) {
966
2681
  Logger({
967
2682
  level: "WARN",
968
- message: `Parameter Validation warrnings for platform > Serviceability > patchApplicationServiceabilitySelfShipment \n ${warrning}`,
2683
+ message: `Parameter Validation warrnings for platform > Serviceability > updateBulkGeoArea \n ${warrning}`,
969
2684
  });
970
2685
  }
971
2686
 
@@ -973,8 +2688,8 @@ class Serviceability {
973
2688
 
974
2689
  const response = await PlatformAPIClient.execute(
975
2690
  this.config,
976
- "patch",
977
- `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/selfship`,
2691
+ "put",
2692
+ `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/geoareas/regions/bulk/${geoareaId}`,
978
2693
  query_params,
979
2694
  body,
980
2695
  requestHeaders,
@@ -988,10 +2703,10 @@ class Serviceability {
988
2703
 
989
2704
  const {
990
2705
  error: res_error,
991
- } = ServiceabilityPlatformModel.ApplicationSelfShipConfigResult().validate(
992
- responseData,
993
- { abortEarly: false, allowUnknown: true }
994
- );
2706
+ } = ServiceabilityPlatformModel.BulkGeoAreaResult().validate(responseData, {
2707
+ abortEarly: false,
2708
+ allowUnknown: true,
2709
+ });
995
2710
 
996
2711
  if (res_error) {
997
2712
  if (this.config.options.strictResponseCheck === true) {
@@ -999,7 +2714,7 @@ class Serviceability {
999
2714
  } else {
1000
2715
  Logger({
1001
2716
  level: "WARN",
1002
- message: `Response Validation Warnings for platform > Serviceability > patchApplicationServiceabilitySelfShipment \n ${res_error}`,
2717
+ message: `Response Validation Warnings for platform > Serviceability > updateBulkGeoArea \n ${res_error}`,
1003
2718
  });
1004
2719
  }
1005
2720
  }
@@ -1008,24 +2723,24 @@ class Serviceability {
1008
2723
  }
1009
2724
 
1010
2725
  /**
1011
- * @param {ServiceabilityPlatformApplicationValidator.UpdateApplicationConfigurationParam} arg
2726
+ * @param {ServiceabilityPlatformApplicationValidator.UpdateCourierPartnerRulePriorityParam} arg
1012
2727
  * - Arg object
1013
2728
  *
1014
2729
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
1015
2730
  * @param {import("../PlatformAPIClient").Options} - Options
1016
- * @returns {Promise<ServiceabilityPlatformModel.ApplicationConfig>} -
2731
+ * @returns {Promise<ServiceabilityPlatformModel.RulePriorityResponse>} -
1017
2732
  * Success response
1018
- * @name updateApplicationConfiguration
1019
- * @summary: Update delivery configuration
1020
- * @description: Updates an existing delivery setup for an application, which involves updating sorting settings or rule priorities. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/updateApplicationConfiguration/).
2733
+ * @name updateCourierPartnerRulePriority
2734
+ * @summary: Update courier partner rule priority
2735
+ * @description: Updates a courier partner rule priority for a single application - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/updateCourierPartnerRulePriority/).
1021
2736
  */
1022
- async updateApplicationConfiguration(
2737
+ async updateCourierPartnerRulePriority(
1023
2738
  { body, requestHeaders } = { requestHeaders: {} },
1024
2739
  { responseHeaders } = { responseHeaders: false }
1025
2740
  ) {
1026
2741
  const {
1027
2742
  error,
1028
- } = ServiceabilityPlatformApplicationValidator.updateApplicationConfiguration().validate(
2743
+ } = ServiceabilityPlatformApplicationValidator.updateCourierPartnerRulePriority().validate(
1029
2744
  {
1030
2745
  body,
1031
2746
  },
@@ -1038,7 +2753,7 @@ class Serviceability {
1038
2753
  // Showing warrnings if extra unknown parameters are found
1039
2754
  const {
1040
2755
  error: warrning,
1041
- } = ServiceabilityPlatformApplicationValidator.updateApplicationConfiguration().validate(
2756
+ } = ServiceabilityPlatformApplicationValidator.updateCourierPartnerRulePriority().validate(
1042
2757
  {
1043
2758
  body,
1044
2759
  },
@@ -1047,7 +2762,7 @@ class Serviceability {
1047
2762
  if (warrning) {
1048
2763
  Logger({
1049
2764
  level: "WARN",
1050
- message: `Parameter Validation warrnings for platform > Serviceability > updateApplicationConfiguration \n ${warrning}`,
2765
+ message: `Parameter Validation warrnings for platform > Serviceability > updateCourierPartnerRulePriority \n ${warrning}`,
1051
2766
  });
1052
2767
  }
1053
2768
 
@@ -1056,7 +2771,7 @@ class Serviceability {
1056
2771
  const response = await PlatformAPIClient.execute(
1057
2772
  this.config,
1058
2773
  "put",
1059
- `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/configuration`,
2774
+ `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/courier-partner/rules/priority`,
1060
2775
  query_params,
1061
2776
  body,
1062
2777
  requestHeaders,
@@ -1070,10 +2785,10 @@ class Serviceability {
1070
2785
 
1071
2786
  const {
1072
2787
  error: res_error,
1073
- } = ServiceabilityPlatformModel.ApplicationConfig().validate(responseData, {
1074
- abortEarly: false,
1075
- allowUnknown: true,
1076
- });
2788
+ } = ServiceabilityPlatformModel.RulePriorityResponse().validate(
2789
+ responseData,
2790
+ { abortEarly: false, allowUnknown: true }
2791
+ );
1077
2792
 
1078
2793
  if (res_error) {
1079
2794
  if (this.config.options.strictResponseCheck === true) {
@@ -1081,7 +2796,7 @@ class Serviceability {
1081
2796
  } else {
1082
2797
  Logger({
1083
2798
  level: "WARN",
1084
- message: `Response Validation Warnings for platform > Serviceability > updateApplicationConfiguration \n ${res_error}`,
2799
+ message: `Response Validation Warnings for platform > Serviceability > updateCourierPartnerRulePriority \n ${res_error}`,
1085
2800
  });
1086
2801
  }
1087
2802
  }
@@ -1090,25 +2805,27 @@ class Serviceability {
1090
2805
  }
1091
2806
 
1092
2807
  /**
1093
- * @param {ServiceabilityPlatformApplicationValidator.UpdateCourierPartnerRulePriorityParam} arg
2808
+ * @param {ServiceabilityPlatformApplicationValidator.UpdateCourierRuleParam} arg
1094
2809
  * - Arg object
1095
2810
  *
1096
2811
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
1097
2812
  * @param {import("../PlatformAPIClient").Options} - Options
1098
- * @returns {Promise<ServiceabilityPlatformModel.RulePriorityResult>} -
1099
- * Success response
1100
- * @name updateCourierPartnerRulePriority
1101
- * @summary: Update courier partner rule priority
1102
- * @description: Updates a courier partner rule priority for a single application - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/updateCourierPartnerRulePriority/).
2813
+ * @returns {Promise<ServiceabilityPlatformModel.CourierPartnerRuleResponseSchema>}
2814
+ * - Success response
2815
+ *
2816
+ * @name updateCourierRule
2817
+ * @summary: Update courier rule
2818
+ * @description: Updates an existing rule within the delivery configuration - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/updateCourierRule/).
1103
2819
  */
1104
- async updateCourierPartnerRulePriority(
1105
- { body, requestHeaders } = { requestHeaders: {} },
2820
+ async updateCourierRule(
2821
+ { ruleUid, body, requestHeaders } = { requestHeaders: {} },
1106
2822
  { responseHeaders } = { responseHeaders: false }
1107
2823
  ) {
1108
2824
  const {
1109
2825
  error,
1110
- } = ServiceabilityPlatformApplicationValidator.updateCourierPartnerRulePriority().validate(
2826
+ } = ServiceabilityPlatformApplicationValidator.updateCourierRule().validate(
1111
2827
  {
2828
+ ruleUid,
1112
2829
  body,
1113
2830
  },
1114
2831
  { abortEarly: false, allowUnknown: true }
@@ -1120,8 +2837,9 @@ class Serviceability {
1120
2837
  // Showing warrnings if extra unknown parameters are found
1121
2838
  const {
1122
2839
  error: warrning,
1123
- } = ServiceabilityPlatformApplicationValidator.updateCourierPartnerRulePriority().validate(
2840
+ } = ServiceabilityPlatformApplicationValidator.updateCourierRule().validate(
1124
2841
  {
2842
+ ruleUid,
1125
2843
  body,
1126
2844
  },
1127
2845
  { abortEarly: false, allowUnknown: false }
@@ -1129,7 +2847,7 @@ class Serviceability {
1129
2847
  if (warrning) {
1130
2848
  Logger({
1131
2849
  level: "WARN",
1132
- message: `Parameter Validation warrnings for platform > Serviceability > updateCourierPartnerRulePriority \n ${warrning}`,
2850
+ message: `Parameter Validation warrnings for platform > Serviceability > updateCourierRule \n ${warrning}`,
1133
2851
  });
1134
2852
  }
1135
2853
 
@@ -1138,7 +2856,7 @@ class Serviceability {
1138
2856
  const response = await PlatformAPIClient.execute(
1139
2857
  this.config,
1140
2858
  "put",
1141
- `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/courier-partner/rules/priority`,
2859
+ `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/courier-partner/rules/${ruleUid}`,
1142
2860
  query_params,
1143
2861
  body,
1144
2862
  requestHeaders,
@@ -1152,7 +2870,7 @@ class Serviceability {
1152
2870
 
1153
2871
  const {
1154
2872
  error: res_error,
1155
- } = ServiceabilityPlatformModel.RulePriorityResult().validate(
2873
+ } = ServiceabilityPlatformModel.CourierPartnerRuleResponseSchema().validate(
1156
2874
  responseData,
1157
2875
  { abortEarly: false, allowUnknown: true }
1158
2876
  );
@@ -1163,7 +2881,7 @@ class Serviceability {
1163
2881
  } else {
1164
2882
  Logger({
1165
2883
  level: "WARN",
1166
- message: `Response Validation Warnings for platform > Serviceability > updateCourierPartnerRulePriority \n ${res_error}`,
2884
+ message: `Response Validation Warnings for platform > Serviceability > updateCourierRule \n ${res_error}`,
1167
2885
  });
1168
2886
  }
1169
2887
  }
@@ -1172,27 +2890,27 @@ class Serviceability {
1172
2890
  }
1173
2891
 
1174
2892
  /**
1175
- * @param {ServiceabilityPlatformApplicationValidator.UpdateCourierRuleParam} arg
2893
+ * @param {ServiceabilityPlatformApplicationValidator.UpdateGeoAreaParam} arg
1176
2894
  * - Arg object
1177
2895
  *
1178
2896
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
1179
2897
  * @param {import("../PlatformAPIClient").Options} - Options
1180
- * @returns {Promise<ServiceabilityPlatformModel.CourierPartnerRuleResult>}
1181
- * - Success response
1182
- *
1183
- * @name updateCourierRule
1184
- * @summary: Update courier rule
1185
- * @description: Updates an existing rule within the delivery configuration. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/updateCourierRule/).
2898
+ * @returns {Promise<ServiceabilityPlatformModel.GeoAreaPutResponseBody>} -
2899
+ * Success response
2900
+ * @name updateGeoArea
2901
+ * @summary: Update the details of existing GeoArea
2902
+ * @description: Updates the GeoArea with a new name, regions, etc. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/updateGeoArea/).
1186
2903
  */
1187
- async updateCourierRule(
1188
- { ruleId, body, requestHeaders } = { requestHeaders: {} },
2904
+ async updateGeoArea(
2905
+ { geoareaId, body, requestHeaders } = { requestHeaders: {} },
1189
2906
  { responseHeaders } = { responseHeaders: false }
1190
2907
  ) {
1191
2908
  const {
1192
2909
  error,
1193
- } = ServiceabilityPlatformApplicationValidator.updateCourierRule().validate(
2910
+ } = ServiceabilityPlatformApplicationValidator.updateGeoArea().validate(
1194
2911
  {
1195
- ruleId,
2912
+ geoareaId,
2913
+
1196
2914
  body,
1197
2915
  },
1198
2916
  { abortEarly: false, allowUnknown: true }
@@ -1204,9 +2922,10 @@ class Serviceability {
1204
2922
  // Showing warrnings if extra unknown parameters are found
1205
2923
  const {
1206
2924
  error: warrning,
1207
- } = ServiceabilityPlatformApplicationValidator.updateCourierRule().validate(
2925
+ } = ServiceabilityPlatformApplicationValidator.updateGeoArea().validate(
1208
2926
  {
1209
- ruleId,
2927
+ geoareaId,
2928
+
1210
2929
  body,
1211
2930
  },
1212
2931
  { abortEarly: false, allowUnknown: false }
@@ -1214,7 +2933,7 @@ class Serviceability {
1214
2933
  if (warrning) {
1215
2934
  Logger({
1216
2935
  level: "WARN",
1217
- message: `Parameter Validation warrnings for platform > Serviceability > updateCourierRule \n ${warrning}`,
2936
+ message: `Parameter Validation warrnings for platform > Serviceability > updateGeoArea \n ${warrning}`,
1218
2937
  });
1219
2938
  }
1220
2939
 
@@ -1223,7 +2942,7 @@ class Serviceability {
1223
2942
  const response = await PlatformAPIClient.execute(
1224
2943
  this.config,
1225
2944
  "put",
1226
- `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/courier-partner/rules/${ruleId}`,
2945
+ `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/geoareas/${geoareaId}`,
1227
2946
  query_params,
1228
2947
  body,
1229
2948
  requestHeaders,
@@ -1237,7 +2956,7 @@ class Serviceability {
1237
2956
 
1238
2957
  const {
1239
2958
  error: res_error,
1240
- } = ServiceabilityPlatformModel.CourierPartnerRuleResult().validate(
2959
+ } = ServiceabilityPlatformModel.GeoAreaPutResponseBody().validate(
1241
2960
  responseData,
1242
2961
  { abortEarly: false, allowUnknown: true }
1243
2962
  );
@@ -1248,7 +2967,7 @@ class Serviceability {
1248
2967
  } else {
1249
2968
  Logger({
1250
2969
  level: "WARN",
1251
- message: `Response Validation Warnings for platform > Serviceability > updateCourierRule \n ${res_error}`,
2970
+ message: `Response Validation Warnings for platform > Serviceability > updateGeoArea \n ${res_error}`,
1252
2971
  });
1253
2972
  }
1254
2973
  }
@@ -1262,7 +2981,7 @@ class Serviceability {
1262
2981
  *
1263
2982
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
1264
2983
  * @param {import("../PlatformAPIClient").Options} - Options
1265
- * @returns {Promise<ServiceabilityPlatformModel.PincodeMopUpdateAuditHistoryResultData>}
2984
+ * @returns {Promise<ServiceabilityPlatformModel.PincodeMopUpdateAuditHistoryResponseData>}
1266
2985
  * - Success response
1267
2986
  *
1268
2987
  * @name updatePincodeAuditHistory
@@ -1270,7 +2989,7 @@ class Serviceability {
1270
2989
  * @description: Retrieves the history of changes made to cash on delivery settings for pincodes. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/updatePincodeAuditHistory/).
1271
2990
  */
1272
2991
  async updatePincodeAuditHistory(
1273
- { body, pageNumber, pageSize, requestHeaders } = { requestHeaders: {} },
2992
+ { body, requestHeaders } = { requestHeaders: {} },
1274
2993
  { responseHeaders } = { responseHeaders: false }
1275
2994
  ) {
1276
2995
  const {
@@ -1278,8 +2997,6 @@ class Serviceability {
1278
2997
  } = ServiceabilityPlatformApplicationValidator.updatePincodeAuditHistory().validate(
1279
2998
  {
1280
2999
  body,
1281
- pageNumber,
1282
- pageSize,
1283
3000
  },
1284
3001
  { abortEarly: false, allowUnknown: true }
1285
3002
  );
@@ -1293,8 +3010,6 @@ class Serviceability {
1293
3010
  } = ServiceabilityPlatformApplicationValidator.updatePincodeAuditHistory().validate(
1294
3011
  {
1295
3012
  body,
1296
- pageNumber,
1297
- pageSize,
1298
3013
  },
1299
3014
  { abortEarly: false, allowUnknown: false }
1300
3015
  );
@@ -1306,8 +3021,6 @@ class Serviceability {
1306
3021
  }
1307
3022
 
1308
3023
  const query_params = {};
1309
- query_params["page_number"] = pageNumber;
1310
- query_params["page_size"] = pageSize;
1311
3024
 
1312
3025
  const response = await PlatformAPIClient.execute(
1313
3026
  this.config,
@@ -1326,7 +3039,7 @@ class Serviceability {
1326
3039
 
1327
3040
  const {
1328
3041
  error: res_error,
1329
- } = ServiceabilityPlatformModel.PincodeMopUpdateAuditHistoryResultData().validate(
3042
+ } = ServiceabilityPlatformModel.PincodeMopUpdateAuditHistoryResponseData().validate(
1330
3043
  responseData,
1331
3044
  { abortEarly: false, allowUnknown: true }
1332
3045
  );
@@ -1351,8 +3064,9 @@ class Serviceability {
1351
3064
  *
1352
3065
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
1353
3066
  * @param {import("../PlatformAPIClient").Options} - Options
1354
- * @returns {Promise<ServiceabilityPlatformModel.PincodeBulkViewResult>} -
1355
- * Success response
3067
+ * @returns {Promise<ServiceabilityPlatformModel.PincodeBulkViewResponse>}
3068
+ * - Success response
3069
+ *
1356
3070
  * @name updatePincodeBulkView
1357
3071
  * @summary: Bulk update pincode COD support
1358
3072
  * @description: Updates the cash on delivery settings for multiple specified pin codes simultaneously. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/updatePincodeBulkView/).
@@ -1408,7 +3122,7 @@ class Serviceability {
1408
3122
 
1409
3123
  const {
1410
3124
  error: res_error,
1411
- } = ServiceabilityPlatformModel.PincodeBulkViewResult().validate(
3125
+ } = ServiceabilityPlatformModel.PincodeBulkViewResponse().validate(
1412
3126
  responseData,
1413
3127
  { abortEarly: false, allowUnknown: true }
1414
3128
  );
@@ -1433,7 +3147,7 @@ class Serviceability {
1433
3147
  *
1434
3148
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
1435
3149
  * @param {import("../PlatformAPIClient").Options} - Options
1436
- * @returns {Promise<ServiceabilityPlatformModel.PincodeCodStatusListingResult>}
3150
+ * @returns {Promise<ServiceabilityPlatformModel.PincodeCodStatusListingResponse>}
1437
3151
  * - Success response
1438
3152
  *
1439
3153
  * @name updatePincodeCoDListing
@@ -1441,7 +3155,7 @@ class Serviceability {
1441
3155
  * @description: Retrieves a list of pincodes along with the count based on whether cash on delivery settings. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/updatePincodeCoDListing/).
1442
3156
  */
1443
3157
  async updatePincodeCoDListing(
1444
- { body, pageNumber, pageSize, requestHeaders } = { requestHeaders: {} },
3158
+ { body, requestHeaders } = { requestHeaders: {} },
1445
3159
  { responseHeaders } = { responseHeaders: false }
1446
3160
  ) {
1447
3161
  const {
@@ -1449,8 +3163,6 @@ class Serviceability {
1449
3163
  } = ServiceabilityPlatformApplicationValidator.updatePincodeCoDListing().validate(
1450
3164
  {
1451
3165
  body,
1452
- pageNumber,
1453
- pageSize,
1454
3166
  },
1455
3167
  { abortEarly: false, allowUnknown: true }
1456
3168
  );
@@ -1464,8 +3176,6 @@ class Serviceability {
1464
3176
  } = ServiceabilityPlatformApplicationValidator.updatePincodeCoDListing().validate(
1465
3177
  {
1466
3178
  body,
1467
- pageNumber,
1468
- pageSize,
1469
3179
  },
1470
3180
  { abortEarly: false, allowUnknown: false }
1471
3181
  );
@@ -1477,8 +3187,6 @@ class Serviceability {
1477
3187
  }
1478
3188
 
1479
3189
  const query_params = {};
1480
- query_params["page_number"] = pageNumber;
1481
- query_params["page_size"] = pageSize;
1482
3190
 
1483
3191
  const response = await PlatformAPIClient.execute(
1484
3192
  this.config,
@@ -1497,7 +3205,7 @@ class Serviceability {
1497
3205
 
1498
3206
  const {
1499
3207
  error: res_error,
1500
- } = ServiceabilityPlatformModel.PincodeCodStatusListingResult().validate(
3208
+ } = ServiceabilityPlatformModel.PincodeCodStatusListingResponse().validate(
1501
3209
  responseData,
1502
3210
  { abortEarly: false, allowUnknown: true }
1503
3211
  );
@@ -1522,7 +3230,8 @@ class Serviceability {
1522
3230
  *
1523
3231
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
1524
3232
  * @param {import("../PlatformAPIClient").Options} - Options
1525
- * @returns {Promise<ServiceabilityPlatformModel.PincodeMOPResult>} - Success response
3233
+ * @returns {Promise<ServiceabilityPlatformModel.PincodeMOPresponse>} -
3234
+ * Success response
1526
3235
  * @name updatePincodeMopView
1527
3236
  * @summary: Update pincode COD support
1528
3237
  * @description: Modify and update views related to pincode MOP (Mode of Payment). - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/updatePincodeMopView/).
@@ -1578,10 +3287,10 @@ class Serviceability {
1578
3287
 
1579
3288
  const {
1580
3289
  error: res_error,
1581
- } = ServiceabilityPlatformModel.PincodeMOPResult().validate(responseData, {
1582
- abortEarly: false,
1583
- allowUnknown: true,
1584
- });
3290
+ } = ServiceabilityPlatformModel.PincodeMOPresponse().validate(
3291
+ responseData,
3292
+ { abortEarly: false, allowUnknown: true }
3293
+ );
1585
3294
 
1586
3295
  if (res_error) {
1587
3296
  if (this.config.options.strictResponseCheck === true) {
@@ -1597,13 +3306,95 @@ class Serviceability {
1597
3306
  return response;
1598
3307
  }
1599
3308
 
3309
+ /**
3310
+ * @param {ServiceabilityPlatformApplicationValidator.UpdateStoreRulePriorityParam} arg
3311
+ * - Arg object
3312
+ *
3313
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
3314
+ * @param {import("../PlatformAPIClient").Options} - Options
3315
+ * @returns {Promise<ServiceabilityPlatformModel.RulePriorityResponse>} -
3316
+ * Success response
3317
+ * @name updateStoreRulePriority
3318
+ * @summary: Update Store Rule priority
3319
+ * @description: Update Store Rule priority - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/updateStoreRulePriority/).
3320
+ */
3321
+ async updateStoreRulePriority(
3322
+ { body, requestHeaders } = { requestHeaders: {} },
3323
+ { responseHeaders } = { responseHeaders: false }
3324
+ ) {
3325
+ const {
3326
+ error,
3327
+ } = ServiceabilityPlatformApplicationValidator.updateStoreRulePriority().validate(
3328
+ {
3329
+ body,
3330
+ },
3331
+ { abortEarly: false, allowUnknown: true }
3332
+ );
3333
+ if (error) {
3334
+ return Promise.reject(new FDKClientValidationError(error));
3335
+ }
3336
+
3337
+ // Showing warrnings if extra unknown parameters are found
3338
+ const {
3339
+ error: warrning,
3340
+ } = ServiceabilityPlatformApplicationValidator.updateStoreRulePriority().validate(
3341
+ {
3342
+ body,
3343
+ },
3344
+ { abortEarly: false, allowUnknown: false }
3345
+ );
3346
+ if (warrning) {
3347
+ Logger({
3348
+ level: "WARN",
3349
+ message: `Parameter Validation warrnings for platform > Serviceability > updateStoreRulePriority \n ${warrning}`,
3350
+ });
3351
+ }
3352
+
3353
+ const query_params = {};
3354
+
3355
+ const response = await PlatformAPIClient.execute(
3356
+ this.config,
3357
+ "put",
3358
+ `/service/platform/logistics/v1.0/company/${this.config.companyId}/application/${this.applicationId}/store/rules/priority`,
3359
+ query_params,
3360
+ body,
3361
+ requestHeaders,
3362
+ { responseHeaders }
3363
+ );
3364
+
3365
+ let responseData = response;
3366
+ if (responseHeaders) {
3367
+ responseData = response[0];
3368
+ }
3369
+
3370
+ const {
3371
+ error: res_error,
3372
+ } = ServiceabilityPlatformModel.RulePriorityResponse().validate(
3373
+ responseData,
3374
+ { abortEarly: false, allowUnknown: true }
3375
+ );
3376
+
3377
+ if (res_error) {
3378
+ if (this.config.options.strictResponseCheck === true) {
3379
+ return Promise.reject(new FDKResponseValidationError(res_error));
3380
+ } else {
3381
+ Logger({
3382
+ level: "WARN",
3383
+ message: `Response Validation Warnings for platform > Serviceability > updateStoreRulePriority \n ${res_error}`,
3384
+ });
3385
+ }
3386
+ }
3387
+
3388
+ return response;
3389
+ }
3390
+
1600
3391
  /**
1601
3392
  * @param {ServiceabilityPlatformApplicationValidator.UpdateStoreRulesParam} arg
1602
3393
  * - Arg object
1603
3394
  *
1604
3395
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
1605
3396
  * @param {import("../PlatformAPIClient").Options} - Options
1606
- * @returns {Promise<ServiceabilityPlatformModel.StoreRuleUpdateResultSchema>}
3397
+ * @returns {Promise<ServiceabilityPlatformModel.StoreRuleUpdateResponseSchema>}
1607
3398
  * - Success response
1608
3399
  *
1609
3400
  * @name updateStoreRules
@@ -1663,7 +3454,7 @@ class Serviceability {
1663
3454
 
1664
3455
  const {
1665
3456
  error: res_error,
1666
- } = ServiceabilityPlatformModel.StoreRuleUpdateResultSchema().validate(
3457
+ } = ServiceabilityPlatformModel.StoreRuleUpdateResponseSchema().validate(
1667
3458
  responseData,
1668
3459
  { abortEarly: false, allowUnknown: true }
1669
3460
  );
@@ -1763,6 +3554,93 @@ class Serviceability {
1763
3554
 
1764
3555
  return response;
1765
3556
  }
3557
+
3558
+ /**
3559
+ * @param {ServiceabilityPlatformApplicationValidator.UpdateZoneParam} arg
3560
+ * - Arg object
3561
+ *
3562
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
3563
+ * @param {import("../PlatformAPIClient").Options} - Options
3564
+ * @returns {Promise<ServiceabilityPlatformModel.ZoneUpdateSuccessResponse>}
3565
+ * - Success response
3566
+ *
3567
+ * @name updateZone
3568
+ * @summary: Update details of a Zone to enable or disable.
3569
+ * @description: Enable or Disable a Zone under that application. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/serviceability/updateZone/).
3570
+ */
3571
+ async updateZone(
3572
+ { zoneId, body, requestHeaders } = { requestHeaders: {} },
3573
+ { responseHeaders } = { responseHeaders: false }
3574
+ ) {
3575
+ const {
3576
+ error,
3577
+ } = ServiceabilityPlatformApplicationValidator.updateZone().validate(
3578
+ {
3579
+ zoneId,
3580
+
3581
+ body,
3582
+ },
3583
+ { abortEarly: false, allowUnknown: true }
3584
+ );
3585
+ if (error) {
3586
+ return Promise.reject(new FDKClientValidationError(error));
3587
+ }
3588
+
3589
+ // Showing warrnings if extra unknown parameters are found
3590
+ const {
3591
+ error: warrning,
3592
+ } = ServiceabilityPlatformApplicationValidator.updateZone().validate(
3593
+ {
3594
+ zoneId,
3595
+
3596
+ body,
3597
+ },
3598
+ { abortEarly: false, allowUnknown: false }
3599
+ );
3600
+ if (warrning) {
3601
+ Logger({
3602
+ level: "WARN",
3603
+ message: `Parameter Validation warrnings for platform > Serviceability > updateZone \n ${warrning}`,
3604
+ });
3605
+ }
3606
+
3607
+ const query_params = {};
3608
+
3609
+ const response = await PlatformAPIClient.execute(
3610
+ this.config,
3611
+ "patch",
3612
+ `/service/platform/logistics/v2.0/company/${this.config.companyId}/application/${this.applicationId}/zones/${zoneId}`,
3613
+ query_params,
3614
+ body,
3615
+ requestHeaders,
3616
+ { responseHeaders }
3617
+ );
3618
+
3619
+ let responseData = response;
3620
+ if (responseHeaders) {
3621
+ responseData = response[0];
3622
+ }
3623
+
3624
+ const {
3625
+ error: res_error,
3626
+ } = ServiceabilityPlatformModel.ZoneUpdateSuccessResponse().validate(
3627
+ responseData,
3628
+ { abortEarly: false, allowUnknown: true }
3629
+ );
3630
+
3631
+ if (res_error) {
3632
+ if (this.config.options.strictResponseCheck === true) {
3633
+ return Promise.reject(new FDKResponseValidationError(res_error));
3634
+ } else {
3635
+ Logger({
3636
+ level: "WARN",
3637
+ message: `Response Validation Warnings for platform > Serviceability > updateZone \n ${res_error}`,
3638
+ });
3639
+ }
3640
+ }
3641
+
3642
+ return response;
3643
+ }
1766
3644
  }
1767
3645
 
1768
3646
  module.exports = Serviceability;