@gofynd/fdk-client-javascript 1.1.6 → 1.2.0

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 (321) hide show
  1. package/README.md +12 -0
  2. package/index.js +0 -3
  3. package/package.json +1 -1
  4. package/sdk/application/ApplicationAPIClient.d.ts +15 -1
  5. package/sdk/application/ApplicationAPIClient.js +8 -1
  6. package/sdk/application/ApplicationClient.d.ts +37 -6
  7. package/sdk/application/ApplicationClient.js +31 -0
  8. package/sdk/application/ApplicationConfig.d.ts +52 -12
  9. package/sdk/application/ApplicationConfig.js +37 -2
  10. package/sdk/application/ApplicationModels.d.ts +46 -1
  11. package/sdk/application/ApplicationModels.js +18 -0
  12. package/sdk/application/Cart/CartApplicationClient.d.ts +172 -357
  13. package/sdk/application/Cart/CartApplicationClient.js +620 -483
  14. package/sdk/application/Cart/CartApplicationModel.d.ts +2054 -96
  15. package/sdk/application/Cart/CartApplicationModel.js +1224 -93
  16. package/sdk/application/Cart/CartApplicationValidator.d.ts +508 -30
  17. package/sdk/application/Cart/CartApplicationValidator.js +270 -15
  18. package/sdk/application/Catalog/CatalogApplicationClient.d.ts +234 -413
  19. package/sdk/application/Catalog/CatalogApplicationClient.js +777 -630
  20. package/sdk/application/Catalog/CatalogApplicationModel.d.ts +2218 -117
  21. package/sdk/application/Catalog/CatalogApplicationModel.js +1499 -170
  22. package/sdk/application/Catalog/CatalogApplicationValidator.d.ts +798 -31
  23. package/sdk/application/Catalog/CatalogApplicationValidator.js +318 -3
  24. package/sdk/application/Common/CommonApplicationClient.d.ts +14 -21
  25. package/sdk/application/Common/CommonApplicationClient.js +50 -33
  26. package/sdk/application/Common/CommonApplicationModel.d.ts +448 -19
  27. package/sdk/application/Common/CommonApplicationModel.js +224 -16
  28. package/sdk/application/Common/CommonApplicationValidator.d.ts +42 -4
  29. package/sdk/application/Common/CommonApplicationValidator.js +21 -3
  30. package/sdk/application/Communication/CommunicationApplicationClient.d.ts +25 -18
  31. package/sdk/application/Communication/CommunicationApplicationClient.js +74 -47
  32. package/sdk/application/Communication/CommunicationApplicationModel.d.ts +190 -14
  33. package/sdk/application/Communication/CommunicationApplicationModel.js +124 -7
  34. package/sdk/application/Communication/CommunicationApplicationValidator.d.ts +27 -4
  35. package/sdk/application/Communication/CommunicationApplicationValidator.js +21 -5
  36. package/sdk/application/Configuration/ConfigurationApplicationClient.d.ts +113 -112
  37. package/sdk/application/Configuration/ConfigurationApplicationClient.js +381 -260
  38. package/sdk/application/Configuration/ConfigurationApplicationModel.d.ts +2453 -110
  39. package/sdk/application/Configuration/ConfigurationApplicationModel.js +1254 -108
  40. package/sdk/application/Configuration/ConfigurationApplicationValidator.d.ts +160 -8
  41. package/sdk/application/Configuration/ConfigurationApplicationValidator.js +88 -4
  42. package/sdk/application/Content/ContentApplicationClient.d.ts +120 -138
  43. package/sdk/application/Content/ContentApplicationClient.js +409 -277
  44. package/sdk/application/Content/ContentApplicationModel.d.ts +1627 -105
  45. package/sdk/application/Content/ContentApplicationModel.js +1202 -109
  46. package/sdk/application/Content/ContentApplicationValidator.d.ts +214 -12
  47. package/sdk/application/Content/ContentApplicationValidator.js +113 -3
  48. package/sdk/application/FileStorage/FileStorageApplicationClient.d.ts +20 -29
  49. package/sdk/application/FileStorage/FileStorageApplicationClient.js +68 -47
  50. package/sdk/application/FileStorage/FileStorageApplicationModel.d.ts +299 -20
  51. package/sdk/application/FileStorage/FileStorageApplicationModel.js +209 -16
  52. package/sdk/application/FileStorage/FileStorageApplicationValidator.d.ts +55 -5
  53. package/sdk/application/FileStorage/FileStorageApplicationValidator.js +33 -6
  54. package/sdk/application/Lead/LeadApplicationClient.d.ts +50 -53
  55. package/sdk/application/Lead/LeadApplicationClient.js +169 -103
  56. package/sdk/application/Lead/LeadApplicationModel.d.ts +1405 -54
  57. package/sdk/application/Lead/LeadApplicationModel.js +619 -73
  58. package/sdk/application/Lead/LeadApplicationValidator.d.ts +91 -9
  59. package/sdk/application/Lead/LeadApplicationValidator.js +51 -6
  60. package/sdk/application/Logistic/LogisticApplicationClient.d.ts +34 -33
  61. package/sdk/application/Logistic/LogisticApplicationClient.js +110 -73
  62. package/sdk/application/Logistic/LogisticApplicationModel.d.ts +399 -28
  63. package/sdk/application/Logistic/LogisticApplicationModel.js +293 -24
  64. package/sdk/application/Logistic/LogisticApplicationValidator.d.ts +48 -6
  65. package/sdk/application/Logistic/LogisticApplicationValidator.js +34 -6
  66. package/sdk/application/Order/OrderApplicationClient.d.ts +81 -133
  67. package/sdk/application/Order/OrderApplicationClient.js +297 -217
  68. package/sdk/application/Order/OrderApplicationModel.d.ts +1101 -66
  69. package/sdk/application/Order/OrderApplicationModel.js +776 -57
  70. package/sdk/application/Order/OrderApplicationValidator.d.ts +249 -14
  71. package/sdk/application/Order/OrderApplicationValidator.js +114 -5
  72. package/sdk/application/Payment/PaymentApplicationClient.d.ts +341 -356
  73. package/sdk/application/Payment/PaymentApplicationClient.js +1077 -703
  74. package/sdk/application/Payment/PaymentApplicationModel.d.ts +3125 -99
  75. package/sdk/application/Payment/PaymentApplicationModel.js +1158 -62
  76. package/sdk/application/Payment/PaymentApplicationValidator.d.ts +494 -41
  77. package/sdk/application/Payment/PaymentApplicationValidator.js +297 -25
  78. package/sdk/application/PosCart/PosCartApplicationClient.d.ts +178 -350
  79. package/sdk/application/PosCart/PosCartApplicationClient.js +636 -491
  80. package/sdk/application/PosCart/PosCartApplicationModel.d.ts +1823 -89
  81. package/sdk/application/PosCart/PosCartApplicationModel.js +1117 -85
  82. package/sdk/application/PosCart/PosCartApplicationValidator.d.ts +480 -29
  83. package/sdk/application/PosCart/PosCartApplicationValidator.js +262 -15
  84. package/sdk/application/Rewards/RewardsApplicationClient.d.ts +49 -47
  85. package/sdk/application/Rewards/RewardsApplicationClient.js +160 -102
  86. package/sdk/application/Rewards/RewardsApplicationModel.d.ts +343 -22
  87. package/sdk/application/Rewards/RewardsApplicationModel.js +230 -15
  88. package/sdk/application/Rewards/RewardsApplicationValidator.d.ts +70 -7
  89. package/sdk/application/Rewards/RewardsApplicationValidator.js +45 -6
  90. package/sdk/application/Share/ShareApplicationClient.d.ts +44 -50
  91. package/sdk/application/Share/ShareApplicationClient.js +165 -97
  92. package/sdk/application/Share/ShareApplicationModel.d.ts +230 -15
  93. package/sdk/application/Share/ShareApplicationModel.js +154 -16
  94. package/sdk/application/Share/ShareApplicationValidator.d.ts +86 -8
  95. package/sdk/application/Share/ShareApplicationValidator.js +48 -4
  96. package/sdk/application/Theme/ThemeApplicationClient.d.ts +25 -27
  97. package/sdk/application/Theme/ThemeApplicationClient.js +83 -54
  98. package/sdk/application/Theme/ThemeApplicationModel.d.ts +621 -48
  99. package/sdk/application/Theme/ThemeApplicationModel.js +464 -40
  100. package/sdk/application/Theme/ThemeApplicationValidator.d.ts +49 -5
  101. package/sdk/application/Theme/ThemeApplicationValidator.js +26 -3
  102. package/sdk/application/User/UserApplicationClient.d.ts +219 -303
  103. package/sdk/application/User/UserApplicationClient.js +819 -522
  104. package/sdk/application/User/UserApplicationModel.d.ts +1390 -101
  105. package/sdk/application/User/UserApplicationModel.js +983 -44
  106. package/sdk/application/User/UserApplicationValidator.d.ts +457 -33
  107. package/sdk/application/User/UserApplicationValidator.js +265 -31
  108. package/sdk/common/AxiosHelper.js +8 -2
  109. package/sdk/common/Paginator.d.ts +27 -12
  110. package/sdk/common/Paginator.js +15 -0
  111. package/sdk/common/RequestSigner.js +0 -1
  112. package/sdk/partner/PartnerAPIClient.d.ts +15 -1
  113. package/sdk/partner/PartnerAPIClient.js +8 -1
  114. package/sdk/partner/PartnerClient.d.ts +20 -3
  115. package/sdk/partner/PartnerClient.js +17 -0
  116. package/sdk/partner/PartnerConfig.d.ts +40 -14
  117. package/sdk/partner/PartnerConfig.js +31 -6
  118. package/sdk/platform/AuditTrail/AuditTrailPlatformClient.d.ts +26 -25
  119. package/sdk/platform/AuditTrail/AuditTrailPlatformClient.js +82 -53
  120. package/sdk/platform/AuditTrail/AuditTrailPlatformModel.d.ts +202 -17
  121. package/sdk/platform/AuditTrail/AuditTrailPlatformModel.js +139 -10
  122. package/sdk/platform/AuditTrail/AuditTrailPlatformValidator.d.ts +42 -5
  123. package/sdk/platform/AuditTrail/AuditTrailPlatformValidator.js +26 -4
  124. package/sdk/platform/Billing/BillingPlatformClient.d.ts +88 -97
  125. package/sdk/platform/Billing/BillingPlatformClient.js +310 -191
  126. package/sdk/platform/Billing/BillingPlatformModel.d.ts +1211 -68
  127. package/sdk/platform/Billing/BillingPlatformModel.js +824 -59
  128. package/sdk/platform/Billing/BillingPlatformValidator.d.ts +153 -12
  129. package/sdk/platform/Billing/BillingPlatformValidator.js +87 -8
  130. package/sdk/platform/Cart/CartPlatformApplicationClient.d.ts +392 -634
  131. package/sdk/platform/Cart/CartPlatformApplicationClient.js +1480 -957
  132. package/sdk/platform/Cart/CartPlatformApplicationValidator.d.ts +827 -57
  133. package/sdk/platform/Cart/CartPlatformApplicationValidator.js +492 -34
  134. package/sdk/platform/Cart/CartPlatformModel.d.ts +3639 -175
  135. package/sdk/platform/Cart/CartPlatformModel.js +2368 -212
  136. package/sdk/platform/Catalog/CatalogPlatformApplicationClient.d.ts +438 -615
  137. package/sdk/platform/Catalog/CatalogPlatformApplicationClient.js +1449 -984
  138. package/sdk/platform/Catalog/CatalogPlatformApplicationValidator.d.ts +1081 -49
  139. package/sdk/platform/Catalog/CatalogPlatformApplicationValidator.js +482 -23
  140. package/sdk/platform/Catalog/CatalogPlatformClient.d.ts +573 -824
  141. package/sdk/platform/Catalog/CatalogPlatformClient.js +1773 -1264
  142. package/sdk/platform/Catalog/CatalogPlatformModel.d.ts +6871 -326
  143. package/sdk/platform/Catalog/CatalogPlatformModel.js +4215 -349
  144. package/sdk/platform/Catalog/CatalogPlatformValidator.d.ts +1331 -71
  145. package/sdk/platform/Catalog/CatalogPlatformValidator.js +611 -30
  146. package/sdk/platform/Common/CommonPlatformClient.d.ts +14 -21
  147. package/sdk/platform/Common/CommonPlatformClient.js +48 -33
  148. package/sdk/platform/Common/CommonPlatformModel.d.ts +448 -19
  149. package/sdk/platform/Common/CommonPlatformModel.js +224 -16
  150. package/sdk/platform/Common/CommonPlatformValidator.d.ts +42 -4
  151. package/sdk/platform/Common/CommonPlatformValidator.js +21 -3
  152. package/sdk/platform/Communication/CommunicationPlatformApplicationClient.d.ts +457 -279
  153. package/sdk/platform/Communication/CommunicationPlatformApplicationClient.js +1423 -553
  154. package/sdk/platform/Communication/CommunicationPlatformApplicationValidator.d.ts +581 -42
  155. package/sdk/platform/Communication/CommunicationPlatformApplicationValidator.js +294 -22
  156. package/sdk/platform/Communication/CommunicationPlatformClient.d.ts +18 -5
  157. package/sdk/platform/Communication/CommunicationPlatformClient.js +58 -19
  158. package/sdk/platform/Communication/CommunicationPlatformModel.d.ts +1630 -102
  159. package/sdk/platform/Communication/CommunicationPlatformModel.js +1150 -85
  160. package/sdk/platform/Communication/CommunicationPlatformValidator.d.ts +16 -3
  161. package/sdk/platform/Communication/CommunicationPlatformValidator.js +11 -3
  162. package/sdk/platform/CompanyProfile/CompanyProfilePlatformClient.d.ts +102 -111
  163. package/sdk/platform/CompanyProfile/CompanyProfilePlatformClient.js +321 -225
  164. package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.d.ts +830 -43
  165. package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.js +612 -78
  166. package/sdk/platform/CompanyProfile/CompanyProfilePlatformValidator.d.ts +180 -13
  167. package/sdk/platform/CompanyProfile/CompanyProfilePlatformValidator.js +98 -10
  168. package/sdk/platform/Configuration/ConfigurationPlatformApplicationClient.d.ts +232 -212
  169. package/sdk/platform/Configuration/ConfigurationPlatformApplicationClient.js +737 -438
  170. package/sdk/platform/Configuration/ConfigurationPlatformApplicationValidator.d.ts +293 -22
  171. package/sdk/platform/Configuration/ConfigurationPlatformApplicationValidator.js +184 -17
  172. package/sdk/platform/Configuration/ConfigurationPlatformClient.d.ts +166 -178
  173. package/sdk/platform/Configuration/ConfigurationPlatformClient.js +519 -310
  174. package/sdk/platform/Configuration/ConfigurationPlatformModel.d.ts +4504 -188
  175. package/sdk/platform/Configuration/ConfigurationPlatformModel.js +2242 -204
  176. package/sdk/platform/Configuration/ConfigurationPlatformValidator.d.ts +332 -19
  177. package/sdk/platform/Configuration/ConfigurationPlatformValidator.js +153 -10
  178. package/sdk/platform/Content/ContentPlatformApplicationClient.d.ts +495 -560
  179. package/sdk/platform/Content/ContentPlatformApplicationClient.js +1777 -987
  180. package/sdk/platform/Content/ContentPlatformApplicationValidator.d.ts +872 -62
  181. package/sdk/platform/Content/ContentPlatformApplicationValidator.js +487 -35
  182. package/sdk/platform/Content/ContentPlatformModel.d.ts +1661 -108
  183. package/sdk/platform/Content/ContentPlatformModel.js +1217 -113
  184. package/sdk/platform/Discount/DiscountPlatformClient.d.ts +67 -101
  185. package/sdk/platform/Discount/DiscountPlatformClient.js +240 -176
  186. package/sdk/platform/Discount/DiscountPlatformModel.d.ts +242 -15
  187. package/sdk/platform/Discount/DiscountPlatformModel.js +162 -10
  188. package/sdk/platform/Discount/DiscountPlatformValidator.d.ts +185 -13
  189. package/sdk/platform/Discount/DiscountPlatformValidator.js +88 -8
  190. package/sdk/platform/FileStorage/FileStoragePlatformApplicationClient.d.ts +32 -41
  191. package/sdk/platform/FileStorage/FileStoragePlatformApplicationClient.js +106 -74
  192. package/sdk/platform/FileStorage/FileStoragePlatformApplicationValidator.d.ts +77 -6
  193. package/sdk/platform/FileStorage/FileStoragePlatformApplicationValidator.js +41 -6
  194. package/sdk/platform/FileStorage/FileStoragePlatformClient.d.ts +39 -54
  195. package/sdk/platform/FileStorage/FileStoragePlatformClient.js +124 -99
  196. package/sdk/platform/FileStorage/FileStoragePlatformModel.d.ts +299 -20
  197. package/sdk/platform/FileStorage/FileStoragePlatformModel.js +207 -16
  198. package/sdk/platform/FileStorage/FileStoragePlatformValidator.d.ts +98 -8
  199. package/sdk/platform/FileStorage/FileStoragePlatformValidator.js +54 -7
  200. package/sdk/platform/Finance/FinancePlatformClient.d.ts +85 -91
  201. package/sdk/platform/Finance/FinancePlatformClient.js +272 -180
  202. package/sdk/platform/Finance/FinancePlatformModel.d.ts +619 -50
  203. package/sdk/platform/Finance/FinancePlatformModel.js +458 -30
  204. package/sdk/platform/Finance/FinancePlatformValidator.d.ts +123 -15
  205. package/sdk/platform/Finance/FinancePlatformValidator.js +95 -16
  206. package/sdk/platform/Inventory/InventoryPlatformClient.d.ts +99 -97
  207. package/sdk/platform/Inventory/InventoryPlatformClient.js +288 -199
  208. package/sdk/platform/Inventory/InventoryPlatformModel.d.ts +1354 -61
  209. package/sdk/platform/Inventory/InventoryPlatformModel.js +916 -83
  210. package/sdk/platform/Inventory/InventoryPlatformValidator.d.ts +168 -12
  211. package/sdk/platform/Inventory/InventoryPlatformValidator.js +82 -6
  212. package/sdk/platform/Lead/LeadPlatformApplicationClient.d.ts +86 -106
  213. package/sdk/platform/Lead/LeadPlatformApplicationClient.js +326 -186
  214. package/sdk/platform/Lead/LeadPlatformApplicationValidator.d.ts +180 -14
  215. package/sdk/platform/Lead/LeadPlatformApplicationValidator.js +94 -9
  216. package/sdk/platform/Lead/LeadPlatformClient.d.ts +75 -101
  217. package/sdk/platform/Lead/LeadPlatformClient.js +240 -174
  218. package/sdk/platform/Lead/LeadPlatformModel.d.ts +1403 -54
  219. package/sdk/platform/Lead/LeadPlatformModel.js +618 -73
  220. package/sdk/platform/Lead/LeadPlatformValidator.d.ts +173 -12
  221. package/sdk/platform/Lead/LeadPlatformValidator.js +85 -8
  222. package/sdk/platform/Order/OrderPlatformApplicationClient.d.ts +18 -14
  223. package/sdk/platform/Order/OrderPlatformApplicationClient.js +56 -29
  224. package/sdk/platform/Order/OrderPlatformApplicationValidator.d.ts +26 -4
  225. package/sdk/platform/Order/OrderPlatformApplicationValidator.js +16 -3
  226. package/sdk/platform/Order/OrderPlatformClient.d.ts +343 -556
  227. package/sdk/platform/Order/OrderPlatformClient.js +969 -762
  228. package/sdk/platform/Order/OrderPlatformModel.d.ts +4967 -247
  229. package/sdk/platform/Order/OrderPlatformModel.js +3249 -259
  230. package/sdk/platform/Order/OrderPlatformValidator.d.ts +758 -37
  231. package/sdk/platform/Order/OrderPlatformValidator.js +351 -22
  232. package/sdk/platform/Partner/PartnerPlatformApplicationClient.d.ts +28 -36
  233. package/sdk/platform/Partner/PartnerPlatformApplicationClient.js +103 -59
  234. package/sdk/platform/Partner/PartnerPlatformApplicationValidator.d.ts +66 -6
  235. package/sdk/platform/Partner/PartnerPlatformApplicationValidator.js +32 -4
  236. package/sdk/platform/Partner/PartnerPlatformClient.d.ts +68 -107
  237. package/sdk/platform/Partner/PartnerPlatformClient.js +253 -174
  238. package/sdk/platform/Partner/PartnerPlatformModel.d.ts +767 -45
  239. package/sdk/platform/Partner/PartnerPlatformModel.js +524 -41
  240. package/sdk/platform/Partner/PartnerPlatformValidator.d.ts +207 -13
  241. package/sdk/platform/Partner/PartnerPlatformValidator.js +87 -5
  242. package/sdk/platform/Payment/PaymentPlatformApplicationClient.d.ts +255 -260
  243. package/sdk/platform/Payment/PaymentPlatformApplicationClient.js +860 -504
  244. package/sdk/platform/Payment/PaymentPlatformApplicationValidator.d.ts +348 -30
  245. package/sdk/platform/Payment/PaymentPlatformApplicationValidator.js +221 -19
  246. package/sdk/platform/Payment/PaymentPlatformClient.d.ts +73 -73
  247. package/sdk/platform/Payment/PaymentPlatformClient.js +238 -154
  248. package/sdk/platform/Payment/PaymentPlatformModel.d.ts +2658 -93
  249. package/sdk/platform/Payment/PaymentPlatformModel.js +1035 -36
  250. package/sdk/platform/Payment/PaymentPlatformValidator.d.ts +111 -11
  251. package/sdk/platform/Payment/PaymentPlatformValidator.js +68 -7
  252. package/sdk/platform/PlatformAPIClient.d.ts +16 -1
  253. package/sdk/platform/PlatformAPIClient.js +9 -1
  254. package/sdk/platform/PlatformApplicationClient.d.ts +22 -1798
  255. package/sdk/platform/PlatformApplicationClient.js +17 -1899
  256. package/sdk/platform/PlatformClient.d.ts +29 -12579
  257. package/sdk/platform/PlatformClient.js +26 -15085
  258. package/sdk/platform/PlatformConfig.d.ts +37 -11
  259. package/sdk/platform/PlatformConfig.js +32 -6
  260. package/sdk/platform/Rewards/RewardsPlatformApplicationClient.d.ts +80 -92
  261. package/sdk/platform/Rewards/RewardsPlatformApplicationClient.js +307 -177
  262. package/sdk/platform/Rewards/RewardsPlatformApplicationValidator.d.ts +149 -12
  263. package/sdk/platform/Rewards/RewardsPlatformApplicationValidator.js +82 -8
  264. package/sdk/platform/Rewards/RewardsPlatformModel.d.ts +371 -23
  265. package/sdk/platform/Rewards/RewardsPlatformModel.js +246 -16
  266. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationClient.d.ts +120 -89
  267. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationClient.js +349 -201
  268. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationValidator.d.ts +128 -12
  269. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationValidator.js +85 -11
  270. package/sdk/platform/Serviceability/ServiceabilityPlatformClient.d.ts +148 -178
  271. package/sdk/platform/Serviceability/ServiceabilityPlatformClient.js +454 -329
  272. package/sdk/platform/Serviceability/ServiceabilityPlatformModel.d.ts +1399 -96
  273. package/sdk/platform/Serviceability/ServiceabilityPlatformModel.js +1022 -71
  274. package/sdk/platform/Serviceability/ServiceabilityPlatformValidator.d.ts +280 -18
  275. package/sdk/platform/Serviceability/ServiceabilityPlatformValidator.js +134 -11
  276. package/sdk/platform/Share/SharePlatformApplicationClient.d.ts +38 -47
  277. package/sdk/platform/Share/SharePlatformApplicationClient.js +137 -73
  278. package/sdk/platform/Share/SharePlatformApplicationValidator.d.ts +87 -7
  279. package/sdk/platform/Share/SharePlatformApplicationValidator.js +42 -5
  280. package/sdk/platform/Share/SharePlatformModel.d.ts +250 -16
  281. package/sdk/platform/Share/SharePlatformModel.js +165 -17
  282. package/sdk/platform/Theme/ThemePlatformApplicationClient.d.ts +149 -183
  283. package/sdk/platform/Theme/ThemePlatformApplicationClient.js +579 -330
  284. package/sdk/platform/Theme/ThemePlatformApplicationValidator.d.ts +308 -24
  285. package/sdk/platform/Theme/ThemePlatformApplicationValidator.js +162 -10
  286. package/sdk/platform/Theme/ThemePlatformModel.d.ts +621 -48
  287. package/sdk/platform/Theme/ThemePlatformModel.js +464 -40
  288. package/sdk/platform/User/UserPlatformApplicationClient.d.ts +119 -151
  289. package/sdk/platform/User/UserPlatformApplicationClient.js +411 -244
  290. package/sdk/platform/User/UserPlatformApplicationValidator.d.ts +235 -18
  291. package/sdk/platform/User/UserPlatformApplicationValidator.js +126 -12
  292. package/sdk/platform/User/UserPlatformModel.d.ts +1390 -101
  293. package/sdk/platform/User/UserPlatformModel.js +983 -44
  294. package/sdk/platform/Webhook/WebhookPlatformClient.d.ts +38 -47
  295. package/sdk/platform/Webhook/WebhookPlatformClient.js +137 -87
  296. package/sdk/platform/Webhook/WebhookPlatformModel.d.ts +242 -16
  297. package/sdk/platform/Webhook/WebhookPlatformModel.js +167 -18
  298. package/sdk/platform/Webhook/WebhookPlatformValidator.d.ts +83 -7
  299. package/sdk/platform/Webhook/WebhookPlatformValidator.js +43 -5
  300. package/sdk/public/Configuration/ConfigurationPublicClient.d.ts +14 -21
  301. package/sdk/public/Configuration/ConfigurationPublicClient.js +46 -33
  302. package/sdk/public/Configuration/ConfigurationPublicModel.d.ts +473 -19
  303. package/sdk/public/Configuration/ConfigurationPublicModel.js +224 -16
  304. package/sdk/public/Configuration/ConfigurationPublicValidator.d.ts +42 -4
  305. package/sdk/public/Configuration/ConfigurationPublicValidator.js +21 -3
  306. package/sdk/public/Inventory/InventoryPublicClient.d.ts +48 -48
  307. package/sdk/public/Inventory/InventoryPublicClient.js +146 -98
  308. package/sdk/public/Inventory/InventoryPublicModel.d.ts +392 -21
  309. package/sdk/public/Inventory/InventoryPublicModel.js +267 -27
  310. package/sdk/public/Inventory/InventoryPublicValidator.d.ts +90 -8
  311. package/sdk/public/Inventory/InventoryPublicValidator.js +44 -4
  312. package/sdk/public/PublicClient.d.ts +19 -3
  313. package/sdk/public/PublicClient.js +16 -0
  314. package/sdk/public/PublicConfig.d.ts +27 -6
  315. package/sdk/public/PublicConfig.js +17 -1
  316. package/sdk/public/Webhook/WebhookPublicClient.d.ts +13 -11
  317. package/sdk/public/Webhook/WebhookPublicClient.js +42 -27
  318. package/sdk/public/Webhook/WebhookPublicModel.d.ts +242 -16
  319. package/sdk/public/Webhook/WebhookPublicModel.js +167 -18
  320. package/sdk/public/Webhook/WebhookPublicValidator.d.ts +18 -3
  321. package/sdk/public/Webhook/WebhookPublicValidator.js +14 -4
