@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,52 +1,811 @@
1
1
  const Joi = require("joi");
2
2
 
3
- class UserModel {
3
+ /**
4
+ * @typedef Accountkit
5
+ * @property {string} [app_id]
6
+ */
7
+
8
+ /**
9
+ * @typedef ArchiveUserRequestSchema
10
+ * @property {string} [user_id]
11
+ */
12
+
13
+ /**
14
+ * @typedef ArchiveUserSuccess
15
+ * @property {boolean} [success]
16
+ */
17
+
18
+ /**
19
+ * @typedef AuthenticationApiErrorSchema
20
+ * @property {string} [message]
21
+ */
22
+
23
+ /**
24
+ * @typedef AuthenticationInternalServerErrorSchema
25
+ * @property {string} [message]
26
+ */
27
+
28
+ /**
29
+ * @typedef AuthSuccess
30
+ * @property {string} [register_token]
31
+ * @property {UserSchema} [user]
32
+ * @property {boolean} [user_exists]
33
+ */
34
+
35
+ /**
36
+ * @typedef AuthSuccessUser
37
+ * @property {boolean} [active]
38
+ * @property {AuthSuccessUserDebug} [debug]
39
+ * @property {AuthSuccessUserEmails} [emails]
40
+ * @property {string} [first_name]
41
+ * @property {string} [last_name]
42
+ */
43
+
44
+ /**
45
+ * @typedef AuthSuccessUserDebug
46
+ * @property {string} [platform]
47
+ */
48
+
49
+ /**
50
+ * @typedef AuthSuccessUserEmails
51
+ * @property {boolean} [active]
52
+ * @property {string} [email]
53
+ * @property {boolean} [primary]
54
+ * @property {boolean} [verified]
55
+ */
56
+
57
+ /**
58
+ * @typedef BlockUserRequestSchema
59
+ * @property {string} [reason]
60
+ * @property {boolean} [status]
61
+ * @property {string[]} [user_id]
62
+ */
63
+
64
+ /**
65
+ * @typedef BlockUserSuccess
66
+ * @property {boolean} [success]
67
+ */
68
+
69
+ /**
70
+ * @typedef CodeRequestBodySchema
71
+ * @property {string} [code]
72
+ */
73
+
74
+ /**
75
+ * @typedef CreateUserGroupSchema
76
+ * @property {string} description
77
+ * @property {string} file_url
78
+ * @property {string} name
79
+ */
80
+
81
+ /**
82
+ * @typedef CreateUserRequestSchema
83
+ * @property {string} [email]
84
+ * @property {string} [first_name]
85
+ * @property {string} [gender]
86
+ * @property {string} [last_name]
87
+ * @property {Object} [meta]
88
+ * @property {string} phone_number
89
+ * @property {string} username
90
+ */
91
+
92
+ /**
93
+ * @typedef CreateUserResponseSchema
94
+ * @property {UserSchema} [user]
95
+ */
96
+
97
+ /**
98
+ * @typedef CreateUserSessionRequestSchema
99
+ * @property {string} [domain]
100
+ * @property {number} [max_age]
101
+ * @property {string} [user_id]
102
+ */
103
+
104
+ /**
105
+ * @typedef CreateUserSessionResponseSchema
106
+ * @property {Object} [cookie]
107
+ * @property {string} [domain]
108
+ * @property {boolean} [http_only]
109
+ * @property {number} [max_age]
110
+ * @property {boolean} [secure]
111
+ */
112
+
113
+ /**
114
+ * @typedef CustomerListResponseSchema
115
+ * @property {UserSchema[]} [items]
116
+ * @property {PaginationSchema} [page]
117
+ */
118
+
119
+ /**
120
+ * @typedef DeleteAccountConsent
121
+ * @property {string} [consent_text]
122
+ */
123
+
124
+ /**
125
+ * @typedef DeleteAccountReasons
126
+ * @property {string} [reason_id]
127
+ * @property {string} [reason_text]
128
+ * @property {boolean} [show_text_area]
129
+ */
130
+
131
+ /**
132
+ * @typedef DeleteApplicationUserRequestSchema
133
+ * @property {string} [otp]
134
+ * @property {string} [reason]
135
+ * @property {string} [reason_id]
136
+ * @property {string} [request_id]
137
+ * @property {string} [user_id]
138
+ */
139
+
140
+ /**
141
+ * @typedef DeleteUserSuccess
142
+ * @property {boolean} [success]
143
+ */
144
+
145
+ /**
146
+ * @typedef EditEmailRequestSchema
147
+ * @property {string} [email]
148
+ */
149
+
150
+ /**
151
+ * @typedef EditMobileRequestSchema
152
+ * @property {string} [country_code]
153
+ * @property {string} [phone]
154
+ */
155
+
156
+ /**
157
+ * @typedef EditProfileMobileSchema
158
+ * @property {string} [country_code]
159
+ * @property {string} [phone]
160
+ */
161
+
162
+ /**
163
+ * @typedef EditProfileRequestSchema
164
+ * @property {string} [android_hash]
165
+ * @property {string} [country_code]
166
+ * @property {string} [dob]
167
+ * @property {string} [email]
168
+ * @property {string} [first_name]
169
+ * @property {string} [gender]
170
+ * @property {string} [last_name]
171
+ * @property {EditProfileMobileSchema} [mobile]
172
+ * @property {string} [profile_pic_url]
173
+ * @property {string} [register_token]
174
+ * @property {string} [sender]
175
+ */
176
+
177
+ /**
178
+ * @typedef Email
179
+ * @property {boolean} [active]
180
+ * @property {string} [email]
181
+ * @property {boolean} [primary]
182
+ * @property {boolean} [verified]
183
+ */
184
+
185
+ /**
186
+ * @typedef EmailOtpSuccess
187
+ * @property {boolean} [success]
188
+ */
189
+
190
+ /**
191
+ * @typedef Facebook
192
+ * @property {string} [app_id]
193
+ */
194
+
195
+ /**
196
+ * @typedef FlashCard
197
+ * @property {string} [background_color]
198
+ * @property {string} [text]
199
+ * @property {string} [text_color]
200
+ */
201
+
202
+ /**
203
+ * @typedef ForgotPasswordRequestSchema
204
+ * @property {string} [code]
205
+ * @property {string} [password]
206
+ */
207
+
208
+ /**
209
+ * @typedef FormRegisterRequestSchema
210
+ * @property {string} [email]
211
+ * @property {string} [first_name]
212
+ * @property {string} [gender]
213
+ * @property {string} [last_name]
214
+ * @property {string} [password]
215
+ * @property {FormRegisterRequestSchemaPhone} [phone]
216
+ * @property {string} [register_token]
217
+ */
218
+
219
+ /**
220
+ * @typedef FormRegisterRequestSchemaPhone
221
+ * @property {string} [country_code]
222
+ * @property {string} [mobile]
223
+ */
224
+
225
+ /**
226
+ * @typedef Google
227
+ * @property {string} [app_id]
228
+ */
229
+
230
+ /**
231
+ * @typedef HasPasswordSuccess
232
+ * @property {boolean} [result]
233
+ */
234
+
235
+ /**
236
+ * @typedef Login
237
+ * @property {boolean} [otp]
238
+ * @property {boolean} [password]
239
+ */
240
+
241
+ /**
242
+ * @typedef LoginSuccess
243
+ * @property {string} [register_token]
244
+ * @property {string} [request_id]
245
+ * @property {UserSchema} [user]
246
+ */
247
+
248
+ /**
249
+ * @typedef LogoutSuccess
250
+ * @property {boolean} [logout]
251
+ */
252
+
253
+ /**
254
+ * @typedef LookAndFeel
255
+ * @property {string} [background_color]
256
+ * @property {string} [card_position]
257
+ */
258
+
259
+ /**
260
+ * @typedef MetaSchema
261
+ * @property {boolean} [fynd_default]
262
+ */
263
+
264
+ /**
265
+ * @typedef NotFoundSchema
266
+ * @property {string} [message]
267
+ */
268
+
269
+ /**
270
+ * @typedef OAuthRequestAppleSchema
271
+ * @property {OAuthRequestAppleSchemaOauth} [oauth]
272
+ * @property {OAuthRequestAppleSchemaProfile} [profile]
273
+ * @property {string} [user_identifier]
274
+ */
275
+
276
+ /**
277
+ * @typedef OAuthRequestAppleSchemaOauth
278
+ * @property {string} [identity_token]
279
+ */
280
+
281
+ /**
282
+ * @typedef OAuthRequestAppleSchemaProfile
283
+ * @property {string} [first_name]
284
+ * @property {string} [full_name]
285
+ * @property {string} [last_name]
286
+ */
287
+
288
+ /**
289
+ * @typedef OAuthRequestSchema
290
+ * @property {boolean} [is_signed_in]
291
+ * @property {OAuthRequestSchemaOauth2} [oauth2]
292
+ * @property {OAuthRequestSchemaProfile} [profile]
293
+ */
294
+
295
+ /**
296
+ * @typedef OAuthRequestSchemaOauth2
297
+ * @property {string} [access_token]
298
+ * @property {number} [expiry]
299
+ * @property {string} [refresh_token]
300
+ */
301
+
302
+ /**
303
+ * @typedef OAuthRequestSchemaProfile
304
+ * @property {string} [email]
305
+ * @property {string} [first_name]
306
+ * @property {string} [full_name]
307
+ * @property {string} [id]
308
+ * @property {string} [image]
309
+ * @property {string} [last_name]
310
+ */
311
+
312
+ /**
313
+ * @typedef OtpSuccess
314
+ * @property {string} [country_code]
315
+ * @property {string} [message]
316
+ * @property {string} [mobile]
317
+ * @property {string} [register_token]
318
+ * @property {string} [request_id]
319
+ * @property {number} [resend_timer]
320
+ * @property {string} [resend_token]
321
+ * @property {boolean} [success]
322
+ */
323
+
324
+ /**
325
+ * @typedef PaginationSchema
326
+ * @property {number} [current]
327
+ * @property {boolean} [has_next]
328
+ * @property {number} [item_total]
329
+ * @property {number} [size]
330
+ * @property {string} [type]
331
+ */
332
+
333
+ /**
334
+ * @typedef PasswordLoginRequestSchema
335
+ * @property {string} [captcha_code]
336
+ * @property {string} [password]
337
+ * @property {string} [username]
338
+ */
339
+
340
+ /**
341
+ * @typedef PhoneNumber
342
+ * @property {boolean} [active]
343
+ * @property {number} [country_code]
344
+ * @property {string} [phone]
345
+ * @property {boolean} [primary]
346
+ * @property {boolean} [verified]
347
+ */
348
+
349
+ /**
350
+ * @typedef PlatformEmail
351
+ * @property {boolean} [is_required]
352
+ * @property {string} [level]
353
+ */
354
+
355
+ /**
356
+ * @typedef PlatformMobile
357
+ * @property {boolean} [is_required]
358
+ * @property {string} [level]
359
+ */
360
+
361
+ /**
362
+ * @typedef PlatformSchema
363
+ * @property {string} [_id]
364
+ * @property {boolean} [active]
365
+ * @property {string} [created_at]
366
+ * @property {Object} [delete_account_consent]
367
+ * @property {number} [delete_account_day]
368
+ * @property {DeleteAccountReasons[]} [delete_account_reasons]
369
+ * @property {string} [desktop_image]
370
+ * @property {string} [display]
371
+ * @property {FlashCard} [flash_card]
372
+ * @property {boolean} [forgot_password]
373
+ * @property {Login} [login]
374
+ * @property {LookAndFeel} [look_and_feel]
375
+ * @property {MetaSchema} [meta]
376
+ * @property {string} [mobile_image]
377
+ * @property {string} [name]
378
+ * @property {boolean} [register]
379
+ * @property {RegisterRequiredFields} [register_required_fields]
380
+ * @property {RequiredFields} [required_fields]
381
+ * @property {Object} [session_config]
382
+ * @property {boolean} [skip_captcha]
383
+ * @property {boolean} [skip_login]
384
+ * @property {Social} [social]
385
+ * @property {SocialTokens} [social_tokens]
386
+ * @property {string} [subtext]
387
+ * @property {string} [updated_at]
388
+ */
389
+
390
+ /**
391
+ * @typedef ProfileEditSuccess
392
+ * @property {string} [country_code]
393
+ * @property {string} [email]
394
+ * @property {string} [message]
395
+ * @property {string} [mobile]
396
+ * @property {string} [register_token]
397
+ * @property {string} [request_id]
398
+ * @property {string} [resend_email_token]
399
+ * @property {number} [resend_timer]
400
+ * @property {string} [resend_token]
401
+ * @property {boolean} [success]
402
+ * @property {UserSchema} [user]
403
+ * @property {boolean} [user_exists]
404
+ * @property {boolean} [verify_email_link]
405
+ * @property {boolean} [verify_email_otp]
406
+ * @property {boolean} [verify_mobile_otp]
407
+ */
408
+
409
+ /**
410
+ * @typedef ProfileEditSuccessSchema
411
+ * @property {string} [email]
412
+ * @property {string} [register_token]
413
+ * @property {string} [user]
414
+ * @property {boolean} [user_exists]
415
+ * @property {boolean} [verify_email_link]
416
+ * @property {boolean} [verify_email_otp]
417
+ * @property {boolean} [verify_mobile_otp]
418
+ */
419
+
420
+ /**
421
+ * @typedef RegisterFormSuccess
422
+ * @property {string} [country_code]
423
+ * @property {string} [email]
424
+ * @property {string} [message]
425
+ * @property {string} [mobile]
426
+ * @property {string} [register_token]
427
+ * @property {string} [request_id]
428
+ * @property {string} [resend_email_token]
429
+ * @property {number} [resend_timer]
430
+ * @property {string} [resend_token]
431
+ * @property {boolean} [success]
432
+ * @property {boolean} [user_exists]
433
+ * @property {boolean} [verify_email_otp]
434
+ * @property {boolean} [verify_mobile_otp]
435
+ */
436
+
437
+ /**
438
+ * @typedef RegisterRequiredFields
439
+ * @property {RegisterRequiredFieldsEmail} [email]
440
+ * @property {RegisterRequiredFieldsMobile} [mobile]
441
+ */
442
+
443
+ /**
444
+ * @typedef RegisterRequiredFieldsEmail
445
+ * @property {boolean} [is_required]
446
+ * @property {string} [level]
447
+ */
448
+
449
+ /**
450
+ * @typedef RegisterRequiredFieldsMobile
451
+ * @property {boolean} [is_required]
452
+ * @property {string} [level]
453
+ */
454
+
455
+ /**
456
+ * @typedef RequiredFields
457
+ * @property {PlatformEmail} [email]
458
+ * @property {PlatformMobile} [mobile]
459
+ */
460
+
461
+ /**
462
+ * @typedef ResetPasswordSuccess
463
+ * @property {string} [status]
464
+ */
465
+
466
+ /**
467
+ * @typedef SendEmailOtpRequestSchema
468
+ * @property {string} [action]
469
+ * @property {string} [email]
470
+ * @property {string} [register_token]
471
+ * @property {string} [token]
472
+ */
473
+
474
+ /**
475
+ * @typedef SendEmailVerifyLinkSuccess
476
+ * @property {boolean} [verify_email_link]
477
+ */
478
+
479
+ /**
480
+ * @typedef SendMobileOtpRequestSchema
481
+ * @property {string} [action]
482
+ * @property {string} [android_hash]
483
+ * @property {string} [captcha_code]
484
+ * @property {string} [country_code]
485
+ * @property {string} [force]
486
+ * @property {string} [mobile]
487
+ * @property {string} [token]
488
+ */
489
+
490
+ /**
491
+ * @typedef SendMobileVerifyLinkSuccess
492
+ * @property {boolean} [verify_mobile_link]
493
+ */
494
+
495
+ /**
496
+ * @typedef SendOtpRequestSchema
497
+ * @property {string} [android_hash]
498
+ * @property {string} [captcha_code]
499
+ * @property {string} [country_code]
500
+ * @property {string} [mobile]
501
+ */
502
+
503
+ /**
504
+ * @typedef SendOtpResponse
505
+ * @property {string} [country_code]
506
+ * @property {string} [email]
507
+ * @property {string} [message]
508
+ * @property {string} [mobile]
509
+ * @property {string} [register_token]
510
+ * @property {string} [request_id]
511
+ * @property {string} [resend_email_token]
512
+ * @property {number} [resend_timer]
513
+ * @property {string} [resend_token]
514
+ * @property {boolean} [success]
515
+ * @property {boolean} [user_exists]
516
+ * @property {boolean} [verify_email_otp]
517
+ * @property {boolean} [verify_mobile_otp]
518
+ */
519
+
520
+ /**
521
+ * @typedef SendResetPasswordEmailRequestSchema
522
+ * @property {string} [captcha_code]
523
+ * @property {string} [email]
524
+ */
525
+
526
+ /**
527
+ * @typedef SendResetPasswordMobileRequestSchema
528
+ * @property {string} [captcha_code]
529
+ * @property {string} [country_code]
530
+ * @property {string} [mobile]
531
+ */
532
+
533
+ /**
534
+ * @typedef SendVerificationLinkMobileRequestSchema
535
+ * @property {boolean} [active]
536
+ * @property {string} [country_code]
537
+ * @property {string} [phone]
538
+ * @property {boolean} [primary]
539
+ * @property {boolean} [verified]
540
+ */
541
+
542
+ /**
543
+ * @typedef SessionDeleteResponseSchema
544
+ * @property {string[]} [items]
545
+ */
546
+
547
+ /**
548
+ * @typedef SessionExpiry
549
+ * @property {number} [duration]
550
+ * @property {boolean} [is_rolling]
551
+ * @property {string} [type]
552
+ */
553
+
554
+ /**
555
+ * @typedef SessionListResponseInfo
556
+ * @property {string} [domain]
557
+ * @property {string} [expire_in]
558
+ * @property {string} [ip]
559
+ * @property {string} [session_id]
560
+ * @property {string} [user_agent]
561
+ */
562
+
563
+ /**
564
+ * @typedef SessionListResponseSchema
565
+ * @property {SessionListResponseInfo[]} [items]
566
+ */
567
+
568
+ /**
569
+ * @typedef SessionListSuccess
570
+ * @property {string[]} [sessions]
571
+ */
572
+
573
+ /**
574
+ * @typedef Social
575
+ * @property {boolean} [account_kit]
576
+ * @property {boolean} [apple]
577
+ * @property {boolean} [facebook]
578
+ * @property {boolean} [google]
579
+ */
580
+
581
+ /**
582
+ * @typedef SocialTokens
583
+ * @property {Accountkit} [account_kit]
584
+ * @property {Facebook} [facebook]
585
+ * @property {Google} [google]
586
+ */
587
+
588
+ /**
589
+ * @typedef TokenRequestBodySchema
590
+ * @property {string} [token]
591
+ */
592
+
593
+ /**
594
+ * @typedef UnauthenticatedSchema
595
+ * @property {boolean} [authenticated]
596
+ */
597
+
598
+ /**
599
+ * @typedef UnauthorizedSchema
600
+ * @property {string} [message]
601
+ */
602
+
603
+ /**
604
+ * @typedef UnDeleteUserRequestSchema
605
+ * @property {string} [reason]
606
+ * @property {string} [reason_id]
607
+ * @property {string} [user_id]
608
+ */
609
+
610
+ /**
611
+ * @typedef UnDeleteUserSuccess
612
+ * @property {boolean} [success]
613
+ */
614
+
615
+ /**
616
+ * @typedef UpdatePasswordRequestSchema
617
+ * @property {string} [new_password]
618
+ * @property {string} [old_password]
619
+ */
620
+
621
+ /**
622
+ * @typedef UpdateUserGroupSchema
623
+ * @property {string} [description]
624
+ * @property {string} [file_url]
625
+ * @property {string} [name]
626
+ */
627
+
628
+ /**
629
+ * @typedef UpdateUserRequestSchema
630
+ * @property {UserEmails[]} [emails]
631
+ * @property {string} [external_id]
632
+ * @property {string} [first_name]
633
+ * @property {string} [gender]
634
+ * @property {string} [last_name]
635
+ * @property {Object} [meta]
636
+ * @property {UserPhoneNumbers[]} [phone_numbers]
637
+ */
638
+
639
+ /**
640
+ * @typedef UserEmails
641
+ * @property {boolean} [active]
642
+ * @property {string} [email]
643
+ * @property {boolean} [primary]
644
+ * @property {boolean} [verified]
645
+ */
646
+
647
+ /**
648
+ * @typedef UserGroupListResponseSchema
649
+ * @property {UserGroupResponseSchema[]} [items]
650
+ * @property {PaginationSchema} [page]
651
+ */
652
+
653
+ /**
654
+ * @typedef UserGroupResponseSchema
655
+ * @property {number} [__v]
656
+ * @property {string} [_id]
657
+ * @property {string} [application_id]
658
+ * @property {string} [created_at]
659
+ * @property {string} [description]
660
+ * @property {string} [file_url]
661
+ * @property {string} [modified_at]
662
+ * @property {string} [name]
663
+ * @property {string} [status]
664
+ * @property {number} [uid]
665
+ */
666
+
667
+ /**
668
+ * @typedef UserObjectSchema
669
+ * @property {UserSchema} [user]
670
+ */
671
+
672
+ /**
673
+ * @typedef UserPhoneNumbers
674
+ * @property {boolean} [active]
675
+ * @property {string} [country_code]
676
+ * @property {string} [phone]
677
+ * @property {boolean} [primary]
678
+ * @property {boolean} [verified]
679
+ */
680
+
681
+ /**
682
+ * @typedef UserSchema
683
+ * @property {string} [_id]
684
+ * @property {string} [account_type]
685
+ * @property {boolean} [active]
686
+ * @property {string} [application_id]
687
+ * @property {string} [created_at]
688
+ * @property {string} [dob]
689
+ * @property {Email[]} [emails]
690
+ * @property {string} [first_name]
691
+ * @property {string} [gender]
692
+ * @property {string} [last_name]
693
+ * @property {Object} [meta]
694
+ * @property {PhoneNumber[]} [phone_numbers]
695
+ * @property {string} [profile_pic_url]
696
+ * @property {string} [updated_at]
697
+ * @property {string} [user_id]
698
+ * @property {string} [username]
699
+ */
700
+
701
+ /**
702
+ * @typedef UserSearchResponseSchema
703
+ * @property {UserSchema[]} [users]
704
+ */
705
+
706
+ /**
707
+ * @typedef VerifyEmailOtpRequestSchema
708
+ * @property {string} [action]
709
+ * @property {string} [email]
710
+ * @property {string} [otp]
711
+ * @property {string} [register_token]
712
+ */
713
+
714
+ /**
715
+ * @typedef VerifyEmailOTPSuccess
716
+ * @property {UserSchema} [user]
717
+ * @property {boolean} [verify_email_link]
718
+ */
719
+
720
+ /**
721
+ * @typedef VerifyEmailSuccess
722
+ * @property {string} [message]
723
+ */
724
+
725
+ /**
726
+ * @typedef VerifyMobileOTPSuccess
727
+ * @property {UserSchema} [user]
728
+ * @property {boolean} [verify_mobile_link]
729
+ */
730
+
731
+ /**
732
+ * @typedef VerifyOtpRequestSchema
733
+ * @property {string} [otp]
734
+ * @property {string} [register_token]
735
+ * @property {string} [request_id]
736
+ */
737
+
738
+ /**
739
+ * @typedef VerifyOtpSuccess
740
+ * @property {string} [register_token]
741
+ * @property {UserSchema} [user]
742
+ * @property {boolean} [user_exists]
743
+ */
744
+
745
+ class UserPlatformModel {
746
+ /** @returns {Accountkit} */
4
747
  static Accountkit() {
5
748
  return Joi.object({
6
749
  app_id: Joi.string().allow(""),
7
750
  });
8
751
  }
752
+
753
+ /** @returns {ArchiveUserRequestSchema} */
9
754
  static ArchiveUserRequestSchema() {
10
755
  return Joi.object({
11
756
  user_id: Joi.string().allow(""),
12
757
  });
13
758
  }
759
+
760
+ /** @returns {ArchiveUserSuccess} */
14
761
  static ArchiveUserSuccess() {
15
762
  return Joi.object({
16
763
  success: Joi.boolean(),
17
764
  });
18
765
  }
766
+
767
+ /** @returns {AuthenticationApiErrorSchema} */
19
768
  static AuthenticationApiErrorSchema() {
20
769
  return Joi.object({
21
770
  message: Joi.string().allow(""),
22
771
  });
23
772
  }
773
+
774
+ /** @returns {AuthenticationInternalServerErrorSchema} */
24
775
  static AuthenticationInternalServerErrorSchema() {
25
776
  return Joi.object({
26
777
  message: Joi.string().allow(""),
27
778
  });
28
779
  }
780
+
781
+ /** @returns {AuthSuccess} */
29
782
  static AuthSuccess() {
30
783
  return Joi.object({
31
784
  register_token: Joi.string().allow(""),
32
- user: UserModel.UserSchema(),
785
+ user: UserPlatformModel.UserSchema(),
33
786
  user_exists: Joi.boolean(),
34
787
  });
35
788
  }
789
+
790
+ /** @returns {AuthSuccessUser} */
36
791
  static AuthSuccessUser() {
37
792
  return Joi.object({
38
793
  active: Joi.boolean(),
39
- debug: UserModel.AuthSuccessUserDebug(),
40
- emails: UserModel.AuthSuccessUserEmails(),
794
+ debug: UserPlatformModel.AuthSuccessUserDebug(),
795
+ emails: UserPlatformModel.AuthSuccessUserEmails(),
41
796
  first_name: Joi.string().allow(""),
42
797
  last_name: Joi.string().allow(""),
43
798
  });
44
799
  }
800
+
801
+ /** @returns {AuthSuccessUserDebug} */
45
802
  static AuthSuccessUserDebug() {
46
803
  return Joi.object({
47
804
  platform: Joi.string().allow(""),
48
805
  });
49
806
  }
807
+
808
+ /** @returns {AuthSuccessUserEmails} */
50
809
  static AuthSuccessUserEmails() {
51
810
  return Joi.object({
52
811
  active: Joi.boolean(),
@@ -55,6 +814,8 @@ class UserModel {
55
814
  verified: Joi.boolean(),
56
815
  });
57
816
  }
817
+
818
+ /** @returns {BlockUserRequestSchema} */
58
819
  static BlockUserRequestSchema() {
59
820
  return Joi.object({
60
821
  reason: Joi.string().allow(""),
@@ -62,16 +823,22 @@ class UserModel {
62
823
  user_id: Joi.array().items(Joi.string().allow("")),
63
824
  });
64
825
  }
826
+
827
+ /** @returns {BlockUserSuccess} */
65
828
  static BlockUserSuccess() {
66
829
  return Joi.object({
67
830
  success: Joi.boolean(),
68
831
  });
69
832
  }
833
+
834
+ /** @returns {CodeRequestBodySchema} */
70
835
  static CodeRequestBodySchema() {
71
836
  return Joi.object({
72
837
  code: Joi.string().allow(""),
73
838
  });
74
839
  }
840
+
841
+ /** @returns {CreateUserGroupSchema} */
75
842
  static CreateUserGroupSchema() {
76
843
  return Joi.object({
77
844
  description: Joi.string().allow("").required(),
@@ -79,6 +846,8 @@ class UserModel {
79
846
  name: Joi.string().allow("").required(),
80
847
  });
81
848
  }
849
+
850
+ /** @returns {CreateUserRequestSchema} */
82
851
  static CreateUserRequestSchema() {
83
852
  return Joi.object({
84
853
  email: Joi.string().allow(""),
@@ -90,11 +859,15 @@ class UserModel {
90
859
  username: Joi.string().allow("").required(),
91
860
  });
92
861
  }
862
+
863
+ /** @returns {CreateUserResponseSchema} */
93
864
  static CreateUserResponseSchema() {
94
865
  return Joi.object({
95
- user: UserModel.UserSchema(),
866
+ user: UserPlatformModel.UserSchema(),
96
867
  });
97
868
  }
869
+
870
+ /** @returns {CreateUserSessionRequestSchema} */
98
871
  static CreateUserSessionRequestSchema() {
99
872
  return Joi.object({
100
873
  domain: Joi.string().allow(""),
@@ -102,6 +875,8 @@ class UserModel {
102
875
  user_id: Joi.string().allow(""),
103
876
  });
104
877
  }
878
+
879
+ /** @returns {CreateUserSessionResponseSchema} */
105
880
  static CreateUserSessionResponseSchema() {
106
881
  return Joi.object({
107
882
  cookie: Joi.any(),
@@ -111,17 +886,23 @@ class UserModel {
111
886
  secure: Joi.boolean(),
112
887
  });
113
888
  }
889
+
890
+ /** @returns {CustomerListResponseSchema} */
114
891
  static CustomerListResponseSchema() {
115
892
  return Joi.object({
116
- items: Joi.array().items(UserModel.UserSchema()),
117
- page: UserModel.PaginationSchema(),
893
+ items: Joi.array().items(UserPlatformModel.UserSchema()),
894
+ page: UserPlatformModel.PaginationSchema(),
118
895
  });
119
896
  }
897
+
898
+ /** @returns {DeleteAccountConsent} */
120
899
  static DeleteAccountConsent() {
121
900
  return Joi.object({
122
901
  consent_text: Joi.string().allow(""),
123
902
  });
124
903
  }
904
+
905
+ /** @returns {DeleteAccountReasons} */
125
906
  static DeleteAccountReasons() {
126
907
  return Joi.object({
127
908
  reason_id: Joi.string().allow(""),
@@ -129,6 +910,8 @@ class UserModel {
129
910
  show_text_area: Joi.boolean(),
130
911
  });
131
912
  }
913
+
914
+ /** @returns {DeleteApplicationUserRequestSchema} */
132
915
  static DeleteApplicationUserRequestSchema() {
133
916
  return Joi.object({
134
917
  otp: Joi.string().allow(""),
@@ -138,28 +921,38 @@ class UserModel {
138
921
  user_id: Joi.string().allow(""),
139
922
  });
140
923
  }
924
+
925
+ /** @returns {DeleteUserSuccess} */
141
926
  static DeleteUserSuccess() {
142
927
  return Joi.object({
143
928
  success: Joi.boolean(),
144
929
  });
145
930
  }
931
+
932
+ /** @returns {EditEmailRequestSchema} */
146
933
  static EditEmailRequestSchema() {
147
934
  return Joi.object({
148
935
  email: Joi.string().allow(""),
149
936
  });
150
937
  }
938
+
939
+ /** @returns {EditMobileRequestSchema} */
151
940
  static EditMobileRequestSchema() {
152
941
  return Joi.object({
153
942
  country_code: Joi.string().allow(""),
154
943
  phone: Joi.string().allow(""),
155
944
  });
156
945
  }
946
+
947
+ /** @returns {EditProfileMobileSchema} */
157
948
  static EditProfileMobileSchema() {
158
949
  return Joi.object({
159
950
  country_code: Joi.string().allow(""),
160
951
  phone: Joi.string().allow(""),
161
952
  });
162
953
  }
954
+
955
+ /** @returns {EditProfileRequestSchema} */
163
956
  static EditProfileRequestSchema() {
164
957
  return Joi.object({
165
958
  android_hash: Joi.string().allow(""),
@@ -169,12 +962,14 @@ class UserModel {
169
962
  first_name: Joi.string().allow(""),
170
963
  gender: Joi.string().allow(""),
171
964
  last_name: Joi.string().allow(""),
172
- mobile: UserModel.EditProfileMobileSchema(),
965
+ mobile: UserPlatformModel.EditProfileMobileSchema(),
173
966
  profile_pic_url: Joi.string().allow(""),
174
967
  register_token: Joi.string().allow(""),
175
968
  sender: Joi.string().allow(""),
176
969
  });
177
970
  }
971
+
972
+ /** @returns {Email} */
178
973
  static Email() {
179
974
  return Joi.object({
180
975
  active: Joi.boolean(),
@@ -183,16 +978,22 @@ class UserModel {
183
978
  verified: Joi.boolean(),
184
979
  });
185
980
  }
981
+
982
+ /** @returns {EmailOtpSuccess} */
186
983
  static EmailOtpSuccess() {
187
984
  return Joi.object({
188
985
  success: Joi.boolean(),
189
986
  });
190
987
  }
988
+
989
+ /** @returns {Facebook} */
191
990
  static Facebook() {
192
991
  return Joi.object({
193
992
  app_id: Joi.string().allow(""),
194
993
  });
195
994
  }
995
+
996
+ /** @returns {FlashCard} */
196
997
  static FlashCard() {
197
998
  return Joi.object({
198
999
  background_color: Joi.string().allow(""),
@@ -200,12 +1001,16 @@ class UserModel {
200
1001
  text_color: Joi.string().allow(""),
201
1002
  });
202
1003
  }
1004
+
1005
+ /** @returns {ForgotPasswordRequestSchema} */
203
1006
  static ForgotPasswordRequestSchema() {
204
1007
  return Joi.object({
205
1008
  code: Joi.string().allow(""),
206
1009
  password: Joi.string().allow(""),
207
1010
  });
208
1011
  }
1012
+
1013
+ /** @returns {FormRegisterRequestSchema} */
209
1014
  static FormRegisterRequestSchema() {
210
1015
  return Joi.object({
211
1016
  email: Joi.string().allow(""),
@@ -213,72 +1018,96 @@ class UserModel {
213
1018
  gender: Joi.string().allow(""),
214
1019
  last_name: Joi.string().allow(""),
215
1020
  password: Joi.string().allow(""),
216
- phone: UserModel.FormRegisterRequestSchemaPhone(),
1021
+ phone: UserPlatformModel.FormRegisterRequestSchemaPhone(),
217
1022
  register_token: Joi.string().allow(""),
218
1023
  });
219
1024
  }
1025
+
1026
+ /** @returns {FormRegisterRequestSchemaPhone} */
220
1027
  static FormRegisterRequestSchemaPhone() {
221
1028
  return Joi.object({
222
1029
  country_code: Joi.string().allow(""),
223
1030
  mobile: Joi.string().allow(""),
224
1031
  });
225
1032
  }
1033
+
1034
+ /** @returns {Google} */
226
1035
  static Google() {
227
1036
  return Joi.object({
228
1037
  app_id: Joi.string().allow(""),
229
1038
  });
230
1039
  }
1040
+
1041
+ /** @returns {HasPasswordSuccess} */
231
1042
  static HasPasswordSuccess() {
232
1043
  return Joi.object({
233
1044
  result: Joi.boolean(),
234
1045
  });
235
1046
  }
1047
+
1048
+ /** @returns {Login} */
236
1049
  static Login() {
237
1050
  return Joi.object({
238
1051
  otp: Joi.boolean(),
239
1052
  password: Joi.boolean(),
240
1053
  });
241
1054
  }
1055
+
1056
+ /** @returns {LoginSuccess} */
242
1057
  static LoginSuccess() {
243
1058
  return Joi.object({
244
1059
  register_token: Joi.string().allow(""),
245
1060
  request_id: Joi.string().allow(""),
246
- user: UserModel.UserSchema(),
1061
+ user: UserPlatformModel.UserSchema(),
247
1062
  });
248
1063
  }
1064
+
1065
+ /** @returns {LogoutSuccess} */
249
1066
  static LogoutSuccess() {
250
1067
  return Joi.object({
251
1068
  logout: Joi.boolean(),
252
1069
  });
253
1070
  }
1071
+
1072
+ /** @returns {LookAndFeel} */
254
1073
  static LookAndFeel() {
255
1074
  return Joi.object({
256
1075
  background_color: Joi.string().allow(""),
257
1076
  card_position: Joi.string().allow(""),
258
1077
  });
259
1078
  }
1079
+
1080
+ /** @returns {MetaSchema} */
260
1081
  static MetaSchema() {
261
1082
  return Joi.object({
262
1083
  fynd_default: Joi.boolean(),
263
1084
  });
264
1085
  }
1086
+
1087
+ /** @returns {NotFoundSchema} */
265
1088
  static NotFoundSchema() {
266
1089
  return Joi.object({
267
1090
  message: Joi.string().allow(""),
268
1091
  });
269
1092
  }
1093
+
1094
+ /** @returns {OAuthRequestAppleSchema} */
270
1095
  static OAuthRequestAppleSchema() {
271
1096
  return Joi.object({
272
- oauth: UserModel.OAuthRequestAppleSchemaOauth(),
273
- profile: UserModel.OAuthRequestAppleSchemaProfile(),
1097
+ oauth: UserPlatformModel.OAuthRequestAppleSchemaOauth(),
1098
+ profile: UserPlatformModel.OAuthRequestAppleSchemaProfile(),
274
1099
  user_identifier: Joi.string().allow(""),
275
1100
  });
276
1101
  }
1102
+
1103
+ /** @returns {OAuthRequestAppleSchemaOauth} */
277
1104
  static OAuthRequestAppleSchemaOauth() {
278
1105
  return Joi.object({
279
1106
  identity_token: Joi.string().allow(""),
280
1107
  });
281
1108
  }
1109
+
1110
+ /** @returns {OAuthRequestAppleSchemaProfile} */
282
1111
  static OAuthRequestAppleSchemaProfile() {
283
1112
  return Joi.object({
284
1113
  first_name: Joi.string().allow(""),
@@ -286,13 +1115,17 @@ class UserModel {
286
1115
  last_name: Joi.string().allow(""),
287
1116
  });
288
1117
  }
1118
+
1119
+ /** @returns {OAuthRequestSchema} */
289
1120
  static OAuthRequestSchema() {
290
1121
  return Joi.object({
291
1122
  is_signed_in: Joi.boolean(),
292
- oauth2: UserModel.OAuthRequestSchemaOauth2(),
293
- profile: UserModel.OAuthRequestSchemaProfile(),
1123
+ oauth2: UserPlatformModel.OAuthRequestSchemaOauth2(),
1124
+ profile: UserPlatformModel.OAuthRequestSchemaProfile(),
294
1125
  });
295
1126
  }
1127
+
1128
+ /** @returns {OAuthRequestSchemaOauth2} */
296
1129
  static OAuthRequestSchemaOauth2() {
297
1130
  return Joi.object({
298
1131
  access_token: Joi.string().allow(""),
@@ -300,6 +1133,8 @@ class UserModel {
300
1133
  refresh_token: Joi.string().allow(""),
301
1134
  });
302
1135
  }
1136
+
1137
+ /** @returns {OAuthRequestSchemaProfile} */
303
1138
  static OAuthRequestSchemaProfile() {
304
1139
  return Joi.object({
305
1140
  email: Joi.string().allow(""),
@@ -310,6 +1145,8 @@ class UserModel {
310
1145
  last_name: Joi.string().allow(""),
311
1146
  });
312
1147
  }
1148
+
1149
+ /** @returns {OtpSuccess} */
313
1150
  static OtpSuccess() {
314
1151
  return Joi.object({
315
1152
  country_code: Joi.string().allow(""),
@@ -322,6 +1159,8 @@ class UserModel {
322
1159
  success: Joi.boolean(),
323
1160
  });
324
1161
  }
1162
+
1163
+ /** @returns {PaginationSchema} */
325
1164
  static PaginationSchema() {
326
1165
  return Joi.object({
327
1166
  current: Joi.number(),
@@ -331,6 +1170,8 @@ class UserModel {
331
1170
  type: Joi.string().allow(""),
332
1171
  });
333
1172
  }
1173
+
1174
+ /** @returns {PasswordLoginRequestSchema} */
334
1175
  static PasswordLoginRequestSchema() {
335
1176
  return Joi.object({
336
1177
  captcha_code: Joi.string().allow(""),
@@ -338,6 +1179,8 @@ class UserModel {
338
1179
  username: Joi.string().allow(""),
339
1180
  });
340
1181
  }
1182
+
1183
+ /** @returns {PhoneNumber} */
341
1184
  static PhoneNumber() {
342
1185
  return Joi.object({
343
1186
  active: Joi.boolean(),
@@ -347,18 +1190,24 @@ class UserModel {
347
1190
  verified: Joi.boolean(),
348
1191
  });
349
1192
  }
1193
+
1194
+ /** @returns {PlatformEmail} */
350
1195
  static PlatformEmail() {
351
1196
  return Joi.object({
352
1197
  is_required: Joi.boolean(),
353
1198
  level: Joi.string().allow(""),
354
1199
  });
355
1200
  }
1201
+
1202
+ /** @returns {PlatformMobile} */
356
1203
  static PlatformMobile() {
357
1204
  return Joi.object({
358
1205
  is_required: Joi.boolean(),
359
1206
  level: Joi.string().allow(""),
360
1207
  });
361
1208
  }
1209
+
1210
+ /** @returns {PlatformSchema} */
362
1211
  static PlatformSchema() {
363
1212
  return Joi.object({
364
1213
  _id: Joi.string().allow(""),
@@ -367,29 +1216,31 @@ class UserModel {
367
1216
  delete_account_consent: Joi.any(),
368
1217
  delete_account_day: Joi.number(),
369
1218
  delete_account_reasons: Joi.array().items(
370
- UserModel.DeleteAccountReasons()
1219
+ UserPlatformModel.DeleteAccountReasons()
371
1220
  ),
372
1221
  desktop_image: Joi.string().allow(""),
373
1222
  display: Joi.string().allow(""),
374
- flash_card: UserModel.FlashCard(),
1223
+ flash_card: UserPlatformModel.FlashCard(),
375
1224
  forgot_password: Joi.boolean(),
376
- login: UserModel.Login(),
377
- look_and_feel: UserModel.LookAndFeel(),
378
- meta: UserModel.MetaSchema(),
1225
+ login: UserPlatformModel.Login(),
1226
+ look_and_feel: UserPlatformModel.LookAndFeel(),
1227
+ meta: UserPlatformModel.MetaSchema(),
379
1228
  mobile_image: Joi.string().allow(""),
380
1229
  name: Joi.string().allow(""),
381
1230
  register: Joi.boolean(),
382
- register_required_fields: UserModel.RegisterRequiredFields(),
383
- required_fields: UserModel.RequiredFields(),
1231
+ register_required_fields: UserPlatformModel.RegisterRequiredFields(),
1232
+ required_fields: UserPlatformModel.RequiredFields(),
384
1233
  session_config: Joi.any(),
385
1234
  skip_captcha: Joi.boolean(),
386
1235
  skip_login: Joi.boolean(),
387
- social: UserModel.Social(),
388
- social_tokens: UserModel.SocialTokens(),
1236
+ social: UserPlatformModel.Social(),
1237
+ social_tokens: UserPlatformModel.SocialTokens(),
389
1238
  subtext: Joi.string().allow(""),
390
1239
  updated_at: Joi.string().allow(""),
391
1240
  });
392
1241
  }
1242
+
1243
+ /** @returns {ProfileEditSuccess} */
393
1244
  static ProfileEditSuccess() {
394
1245
  return Joi.object({
395
1246
  country_code: Joi.string().allow(""),
@@ -402,13 +1253,15 @@ class UserModel {
402
1253
  resend_timer: Joi.number(),
403
1254
  resend_token: Joi.string().allow(""),
404
1255
  success: Joi.boolean(),
405
- user: UserModel.UserSchema(),
1256
+ user: UserPlatformModel.UserSchema(),
406
1257
  user_exists: Joi.boolean(),
407
1258
  verify_email_link: Joi.boolean(),
408
1259
  verify_email_otp: Joi.boolean(),
409
1260
  verify_mobile_otp: Joi.boolean(),
410
1261
  });
411
1262
  }
1263
+
1264
+ /** @returns {ProfileEditSuccessSchema} */
412
1265
  static ProfileEditSuccessSchema() {
413
1266
  return Joi.object({
414
1267
  email: Joi.string().allow(""),
@@ -420,6 +1273,8 @@ class UserModel {
420
1273
  verify_mobile_otp: Joi.boolean(),
421
1274
  });
422
1275
  }
1276
+
1277
+ /** @returns {RegisterFormSuccess} */
423
1278
  static RegisterFormSuccess() {
424
1279
  return Joi.object({
425
1280
  country_code: Joi.string().allow(""),
@@ -437,35 +1292,47 @@ class UserModel {
437
1292
  verify_mobile_otp: Joi.boolean(),
438
1293
  });
439
1294
  }
1295
+
1296
+ /** @returns {RegisterRequiredFields} */
440
1297
  static RegisterRequiredFields() {
441
1298
  return Joi.object({
442
- email: UserModel.RegisterRequiredFieldsEmail(),
443
- mobile: UserModel.RegisterRequiredFieldsMobile(),
1299
+ email: UserPlatformModel.RegisterRequiredFieldsEmail(),
1300
+ mobile: UserPlatformModel.RegisterRequiredFieldsMobile(),
444
1301
  });
445
1302
  }
1303
+
1304
+ /** @returns {RegisterRequiredFieldsEmail} */
446
1305
  static RegisterRequiredFieldsEmail() {
447
1306
  return Joi.object({
448
1307
  is_required: Joi.boolean(),
449
1308
  level: Joi.string().allow(""),
450
1309
  });
451
1310
  }
1311
+
1312
+ /** @returns {RegisterRequiredFieldsMobile} */
452
1313
  static RegisterRequiredFieldsMobile() {
453
1314
  return Joi.object({
454
1315
  is_required: Joi.boolean(),
455
1316
  level: Joi.string().allow(""),
456
1317
  });
457
1318
  }
1319
+
1320
+ /** @returns {RequiredFields} */
458
1321
  static RequiredFields() {
459
1322
  return Joi.object({
460
- email: UserModel.PlatformEmail(),
461
- mobile: UserModel.PlatformMobile(),
1323
+ email: UserPlatformModel.PlatformEmail(),
1324
+ mobile: UserPlatformModel.PlatformMobile(),
462
1325
  });
463
1326
  }
1327
+
1328
+ /** @returns {ResetPasswordSuccess} */
464
1329
  static ResetPasswordSuccess() {
465
1330
  return Joi.object({
466
1331
  status: Joi.string().allow(""),
467
1332
  });
468
1333
  }
1334
+
1335
+ /** @returns {SendEmailOtpRequestSchema} */
469
1336
  static SendEmailOtpRequestSchema() {
470
1337
  return Joi.object({
471
1338
  action: Joi.string().allow(""),
@@ -474,11 +1341,15 @@ class UserModel {
474
1341
  token: Joi.string().allow(""),
475
1342
  });
476
1343
  }
1344
+
1345
+ /** @returns {SendEmailVerifyLinkSuccess} */
477
1346
  static SendEmailVerifyLinkSuccess() {
478
1347
  return Joi.object({
479
1348
  verify_email_link: Joi.boolean(),
480
1349
  });
481
1350
  }
1351
+
1352
+ /** @returns {SendMobileOtpRequestSchema} */
482
1353
  static SendMobileOtpRequestSchema() {
483
1354
  return Joi.object({
484
1355
  action: Joi.string().allow(""),
@@ -490,11 +1361,15 @@ class UserModel {
490
1361
  token: Joi.string().allow(""),
491
1362
  });
492
1363
  }
1364
+
1365
+ /** @returns {SendMobileVerifyLinkSuccess} */
493
1366
  static SendMobileVerifyLinkSuccess() {
494
1367
  return Joi.object({
495
1368
  verify_mobile_link: Joi.boolean(),
496
1369
  });
497
1370
  }
1371
+
1372
+ /** @returns {SendOtpRequestSchema} */
498
1373
  static SendOtpRequestSchema() {
499
1374
  return Joi.object({
500
1375
  android_hash: Joi.string().allow(""),
@@ -503,6 +1378,8 @@ class UserModel {
503
1378
  mobile: Joi.string().allow(""),
504
1379
  });
505
1380
  }
1381
+
1382
+ /** @returns {SendOtpResponse} */
506
1383
  static SendOtpResponse() {
507
1384
  return Joi.object({
508
1385
  country_code: Joi.string().allow(""),
@@ -520,12 +1397,16 @@ class UserModel {
520
1397
  verify_mobile_otp: Joi.boolean(),
521
1398
  });
522
1399
  }
1400
+
1401
+ /** @returns {SendResetPasswordEmailRequestSchema} */
523
1402
  static SendResetPasswordEmailRequestSchema() {
524
1403
  return Joi.object({
525
1404
  captcha_code: Joi.string().allow(""),
526
1405
  email: Joi.string().allow(""),
527
1406
  });
528
1407
  }
1408
+
1409
+ /** @returns {SendResetPasswordMobileRequestSchema} */
529
1410
  static SendResetPasswordMobileRequestSchema() {
530
1411
  return Joi.object({
531
1412
  captcha_code: Joi.string().allow(""),
@@ -533,6 +1414,8 @@ class UserModel {
533
1414
  mobile: Joi.string().allow(""),
534
1415
  });
535
1416
  }
1417
+
1418
+ /** @returns {SendVerificationLinkMobileRequestSchema} */
536
1419
  static SendVerificationLinkMobileRequestSchema() {
537
1420
  return Joi.object({
538
1421
  active: Joi.boolean(),
@@ -542,11 +1425,15 @@ class UserModel {
542
1425
  verified: Joi.boolean(),
543
1426
  });
544
1427
  }
1428
+
1429
+ /** @returns {SessionDeleteResponseSchema} */
545
1430
  static SessionDeleteResponseSchema() {
546
1431
  return Joi.object({
547
1432
  items: Joi.array().items(Joi.string().allow("")),
548
1433
  });
549
1434
  }
1435
+
1436
+ /** @returns {SessionExpiry} */
550
1437
  static SessionExpiry() {
551
1438
  return Joi.object({
552
1439
  duration: Joi.number(),
@@ -554,6 +1441,8 @@ class UserModel {
554
1441
  type: Joi.string().allow(""),
555
1442
  });
556
1443
  }
1444
+
1445
+ /** @returns {SessionListResponseInfo} */
557
1446
  static SessionListResponseInfo() {
558
1447
  return Joi.object({
559
1448
  domain: Joi.string().allow(""),
@@ -563,16 +1452,22 @@ class UserModel {
563
1452
  user_agent: Joi.string().allow(""),
564
1453
  });
565
1454
  }
1455
+
1456
+ /** @returns {SessionListResponseSchema} */
566
1457
  static SessionListResponseSchema() {
567
1458
  return Joi.object({
568
- items: Joi.array().items(UserModel.SessionListResponseInfo()),
1459
+ items: Joi.array().items(UserPlatformModel.SessionListResponseInfo()),
569
1460
  });
570
1461
  }
1462
+
1463
+ /** @returns {SessionListSuccess} */
571
1464
  static SessionListSuccess() {
572
1465
  return Joi.object({
573
1466
  sessions: Joi.array().items(Joi.string().allow("")),
574
1467
  });
575
1468
  }
1469
+
1470
+ /** @returns {Social} */
576
1471
  static Social() {
577
1472
  return Joi.object({
578
1473
  account_kit: Joi.boolean(),
@@ -581,28 +1476,38 @@ class UserModel {
581
1476
  google: Joi.boolean(),
582
1477
  });
583
1478
  }
1479
+
1480
+ /** @returns {SocialTokens} */
584
1481
  static SocialTokens() {
585
1482
  return Joi.object({
586
- account_kit: UserModel.Accountkit(),
587
- facebook: UserModel.Facebook(),
588
- google: UserModel.Google(),
1483
+ account_kit: UserPlatformModel.Accountkit(),
1484
+ facebook: UserPlatformModel.Facebook(),
1485
+ google: UserPlatformModel.Google(),
589
1486
  });
590
1487
  }
1488
+
1489
+ /** @returns {TokenRequestBodySchema} */
591
1490
  static TokenRequestBodySchema() {
592
1491
  return Joi.object({
593
1492
  token: Joi.string().allow(""),
594
1493
  });
595
1494
  }
1495
+
1496
+ /** @returns {UnauthenticatedSchema} */
596
1497
  static UnauthenticatedSchema() {
597
1498
  return Joi.object({
598
1499
  authenticated: Joi.boolean(),
599
1500
  });
600
1501
  }
1502
+
1503
+ /** @returns {UnauthorizedSchema} */
601
1504
  static UnauthorizedSchema() {
602
1505
  return Joi.object({
603
1506
  message: Joi.string().allow(""),
604
1507
  });
605
1508
  }
1509
+
1510
+ /** @returns {UnDeleteUserRequestSchema} */
606
1511
  static UnDeleteUserRequestSchema() {
607
1512
  return Joi.object({
608
1513
  reason: Joi.string().allow(""),
@@ -610,17 +1515,23 @@ class UserModel {
610
1515
  user_id: Joi.string().allow(""),
611
1516
  });
612
1517
  }
1518
+
1519
+ /** @returns {UnDeleteUserSuccess} */
613
1520
  static UnDeleteUserSuccess() {
614
1521
  return Joi.object({
615
1522
  success: Joi.boolean(),
616
1523
  });
617
1524
  }
1525
+
1526
+ /** @returns {UpdatePasswordRequestSchema} */
618
1527
  static UpdatePasswordRequestSchema() {
619
1528
  return Joi.object({
620
1529
  new_password: Joi.string().allow(""),
621
1530
  old_password: Joi.string().allow(""),
622
1531
  });
623
1532
  }
1533
+
1534
+ /** @returns {UpdateUserGroupSchema} */
624
1535
  static UpdateUserGroupSchema() {
625
1536
  return Joi.object({
626
1537
  description: Joi.string().allow(""),
@@ -628,17 +1539,21 @@ class UserModel {
628
1539
  name: Joi.string().allow(""),
629
1540
  });
630
1541
  }
1542
+
1543
+ /** @returns {UpdateUserRequestSchema} */
631
1544
  static UpdateUserRequestSchema() {
632
1545
  return Joi.object({
633
- emails: Joi.array().items(UserModel.UserEmails()),
1546
+ emails: Joi.array().items(UserPlatformModel.UserEmails()),
634
1547
  external_id: Joi.string().allow(""),
635
1548
  first_name: Joi.string().allow(""),
636
1549
  gender: Joi.string().allow(""),
637
1550
  last_name: Joi.string().allow(""),
638
1551
  meta: Joi.any(),
639
- phone_numbers: Joi.array().items(UserModel.UserPhoneNumbers()),
1552
+ phone_numbers: Joi.array().items(UserPlatformModel.UserPhoneNumbers()),
640
1553
  });
641
1554
  }
1555
+
1556
+ /** @returns {UserEmails} */
642
1557
  static UserEmails() {
643
1558
  return Joi.object({
644
1559
  active: Joi.boolean(),
@@ -647,12 +1562,16 @@ class UserModel {
647
1562
  verified: Joi.boolean(),
648
1563
  });
649
1564
  }
1565
+
1566
+ /** @returns {UserGroupListResponseSchema} */
650
1567
  static UserGroupListResponseSchema() {
651
1568
  return Joi.object({
652
- items: Joi.array().items(UserModel.UserGroupResponseSchema()),
653
- page: UserModel.PaginationSchema(),
1569
+ items: Joi.array().items(UserPlatformModel.UserGroupResponseSchema()),
1570
+ page: UserPlatformModel.PaginationSchema(),
654
1571
  });
655
1572
  }
1573
+
1574
+ /** @returns {UserGroupResponseSchema} */
656
1575
  static UserGroupResponseSchema() {
657
1576
  return Joi.object({
658
1577
  __v: Joi.number(),
@@ -667,11 +1586,15 @@ class UserModel {
667
1586
  uid: Joi.number(),
668
1587
  });
669
1588
  }
1589
+
1590
+ /** @returns {UserObjectSchema} */
670
1591
  static UserObjectSchema() {
671
1592
  return Joi.object({
672
- user: UserModel.UserSchema(),
1593
+ user: UserPlatformModel.UserSchema(),
673
1594
  });
674
1595
  }
1596
+
1597
+ /** @returns {UserPhoneNumbers} */
675
1598
  static UserPhoneNumbers() {
676
1599
  return Joi.object({
677
1600
  active: Joi.boolean(),
@@ -681,6 +1604,8 @@ class UserModel {
681
1604
  verified: Joi.boolean(),
682
1605
  });
683
1606
  }
1607
+
1608
+ /** @returns {UserSchema} */
684
1609
  static UserSchema() {
685
1610
  return Joi.object({
686
1611
  _id: Joi.string().allow(""),
@@ -689,23 +1614,27 @@ class UserModel {
689
1614
  application_id: Joi.string().allow(""),
690
1615
  created_at: Joi.string().allow(""),
691
1616
  dob: Joi.string().allow(""),
692
- emails: Joi.array().items(UserModel.Email()),
1617
+ emails: Joi.array().items(UserPlatformModel.Email()),
693
1618
  first_name: Joi.string().allow(""),
694
1619
  gender: Joi.string().allow(""),
695
1620
  last_name: Joi.string().allow(""),
696
1621
  meta: Joi.any(),
697
- phone_numbers: Joi.array().items(UserModel.PhoneNumber()),
1622
+ phone_numbers: Joi.array().items(UserPlatformModel.PhoneNumber()),
698
1623
  profile_pic_url: Joi.string().allow(""),
699
1624
  updated_at: Joi.string().allow(""),
700
1625
  user_id: Joi.string().allow(""),
701
1626
  username: Joi.string().allow(""),
702
1627
  });
703
1628
  }
1629
+
1630
+ /** @returns {UserSearchResponseSchema} */
704
1631
  static UserSearchResponseSchema() {
705
1632
  return Joi.object({
706
- users: Joi.array().items(UserModel.UserSchema()),
1633
+ users: Joi.array().items(UserPlatformModel.UserSchema()),
707
1634
  });
708
1635
  }
1636
+
1637
+ /** @returns {VerifyEmailOtpRequestSchema} */
709
1638
  static VerifyEmailOtpRequestSchema() {
710
1639
  return Joi.object({
711
1640
  action: Joi.string().allow(""),
@@ -714,23 +1643,31 @@ class UserModel {
714
1643
  register_token: Joi.string().allow(""),
715
1644
  });
716
1645
  }
1646
+
1647
+ /** @returns {VerifyEmailOTPSuccess} */
717
1648
  static VerifyEmailOTPSuccess() {
718
1649
  return Joi.object({
719
- user: UserModel.UserSchema(),
1650
+ user: UserPlatformModel.UserSchema(),
720
1651
  verify_email_link: Joi.boolean(),
721
1652
  });
722
1653
  }
1654
+
1655
+ /** @returns {VerifyEmailSuccess} */
723
1656
  static VerifyEmailSuccess() {
724
1657
  return Joi.object({
725
1658
  message: Joi.string().allow(""),
726
1659
  });
727
1660
  }
1661
+
1662
+ /** @returns {VerifyMobileOTPSuccess} */
728
1663
  static VerifyMobileOTPSuccess() {
729
1664
  return Joi.object({
730
- user: UserModel.UserSchema(),
1665
+ user: UserPlatformModel.UserSchema(),
731
1666
  verify_mobile_link: Joi.boolean(),
732
1667
  });
733
1668
  }
1669
+
1670
+ /** @returns {VerifyOtpRequestSchema} */
734
1671
  static VerifyOtpRequestSchema() {
735
1672
  return Joi.object({
736
1673
  otp: Joi.string().allow(""),
@@ -738,12 +1675,14 @@ class UserModel {
738
1675
  request_id: Joi.string().allow(""),
739
1676
  });
740
1677
  }
1678
+
1679
+ /** @returns {VerifyOtpSuccess} */
741
1680
  static VerifyOtpSuccess() {
742
1681
  return Joi.object({
743
1682
  register_token: Joi.string().allow(""),
744
- user: UserModel.UserSchema(),
1683
+ user: UserPlatformModel.UserSchema(),
745
1684
  user_exists: Joi.boolean(),
746
1685
  });
747
1686
  }
748
1687
  }
749
- module.exports = UserModel;
1688
+ module.exports = UserPlatformModel;