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

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (237) hide show
  1. package/README.md +1 -1
  2. package/package.json +1 -1
  3. package/sdk/application/ApplicationClient.d.ts +2 -0
  4. package/sdk/application/ApplicationClient.js +2 -0
  5. package/sdk/application/Cart/CartApplicationClient.d.ts +68 -48
  6. package/sdk/application/Cart/CartApplicationClient.js +130 -27
  7. package/sdk/application/Catalog/CatalogApplicationClient.d.ts +59 -58
  8. package/sdk/application/Catalog/CatalogApplicationClient.js +30 -29
  9. package/sdk/application/Common/CommonApplicationClient.d.ts +2 -2
  10. package/sdk/application/Common/CommonApplicationClient.js +1 -1
  11. package/sdk/application/Configuration/ConfigurationApplicationClient.d.ts +20 -20
  12. package/sdk/application/Configuration/ConfigurationApplicationClient.js +10 -10
  13. package/sdk/application/Content/ContentApplicationClient.d.ts +19 -30
  14. package/sdk/application/Content/ContentApplicationClient.js +40 -60
  15. package/sdk/application/FileStorage/FileStorageApplicationClient.d.ts +8 -8
  16. package/sdk/application/FileStorage/FileStorageApplicationClient.js +7 -7
  17. package/sdk/application/Finance/FinanceApplicationClient.d.ts +29 -0
  18. package/sdk/application/Finance/FinanceApplicationClient.js +126 -0
  19. package/sdk/application/Lead/LeadApplicationClient.d.ts +2 -2
  20. package/sdk/application/Lead/LeadApplicationClient.js +1 -1
  21. package/sdk/application/Logistic/LogisticApplicationClient.d.ts +35 -15
  22. package/sdk/application/Logistic/LogisticApplicationClient.js +118 -8
  23. package/sdk/application/Order/OrderApplicationClient.d.ts +22 -12
  24. package/sdk/application/Order/OrderApplicationClient.js +62 -8
  25. package/sdk/application/Payment/PaymentApplicationClient.d.ts +87 -87
  26. package/sdk/application/Payment/PaymentApplicationClient.js +65 -46
  27. package/sdk/application/Rewards/RewardsApplicationClient.d.ts +13 -13
  28. package/sdk/application/Rewards/RewardsApplicationClient.js +7 -7
  29. package/sdk/application/Theme/ThemeApplicationClient.d.ts +2 -2
  30. package/sdk/application/Theme/ThemeApplicationClient.js +4 -2
  31. package/sdk/application/User/UserApplicationClient.d.ts +10 -10
  32. package/sdk/application/User/UserApplicationClient.js +6 -6
  33. package/sdk/application/Webhook/WebhookApplicationClient.d.ts +4 -4
  34. package/sdk/application/Webhook/WebhookApplicationClient.js +3 -3
  35. package/sdk/partner/FileStorage/FileStoragePartnerClient.d.ts +86 -12
  36. package/sdk/partner/FileStorage/FileStoragePartnerClient.js +582 -24
  37. package/sdk/partner/FileStorage/FileStoragePartnerModel.d.ts +116 -19
  38. package/sdk/partner/FileStorage/FileStoragePartnerModel.js +121 -14
  39. package/sdk/partner/FileStorage/FileStoragePartnerValidator.d.ts +8 -1
  40. package/sdk/partner/FileStorage/FileStoragePartnerValidator.js +51 -4
  41. package/sdk/partner/Lead/LeadPartnerClient.d.ts +2 -2
  42. package/sdk/partner/Lead/LeadPartnerClient.js +2 -2
  43. package/sdk/partner/Lead/LeadPartnerModel.d.ts +5 -5
  44. package/sdk/partner/Lead/LeadPartnerModel.js +15 -15
  45. package/sdk/partner/Logistics/LogisticsPartnerClient.d.ts +126 -20
  46. package/sdk/partner/Logistics/LogisticsPartnerClient.js +970 -20
  47. package/sdk/partner/Logistics/LogisticsPartnerModel.d.ts +1200 -167
  48. package/sdk/partner/Logistics/LogisticsPartnerModel.js +571 -160
  49. package/sdk/partner/Logistics/LogisticsPartnerValidator.d.ts +10 -0
  50. package/sdk/partner/Logistics/LogisticsPartnerValidator.js +121 -7
  51. package/sdk/partner/Theme/ThemePartnerClient.d.ts +8 -10
  52. package/sdk/partner/Theme/ThemePartnerClient.js +14 -16
  53. package/sdk/partner/Theme/ThemePartnerModel.d.ts +96 -37
  54. package/sdk/partner/Theme/ThemePartnerModel.js +90 -36
  55. package/sdk/partner/Theme/ThemePartnerValidator.js +4 -4
  56. package/sdk/partner/Webhook/WebhookPartnerClient.d.ts +28 -18
  57. package/sdk/partner/Webhook/WebhookPartnerClient.js +103 -18
  58. package/sdk/partner/Webhook/WebhookPartnerModel.d.ts +612 -179
  59. package/sdk/partner/Webhook/WebhookPartnerModel.js +253 -150
  60. package/sdk/partner/Webhook/WebhookPartnerValidator.d.ts +1 -0
  61. package/sdk/partner/Webhook/WebhookPartnerValidator.js +11 -3
  62. package/sdk/platform/Analytics/AnalyticsPlatformApplicationClient.d.ts +5 -4
  63. package/sdk/platform/Analytics/AnalyticsPlatformApplicationClient.js +14 -8
  64. package/sdk/platform/Analytics/AnalyticsPlatformModel.d.ts +59 -9
  65. package/sdk/platform/Analytics/AnalyticsPlatformModel.js +40 -4
  66. package/sdk/platform/AuditTrail/AuditTrailPlatformClient.d.ts +2 -32
  67. package/sdk/platform/AuditTrail/AuditTrailPlatformClient.js +3 -243
  68. package/sdk/platform/AuditTrail/AuditTrailPlatformModel.d.ts +11 -130
  69. package/sdk/platform/AuditTrail/AuditTrailPlatformModel.js +12 -152
  70. package/sdk/platform/AuditTrail/AuditTrailPlatformValidator.d.ts +1 -39
  71. package/sdk/platform/AuditTrail/AuditTrailPlatformValidator.js +0 -35
  72. package/sdk/platform/Billing/BillingPlatformClient.d.ts +12 -12
  73. package/sdk/platform/Billing/BillingPlatformClient.js +15 -15
  74. package/sdk/platform/Billing/BillingPlatformModel.d.ts +443 -388
  75. package/sdk/platform/Billing/BillingPlatformModel.js +280 -263
  76. package/sdk/platform/Billing/BillingPlatformValidator.d.ts +16 -18
  77. package/sdk/platform/Billing/BillingPlatformValidator.js +8 -9
  78. package/sdk/platform/Cart/CartPlatformApplicationClient.d.ts +134 -103
  79. package/sdk/platform/Cart/CartPlatformApplicationClient.js +419 -115
  80. package/sdk/platform/Cart/CartPlatformApplicationValidator.d.ts +121 -65
  81. package/sdk/platform/Cart/CartPlatformApplicationValidator.js +109 -44
  82. package/sdk/platform/Cart/CartPlatformModel.d.ts +5039 -1300
  83. package/sdk/platform/Cart/CartPlatformModel.js +1976 -1217
  84. package/sdk/platform/Catalog/CatalogPlatformApplicationClient.d.ts +209 -183
  85. package/sdk/platform/Catalog/CatalogPlatformApplicationClient.js +452 -395
  86. package/sdk/platform/Catalog/CatalogPlatformApplicationValidator.d.ts +185 -142
  87. package/sdk/platform/Catalog/CatalogPlatformApplicationValidator.js +96 -78
  88. package/sdk/platform/Catalog/CatalogPlatformClient.d.ts +154 -117
  89. package/sdk/platform/Catalog/CatalogPlatformClient.js +292 -172
  90. package/sdk/platform/Catalog/CatalogPlatformModel.d.ts +6941 -2203
  91. package/sdk/platform/Catalog/CatalogPlatformModel.js +3224 -1687
  92. package/sdk/platform/Catalog/CatalogPlatformValidator.d.ts +72 -31
  93. package/sdk/platform/Catalog/CatalogPlatformValidator.js +50 -24
  94. package/sdk/platform/Common/CommonPlatformClient.d.ts +3 -2
  95. package/sdk/platform/Common/CommonPlatformClient.js +3 -2
  96. package/sdk/platform/Common/CommonPlatformModel.d.ts +9 -9
  97. package/sdk/platform/Common/CommonPlatformModel.js +6 -6
  98. package/sdk/platform/Communication/CommunicationPlatformApplicationClient.d.ts +16 -17
  99. package/sdk/platform/Communication/CommunicationPlatformApplicationClient.js +16 -17
  100. package/sdk/platform/Communication/CommunicationPlatformApplicationValidator.d.ts +8 -8
  101. package/sdk/platform/Communication/CommunicationPlatformApplicationValidator.js +8 -8
  102. package/sdk/platform/Communication/CommunicationPlatformModel.d.ts +43 -33
  103. package/sdk/platform/Communication/CommunicationPlatformModel.js +38 -34
  104. package/sdk/platform/CompanyProfile/CompanyProfilePlatformClient.d.ts +46 -42
  105. package/sdk/platform/CompanyProfile/CompanyProfilePlatformClient.js +47 -43
  106. package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.d.ts +223 -223
  107. package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.js +210 -212
  108. package/sdk/platform/CompanyProfile/CompanyProfilePlatformValidator.d.ts +12 -12
  109. package/sdk/platform/CompanyProfile/CompanyProfilePlatformValidator.js +12 -12
  110. package/sdk/platform/Configuration/ConfigurationPlatformApplicationClient.d.ts +46 -33
  111. package/sdk/platform/Configuration/ConfigurationPlatformApplicationClient.js +67 -54
  112. package/sdk/platform/Configuration/ConfigurationPlatformApplicationValidator.d.ts +18 -18
  113. package/sdk/platform/Configuration/ConfigurationPlatformApplicationValidator.js +18 -18
  114. package/sdk/platform/Configuration/ConfigurationPlatformClient.d.ts +45 -24
  115. package/sdk/platform/Configuration/ConfigurationPlatformClient.js +134 -30
  116. package/sdk/platform/Configuration/ConfigurationPlatformModel.d.ts +283 -124
  117. package/sdk/platform/Configuration/ConfigurationPlatformModel.js +219 -94
  118. package/sdk/platform/Configuration/ConfigurationPlatformValidator.d.ts +37 -9
  119. package/sdk/platform/Configuration/ConfigurationPlatformValidator.js +27 -8
  120. package/sdk/platform/Content/ContentPlatformApplicationClient.d.ts +124 -141
  121. package/sdk/platform/Content/ContentPlatformApplicationClient.js +449 -422
  122. package/sdk/platform/Content/ContentPlatformApplicationValidator.d.ts +179 -141
  123. package/sdk/platform/Content/ContentPlatformApplicationValidator.js +168 -130
  124. package/sdk/platform/Content/ContentPlatformClient.d.ts +142 -106
  125. package/sdk/platform/Content/ContentPlatformClient.js +523 -336
  126. package/sdk/platform/Content/ContentPlatformModel.d.ts +1241 -395
  127. package/sdk/platform/Content/ContentPlatformModel.js +521 -390
  128. package/sdk/platform/Content/ContentPlatformValidator.d.ts +168 -117
  129. package/sdk/platform/Content/ContentPlatformValidator.js +162 -108
  130. package/sdk/platform/Discount/DiscountPlatformClient.d.ts +14 -12
  131. package/sdk/platform/Discount/DiscountPlatformClient.js +14 -12
  132. package/sdk/platform/Discount/DiscountPlatformModel.d.ts +13 -13
  133. package/sdk/platform/Discount/DiscountPlatformModel.js +12 -12
  134. package/sdk/platform/Discount/DiscountPlatformValidator.d.ts +2 -2
  135. package/sdk/platform/Discount/DiscountPlatformValidator.js +2 -2
  136. package/sdk/platform/FileStorage/FileStoragePlatformApplicationClient.d.ts +94 -36
  137. package/sdk/platform/FileStorage/FileStoragePlatformApplicationClient.js +462 -60
  138. package/sdk/platform/FileStorage/FileStoragePlatformApplicationValidator.d.ts +62 -15
  139. package/sdk/platform/FileStorage/FileStoragePlatformApplicationValidator.js +75 -13
  140. package/sdk/platform/FileStorage/FileStoragePlatformClient.d.ts +19 -19
  141. package/sdk/platform/FileStorage/FileStoragePlatformClient.js +21 -21
  142. package/sdk/platform/FileStorage/FileStoragePlatformModel.d.ts +370 -101
  143. package/sdk/platform/FileStorage/FileStoragePlatformModel.js +313 -84
  144. package/sdk/platform/FileStorage/FileStoragePlatformValidator.d.ts +6 -6
  145. package/sdk/platform/FileStorage/FileStoragePlatformValidator.js +6 -6
  146. package/sdk/platform/Lead/LeadPlatformClient.d.ts +2 -2
  147. package/sdk/platform/Lead/LeadPlatformClient.js +2 -2
  148. package/sdk/platform/Lead/LeadPlatformModel.d.ts +5 -5
  149. package/sdk/platform/Lead/LeadPlatformModel.js +16 -16
  150. package/sdk/platform/Order/OrderPlatformApplicationClient.d.ts +17 -6
  151. package/sdk/platform/Order/OrderPlatformApplicationClient.js +85 -7
  152. package/sdk/platform/Order/OrderPlatformApplicationValidator.d.ts +95 -24
  153. package/sdk/platform/Order/OrderPlatformApplicationValidator.js +39 -19
  154. package/sdk/platform/Order/OrderPlatformClient.d.ts +153 -96
  155. package/sdk/platform/Order/OrderPlatformClient.js +416 -198
  156. package/sdk/platform/Order/OrderPlatformModel.d.ts +7602 -1269
  157. package/sdk/platform/Order/OrderPlatformModel.js +3926 -1269
  158. package/sdk/platform/Order/OrderPlatformValidator.d.ts +270 -109
  159. package/sdk/platform/Order/OrderPlatformValidator.js +135 -77
  160. package/sdk/platform/Partner/PartnerPlatformApplicationClient.d.ts +6 -4
  161. package/sdk/platform/Partner/PartnerPlatformApplicationClient.js +9 -7
  162. package/sdk/platform/Partner/PartnerPlatformModel.d.ts +9 -9
  163. package/sdk/platform/Partner/PartnerPlatformModel.js +8 -8
  164. package/sdk/platform/Payment/PaymentPlatformApplicationClient.d.ts +93 -105
  165. package/sdk/platform/Payment/PaymentPlatformApplicationClient.js +129 -141
  166. package/sdk/platform/Payment/PaymentPlatformApplicationValidator.d.ts +48 -48
  167. package/sdk/platform/Payment/PaymentPlatformApplicationValidator.js +48 -48
  168. package/sdk/platform/Payment/PaymentPlatformClient.d.ts +20 -20
  169. package/sdk/platform/Payment/PaymentPlatformClient.js +20 -20
  170. package/sdk/platform/Payment/PaymentPlatformModel.d.ts +333 -319
  171. package/sdk/platform/Payment/PaymentPlatformModel.js +288 -278
  172. package/sdk/platform/Payment/PaymentPlatformValidator.d.ts +8 -8
  173. package/sdk/platform/Payment/PaymentPlatformValidator.js +8 -8
  174. package/sdk/platform/PlatformClient.d.ts +0 -2
  175. package/sdk/platform/PlatformClient.js +0 -4
  176. package/sdk/platform/Rewards/RewardsPlatformApplicationClient.d.ts +2 -2
  177. package/sdk/platform/Rewards/RewardsPlatformApplicationClient.js +2 -2
  178. package/sdk/platform/Rewards/RewardsPlatformApplicationValidator.d.ts +2 -2
  179. package/sdk/platform/Rewards/RewardsPlatformApplicationValidator.js +2 -2
  180. package/sdk/platform/Rewards/RewardsPlatformModel.d.ts +9 -9
  181. package/sdk/platform/Rewards/RewardsPlatformModel.js +8 -8
  182. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationClient.d.ts +48 -38
  183. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationClient.js +134 -43
  184. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationValidator.d.ts +46 -17
  185. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationValidator.js +34 -14
  186. package/sdk/platform/Serviceability/ServiceabilityPlatformClient.d.ts +38 -44
  187. package/sdk/platform/Serviceability/ServiceabilityPlatformClient.js +56 -62
  188. package/sdk/platform/Serviceability/ServiceabilityPlatformModel.d.ts +1842 -609
  189. package/sdk/platform/Serviceability/ServiceabilityPlatformModel.js +886 -554
  190. package/sdk/platform/Serviceability/ServiceabilityPlatformValidator.d.ts +42 -46
  191. package/sdk/platform/Serviceability/ServiceabilityPlatformValidator.js +26 -28
  192. package/sdk/platform/Share/SharePlatformApplicationClient.d.ts +2 -2
  193. package/sdk/platform/Share/SharePlatformApplicationClient.js +2 -2
  194. package/sdk/platform/Share/SharePlatformModel.d.ts +36 -5
  195. package/sdk/platform/Share/SharePlatformModel.js +27 -4
  196. package/sdk/platform/Theme/ThemePlatformApplicationClient.d.ts +3 -3
  197. package/sdk/platform/Theme/ThemePlatformApplicationClient.js +8 -4
  198. package/sdk/platform/Theme/ThemePlatformApplicationValidator.d.ts +5 -0
  199. package/sdk/platform/Theme/ThemePlatformApplicationValidator.js +2 -0
  200. package/sdk/platform/Theme/ThemePlatformModel.d.ts +37 -11
  201. package/sdk/platform/Theme/ThemePlatformModel.js +33 -15
  202. package/sdk/platform/User/UserPlatformApplicationClient.d.ts +12 -12
  203. package/sdk/platform/User/UserPlatformApplicationClient.js +12 -12
  204. package/sdk/platform/User/UserPlatformApplicationValidator.d.ts +2 -2
  205. package/sdk/platform/User/UserPlatformApplicationValidator.js +2 -2
  206. package/sdk/platform/User/UserPlatformModel.d.ts +21 -21
  207. package/sdk/platform/User/UserPlatformModel.js +23 -23
  208. package/sdk/platform/Webhook/WebhookPlatformClient.d.ts +25 -78
  209. package/sdk/platform/Webhook/WebhookPlatformClient.js +75 -470
  210. package/sdk/platform/Webhook/WebhookPlatformModel.d.ts +720 -427
  211. package/sdk/platform/Webhook/WebhookPlatformModel.js +410 -386
  212. package/sdk/platform/Webhook/WebhookPlatformValidator.d.ts +10 -55
  213. package/sdk/platform/Webhook/WebhookPlatformValidator.js +12 -72
  214. package/sdk/platform/index.d.ts +0 -1
  215. package/sdk/platform/index.js +0 -2
  216. package/sdk/public/Configuration/ConfigurationPublicClient.d.ts +3 -2
  217. package/sdk/public/Configuration/ConfigurationPublicClient.js +6 -5
  218. package/sdk/public/Configuration/ConfigurationPublicModel.d.ts +9 -9
  219. package/sdk/public/Configuration/ConfigurationPublicModel.js +6 -6
  220. package/sdk/public/Content/ContentPublicClient.d.ts +112 -2
  221. package/sdk/public/Content/ContentPublicClient.js +895 -8
  222. package/sdk/public/Content/ContentPublicModel.d.ts +549 -3
  223. package/sdk/public/Content/ContentPublicModel.js +649 -3
  224. package/sdk/public/Content/ContentPublicValidator.d.ts +69 -3
  225. package/sdk/public/Content/ContentPublicValidator.js +88 -2
  226. package/sdk/public/Webhook/WebhookPublicClient.d.ts +8 -8
  227. package/sdk/public/Webhook/WebhookPublicClient.js +8 -8
  228. package/sdk/public/Webhook/WebhookPublicModel.d.ts +21 -21
  229. package/sdk/public/Webhook/WebhookPublicModel.js +15 -15
  230. package/sdk/public/Webhook/WebhookPublicValidator.d.ts +4 -4
  231. package/sdk/public/Webhook/WebhookPublicValidator.js +4 -4
  232. package/sdk/platform/Finance/FinancePlatformClient.d.ts +0 -320
  233. package/sdk/platform/Finance/FinancePlatformClient.js +0 -2333
  234. package/sdk/platform/Finance/FinancePlatformModel.d.ts +0 -2890
  235. package/sdk/platform/Finance/FinancePlatformModel.js +0 -2148
  236. package/sdk/platform/Finance/FinancePlatformValidator.d.ts +0 -284
  237. package/sdk/platform/Finance/FinancePlatformValidator.js +0 -354