@@ -1,6 +1,1792 @@
1
1
  const Joi = require("joi");
2
2
 
3
- class CartModel {
3
+ /**
4
+ * @typedef AbandonedCart
5
+ * @property {string} _id
6
+ * @property {string} [app_id]
7
+ * @property {Object[]} articles
8
+ * @property {number} [bulk_coupon_discount]
9
+ * @property {boolean} [buy_now]
10
+ * @property {number} [cart_value]
11
+ * @property {Object} cashback
12
+ * @property {string} [checkout_mode]
13
+ * @property {Object} [cod_charges]
14
+ * @property {string} [comment]
15
+ * @property {Object} [coupon]
16
+ * @property {string} created_on
17
+ * @property {Object} [delivery_charges]
18
+ * @property {number} [discount]
19
+ * @property {string} expire_at
20
+ * @property {number[]} [fc_index_map]
21
+ * @property {Object} [fynd_credits]
22
+ * @property {string} [gstin]
23
+ * @property {boolean} [is_active]
24
+ * @property {boolean} [is_archive]
25
+ * @property {boolean} is_default
26
+ * @property {string} last_modified
27
+ * @property {boolean} [merge_qty]
28
+ * @property {Object} [meta]
29
+ * @property {string} [order_id]
30
+ * @property {Object[]} [payment_methods]
31
+ * @property {string} [payment_mode]
32
+ * @property {Object} [payments]
33
+ * @property {Object} [pick_up_customer_details]
34
+ * @property {Object} [promotion]
35
+ * @property {Object[]} [shipments]
36
+ * @property {number} uid
37
+ * @property {string} user_id
38
+ */
39
+
40
+ /**
41
+ * @typedef AbandonedCartResponse
42
+ * @property {AbandonedCart[]} [items]
43
+ * @property {string} [message] - Message of the response
44
+ * @property {Page} [page]
45
+ * @property {Object} [result]
46
+ * @property {boolean} [success] - The request success is defined
47
+ */
48
+
49
+ /**
50
+ * @typedef ActionQuery
51
+ * @property {string[]} [product_slug] - Contains list of product slug
52
+ */
53
+
54
+ /**
55
+ * @typedef ActivePromosResponse
56
+ * @property {string} [created_on] - Coupon creation date
57
+ * @property {string} [description] - The description of the offer in the form of an HTML
58
+ * @property {string} [entity_slug]
59
+ * @property {string} [entity_type] - Type of entity to be selected from :
60
+ * ['coupon', 'promotion']
61
+ * @property {string} [example] - Discount offers examples
62
+ * @property {boolean} [is_hidden] - If the promo is active or not
63
+ * @property {string} [modified_on] - Coupon modification date
64
+ * @property {string} [subtitle] - Small description of the current offer
65
+ * @property {string} [title] - Name of the promotion
66
+ * @property {string} [type] - Coupon type
67
+ */
68
+
69
+ /**
70
+ * @typedef AddCartDetailResponse
71
+ * @property {CartDetailResponse} [cart]
72
+ * @property {string} [message]
73
+ * @property {boolean} [partial] - When adding multiple items check if all
74
+ * added. True if only few are added.
75
+ * @property {boolean} [success] - True if all items are added successfully.
76
+ * False if partially added or not added.
77
+ */
78
+
79
+ /**
80
+ * @typedef AddCartRequest
81
+ * @property {AddProductCart[]} [items]
82
+ * @property {boolean} [new_cart]
83
+ */
84
+
85
+ /**
86
+ * @typedef AddProductCart
87
+ * @property {Object} [_custom_json]
88
+ * @property {Object} [article_assignment]
89
+ * @property {string} [article_id]
90
+ * @property {string} [display]
91
+ * @property {Object} [extra_meta]
92
+ * @property {number} [item_id]
93
+ * @property {string} [item_size]
94
+ * @property {Object} [meta]
95
+ * @property {Object[]} [parent_item_identifiers]
96
+ * @property {boolean} [pos]
97
+ * @property {string[]} [product_group_tags]
98
+ * @property {number} [quantity]
99
+ * @property {number} [seller_id]
100
+ * @property {number} [store_id]
101
+ */
102
+
103
+ /**
104
+ * @typedef AppliedFreeArticles
105
+ * @property {string} [article_id] - Free article id
106
+ * @property {FreeGiftItem} [free_gift_item_details] - Free gift items details
107
+ * @property {string} [parent_item_identifier] - Parent item identifier for free article
108
+ * @property {number} [quantity] - Free article quantity
109
+ */
110
+
111
+ /**
112
+ * @typedef AppliedPromotion
113
+ * @property {number} [amount] - Per unit discount amount applied with current promotion
114
+ * @property {AppliedFreeArticles[]} [applied_free_articles] - Applied free
115
+ * article for free gift item promotions
116
+ * @property {number} [article_quantity] - Quantity of article on which
117
+ * promotion is applicable
118
+ * @property {BuyRules[]} [buy_rules] - Buy rules for promotions
119
+ * @property {DiscountRulesApp[]} [discount_rules] - Discount rules for promotions
120
+ * @property {boolean} [mrp_promotion] - If applied promotion is applied on
121
+ * product MRP or ESP
122
+ * @property {string} [offer_text] - Offer text of current promotion
123
+ * @property {Ownership2} [ownership] - Ownership of promotion
124
+ * @property {string} [promo_id] - Promotion id
125
+ * @property {string} [promotion_group] - Promotion group for the promotion
126
+ * @property {string} [promotion_name] - Promotion name of current promotion
127
+ * @property {string} [promotion_type] - Promotion type of current promotion
128
+ */
129
+
130
+ /**
131
+ * @typedef ApplyCouponRequest
132
+ * @property {string} coupon_code - Coupon code to be applied
133
+ */
134
+
135
+ /**
136
+ * @typedef Article
137
+ * @property {string} article_id
138
+ * @property {string} [code]
139
+ * @property {Object} [meta]
140
+ * @property {string} [type]
141
+ * @property {number} [value]
142
+ */
143
+
144
+ /**
145
+ * @typedef ArticlePriceInfo
146
+ * @property {BasePrice} [base]
147
+ * @property {BasePrice} [converted]
148
+ */
149
+
150
+ /**
151
+ * @typedef BaseInfo
152
+ * @property {string} [name]
153
+ * @property {number} [uid]
154
+ */
155
+
156
+ /**
157
+ * @typedef BasePrice
158
+ * @property {string} [currency_code]
159
+ * @property {string} [currency_symbol]
160
+ * @property {number} [effective]
161
+ * @property {number} [marked]
162
+ */
163
+
164
+ /**
165
+ * @typedef BulkBundleRestriction
166
+ * @property {boolean} multi_store_allowed
167
+ */
168
+
169
+ /**
170
+ * @typedef BuyRules
171
+ * @property {Object} [cart_conditions] - Cart conditions details for promotion
172
+ * @property {Object} [item_criteria] - Item criteria of promotion
173
+ */
174
+
175
+ /**
176
+ * @typedef CartBreakup
177
+ * @property {CouponBreakup} [coupon]
178
+ * @property {DisplayBreakup[]} [display]
179
+ * @property {LoyaltyPoints} [loyalty_points]
180
+ * @property {RawBreakup} [raw]
181
+ */
182
+
183
+ /**
184
+ * @typedef CartCheckoutResponse
185
+ * @property {string} [app_intercept_url]
186
+ * @property {string} [callback_url]
187
+ * @property {CheckCart} [cart]
188
+ * @property {Object} [data]
189
+ * @property {string} [message]
190
+ * @property {string} [order_id]
191
+ * @property {string} [payment_confirm_url]
192
+ * @property {boolean} [success]
193
+ */
194
+
195
+ /**
196
+ * @typedef CartCurrency
197
+ * @property {string} [code] - Currency code defined by ISO 4217:2015
198
+ * @property {string} [symbol]
199
+ */
200
+
201
+ /**
202
+ * @typedef CartDeliveryModesResponse
203
+ * @property {string[]} [available_modes] - Available delivery modes
204
+ * @property {number[]} [pickup_stores] - Store pick up available store uids
205
+ */
206
+
207
+ /**
208
+ * @typedef CartDetailResponse
209
+ * @property {AppliedPromotion[]} [applied_promo_details]
210
+ * @property {CartBreakup} [breakup_values]
211
+ * @property {boolean} [buy_now]
212
+ * @property {string} [checkout_mode]
213
+ * @property {string} [comment]
214
+ * @property {string} [coupon_text]
215
+ * @property {CartCurrency} [currency]
216
+ * @property {string} [delivery_charge_info]
217
+ * @property {ShipmentPromise} [delivery_promise]
218
+ * @property {string} [gstin]
219
+ * @property {string} [id]
220
+ * @property {boolean} [is_valid]
221
+ * @property {CartProductInfo[]} [items]
222
+ * @property {string} [last_modified]
223
+ * @property {string} [message]
224
+ * @property {Object} [pan_config]
225
+ * @property {string} [pan_no]
226
+ * @property {PaymentSelectionLock} [payment_selection_lock]
227
+ * @property {boolean} [restrict_checkout]
228
+ */
229
+
230
+ /**
231
+ * @typedef CartItem
232
+ * @property {string} product_id
233
+ * @property {number} [quantity]
234
+ * @property {string} size
235
+ */
236
+
237
+ /**
238
+ * @typedef CartItemCountResponse
239
+ * @property {number} [user_cart_items_count] - Item count present in cart
240
+ */
241
+
242
+ /**
243
+ * @typedef CartItemMeta
244
+ * @property {string} [group_id]
245
+ * @property {boolean} [primary_item]
246
+ */
247
+
248
+ /**
249
+ * @typedef CartList
250
+ * @property {string} [cart_id]
251
+ * @property {number} [cart_value]
252
+ * @property {string} [created_on]
253
+ * @property {number} [item_counts]
254
+ * @property {Object} [pick_up_customer_details]
255
+ * @property {string} [user_id]
256
+ */
257
+
258
+ /**
259
+ * @typedef CartMetaConfigAdd
260
+ * @property {boolean} [bulk_coupons]
261
+ * @property {DeliveryCharges} [delivery_charges]
262
+ * @property {boolean} [enabled]
263
+ * @property {string} [gift_display_text]
264
+ * @property {number} [gift_pricing]
265
+ * @property {number} [max_cart_items]
266
+ * @property {number} [min_cart_value]
267
+ * @property {boolean} [revenue_engine_coupon]
268
+ */
269
+
270
+ /**
271
+ * @typedef CartMetaConfigUpdate
272
+ * @property {boolean} [bulk_coupons]
273
+ * @property {DeliveryCharges} [delivery_charges]
274
+ * @property {boolean} [enabled]
275
+ * @property {string} [gift_display_text]
276
+ * @property {number} [gift_pricing]
277
+ * @property {number} [max_cart_items]
278
+ * @property {number} [min_cart_value]
279
+ * @property {boolean} [revenue_engine_coupon]
280
+ */
281
+
282
+ /**
283
+ * @typedef CartMetaMissingResponse
284
+ * @property {string[]} [errors]
285
+ */
286
+
287
+ /**
288
+ * @typedef CartMetaResponse
289
+ * @property {boolean} [is_valid]
290
+ * @property {string} [message]
291
+ */
292
+
293
+ /**
294
+ * @typedef CartProduct
295
+ * @property {Object} [_custom_json]
296
+ * @property {ProductAction} [action]
297
+ * @property {BaseInfo} [brand]
298
+ * @property {CategoryInfo[]} [categories]
299
+ * @property {ProductImage[]} [images]
300
+ * @property {string} [item_code]
301
+ * @property {string} [name]
302
+ * @property {string} [slug] - Unique product url name generated via product
303
+ * name and other meta data
304
+ * @property {string[]} [tags]
305
+ * @property {Tags} [teaser_tag]
306
+ * @property {string} [type]
307
+ * @property {number} [uid]
308
+ */
309
+
310
+ /**
311
+ * @typedef CartProductIdentifer
312
+ * @property {string} [identifier] - Article idenfier generated by cart
313
+ */
314
+
315
+ /**
316
+ * @typedef CartProductInfo
317
+ * @property {ProductArticle} [article]
318
+ * @property {ProductAvailability} [availability]
319
+ * @property {Object} [bulk_offer]
320
+ * @property {CouponDetails} [coupon]
321
+ * @property {string} [coupon_message]
322
+ * @property {Object} [custom_order]
323
+ * @property {ShipmentPromise} [delivery_promise]
324
+ * @property {string} [discount]
325
+ * @property {CartProductIdentifer} identifiers
326
+ * @property {boolean} [is_set]
327
+ * @property {string} [key]
328
+ * @property {string} [message]
329
+ * @property {Object} [moq]
330
+ * @property {Object} [parent_item_identifiers]
331
+ * @property {ProductPriceInfo} [price]
332
+ * @property {ProductPriceInfo} [price_per_unit]
333
+ * @property {CartProduct} [product]
334
+ * @property {PromoMeta} [promo_meta]
335
+ * @property {AppliedPromotion[]} [promotions_applied]
336
+ * @property {number} [quantity]
337
+ */
338
+
339
+ /**
340
+ * @typedef CategoryInfo
341
+ * @property {string} [name]
342
+ * @property {number} [uid] - Product Category Id
343
+ */
344
+
345
+ /**
346
+ * @typedef Charges
347
+ * @property {number} [charges]
348
+ * @property {number} [threshold]
349
+ */
350
+
351
+ /**
352
+ * @typedef CheckCart
353
+ * @property {CartBreakup} [breakup_values]
354
+ * @property {boolean} [buy_now]
355
+ * @property {number} [cart_id]
356
+ * @property {string} [checkout_mode]
357
+ * @property {boolean} [cod_available]
358
+ * @property {number} [cod_charges]
359
+ * @property {string} [cod_message]
360
+ * @property {string} [comment]
361
+ * @property {string} [coupon_text]
362
+ * @property {CartCurrency} [currency]
363
+ * @property {string} [delivery_charge_info]
364
+ * @property {number} [delivery_charge_order_value]
365
+ * @property {number} [delivery_charges]
366
+ * @property {ShipmentPromise} [delivery_promise]
367
+ * @property {string} [error_message]
368
+ * @property {string} [gstin]
369
+ * @property {string} [id]
370
+ * @property {boolean} [is_valid]
371
+ * @property {CartProductInfo[]} [items]
372
+ * @property {string} [last_modified]
373
+ * @property {string} [message]
374
+ * @property {string} [order_id]
375
+ * @property {PaymentSelectionLock} [payment_selection_lock]
376
+ * @property {boolean} [restrict_checkout]
377
+ * @property {string} [store_code]
378
+ * @property {Object[]} [store_emps]
379
+ * @property {boolean} [success]
380
+ * @property {string} [uid]
381
+ * @property {string} [user_type]
382
+ */
383
+
384
+ /**
385
+ * @typedef Collection
386
+ * @property {string} collected_by
387
+ * @property {string} refund_by
388
+ */
389
+
390
+ /**
391
+ * @typedef CompareObject
392
+ * @property {number} [equals]
393
+ * @property {number} [greater_than]
394
+ * @property {number} [greater_than_equals]
395
+ * @property {number} [less_than]
396
+ * @property {number} [less_than_equals]
397
+ */
398
+
399
+ /**
400
+ * @typedef Coupon
401
+ * @property {string} [coupon_code]
402
+ * @property {string} [coupon_type]
403
+ * @property {number} [coupon_value]
404
+ * @property {string} [description]
405
+ * @property {string} [expires_on]
406
+ * @property {boolean} [is_applicable]
407
+ * @property {boolean} [is_applied]
408
+ * @property {number} [max_discount_value]
409
+ * @property {string} [message]
410
+ * @property {number} [minimum_cart_value]
411
+ * @property {string} [sub_title]
412
+ * @property {string} [title]
413
+ */
414
+
415
+ /**
416
+ * @typedef CouponAction
417
+ * @property {string} [action_date]
418
+ * @property {string} [txn_mode]
419
+ */
420
+
421
+ /**
422
+ * @typedef CouponAdd
423
+ * @property {CouponSchedule} [_schedule]
424
+ * @property {CouponAction} [action]
425
+ * @property {CouponAuthor} [author]
426
+ * @property {string} code
427
+ * @property {CouponDateMeta} [date_meta]
428
+ * @property {DisplayMeta} display_meta
429
+ * @property {Identifier} identifiers
430
+ * @property {Ownership} ownership
431
+ * @property {Restrictions} [restrictions]
432
+ * @property {Rule[]} rule
433
+ * @property {RuleDefinition} rule_definition
434
+ * @property {State} [state]
435
+ * @property {string[]} [tags]
436
+ * @property {string} type_slug
437
+ * @property {Validation} [validation]
438
+ * @property {Validity} validity
439
+ */
440
+
441
+ /**
442
+ * @typedef CouponAuthor
443
+ * @property {string} [created_by]
444
+ * @property {string} [modified_by]
445
+ */
446
+
447
+ /**
448
+ * @typedef CouponBreakup
449
+ * @property {string} [code]
450
+ * @property {string} [coupon_type]
451
+ * @property {number} [coupon_value]
452
+ * @property {string} [description]
453
+ * @property {boolean} [is_applied]
454
+ * @property {number} [max_discount_value]
455
+ * @property {string} [message]
456
+ * @property {number} [minimum_cart_value]
457
+ * @property {string} [sub_title]
458
+ * @property {string} [title]
459
+ * @property {string} [type]
460
+ * @property {string} [uid]
461
+ * @property {number} [value]
462
+ */
463
+
464
+ /**
465
+ * @typedef CouponDateMeta
466
+ * @property {string} [created_on]
467
+ * @property {string} [modified_on]
468
+ */
469
+
470
+ /**
471
+ * @typedef CouponDetails
472
+ * @property {string} [code]
473
+ * @property {number} [discount_single_quantity]
474
+ * @property {number} [discount_total_quantity]
475
+ */
476
+
477
+ /**
478
+ * @typedef CouponPartialUpdate
479
+ * @property {boolean} [archive] - Send true to unpublish coupon
480
+ * @property {CouponSchedule} [schedule]
481
+ */
482
+
483
+ /**
484
+ * @typedef CouponSchedule
485
+ * @property {string} [cron]
486
+ * @property {number} [duration]
487
+ * @property {string} [end]
488
+ * @property {Object[]} [next_schedule]
489
+ * @property {string} [start]
490
+ */
491
+
492
+ /**
493
+ * @typedef CouponsResponse
494
+ * @property {CouponAdd} [items]
495
+ * @property {Page} [page]
496
+ */
497
+
498
+ /**
499
+ * @typedef CouponUpdate
500
+ * @property {CouponSchedule} [_schedule]
501
+ * @property {CouponAction} [action]
502
+ * @property {CouponAuthor} [author]
503
+ * @property {string} code
504
+ * @property {CouponDateMeta} [date_meta]
505
+ * @property {DisplayMeta} display_meta
506
+ * @property {Identifier} identifiers
507
+ * @property {Ownership} ownership
508
+ * @property {Restrictions} [restrictions]
509
+ * @property {Rule[]} rule
510
+ * @property {RuleDefinition} rule_definition
511
+ * @property {State} [state]
512
+ * @property {string[]} [tags]
513
+ * @property {string} type_slug
514
+ * @property {Validation} [validation]
515
+ * @property {Validity} validity
516
+ */
517
+
518
+ /**
519
+ * @typedef CouponValidity
520
+ * @property {string} [code]
521
+ * @property {number} [discount]
522
+ * @property {string} [display_message_en]
523
+ * @property {boolean} [next_validation_required]
524
+ * @property {string} [title]
525
+ * @property {boolean} [valid]
526
+ */
527
+
528
+ /**
529
+ * @typedef DeleteAddressResponse
530
+ * @property {string} [id]
531
+ * @property {boolean} [is_deleted]
532
+ */
533
+
534
+ /**
535
+ * @typedef DeleteCartDetailResponse
536
+ * @property {string} [message]
537
+ * @property {boolean} [success] - True if cart is archived successfully. False
538
+ * if not archived.
539
+ */
540
+
541
+ /**
542
+ * @typedef DeleteCartRequest
543
+ * @property {string[]} [cart_id_list]
544
+ */
545
+
546
+ /**
547
+ * @typedef DeliveryCharges
548
+ * @property {Charges[]} [charges]
549
+ * @property {boolean} [enabled]
550
+ */
551
+
552
+ /**
553
+ * @typedef DiscountOffer
554
+ * @property {boolean} [apportion_discount]
555
+ * @property {string} [code]
556
+ * @property {number} [discount_amount]
557
+ * @property {number} [discount_percentage]
558
+ * @property {number} [discount_price]
559
+ * @property {number} [max_discount_amount]
560
+ * @property {number} [max_offer_quantity]
561
+ * @property {number} [max_usage_per_transaction]
562
+ * @property {number} [min_offer_quantity]
563
+ * @property {boolean} [partial_can_ret]
564
+ */
565
+
566
+ /**
567
+ * @typedef DiscountRule
568
+ * @property {string} buy_condition
569
+ * @property {string} discount_type
570
+ * @property {ItemCriteria} item_criteria
571
+ * @property {DiscountOffer} offer
572
+ */
573
+
574
+ /**
575
+ * @typedef DiscountRulesApp
576
+ * @property {Object} [item_criteria] - Item criteria of promotion
577
+ * @property {string[]} [matched_buy_rules] - Matched buy rules for promotion
578
+ * @property {Object} [offer] - Offer for promotion
579
+ * @property {Object} [raw_offer] - Raw offer details for promotion
580
+ */
581
+
582
+ /**
583
+ * @typedef DisplayBreakup
584
+ * @property {string} [currency_code]
585
+ * @property {string} [currency_symbol]
586
+ * @property {string} [display]
587
+ * @property {string} [key]
588
+ * @property {string[]} [message]
589
+ * @property {number} [value]
590
+ */
591
+
592
+ /**
593
+ * @typedef DisplayMeta
594
+ * @property {DisplayMetaDict} [apply]
595
+ * @property {DisplayMetaDict} [auto]
596
+ * @property {string} [description]
597
+ * @property {DisplayMetaDict} [remove]
598
+ * @property {string} [subtitle]
599
+ * @property {string} [title]
600
+ */
601
+
602
+ /**
603
+ * @typedef DisplayMeta1
604
+ * @property {string} [description]
605
+ * @property {string} [name]
606
+ * @property {string} [offer_label]
607
+ * @property {string} [offer_text]
608
+ */
609
+
610
+ /**
611
+ * @typedef DisplayMetaDict
612
+ * @property {string} [subtitle]
613
+ * @property {string} [title]
614
+ */
615
+
616
+ /**
617
+ * @typedef Files
618
+ * @property {string} key
619
+ * @property {string[]} values
620
+ */
621
+
622
+ /**
623
+ * @typedef FreeGiftItem
624
+ * @property {string} [item_brand_name] - Item brand name
625
+ * @property {number} [item_id] - Item id
626
+ * @property {string[]} [item_images_url] - Item images URL
627
+ * @property {string} [item_name] - Item name
628
+ * @property {Object} [item_price_details] - Item price details
629
+ * @property {string} [item_slug] - Item slug
630
+ */
631
+
632
+ /**
633
+ * @typedef GeoLocation
634
+ * @property {number} [latitude]
635
+ * @property {number} [longitude]
636
+ */
637
+
638
+ /**
639
+ * @typedef GetCouponResponse
640
+ * @property {Coupon[]} [available_coupon_list]
641
+ * @property {PageCoupon} [page]
642
+ */
643
+
644
+ /**
645
+ * @typedef GetShareCartLinkRequest
646
+ * @property {string} [id] - Cart uid for generating sharing
647
+ * @property {Object} [meta] - Staff, Ordering store or any other data. This
648
+ * data will be used to generate link as well as sent as shared details.
649
+ */
650
+
651
+ /**
652
+ * @typedef GetShareCartLinkResponse
653
+ * @property {string} [share_url] - Short shareable final url
654
+ * @property {string} [token] - Short url unique id
655
+ */
656
+
657
+ /**
658
+ * @typedef Identifier
659
+ * @property {string[]} [article_id]
660
+ * @property {number[]} [brand_id]
661
+ * @property {number[]} [category_id]
662
+ * @property {string[]} [collection_id]
663
+ * @property {number[]} [company_id]
664
+ * @property {string[]} [email_domain]
665
+ * @property {number[]} [exclude_brand_id]
666
+ * @property {number[]} [item_id]
667
+ * @property {number[]} [store_id]
668
+ * @property {string[]} [user_id]
669
+ */
670
+
671
+ /**
672
+ * @typedef ItemCriteria
673
+ * @property {boolean} [all_items]
674
+ * @property {string[]} [available_zones]
675
+ * @property {string[]} [buy_rules]
676
+ * @property {CompareObject} [cart_quantity]
677
+ * @property {CompareObject} [cart_total]
678
+ * @property {CompareObject} [cart_unique_item_amount]
679
+ * @property {CompareObject} [cart_unique_item_quantity]
680
+ * @property {number[]} [item_brand]
681
+ * @property {number[]} [item_category]
682
+ * @property {number[]} [item_company]
683
+ * @property {number[]} [item_department]
684
+ * @property {number[]} [item_exclude_brand]
685
+ * @property {number[]} [item_exclude_category]
686
+ * @property {number[]} [item_exclude_company]
687
+ * @property {number[]} [item_exclude_department]
688
+ * @property {number[]} [item_exclude_id]
689
+ * @property {number[]} [item_exclude_l1_category]
690
+ * @property {number[]} [item_exclude_l2_category]
691
+ * @property {string[]} [item_exclude_sku]
692
+ * @property {number[]} [item_exclude_store]
693
+ * @property {number[]} [item_id]
694
+ * @property {number[]} [item_l1_category]
695
+ * @property {number[]} [item_l2_category]
696
+ * @property {string[]} [item_size]
697
+ * @property {string[]} [item_sku]
698
+ * @property {number[]} [item_store]
699
+ * @property {string[]} [item_tags]
700
+ */
701
+
702
+ /**
703
+ * @typedef LoyaltyPoints
704
+ * @property {number} [applicable]
705
+ * @property {string} [description]
706
+ * @property {boolean} [is_applied]
707
+ * @property {number} [total]
708
+ */
709
+
710
+ /**
711
+ * @typedef MultiCartResponse
712
+ * @property {CartList[]} [data]
713
+ * @property {boolean} [success]
714
+ */
715
+
716
+ /**
717
+ * @typedef MultiTenderPaymentMeta
718
+ * @property {string} [current_status]
719
+ * @property {Object} [extra_meta]
720
+ * @property {string} [order_id]
721
+ * @property {string} [payment_gateway]
722
+ * @property {string} [payment_id]
723
+ */
724
+
725
+ /**
726
+ * @typedef MultiTenderPaymentMethod
727
+ * @property {number} amount - Payment amount
728
+ * @property {MultiTenderPaymentMeta} [meta]
729
+ * @property {string} mode
730
+ * @property {string} [name] - Payment mode name
731
+ */
732
+
733
+ /**
734
+ * @typedef OpenapiCartDetailsRequest
735
+ * @property {CartItem[]} cart_items
736
+ */
737
+
738
+ /**
739
+ * @typedef OpenapiCartDetailsResponse
740
+ * @property {CartBreakup} [breakup_values]
741
+ * @property {boolean} [is_valid]
742
+ * @property {CartProductInfo[]} [items]
743
+ * @property {string} [message]
744
+ */
745
+
746
+ /**
747
+ * @typedef OpenApiCartServiceabilityRequest
748
+ * @property {CartItem[]} cart_items
749
+ * @property {ShippingAddress} shipping_address
750
+ */
751
+
752
+ /**
753
+ * @typedef OpenApiCartServiceabilityResponse
754
+ * @property {CartBreakup} [breakup_values]
755
+ * @property {ShipmentPromise} [delivery_promise]
756
+ * @property {boolean} [is_valid]
757
+ * @property {CartProductInfo[]} [items]
758
+ * @property {string} [message]
759
+ */
760
+
761
+ /**
762
+ * @typedef OpenApiCheckoutResponse
763
+ * @property {string} [message]
764
+ * @property {string} order_id - Fynd order id
765
+ * @property {string} [order_ref_id] - Order id sent in request
766
+ * @property {boolean} [success]
767
+ */
768
+
769
+ /**
770
+ * @typedef OpenApiErrorResponse
771
+ * @property {Object} [errors] - Contains field name which has error as key and
772
+ * error message as value
773
+ * @property {string} [message]
774
+ * @property {boolean} [success]
775
+ */
776
+
777
+ /**
778
+ * @typedef OpenApiFiles
779
+ * @property {string} key
780
+ * @property {string[]} values
781
+ */
782
+
783
+ /**
784
+ * @typedef OpenApiOrderItem
785
+ * @property {number} amount_paid
786
+ * @property {number} cashback_applied
787
+ * @property {number} cod_charges
788
+ * @property {number} coupon_effective_discount
789
+ * @property {number} delivery_charges
790
+ * @property {number} discount
791
+ * @property {number} [employee_discount]
792
+ * @property {Object} [extra_meta]
793
+ * @property {OpenApiFiles[]} [files]
794
+ * @property {number} [loyalty_discount]
795
+ * @property {CartItemMeta} [meta]
796
+ * @property {MultiTenderPaymentMethod[]} payment_methods
797
+ * @property {number} price_effective
798
+ * @property {number} price_marked
799
+ * @property {number} product_id
800
+ * @property {number} [quantity]
801
+ * @property {string} size
802
+ */
803
+
804
+ /**
805
+ * @typedef OpenApiPlatformCheckoutReq
806
+ * @property {string} [affiliate_order_id]
807
+ * @property {ShippingAddress} billing_address
808
+ * @property {OpenApiOrderItem[]} cart_items
809
+ * @property {number} cart_value
810
+ * @property {number} cashback_applied
811
+ * @property {number} cod_charges
812
+ * @property {string} [comment]
813
+ * @property {string} [coupon]
814
+ * @property {string} coupon_code
815
+ * @property {number} coupon_value
816
+ * @property {string} [currency_code]
817
+ * @property {number} delivery_charges
818
+ * @property {Object} [employee_discount]
819
+ * @property {OpenApiFiles[]} [files]
820
+ * @property {string} [gstin]
821
+ * @property {number} [loyalty_discount]
822
+ * @property {string} [order_id]
823
+ * @property {MultiTenderPaymentMethod[]} payment_methods
824
+ * @property {string} [payment_mode]
825
+ * @property {ShippingAddress} [shipping_address]
826
+ */
827
+
828
+ /**
829
+ * @typedef OperationErrorResponse
830
+ * @property {string} [message]
831
+ * @property {boolean} [success]
832
+ */
833
+
834
+ /**
835
+ * @typedef OverrideCartItem
836
+ * @property {number} amount_paid
837
+ * @property {number} discount
838
+ * @property {Object} [extra_meta]
839
+ * @property {number} item_id
840
+ * @property {number} price_effective
841
+ * @property {number} price_marked
842
+ * @property {OverrideCartItemPromo[]} [promo_list]
843
+ * @property {number} [quantity]
844
+ * @property {string} [seller_identifier]
845
+ * @property {string} size
846
+ */
847
+
848
+ /**
849
+ * @typedef OverrideCartItemPromo
850
+ * @property {Object[]} [item_list]
851
+ * @property {string} promo_amount
852
+ * @property {string} [promo_desc]
853
+ * @property {string} promo_id
854
+ * @property {string} [rwrd_tndr]
855
+ */
856
+
857
+ /**
858
+ * @typedef OverrideCheckoutReq
859
+ * @property {string} aggregator
860
+ * @property {Object} [billing_address]
861
+ * @property {string} cart_id
862
+ * @property {OverrideCartItem[]} cart_items
863
+ * @property {string} currency_code
864
+ * @property {string} merchant_code
865
+ * @property {string} order_type
866
+ * @property {number} [ordering_store]
867
+ * @property {string} payment_identifier
868
+ * @property {string} payment_mode
869
+ * @property {Object} [shipping_address]
870
+ */
871
+
872
+ /**
873
+ * @typedef OverrideCheckoutResponse
874
+ * @property {Object} cart
875
+ * @property {Object} data
876
+ * @property {string} message
877
+ * @property {string} order_id
878
+ * @property {string} success
879
+ */
880
+
881
+ /**
882
+ * @typedef Ownership
883
+ * @property {string} payable_by
884
+ * @property {string} payable_category
885
+ */
886
+
887
+ /**
888
+ * @typedef Ownership1
889
+ * @property {string} payable_by
890
+ * @property {string} payable_category
891
+ */
892
+
893
+ /**
894
+ * @typedef Ownership2
895
+ * @property {string} [payable_by] - Promo amount bearable party
896
+ * @property {string} [payable_category] - Promo amount payable category
897
+ */
898
+
899
+ /**
900
+ * @typedef Page
901
+ * @property {number} [current]
902
+ * @property {boolean} [has_next]
903
+ * @property {boolean} [has_previous]
904
+ * @property {number} [item_total]
905
+ * @property {string} [next_id]
906
+ * @property {number} [size]
907
+ * @property {string} type
908
+ */
909
+
910
+ /**
911
+ * @typedef PageCoupon
912
+ * @property {number} [current]
913
+ * @property {boolean} [has_next]
914
+ * @property {boolean} [has_previous]
915
+ * @property {number} [total]
916
+ * @property {number} [total_item_count]
917
+ */
918
+
919
+ /**
920
+ * @typedef PaymentAllowValue
921
+ * @property {number} [max]
922
+ */
923
+
924
+ /**
925
+ * @typedef PaymentAllowValue1
926
+ * @property {number} [max]
927
+ */
928
+
929
+ /**
930
+ * @typedef PaymentCouponValidate
931
+ * @property {CouponValidity} [coupon_validity]
932
+ * @property {string} [message]
933
+ * @property {boolean} success
934
+ */
935
+
936
+ /**
937
+ * @typedef PaymentMeta
938
+ * @property {string} [merchant_code]
939
+ * @property {string} [payment_gateway]
940
+ * @property {string} [payment_identifier]
941
+ * @property {string} [type]
942
+ */
943
+
944
+ /**
945
+ * @typedef PaymentMethod
946
+ * @property {number} [amount]
947
+ * @property {string} mode
948
+ * @property {string} [name]
949
+ * @property {string} [payment]
950
+ * @property {PaymentMeta} payment_meta
951
+ */
952
+
953
+ /**
954
+ * @typedef PaymentModes
955
+ * @property {string[]} [codes]
956
+ * @property {string[]} [iins]
957
+ * @property {string[]} [networks]
958
+ * @property {string[]} [types]
959
+ * @property {PaymentAllowValue} [uses]
960
+ */
961
+
962
+ /**
963
+ * @typedef PaymentSelectionLock
964
+ * @property {string} [default_options]
965
+ * @property {boolean} [enabled]
966
+ * @property {string} [payment_identifier]
967
+ */
968
+
969
+ /**
970
+ * @typedef PickupStoreDetail
971
+ * @property {string} [address]
972
+ * @property {string} [address_type]
973
+ * @property {string} [area]
974
+ * @property {string} [area_code]
975
+ * @property {string} [area_code_slug]
976
+ * @property {string} [city]
977
+ * @property {string} [country]
978
+ * @property {string} [email]
979
+ * @property {number} [id]
980
+ * @property {string} [landmark]
981
+ * @property {string} [name]
982
+ * @property {string} [phone]
983
+ * @property {number} [pincode]
984
+ * @property {string} [state]
985
+ * @property {string} [store_code]
986
+ * @property {number} [uid]
987
+ */
988
+
989
+ /**
990
+ * @typedef PlatformAddCartRequest
991
+ * @property {AddProductCart[]} [items]
992
+ * @property {boolean} [new_cart]
993
+ * @property {string} [user_id]
994
+ */
995
+
996
+ /**
997
+ * @typedef PlatformAddress
998
+ * @property {string} [address]
999
+ * @property {string} [address_type]
1000
+ * @property {string} [area]
1001
+ * @property {string} [area_code]
1002
+ * @property {string} [area_code_slug]
1003
+ * @property {string} [cart_id]
1004
+ * @property {string} [checkout_mode]
1005
+ * @property {string} [city]
1006
+ * @property {string} [country]
1007
+ * @property {string} [country_code]
1008
+ * @property {string} [created_by_user_id]
1009
+ * @property {string} [email]
1010
+ * @property {GeoLocation} [geo_location]
1011
+ * @property {Object} [google_map_point]
1012
+ * @property {string} [id]
1013
+ * @property {boolean} [is_active]
1014
+ * @property {boolean} [is_default_address]
1015
+ * @property {string} [landmark]
1016
+ * @property {Object} [meta]
1017
+ * @property {string} [name]
1018
+ * @property {string} [phone]
1019
+ * @property {string} [state]
1020
+ * @property {string[]} [tags]
1021
+ * @property {string} [user_id]
1022
+ */
1023
+
1024
+ /**
1025
+ * @typedef PlatformCartCheckoutDetailRequest
1026
+ * @property {string} [address_id]
1027
+ * @property {string} [aggregator]
1028
+ * @property {Object} [billing_address]
1029
+ * @property {string} [billing_address_id]
1030
+ * @property {string} [callback_url]
1031
+ * @property {string} [checkout_mode]
1032
+ * @property {Object} [delivery_address]
1033
+ * @property {string} [device_id]
1034
+ * @property {string} [employee_code]
1035
+ * @property {Object} [extra_meta]
1036
+ * @property {Files[]} [files] - List of file url
1037
+ * @property {string} id
1038
+ * @property {string} [merchant_code]
1039
+ * @property {Object} [meta]
1040
+ * @property {string} order_type
1041
+ * @property {number} [ordering_store]
1042
+ * @property {boolean} [payment_auto_confirm]
1043
+ * @property {string} [payment_identifier]
1044
+ * @property {string} payment_mode
1045
+ * @property {Object} [payment_params]
1046
+ * @property {number} [pick_at_store_uid]
1047
+ * @property {boolean} [pos]
1048
+ * @property {StaffCheckout} [staff]
1049
+ * @property {string} user_id
1050
+ */
1051
+
1052
+ /**
1053
+ * @typedef PlatformCartCheckoutDetailV2Request
1054
+ * @property {string} [address_id]
1055
+ * @property {string} [aggregator]
1056
+ * @property {Object} [billing_address]
1057
+ * @property {string} [billing_address_id]
1058
+ * @property {string} [callback_url]
1059
+ * @property {string} [checkout_mode]
1060
+ * @property {Object} [custom_meta]
1061
+ * @property {Object} [delivery_address]
1062
+ * @property {string} [device_id]
1063
+ * @property {string} [employee_code]
1064
+ * @property {Object} [extra_meta]
1065
+ * @property {Files[]} [files] - List of file url
1066
+ * @property {string} id
1067
+ * @property {string} [merchant_code]
1068
+ * @property {Object} [meta]
1069
+ * @property {string} order_type
1070
+ * @property {number} [ordering_store]
1071
+ * @property {boolean} [payment_auto_confirm]
1072
+ * @property {string} [payment_identifier]
1073
+ * @property {PaymentMethod[]} payment_methods
1074
+ * @property {string} [payment_mode]
1075
+ * @property {Object} [payment_params]
1076
+ * @property {number} [pick_at_store_uid]
1077
+ * @property {boolean} [pos]
1078
+ * @property {StaffCheckout} [staff]
1079
+ * @property {string} user_id
1080
+ */
1081
+
1082
+ /**
1083
+ * @typedef PlatformCartMetaRequest
1084
+ * @property {string} [checkout_mode]
1085
+ * @property {string} [comment]
1086
+ * @property {Object} [gift_details]
1087
+ * @property {string} [gstin]
1088
+ * @property {string} [pan_no]
1089
+ * @property {Object} [pick_up_customer_details] - Customer contact details for
1090
+ * customer pickup at store
1091
+ * @property {string} [staff_user_id] - Staff user id
1092
+ */
1093
+
1094
+ /**
1095
+ * @typedef PlatformCartShipmentsResponse
1096
+ * @property {AppliedPromotion[]} [applied_promo_details]
1097
+ * @property {CartBreakup} [breakup_values]
1098
+ * @property {boolean} [buy_now]
1099
+ * @property {string} [checkout_mode]
1100
+ * @property {string} [comment]
1101
+ * @property {string} [coupon_text]
1102
+ * @property {CartCurrency} [currency]
1103
+ * @property {string} [delivery_charge_info]
1104
+ * @property {ShipmentPromise} [delivery_promise]
1105
+ * @property {boolean} [error]
1106
+ * @property {string} [gstin]
1107
+ * @property {string} [id]
1108
+ * @property {boolean} [is_valid]
1109
+ * @property {CartProductInfo[]} [items]
1110
+ * @property {string} [last_modified]
1111
+ * @property {string} [message]
1112
+ * @property {Object} [pan_config]
1113
+ * @property {string} [pan_no]
1114
+ * @property {PaymentSelectionLock} [payment_selection_lock]
1115
+ * @property {boolean} [restrict_checkout]
1116
+ * @property {PlatformShipmentResponse[]} [shipments]
1117
+ * @property {string} [staff_user_id]
1118
+ */
1119
+
1120
+ /**
1121
+ * @typedef PlatformGetAddressesResponse
1122
+ * @property {PlatformAddress[]} [address]
1123
+ */
1124
+
1125
+ /**
1126
+ * @typedef PlatformSelectCartAddressRequest
1127
+ * @property {string} [billing_address_id]
1128
+ * @property {string} [cart_id]
1129
+ * @property {string} [checkout_mode]
1130
+ * @property {string} [id]
1131
+ * @property {string} [user_id]
1132
+ */
1133
+
1134
+ /**
1135
+ * @typedef PlatformShipmentResponse
1136
+ * @property {ShipmentArticle[]} [articles]
1137
+ * @property {string} [box_type]
1138
+ * @property {string} [dp_id]
1139
+ * @property {Object} [dp_options]
1140
+ * @property {number} [fulfillment_id]
1141
+ * @property {string} [fulfillment_type]
1142
+ * @property {CartProductInfo[]} [items]
1143
+ * @property {string} [order_type]
1144
+ * @property {ShipmentPromise} [promise]
1145
+ * @property {string} [shipment_type]
1146
+ * @property {number} [shipments]
1147
+ */
1148
+
1149
+ /**
1150
+ * @typedef PlatformUpdateCartRequest
1151
+ * @property {UpdateProductCart[]} [items]
1152
+ * @property {string} operation
1153
+ * @property {string} [user_id]
1154
+ */
1155
+
1156
+ /**
1157
+ * @typedef PostOrder
1158
+ * @property {boolean} [cancellation_allowed]
1159
+ * @property {boolean} [return_allowed]
1160
+ */
1161
+
1162
+ /**
1163
+ * @typedef PostOrder1
1164
+ * @property {boolean} [cancellation_allowed]
1165
+ * @property {boolean} [return_allowed]
1166
+ */
1167
+
1168
+ /**
1169
+ * @typedef PriceAdjustment
1170
+ * @property {boolean} [allowed_refund]
1171
+ * @property {string} [apply_expiry]
1172
+ * @property {Article[]} article_ids
1173
+ * @property {boolean} article_level_distribution
1174
+ * @property {string} cart_id
1175
+ * @property {number} [cart_value]
1176
+ * @property {Collection} collection
1177
+ * @property {string} [id]
1178
+ * @property {boolean} is_authenticated
1179
+ * @property {string} message
1180
+ * @property {Object} [meta]
1181
+ * @property {string} type
1182
+ * @property {number} value
1183
+ */
1184
+
1185
+ /**
1186
+ * @typedef PriceAdjustmentAdd
1187
+ * @property {boolean} [allowed_refund]
1188
+ * @property {string} [apply_expiry]
1189
+ * @property {Article[]} article_ids
1190
+ * @property {boolean} article_level_distribution
1191
+ * @property {string} cart_id
1192
+ * @property {number} [cart_value]
1193
+ * @property {Collection} collection
1194
+ * @property {string} [created_by]
1195
+ * @property {boolean} is_authenticated
1196
+ * @property {string} message
1197
+ * @property {Object} [meta]
1198
+ * @property {string} type
1199
+ * @property {number} value
1200
+ */
1201
+
1202
+ /**
1203
+ * @typedef PriceAdjustmentResponse
1204
+ * @property {PriceAdjustment} [data]
1205
+ */
1206
+
1207
+ /**
1208
+ * @typedef PriceAdjustmentUpdate
1209
+ * @property {boolean} [allowed_refund]
1210
+ * @property {string} [apply_expiry]
1211
+ * @property {Article[]} article_ids
1212
+ * @property {boolean} article_level_distribution
1213
+ * @property {string} cart_id
1214
+ * @property {number} [cart_value]
1215
+ * @property {Collection} collection
1216
+ * @property {boolean} is_authenticated
1217
+ * @property {string} message
1218
+ * @property {Object} [meta]
1219
+ * @property {string} [modified_by]
1220
+ * @property {string} type
1221
+ * @property {number} value
1222
+ */
1223
+
1224
+ /**
1225
+ * @typedef PriceRange
1226
+ * @property {number} [max]
1227
+ * @property {number} [min]
1228
+ */
1229
+
1230
+ /**
1231
+ * @typedef ProductAction
1232
+ * @property {ActionQuery} [query]
1233
+ * @property {string} [type]
1234
+ * @property {string} [url]
1235
+ */
1236
+
1237
+ /**
1238
+ * @typedef ProductArticle
1239
+ * @property {Object} [_custom_json]
1240
+ * @property {Object} [cart_item_meta]
1241
+ * @property {Object} [extra_meta]
1242
+ * @property {Object} [gift_card]
1243
+ * @property {Object} [identifier]
1244
+ * @property {boolean} [is_gift_visible]
1245
+ * @property {Object} [meta]
1246
+ * @property {number} [mto_quantity]
1247
+ * @property {Object} [parent_item_identifiers]
1248
+ * @property {ArticlePriceInfo} [price]
1249
+ * @property {string[]} [product_group_tags]
1250
+ * @property {number} [quantity]
1251
+ * @property {BaseInfo} [seller]
1252
+ * @property {string} [seller_identifier]
1253
+ * @property {string} [size]
1254
+ * @property {StoreInfo} [store]
1255
+ * @property {string} [type]
1256
+ * @property {string} [uid]
1257
+ */
1258
+
1259
+ /**
1260
+ * @typedef ProductAvailability
1261
+ * @property {ProductAvailabilitySize[]} [available_sizes]
1262
+ * @property {boolean} [deliverable]
1263
+ * @property {boolean} [is_valid]
1264
+ * @property {number} [other_store_quantity]
1265
+ * @property {boolean} [out_of_stock]
1266
+ * @property {string[]} [sizes]
1267
+ */
1268
+
1269
+ /**
1270
+ * @typedef ProductAvailabilitySize
1271
+ * @property {string} [display]
1272
+ * @property {boolean} [is_available]
1273
+ * @property {string} [value]
1274
+ */
1275
+
1276
+ /**
1277
+ * @typedef ProductImage
1278
+ * @property {string} [aspect_ratio]
1279
+ * @property {string} [secure_url]
1280
+ * @property {string} [url]
1281
+ */
1282
+
1283
+ /**
1284
+ * @typedef ProductPrice
1285
+ * @property {number} [add_on]
1286
+ * @property {string} [currency_code]
1287
+ * @property {string} [currency_symbol]
1288
+ * @property {number} [effective]
1289
+ * @property {number} [marked]
1290
+ * @property {number} [selling]
1291
+ */
1292
+
1293
+ /**
1294
+ * @typedef ProductPriceInfo
1295
+ * @property {ProductPrice} [base]
1296
+ * @property {ProductPrice} [converted]
1297
+ */
1298
+
1299
+ /**
1300
+ * @typedef PromiseFormatted
1301
+ * @property {string} [max]
1302
+ * @property {string} [min]
1303
+ */
1304
+
1305
+ /**
1306
+ * @typedef PromiseTimestamp
1307
+ * @property {number} [max]
1308
+ * @property {number} [min]
1309
+ */
1310
+
1311
+ /**
1312
+ * @typedef PromoMeta
1313
+ * @property {string} [message]
1314
+ */
1315
+
1316
+ /**
1317
+ * @typedef PromotionAction
1318
+ * @property {string} action_date
1319
+ * @property {string} action_type
1320
+ */
1321
+
1322
+ /**
1323
+ * @typedef PromotionAdd
1324
+ * @property {Object} [_custom_json]
1325
+ * @property {PromotionSchedule} [_schedule]
1326
+ * @property {string} application_id
1327
+ * @property {boolean} [apply_all_discount]
1328
+ * @property {string} [apply_exclusive]
1329
+ * @property {number} [apply_priority]
1330
+ * @property {PromotionAuthor} [author]
1331
+ * @property {Object} buy_rules
1332
+ * @property {string} [calculate_on] - Only available for Contract pricing and
1333
+ * Ladder pricing promotion type
1334
+ * @property {string} [code]
1335
+ * @property {string} [currency]
1336
+ * @property {PromotionDateMeta} [date_meta]
1337
+ * @property {DiscountRule[]} discount_rules
1338
+ * @property {DisplayMeta1} display_meta
1339
+ * @property {string} mode
1340
+ * @property {Ownership1} ownership
1341
+ * @property {PromotionAction} [post_order_action]
1342
+ * @property {string} promo_group
1343
+ * @property {string} promotion_type
1344
+ * @property {Restrictions1} [restrictions]
1345
+ * @property {boolean} [stackable]
1346
+ * @property {Visibility} [visiblility]
1347
+ */
1348
+
1349
+ /**
1350
+ * @typedef PromotionAuthor
1351
+ * @property {string} [created_by]
1352
+ * @property {string} [modified_by]
1353
+ */
1354
+
1355
+ /**
1356
+ * @typedef PromotionDateMeta
1357
+ * @property {string} [created_on]
1358
+ * @property {string} [modified_on]
1359
+ */
1360
+
1361
+ /**
1362
+ * @typedef PromotionListItem
1363
+ * @property {Object} [_custom_json]
1364
+ * @property {PromotionSchedule} [_schedule]
1365
+ * @property {string} application_id
1366
+ * @property {boolean} [apply_all_discount]
1367
+ * @property {string} [apply_exclusive]
1368
+ * @property {number} [apply_priority]
1369
+ * @property {PromotionAuthor} [author]
1370
+ * @property {Object} buy_rules
1371
+ * @property {string} [calculate_on] - Only available for Contract pricing and
1372
+ * Ladder pricing promotion type
1373
+ * @property {string} [code]
1374
+ * @property {string} [currency]
1375
+ * @property {PromotionDateMeta} [date_meta]
1376
+ * @property {DiscountRule[]} discount_rules
1377
+ * @property {DisplayMeta1} display_meta
1378
+ * @property {string} mode
1379
+ * @property {Ownership1} ownership
1380
+ * @property {PromotionAction} [post_order_action]
1381
+ * @property {string} promo_group
1382
+ * @property {string} promotion_type
1383
+ * @property {Restrictions1} [restrictions]
1384
+ * @property {boolean} [stackable]
1385
+ * @property {Visibility} [visiblility]
1386
+ */
1387
+
1388
+ /**
1389
+ * @typedef PromotionPartialUpdate
1390
+ * @property {boolean} [archive] - Send true to unpublish promotion
1391
+ * @property {PromotionSchedule} [schedule]
1392
+ */
1393
+
1394
+ /**
1395
+ * @typedef PromotionPaymentModes
1396
+ * @property {string[]} [codes]
1397
+ * @property {string} type
1398
+ * @property {PaymentAllowValue1} [uses]
1399
+ */
1400
+
1401
+ /**
1402
+ * @typedef PromotionSchedule
1403
+ * @property {string} [cron]
1404
+ * @property {number} [duration]
1405
+ * @property {string} end
1406
+ * @property {Object[]} [next_schedule]
1407
+ * @property {boolean} published
1408
+ * @property {string} start
1409
+ */
1410
+
1411
+ /**
1412
+ * @typedef PromotionsResponse
1413
+ * @property {PromotionListItem[]} [items]
1414
+ * @property {Page} [page]
1415
+ */
1416
+
1417
+ /**
1418
+ * @typedef PromotionUpdate
1419
+ * @property {Object} [_custom_json]
1420
+ * @property {PromotionSchedule} [_schedule]
1421
+ * @property {string} application_id
1422
+ * @property {boolean} [apply_all_discount]
1423
+ * @property {string} [apply_exclusive]
1424
+ * @property {number} [apply_priority]
1425
+ * @property {PromotionAuthor} [author]
1426
+ * @property {Object} buy_rules
1427
+ * @property {string} [calculate_on] - Only available for Contract pricing and
1428
+ * Ladder pricing promotion type
1429
+ * @property {string} [code]
1430
+ * @property {string} [currency]
1431
+ * @property {PromotionDateMeta} [date_meta]
1432
+ * @property {DiscountRule[]} discount_rules
1433
+ * @property {DisplayMeta1} display_meta
1434
+ * @property {string} mode
1435
+ * @property {Ownership1} ownership
1436
+ * @property {PromotionAction} [post_order_action]
1437
+ * @property {string} promo_group
1438
+ * @property {string} promotion_type
1439
+ * @property {Restrictions1} [restrictions]
1440
+ * @property {boolean} [stackable]
1441
+ * @property {Visibility} [visiblility]
1442
+ */
1443
+
1444
+ /**
1445
+ * @typedef RawBreakup
1446
+ * @property {number} [cod_charge]
1447
+ * @property {number} [convenience_fee]
1448
+ * @property {number} [coupon]
1449
+ * @property {number} [delivery_charge]
1450
+ * @property {number} [discount]
1451
+ * @property {number} [fynd_cash]
1452
+ * @property {number} [gift_card]
1453
+ * @property {number} [gst_charges]
1454
+ * @property {number} [mrp_total]
1455
+ * @property {number} [subtotal]
1456
+ * @property {number} [total]
1457
+ * @property {number} [vog]
1458
+ * @property {number} [you_saved]
1459
+ */
1460
+
1461
+ /**
1462
+ * @typedef Restrictions
1463
+ * @property {BulkBundleRestriction} [bulk_bundle]
1464
+ * @property {boolean} [coupon_allowed]
1465
+ * @property {number[]} [ordering_stores]
1466
+ * @property {Object} [payments]
1467
+ * @property {string[]} [platforms]
1468
+ * @property {PostOrder} [post_order]
1469
+ * @property {PriceRange} [price_range]
1470
+ * @property {number[]} [user_groups]
1471
+ * @property {string} [user_type]
1472
+ * @property {UsesRestriction} [uses]
1473
+ */
1474
+
1475
+ /**
1476
+ * @typedef Restrictions1
1477
+ * @property {boolean} [anonymous_users]
1478
+ * @property {number} [order_quantity]
1479
+ * @property {number[]} [ordering_stores]
1480
+ * @property {PromotionPaymentModes[]} [payments]
1481
+ * @property {string[]} [platforms]
1482
+ * @property {PostOrder1} [post_order]
1483
+ * @property {number[]} [user_groups]
1484
+ * @property {string[]} [user_id]
1485
+ * @property {UserRegistered} [user_registered]
1486
+ * @property {UsesRestriction1} uses
1487
+ */
1488
+
1489
+ /**
1490
+ * @typedef Rule
1491
+ * @property {number} [discount_qty]
1492
+ * @property {number} [key]
1493
+ * @property {number} [max]
1494
+ * @property {number} [min]
1495
+ * @property {number} [value]
1496
+ */
1497
+
1498
+ /**
1499
+ * @typedef RuleDefinition
1500
+ * @property {string} applicable_on
1501
+ * @property {boolean} [auto_apply]
1502
+ * @property {string} calculate_on
1503
+ * @property {string} [currency_code]
1504
+ * @property {boolean} [is_exact]
1505
+ * @property {string[]} [scope]
1506
+ * @property {string} type
1507
+ * @property {string} value_type
1508
+ */
1509
+
1510
+ /**
1511
+ * @typedef SaveAddressResponse
1512
+ * @property {string} [id]
1513
+ * @property {boolean} [is_default_address]
1514
+ * @property {boolean} [success]
1515
+ */
1516
+
1517
+ /**
1518
+ * @typedef SharedCart
1519
+ * @property {CartBreakup} [breakup_values]
1520
+ * @property {boolean} [buy_now]
1521
+ * @property {number} [cart_id]
1522
+ * @property {string} [checkout_mode]
1523
+ * @property {string} [comment]
1524
+ * @property {string} [coupon_text]
1525
+ * @property {CartCurrency} [currency]
1526
+ * @property {string} [delivery_charge_info]
1527
+ * @property {ShipmentPromise} [delivery_promise]
1528
+ * @property {string} [gstin]
1529
+ * @property {string} [id]
1530
+ * @property {boolean} [is_valid]
1531
+ * @property {CartProductInfo[]} [items]
1532
+ * @property {string} [last_modified]
1533
+ * @property {string} [message]
1534
+ * @property {PaymentSelectionLock} [payment_selection_lock]
1535
+ * @property {boolean} [restrict_checkout]
1536
+ * @property {SharedCartDetails} [shared_cart_details]
1537
+ * @property {string} [uid]
1538
+ */
1539
+
1540
+ /**
1541
+ * @typedef SharedCartDetails
1542
+ * @property {string} [created_on]
1543
+ * @property {Object} [meta] - Meta data sent while generating share cart link
1544
+ * @property {Object} [source] - Share link device and other source information
1545
+ * @property {string} [token] - Short link id
1546
+ * @property {Object} [user] - User details of who generated share link
1547
+ */
1548
+
1549
+ /**
1550
+ * @typedef SharedCartResponse
1551
+ * @property {SharedCart} [cart]
1552
+ * @property {string} [error]
1553
+ */
1554
+
1555
+ /**
1556
+ * @typedef ShipmentArticle
1557
+ * @property {string} [article_id]
1558
+ * @property {string} [meta]
1559
+ * @property {string} [quantity]
1560
+ */
1561
+
1562
+ /**
1563
+ * @typedef ShipmentPromise
1564
+ * @property {PromiseFormatted} [formatted]
1565
+ * @property {PromiseTimestamp} [timestamp]
1566
+ */
1567
+
1568
+ /**
1569
+ * @typedef ShippingAddress
1570
+ * @property {string} [address]
1571
+ * @property {string} [address_type]
1572
+ * @property {string} [area]
1573
+ * @property {string} area_code
1574
+ * @property {string} [area_code_slug]
1575
+ * @property {string} [city]
1576
+ * @property {string} [country]
1577
+ * @property {string} [country_code]
1578
+ * @property {string} [country_iso_code]
1579
+ * @property {string} [country_phone_code]
1580
+ * @property {string} [email]
1581
+ * @property {string} [landmark]
1582
+ * @property {Object} [meta]
1583
+ * @property {string} [name]
1584
+ * @property {number} [phone]
1585
+ * @property {number} [pincode]
1586
+ * @property {string} [state]
1587
+ */
1588
+
1589
+ /**
1590
+ * @typedef StaffCheckout
1591
+ * @property {string} _id
1592
+ * @property {string} [employee_code]
1593
+ * @property {string} first_name
1594
+ * @property {string} last_name
1595
+ * @property {string} user
1596
+ */
1597
+
1598
+ /**
1599
+ * @typedef State
1600
+ * @property {boolean} [is_archived]
1601
+ * @property {boolean} [is_display]
1602
+ * @property {boolean} [is_public]
1603
+ */
1604
+
1605
+ /**
1606
+ * @typedef StoreDetailsResponse
1607
+ * @property {PickupStoreDetail[]} [items]
1608
+ */
1609
+
1610
+ /**
1611
+ * @typedef StoreInfo
1612
+ * @property {string} [name]
1613
+ * @property {string} [store_code]
1614
+ * @property {number} [uid]
1615
+ */
1616
+
1617
+ /**
1618
+ * @typedef SuccessMessage
1619
+ * @property {string} [message]
1620
+ * @property {boolean} [success]
1621
+ */
1622
+
1623
+ /**
1624
+ * @typedef Tags
1625
+ * @property {Object} [tags]
1626
+ */
1627
+
1628
+ /**
1629
+ * @typedef UpdateAddressResponse
1630
+ * @property {string} [id]
1631
+ * @property {boolean} [is_default_address]
1632
+ * @property {boolean} [is_updated]
1633
+ * @property {boolean} [success]
1634
+ */
1635
+
1636
+ /**
1637
+ * @typedef UpdateCartDetailResponse
1638
+ * @property {CartDetailResponse} [cart]
1639
+ * @property {string} [message]
1640
+ * @property {boolean} [success] - True if all items are added successfully.
1641
+ * False if partially added or not added.
1642
+ */
1643
+
1644
+ /**
1645
+ * @typedef UpdateCartPaymentRequest
1646
+ * @property {string} [address_id]
1647
+ * @property {string} [aggregator_name]
1648
+ * @property {string} [id]
1649
+ * @property {string} [merchant_code]
1650
+ * @property {string} [payment_identifier]
1651
+ * @property {string} [payment_mode]
1652
+ */
1653
+
1654
+ /**
1655
+ * @typedef UpdateCartPaymentRequestV2
1656
+ * @property {string} [address_id]
1657
+ * @property {string} [aggregator_name]
1658
+ * @property {string} [id]
1659
+ * @property {string} [merchant_code]
1660
+ * @property {string} [payment_identifier]
1661
+ * @property {PaymentMethod[]} [payment_methods]
1662
+ * @property {string} [payment_mode]
1663
+ */
1664
+
1665
+ /**
1666
+ * @typedef UpdateCartRequest
1667
+ * @property {UpdateProductCart[]} [items]
1668
+ * @property {string} operation
1669
+ */
1670
+
1671
+ /**
1672
+ * @typedef UpdateCartShipmentItem
1673
+ * @property {string} article_uid - Article mongo id
1674
+ * @property {number} [quantity] - Quantity of product in shipment
1675
+ * @property {string} shipment_type - Shipment delivery type
1676
+ */
1677
+
1678
+ /**
1679
+ * @typedef UpdateCartShipmentRequest
1680
+ * @property {UpdateCartShipmentItem[]} shipments
1681
+ */
1682
+
1683
+ /**
1684
+ * @typedef UpdateProductCart
1685
+ * @property {Object} [_custom_json]
1686
+ * @property {string} [article_id]
1687
+ * @property {Object} [extra_meta]
1688
+ * @property {CartProductIdentifer} identifiers
1689
+ * @property {number} [item_id]
1690
+ * @property {number} [item_index]
1691
+ * @property {string} [item_size]
1692
+ * @property {Object} [meta]
1693
+ * @property {Object} [parent_item_identifiers]
1694
+ * @property {number} [quantity]
1695
+ */
1696
+
1697
+ /**
1698
+ * @typedef UpdateUserCartMapping
1699
+ * @property {string} user_id
1700
+ */
1701
+
1702
+ /**
1703
+ * @typedef UserCartMappingResponse
1704
+ * @property {AppliedPromotion[]} [applied_promo_details]
1705
+ * @property {CartBreakup} [breakup_values]
1706
+ * @property {boolean} [buy_now]
1707
+ * @property {string} [checkout_mode]
1708
+ * @property {string} [comment]
1709
+ * @property {string} [coupon_text]
1710
+ * @property {CartCurrency} [currency]
1711
+ * @property {string} [delivery_charge_info]
1712
+ * @property {ShipmentPromise} [delivery_promise]
1713
+ * @property {string} [gstin]
1714
+ * @property {string} [id]
1715
+ * @property {boolean} [is_valid]
1716
+ * @property {CartProductInfo[]} [items]
1717
+ * @property {string} [last_modified]
1718
+ * @property {string} [message]
1719
+ * @property {Object} [pan_config]
1720
+ * @property {string} [pan_no]
1721
+ * @property {PaymentSelectionLock} [payment_selection_lock]
1722
+ * @property {boolean} [restrict_checkout]
1723
+ * @property {UserInfo} [user]
1724
+ */
1725
+
1726
+ /**
1727
+ * @typedef UserInfo
1728
+ * @property {string} [_id]
1729
+ * @property {string} [created_at]
1730
+ * @property {string} [external_id]
1731
+ * @property {string} [first_name]
1732
+ * @property {string} [gender]
1733
+ * @property {string} [last_name]
1734
+ * @property {string} [mobile]
1735
+ * @property {string} [modified_on]
1736
+ * @property {string} [uid]
1737
+ */
1738
+
1739
+ /**
1740
+ * @typedef UserRegistered
1741
+ * @property {string} [end]
1742
+ * @property {string} [start]
1743
+ */
1744
+
1745
+ /**
1746
+ * @typedef UsesRemaining
1747
+ * @property {number} [app]
1748
+ * @property {number} [total]
1749
+ * @property {number} [user]
1750
+ */
1751
+
1752
+ /**
1753
+ * @typedef UsesRemaining1
1754
+ * @property {number} [total]
1755
+ * @property {number} [user]
1756
+ */
1757
+
1758
+ /**
1759
+ * @typedef UsesRestriction
1760
+ * @property {UsesRemaining} [maximum]
1761
+ * @property {UsesRemaining} [remaining]
1762
+ */
1763
+
1764
+ /**
1765
+ * @typedef UsesRestriction1
1766
+ * @property {UsesRemaining1} [maximum]
1767
+ * @property {UsesRemaining1} [remaining]
1768
+ */
1769
+
1770
+ /**
1771
+ * @typedef Validation
1772
+ * @property {boolean} [anonymous]
1773
+ * @property {string[]} [app_id]
1774
+ * @property {string} [user_registered_after]
1775
+ */
1776
+
1777
+ /**
1778
+ * @typedef Validity
1779
+ * @property {number} [priority]
1780
+ */
1781
+
1782
+ /**
1783
+ * @typedef Visibility
1784
+ * @property {boolean} coupon_list
1785
+ * @property {boolean} pdp
1786
+ */
1787
+
1788
+ class CartPlatformModel {
1789
+ /** @returns {AbandonedCart} */
4
1790
  static AbandonedCart() {
5
1791
  return Joi.object({
6
1792
  _id: Joi.string().allow("").required(),
@@ -38,20 +1824,26 @@ class CartModel {
38
1824
  user_id: Joi.string().allow("").required(),
39
1825
  });
40
1826
  }
1827
+
1828
+ /** @returns {AbandonedCartResponse} */
41
1829
  static AbandonedCartResponse() {
42
1830
  return Joi.object({
43
- items: Joi.array().items(CartModel.AbandonedCart()),
1831
+ items: Joi.array().items(CartPlatformModel.AbandonedCart()),
44
1832
  message: Joi.string().allow(""),
45
- page: CartModel.Page(),
1833
+ page: CartPlatformModel.Page(),
46
1834
  result: Joi.any(),
47
1835
  success: Joi.boolean(),
48
1836
  });
49
1837
  }
1838
+
1839
+ /** @returns {ActionQuery} */
50
1840
  static ActionQuery() {
51
1841
  return Joi.object({
52
1842
  product_slug: Joi.array().items(Joi.string().allow("")),
53
1843
  });
54
1844
  }
1845
+
1846
+ /** @returns {ActivePromosResponse} */
55
1847
  static ActivePromosResponse() {
56
1848
  return Joi.object({
57
1849
  created_on: Joi.string().allow(""),
@@ -66,20 +1858,26 @@ class CartModel {
66
1858
  type: Joi.string().allow(""),
67
1859
  });
68
1860
  }
1861
+
1862
+ /** @returns {AddCartDetailResponse} */
69
1863
  static AddCartDetailResponse() {
70
1864
  return Joi.object({
71
- cart: CartModel.CartDetailResponse(),
1865
+ cart: CartPlatformModel.CartDetailResponse(),
72
1866
  message: Joi.string().allow(""),
73
1867
  partial: Joi.boolean(),
74
1868
  success: Joi.boolean(),
75
1869
  });
76
1870
  }
1871
+
1872
+ /** @returns {AddCartRequest} */
77
1873
  static AddCartRequest() {
78
1874
  return Joi.object({
79
- items: Joi.array().items(CartModel.AddProductCart()),
1875
+ items: Joi.array().items(CartPlatformModel.AddProductCart()),
80
1876
  new_cart: Joi.boolean(),
81
1877
  });
82
1878
  }
1879
+
1880
+ /** @returns {AddProductCart} */
83
1881
  static AddProductCart() {
84
1882
  return Joi.object({
85
1883
  _custom_json: Joi.any(),
@@ -100,35 +1898,45 @@ class CartModel {
100
1898
  store_id: Joi.number(),
101
1899
  });
102
1900
  }
1901
+
1902
+ /** @returns {AppliedFreeArticles} */
103
1903
  static AppliedFreeArticles() {
104
1904
  return Joi.object({
105
1905
  article_id: Joi.string().allow(""),
106
- free_gift_item_details: CartModel.FreeGiftItem(),
1906
+ free_gift_item_details: CartPlatformModel.FreeGiftItem(),
107
1907
  parent_item_identifier: Joi.string().allow(""),
108
1908
  quantity: Joi.number(),
109
1909
  });
110
1910
  }
1911
+
1912
+ /** @returns {AppliedPromotion} */
111
1913
  static AppliedPromotion() {
112
1914
  return Joi.object({
113
1915
  amount: Joi.number(),
114
- applied_free_articles: Joi.array().items(CartModel.AppliedFreeArticles()),
1916
+ applied_free_articles: Joi.array().items(
1917
+ CartPlatformModel.AppliedFreeArticles()
1918
+ ),
115
1919
  article_quantity: Joi.number(),
116
- buy_rules: Joi.array().items(CartModel.BuyRules()),
117
- discount_rules: Joi.array().items(CartModel.DiscountRulesApp()),
1920
+ buy_rules: Joi.array().items(CartPlatformModel.BuyRules()),
1921
+ discount_rules: Joi.array().items(CartPlatformModel.DiscountRulesApp()),
118
1922
  mrp_promotion: Joi.boolean(),
119
1923
  offer_text: Joi.string().allow(""),
120
- ownership: CartModel.Ownership2(),
1924
+ ownership: CartPlatformModel.Ownership2(),
121
1925
  promo_id: Joi.string().allow(""),
122
1926
  promotion_group: Joi.string().allow(""),
123
1927
  promotion_name: Joi.string().allow(""),
124
1928
  promotion_type: Joi.string().allow(""),
125
1929
  });
126
1930
  }
1931
+
1932
+ /** @returns {ApplyCouponRequest} */
127
1933
  static ApplyCouponRequest() {
128
1934
  return Joi.object({
129
1935
  coupon_code: Joi.string().allow("").required(),
130
1936
  });
131
1937
  }
1938
+
1939
+ /** @returns {Article} */
132
1940
  static Article() {
133
1941
  return Joi.object({
134
1942
  article_id: Joi.string().allow("").required(),
@@ -138,18 +1946,24 @@ class CartModel {
138
1946
  value: Joi.number(),
139
1947
  });
140
1948
  }
1949
+
1950
+ /** @returns {ArticlePriceInfo} */
141
1951
  static ArticlePriceInfo() {
142
1952
  return Joi.object({
143
- base: CartModel.BasePrice(),
144
- converted: CartModel.BasePrice(),
1953
+ base: CartPlatformModel.BasePrice(),
1954
+ converted: CartPlatformModel.BasePrice(),
145
1955
  });
146
1956
  }
1957
+
1958
+ /** @returns {BaseInfo} */
147
1959
  static BaseInfo() {
148
1960
  return Joi.object({
149
1961
  name: Joi.string().allow(""),
150
1962
  uid: Joi.number(),
151
1963
  });
152
1964
  }
1965
+
1966
+ /** @returns {BasePrice} */
153
1967
  static BasePrice() {
154
1968
  return Joi.object({
155
1969
  currency_code: Joi.string().allow(""),
@@ -158,30 +1972,38 @@ class CartModel {
158
1972
  marked: Joi.number(),
159
1973
  });
160
1974
  }
1975
+
1976
+ /** @returns {BulkBundleRestriction} */
161
1977
  static BulkBundleRestriction() {
162
1978
  return Joi.object({
163
1979
  multi_store_allowed: Joi.boolean().required(),
164
1980
  });
165
1981
  }
1982
+
1983
+ /** @returns {BuyRules} */
166
1984
  static BuyRules() {
167
1985
  return Joi.object({
168
1986
  cart_conditions: Joi.any(),
169
1987
  item_criteria: Joi.any(),
170
1988
  });
171
1989
  }
1990
+
1991
+ /** @returns {CartBreakup} */
172
1992
  static CartBreakup() {
173
1993
  return Joi.object({
174
- coupon: CartModel.CouponBreakup(),
175
- display: Joi.array().items(CartModel.DisplayBreakup()),
176
- loyalty_points: CartModel.LoyaltyPoints(),
177
- raw: CartModel.RawBreakup(),
1994
+ coupon: CartPlatformModel.CouponBreakup(),
1995
+ display: Joi.array().items(CartPlatformModel.DisplayBreakup()),
1996
+ loyalty_points: CartPlatformModel.LoyaltyPoints(),
1997
+ raw: CartPlatformModel.RawBreakup(),
178
1998
  });
179
1999
  }
2000
+
2001
+ /** @returns {CartCheckoutResponse} */
180
2002
  static CartCheckoutResponse() {
181
2003
  return Joi.object({
182
2004
  app_intercept_url: Joi.string().allow(""),
183
2005
  callback_url: Joi.string().allow(""),
184
- cart: CartModel.CheckCart(),
2006
+ cart: CartPlatformModel.CheckCart(),
185
2007
  data: Joi.any(),
186
2008
  message: Joi.string().allow(""),
187
2009
  order_id: Joi.string().allow(""),
@@ -189,41 +2011,51 @@ class CartModel {
189
2011
  success: Joi.boolean(),
190
2012
  });
191
2013
  }
2014
+
2015
+ /** @returns {CartCurrency} */
192
2016
  static CartCurrency() {
193
2017
  return Joi.object({
194
2018
  code: Joi.string().allow(""),
195
2019
  symbol: Joi.string().allow(""),
196
2020
  });
197
2021
  }
2022
+
2023
+ /** @returns {CartDeliveryModesResponse} */
198
2024
  static CartDeliveryModesResponse() {
199
2025
  return Joi.object({
200
2026
  available_modes: Joi.array().items(Joi.string().allow("")),
201
2027
  pickup_stores: Joi.array().items(Joi.number()),
202
2028
  });
203
2029
  }
2030
+
2031
+ /** @returns {CartDetailResponse} */
204
2032
  static CartDetailResponse() {
205
2033
  return Joi.object({
206
- applied_promo_details: Joi.array().items(CartModel.AppliedPromotion()),
207
- breakup_values: CartModel.CartBreakup(),
2034
+ applied_promo_details: Joi.array().items(
2035
+ CartPlatformModel.AppliedPromotion()
2036
+ ),
2037
+ breakup_values: CartPlatformModel.CartBreakup(),
208
2038
  buy_now: Joi.boolean(),
209
2039
  checkout_mode: Joi.string().allow(""),
210
2040
  comment: Joi.string().allow(""),
211
2041
  coupon_text: Joi.string().allow(""),
212
- currency: CartModel.CartCurrency(),
2042
+ currency: CartPlatformModel.CartCurrency(),
213
2043
  delivery_charge_info: Joi.string().allow(""),
214
- delivery_promise: CartModel.ShipmentPromise(),
2044
+ delivery_promise: CartPlatformModel.ShipmentPromise(),
215
2045
  gstin: Joi.string().allow(""),
216
2046
  id: Joi.string().allow(""),
217
2047
  is_valid: Joi.boolean(),
218
- items: Joi.array().items(CartModel.CartProductInfo()),
2048
+ items: Joi.array().items(CartPlatformModel.CartProductInfo()),
219
2049
  last_modified: Joi.string().allow(""),
220
2050
  message: Joi.string().allow(""),
221
2051
  pan_config: Joi.any(),
222
2052
  pan_no: Joi.string().allow(""),
223
- payment_selection_lock: CartModel.PaymentSelectionLock(),
2053
+ payment_selection_lock: CartPlatformModel.PaymentSelectionLock(),
224
2054
  restrict_checkout: Joi.boolean(),
225
2055
  });
226
2056
  }
2057
+
2058
+ /** @returns {CartItem} */
227
2059
  static CartItem() {
228
2060
  return Joi.object({
229
2061
  product_id: Joi.string().allow("").required(),
@@ -231,17 +2063,23 @@ class CartModel {
231
2063
  size: Joi.string().allow("").required(),
232
2064
  });
233
2065
  }
2066
+
2067
+ /** @returns {CartItemCountResponse} */
234
2068
  static CartItemCountResponse() {
235
2069
  return Joi.object({
236
2070
  user_cart_items_count: Joi.number(),
237
2071
  });
238
2072
  }
2073
+
2074
+ /** @returns {CartItemMeta} */
239
2075
  static CartItemMeta() {
240
2076
  return Joi.object({
241
2077
  group_id: Joi.string().allow(""),
242
2078
  primary_item: Joi.boolean(),
243
2079
  });
244
2080
  }
2081
+
2082
+ /** @returns {CartList} */
245
2083
  static CartList() {
246
2084
  return Joi.object({
247
2085
  cart_id: Joi.string().allow(""),
@@ -252,10 +2090,12 @@ class CartModel {
252
2090
  user_id: Joi.string().allow(""),
253
2091
  });
254
2092
  }
2093
+
2094
+ /** @returns {CartMetaConfigAdd} */
255
2095
  static CartMetaConfigAdd() {
256
2096
  return Joi.object({
257
2097
  bulk_coupons: Joi.boolean(),
258
- delivery_charges: CartModel.DeliveryCharges(),
2098
+ delivery_charges: CartPlatformModel.DeliveryCharges(),
259
2099
  enabled: Joi.boolean(),
260
2100
  gift_display_text: Joi.string().allow(""),
261
2101
  gift_pricing: Joi.number(),
@@ -264,10 +2104,12 @@ class CartModel {
264
2104
  revenue_engine_coupon: Joi.boolean(),
265
2105
  });
266
2106
  }
2107
+
2108
+ /** @returns {CartMetaConfigUpdate} */
267
2109
  static CartMetaConfigUpdate() {
268
2110
  return Joi.object({
269
2111
  bulk_coupons: Joi.boolean(),
270
- delivery_charges: CartModel.DeliveryCharges(),
2112
+ delivery_charges: CartPlatformModel.DeliveryCharges(),
271
2113
  enabled: Joi.boolean(),
272
2114
  gift_display_text: Joi.string().allow(""),
273
2115
  gift_pricing: Joi.number(),
@@ -276,77 +2118,95 @@ class CartModel {
276
2118
  revenue_engine_coupon: Joi.boolean(),
277
2119
  });
278
2120
  }
2121
+
2122
+ /** @returns {CartMetaMissingResponse} */
279
2123
  static CartMetaMissingResponse() {
280
2124
  return Joi.object({
281
2125
  errors: Joi.array().items(Joi.string().allow("")),
282
2126
  });
283
2127
  }
2128
+
2129
+ /** @returns {CartMetaResponse} */
284
2130
  static CartMetaResponse() {
285
2131
  return Joi.object({
286
2132
  is_valid: Joi.boolean(),
287
2133
  message: Joi.string().allow(""),
288
2134
  });
289
2135
  }
2136
+
2137
+ /** @returns {CartProduct} */
290
2138
  static CartProduct() {
291
2139
  return Joi.object({
292
2140
  _custom_json: Joi.any(),
293
- action: CartModel.ProductAction(),
294
- brand: CartModel.BaseInfo(),
295
- categories: Joi.array().items(CartModel.CategoryInfo()),
296
- images: Joi.array().items(CartModel.ProductImage()),
2141
+ action: CartPlatformModel.ProductAction(),
2142
+ brand: CartPlatformModel.BaseInfo(),
2143
+ categories: Joi.array().items(CartPlatformModel.CategoryInfo()),
2144
+ images: Joi.array().items(CartPlatformModel.ProductImage()),
297
2145
  item_code: Joi.string().allow("").allow(null),
298
2146
  name: Joi.string().allow(""),
299
2147
  slug: Joi.string().allow(""),
300
2148
  tags: Joi.array().items(Joi.string().allow("")),
301
- teaser_tag: CartModel.Tags(),
2149
+ teaser_tag: CartPlatformModel.Tags(),
302
2150
  type: Joi.string().allow(""),
303
2151
  uid: Joi.number(),
304
2152
  });
305
2153
  }
2154
+
2155
+ /** @returns {CartProductIdentifer} */
306
2156
  static CartProductIdentifer() {
307
2157
  return Joi.object({
308
2158
  identifier: Joi.string().allow(""),
309
2159
  });
310
2160
  }
2161
+
2162
+ /** @returns {CartProductInfo} */
311
2163
  static CartProductInfo() {
312
2164
  return Joi.object({
313
- article: CartModel.ProductArticle(),
314
- availability: CartModel.ProductAvailability(),
2165
+ article: CartPlatformModel.ProductArticle(),
2166
+ availability: CartPlatformModel.ProductAvailability(),
315
2167
  bulk_offer: Joi.any(),
316
- coupon: CartModel.CouponDetails(),
2168
+ coupon: CartPlatformModel.CouponDetails(),
317
2169
  coupon_message: Joi.string().allow(""),
318
2170
  custom_order: Joi.any(),
319
- delivery_promise: CartModel.ShipmentPromise(),
2171
+ delivery_promise: CartPlatformModel.ShipmentPromise(),
320
2172
  discount: Joi.string().allow(""),
321
- identifiers: CartModel.CartProductIdentifer().required(),
2173
+ identifiers: CartPlatformModel.CartProductIdentifer().required(),
322
2174
  is_set: Joi.boolean(),
323
2175
  key: Joi.string().allow(""),
324
2176
  message: Joi.string().allow(""),
325
2177
  moq: Joi.any(),
326
2178
  parent_item_identifiers: Joi.any(),
327
- price: CartModel.ProductPriceInfo(),
328
- price_per_unit: CartModel.ProductPriceInfo(),
329
- product: CartModel.CartProduct(),
330
- promo_meta: CartModel.PromoMeta(),
331
- promotions_applied: Joi.array().items(CartModel.AppliedPromotion()),
2179
+ price: CartPlatformModel.ProductPriceInfo(),
2180
+ price_per_unit: CartPlatformModel.ProductPriceInfo(),
2181
+ product: CartPlatformModel.CartProduct(),
2182
+ promo_meta: CartPlatformModel.PromoMeta(),
2183
+ promotions_applied: Joi.array().items(
2184
+ CartPlatformModel.AppliedPromotion()
2185
+ ),
332
2186
  quantity: Joi.number(),
333
2187
  });
334
2188
  }
2189
+
2190
+ /** @returns {CategoryInfo} */
335
2191
  static CategoryInfo() {
336
2192
  return Joi.object({
337
2193
  name: Joi.string().allow(""),
338
2194
  uid: Joi.number(),
339
2195
  });
340
2196
  }
2197
+
2198
+ /** @returns {Charges} */
341
2199
  static Charges() {
342
2200
  return Joi.object({
343
2201
  charges: Joi.number(),
344
2202
  threshold: Joi.number(),
345
2203
  });
346
2204
  }
2205
+
2206
+ /** @returns {CheckCart} */
347
2207
  static CheckCart() {
348
2208
  return Joi.object({
349
- breakup_values: CartModel.CartBreakup(),
2209
+ breakup_values: CartPlatformModel.CartBreakup(),
350
2210
  buy_now: Joi.boolean(),
351
2211
  cart_id: Joi.number(),
352
2212
  checkout_mode: Joi.string().allow(""),
@@ -355,20 +2215,20 @@ class CartModel {
355
2215
  cod_message: Joi.string().allow(""),
356
2216
  comment: Joi.string().allow(""),
357
2217
  coupon_text: Joi.string().allow(""),
358
- currency: CartModel.CartCurrency(),
2218
+ currency: CartPlatformModel.CartCurrency(),
359
2219
  delivery_charge_info: Joi.string().allow(""),
360
2220
  delivery_charge_order_value: Joi.number(),
361
2221
  delivery_charges: Joi.number(),
362
- delivery_promise: CartModel.ShipmentPromise(),
2222
+ delivery_promise: CartPlatformModel.ShipmentPromise(),
363
2223
  error_message: Joi.string().allow(""),
364
2224
  gstin: Joi.string().allow(""),
365
2225
  id: Joi.string().allow(""),
366
2226
  is_valid: Joi.boolean(),
367
- items: Joi.array().items(CartModel.CartProductInfo()),
2227
+ items: Joi.array().items(CartPlatformModel.CartProductInfo()),
368
2228
  last_modified: Joi.string().allow(""),
369
2229
  message: Joi.string().allow(""),
370
2230
  order_id: Joi.string().allow(""),
371
- payment_selection_lock: CartModel.PaymentSelectionLock(),
2231
+ payment_selection_lock: CartPlatformModel.PaymentSelectionLock(),
372
2232
  restrict_checkout: Joi.boolean(),
373
2233
  store_code: Joi.string().allow(""),
374
2234
  store_emps: Joi.array().items(Joi.any()),
@@ -377,12 +2237,16 @@ class CartModel {
377
2237
  user_type: Joi.string().allow(""),
378
2238
  });
379
2239
  }
2240
+
2241
+ /** @returns {Collection} */
380
2242
  static Collection() {
381
2243
  return Joi.object({
382
2244
  collected_by: Joi.string().allow("").required(),
383
2245
  refund_by: Joi.string().allow("").required(),
384
2246
  });
385
2247
  }
2248
+
2249
+ /** @returns {CompareObject} */
386
2250
  static CompareObject() {
387
2251
  return Joi.object({
388
2252
  equals: Joi.number(),
@@ -392,6 +2256,8 @@ class CartModel {
392
2256
  less_than_equals: Joi.number(),
393
2257
  });
394
2258
  }
2259
+
2260
+ /** @returns {Coupon} */
395
2261
  static Coupon() {
396
2262
  return Joi.object({
397
2263
  coupon_code: Joi.string().allow(""),
@@ -408,38 +2274,46 @@ class CartModel {
408
2274
  title: Joi.string().allow(""),
409
2275
  });
410
2276
  }
2277
+
2278
+ /** @returns {CouponAction} */
411
2279
  static CouponAction() {
412
2280
  return Joi.object({
413
2281
  action_date: Joi.string().allow("").allow(null),
414
2282
  txn_mode: Joi.string().allow(""),
415
2283
  });
416
2284
  }
2285
+
2286
+ /** @returns {CouponAdd} */
417
2287
  static CouponAdd() {
418
2288
  return Joi.object({
419
- _schedule: CartModel.CouponSchedule(),
420
- action: CartModel.CouponAction(),
421
- author: CartModel.CouponAuthor(),
2289
+ _schedule: CartPlatformModel.CouponSchedule(),
2290
+ action: CartPlatformModel.CouponAction(),
2291
+ author: CartPlatformModel.CouponAuthor(),
422
2292
  code: Joi.string().allow("").required(),
423
- date_meta: CartModel.CouponDateMeta(),
424
- display_meta: CartModel.DisplayMeta().required(),
425
- identifiers: CartModel.Identifier().required(),
426
- ownership: CartModel.Ownership().required(),
427
- restrictions: CartModel.Restrictions(),
428
- rule: Joi.array().items(CartModel.Rule()).required(),
429
- rule_definition: CartModel.RuleDefinition().required(),
430
- state: CartModel.State(),
2293
+ date_meta: CartPlatformModel.CouponDateMeta(),
2294
+ display_meta: CartPlatformModel.DisplayMeta().required(),
2295
+ identifiers: CartPlatformModel.Identifier().required(),
2296
+ ownership: CartPlatformModel.Ownership().required(),
2297
+ restrictions: CartPlatformModel.Restrictions(),
2298
+ rule: Joi.array().items(CartPlatformModel.Rule()).required(),
2299
+ rule_definition: CartPlatformModel.RuleDefinition().required(),
2300
+ state: CartPlatformModel.State(),
431
2301
  tags: Joi.array().items(Joi.string().allow("")),
432
2302
  type_slug: Joi.string().allow("").required(),
433
- validation: CartModel.Validation(),
434
- validity: CartModel.Validity().required(),
2303
+ validation: CartPlatformModel.Validation(),
2304
+ validity: CartPlatformModel.Validity().required(),
435
2305
  });
436
2306
  }
2307
+
2308
+ /** @returns {CouponAuthor} */
437
2309
  static CouponAuthor() {
438
2310
  return Joi.object({
439
2311
  created_by: Joi.string().allow("").allow(null),
440
2312
  modified_by: Joi.string().allow("").allow(null),
441
2313
  });
442
2314
  }
2315
+
2316
+ /** @returns {CouponBreakup} */
443
2317
  static CouponBreakup() {
444
2318
  return Joi.object({
445
2319
  code: Joi.string().allow(""),
@@ -457,12 +2331,16 @@ class CartModel {
457
2331
  value: Joi.number(),
458
2332
  });
459
2333
  }
2334
+
2335
+ /** @returns {CouponDateMeta} */
460
2336
  static CouponDateMeta() {
461
2337
  return Joi.object({
462
2338
  created_on: Joi.string().allow("").allow(null),
463
2339
  modified_on: Joi.string().allow("").allow(null),
464
2340
  });
465
2341
  }
2342
+
2343
+ /** @returns {CouponDetails} */
466
2344
  static CouponDetails() {
467
2345
  return Joi.object({
468
2346
  code: Joi.string().allow(""),
@@ -470,12 +2348,16 @@ class CartModel {
470
2348
  discount_total_quantity: Joi.number(),
471
2349
  });
472
2350
  }
2351
+
2352
+ /** @returns {CouponPartialUpdate} */
473
2353
  static CouponPartialUpdate() {
474
2354
  return Joi.object({
475
2355
  archive: Joi.boolean(),
476
- schedule: CartModel.CouponSchedule(),
2356
+ schedule: CartPlatformModel.CouponSchedule(),
477
2357
  });
478
2358
  }
2359
+
2360
+ /** @returns {CouponSchedule} */
479
2361
  static CouponSchedule() {
480
2362
  return Joi.object({
481
2363
  cron: Joi.string().allow("").allow(null),
@@ -485,32 +2367,38 @@ class CartModel {
485
2367
  start: Joi.string().allow(""),
486
2368
  });
487
2369
  }
2370
+
2371
+ /** @returns {CouponsResponse} */
488
2372
  static CouponsResponse() {
489
2373
  return Joi.object({
490
- items: CartModel.CouponAdd(),
491
- page: CartModel.Page(),
2374
+ items: CartPlatformModel.CouponAdd(),
2375
+ page: CartPlatformModel.Page(),
492
2376
  });
493
2377
  }
2378
+
2379
+ /** @returns {CouponUpdate} */
494
2380
  static CouponUpdate() {
495
2381
  return Joi.object({
496
- _schedule: CartModel.CouponSchedule(),
497
- action: CartModel.CouponAction(),
498
- author: CartModel.CouponAuthor(),
2382
+ _schedule: CartPlatformModel.CouponSchedule(),
2383
+ action: CartPlatformModel.CouponAction(),
2384
+ author: CartPlatformModel.CouponAuthor(),
499
2385
  code: Joi.string().allow("").required(),
500
- date_meta: CartModel.CouponDateMeta(),
501
- display_meta: CartModel.DisplayMeta().required(),
502
- identifiers: CartModel.Identifier().required(),
503
- ownership: CartModel.Ownership().required(),
504
- restrictions: CartModel.Restrictions(),
505
- rule: Joi.array().items(CartModel.Rule()).required(),
506
- rule_definition: CartModel.RuleDefinition().required(),
507
- state: CartModel.State(),
2386
+ date_meta: CartPlatformModel.CouponDateMeta(),
2387
+ display_meta: CartPlatformModel.DisplayMeta().required(),
2388
+ identifiers: CartPlatformModel.Identifier().required(),
2389
+ ownership: CartPlatformModel.Ownership().required(),
2390
+ restrictions: CartPlatformModel.Restrictions(),
2391
+ rule: Joi.array().items(CartPlatformModel.Rule()).required(),
2392
+ rule_definition: CartPlatformModel.RuleDefinition().required(),
2393
+ state: CartPlatformModel.State(),
508
2394
  tags: Joi.array().items(Joi.string().allow("")),
509
2395
  type_slug: Joi.string().allow("").required(),
510
- validation: CartModel.Validation(),
511
- validity: CartModel.Validity().required(),
2396
+ validation: CartPlatformModel.Validation(),
2397
+ validity: CartPlatformModel.Validity().required(),
512
2398
  });
513
2399
  }
2400
+
2401
+ /** @returns {CouponValidity} */
514
2402
  static CouponValidity() {
515
2403
  return Joi.object({
516
2404
  code: Joi.string().allow("").allow(null),
@@ -521,29 +2409,39 @@ class CartModel {
521
2409
  valid: Joi.boolean(),
522
2410
  });
523
2411
  }
2412
+
2413
+ /** @returns {DeleteAddressResponse} */
524
2414
  static DeleteAddressResponse() {
525
2415
  return Joi.object({
526
2416
  id: Joi.string().allow(""),
527
2417
  is_deleted: Joi.boolean(),
528
2418
  });
529
2419
  }
2420
+
2421
+ /** @returns {DeleteCartDetailResponse} */
530
2422
  static DeleteCartDetailResponse() {
531
2423
  return Joi.object({
532
2424
  message: Joi.string().allow(""),
533
2425
  success: Joi.boolean(),
534
2426
  });
535
2427
  }
2428
+
2429
+ /** @returns {DeleteCartRequest} */
536
2430
  static DeleteCartRequest() {
537
2431
  return Joi.object({
538
2432
  cart_id_list: Joi.array().items(Joi.string().allow("")),
539
2433
  });
540
2434
  }
2435
+
2436
+ /** @returns {DeliveryCharges} */
541
2437
  static DeliveryCharges() {
542
2438
  return Joi.object({
543
- charges: Joi.array().items(CartModel.Charges()),
2439
+ charges: Joi.array().items(CartPlatformModel.Charges()),
544
2440
  enabled: Joi.boolean(),
545
2441
  });
546
2442
  }
2443
+
2444
+ /** @returns {DiscountOffer} */
547
2445
  static DiscountOffer() {
548
2446
  return Joi.object({
549
2447
  apportion_discount: Joi.boolean(),
@@ -558,14 +2456,18 @@ class CartModel {
558
2456
  partial_can_ret: Joi.boolean(),
559
2457
  });
560
2458
  }
2459
+
2460
+ /** @returns {DiscountRule} */
561
2461
  static DiscountRule() {
562
2462
  return Joi.object({
563
2463
  buy_condition: Joi.string().allow("").required(),
564
2464
  discount_type: Joi.string().allow("").required(),
565
- item_criteria: CartModel.ItemCriteria().required(),
566
- offer: CartModel.DiscountOffer().required(),
2465
+ item_criteria: CartPlatformModel.ItemCriteria().required(),
2466
+ offer: CartPlatformModel.DiscountOffer().required(),
567
2467
  });
568
2468
  }
2469
+
2470
+ /** @returns {DiscountRulesApp} */
569
2471
  static DiscountRulesApp() {
570
2472
  return Joi.object({
571
2473
  item_criteria: Joi.any(),
@@ -574,6 +2476,8 @@ class CartModel {
574
2476
  raw_offer: Joi.any(),
575
2477
  });
576
2478
  }
2479
+
2480
+ /** @returns {DisplayBreakup} */
577
2481
  static DisplayBreakup() {
578
2482
  return Joi.object({
579
2483
  currency_code: Joi.string().allow(""),
@@ -584,16 +2488,20 @@ class CartModel {
584
2488
  value: Joi.number(),
585
2489
  });
586
2490
  }
2491
+
2492
+ /** @returns {DisplayMeta} */
587
2493
  static DisplayMeta() {
588
2494
  return Joi.object({
589
- apply: CartModel.DisplayMetaDict(),
590
- auto: CartModel.DisplayMetaDict(),
2495
+ apply: CartPlatformModel.DisplayMetaDict(),
2496
+ auto: CartPlatformModel.DisplayMetaDict(),
591
2497
  description: Joi.string().allow(""),
592
- remove: CartModel.DisplayMetaDict(),
2498
+ remove: CartPlatformModel.DisplayMetaDict(),
593
2499
  subtitle: Joi.string().allow(""),
594
2500
  title: Joi.string().allow(""),
595
2501
  });
596
2502
  }
2503
+
2504
+ /** @returns {DisplayMeta1} */
597
2505
  static DisplayMeta1() {
598
2506
  return Joi.object({
599
2507
  description: Joi.string().allow(""),
@@ -602,18 +2510,24 @@ class CartModel {
602
2510
  offer_text: Joi.string().allow(""),
603
2511
  });
604
2512
  }
2513
+
2514
+ /** @returns {DisplayMetaDict} */
605
2515
  static DisplayMetaDict() {
606
2516
  return Joi.object({
607
2517
  subtitle: Joi.string().allow(""),
608
2518
  title: Joi.string().allow(""),
609
2519
  });
610
2520
  }
2521
+
2522
+ /** @returns {Files} */
611
2523
  static Files() {
612
2524
  return Joi.object({
613
2525
  key: Joi.string().allow("").required(),
614
2526
  values: Joi.array().items(Joi.string().allow("")).required(),
615
2527
  });
616
2528
  }
2529
+
2530
+ /** @returns {FreeGiftItem} */
617
2531
  static FreeGiftItem() {
618
2532
  return Joi.object({
619
2533
  item_brand_name: Joi.string().allow(""),
@@ -624,30 +2538,40 @@ class CartModel {
624
2538
  item_slug: Joi.string().allow(""),
625
2539
  });
626
2540
  }
2541
+
2542
+ /** @returns {GeoLocation} */
627
2543
  static GeoLocation() {
628
2544
  return Joi.object({
629
2545
  latitude: Joi.number(),
630
2546
  longitude: Joi.number(),
631
2547
  });
632
2548
  }
2549
+
2550
+ /** @returns {GetCouponResponse} */
633
2551
  static GetCouponResponse() {
634
2552
  return Joi.object({
635
- available_coupon_list: Joi.array().items(CartModel.Coupon()),
636
- page: CartModel.PageCoupon(),
2553
+ available_coupon_list: Joi.array().items(CartPlatformModel.Coupon()),
2554
+ page: CartPlatformModel.PageCoupon(),
637
2555
  });
638
2556
  }
2557
+
2558
+ /** @returns {GetShareCartLinkRequest} */
639
2559
  static GetShareCartLinkRequest() {
640
2560
  return Joi.object({
641
2561
  id: Joi.string().allow(""),
642
2562
  meta: Joi.any(),
643
2563
  });
644
2564
  }
2565
+
2566
+ /** @returns {GetShareCartLinkResponse} */
645
2567
  static GetShareCartLinkResponse() {
646
2568
  return Joi.object({
647
2569
  share_url: Joi.string().allow(""),
648
2570
  token: Joi.string().allow(""),
649
2571
  });
650
2572
  }
2573
+
2574
+ /** @returns {Identifier} */
651
2575
  static Identifier() {
652
2576
  return Joi.object({
653
2577
  article_id: Joi.array().items(Joi.string().allow("")),
@@ -662,15 +2586,17 @@ class CartModel {
662
2586
  user_id: Joi.array().items(Joi.string().allow("")),
663
2587
  });
664
2588
  }
2589
+
2590
+ /** @returns {ItemCriteria} */
665
2591
  static ItemCriteria() {
666
2592
  return Joi.object({
667
2593
  all_items: Joi.boolean(),
668
2594
  available_zones: Joi.array().items(Joi.string().allow("")),
669
2595
  buy_rules: Joi.array().items(Joi.string().allow("")),
670
- cart_quantity: CartModel.CompareObject(),
671
- cart_total: CartModel.CompareObject(),
672
- cart_unique_item_amount: CartModel.CompareObject(),
673
- cart_unique_item_quantity: CartModel.CompareObject(),
2596
+ cart_quantity: CartPlatformModel.CompareObject(),
2597
+ cart_total: CartPlatformModel.CompareObject(),
2598
+ cart_unique_item_amount: CartPlatformModel.CompareObject(),
2599
+ cart_unique_item_quantity: CartPlatformModel.CompareObject(),
674
2600
  item_brand: Joi.array().items(Joi.number()),
675
2601
  item_category: Joi.array().items(Joi.number()),
676
2602
  item_company: Joi.array().items(Joi.number()),
@@ -693,6 +2619,8 @@ class CartModel {
693
2619
  item_tags: Joi.array().items(Joi.string().allow("")),
694
2620
  });
695
2621
  }
2622
+
2623
+ /** @returns {LoyaltyPoints} */
696
2624
  static LoyaltyPoints() {
697
2625
  return Joi.object({
698
2626
  applicable: Joi.number(),
@@ -701,12 +2629,16 @@ class CartModel {
701
2629
  total: Joi.number(),
702
2630
  });
703
2631
  }
2632
+
2633
+ /** @returns {MultiCartResponse} */
704
2634
  static MultiCartResponse() {
705
2635
  return Joi.object({
706
- data: Joi.array().items(CartModel.CartList()),
2636
+ data: Joi.array().items(CartPlatformModel.CartList()),
707
2637
  success: Joi.boolean(),
708
2638
  });
709
2639
  }
2640
+
2641
+ /** @returns {MultiTenderPaymentMeta} */
710
2642
  static MultiTenderPaymentMeta() {
711
2643
  return Joi.object({
712
2644
  current_status: Joi.string().allow("").allow(null),
@@ -716,42 +2648,54 @@ class CartModel {
716
2648
  payment_id: Joi.string().allow("").allow(null),
717
2649
  });
718
2650
  }
2651
+
2652
+ /** @returns {MultiTenderPaymentMethod} */
719
2653
  static MultiTenderPaymentMethod() {
720
2654
  return Joi.object({
721
2655
  amount: Joi.number().required(),
722
- meta: CartModel.MultiTenderPaymentMeta(),
2656
+ meta: CartPlatformModel.MultiTenderPaymentMeta(),
723
2657
  mode: Joi.string().allow("").required(),
724
2658
  name: Joi.string().allow(""),
725
2659
  });
726
2660
  }
2661
+
2662
+ /** @returns {OpenapiCartDetailsRequest} */
727
2663
  static OpenapiCartDetailsRequest() {
728
2664
  return Joi.object({
729
- cart_items: Joi.array().items(CartModel.CartItem()).required(),
2665
+ cart_items: Joi.array().items(CartPlatformModel.CartItem()).required(),
730
2666
  });
731
2667
  }
2668
+
2669
+ /** @returns {OpenapiCartDetailsResponse} */
732
2670
  static OpenapiCartDetailsResponse() {
733
2671
  return Joi.object({
734
- breakup_values: CartModel.CartBreakup(),
2672
+ breakup_values: CartPlatformModel.CartBreakup(),
735
2673
  is_valid: Joi.boolean(),
736
- items: Joi.array().items(CartModel.CartProductInfo()),
2674
+ items: Joi.array().items(CartPlatformModel.CartProductInfo()),
737
2675
  message: Joi.string().allow(""),
738
2676
  });
739
2677
  }
2678
+
2679
+ /** @returns {OpenApiCartServiceabilityRequest} */
740
2680
  static OpenApiCartServiceabilityRequest() {
741
2681
  return Joi.object({
742
- cart_items: Joi.array().items(CartModel.CartItem()).required(),
743
- shipping_address: CartModel.ShippingAddress().required(),
2682
+ cart_items: Joi.array().items(CartPlatformModel.CartItem()).required(),
2683
+ shipping_address: CartPlatformModel.ShippingAddress().required(),
744
2684
  });
745
2685
  }
2686
+
2687
+ /** @returns {OpenApiCartServiceabilityResponse} */
746
2688
  static OpenApiCartServiceabilityResponse() {
747
2689
  return Joi.object({
748
- breakup_values: CartModel.CartBreakup(),
749
- delivery_promise: CartModel.ShipmentPromise(),
2690
+ breakup_values: CartPlatformModel.CartBreakup(),
2691
+ delivery_promise: CartPlatformModel.ShipmentPromise(),
750
2692
  is_valid: Joi.boolean(),
751
- items: Joi.array().items(CartModel.CartProductInfo()),
2693
+ items: Joi.array().items(CartPlatformModel.CartProductInfo()),
752
2694
  message: Joi.string().allow(""),
753
2695
  });
754
2696
  }
2697
+
2698
+ /** @returns {OpenApiCheckoutResponse} */
755
2699
  static OpenApiCheckoutResponse() {
756
2700
  return Joi.object({
757
2701
  message: Joi.string().allow(""),
@@ -760,6 +2704,8 @@ class CartModel {
760
2704
  success: Joi.boolean(),
761
2705
  });
762
2706
  }
2707
+
2708
+ /** @returns {OpenApiErrorResponse} */
763
2709
  static OpenApiErrorResponse() {
764
2710
  return Joi.object({
765
2711
  errors: Joi.any(),
@@ -767,12 +2713,16 @@ class CartModel {
767
2713
  success: Joi.boolean(),
768
2714
  });
769
2715
  }
2716
+
2717
+ /** @returns {OpenApiFiles} */
770
2718
  static OpenApiFiles() {
771
2719
  return Joi.object({
772
2720
  key: Joi.string().allow("").required(),
773
2721
  values: Joi.array().items(Joi.string().allow("")).required(),
774
2722
  });
775
2723
  }
2724
+
2725
+ /** @returns {OpenApiOrderItem} */
776
2726
  static OpenApiOrderItem() {
777
2727
  return Joi.object({
778
2728
  amount_paid: Joi.number().required(),
@@ -783,11 +2733,11 @@ class CartModel {
783
2733
  discount: Joi.number().required(),
784
2734
  employee_discount: Joi.number(),
785
2735
  extra_meta: Joi.any(),
786
- files: Joi.array().items(CartModel.OpenApiFiles()),
2736
+ files: Joi.array().items(CartPlatformModel.OpenApiFiles()),
787
2737
  loyalty_discount: Joi.number(),
788
- meta: CartModel.CartItemMeta(),
2738
+ meta: CartPlatformModel.CartItemMeta(),
789
2739
  payment_methods: Joi.array()
790
- .items(CartModel.MultiTenderPaymentMethod())
2740
+ .items(CartPlatformModel.MultiTenderPaymentMethod())
791
2741
  .required(),
792
2742
  price_effective: Joi.number().required(),
793
2743
  price_marked: Joi.number().required(),
@@ -796,11 +2746,15 @@ class CartModel {
796
2746
  size: Joi.string().allow("").required(),
797
2747
  });
798
2748
  }
2749
+
2750
+ /** @returns {OpenApiPlatformCheckoutReq} */
799
2751
  static OpenApiPlatformCheckoutReq() {
800
2752
  return Joi.object({
801
2753
  affiliate_order_id: Joi.string().allow(""),
802
- billing_address: CartModel.ShippingAddress().required(),
803
- cart_items: Joi.array().items(CartModel.OpenApiOrderItem()).required(),
2754
+ billing_address: CartPlatformModel.ShippingAddress().required(),
2755
+ cart_items: Joi.array()
2756
+ .items(CartPlatformModel.OpenApiOrderItem())
2757
+ .required(),
804
2758
  cart_value: Joi.number().required(),
805
2759
  cashback_applied: Joi.number().required(),
806
2760
  cod_charges: Joi.number().required(),
@@ -811,23 +2765,27 @@ class CartModel {
811
2765
  currency_code: Joi.string().allow(""),
812
2766
  delivery_charges: Joi.number().required(),
813
2767
  employee_discount: Joi.any(),
814
- files: Joi.array().items(CartModel.OpenApiFiles()),
2768
+ files: Joi.array().items(CartPlatformModel.OpenApiFiles()),
815
2769
  gstin: Joi.string().allow("").allow(null),
816
2770
  loyalty_discount: Joi.number(),
817
2771
  order_id: Joi.string().allow(""),
818
2772
  payment_methods: Joi.array()
819
- .items(CartModel.MultiTenderPaymentMethod())
2773
+ .items(CartPlatformModel.MultiTenderPaymentMethod())
820
2774
  .required(),
821
2775
  payment_mode: Joi.string().allow(""),
822
- shipping_address: CartModel.ShippingAddress(),
2776
+ shipping_address: CartPlatformModel.ShippingAddress(),
823
2777
  });
824
2778
  }
2779
+
2780
+ /** @returns {OperationErrorResponse} */
825
2781
  static OperationErrorResponse() {
826
2782
  return Joi.object({
827
2783
  message: Joi.string().allow(""),
828
2784
  success: Joi.boolean(),
829
2785
  });
830
2786
  }
2787
+
2788
+ /** @returns {OverrideCartItem} */
831
2789
  static OverrideCartItem() {
832
2790
  return Joi.object({
833
2791
  amount_paid: Joi.number().required(),
@@ -836,12 +2794,14 @@ class CartModel {
836
2794
  item_id: Joi.number().required(),
837
2795
  price_effective: Joi.number().required(),
838
2796
  price_marked: Joi.number().required(),
839
- promo_list: Joi.array().items(CartModel.OverrideCartItemPromo()),
2797
+ promo_list: Joi.array().items(CartPlatformModel.OverrideCartItemPromo()),
840
2798
  quantity: Joi.number(),
841
2799
  seller_identifier: Joi.string().allow(""),
842
2800
  size: Joi.string().allow("").required(),
843
2801
  });
844
2802
  }
2803
+
2804
+ /** @returns {OverrideCartItemPromo} */
845
2805
  static OverrideCartItemPromo() {
846
2806
  return Joi.object({
847
2807
  item_list: Joi.array().items(Joi.any().allow(null)),
@@ -851,12 +2811,16 @@ class CartModel {
851
2811
  rwrd_tndr: Joi.string().allow(""),
852
2812
  });
853
2813
  }
2814
+
2815
+ /** @returns {OverrideCheckoutReq} */
854
2816
  static OverrideCheckoutReq() {
855
2817
  return Joi.object({
856
2818
  aggregator: Joi.string().allow("").required(),
857
2819
  billing_address: Joi.any(),
858
2820
  cart_id: Joi.string().allow("").required(),
859
- cart_items: Joi.array().items(CartModel.OverrideCartItem()).required(),
2821
+ cart_items: Joi.array()
2822
+ .items(CartPlatformModel.OverrideCartItem())
2823
+ .required(),
860
2824
  currency_code: Joi.string().allow("").required(),
861
2825
  merchant_code: Joi.string().allow("").required(),
862
2826
  order_type: Joi.string().allow("").required(),
@@ -866,6 +2830,8 @@ class CartModel {
866
2830
  shipping_address: Joi.any(),
867
2831
  });
868
2832
  }
2833
+
2834
+ /** @returns {OverrideCheckoutResponse} */
869
2835
  static OverrideCheckoutResponse() {
870
2836
  return Joi.object({
871
2837
  cart: Joi.any().required(),
@@ -875,24 +2841,32 @@ class CartModel {
875
2841
  success: Joi.string().allow("").required(),
876
2842
  });
877
2843
  }
2844
+
2845
+ /** @returns {Ownership} */
878
2846
  static Ownership() {
879
2847
  return Joi.object({
880
2848
  payable_by: Joi.string().allow("").required(),
881
2849
  payable_category: Joi.string().allow("").required(),
882
2850
  });
883
2851
  }
2852
+
2853
+ /** @returns {Ownership1} */
884
2854
  static Ownership1() {
885
2855
  return Joi.object({
886
2856
  payable_by: Joi.string().allow("").required(),
887
2857
  payable_category: Joi.string().allow("").required(),
888
2858
  });
889
2859
  }
2860
+
2861
+ /** @returns {Ownership2} */
890
2862
  static Ownership2() {
891
2863
  return Joi.object({
892
2864
  payable_by: Joi.string().allow(""),
893
2865
  payable_category: Joi.string().allow(""),
894
2866
  });
895
2867
  }
2868
+
2869
+ /** @returns {Page} */
896
2870
  static Page() {
897
2871
  return Joi.object({
898
2872
  current: Joi.number(),
@@ -904,6 +2878,8 @@ class CartModel {
904
2878
  type: Joi.string().allow("").required(),
905
2879
  });
906
2880
  }
2881
+
2882
+ /** @returns {PageCoupon} */
907
2883
  static PageCoupon() {
908
2884
  return Joi.object({
909
2885
  current: Joi.number(),
@@ -913,23 +2889,31 @@ class CartModel {
913
2889
  total_item_count: Joi.number(),
914
2890
  });
915
2891
  }
2892
+
2893
+ /** @returns {PaymentAllowValue} */
916
2894
  static PaymentAllowValue() {
917
2895
  return Joi.object({
918
2896
  max: Joi.number(),
919
2897
  });
920
2898
  }
2899
+
2900
+ /** @returns {PaymentAllowValue1} */
921
2901
  static PaymentAllowValue1() {
922
2902
  return Joi.object({
923
2903
  max: Joi.number(),
924
2904
  });
925
2905
  }
2906
+
2907
+ /** @returns {PaymentCouponValidate} */
926
2908
  static PaymentCouponValidate() {
927
2909
  return Joi.object({
928
- coupon_validity: CartModel.CouponValidity(),
2910
+ coupon_validity: CartPlatformModel.CouponValidity(),
929
2911
  message: Joi.string().allow(""),
930
2912
  success: Joi.boolean().required(),
931
2913
  });
932
2914
  }
2915
+
2916
+ /** @returns {PaymentMeta} */
933
2917
  static PaymentMeta() {
934
2918
  return Joi.object({
935
2919
  merchant_code: Joi.string().allow(""),
@@ -938,24 +2922,30 @@ class CartModel {
938
2922
  type: Joi.string().allow(""),
939
2923
  });
940
2924
  }
2925
+
2926
+ /** @returns {PaymentMethod} */
941
2927
  static PaymentMethod() {
942
2928
  return Joi.object({
943
2929
  amount: Joi.number().allow(null),
944
2930
  mode: Joi.string().allow("").required(),
945
2931
  name: Joi.string().allow(""),
946
2932
  payment: Joi.string().allow(""),
947
- payment_meta: CartModel.PaymentMeta().required(),
2933
+ payment_meta: CartPlatformModel.PaymentMeta().required(),
948
2934
  });
949
2935
  }
2936
+
2937
+ /** @returns {PaymentModes} */
950
2938
  static PaymentModes() {
951
2939
  return Joi.object({
952
2940
  codes: Joi.array().items(Joi.string().allow("")),
953
2941
  iins: Joi.array().items(Joi.string().allow("")),
954
2942
  networks: Joi.array().items(Joi.string().allow("")),
955
2943
  types: Joi.array().items(Joi.string().allow("")),
956
- uses: CartModel.PaymentAllowValue(),
2944
+ uses: CartPlatformModel.PaymentAllowValue(),
957
2945
  });
958
2946
  }
2947
+
2948
+ /** @returns {PaymentSelectionLock} */
959
2949
  static PaymentSelectionLock() {
960
2950
  return Joi.object({
961
2951
  default_options: Joi.string().allow(""),
@@ -963,6 +2953,8 @@ class CartModel {
963
2953
  payment_identifier: Joi.string().allow(""),
964
2954
  });
965
2955
  }
2956
+
2957
+ /** @returns {PickupStoreDetail} */
966
2958
  static PickupStoreDetail() {
967
2959
  return Joi.object({
968
2960
  address: Joi.string().allow(""),
@@ -983,13 +2975,17 @@ class CartModel {
983
2975
  uid: Joi.number(),
984
2976
  });
985
2977
  }
2978
+
2979
+ /** @returns {PlatformAddCartRequest} */
986
2980
  static PlatformAddCartRequest() {
987
2981
  return Joi.object({
988
- items: Joi.array().items(CartModel.AddProductCart()),
2982
+ items: Joi.array().items(CartPlatformModel.AddProductCart()),
989
2983
  new_cart: Joi.boolean(),
990
2984
  user_id: Joi.string().allow(""),
991
2985
  });
992
2986
  }
2987
+
2988
+ /** @returns {PlatformAddress} */
993
2989
  static PlatformAddress() {
994
2990
  return Joi.object({
995
2991
  address: Joi.string().allow(""),
@@ -1004,7 +3000,7 @@ class CartModel {
1004
3000
  country_code: Joi.string().allow(""),
1005
3001
  created_by_user_id: Joi.string().allow(""),
1006
3002
  email: Joi.string().allow(""),
1007
- geo_location: CartModel.GeoLocation(),
3003
+ geo_location: CartPlatformModel.GeoLocation(),
1008
3004
  google_map_point: Joi.any(),
1009
3005
  id: Joi.string().allow(""),
1010
3006
  is_active: Joi.boolean(),
@@ -1018,6 +3014,8 @@ class CartModel {
1018
3014
  user_id: Joi.string().allow(""),
1019
3015
  });
1020
3016
  }
3017
+
3018
+ /** @returns {PlatformCartCheckoutDetailRequest} */
1021
3019
  static PlatformCartCheckoutDetailRequest() {
1022
3020
  return Joi.object({
1023
3021
  address_id: Joi.string().allow(""),
@@ -1030,7 +3028,7 @@ class CartModel {
1030
3028
  device_id: Joi.string().allow("").allow(null),
1031
3029
  employee_code: Joi.string().allow("").allow(null),
1032
3030
  extra_meta: Joi.any(),
1033
- files: Joi.array().items(CartModel.Files()),
3031
+ files: Joi.array().items(CartPlatformModel.Files()),
1034
3032
  id: Joi.string().allow("").required(),
1035
3033
  merchant_code: Joi.string().allow(""),
1036
3034
  meta: Joi.any(),
@@ -1042,10 +3040,12 @@ class CartModel {
1042
3040
  payment_params: Joi.any().allow(null),
1043
3041
  pick_at_store_uid: Joi.number().allow(null),
1044
3042
  pos: Joi.boolean(),
1045
- staff: CartModel.StaffCheckout(),
3043
+ staff: CartPlatformModel.StaffCheckout(),
1046
3044
  user_id: Joi.string().allow("").required(),
1047
3045
  });
1048
3046
  }
3047
+
3048
+ /** @returns {PlatformCartCheckoutDetailV2Request} */
1049
3049
  static PlatformCartCheckoutDetailV2Request() {
1050
3050
  return Joi.object({
1051
3051
  address_id: Joi.string().allow(""),
@@ -1059,7 +3059,7 @@ class CartModel {
1059
3059
  device_id: Joi.string().allow("").allow(null),
1060
3060
  employee_code: Joi.string().allow("").allow(null),
1061
3061
  extra_meta: Joi.any(),
1062
- files: Joi.array().items(CartModel.Files()),
3062
+ files: Joi.array().items(CartPlatformModel.Files()),
1063
3063
  id: Joi.string().allow("").required(),
1064
3064
  merchant_code: Joi.string().allow(""),
1065
3065
  meta: Joi.any(),
@@ -1067,15 +3067,19 @@ class CartModel {
1067
3067
  ordering_store: Joi.number().allow(null),
1068
3068
  payment_auto_confirm: Joi.boolean(),
1069
3069
  payment_identifier: Joi.string().allow("").allow(null),
1070
- payment_methods: Joi.array().items(CartModel.PaymentMethod()).required(),
3070
+ payment_methods: Joi.array()
3071
+ .items(CartPlatformModel.PaymentMethod())
3072
+ .required(),
1071
3073
  payment_mode: Joi.string().allow(""),
1072
3074
  payment_params: Joi.any().allow(null),
1073
3075
  pick_at_store_uid: Joi.number().allow(null),
1074
3076
  pos: Joi.boolean(),
1075
- staff: CartModel.StaffCheckout(),
3077
+ staff: CartPlatformModel.StaffCheckout(),
1076
3078
  user_id: Joi.string().allow("").required(),
1077
3079
  });
1078
3080
  }
3081
+
3082
+ /** @returns {PlatformCartMetaRequest} */
1079
3083
  static PlatformCartMetaRequest() {
1080
3084
  return Joi.object({
1081
3085
  checkout_mode: Joi.string().allow(""),
@@ -1087,37 +3091,47 @@ class CartModel {
1087
3091
  staff_user_id: Joi.string().allow("").allow(null),
1088
3092
  });
1089
3093
  }
3094
+
3095
+ /** @returns {PlatformCartShipmentsResponse} */
1090
3096
  static PlatformCartShipmentsResponse() {
1091
3097
  return Joi.object({
1092
- applied_promo_details: Joi.array().items(CartModel.AppliedPromotion()),
1093
- breakup_values: CartModel.CartBreakup(),
3098
+ applied_promo_details: Joi.array().items(
3099
+ CartPlatformModel.AppliedPromotion()
3100
+ ),
3101
+ breakup_values: CartPlatformModel.CartBreakup(),
1094
3102
  buy_now: Joi.boolean(),
1095
3103
  checkout_mode: Joi.string().allow(""),
1096
3104
  comment: Joi.string().allow(""),
1097
3105
  coupon_text: Joi.string().allow(""),
1098
- currency: CartModel.CartCurrency(),
3106
+ currency: CartPlatformModel.CartCurrency(),
1099
3107
  delivery_charge_info: Joi.string().allow(""),
1100
- delivery_promise: CartModel.ShipmentPromise(),
3108
+ delivery_promise: CartPlatformModel.ShipmentPromise(),
1101
3109
  error: Joi.boolean(),
1102
3110
  gstin: Joi.string().allow(""),
1103
3111
  id: Joi.string().allow(""),
1104
3112
  is_valid: Joi.boolean(),
1105
- items: Joi.array().items(CartModel.CartProductInfo()),
3113
+ items: Joi.array().items(CartPlatformModel.CartProductInfo()),
1106
3114
  last_modified: Joi.string().allow(""),
1107
3115
  message: Joi.string().allow(""),
1108
3116
  pan_config: Joi.any(),
1109
3117
  pan_no: Joi.string().allow(""),
1110
- payment_selection_lock: CartModel.PaymentSelectionLock(),
3118
+ payment_selection_lock: CartPlatformModel.PaymentSelectionLock(),
1111
3119
  restrict_checkout: Joi.boolean(),
1112
- shipments: Joi.array().items(CartModel.PlatformShipmentResponse()),
3120
+ shipments: Joi.array().items(
3121
+ CartPlatformModel.PlatformShipmentResponse()
3122
+ ),
1113
3123
  staff_user_id: Joi.string().allow("").allow(null),
1114
3124
  });
1115
3125
  }
3126
+
3127
+ /** @returns {PlatformGetAddressesResponse} */
1116
3128
  static PlatformGetAddressesResponse() {
1117
3129
  return Joi.object({
1118
- address: Joi.array().items(CartModel.PlatformAddress()),
3130
+ address: Joi.array().items(CartPlatformModel.PlatformAddress()),
1119
3131
  });
1120
3132
  }
3133
+
3134
+ /** @returns {PlatformSelectCartAddressRequest} */
1121
3135
  static PlatformSelectCartAddressRequest() {
1122
3136
  return Joi.object({
1123
3137
  billing_address_id: Joi.string().allow(""),
@@ -1127,49 +3141,59 @@ class CartModel {
1127
3141
  user_id: Joi.string().allow(""),
1128
3142
  });
1129
3143
  }
3144
+
3145
+ /** @returns {PlatformShipmentResponse} */
1130
3146
  static PlatformShipmentResponse() {
1131
3147
  return Joi.object({
1132
- articles: Joi.array().items(CartModel.ShipmentArticle()),
3148
+ articles: Joi.array().items(CartPlatformModel.ShipmentArticle()),
1133
3149
  box_type: Joi.string().allow("").allow(null),
1134
3150
  dp_id: Joi.string().allow("").allow(null),
1135
3151
  dp_options: Joi.any().allow(null),
1136
3152
  fulfillment_id: Joi.number(),
1137
3153
  fulfillment_type: Joi.string().allow(""),
1138
- items: Joi.array().items(CartModel.CartProductInfo()),
3154
+ items: Joi.array().items(CartPlatformModel.CartProductInfo()),
1139
3155
  order_type: Joi.string().allow(""),
1140
- promise: CartModel.ShipmentPromise(),
3156
+ promise: CartPlatformModel.ShipmentPromise(),
1141
3157
  shipment_type: Joi.string().allow(""),
1142
3158
  shipments: Joi.number(),
1143
3159
  });
1144
3160
  }
3161
+
3162
+ /** @returns {PlatformUpdateCartRequest} */
1145
3163
  static PlatformUpdateCartRequest() {
1146
3164
  return Joi.object({
1147
- items: Joi.array().items(CartModel.UpdateProductCart()),
3165
+ items: Joi.array().items(CartPlatformModel.UpdateProductCart()),
1148
3166
  operation: Joi.string().allow("").required(),
1149
3167
  user_id: Joi.string().allow(""),
1150
3168
  });
1151
3169
  }
3170
+
3171
+ /** @returns {PostOrder} */
1152
3172
  static PostOrder() {
1153
3173
  return Joi.object({
1154
3174
  cancellation_allowed: Joi.boolean(),
1155
3175
  return_allowed: Joi.boolean(),
1156
3176
  });
1157
3177
  }
3178
+
3179
+ /** @returns {PostOrder1} */
1158
3180
  static PostOrder1() {
1159
3181
  return Joi.object({
1160
3182
  cancellation_allowed: Joi.boolean(),
1161
3183
  return_allowed: Joi.boolean(),
1162
3184
  });
1163
3185
  }
3186
+
3187
+ /** @returns {PriceAdjustment} */
1164
3188
  static PriceAdjustment() {
1165
3189
  return Joi.object({
1166
3190
  allowed_refund: Joi.boolean(),
1167
3191
  apply_expiry: Joi.string().allow(""),
1168
- article_ids: Joi.array().items(CartModel.Article()).required(),
3192
+ article_ids: Joi.array().items(CartPlatformModel.Article()).required(),
1169
3193
  article_level_distribution: Joi.boolean().required(),
1170
3194
  cart_id: Joi.string().allow("").required(),
1171
3195
  cart_value: Joi.number(),
1172
- collection: CartModel.Collection().required(),
3196
+ collection: CartPlatformModel.Collection().required(),
1173
3197
  id: Joi.string().allow(""),
1174
3198
  is_authenticated: Joi.boolean().required(),
1175
3199
  message: Joi.string().allow("").required(),
@@ -1178,15 +3202,17 @@ class CartModel {
1178
3202
  value: Joi.number().required(),
1179
3203
  });
1180
3204
  }
3205
+
3206
+ /** @returns {PriceAdjustmentAdd} */
1181
3207
  static PriceAdjustmentAdd() {
1182
3208
  return Joi.object({
1183
3209
  allowed_refund: Joi.boolean(),
1184
3210
  apply_expiry: Joi.string().allow(""),
1185
- article_ids: Joi.array().items(CartModel.Article()).required(),
3211
+ article_ids: Joi.array().items(CartPlatformModel.Article()).required(),
1186
3212
  article_level_distribution: Joi.boolean().required(),
1187
3213
  cart_id: Joi.string().allow("").required(),
1188
3214
  cart_value: Joi.number(),
1189
- collection: CartModel.Collection().required(),
3215
+ collection: CartPlatformModel.Collection().required(),
1190
3216
  created_by: Joi.string().allow(""),
1191
3217
  is_authenticated: Joi.boolean().required(),
1192
3218
  message: Joi.string().allow("").required(),
@@ -1195,20 +3221,24 @@ class CartModel {
1195
3221
  value: Joi.number().required(),
1196
3222
  });
1197
3223
  }
3224
+
3225
+ /** @returns {PriceAdjustmentResponse} */
1198
3226
  static PriceAdjustmentResponse() {
1199
3227
  return Joi.object({
1200
- data: CartModel.PriceAdjustment(),
3228
+ data: CartPlatformModel.PriceAdjustment(),
1201
3229
  });
1202
3230
  }
3231
+
3232
+ /** @returns {PriceAdjustmentUpdate} */
1203
3233
  static PriceAdjustmentUpdate() {
1204
3234
  return Joi.object({
1205
3235
  allowed_refund: Joi.boolean(),
1206
3236
  apply_expiry: Joi.string().allow(""),
1207
- article_ids: Joi.array().items(CartModel.Article()).required(),
3237
+ article_ids: Joi.array().items(CartPlatformModel.Article()).required(),
1208
3238
  article_level_distribution: Joi.boolean().required(),
1209
3239
  cart_id: Joi.string().allow("").required(),
1210
3240
  cart_value: Joi.number(),
1211
- collection: CartModel.Collection().required(),
3241
+ collection: CartPlatformModel.Collection().required(),
1212
3242
  is_authenticated: Joi.boolean().required(),
1213
3243
  message: Joi.string().allow("").required(),
1214
3244
  meta: Joi.any(),
@@ -1217,19 +3247,25 @@ class CartModel {
1217
3247
  value: Joi.number().required(),
1218
3248
  });
1219
3249
  }
3250
+
3251
+ /** @returns {PriceRange} */
1220
3252
  static PriceRange() {
1221
3253
  return Joi.object({
1222
3254
  max: Joi.number(),
1223
3255
  min: Joi.number(),
1224
3256
  });
1225
3257
  }
3258
+
3259
+ /** @returns {ProductAction} */
1226
3260
  static ProductAction() {
1227
3261
  return Joi.object({
1228
- query: CartModel.ActionQuery(),
3262
+ query: CartPlatformModel.ActionQuery(),
1229
3263
  type: Joi.string().allow(""),
1230
3264
  url: Joi.string().allow(""),
1231
3265
  });
1232
3266
  }
3267
+
3268
+ /** @returns {ProductArticle} */
1233
3269
  static ProductArticle() {
1234
3270
  return Joi.object({
1235
3271
  _custom_json: Joi.any(),
@@ -1241,20 +3277,24 @@ class CartModel {
1241
3277
  meta: Joi.any(),
1242
3278
  mto_quantity: Joi.number(),
1243
3279
  parent_item_identifiers: Joi.any(),
1244
- price: CartModel.ArticlePriceInfo(),
3280
+ price: CartPlatformModel.ArticlePriceInfo(),
1245
3281
  product_group_tags: Joi.array().items(Joi.string().allow("")),
1246
3282
  quantity: Joi.number(),
1247
- seller: CartModel.BaseInfo(),
3283
+ seller: CartPlatformModel.BaseInfo(),
1248
3284
  seller_identifier: Joi.string().allow(""),
1249
3285
  size: Joi.string().allow(""),
1250
- store: CartModel.StoreInfo(),
3286
+ store: CartPlatformModel.StoreInfo(),
1251
3287
  type: Joi.string().allow(""),
1252
3288
  uid: Joi.string().allow(""),
1253
3289
  });
1254
3290
  }
3291
+
3292
+ /** @returns {ProductAvailability} */
1255
3293
  static ProductAvailability() {
1256
3294
  return Joi.object({
1257
- available_sizes: Joi.array().items(CartModel.ProductAvailabilitySize()),
3295
+ available_sizes: Joi.array().items(
3296
+ CartPlatformModel.ProductAvailabilitySize()
3297
+ ),
1258
3298
  deliverable: Joi.boolean(),
1259
3299
  is_valid: Joi.boolean(),
1260
3300
  other_store_quantity: Joi.number(),
@@ -1262,6 +3302,8 @@ class CartModel {
1262
3302
  sizes: Joi.array().items(Joi.string().allow("")),
1263
3303
  });
1264
3304
  }
3305
+
3306
+ /** @returns {ProductAvailabilitySize} */
1265
3307
  static ProductAvailabilitySize() {
1266
3308
  return Joi.object({
1267
3309
  display: Joi.string().allow(""),
@@ -1269,6 +3311,8 @@ class CartModel {
1269
3311
  value: Joi.string().allow(""),
1270
3312
  });
1271
3313
  }
3314
+
3315
+ /** @returns {ProductImage} */
1272
3316
  static ProductImage() {
1273
3317
  return Joi.object({
1274
3318
  aspect_ratio: Joi.string().allow(""),
@@ -1276,6 +3320,8 @@ class CartModel {
1276
3320
  url: Joi.string().allow(""),
1277
3321
  });
1278
3322
  }
3323
+
3324
+ /** @returns {ProductPrice} */
1279
3325
  static ProductPrice() {
1280
3326
  return Joi.object({
1281
3327
  add_on: Joi.number(),
@@ -1286,116 +3332,144 @@ class CartModel {
1286
3332
  selling: Joi.number(),
1287
3333
  });
1288
3334
  }
3335
+
3336
+ /** @returns {ProductPriceInfo} */
1289
3337
  static ProductPriceInfo() {
1290
3338
  return Joi.object({
1291
- base: CartModel.ProductPrice(),
1292
- converted: CartModel.ProductPrice(),
3339
+ base: CartPlatformModel.ProductPrice(),
3340
+ converted: CartPlatformModel.ProductPrice(),
1293
3341
  });
1294
3342
  }
3343
+
3344
+ /** @returns {PromiseFormatted} */
1295
3345
  static PromiseFormatted() {
1296
3346
  return Joi.object({
1297
3347
  max: Joi.string().allow(""),
1298
3348
  min: Joi.string().allow(""),
1299
3349
  });
1300
3350
  }
3351
+
3352
+ /** @returns {PromiseTimestamp} */
1301
3353
  static PromiseTimestamp() {
1302
3354
  return Joi.object({
1303
3355
  max: Joi.number(),
1304
3356
  min: Joi.number(),
1305
3357
  });
1306
3358
  }
3359
+
3360
+ /** @returns {PromoMeta} */
1307
3361
  static PromoMeta() {
1308
3362
  return Joi.object({
1309
3363
  message: Joi.string().allow(""),
1310
3364
  });
1311
3365
  }
3366
+
3367
+ /** @returns {PromotionAction} */
1312
3368
  static PromotionAction() {
1313
3369
  return Joi.object({
1314
3370
  action_date: Joi.string().allow("").allow(null).required(),
1315
3371
  action_type: Joi.string().allow("").required(),
1316
3372
  });
1317
3373
  }
3374
+
3375
+ /** @returns {PromotionAdd} */
1318
3376
  static PromotionAdd() {
1319
3377
  return Joi.object({
1320
3378
  _custom_json: Joi.any(),
1321
- _schedule: CartModel.PromotionSchedule(),
3379
+ _schedule: CartPlatformModel.PromotionSchedule(),
1322
3380
  application_id: Joi.string().allow("").required(),
1323
3381
  apply_all_discount: Joi.boolean(),
1324
3382
  apply_exclusive: Joi.string().allow("").allow(null),
1325
3383
  apply_priority: Joi.number(),
1326
- author: CartModel.PromotionAuthor(),
3384
+ author: CartPlatformModel.PromotionAuthor(),
1327
3385
  buy_rules: Joi.object()
1328
- .pattern(/\S/, CartModel.ItemCriteria())
3386
+ .pattern(/\S/, CartPlatformModel.ItemCriteria())
1329
3387
  .required(),
1330
3388
  calculate_on: Joi.string().allow(""),
1331
3389
  code: Joi.string().allow(""),
1332
3390
  currency: Joi.string().allow(""),
1333
- date_meta: CartModel.PromotionDateMeta(),
1334
- discount_rules: Joi.array().items(CartModel.DiscountRule()).required(),
1335
- display_meta: CartModel.DisplayMeta1().required(),
3391
+ date_meta: CartPlatformModel.PromotionDateMeta(),
3392
+ discount_rules: Joi.array()
3393
+ .items(CartPlatformModel.DiscountRule())
3394
+ .required(),
3395
+ display_meta: CartPlatformModel.DisplayMeta1().required(),
1336
3396
  mode: Joi.string().allow("").required(),
1337
- ownership: CartModel.Ownership1().required(),
1338
- post_order_action: CartModel.PromotionAction(),
3397
+ ownership: CartPlatformModel.Ownership1().required(),
3398
+ post_order_action: CartPlatformModel.PromotionAction(),
1339
3399
  promo_group: Joi.string().allow("").required(),
1340
3400
  promotion_type: Joi.string().allow("").required(),
1341
- restrictions: CartModel.Restrictions1(),
3401
+ restrictions: CartPlatformModel.Restrictions1(),
1342
3402
  stackable: Joi.boolean(),
1343
- visiblility: CartModel.Visibility(),
3403
+ visiblility: CartPlatformModel.Visibility(),
1344
3404
  });
1345
3405
  }
3406
+
3407
+ /** @returns {PromotionAuthor} */
1346
3408
  static PromotionAuthor() {
1347
3409
  return Joi.object({
1348
3410
  created_by: Joi.string().allow("").allow(null),
1349
3411
  modified_by: Joi.string().allow("").allow(null),
1350
3412
  });
1351
3413
  }
3414
+
3415
+ /** @returns {PromotionDateMeta} */
1352
3416
  static PromotionDateMeta() {
1353
3417
  return Joi.object({
1354
3418
  created_on: Joi.string().allow("").allow(null),
1355
3419
  modified_on: Joi.string().allow("").allow(null),
1356
3420
  });
1357
3421
  }
3422
+
3423
+ /** @returns {PromotionListItem} */
1358
3424
  static PromotionListItem() {
1359
3425
  return Joi.object({
1360
3426
  _custom_json: Joi.any(),
1361
- _schedule: CartModel.PromotionSchedule(),
3427
+ _schedule: CartPlatformModel.PromotionSchedule(),
1362
3428
  application_id: Joi.string().allow("").required(),
1363
3429
  apply_all_discount: Joi.boolean(),
1364
3430
  apply_exclusive: Joi.string().allow("").allow(null),
1365
3431
  apply_priority: Joi.number(),
1366
- author: CartModel.PromotionAuthor(),
3432
+ author: CartPlatformModel.PromotionAuthor(),
1367
3433
  buy_rules: Joi.object()
1368
- .pattern(/\S/, CartModel.ItemCriteria())
3434
+ .pattern(/\S/, CartPlatformModel.ItemCriteria())
1369
3435
  .required(),
1370
3436
  calculate_on: Joi.string().allow(""),
1371
3437
  code: Joi.string().allow(""),
1372
3438
  currency: Joi.string().allow(""),
1373
- date_meta: CartModel.PromotionDateMeta(),
1374
- discount_rules: Joi.array().items(CartModel.DiscountRule()).required(),
1375
- display_meta: CartModel.DisplayMeta1().required(),
3439
+ date_meta: CartPlatformModel.PromotionDateMeta(),
3440
+ discount_rules: Joi.array()
3441
+ .items(CartPlatformModel.DiscountRule())
3442
+ .required(),
3443
+ display_meta: CartPlatformModel.DisplayMeta1().required(),
1376
3444
  mode: Joi.string().allow("").required(),
1377
- ownership: CartModel.Ownership1().required(),
1378
- post_order_action: CartModel.PromotionAction(),
3445
+ ownership: CartPlatformModel.Ownership1().required(),
3446
+ post_order_action: CartPlatformModel.PromotionAction(),
1379
3447
  promo_group: Joi.string().allow("").required(),
1380
3448
  promotion_type: Joi.string().allow("").required(),
1381
- restrictions: CartModel.Restrictions1(),
3449
+ restrictions: CartPlatformModel.Restrictions1(),
1382
3450
  stackable: Joi.boolean(),
1383
- visiblility: CartModel.Visibility(),
3451
+ visiblility: CartPlatformModel.Visibility(),
1384
3452
  });
1385
3453
  }
3454
+
3455
+ /** @returns {PromotionPartialUpdate} */
1386
3456
  static PromotionPartialUpdate() {
1387
3457
  return Joi.object({
1388
3458
  archive: Joi.boolean(),
1389
- schedule: CartModel.PromotionSchedule(),
3459
+ schedule: CartPlatformModel.PromotionSchedule(),
1390
3460
  });
1391
3461
  }
3462
+
3463
+ /** @returns {PromotionPaymentModes} */
1392
3464
  static PromotionPaymentModes() {
1393
3465
  return Joi.object({
1394
3466
  codes: Joi.array().items(Joi.string().allow("")),
1395
3467
  type: Joi.string().allow("").required(),
1396
- uses: CartModel.PaymentAllowValue1(),
3468
+ uses: CartPlatformModel.PaymentAllowValue1(),
1397
3469
  });
1398
3470
  }
3471
+
3472
+ /** @returns {PromotionSchedule} */
1399
3473
  static PromotionSchedule() {
1400
3474
  return Joi.object({
1401
3475
  cron: Joi.string().allow("").allow(null),
@@ -1406,40 +3480,48 @@ class CartModel {
1406
3480
  start: Joi.string().allow("").required(),
1407
3481
  });
1408
3482
  }
3483
+
3484
+ /** @returns {PromotionsResponse} */
1409
3485
  static PromotionsResponse() {
1410
3486
  return Joi.object({
1411
- items: Joi.array().items(CartModel.PromotionListItem()),
1412
- page: CartModel.Page(),
3487
+ items: Joi.array().items(CartPlatformModel.PromotionListItem()),
3488
+ page: CartPlatformModel.Page(),
1413
3489
  });
1414
3490
  }
3491
+
3492
+ /** @returns {PromotionUpdate} */
1415
3493
  static PromotionUpdate() {
1416
3494
  return Joi.object({
1417
3495
  _custom_json: Joi.any(),
1418
- _schedule: CartModel.PromotionSchedule(),
3496
+ _schedule: CartPlatformModel.PromotionSchedule(),
1419
3497
  application_id: Joi.string().allow("").required(),
1420
3498
  apply_all_discount: Joi.boolean(),
1421
3499
  apply_exclusive: Joi.string().allow("").allow(null),
1422
3500
  apply_priority: Joi.number(),
1423
- author: CartModel.PromotionAuthor(),
3501
+ author: CartPlatformModel.PromotionAuthor(),
1424
3502
  buy_rules: Joi.object()
1425
- .pattern(/\S/, CartModel.ItemCriteria())
3503
+ .pattern(/\S/, CartPlatformModel.ItemCriteria())
1426
3504
  .required(),
1427
3505
  calculate_on: Joi.string().allow(""),
1428
3506
  code: Joi.string().allow(""),
1429
3507
  currency: Joi.string().allow(""),
1430
- date_meta: CartModel.PromotionDateMeta(),
1431
- discount_rules: Joi.array().items(CartModel.DiscountRule()).required(),
1432
- display_meta: CartModel.DisplayMeta1().required(),
3508
+ date_meta: CartPlatformModel.PromotionDateMeta(),
3509
+ discount_rules: Joi.array()
3510
+ .items(CartPlatformModel.DiscountRule())
3511
+ .required(),
3512
+ display_meta: CartPlatformModel.DisplayMeta1().required(),
1433
3513
  mode: Joi.string().allow("").required(),
1434
- ownership: CartModel.Ownership1().required(),
1435
- post_order_action: CartModel.PromotionAction(),
3514
+ ownership: CartPlatformModel.Ownership1().required(),
3515
+ post_order_action: CartPlatformModel.PromotionAction(),
1436
3516
  promo_group: Joi.string().allow("").required(),
1437
3517
  promotion_type: Joi.string().allow("").required(),
1438
- restrictions: CartModel.Restrictions1(),
3518
+ restrictions: CartPlatformModel.Restrictions1(),
1439
3519
  stackable: Joi.boolean(),
1440
- visiblility: CartModel.Visibility(),
3520
+ visiblility: CartPlatformModel.Visibility(),
1441
3521
  });
1442
3522
  }
3523
+
3524
+ /** @returns {RawBreakup} */
1443
3525
  static RawBreakup() {
1444
3526
  return Joi.object({
1445
3527
  cod_charge: Joi.number(),
@@ -1457,34 +3539,40 @@ class CartModel {
1457
3539
  you_saved: Joi.number(),
1458
3540
  });
1459
3541
  }
3542
+
3543
+ /** @returns {Restrictions} */
1460
3544
  static Restrictions() {
1461
3545
  return Joi.object({
1462
- bulk_bundle: CartModel.BulkBundleRestriction(),
3546
+ bulk_bundle: CartPlatformModel.BulkBundleRestriction(),
1463
3547
  coupon_allowed: Joi.boolean(),
1464
3548
  ordering_stores: Joi.array().items(Joi.number()),
1465
- payments: Joi.object().pattern(/\S/, CartModel.PaymentModes()),
3549
+ payments: Joi.object().pattern(/\S/, CartPlatformModel.PaymentModes()),
1466
3550
  platforms: Joi.array().items(Joi.string().allow("")),
1467
- post_order: CartModel.PostOrder(),
1468
- price_range: CartModel.PriceRange(),
3551
+ post_order: CartPlatformModel.PostOrder(),
3552
+ price_range: CartPlatformModel.PriceRange(),
1469
3553
  user_groups: Joi.array().items(Joi.number()),
1470
3554
  user_type: Joi.string().allow(""),
1471
- uses: CartModel.UsesRestriction(),
3555
+ uses: CartPlatformModel.UsesRestriction(),
1472
3556
  });
1473
3557
  }
3558
+
3559
+ /** @returns {Restrictions1} */
1474
3560
  static Restrictions1() {
1475
3561
  return Joi.object({
1476
3562
  anonymous_users: Joi.boolean(),
1477
3563
  order_quantity: Joi.number(),
1478
3564
  ordering_stores: Joi.array().items(Joi.number()),
1479
- payments: Joi.array().items(CartModel.PromotionPaymentModes()),
3565
+ payments: Joi.array().items(CartPlatformModel.PromotionPaymentModes()),
1480
3566
  platforms: Joi.array().items(Joi.string().allow("")),
1481
- post_order: CartModel.PostOrder1(),
3567
+ post_order: CartPlatformModel.PostOrder1(),
1482
3568
  user_groups: Joi.array().items(Joi.number()),
1483
3569
  user_id: Joi.array().items(Joi.string().allow("")),
1484
- user_registered: CartModel.UserRegistered(),
1485
- uses: CartModel.UsesRestriction1().required(),
3570
+ user_registered: CartPlatformModel.UserRegistered(),
3571
+ uses: CartPlatformModel.UsesRestriction1().required(),
1486
3572
  });
1487
3573
  }
3574
+
3575
+ /** @returns {Rule} */
1488
3576
  static Rule() {
1489
3577
  return Joi.object({
1490
3578
  discount_qty: Joi.number(),
@@ -1494,6 +3582,8 @@ class CartModel {
1494
3582
  value: Joi.number(),
1495
3583
  });
1496
3584
  }
3585
+
3586
+ /** @returns {RuleDefinition} */
1497
3587
  static RuleDefinition() {
1498
3588
  return Joi.object({
1499
3589
  applicable_on: Joi.string().allow("").required(),
@@ -1506,6 +3596,8 @@ class CartModel {
1506
3596
  value_type: Joi.string().allow("").required(),
1507
3597
  });
1508
3598
  }
3599
+
3600
+ /** @returns {SaveAddressResponse} */
1509
3601
  static SaveAddressResponse() {
1510
3602
  return Joi.object({
1511
3603
  id: Joi.string().allow(""),
@@ -1513,29 +3605,33 @@ class CartModel {
1513
3605
  success: Joi.boolean(),
1514
3606
  });
1515
3607
  }
3608
+
3609
+ /** @returns {SharedCart} */
1516
3610
  static SharedCart() {
1517
3611
  return Joi.object({
1518
- breakup_values: CartModel.CartBreakup(),
3612
+ breakup_values: CartPlatformModel.CartBreakup(),
1519
3613
  buy_now: Joi.boolean(),
1520
3614
  cart_id: Joi.number(),
1521
3615
  checkout_mode: Joi.string().allow(""),
1522
3616
  comment: Joi.string().allow(""),
1523
3617
  coupon_text: Joi.string().allow(""),
1524
- currency: CartModel.CartCurrency(),
3618
+ currency: CartPlatformModel.CartCurrency(),
1525
3619
  delivery_charge_info: Joi.string().allow(""),
1526
- delivery_promise: CartModel.ShipmentPromise(),
3620
+ delivery_promise: CartPlatformModel.ShipmentPromise(),
1527
3621
  gstin: Joi.string().allow(""),
1528
3622
  id: Joi.string().allow(""),
1529
3623
  is_valid: Joi.boolean(),
1530
- items: Joi.array().items(CartModel.CartProductInfo()),
3624
+ items: Joi.array().items(CartPlatformModel.CartProductInfo()),
1531
3625
  last_modified: Joi.string().allow(""),
1532
3626
  message: Joi.string().allow(""),
1533
- payment_selection_lock: CartModel.PaymentSelectionLock(),
3627
+ payment_selection_lock: CartPlatformModel.PaymentSelectionLock(),
1534
3628
  restrict_checkout: Joi.boolean(),
1535
- shared_cart_details: CartModel.SharedCartDetails(),
3629
+ shared_cart_details: CartPlatformModel.SharedCartDetails(),
1536
3630
  uid: Joi.string().allow(""),
1537
3631
  });
1538
3632
  }
3633
+
3634
+ /** @returns {SharedCartDetails} */
1539
3635
  static SharedCartDetails() {
1540
3636
  return Joi.object({
1541
3637
  created_on: Joi.string().allow(""),
@@ -1545,12 +3641,16 @@ class CartModel {
1545
3641
  user: Joi.any(),
1546
3642
  });
1547
3643
  }
3644
+
3645
+ /** @returns {SharedCartResponse} */
1548
3646
  static SharedCartResponse() {
1549
3647
  return Joi.object({
1550
- cart: CartModel.SharedCart(),
3648
+ cart: CartPlatformModel.SharedCart(),
1551
3649
  error: Joi.string().allow(""),
1552
3650
  });
1553
3651
  }
3652
+
3653
+ /** @returns {ShipmentArticle} */
1554
3654
  static ShipmentArticle() {
1555
3655
  return Joi.object({
1556
3656
  article_id: Joi.string().allow(""),
@@ -1558,12 +3658,16 @@ class CartModel {
1558
3658
  quantity: Joi.string().allow(""),
1559
3659
  });
1560
3660
  }
3661
+
3662
+ /** @returns {ShipmentPromise} */
1561
3663
  static ShipmentPromise() {
1562
3664
  return Joi.object({
1563
- formatted: CartModel.PromiseFormatted(),
1564
- timestamp: CartModel.PromiseTimestamp(),
3665
+ formatted: CartPlatformModel.PromiseFormatted(),
3666
+ timestamp: CartPlatformModel.PromiseTimestamp(),
1565
3667
  });
1566
3668
  }
3669
+
3670
+ /** @returns {ShippingAddress} */
1567
3671
  static ShippingAddress() {
1568
3672
  return Joi.object({
1569
3673
  address: Joi.string().allow(""),
@@ -1585,6 +3689,8 @@ class CartModel {
1585
3689
  state: Joi.string().allow("").allow(null),
1586
3690
  });
1587
3691
  }
3692
+
3693
+ /** @returns {StaffCheckout} */
1588
3694
  static StaffCheckout() {
1589
3695
  return Joi.object({
1590
3696
  _id: Joi.string().allow("").required(),
@@ -1594,6 +3700,8 @@ class CartModel {
1594
3700
  user: Joi.string().allow("").required(),
1595
3701
  });
1596
3702
  }
3703
+
3704
+ /** @returns {State} */
1597
3705
  static State() {
1598
3706
  return Joi.object({
1599
3707
  is_archived: Joi.boolean(),
@@ -1601,11 +3709,15 @@ class CartModel {
1601
3709
  is_public: Joi.boolean(),
1602
3710
  });
1603
3711
  }
3712
+
3713
+ /** @returns {StoreDetailsResponse} */
1604
3714
  static StoreDetailsResponse() {
1605
3715
  return Joi.object({
1606
- items: Joi.array().items(CartModel.PickupStoreDetail()),
3716
+ items: Joi.array().items(CartPlatformModel.PickupStoreDetail()),
1607
3717
  });
1608
3718
  }
3719
+
3720
+ /** @returns {StoreInfo} */
1609
3721
  static StoreInfo() {
1610
3722
  return Joi.object({
1611
3723
  name: Joi.string().allow(""),
@@ -1613,17 +3725,23 @@ class CartModel {
1613
3725
  uid: Joi.number(),
1614
3726
  });
1615
3727
  }
3728
+
3729
+ /** @returns {SuccessMessage} */
1616
3730
  static SuccessMessage() {
1617
3731
  return Joi.object({
1618
3732
  message: Joi.string().allow(""),
1619
3733
  success: Joi.boolean(),
1620
3734
  });
1621
3735
  }
3736
+
3737
+ /** @returns {Tags} */
1622
3738
  static Tags() {
1623
3739
  return Joi.object({
1624
3740
  tags: Joi.any(),
1625
3741
  });
1626
3742
  }
3743
+
3744
+ /** @returns {UpdateAddressResponse} */
1627
3745
  static UpdateAddressResponse() {
1628
3746
  return Joi.object({
1629
3747
  id: Joi.string().allow(""),
@@ -1632,13 +3750,17 @@ class CartModel {
1632
3750
  success: Joi.boolean(),
1633
3751
  });
1634
3752
  }
3753
+
3754
+ /** @returns {UpdateCartDetailResponse} */
1635
3755
  static UpdateCartDetailResponse() {
1636
3756
  return Joi.object({
1637
- cart: CartModel.CartDetailResponse(),
3757
+ cart: CartPlatformModel.CartDetailResponse(),
1638
3758
  message: Joi.string().allow(""),
1639
3759
  success: Joi.boolean(),
1640
3760
  });
1641
3761
  }
3762
+
3763
+ /** @returns {UpdateCartPaymentRequest} */
1642
3764
  static UpdateCartPaymentRequest() {
1643
3765
  return Joi.object({
1644
3766
  address_id: Joi.string().allow(""),
@@ -1649,6 +3771,8 @@ class CartModel {
1649
3771
  payment_mode: Joi.string().allow(""),
1650
3772
  });
1651
3773
  }
3774
+
3775
+ /** @returns {UpdateCartPaymentRequestV2} */
1652
3776
  static UpdateCartPaymentRequestV2() {
1653
3777
  return Joi.object({
1654
3778
  address_id: Joi.string().allow(""),
@@ -1656,16 +3780,20 @@ class CartModel {
1656
3780
  id: Joi.string().allow(""),
1657
3781
  merchant_code: Joi.string().allow(""),
1658
3782
  payment_identifier: Joi.string().allow("").allow(null),
1659
- payment_methods: Joi.array().items(CartModel.PaymentMethod()),
3783
+ payment_methods: Joi.array().items(CartPlatformModel.PaymentMethod()),
1660
3784
  payment_mode: Joi.string().allow(""),
1661
3785
  });
1662
3786
  }
3787
+
3788
+ /** @returns {UpdateCartRequest} */
1663
3789
  static UpdateCartRequest() {
1664
3790
  return Joi.object({
1665
- items: Joi.array().items(CartModel.UpdateProductCart()),
3791
+ items: Joi.array().items(CartPlatformModel.UpdateProductCart()),
1666
3792
  operation: Joi.string().allow("").required(),
1667
3793
  });
1668
3794
  }
3795
+
3796
+ /** @returns {UpdateCartShipmentItem} */
1669
3797
  static UpdateCartShipmentItem() {
1670
3798
  return Joi.object({
1671
3799
  article_uid: Joi.string().allow("").required(),
@@ -1673,19 +3801,23 @@ class CartModel {
1673
3801
  shipment_type: Joi.string().allow("").required(),
1674
3802
  });
1675
3803
  }
3804
+
3805
+ /** @returns {UpdateCartShipmentRequest} */
1676
3806
  static UpdateCartShipmentRequest() {
1677
3807
  return Joi.object({
1678
3808
  shipments: Joi.array()
1679
- .items(CartModel.UpdateCartShipmentItem())
3809
+ .items(CartPlatformModel.UpdateCartShipmentItem())
1680
3810
  .required(),
1681
3811
  });
1682
3812
  }
3813
+
3814
+ /** @returns {UpdateProductCart} */
1683
3815
  static UpdateProductCart() {
1684
3816
  return Joi.object({
1685
3817
  _custom_json: Joi.any(),
1686
3818
  article_id: Joi.string().allow(""),
1687
3819
  extra_meta: Joi.any(),
1688
- identifiers: CartModel.CartProductIdentifer().required(),
3820
+ identifiers: CartPlatformModel.CartProductIdentifer().required(),
1689
3821
  item_id: Joi.number(),
1690
3822
  item_index: Joi.number(),
1691
3823
  item_size: Joi.string().allow(""),
@@ -1694,35 +3826,43 @@ class CartModel {
1694
3826
  quantity: Joi.number(),
1695
3827
  });
1696
3828
  }
3829
+
3830
+ /** @returns {UpdateUserCartMapping} */
1697
3831
  static UpdateUserCartMapping() {
1698
3832
  return Joi.object({
1699
3833
  user_id: Joi.string().allow("").required(),
1700
3834
  });
1701
3835
  }
3836
+
3837
+ /** @returns {UserCartMappingResponse} */
1702
3838
  static UserCartMappingResponse() {
1703
3839
  return Joi.object({
1704
- applied_promo_details: Joi.array().items(CartModel.AppliedPromotion()),
1705
- breakup_values: CartModel.CartBreakup(),
3840
+ applied_promo_details: Joi.array().items(
3841
+ CartPlatformModel.AppliedPromotion()
3842
+ ),
3843
+ breakup_values: CartPlatformModel.CartBreakup(),
1706
3844
  buy_now: Joi.boolean(),
1707
3845
  checkout_mode: Joi.string().allow(""),
1708
3846
  comment: Joi.string().allow(""),
1709
3847
  coupon_text: Joi.string().allow(""),
1710
- currency: CartModel.CartCurrency(),
3848
+ currency: CartPlatformModel.CartCurrency(),
1711
3849
  delivery_charge_info: Joi.string().allow(""),
1712
- delivery_promise: CartModel.ShipmentPromise(),
3850
+ delivery_promise: CartPlatformModel.ShipmentPromise(),
1713
3851
  gstin: Joi.string().allow(""),
1714
3852
  id: Joi.string().allow(""),
1715
3853
  is_valid: Joi.boolean(),
1716
- items: Joi.array().items(CartModel.CartProductInfo()),
3854
+ items: Joi.array().items(CartPlatformModel.CartProductInfo()),
1717
3855
  last_modified: Joi.string().allow(""),
1718
3856
  message: Joi.string().allow(""),
1719
3857
  pan_config: Joi.any(),
1720
3858
  pan_no: Joi.string().allow(""),
1721
- payment_selection_lock: CartModel.PaymentSelectionLock(),
3859
+ payment_selection_lock: CartPlatformModel.PaymentSelectionLock(),
1722
3860
  restrict_checkout: Joi.boolean(),
1723
- user: CartModel.UserInfo(),
3861
+ user: CartPlatformModel.UserInfo(),
1724
3862
  });
1725
3863
  }
3864
+
3865
+ /** @returns {UserInfo} */
1726
3866
  static UserInfo() {
1727
3867
  return Joi.object({
1728
3868
  _id: Joi.string().allow(""),
@@ -1736,12 +3876,16 @@ class CartModel {
1736
3876
  uid: Joi.string().allow(""),
1737
3877
  });
1738
3878
  }
3879
+
3880
+ /** @returns {UserRegistered} */
1739
3881
  static UserRegistered() {
1740
3882
  return Joi.object({
1741
3883
  end: Joi.string().allow("").allow(null),
1742
3884
  start: Joi.string().allow("").allow(null),
1743
3885
  });
1744
3886
  }
3887
+
3888
+ /** @returns {UsesRemaining} */
1745
3889
  static UsesRemaining() {
1746
3890
  return Joi.object({
1747
3891
  app: Joi.number(),
@@ -1749,24 +3893,32 @@ class CartModel {
1749
3893
  user: Joi.number(),
1750
3894
  });
1751
3895
  }
3896
+
3897
+ /** @returns {UsesRemaining1} */
1752
3898
  static UsesRemaining1() {
1753
3899
  return Joi.object({
1754
3900
  total: Joi.number(),
1755
3901
  user: Joi.number(),
1756
3902
  });
1757
3903
  }
3904
+
3905
+ /** @returns {UsesRestriction} */
1758
3906
  static UsesRestriction() {
1759
3907
  return Joi.object({
1760
- maximum: CartModel.UsesRemaining(),
1761
- remaining: CartModel.UsesRemaining(),
3908
+ maximum: CartPlatformModel.UsesRemaining(),
3909
+ remaining: CartPlatformModel.UsesRemaining(),
1762
3910
  });
1763
3911
  }
3912
+
3913
+ /** @returns {UsesRestriction1} */
1764
3914
  static UsesRestriction1() {
1765
3915
  return Joi.object({
1766
- maximum: CartModel.UsesRemaining1(),
1767
- remaining: CartModel.UsesRemaining1(),
3916
+ maximum: CartPlatformModel.UsesRemaining1(),
3917
+ remaining: CartPlatformModel.UsesRemaining1(),
1768
3918
  });
1769
3919
  }
3920
+
3921
+ /** @returns {Validation} */
1770
3922
  static Validation() {
1771
3923
  return Joi.object({
1772
3924
  anonymous: Joi.boolean(),
@@ -1774,11 +3926,15 @@ class CartModel {
1774
3926
  user_registered_after: Joi.string().allow("").allow(null),
1775
3927
  });
1776
3928
  }
3929
+
3930
+ /** @returns {Validity} */
1777
3931
  static Validity() {
1778
3932
  return Joi.object({
1779
3933
  priority: Joi.number(),
1780
3934
  });
1781
3935
  }
3936
+
3937
+ /** @returns {Visibility} */
1782
3938
  static Visibility() {
1783
3939
  return Joi.object({
1784
3940
  coupon_list: Joi.boolean().required(),
@@ -1786,4 +3942,4 @@ class CartModel {
1786
3942
  });
1787
3943
  }
1788
3944
  }
1789
- module.exports = CartModel;
3945
+ module.exports = CartPlatformModel;