@@ -1,11 +1,300 @@
1
1
  const Joi = require("joi");
2
2
 
3
+ /**
4
+ * @typedef BasicDetailsPayloadSchema
5
+ * @property {string} [name]
6
+ * @property {string} [logo_url]
7
+ * @property {string} [favicon_url]
8
+ * @property {string} [title]
9
+ * @property {string} [meta_title]
10
+ * @property {string} [meta_description]
11
+ * @property {string} [meta_image]
12
+ * @property {WhatsNew[]} [whats_new]
13
+ * @property {Features[]} [features]
14
+ * @property {Object} [authentication]
15
+ * @property {BusinessAccount} [business_account]
16
+ * @property {SellerSupport} [seller_support]
17
+ * @property {string} [copyright]
18
+ * @property {string} [address]
19
+ * @property {string} [documentation_url]
20
+ * @property {string} [faq_url]
21
+ * @property {string} [facebook_url]
22
+ * @property {string} [instagram_url]
23
+ * @property {string} [privacy_url]
24
+ * @property {string} [twitter_url]
25
+ * @property {string} [termsofservice_url]
26
+ */
27
+
28
+ /**
29
+ * @typedef WhatsNew
30
+ * @property {string} [description]
31
+ */
32
+
33
+ /**
34
+ * @typedef Features
35
+ * @property {string} [title]
36
+ * @property {string} [text]
37
+ * @property {string[]} [list]
38
+ * @property {string} [image]
39
+ */
40
+
41
+ /**
42
+ * @typedef BusinessAccount
43
+ * @property {boolean} [is_limit]
44
+ * @property {number} [threshold]
45
+ */
46
+
47
+ /**
48
+ * @typedef SellerSupport
49
+ * @property {string} [email]
50
+ * @property {number} [phone_number]
51
+ */
52
+
53
+ /**
54
+ * @typedef MenuSchema
55
+ * @property {SalesChannelSchema} [sales_channel]
56
+ * @property {OtherSellerSchema} [other_seller]
57
+ * @property {FooterContentSchema} [footer_content]
58
+ * @property {boolean} [can_create_business_account]
59
+ * @property {CompanyLevelMenuItemSchema[]} [company_level]
60
+ * @property {ApplicationLevelMenuItemSchema[]} [application_level]
61
+ */
62
+
63
+ /**
64
+ * @typedef MenusSchema
65
+ * @property {string} [_id]
66
+ * @property {MenuTypeSchema} [desktop]
67
+ * @property {MenuTypeSchema} [mobile]
68
+ * @property {number} [__v]
69
+ */
70
+
71
+ /**
72
+ * @typedef MenuTypeSchema
73
+ * @property {MenuSchema} [menu]
74
+ */
75
+
76
+ /**
77
+ * @typedef CompanyLevelMenuItemSchema
78
+ * @property {VisibleOnSchema} [visible_on]
79
+ * @property {string} [display]
80
+ * @property {string[]} [permissions]
81
+ * @property {string} [title]
82
+ * @property {string} [link]
83
+ * @property {string} [icon]
84
+ * @property {boolean} [is_disabled]
85
+ * @property {CompanyLevelMenuItemSchema[]} [child]
86
+ */
87
+
88
+ /**
89
+ * @typedef ApplicationLevelMenuItemSchema
90
+ * @property {VisibleOnSchema} [visible_on]
91
+ * @property {string} [display]
92
+ * @property {string[]} [permissions]
93
+ * @property {string} [title]
94
+ * @property {string} [link]
95
+ * @property {string} [icon]
96
+ * @property {boolean} [is_disabled]
97
+ * @property {ApplicationLevelMenuItemSchema[]} [child]
98
+ */
99
+
100
+ /**
101
+ * @typedef VisibleOnSchema
102
+ * @property {boolean} [web]
103
+ * @property {boolean} [ios]
104
+ * @property {boolean} [android]
105
+ */
106
+
107
+ /**
108
+ * @typedef SalesChannelSchema
109
+ * @property {boolean} [can_add]
110
+ * @property {string} [title]
111
+ */
112
+
113
+ /**
114
+ * @typedef OtherSellerSchema
115
+ * @property {boolean} [is_visible]
116
+ * @property {string} [title]
117
+ */
118
+
119
+ /**
120
+ * @typedef FooterContentSchema
121
+ * @property {boolean} [is_visible]
122
+ * @property {string} [line_one]
123
+ * @property {string} [line_two]
124
+ */
125
+
126
+ /**
127
+ * @typedef AnalyticsTagsSchema
128
+ * @property {string} [_id]
129
+ * @property {number} [__v]
130
+ * @property {string} [body_code]
131
+ * @property {boolean} [enabled]
132
+ * @property {string} [header_code]
133
+ * @property {string} [name]
134
+ */
135
+
136
+ /**
137
+ * @typedef CustomPageBySlugSchema
138
+ * @property {string} [_id]
139
+ * @property {string} [title]
140
+ * @property {string} [slug]
141
+ * @property {string} [type]
142
+ * @property {string} [description]
143
+ * @property {boolean} [published]
144
+ * @property {ItemSchema[]} [content]
145
+ * @property {CreateCustomPageSeoSchema} [seo]
146
+ * @property {CreatedBySchema} [created_by]
147
+ * @property {CreatedBySchema} [modified_by]
148
+ * @property {boolean} [archived]
149
+ * @property {string} [created_on]
150
+ * @property {string} [modified_on]
151
+ * @property {number} [__v]
152
+ */
153
+
154
+ /**
155
+ * @typedef ItemSchema
156
+ * @property {string} [type]
157
+ * @property {string} [value]
158
+ */
159
+
160
+ /**
161
+ * @typedef CreateCustomPageSeoSchema
162
+ * @property {string} [title]
163
+ * @property {string} [description]
164
+ */
165
+
166
+ /**
167
+ * @typedef RawHtmlContentSchema
168
+ * @property {string} [type]
169
+ * @property {string} [value]
170
+ */
171
+
172
+ /**
173
+ * @typedef FooterSchema
174
+ * @property {string} [_id]
175
+ * @property {string} [title]
176
+ * @property {string} [description]
177
+ * @property {string} [type]
178
+ * @property {Object[]} [tags]
179
+ * @property {boolean} [published]
180
+ * @property {RawHtmlContentSchema[]} [content]
181
+ * @property {Object[]} [footer_meta]
182
+ * @property {CreatedBySchema} [created_by]
183
+ * @property {CreatedBySchema} [modified_by]
184
+ * @property {boolean} [archived]
185
+ * @property {number} [__v]
186
+ */
187
+
188
+ /**
189
+ * @typedef HomePageContentSchema
190
+ * @property {string} [_id]
191
+ * @property {string} [slug]
192
+ * @property {CreatedBySchema} [created_by]
193
+ * @property {boolean} [archived]
194
+ * @property {string} [page_type]
195
+ * @property {string} [created_on]
196
+ * @property {string} [modified_on]
197
+ * @property {number} [__v]
198
+ */
199
+
200
+ /**
201
+ * @typedef NavItemSchema
202
+ * @property {string} [title]
203
+ * @property {string} [link]
204
+ * @property {string} [href]
205
+ */
206
+
207
+ /**
208
+ * @typedef NavbarSchema
209
+ * @property {string} [_id]
210
+ * @property {NavItemSchema[]} [items]
211
+ * @property {number} [__v]
212
+ * @property {CreatedBySchema} [modified_by]
213
+ */
214
+
215
+ /**
216
+ * @typedef MediaSchema
217
+ * @property {string} [url]
218
+ * @property {string} [type]
219
+ * @property {string} [alt]
220
+ * @property {string} [anchor_link]
221
+ */
222
+
223
+ /**
224
+ * @typedef CreatedBySchema
225
+ * @property {string} [user_id]
226
+ */
227
+
228
+ /**
229
+ * @typedef PricingBannerSchema
230
+ * @property {string} [_id]
231
+ * @property {MediaSchema} [web_banner]
232
+ * @property {MediaSchema} [mobile_banner]
233
+ * @property {boolean} [published]
234
+ * @property {CreatedBySchema} [created_by]
235
+ * @property {CreatedBySchema} [modified_by]
236
+ * @property {string} [created_on]
237
+ * @property {string} [modified_on]
238
+ * @property {number} [__v]
239
+ */
240
+
241
+ /**
242
+ * @typedef SdkReadmeSchema
243
+ * @property {string} [data]
244
+ */
245
+
246
+ /**
247
+ * @typedef TagsSchema
248
+ * @property {CustomItemSchema[]} [items]
249
+ * @property {PageSchema} [page]
250
+ */
251
+
252
+ /**
253
+ * @typedef CustomItemSchema
254
+ * @property {string} [_id]
255
+ * @property {string} [name]
256
+ * @property {string} [type]
257
+ * @property {string} [sub_type]
258
+ * @property {string} [position]
259
+ * @property {boolean} [archived]
260
+ * @property {UserSchema} [created_by]
261
+ * @property {string} [url]
262
+ * @property {string} [content]
263
+ * @property {string} [created_on]
264
+ * @property {string} [modified_on]
265
+ * @property {number} [__v]
266
+ */
267
+
268
+ /**
269
+ * @typedef PageSchema
270
+ * @property {string} [type]
271
+ * @property {number} [current]
272
+ * @property {number} [size]
273
+ * @property {number} [item_total]
274
+ * @property {boolean} [has_next]
275
+ */
276
+
277
+ /**
278
+ * @typedef UserSchema
279
+ * @property {string} [user_id]
280
+ */
281
+
3
282
  /**
4
283
  * @typedef CredentialSchema
5
- * @property {Object} [configuration]
284
+ * @property {string} [_id]
285
+ * @property {ConfigurationSchema} [configuration]
6
286
  * @property {string} [entity_type]
7
287
  * @property {string} [type]
8
288
  * @property {boolean} [is_enable]
289
+ * @property {string} [updated_at]
290
+ * @property {string} [created_at]
291
+ * @property {number} [__v]
292
+ */
293
+
294
+ /**
295
+ * @typedef ConfigurationSchema
296
+ * @property {string} [token]
297
+ * @property {string} [host]
9
298
  */
10
299
 
11
300
  /**
@@ -26,13 +315,370 @@ const Joi = require("joi");
26
315
  */
27
316
 
28
317
  class ContentPublicModel {
318
+ /** @returns {BasicDetailsPayloadSchema} */
319
+ static BasicDetailsPayloadSchema() {
320
+ return Joi.object({
321
+ name: Joi.string().allow(""),
322
+ logo_url: Joi.string().allow(""),
323
+ favicon_url: Joi.string().allow(""),
324
+ title: Joi.string().allow(""),
325
+ meta_title: Joi.string().allow(""),
326
+ meta_description: Joi.string().allow(""),
327
+ meta_image: Joi.string().allow(""),
328
+ whats_new: Joi.array().items(ContentPublicModel.WhatsNew()),
329
+ features: Joi.array().items(ContentPublicModel.Features()),
330
+ authentication: Joi.object().pattern(/\S/, Joi.any()),
331
+ business_account: ContentPublicModel.BusinessAccount(),
332
+ seller_support: ContentPublicModel.SellerSupport(),
333
+ copyright: Joi.string().allow(""),
334
+ address: Joi.string().allow(""),
335
+ documentation_url: Joi.string().allow(""),
336
+ faq_url: Joi.string().allow(""),
337
+ facebook_url: Joi.string().allow(""),
338
+ instagram_url: Joi.string().allow(""),
339
+ privacy_url: Joi.string().allow(""),
340
+ twitter_url: Joi.string().allow(""),
341
+ termsofservice_url: Joi.string().allow(""),
342
+ });
343
+ }
344
+
345
+ /** @returns {WhatsNew} */
346
+ static WhatsNew() {
347
+ return Joi.object({
348
+ description: Joi.string().allow(""),
349
+ });
350
+ }
351
+
352
+ /** @returns {Features} */
353
+ static Features() {
354
+ return Joi.object({
355
+ title: Joi.string().allow(""),
356
+ text: Joi.string().allow(""),
357
+ list: Joi.array().items(Joi.string().allow("")),
358
+ image: Joi.string().allow(""),
359
+ });
360
+ }
361
+
362
+ /** @returns {BusinessAccount} */
363
+ static BusinessAccount() {
364
+ return Joi.object({
365
+ is_limit: Joi.boolean(),
366
+ threshold: Joi.number(),
367
+ });
368
+ }
369
+
370
+ /** @returns {SellerSupport} */
371
+ static SellerSupport() {
372
+ return Joi.object({
373
+ email: Joi.string().allow(""),
374
+ phone_number: Joi.number(),
375
+ });
376
+ }
377
+
378
+ /** @returns {MenuSchema} */
379
+ static MenuSchema() {
380
+ return Joi.object({
381
+ sales_channel: ContentPublicModel.SalesChannelSchema(),
382
+ other_seller: ContentPublicModel.OtherSellerSchema(),
383
+ footer_content: ContentPublicModel.FooterContentSchema(),
384
+ can_create_business_account: Joi.boolean(),
385
+ company_level: Joi.array().items(
386
+ ContentPublicModel.CompanyLevelMenuItemSchema()
387
+ ),
388
+ application_level: Joi.array().items(
389
+ ContentPublicModel.ApplicationLevelMenuItemSchema()
390
+ ),
391
+ });
392
+ }
393
+
394
+ /** @returns {MenusSchema} */
395
+ static MenusSchema() {
396
+ return Joi.object({
397
+ _id: Joi.string().allow(""),
398
+ desktop: ContentPublicModel.MenuTypeSchema(),
399
+ mobile: ContentPublicModel.MenuTypeSchema(),
400
+ __v: Joi.number(),
401
+ });
402
+ }
403
+
404
+ /** @returns {MenuTypeSchema} */
405
+ static MenuTypeSchema() {
406
+ return Joi.object({
407
+ menu: ContentPublicModel.MenuSchema(),
408
+ });
409
+ }
410
+
411
+ /** @returns {CompanyLevelMenuItemSchema} */
412
+ static CompanyLevelMenuItemSchema() {
413
+ return Joi.object({
414
+ visible_on: ContentPublicModel.VisibleOnSchema(),
415
+ display: Joi.string().allow(""),
416
+ permissions: Joi.array().items(Joi.string().allow("")),
417
+ title: Joi.string().allow(""),
418
+ link: Joi.string().allow(""),
419
+ icon: Joi.string().allow(""),
420
+ is_disabled: Joi.boolean(),
421
+ child: Joi.array().items(Joi.link("#CompanyLevelMenuItemSchema")),
422
+ }).id("CompanyLevelMenuItemSchema");
423
+ }
424
+
425
+ /** @returns {ApplicationLevelMenuItemSchema} */
426
+ static ApplicationLevelMenuItemSchema() {
427
+ return Joi.object({
428
+ visible_on: ContentPublicModel.VisibleOnSchema(),
429
+ display: Joi.string().allow(""),
430
+ permissions: Joi.array().items(Joi.string().allow("")),
431
+ title: Joi.string().allow(""),
432
+ link: Joi.string().allow(""),
433
+ icon: Joi.string().allow(""),
434
+ is_disabled: Joi.boolean(),
435
+ child: Joi.array().items(Joi.link("#ApplicationLevelMenuItemSchema")),
436
+ }).id("ApplicationLevelMenuItemSchema");
437
+ }
438
+
439
+ /** @returns {VisibleOnSchema} */
440
+ static VisibleOnSchema() {
441
+ return Joi.object({
442
+ web: Joi.boolean(),
443
+ ios: Joi.boolean(),
444
+ android: Joi.boolean(),
445
+ });
446
+ }
447
+
448
+ /** @returns {SalesChannelSchema} */
449
+ static SalesChannelSchema() {
450
+ return Joi.object({
451
+ can_add: Joi.boolean(),
452
+ title: Joi.string().allow(""),
453
+ });
454
+ }
455
+
456
+ /** @returns {OtherSellerSchema} */
457
+ static OtherSellerSchema() {
458
+ return Joi.object({
459
+ is_visible: Joi.boolean(),
460
+ title: Joi.string().allow(""),
461
+ });
462
+ }
463
+
464
+ /** @returns {FooterContentSchema} */
465
+ static FooterContentSchema() {
466
+ return Joi.object({
467
+ is_visible: Joi.boolean(),
468
+ line_one: Joi.string().allow(""),
469
+ line_two: Joi.string().allow(""),
470
+ });
471
+ }
472
+
473
+ /** @returns {AnalyticsTagsSchema} */
474
+ static AnalyticsTagsSchema() {
475
+ return Joi.object({
476
+ _id: Joi.string().allow(""),
477
+ __v: Joi.number(),
478
+ body_code: Joi.string().allow(""),
479
+ enabled: Joi.boolean(),
480
+ header_code: Joi.string().allow(""),
481
+ name: Joi.string().allow(""),
482
+ });
483
+ }
484
+
485
+ /** @returns {CustomPageBySlugSchema} */
486
+ static CustomPageBySlugSchema() {
487
+ return Joi.object({
488
+ _id: Joi.string().allow(""),
489
+ title: Joi.string().allow(""),
490
+ slug: Joi.string().allow(""),
491
+ type: Joi.string().allow(""),
492
+ description: Joi.string().allow(""),
493
+ published: Joi.boolean(),
494
+ content: Joi.array().items(ContentPublicModel.ItemSchema()),
495
+ seo: ContentPublicModel.CreateCustomPageSeoSchema(),
496
+ created_by: ContentPublicModel.CreatedBySchema(),
497
+ modified_by: ContentPublicModel.CreatedBySchema(),
498
+ archived: Joi.boolean(),
499
+ created_on: Joi.string().allow(""),
500
+ modified_on: Joi.string().allow(""),
501
+ __v: Joi.number(),
502
+ });
503
+ }
504
+
505
+ /** @returns {ItemSchema} */
506
+ static ItemSchema() {
507
+ return Joi.object({
508
+ type: Joi.string().allow(""),
509
+ value: Joi.string().allow(""),
510
+ });
511
+ }
512
+
513
+ /** @returns {CreateCustomPageSeoSchema} */
514
+ static CreateCustomPageSeoSchema() {
515
+ return Joi.object({
516
+ title: Joi.string().allow(""),
517
+ description: Joi.string().allow(""),
518
+ });
519
+ }
520
+
521
+ /** @returns {RawHtmlContentSchema} */
522
+ static RawHtmlContentSchema() {
523
+ return Joi.object({
524
+ type: Joi.string().allow(""),
525
+ value: Joi.string().allow(""),
526
+ });
527
+ }
528
+
529
+ /** @returns {FooterSchema} */
530
+ static FooterSchema() {
531
+ return Joi.object({
532
+ _id: Joi.string().allow(""),
533
+ title: Joi.string().allow(""),
534
+ description: Joi.string().allow(""),
535
+ type: Joi.string().allow(""),
536
+ tags: Joi.array().items(Joi.any()),
537
+ published: Joi.boolean(),
538
+ content: Joi.array().items(ContentPublicModel.RawHtmlContentSchema()),
539
+ footer_meta: Joi.array().items(Joi.any()),
540
+ created_by: ContentPublicModel.CreatedBySchema(),
541
+ modified_by: ContentPublicModel.CreatedBySchema(),
542
+ archived: Joi.boolean(),
543
+ __v: Joi.number(),
544
+ });
545
+ }
546
+
547
+ /** @returns {HomePageContentSchema} */
548
+ static HomePageContentSchema() {
549
+ return Joi.object({
550
+ _id: Joi.string().allow(""),
551
+ slug: Joi.string().allow(""),
552
+ created_by: ContentPublicModel.CreatedBySchema(),
553
+ archived: Joi.boolean(),
554
+ page_type: Joi.string().allow(""),
555
+ created_on: Joi.string().allow(""),
556
+ modified_on: Joi.string().allow(""),
557
+ __v: Joi.number(),
558
+ });
559
+ }
560
+
561
+ /** @returns {NavItemSchema} */
562
+ static NavItemSchema() {
563
+ return Joi.object({
564
+ title: Joi.string().allow(""),
565
+ link: Joi.string().allow(""),
566
+ href: Joi.string().allow(""),
567
+ });
568
+ }
569
+
570
+ /** @returns {NavbarSchema} */
571
+ static NavbarSchema() {
572
+ return Joi.object({
573
+ _id: Joi.string().allow(""),
574
+ items: Joi.array().items(ContentPublicModel.NavItemSchema()),
575
+ __v: Joi.number(),
576
+ modified_by: ContentPublicModel.CreatedBySchema(),
577
+ });
578
+ }
579
+
580
+ /** @returns {MediaSchema} */
581
+ static MediaSchema() {
582
+ return Joi.object({
583
+ url: Joi.string().allow(""),
584
+ type: Joi.string().allow(""),
585
+ alt: Joi.string().allow(""),
586
+ anchor_link: Joi.string().allow(""),
587
+ });
588
+ }
589
+
590
+ /** @returns {CreatedBySchema} */
591
+ static CreatedBySchema() {
592
+ return Joi.object({
593
+ user_id: Joi.string().allow(""),
594
+ });
595
+ }
596
+
597
+ /** @returns {PricingBannerSchema} */
598
+ static PricingBannerSchema() {
599
+ return Joi.object({
600
+ _id: Joi.string().allow(""),
601
+ web_banner: ContentPublicModel.MediaSchema(),
602
+ mobile_banner: ContentPublicModel.MediaSchema(),
603
+ published: Joi.boolean(),
604
+ created_by: ContentPublicModel.CreatedBySchema(),
605
+ modified_by: ContentPublicModel.CreatedBySchema(),
606
+ created_on: Joi.string().allow(""),
607
+ modified_on: Joi.string().allow(""),
608
+ __v: Joi.number(),
609
+ });
610
+ }
611
+
612
+ /** @returns {SdkReadmeSchema} */
613
+ static SdkReadmeSchema() {
614
+ return Joi.object({
615
+ data: Joi.string().allow(""),
616
+ });
617
+ }
618
+
619
+ /** @returns {TagsSchema} */
620
+ static TagsSchema() {
621
+ return Joi.object({
622
+ items: Joi.array().items(ContentPublicModel.CustomItemSchema()),
623
+ page: ContentPublicModel.PageSchema(),
624
+ });
625
+ }
626
+
627
+ /** @returns {CustomItemSchema} */
628
+ static CustomItemSchema() {
629
+ return Joi.object({
630
+ _id: Joi.string().allow(""),
631
+ name: Joi.string().allow(""),
632
+ type: Joi.string().allow(""),
633
+ sub_type: Joi.string().allow(""),
634
+ position: Joi.string().allow(""),
635
+ archived: Joi.boolean(),
636
+ created_by: ContentPublicModel.UserSchema(),
637
+ url: Joi.string().allow(""),
638
+ content: Joi.string().allow(""),
639
+ created_on: Joi.string().allow(""),
640
+ modified_on: Joi.string().allow(""),
641
+ __v: Joi.number(),
642
+ });
643
+ }
644
+
645
+ /** @returns {PageSchema} */
646
+ static PageSchema() {
647
+ return Joi.object({
648
+ type: Joi.string().allow(""),
649
+ current: Joi.number(),
650
+ size: Joi.number(),
651
+ item_total: Joi.number(),
652
+ has_next: Joi.boolean(),
653
+ });
654
+ }
655
+
656
+ /** @returns {UserSchema} */
657
+ static UserSchema() {
658
+ return Joi.object({
659
+ user_id: Joi.string().allow(""),
660
+ });
661
+ }
662
+
29
663
  /** @returns {CredentialSchema} */
30
664
  static CredentialSchema() {
31
665
  return Joi.object({
32
- configuration: Joi.any(),
666
+ _id: Joi.string().allow(""),
667
+ configuration: ContentPublicModel.ConfigurationSchema(),
33
668
  entity_type: Joi.string().allow(""),
34
669
  type: Joi.string().allow(""),
35
670
  is_enable: Joi.boolean(),
671
+ updated_at: Joi.string().allow(""),
672
+ created_at: Joi.string().allow(""),
673
+ __v: Joi.number(),
674
+ });
675
+ }
676
+
677
+ /** @returns {ConfigurationSchema} */
678
+ static ConfigurationSchema() {
679
+ return Joi.object({
680
+ token: Joi.string().allow(""),
681
+ host: Joi.string().allow(""),
36
682
  });
37
683
  }
38
684
 
@@ -53,7 +699,7 @@ class ContentPublicModel {
53
699
  info: Joi.string().allow(""),
54
700
  request_id: Joi.string().allow(""),
55
701
  stack_trace: Joi.string().allow(""),
56
- meta: Joi.any(),
702
+ meta: Joi.object().pattern(/\S/, Joi.any()),
57
703
  });
58
704
  }
59
705
  }