@gofynd/fdk-client-javascript 1.4.15-beta.14 → 1.4.15-beta.15

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 (278) hide show
  1. package/README.md +23 -26
  2. package/package.json +5 -1
  3. package/sdk/application/ApplicationClient.d.ts +5 -6
  4. package/sdk/application/ApplicationClient.js +24 -20
  5. package/sdk/application/Cart/CartApplicationClient.d.ts +133 -83
  6. package/sdk/application/Cart/CartApplicationClient.js +444 -76
  7. package/sdk/application/Catalog/CatalogApplicationClient.d.ts +132 -114
  8. package/sdk/application/Catalog/CatalogApplicationClient.js +209 -126
  9. package/sdk/application/Common/CommonApplicationClient.d.ts +4 -4
  10. package/sdk/application/Common/CommonApplicationClient.js +4 -4
  11. package/sdk/application/Communication/CommunicationApplicationClient.d.ts +3 -3
  12. package/sdk/application/Communication/CommunicationApplicationClient.js +3 -3
  13. package/sdk/application/Configuration/ConfigurationApplicationClient.d.ts +58 -36
  14. package/sdk/application/Configuration/ConfigurationApplicationClient.js +73 -29
  15. package/sdk/application/Content/ContentApplicationClient.d.ts +95 -66
  16. package/sdk/application/Content/ContentApplicationClient.js +274 -111
  17. package/sdk/application/FileStorage/FileStorageApplicationClient.d.ts +11 -11
  18. package/sdk/application/FileStorage/FileStorageApplicationClient.js +10 -10
  19. package/sdk/application/Finance/FinanceApplicationClient.d.ts +29 -0
  20. package/sdk/application/Finance/FinanceApplicationClient.js +111 -0
  21. package/sdk/application/Lead/LeadApplicationClient.d.ts +7 -7
  22. package/sdk/application/Lead/LeadApplicationClient.js +6 -6
  23. package/sdk/application/Logistic/LogisticApplicationClient.d.ts +37 -57
  24. package/sdk/application/Logistic/LogisticApplicationClient.js +117 -180
  25. package/sdk/application/Order/OrderApplicationClient.d.ts +63 -21
  26. package/sdk/application/Order/OrderApplicationClient.js +217 -17
  27. package/sdk/application/Payment/PaymentApplicationClient.d.ts +179 -149
  28. package/sdk/application/Payment/PaymentApplicationClient.js +301 -167
  29. package/sdk/application/Share/ShareApplicationClient.d.ts +7 -7
  30. package/sdk/application/Share/ShareApplicationClient.js +7 -7
  31. package/sdk/application/Theme/ThemeApplicationClient.d.ts +7 -7
  32. package/sdk/application/Theme/ThemeApplicationClient.js +10 -6
  33. package/sdk/application/User/UserApplicationClient.d.ts +103 -53
  34. package/sdk/application/User/UserApplicationClient.js +308 -49
  35. package/sdk/common/AxiosHelper.js +11 -4
  36. package/sdk/common/Constant.d.ts +27 -4
  37. package/sdk/common/Constant.js +33 -6
  38. package/sdk/common/utils.d.ts +10 -0
  39. package/sdk/common/utils.js +24 -3
  40. package/sdk/partner/FileStorage/FileStoragePartnerClient.d.ts +46 -16
  41. package/sdk/partner/FileStorage/FileStoragePartnerClient.js +266 -40
  42. package/sdk/partner/FileStorage/FileStoragePartnerModel.d.ts +163 -19
  43. package/sdk/partner/FileStorage/FileStoragePartnerModel.js +158 -14
  44. package/sdk/partner/FileStorage/FileStoragePartnerValidator.d.ts +5 -2
  45. package/sdk/partner/FileStorage/FileStoragePartnerValidator.js +23 -7
  46. package/sdk/partner/Lead/LeadPartnerClient.d.ts +9 -9
  47. package/sdk/partner/Lead/LeadPartnerClient.js +9 -9
  48. package/sdk/partner/Lead/LeadPartnerModel.d.ts +14 -9
  49. package/sdk/partner/Lead/LeadPartnerModel.js +19 -17
  50. package/sdk/partner/Logistics/LogisticsPartnerClient.d.ts +264 -49
  51. package/sdk/partner/Logistics/LogisticsPartnerClient.js +2116 -252
  52. package/sdk/partner/Logistics/LogisticsPartnerModel.d.ts +2256 -258
  53. package/sdk/partner/Logistics/LogisticsPartnerModel.js +1187 -230
  54. package/sdk/partner/Logistics/LogisticsPartnerValidator.d.ts +21 -1
  55. package/sdk/partner/Logistics/LogisticsPartnerValidator.js +218 -13
  56. package/sdk/partner/PartnerClient.d.ts +5 -2
  57. package/sdk/partner/PartnerClient.js +21 -7
  58. package/sdk/partner/Theme/ThemePartnerClient.d.ts +32 -34
  59. package/sdk/partner/Theme/ThemePartnerClient.js +42 -44
  60. package/sdk/partner/Theme/ThemePartnerModel.d.ts +142 -43
  61. package/sdk/partner/Theme/ThemePartnerModel.js +129 -44
  62. package/sdk/partner/Theme/ThemePartnerValidator.js +4 -4
  63. package/sdk/partner/Webhook/WebhookPartnerClient.d.ts +83 -27
  64. package/sdk/partner/Webhook/WebhookPartnerClient.js +446 -27
  65. package/sdk/partner/Webhook/WebhookPartnerModel.d.ts +920 -185
  66. package/sdk/partner/Webhook/WebhookPartnerModel.js +462 -154
  67. package/sdk/partner/Webhook/WebhookPartnerValidator.d.ts +5 -0
  68. package/sdk/partner/Webhook/WebhookPartnerValidator.js +41 -3
  69. package/sdk/platform/Analytics/AnalyticsPlatformApplicationClient.d.ts +8 -7
  70. package/sdk/platform/Analytics/AnalyticsPlatformApplicationClient.js +17 -11
  71. package/sdk/platform/Analytics/AnalyticsPlatformApplicationValidator.d.ts +4 -1
  72. package/sdk/platform/Analytics/AnalyticsPlatformApplicationValidator.js +1 -1
  73. package/sdk/platform/Analytics/AnalyticsPlatformModel.d.ts +68 -13
  74. package/sdk/platform/Analytics/AnalyticsPlatformModel.js +44 -6
  75. package/sdk/platform/AuditTrail/AuditTrailPlatformClient.d.ts +3 -33
  76. package/sdk/platform/AuditTrail/AuditTrailPlatformClient.js +4 -244
  77. package/sdk/platform/AuditTrail/AuditTrailPlatformModel.d.ts +49 -145
  78. package/sdk/platform/AuditTrail/AuditTrailPlatformModel.js +20 -171
  79. package/sdk/platform/AuditTrail/AuditTrailPlatformValidator.d.ts +1 -39
  80. package/sdk/platform/AuditTrail/AuditTrailPlatformValidator.js +0 -35
  81. package/sdk/platform/Billing/BillingPlatformClient.d.ts +15 -15
  82. package/sdk/platform/Billing/BillingPlatformClient.js +18 -18
  83. package/sdk/platform/Billing/BillingPlatformModel.d.ts +443 -388
  84. package/sdk/platform/Billing/BillingPlatformModel.js +280 -263
  85. package/sdk/platform/Billing/BillingPlatformValidator.d.ts +16 -18
  86. package/sdk/platform/Billing/BillingPlatformValidator.js +8 -9
  87. package/sdk/platform/Cart/CartPlatformApplicationClient.d.ts +266 -203
  88. package/sdk/platform/Cart/CartPlatformApplicationClient.js +1446 -500
  89. package/sdk/platform/Cart/CartPlatformApplicationValidator.d.ts +729 -100
  90. package/sdk/platform/Cart/CartPlatformApplicationValidator.js +446 -82
  91. package/sdk/platform/Cart/CartPlatformModel.d.ts +6927 -1396
  92. package/sdk/platform/Cart/CartPlatformModel.js +3065 -1316
  93. package/sdk/platform/Catalog/CatalogPlatformApplicationClient.d.ts +433 -248
  94. package/sdk/platform/Catalog/CatalogPlatformApplicationClient.js +1662 -559
  95. package/sdk/platform/Catalog/CatalogPlatformApplicationValidator.d.ts +464 -159
  96. package/sdk/platform/Catalog/CatalogPlatformApplicationValidator.js +304 -87
  97. package/sdk/platform/Catalog/CatalogPlatformClient.d.ts +383 -234
  98. package/sdk/platform/Catalog/CatalogPlatformClient.js +2475 -1557
  99. package/sdk/platform/Catalog/CatalogPlatformModel.d.ts +9573 -2678
  100. package/sdk/platform/Catalog/CatalogPlatformModel.js +5033 -1973
  101. package/sdk/platform/Catalog/CatalogPlatformValidator.d.ts +364 -117
  102. package/sdk/platform/Catalog/CatalogPlatformValidator.js +281 -104
  103. package/sdk/platform/Common/CommonPlatformClient.d.ts +5 -4
  104. package/sdk/platform/Common/CommonPlatformClient.js +6 -5
  105. package/sdk/platform/Common/CommonPlatformModel.d.ts +36 -25
  106. package/sdk/platform/Common/CommonPlatformModel.js +25 -14
  107. package/sdk/platform/Communication/CommunicationPlatformApplicationClient.d.ts +80 -153
  108. package/sdk/platform/Communication/CommunicationPlatformApplicationClient.js +102 -541
  109. package/sdk/platform/Communication/CommunicationPlatformApplicationValidator.d.ts +36 -49
  110. package/sdk/platform/Communication/CommunicationPlatformApplicationValidator.js +20 -60
  111. package/sdk/platform/Communication/CommunicationPlatformClient.d.ts +1 -1
  112. package/sdk/platform/Communication/CommunicationPlatformClient.js +1 -1
  113. package/sdk/platform/Communication/CommunicationPlatformModel.d.ts +189 -43
  114. package/sdk/platform/Communication/CommunicationPlatformModel.js +165 -42
  115. package/sdk/platform/CompanyProfile/CompanyProfilePlatformClient.d.ts +58 -81
  116. package/sdk/platform/CompanyProfile/CompanyProfilePlatformClient.js +68 -116
  117. package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.d.ts +291 -249
  118. package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.js +243 -234
  119. package/sdk/platform/CompanyProfile/CompanyProfilePlatformValidator.d.ts +12 -12
  120. package/sdk/platform/CompanyProfile/CompanyProfilePlatformValidator.js +12 -12
  121. package/sdk/platform/Configuration/ConfigurationPlatformApplicationClient.d.ts +78 -65
  122. package/sdk/platform/Configuration/ConfigurationPlatformApplicationClient.js +101 -88
  123. package/sdk/platform/Configuration/ConfigurationPlatformApplicationValidator.d.ts +20 -20
  124. package/sdk/platform/Configuration/ConfigurationPlatformApplicationValidator.js +19 -19
  125. package/sdk/platform/Configuration/ConfigurationPlatformClient.d.ts +68 -34
  126. package/sdk/platform/Configuration/ConfigurationPlatformClient.js +174 -41
  127. package/sdk/platform/Configuration/ConfigurationPlatformModel.d.ts +667 -244
  128. package/sdk/platform/Configuration/ConfigurationPlatformModel.js +474 -155
  129. package/sdk/platform/Configuration/ConfigurationPlatformValidator.d.ts +37 -9
  130. package/sdk/platform/Configuration/ConfigurationPlatformValidator.js +27 -8
  131. package/sdk/platform/Content/ContentPlatformApplicationClient.d.ts +366 -280
  132. package/sdk/platform/Content/ContentPlatformApplicationClient.js +1435 -753
  133. package/sdk/platform/Content/ContentPlatformApplicationValidator.d.ts +323 -223
  134. package/sdk/platform/Content/ContentPlatformApplicationValidator.js +335 -205
  135. package/sdk/platform/Content/ContentPlatformClient.d.ts +304 -106
  136. package/sdk/platform/Content/ContentPlatformClient.js +1842 -450
  137. package/sdk/platform/Content/ContentPlatformModel.d.ts +2582 -566
  138. package/sdk/platform/Content/ContentPlatformModel.js +1426 -558
  139. package/sdk/platform/Content/ContentPlatformValidator.d.ts +293 -114
  140. package/sdk/platform/Content/ContentPlatformValidator.js +328 -101
  141. package/sdk/platform/Discount/DiscountPlatformClient.d.ts +59 -23
  142. package/sdk/platform/Discount/DiscountPlatformClient.js +84 -23
  143. package/sdk/platform/Discount/DiscountPlatformModel.d.ts +403 -110
  144. package/sdk/platform/Discount/DiscountPlatformModel.js +121 -107
  145. package/sdk/platform/Discount/DiscountPlatformValidator.d.ts +56 -36
  146. package/sdk/platform/Discount/DiscountPlatformValidator.js +29 -19
  147. package/sdk/platform/FileStorage/FileStoragePlatformApplicationClient.d.ts +12 -110
  148. package/sdk/platform/FileStorage/FileStoragePlatformApplicationClient.js +14 -684
  149. package/sdk/platform/FileStorage/FileStoragePlatformApplicationValidator.d.ts +5 -94
  150. package/sdk/platform/FileStorage/FileStoragePlatformApplicationValidator.js +4 -115
  151. package/sdk/platform/FileStorage/FileStoragePlatformClient.d.ts +20 -20
  152. package/sdk/platform/FileStorage/FileStoragePlatformClient.js +22 -22
  153. package/sdk/platform/FileStorage/FileStoragePlatformModel.d.ts +90 -920
  154. package/sdk/platform/FileStorage/FileStoragePlatformModel.js +53 -949
  155. package/sdk/platform/FileStorage/FileStoragePlatformValidator.d.ts +6 -6
  156. package/sdk/platform/FileStorage/FileStoragePlatformValidator.js +6 -6
  157. package/sdk/platform/Lead/LeadPlatformApplicationClient.d.ts +10 -10
  158. package/sdk/platform/Lead/LeadPlatformApplicationClient.js +10 -10
  159. package/sdk/platform/Lead/LeadPlatformClient.d.ts +11 -11
  160. package/sdk/platform/Lead/LeadPlatformClient.js +11 -11
  161. package/sdk/platform/Lead/LeadPlatformModel.d.ts +14 -9
  162. package/sdk/platform/Lead/LeadPlatformModel.js +20 -18
  163. package/sdk/platform/Order/OrderPlatformApplicationClient.d.ts +56 -9
  164. package/sdk/platform/Order/OrderPlatformApplicationClient.js +340 -10
  165. package/sdk/platform/Order/OrderPlatformApplicationValidator.d.ts +128 -24
  166. package/sdk/platform/Order/OrderPlatformApplicationValidator.js +81 -19
  167. package/sdk/platform/Order/OrderPlatformClient.d.ts +517 -160
  168. package/sdk/platform/Order/OrderPlatformClient.js +1623 -384
  169. package/sdk/platform/Order/OrderPlatformModel.d.ts +10372 -1587
  170. package/sdk/platform/Order/OrderPlatformModel.js +5726 -1512
  171. package/sdk/platform/Order/OrderPlatformValidator.d.ts +539 -123
  172. package/sdk/platform/Order/OrderPlatformValidator.js +323 -92
  173. package/sdk/platform/Partner/PartnerPlatformApplicationClient.d.ts +8 -6
  174. package/sdk/platform/Partner/PartnerPlatformApplicationClient.js +11 -9
  175. package/sdk/platform/Partner/PartnerPlatformApplicationValidator.d.ts +6 -4
  176. package/sdk/platform/Partner/PartnerPlatformApplicationValidator.js +3 -2
  177. package/sdk/platform/Partner/PartnerPlatformModel.d.ts +77 -25
  178. package/sdk/platform/Partner/PartnerPlatformModel.js +32 -21
  179. package/sdk/platform/Payment/PaymentPlatformApplicationClient.d.ts +144 -219
  180. package/sdk/platform/Payment/PaymentPlatformApplicationClient.js +307 -796
  181. package/sdk/platform/Payment/PaymentPlatformApplicationValidator.d.ts +86 -121
  182. package/sdk/platform/Payment/PaymentPlatformApplicationValidator.js +80 -138
  183. package/sdk/platform/Payment/PaymentPlatformClient.d.ts +30 -30
  184. package/sdk/platform/Payment/PaymentPlatformClient.js +30 -30
  185. package/sdk/platform/Payment/PaymentPlatformModel.d.ts +901 -761
  186. package/sdk/platform/Payment/PaymentPlatformModel.js +663 -583
  187. package/sdk/platform/Payment/PaymentPlatformValidator.d.ts +8 -8
  188. package/sdk/platform/Payment/PaymentPlatformValidator.js +8 -8
  189. package/sdk/platform/PlatformApplicationClient.d.ts +0 -2
  190. package/sdk/platform/PlatformApplicationClient.js +0 -4
  191. package/sdk/platform/PlatformClient.d.ts +5 -4
  192. package/sdk/platform/PlatformClient.js +32 -22
  193. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationClient.d.ts +526 -69
  194. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationClient.js +3337 -337
  195. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationValidator.d.ts +603 -38
  196. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationValidator.js +529 -32
  197. package/sdk/platform/Serviceability/ServiceabilityPlatformClient.d.ts +184 -133
  198. package/sdk/platform/Serviceability/ServiceabilityPlatformClient.js +780 -491
  199. package/sdk/platform/Serviceability/ServiceabilityPlatformModel.d.ts +9408 -1666
  200. package/sdk/platform/Serviceability/ServiceabilityPlatformModel.js +5720 -1765
  201. package/sdk/platform/Serviceability/ServiceabilityPlatformValidator.d.ts +257 -180
  202. package/sdk/platform/Serviceability/ServiceabilityPlatformValidator.js +185 -127
  203. package/sdk/platform/Share/SharePlatformApplicationClient.d.ts +7 -7
  204. package/sdk/platform/Share/SharePlatformApplicationClient.js +7 -7
  205. package/sdk/platform/Share/SharePlatformModel.d.ts +45 -9
  206. package/sdk/platform/Share/SharePlatformModel.js +31 -6
  207. package/sdk/platform/Theme/ThemePlatformApplicationClient.d.ts +26 -26
  208. package/sdk/platform/Theme/ThemePlatformApplicationClient.js +38 -29
  209. package/sdk/platform/Theme/ThemePlatformApplicationValidator.d.ts +18 -3
  210. package/sdk/platform/Theme/ThemePlatformApplicationValidator.js +10 -2
  211. package/sdk/platform/Theme/ThemePlatformClient.d.ts +4 -4
  212. package/sdk/platform/Theme/ThemePlatformClient.js +4 -4
  213. package/sdk/platform/Theme/ThemePlatformModel.d.ts +103 -17
  214. package/sdk/platform/Theme/ThemePlatformModel.js +92 -23
  215. package/sdk/platform/User/UserPlatformApplicationClient.d.ts +167 -45
  216. package/sdk/platform/User/UserPlatformApplicationClient.js +950 -67
  217. package/sdk/platform/User/UserPlatformApplicationValidator.d.ts +189 -3
  218. package/sdk/platform/User/UserPlatformApplicationValidator.js +157 -3
  219. package/sdk/platform/User/UserPlatformModel.d.ts +880 -47
  220. package/sdk/platform/User/UserPlatformModel.js +607 -46
  221. package/sdk/platform/Webhook/WebhookPlatformClient.d.ts +33 -86
  222. package/sdk/platform/Webhook/WebhookPlatformClient.js +79 -474
  223. package/sdk/platform/Webhook/WebhookPlatformModel.d.ts +861 -422
  224. package/sdk/platform/Webhook/WebhookPlatformModel.js +469 -391
  225. package/sdk/platform/Webhook/WebhookPlatformValidator.d.ts +10 -55
  226. package/sdk/platform/Webhook/WebhookPlatformValidator.js +12 -72
  227. package/sdk/platform/index.d.ts +0 -2
  228. package/sdk/platform/index.js +0 -4
  229. package/sdk/public/Catalog/CatalogPublicClient.d.ts +22 -0
  230. package/sdk/public/Catalog/CatalogPublicClient.js +133 -0
  231. package/sdk/public/Catalog/CatalogPublicModel.d.ts +158 -0
  232. package/sdk/public/Catalog/CatalogPublicModel.js +116 -0
  233. package/sdk/public/Catalog/CatalogPublicValidator.d.ts +55 -0
  234. package/sdk/public/Catalog/CatalogPublicValidator.js +35 -0
  235. package/sdk/public/Configuration/ConfigurationPublicClient.d.ts +5 -4
  236. package/sdk/public/Configuration/ConfigurationPublicClient.js +9 -8
  237. package/sdk/public/Configuration/ConfigurationPublicModel.d.ts +41 -21
  238. package/sdk/public/Configuration/ConfigurationPublicModel.js +28 -12
  239. package/sdk/public/Content/ContentPublicClient.d.ts +145 -2
  240. package/sdk/public/Content/ContentPublicClient.js +1067 -17
  241. package/sdk/public/Content/ContentPublicModel.d.ts +704 -3
  242. package/sdk/public/Content/ContentPublicModel.js +751 -3
  243. package/sdk/public/Content/ContentPublicValidator.d.ts +94 -3
  244. package/sdk/public/Content/ContentPublicValidator.js +119 -2
  245. package/sdk/public/Partner/PartnerPublicClient.d.ts +1 -1
  246. package/sdk/public/Partner/PartnerPublicClient.js +1 -1
  247. package/sdk/public/Partner/PartnerPublicModel.d.ts +248 -72
  248. package/sdk/public/Partner/PartnerPublicModel.js +81 -71
  249. package/sdk/public/Partner/PartnerPublicValidator.d.ts +2 -2
  250. package/sdk/public/Partner/PartnerPublicValidator.js +1 -1
  251. package/sdk/public/PublicClient.d.ts +5 -2
  252. package/sdk/public/PublicClient.js +16 -6
  253. package/sdk/public/Webhook/WebhookPublicClient.d.ts +13 -13
  254. package/sdk/public/Webhook/WebhookPublicClient.js +13 -13
  255. package/sdk/public/Webhook/WebhookPublicModel.d.ts +249 -67
  256. package/sdk/public/Webhook/WebhookPublicModel.js +81 -61
  257. package/sdk/public/Webhook/WebhookPublicValidator.d.ts +4 -4
  258. package/sdk/public/Webhook/WebhookPublicValidator.js +4 -4
  259. package/sdk/public/index.d.ts +1 -0
  260. package/sdk/public/index.js +2 -0
  261. package/utility.d.ts +3 -0
  262. package/utility.js +7 -0
  263. package/sdk/application/Rewards/RewardsApplicationClient.d.ts +0 -79
  264. package/sdk/application/Rewards/RewardsApplicationClient.js +0 -315
  265. package/sdk/application/Webhook/WebhookApplicationClient.d.ts +0 -19
  266. package/sdk/application/Webhook/WebhookApplicationClient.js +0 -72
  267. package/sdk/platform/Finance/FinancePlatformClient.d.ts +0 -320
  268. package/sdk/platform/Finance/FinancePlatformClient.js +0 -2333
  269. package/sdk/platform/Finance/FinancePlatformModel.d.ts +0 -2890
  270. package/sdk/platform/Finance/FinancePlatformModel.js +0 -2148
  271. package/sdk/platform/Finance/FinancePlatformValidator.d.ts +0 -284
  272. package/sdk/platform/Finance/FinancePlatformValidator.js +0 -354
  273. package/sdk/platform/Rewards/RewardsPlatformApplicationClient.d.ts +0 -136
  274. package/sdk/platform/Rewards/RewardsPlatformApplicationClient.js +0 -976
  275. package/sdk/platform/Rewards/RewardsPlatformApplicationValidator.d.ts +0 -152
  276. package/sdk/platform/Rewards/RewardsPlatformApplicationValidator.js +0 -157
  277. package/sdk/platform/Rewards/RewardsPlatformModel.d.ts +0 -382
  278. package/sdk/platform/Rewards/RewardsPlatformModel.js +0 -408
@@ -1,7 +1,23 @@
1
1
  const Joi = require("joi");
2
2
 
3
3
  /**
4
- * @typedef PaymentGatewayConfigResponse
4
+ * @typedef AggregatorToken
5
+ * @property {number} payment_mode_id - Payment mode identifier Supported values are:
6
+ *
7
+ * - **4**: Wallet
8
+ * - **3**: Net Banking
9
+ * - **2**: Card
10
+ * - **1**: Pay Later
11
+ *
12
+ * @property {string} sub_payment_mode_code - Sub-payment method code
13
+ * @property {string} token - Token value to be saved for the aggregator
14
+ * @property {string} status - Status of the token verification
15
+ * @property {boolean} is_active - Enable or Disable Flag
16
+ * @property {string} domain - Name of domain
17
+ */
18
+
19
+ /**
20
+ * @typedef PaymentGatewayConfigDetails
5
21
  * @property {Object[]} [aggregators] - List of all config specific to the
6
22
  * aggregator with their Details.
7
23
  * @property {string} app_id - Application Id to which Payment config Mapped
@@ -29,7 +45,7 @@ const Joi = require("joi");
29
45
  */
30
46
 
31
47
  /**
32
- * @typedef PaymentGatewayConfigRequest
48
+ * @typedef PaymentGatewayConfigCreation
33
49
  * @property {string} app_id - Application Id to which Payment config Mapped
34
50
  * @property {boolean} [is_active] - Enable or Disable Flag
35
51
  * @property {PaymentGatewayConfig} [aggregator_name]
@@ -48,7 +64,7 @@ const Joi = require("joi");
48
64
  */
49
65
 
50
66
  /**
51
- * @typedef HttpErrorCodeAndResponse
67
+ * @typedef HttpErrorDetails
52
68
  * @property {ErrorCodeAndDescription} error
53
69
  * @property {boolean} success - Response is successful or not
54
70
  */
@@ -62,11 +78,11 @@ const Joi = require("joi");
62
78
  /**
63
79
  * @typedef ProductCODData
64
80
  * @property {Object} [items] - Item id with its cod availability.
65
- * @property {CODChargesLimitsResponse} [cod_charges]
81
+ * @property {CODChargesLimitsDetails} [cod_charges]
66
82
  */
67
83
 
68
84
  /**
69
- * @typedef CODChargesLimitsResponse
85
+ * @typedef CODChargesLimitsDetails
70
86
  * @property {number} [max_cart_value] - Max allowed cart value for cod order.
71
87
  * @property {number} [min_cart_value] - Min allowed cart value for cod order.
72
88
  * @property {number} [cod_charge] - Cod charges to be applied on order.
@@ -125,6 +141,16 @@ const Joi = require("joi");
125
141
  * @property {number} [exp_year] - Exp_year
126
142
  * @property {string} [name] - Name
127
143
  * @property {string[]} [intent_app_error_list] - Intent_app_error_list
144
+ * @property {PaymentConfirmationElement[]} [payment_confirmation_elements] -
145
+ * List of additional fields required to confirm the payment, such as
146
+ * transaction ID or receipt image.
147
+ */
148
+
149
+ /**
150
+ * @typedef PaymentConfirmationElement
151
+ * @property {boolean} [is_required]
152
+ * @property {string} [display_label]
153
+ * @property {string} [slug]
128
154
  */
129
155
 
130
156
  /**
@@ -166,17 +192,11 @@ const Joi = require("joi");
166
192
  * @typedef PaymentFlow
167
193
  * @property {AggregatorRoute} [bqr_razorpay]
168
194
  * @property {AggregatorRoute} [fynd]
169
- * @property {AggregatorRoute} [epaylater]
170
195
  * @property {AggregatorRoute} [razorpay]
171
196
  * @property {AggregatorRoute} [juspay]
172
- * @property {AggregatorRoute} [ajiodhan]
173
197
  * @property {AggregatorRoute} [simpl]
174
- * @property {AggregatorRoute} [rupifi]
175
- * @property {AggregatorRoute} [mswipe]
176
- * @property {AggregatorRoute} [stripe]
177
198
  * @property {AggregatorRoute} [ccavenue]
178
199
  * @property {AggregatorRoute} [payubiz]
179
- * @property {AggregatorRoute} [jiopay]
180
200
  */
181
201
 
182
202
  /**
@@ -221,7 +241,7 @@ const Joi = require("joi");
221
241
  */
222
242
 
223
243
  /**
224
- * @typedef PaymentModeRouteResponse
244
+ * @typedef PaymentModeRouteDetails
225
245
  * @property {PaymentOptionAndFlow} payment_options
226
246
  * @property {boolean} success - Response is successful or not
227
247
  * @property {Object} [payment_breakup] - Payment Breakup for advance payment
@@ -229,7 +249,7 @@ const Joi = require("joi");
229
249
  */
230
250
 
231
251
  /**
232
- * @typedef PaymentOptionsResponse
252
+ * @typedef PaymentOptionsDetails
233
253
  * @property {PaymentOptions} payment_options
234
254
  * @property {boolean} success - Response is successful or not
235
255
  * @property {Object} [payment_breakup] - Payment Breakup for advance payment
@@ -276,7 +296,7 @@ const Joi = require("joi");
276
296
  */
277
297
 
278
298
  /**
279
- * @typedef PayoutsResponse
299
+ * @typedef PayoutsDetails
280
300
  * @property {boolean} success - Response is successful or not
281
301
  * @property {Payout[]} items - Contains list of PayoutSchema
282
302
  */
@@ -296,7 +316,7 @@ const Joi = require("joi");
296
316
  */
297
317
 
298
318
  /**
299
- * @typedef PayoutRequest
319
+ * @typedef PayoutCreation
300
320
  * @property {string} aggregator - Aggregator Name
301
321
  * @property {Object} users - Payout users object
302
322
  * @property {string} unique_external_id - Unique Id of Payout
@@ -306,7 +326,7 @@ const Joi = require("joi");
306
326
  */
307
327
 
308
328
  /**
309
- * @typedef PayoutResponse
329
+ * @typedef PayoutDetails
310
330
  * @property {string} payment_status - Status of payment
311
331
  * @property {Object} users - Users details object
312
332
  * @property {string} aggregator - Aggregator Name
@@ -320,55 +340,55 @@ const Joi = require("joi");
320
340
  */
321
341
 
322
342
  /**
323
- * @typedef UpdatePayoutResponse
343
+ * @typedef UpdatePayoutDetails
324
344
  * @property {boolean} is_default - Enable or Disable Default Payout
325
345
  * @property {boolean} is_active - Enable or DIsable Flag Payout
326
346
  * @property {boolean} success - Response is successful or not
327
347
  */
328
348
 
329
349
  /**
330
- * @typedef UpdatePayoutRequest
350
+ * @typedef UpdatePayoutCreation
331
351
  * @property {boolean} is_default - Enable or Disable Default Payout
332
352
  * @property {boolean} is_active - Enable or Disable Flag Payout
333
353
  * @property {string} unique_external_id - Unique Id of Payout
334
354
  */
335
355
 
336
356
  /**
337
- * @typedef DeletePayoutResponse
357
+ * @typedef DeletePayoutDetails
338
358
  * @property {boolean} success - Response is successful or not
339
359
  */
340
360
 
341
361
  /**
342
- * @typedef SubscriptionPaymentMethodResponse
362
+ * @typedef SubscriptionPaymentMethodDetails
343
363
  * @property {Object[]} data - Subscription Payment Method Object
344
364
  * @property {boolean} success - Response is successful or not
345
365
  */
346
366
 
347
367
  /**
348
- * @typedef DeleteSubscriptionPaymentMethodResponse
368
+ * @typedef DeleteSubscriptionPaymentMethodDetails
349
369
  * @property {boolean} success - Success or failure.
350
370
  */
351
371
 
352
372
  /**
353
- * @typedef SubscriptionConfigResponse
373
+ * @typedef SubscriptionConfigDetails
354
374
  * @property {string} aggregator - Aggregator Name
355
375
  * @property {Object} config - Aggregator Config
356
376
  * @property {boolean} success - Response is successful or not
357
377
  */
358
378
 
359
379
  /**
360
- * @typedef SaveSubscriptionSetupIntentRequest
380
+ * @typedef SaveSubscriptionSetupIntentCreation
361
381
  * @property {string} unique_external_id - Unique id i.e company:id
362
382
  */
363
383
 
364
384
  /**
365
- * @typedef SaveSubscriptionSetupIntentResponse
385
+ * @typedef SaveSubscriptionSetupIntentDetails
366
386
  * @property {Object} data - Subscription Payment Method Object
367
387
  * @property {boolean} success - Response is successful or not
368
388
  */
369
389
 
370
390
  /**
371
- * @typedef RefundAccountResponse
391
+ * @typedef RefundAccountDetails
372
392
  * @property {boolean} [is_verified_flag] - Account is verified or not
373
393
  * @property {string} [message] - Response message
374
394
  * @property {Object} data - Refund account data.
@@ -384,21 +404,23 @@ const Joi = require("joi");
384
404
 
385
405
  /**
386
406
  * @typedef BankDetailsForOTP
387
- * @property {string} ifsc_code - IFSC code of account
388
- * @property {string} account_no - Account number
389
- * @property {string} branch_name - Branch name of account
390
- * @property {string} bank_name - Bank name of account
391
- * @property {string} account_holder - Accountg holder name of account
407
+ * @property {string} [ifsc_code] - IFSC code of account
408
+ * @property {string} [account_no] - Account number
409
+ * @property {string} [branch_name] - Branch name of account
410
+ * @property {string} [bank_name] - Bank name of account
411
+ * @property {string} [account_holder] - Accountg holder name of account
412
+ * @property {string} [upi] - UPI ID of account holder
392
413
  */
393
414
 
394
415
  /**
395
- * @typedef AddBeneficiaryDetailsOTPRequest
416
+ * @typedef AddBeneficiaryDetailsOTPCreation
396
417
  * @property {string} order_id - Order_id for which account will be added
418
+ * @property {string} [shipment_id] - Shipment_id for which account will be added
397
419
  * @property {BankDetailsForOTP} details
398
420
  */
399
421
 
400
422
  /**
401
- * @typedef IfscCodeResponse
423
+ * @typedef IfscCodeDetails
402
424
  * @property {string} branch_name - Branch Name Of Account
403
425
  * @property {boolean} [success] - Response is successful or not
404
426
  * @property {string} bank_name - Bank Name Of Account
@@ -428,7 +450,7 @@ const Joi = require("joi");
428
450
  */
429
451
 
430
452
  /**
431
- * @typedef OrderBeneficiaryResponse
453
+ * @typedef OrderBeneficiaryFetchResults
432
454
  * @property {OrderBeneficiaryDetails[]} [beneficiaries] - All Beneficiaries Of An Order
433
455
  * @property {boolean} [show_beneficiary_details] - Show beneficiary details or not.
434
456
  */
@@ -457,13 +479,13 @@ const Joi = require("joi");
457
479
  */
458
480
 
459
481
  /**
460
- * @typedef PaymentConfirmationRequest
482
+ * @typedef PaymentConfirmationCreation
461
483
  * @property {string} order_id - Unique order id
462
484
  * @property {MultiTenderPaymentMethod[]} payment_methods
463
485
  */
464
486
 
465
487
  /**
466
- * @typedef PaymentConfirmationResponse
488
+ * @typedef PaymentConfirmationDetails
467
489
  * @property {string} order_id - Unique order id
468
490
  * @property {string} message - Message
469
491
  * @property {boolean} success - Payment confirmation updated or not.
@@ -495,21 +517,21 @@ const Joi = require("joi");
495
517
  */
496
518
 
497
519
  /**
498
- * @typedef GetUserBULimitResponse
520
+ * @typedef GetUserBULimitResponseSchema
499
521
  * @property {string} business_unit - COD limit business unit
500
522
  * @property {string} display_name - Display name for cod limit
501
523
  * @property {CODPaymentLimitConfig} config
502
524
  */
503
525
 
504
526
  /**
505
- * @typedef GetUserCODLimitResponse
506
- * @property {GetUserBULimitResponse[]} items
527
+ * @typedef GetUserCODLimitDetails
528
+ * @property {GetUserBULimitResponseSchema[]} items
507
529
  * @property {boolean} success - Response is successful or not
508
530
  * @property {string} [message] - Message for cod limit
509
531
  */
510
532
 
511
533
  /**
512
- * @typedef SetCODForUserRequest
534
+ * @typedef SetCODForUserCreation
513
535
  * @property {string} [business_unit] - Business unit
514
536
  * @property {string} mobileno - Mobile No. of User
515
537
  * @property {boolean} is_active - Either true or false
@@ -517,112 +539,13 @@ const Joi = require("joi");
517
539
  */
518
540
 
519
541
  /**
520
- * @typedef SetCODOptionResponse
542
+ * @typedef SetCODOptionDetails
521
543
  * @property {string} message - Message
522
544
  * @property {boolean} success - Response is successful or not
523
545
  */
524
546
 
525
547
  /**
526
- * @typedef EdcModelData
527
- * @property {string} aggregator - Name of aggregator
528
- * @property {number} aggregator_id - ID of aggregator
529
- * @property {string[]} models - List of string of edc models
530
- */
531
-
532
- /**
533
- * @typedef EdcAggregatorAndModelListResponse
534
- * @property {EdcModelData[]} data - List of aggregators and their edc models
535
- * @property {boolean} success - Response is successful or not
536
- */
537
-
538
- /**
539
- * @typedef StatisticsData
540
- * @property {number} inactive_device_count - No of inactive devices
541
- * @property {number} active_device_count - No of active devices
542
- */
543
-
544
- /**
545
- * @typedef EdcDeviceStatsResponse
546
- * @property {StatisticsData} statistics
547
- * @property {boolean} success - Response is successful or not
548
- */
549
-
550
- /**
551
- * @typedef EdcAddRequest
552
- * @property {string} edc_model - Model of the edc machine
553
- * @property {number} store_id - Store at which devices is to used
554
- * @property {number} aggregator_id - Aggregator which will accept payment
555
- * @property {string} edc_device_serial_no - Serial number or imei of EDC device
556
- * @property {string} terminal_serial_no - Device serial number of
557
- * terminal(android tablet)
558
- * @property {string} [device_tag] - Device tag of edc device to identify it
559
- */
560
-
561
- /**
562
- * @typedef EdcDevice
563
- * @property {string} [edc_model] - Name of the model
564
- * @property {number} store_id - Store at which devices is to used
565
- * @property {number} aggregator_id - Aggregator which will accept payment
566
- * @property {string} terminal_unique_identifier - Genearated unique value for edc device
567
- * @property {string} edc_device_serial_no - Serial number of EDC device
568
- * @property {boolean} is_active - State whether device is active or inactive
569
- * @property {string} [aggregator_name] - Name of the corresponding aggregator
570
- * @property {string} terminal_serial_no - Device serial number of
571
- * terminal(android tablet)
572
- * @property {string} [merchant_store_pos_code] - This is provided by pinelabs
573
- * @property {string} device_tag - Device tag of edc device to identify it
574
- * @property {string} application_id - Application ID
575
- */
576
-
577
- /**
578
- * @typedef EdcDeviceAddResponse
579
- * @property {EdcDevice} data
580
- * @property {boolean} success - Response is successful or not
581
- */
582
-
583
- /**
584
- * @typedef EdcDeviceDetailsResponse
585
- * @property {EdcDevice} data
586
- * @property {boolean} success - Response is successful or not
587
- */
588
-
589
- /**
590
- * @typedef EdcUpdateRequest
591
- * @property {string} [edc_model] - Model of the edc machine
592
- * @property {number} [store_id] - Store at which devices is to used
593
- * @property {number} [aggregator_id] - Aggregator which will accept payment
594
- * @property {string} [edc_device_serial_no] - Serial number or imei of EDC device
595
- * @property {boolean} [is_active] - State whether device is active or inactive
596
- * @property {string} [merchant_store_pos_code] - This is provided by pinelabs
597
- * @property {string} [device_tag] - Device tag of edc device to identify it
598
- */
599
-
600
- /**
601
- * @typedef EdcDeviceUpdateResponse
602
- * @property {boolean} success - Response is successful or not
603
- */
604
-
605
- /**
606
- * @typedef Page
607
- * @property {number} [item_total] - The total number of items on the page.
608
- * @property {string} [next_id] - The identifier for the next page.
609
- * @property {boolean} [has_previous] - Indicates whether there is a previous page.
610
- * @property {boolean} [has_next] - Indicates whether there is a next page.
611
- * @property {number} [current] - The current page number.
612
- * @property {string} type - The type of the page, such as 'PageType'.
613
- * @property {number} [size] - The number of items per page.
614
- */
615
-
616
- /**
617
- * @typedef EdcDeviceListResponse
618
- * @property {EdcDevice[]} items - List of all edc mapped to the application
619
- * options with their Details.
620
- * @property {Page} page
621
- * @property {boolean} success - Response is successful or not
622
- */
623
-
624
- /**
625
- * @typedef PaymentInitializationRequest
548
+ * @typedef PaymentInitializationCreation
626
549
  * @property {string} [razorpay_payment_id] - Payment gateway payment id
627
550
  * @property {string} [device_id] - EDC machine Unique Identifier
628
551
  * @property {string} email - Customer valid email
@@ -639,7 +562,7 @@ const Joi = require("joi");
639
562
  */
640
563
 
641
564
  /**
642
- * @typedef PaymentInitializationResponse
565
+ * @typedef PaymentInitializationDetails
643
566
  * @property {string} [razorpay_payment_id] - Payment id.
644
567
  * @property {string} [device_id] - EDC machine Unique Identifier
645
568
  * @property {string} [upi_poll_url] - UPI poll url.
@@ -660,7 +583,7 @@ const Joi = require("joi");
660
583
  */
661
584
 
662
585
  /**
663
- * @typedef PaymentStatusUpdateRequest
586
+ * @typedef PaymentStatusUpdateCreation
664
587
  * @property {string} [device_id] - EDC machine Unique Identifier
665
588
  * @property {string} email - Customer valid email
666
589
  * @property {string} customer_id - Payment gateway customer id.
@@ -677,7 +600,7 @@ const Joi = require("joi");
677
600
  */
678
601
 
679
602
  /**
680
- * @typedef PaymentStatusUpdateResponse
603
+ * @typedef PaymentStatusUpdateDetails
681
604
  * @property {string} [redirect_url] - Redirect url
682
605
  * @property {boolean} retry - Response is successful or not.
683
606
  * @property {boolean} [success] - Response is successful or not
@@ -686,7 +609,7 @@ const Joi = require("joi");
686
609
  */
687
610
 
688
611
  /**
689
- * @typedef ResendOrCancelPaymentRequest
612
+ * @typedef ResendOrCancelPaymentCreation
690
613
  * @property {string} order_id - Unique order id
691
614
  * @property {string} [device_id] - EDC machine Unique Identifier
692
615
  * @property {string} request_type - Either resend or cancel
@@ -701,18 +624,18 @@ const Joi = require("joi");
701
624
  */
702
625
 
703
626
  /**
704
- * @typedef ResendOrCancelPaymentResponse
627
+ * @typedef ResendOrCancelPaymentDetails
705
628
  * @property {LinkStatus} data
706
629
  * @property {boolean} success - Response is successful or not.
707
630
  */
708
631
 
709
632
  /**
710
- * @typedef PaymentStatusBulkHandlerRequest
633
+ * @typedef PaymentStatusBulkHandlerCreation
711
634
  * @property {string[]} merchant_order_id - List of order ids
712
635
  */
713
636
 
714
637
  /**
715
- * @typedef PaymentObjectListSerializer
638
+ * @typedef PaymentObjectList
716
639
  * @property {Object} user_object
717
640
  * @property {string} modified_on
718
641
  * @property {string} collected_by
@@ -736,11 +659,11 @@ const Joi = require("joi");
736
659
  /**
737
660
  * @typedef PaymentStatusObject
738
661
  * @property {string} merchant_order_id
739
- * @property {PaymentObjectListSerializer[]} [payment_object_list]
662
+ * @property {PaymentObjectList[]} [payment_object_list]
740
663
  */
741
664
 
742
665
  /**
743
- * @typedef PaymentStatusBulkHandlerResponse
666
+ * @typedef PaymentStatusBulkHandlerDetails
744
667
  * @property {number} [count]
745
668
  * @property {PaymentStatusObject[]} [data]
746
669
  * @property {string} success
@@ -749,7 +672,7 @@ const Joi = require("joi");
749
672
  */
750
673
 
751
674
  /**
752
- * @typedef GetOauthUrlResponse
675
+ * @typedef GetOauthUrlDetails
753
676
  * @property {string} url - The url to call for authenticating
754
677
  * @property {boolean} success - Response is successful or not
755
678
  */
@@ -761,51 +684,7 @@ const Joi = require("joi");
761
684
  */
762
685
 
763
686
  /**
764
- * @typedef RepaymentRequestDetails
765
- * @property {string} fwd_shipment_id - Purchase Shipment Id
766
- * @property {string} aggregator - Name of Payment Gateway
767
- * @property {string} current_status - Status
768
- * @property {string} merchant_order_id - Merchant's Order Id
769
- * @property {number} amount - Amount to paid back
770
- * @property {string} payment_mode - Payment Mode
771
- * @property {number} outstanding_details_id - Outstanding details ID
772
- * @property {string} aggregator_transaction_id - Unique Id for the transaction
773
- * @property {string} aggregator_order_id - Id of payment gateway
774
- * @property {string} payment_mode_identifier - Payment Mode Id
775
- */
776
-
777
- /**
778
- * @typedef RepaymentDetailsSerialiserPayAll
779
- * @property {number} total_amount - Total amount
780
- * @property {string} extension_order_id - Order id created in extension
781
- * @property {string} aggregator_transaction_id - Unique Id for the transaction
782
- * @property {string} aggregator_order_id - Id of payment gateway
783
- * @property {RepaymentRequestDetails[]} [shipment_details]
784
- */
785
-
786
- /**
787
- * @typedef RepaymentResponse
788
- * @property {Object} data
789
- * @property {boolean} success - Success/Failure of the transaction
790
- */
791
-
792
- /**
793
- * @typedef MerchantOnBoardingRequest
794
- * @property {string} credit_line_id - Merchant ID at Ajiodhan's end
795
- * @property {string} aggregator - Payment aggregator name
796
- * @property {string} app_id - Application id
797
- * @property {string} user_id - Deadlock or Grimlock user id
798
- * @property {string} status - Status
799
- */
800
-
801
- /**
802
- * @typedef MerchantOnBoardingResponse
803
- * @property {Object} data
804
- * @property {boolean} success - Success/Failure of the transaction
805
- */
806
-
807
- /**
808
- * @typedef ValidateCustomerRequest
687
+ * @typedef ValidateCustomerCreation
809
688
  * @property {string} phone_number - User mobile number without country code.
810
689
  * @property {string} aggregator - Payment gateway name in camel case i.e Simpl, Rupifi
811
690
  * @property {string} [payload] - Hashed payload string.
@@ -817,14 +696,14 @@ const Joi = require("joi");
817
696
  */
818
697
 
819
698
  /**
820
- * @typedef ValidateCustomerResponse
699
+ * @typedef ValidateCustomerDetails
821
700
  * @property {string} message - Error or success message.
822
701
  * @property {Object} [data] - Payment gateway response data
823
702
  * @property {boolean} success - Response is successful or not
824
703
  */
825
704
 
826
705
  /**
827
- * @typedef GetPaymentLinkResponse
706
+ * @typedef GetPaymentLinkDetails
828
707
  * @property {string} message - Message
829
708
  * @property {number} status_code - HTTP status code
830
709
  * @property {number} [amount] - Total value of order
@@ -850,7 +729,7 @@ const Joi = require("joi");
850
729
  */
851
730
 
852
731
  /**
853
- * @typedef ErrorResponse
732
+ * @typedef ErrorDetails
854
733
  * @property {number} status_code - HTTP status code
855
734
  * @property {ErrorDescription} [error]
856
735
  * @property {string} message - Message
@@ -867,7 +746,7 @@ const Joi = require("joi");
867
746
  */
868
747
 
869
748
  /**
870
- * @typedef CreatePaymentLinkRequest
749
+ * @typedef CreatePaymentLinkCreation
871
750
  * @property {string} email - Email to which the payment link is to be sent
872
751
  * @property {number} amount - Total value of order
873
752
  * @property {string} mobile_number - Mobile number to which the payment link is
@@ -876,10 +755,16 @@ const Joi = require("joi");
876
755
  * @property {string} [description] - Merchant order id
877
756
  * @property {CreatePaymentLinkMeta} meta
878
757
  * @property {string} external_order_id - Merchant order id
758
+ * @property {string} [success_redirection_url] - URL to which the user will be
759
+ * redirected after a successful payment.
760
+ * @property {string} [failure_redirection_url] - URL to which the user will be
761
+ * redirected if the payment fails.
762
+ * @property {boolean} [send_communication] - Flag indicating whether to send
763
+ * communications (e.g., SMS or email) for the payment link
879
764
  */
880
765
 
881
766
  /**
882
- * @typedef CreatePaymentLinkResponse
767
+ * @typedef CreatePaymentLinkDetails
883
768
  * @property {string} message - Message
884
769
  * @property {number} status_code - HTTP status code
885
770
  * @property {string} [payment_link_url] - Url of payment link
@@ -889,7 +774,7 @@ const Joi = require("joi");
889
774
  */
890
775
 
891
776
  /**
892
- * @typedef PollingPaymentLinkResponse
777
+ * @typedef PollingPaymentLinkDetails
893
778
  * @property {string} [message] - Message
894
779
  * @property {number} [http_status] - HTTP status code
895
780
  * @property {number} [status_code] - HTTP status code
@@ -903,12 +788,12 @@ const Joi = require("joi");
903
788
  */
904
789
 
905
790
  /**
906
- * @typedef CancelOrResendPaymentLinkRequest
791
+ * @typedef CancelOrResendPaymentLinkCreation
907
792
  * @property {string} payment_link_id - Unique id of payment link
908
793
  */
909
794
 
910
795
  /**
911
- * @typedef ResendPaymentLinkResponse
796
+ * @typedef ResendPaymentLinkDetails
912
797
  * @property {number} status_code - HTTP status code
913
798
  * @property {string} message - Message
914
799
  * @property {number} [polling_timeout] - Polling request timeout
@@ -916,7 +801,7 @@ const Joi = require("joi");
916
801
  */
917
802
 
918
803
  /**
919
- * @typedef CancelPaymentLinkResponse
804
+ * @typedef CancelPaymentLinkDetails
920
805
  * @property {number} status_code - HTTP status code
921
806
  * @property {string} message - Message
922
807
  * @property {boolean} success - Successful or failure
@@ -943,24 +828,139 @@ const Joi = require("joi");
943
828
  */
944
829
 
945
830
  /**
946
- * @typedef GetPaymentCodeResponse
831
+ * @typedef GetPaymentCodeDetails
947
832
  * @property {GetPaymentCode} data
948
833
  * @property {boolean} success - Response is successful or not.
949
834
  */
950
835
 
951
836
  /**
952
- * @typedef PlatformPaymentModeResponse
837
+ * @typedef PlatformPaymentModeDetails
953
838
  * @property {string} [message] - Message
954
839
  * @property {Object[]} [items] - List of all aggregator and payment mode details.
955
840
  * @property {boolean} success - Response is successful or not.
956
841
  */
957
842
 
958
843
  /**
959
- * @typedef MerchnatPaymentModeRequest
844
+ * @typedef PaymentModeConfig
845
+ * @property {string} [business_unit] - Business unit for which the configuration applies.
846
+ * @property {string} [device] - Device type for which the configuration applies.
847
+ * @property {boolean} [is_active] - Indicates if the payment configuration is
848
+ * currently active.
849
+ * @property {PaymentModeItems[]} [items] - List of payment modes available for
850
+ * the given business unit and device. This list is dynamic and can contain
851
+ * one or more payment modes.
852
+ */
853
+
854
+ /**
855
+ * @typedef PaymentModeItems
856
+ * @property {number} [id] - Unique identifier for the payment mode.
857
+ * @property {string} [name] - Display name of the payment mode.
858
+ * @property {string} [short_code] - Short code for the payment mode.
859
+ * @property {LogoSet} [logos]
860
+ * @property {boolean} [is_active] - Indicates if this payment mode is active in
861
+ * the system.
862
+ * @property {SubPaymentMode[]} [sub_payment_mode] - Dynamic list of sub-payment
863
+ * modes under this payment mode.
864
+ * @property {boolean} [is_active_at_pg] - Indicates if this payment mode is
865
+ * active at the payment gateway (PG) side.
866
+ * @property {Object} [fulfillment_options] - Fulfillment options applicable for
867
+ * these payment modes. Keys are option slugs and values indicate whether the
868
+ * option is enabled.
869
+ */
870
+
871
+ /**
872
+ * @typedef SubPaymentMode
873
+ * @property {string} [code] - Unique code of the sub-payment mode.
874
+ * @property {boolean} [is_active] - Indicates if this sub-payment mode is
875
+ * active in the system.
876
+ * @property {number} [priority] - Priority used for ordering in UI. Lower
877
+ * numbers can represent higher priority, depending on implementation.
878
+ * @property {LogoSet} [logos]
879
+ * @property {string} [name] - Human-readable name of the sub-payment mode.
880
+ * @property {boolean} [is_active_at_pg] - Indicates if this sub-payment mode is
881
+ * active at the payment gateway (PG) side.
882
+ */
883
+
884
+ /**
885
+ * @typedef LogoSet
886
+ * @property {string} [large] - URL of the large-sized logo.
887
+ * @property {string} [small] - URL of the small-sized logo.
888
+ */
889
+
890
+ /**
891
+ * @typedef PlatformLogoSet
892
+ * @property {string} [large] - URL of the large-sized logo.
893
+ * @property {string} [small] - URL of the small-sized logo.
894
+ */
895
+
896
+ /**
897
+ * @typedef PlatformConfigPaymentModeDetails
898
+ * @property {string} [business_unit] - Business unit for which the
899
+ * configuration applies (e.g. "storefront", "pos").
900
+ * @property {string} [device] - Device or channel for which the configuration
901
+ * applies (e.g. "desktop", "android", "ios").
902
+ * @property {Object} [fulfillment_options] - Fulfillment options applicable for
903
+ * these payment modes. Keys are option slugs (e.g. "self-pickup", "delivery")
904
+ * and values indicate whether the option is enabled.
905
+ * @property {boolean} [is_active] - Overall active status for this aggregator
906
+ * payment configuration for the given application and device.
907
+ * @property {PlatformPaymentModeItem[]} [items] - List of payment modes and
908
+ * their configuration.
909
+ */
910
+
911
+ /**
912
+ * @typedef PlatformPaymentModeItem
913
+ * @property {number} [id] - Unique identifier of the payment mode.
914
+ * @property {string} [name] - Human readable name of the payment mode.
915
+ * @property {string} [short_code] - Short code representing the payment mode.
916
+ * @property {PlatformLogoSet} [logos]
917
+ * @property {boolean} [is_active] - Indicates if the payment mode is enabled on
918
+ * the platform.
919
+ * @property {boolean} [is_active_at_pg] - Indicates if the payment mode is
920
+ * active at the payment gateway.
921
+ * @property {PlatformSubPaymentMode[]} [sub_payment_mode] - List of sub payment
922
+ * modes (e.g. card networks like VISA, MASTERCARD).
923
+ */
924
+
925
+ /**
926
+ * @typedef PlatformSubPaymentMode
927
+ * @property {string} [code] - Code of the sub payment mode (e.g. "VISA", "AMEX").
928
+ * @property {string} [name] - Human readable name of the sub payment mode.
929
+ * @property {boolean} [is_active] - Indicates if the sub payment mode is enabled.
930
+ * @property {boolean} [is_active_at_pg] - Indicates if the sub payment mode is
931
+ * active at payment gateway.
932
+ * @property {number} [priority] - Display priority for the sub payment mode.
933
+ * Lower numbers indicate higher priority.
934
+ * @property {PlatformLogoSet} [logos]
935
+ */
936
+
937
+ /**
938
+ * @typedef MerchnatPaymentModeCreation
960
939
  * @property {Object} [offline] - Details to be updated for online payment configuration.
961
940
  * @property {Object} [online] - Details to be updated for offline payment configuration.
962
941
  */
963
942
 
943
+ /**
944
+ * @typedef SkuDetails
945
+ * @property {string} [identifier] - SKU identifier of the offer
946
+ * @property {string} [sku_id] - Unique SKU identifier (example: GTIN, variant ID)
947
+ * @property {string} [sku_name] - Display name of the SKU
948
+ */
949
+
950
+ /**
951
+ * @typedef AppliedOffer
952
+ * @property {boolean} [is_mop] - Whether the offer is a mop or not. MOP is a
953
+ * discount that is applied on the total order value.
954
+ * @property {string} [offer_type] - Type of offer. It can be either a bank or
955
+ * brand offer.
956
+ * @property {string} [offer_id] - Unique identifier for the offer.
957
+ * @property {string} [description] - Description of the offer.
958
+ * @property {number} [amount] - Amount of the offer in paise. (Example: ₹1 = 100 paise)
959
+ * @property {Object} [meta] - Extra meta data specific to extension
960
+ * @property {SkuDetails[]} [sku_details] - List of sku details for which the
961
+ * offer is applicable. This is applicable only for brand offers.
962
+ */
963
+
964
964
  /**
965
965
  * @typedef OrderDetail
966
966
  * @property {string} gid - Global identifier of the entity (e.g. order, cart
@@ -972,6 +972,7 @@ const Joi = require("joi");
972
972
  * @property {Object} aggregator_order_details - Aggregator order details
973
973
  * generated by the payment gateway.
974
974
  * @property {string} aggregator - Name of the payment gateway aggregator.
975
+ * @property {AppliedOffer[]} [applied_offers] - List of offers applied on the order.
975
976
  */
976
977
 
977
978
  /**
@@ -998,6 +999,13 @@ const Joi = require("joi");
998
999
  * @property {Object[]} [tags] - Optional address tag
999
1000
  */
1000
1001
 
1002
+ /**
1003
+ * @typedef ReasonDetail
1004
+ * @property {string} [code] - The code indicating the type of reason.
1005
+ * @property {string} [description] - A detailed description of the payment
1006
+ * reason or error.
1007
+ */
1008
+
1001
1009
  /**
1002
1010
  * @typedef PaymentSessionDetail
1003
1011
  * @property {string} payment_id - Unique transaction id generated by payment gateway
@@ -1034,10 +1042,11 @@ const Joi = require("joi");
1034
1042
  * merchant account) by payment gateway.
1035
1043
  * @property {Object} [meta] - Extra meta data specific to extension
1036
1044
  * @property {string} status - Status of the payment
1045
+ * @property {ReasonDetail} [reason]
1037
1046
  */
1038
1047
 
1039
1048
  /**
1040
- * @typedef PaymentSessionRequestSerializer
1049
+ * @typedef PaymentSessionCreation
1041
1050
  * @property {Object} [meta] - Extra meta data specific to extensions
1042
1051
  * @property {string} gid - Global identifier of the entity (e.g. order, cart
1043
1052
  * etc.) against which payment_session was initiated. This is generated by
@@ -1053,7 +1062,7 @@ const Joi = require("joi");
1053
1062
  */
1054
1063
 
1055
1064
  /**
1056
- * @typedef PaymentSessionResponseSerializer
1065
+ * @typedef PaymentSessionPutDetails
1057
1066
  * @property {string} gid - Global identifier of the entity (e.g. order, cart
1058
1067
  * etc.) against which payment_session was initiated. This is generated by
1059
1068
  * Fynd payments platform and is unique.
@@ -1084,7 +1093,7 @@ const Joi = require("joi");
1084
1093
  */
1085
1094
 
1086
1095
  /**
1087
- * @typedef RefundSessionRequestSerializer
1096
+ * @typedef RefundSessionCreation
1088
1097
  * @property {Object} [meta] - Meta
1089
1098
  * @property {string} gid - Global identifier of the entity (e.g. order, cart
1090
1099
  * etc.) against which payment_session was initiated. This is generated by
@@ -1100,7 +1109,7 @@ const Joi = require("joi");
1100
1109
  */
1101
1110
 
1102
1111
  /**
1103
- * @typedef RefundSessionResponseSerializer
1112
+ * @typedef RefundSessionDetails
1104
1113
  * @property {string} gid - Global identifier of the entity (e.g. order, cart
1105
1114
  * etc.) against which payment_session was initiated. This is generated by
1106
1115
  * Fynd payments platform and is unique.
@@ -1111,7 +1120,7 @@ const Joi = require("joi");
1111
1120
  */
1112
1121
 
1113
1122
  /**
1114
- * @typedef PaymentDetailsSerializer
1123
+ * @typedef PaymentDetails
1115
1124
  * @property {Object[]} payment_methods - List of payment methods
1116
1125
  * @property {string} gid - Global identifier of the entity (e.g. order, cart
1117
1126
  * etc.) against which payment_session was initiated. This is generated by
@@ -1147,7 +1156,7 @@ const Joi = require("joi");
1147
1156
  */
1148
1157
 
1149
1158
  /**
1150
- * @typedef CartDetailsSerializer
1159
+ * @typedef CartDetails
1151
1160
  * @property {Object} items - Items that are added in cart
1152
1161
  * @property {Object[]} articles - List of articles that are added in cart
1153
1162
  * @property {number} cart_value - Total cart value i.e. amount to be paid
@@ -1157,7 +1166,7 @@ const Joi = require("joi");
1157
1166
  */
1158
1167
 
1159
1168
  /**
1160
- * @typedef RefundDetailsSerializer
1169
+ * @typedef RefundDetails
1161
1170
  * @property {number} amount - Refunded amount
1162
1171
  * @property {string} currency - The currency of the payment.
1163
1172
  * @property {string} request_id - Refund request id, unique id generated by Fynd platform
@@ -1167,7 +1176,7 @@ const Joi = require("joi");
1167
1176
  */
1168
1177
 
1169
1178
  /**
1170
- * @typedef PaymentSessionSerializer
1179
+ * @typedef PaymentSessionFetchDetails
1171
1180
  * @property {Object} payment_details - Object of payment details
1172
1181
  * @property {string} [currency] - The currency of the payment.
1173
1182
  * @property {string} status - The status of the payment session.
@@ -1175,8 +1184,8 @@ const Joi = require("joi");
1175
1184
  * @property {string} gid - Global identifier of the entity (e.g. order, cart
1176
1185
  * etc.) against which payment_session was initiated. This is generated by
1177
1186
  * Fynd payments platform and is unique.
1178
- * @property {CartDetailsSerializer} [cart_details]
1179
- * @property {RefundDetailsSerializer[]} refund_details - Object of refund details
1187
+ * @property {CartDetails} [cart_details]
1188
+ * @property {RefundDetails[]} refund_details - Object of refund details
1180
1189
  */
1181
1190
 
1182
1191
  /**
@@ -1187,7 +1196,7 @@ const Joi = require("joi");
1187
1196
  */
1188
1197
 
1189
1198
  /**
1190
- * @typedef RefundPriorityResponseSerializer
1199
+ * @typedef RefundPriorityDetails
1191
1200
  * @property {string} configuration - Configuration for merchant or customer
1192
1201
  * @property {boolean} success - Success
1193
1202
  * @property {boolean} apportion - Apportion refund to multiple sources
@@ -1196,13 +1205,13 @@ const Joi = require("joi");
1196
1205
  */
1197
1206
 
1198
1207
  /**
1199
- * @typedef RefundPriorityRequestSerializer
1208
+ * @typedef RefundPriorityCreation
1200
1209
  * @property {boolean} apportion - Apportion refund to multiple sources
1201
1210
  * @property {RefundSourcesPriority[]} refund_sources_priority - Refund sources priority
1202
1211
  */
1203
1212
 
1204
1213
  /**
1205
- * @typedef MerchantPaymentModeRequest
1214
+ * @typedef MerchantPaymentModeCreation
1206
1215
  * @property {string} business_unit - Business unit
1207
1216
  * @property {Object[]} items - List of item details with respect to payment_mode
1208
1217
  * @property {Object} device - List of devices and its activation status
@@ -1221,7 +1230,7 @@ const Joi = require("joi");
1221
1230
  */
1222
1231
 
1223
1232
  /**
1224
- * @typedef PlatformPaymentModeCopyConfigRequest
1233
+ * @typedef PlatformPaymentModeCopyConfigCreation
1225
1234
  * @property {FromConfig} from_config
1226
1235
  * @property {ToConfig} to_config
1227
1236
  */
@@ -1243,7 +1252,7 @@ const Joi = require("joi");
1243
1252
  */
1244
1253
 
1245
1254
  /**
1246
- * @typedef PaymentOrderRequest
1255
+ * @typedef PaymentOrderCreation
1247
1256
  * @property {string} order_id - Order id
1248
1257
  * @property {PaymentOrderMethods[]} [payment_methods]
1249
1258
  * @property {string} [shipment_id] - Shipment_id
@@ -1264,7 +1273,7 @@ const Joi = require("joi");
1264
1273
  */
1265
1274
 
1266
1275
  /**
1267
- * @typedef PaymentOrderResponse
1276
+ * @typedef PaymentOrderDetails
1268
1277
  * @property {string} message - Message
1269
1278
  * @property {boolean} success - Successful or failure
1270
1279
  * @property {string} [payment_confirm_url] - Payment confirm url for aggregator
@@ -1282,7 +1291,7 @@ const Joi = require("joi");
1282
1291
  */
1283
1292
 
1284
1293
  /**
1285
- * @typedef AggregatorVersionResponse
1294
+ * @typedef AggregatorVersionDetails
1286
1295
  * @property {string} message - Message
1287
1296
  * @property {boolean} success - Successful or failure
1288
1297
  * @property {AggregatorVersionItemSchema} [items]
@@ -1296,7 +1305,7 @@ const Joi = require("joi");
1296
1305
  */
1297
1306
 
1298
1307
  /**
1299
- * @typedef AggregatorControlRequest
1308
+ * @typedef PatchAggregatorControl
1300
1309
  * @property {string} [business_unit] - Business unit
1301
1310
  * @property {Object[]} [items] - List of item details with respect to payment_mode
1302
1311
  * @property {string} [device] - Device name
@@ -1357,9 +1366,65 @@ const Joi = require("joi");
1357
1366
  * @property {PaymentModeCustomConfigSchema[]} items
1358
1367
  */
1359
1368
 
1369
+ /**
1370
+ * @typedef CustomerValidationSchema
1371
+ * @property {string} aggregator - Aggregator name of the payment gateway.
1372
+ * @property {number} transaction_amount - Payable amount
1373
+ * @property {string} [cart_id] - Unique identifier for the shopping cart.
1374
+ * @property {string} [user_id] - The unique identifier of the user.
1375
+ */
1376
+
1377
+ /**
1378
+ * @typedef UserCreditSchema
1379
+ * @property {number} amount - The monetary value, which can represent available
1380
+ * balance, redeemed balance, or hold amount, depending on the context.
1381
+ * @property {string} currency - The currency code (e.g., INR, USD).
1382
+ * @property {string} [unique_id] - A unique identifier for the payment transaction.
1383
+ */
1384
+
1385
+ /**
1386
+ * @typedef CreditAccountSummary
1387
+ * @property {string} account_id - Unique identifier associated with the
1388
+ * customer's account
1389
+ * @property {string} status - Current state of the account, indicating whether
1390
+ * it is ACTIVE, INACTIVE, or UNREGISTERED.
1391
+ * @property {UserCreditSchema} [redeemable_balance]
1392
+ * @property {UserCreditSchema} [available_balance]
1393
+ * @property {UserCreditSchema[]} [amount_on_hold]
1394
+ */
1395
+
1396
+ /**
1397
+ * @typedef ValidateCustomerCreditSchema
1398
+ * @property {boolean} success - Successful or failure of API
1399
+ * @property {boolean} is_eligible - The customer is eligible to make a transaction or not
1400
+ * @property {boolean} [is_applied] - Credit is applied to the user's account or not
1401
+ * @property {string} message - Detailed message about the user credt eligibility.
1402
+ * @property {string} [cart_id] - Unique identifier for the shopping cart.
1403
+ * @property {CreditAccountSummary} [account]
1404
+ */
1405
+
1406
+ /**
1407
+ * @typedef OperationResponseSchema
1408
+ * @property {boolean} success - Indicates if the operation was successful
1409
+ * @property {string} [message] - Optional message providing additional
1410
+ * information about the operation
1411
+ */
1412
+
1360
1413
  class PaymentPlatformModel {
1361
- /** @returns {PaymentGatewayConfigResponse} */
1362
- static PaymentGatewayConfigResponse() {
1414
+ /** @returns {AggregatorToken} */
1415
+ static AggregatorToken() {
1416
+ return Joi.object({
1417
+ payment_mode_id: Joi.number().required(),
1418
+ sub_payment_mode_code: Joi.string().allow("").required(),
1419
+ token: Joi.string().allow("").required(),
1420
+ status: Joi.string().allow("").required(),
1421
+ is_active: Joi.boolean().required(),
1422
+ domain: Joi.string().allow("").required(),
1423
+ });
1424
+ }
1425
+
1426
+ /** @returns {PaymentGatewayConfigDetails} */
1427
+ static PaymentGatewayConfigDetails() {
1363
1428
  return Joi.object({
1364
1429
  aggregators: Joi.array().items(Joi.any()),
1365
1430
  app_id: Joi.string().allow("").required(),
@@ -1390,8 +1455,8 @@ class PaymentPlatformModel {
1390
1455
  });
1391
1456
  }
1392
1457
 
1393
- /** @returns {PaymentGatewayConfigRequest} */
1394
- static PaymentGatewayConfigRequest() {
1458
+ /** @returns {PaymentGatewayConfigCreation} */
1459
+ static PaymentGatewayConfigCreation() {
1395
1460
  return Joi.object({
1396
1461
  app_id: Joi.string().allow("").required(),
1397
1462
  is_active: Joi.boolean().allow(null),
@@ -1415,8 +1480,8 @@ class PaymentPlatformModel {
1415
1480
  });
1416
1481
  }
1417
1482
 
1418
- /** @returns {HttpErrorCodeAndResponse} */
1419
- static HttpErrorCodeAndResponse() {
1483
+ /** @returns {HttpErrorDetails} */
1484
+ static HttpErrorDetails() {
1420
1485
  return Joi.object({
1421
1486
  error: PaymentPlatformModel.ErrorCodeAndDescription().required(),
1422
1487
  success: Joi.boolean().required(),
@@ -1434,13 +1499,13 @@ class PaymentPlatformModel {
1434
1499
  /** @returns {ProductCODData} */
1435
1500
  static ProductCODData() {
1436
1501
  return Joi.object({
1437
- items: Joi.any().allow(null),
1438
- cod_charges: PaymentPlatformModel.CODChargesLimitsResponse(),
1502
+ items: Joi.object().pattern(/\S/, Joi.any()).allow(null, ""),
1503
+ cod_charges: PaymentPlatformModel.CODChargesLimitsDetails(),
1439
1504
  });
1440
1505
  }
1441
1506
 
1442
- /** @returns {CODChargesLimitsResponse} */
1443
- static CODChargesLimitsResponse() {
1507
+ /** @returns {CODChargesLimitsDetails} */
1508
+ static CODChargesLimitsDetails() {
1444
1509
  return Joi.object({
1445
1510
  max_cart_value: Joi.number().allow(null),
1446
1511
  min_cart_value: Joi.number().allow(null),
@@ -1510,6 +1575,18 @@ class PaymentPlatformModel {
1510
1575
  intent_app_error_list: Joi.array()
1511
1576
  .items(Joi.string().allow(""))
1512
1577
  .allow(null, ""),
1578
+ payment_confirmation_elements: Joi.array().items(
1579
+ PaymentPlatformModel.PaymentConfirmationElement()
1580
+ ),
1581
+ });
1582
+ }
1583
+
1584
+ /** @returns {PaymentConfirmationElement} */
1585
+ static PaymentConfirmationElement() {
1586
+ return Joi.object({
1587
+ is_required: Joi.boolean(),
1588
+ display_label: Joi.string().allow(""),
1589
+ slug: Joi.string().allow(""),
1513
1590
  });
1514
1591
  }
1515
1592
 
@@ -1540,8 +1617,8 @@ class PaymentPlatformModel {
1540
1617
  /** @returns {AggregatorRoute} */
1541
1618
  static AggregatorRoute() {
1542
1619
  return Joi.object({
1543
- data: Joi.any().allow(null),
1544
- payment_flow_data: Joi.any().allow(null),
1620
+ data: Joi.object().pattern(/\S/, Joi.any()).allow(null, ""),
1621
+ payment_flow_data: Joi.object().pattern(/\S/, Joi.any()).allow(null, ""),
1545
1622
  payment_flow: Joi.string().allow("").allow(null),
1546
1623
  api_link: Joi.string().allow("").allow(null),
1547
1624
  }).allow(null);
@@ -1561,17 +1638,11 @@ class PaymentPlatformModel {
1561
1638
  return Joi.object({
1562
1639
  bqr_razorpay: PaymentPlatformModel.AggregatorRoute(),
1563
1640
  fynd: PaymentPlatformModel.AggregatorRoute(),
1564
- epaylater: PaymentPlatformModel.AggregatorRoute(),
1565
1641
  razorpay: PaymentPlatformModel.AggregatorRoute(),
1566
1642
  juspay: PaymentPlatformModel.AggregatorRoute(),
1567
- ajiodhan: PaymentPlatformModel.AggregatorRoute(),
1568
1643
  simpl: PaymentPlatformModel.AggregatorRoute(),
1569
- rupifi: PaymentPlatformModel.AggregatorRoute(),
1570
- mswipe: PaymentPlatformModel.AggregatorRoute(),
1571
- stripe: PaymentPlatformModel.AggregatorRoute(),
1572
1644
  ccavenue: PaymentPlatformModel.AggregatorRoute(),
1573
1645
  payubiz: PaymentPlatformModel.AggregatorRoute(),
1574
- jiopay: PaymentPlatformModel.AggregatorRoute(),
1575
1646
  });
1576
1647
  }
1577
1648
 
@@ -1629,24 +1700,24 @@ class PaymentPlatformModel {
1629
1700
  });
1630
1701
  }
1631
1702
 
1632
- /** @returns {PaymentModeRouteResponse} */
1633
- static PaymentModeRouteResponse() {
1703
+ /** @returns {PaymentModeRouteDetails} */
1704
+ static PaymentModeRouteDetails() {
1634
1705
  return Joi.object({
1635
1706
  payment_options: PaymentPlatformModel.PaymentOptionAndFlow().required(),
1636
1707
  success: Joi.boolean().required(),
1637
- payment_breakup: Joi.any(),
1708
+ payment_breakup: Joi.object().pattern(/\S/, Joi.any()),
1638
1709
  advance_payment: Joi.array()
1639
1710
  .items(PaymentPlatformModel.AdvancePaymentObject())
1640
1711
  .allow(null, ""),
1641
1712
  });
1642
1713
  }
1643
1714
 
1644
- /** @returns {PaymentOptionsResponse} */
1645
- static PaymentOptionsResponse() {
1715
+ /** @returns {PaymentOptionsDetails} */
1716
+ static PaymentOptionsDetails() {
1646
1717
  return Joi.object({
1647
1718
  payment_options: PaymentPlatformModel.PaymentOptions().required(),
1648
1719
  success: Joi.boolean().required(),
1649
- payment_breakup: Joi.any(),
1720
+ payment_breakup: Joi.object().pattern(/\S/, Joi.any()),
1650
1721
  });
1651
1722
  }
1652
1723
 
@@ -1700,8 +1771,8 @@ class PaymentPlatformModel {
1700
1771
  });
1701
1772
  }
1702
1773
 
1703
- /** @returns {PayoutsResponse} */
1704
- static PayoutsResponse() {
1774
+ /** @returns {PayoutsDetails} */
1775
+ static PayoutsDetails() {
1705
1776
  return Joi.object({
1706
1777
  success: Joi.boolean().required(),
1707
1778
  items: Joi.array().items(PaymentPlatformModel.Payout()).required(),
@@ -1724,11 +1795,11 @@ class PaymentPlatformModel {
1724
1795
  });
1725
1796
  }
1726
1797
 
1727
- /** @returns {PayoutRequest} */
1728
- static PayoutRequest() {
1798
+ /** @returns {PayoutCreation} */
1799
+ static PayoutCreation() {
1729
1800
  return Joi.object({
1730
1801
  aggregator: Joi.string().allow("").required(),
1731
- users: Joi.any().required(),
1802
+ users: Joi.object().pattern(/\S/, Joi.any()).required(),
1732
1803
  unique_external_id: Joi.string().allow("").required(),
1733
1804
  is_active: Joi.boolean().required(),
1734
1805
  bank_details: PaymentPlatformModel.PayoutBankDetails().required(),
@@ -1736,24 +1807,24 @@ class PaymentPlatformModel {
1736
1807
  });
1737
1808
  }
1738
1809
 
1739
- /** @returns {PayoutResponse} */
1740
- static PayoutResponse() {
1810
+ /** @returns {PayoutDetails} */
1811
+ static PayoutDetails() {
1741
1812
  return Joi.object({
1742
1813
  payment_status: Joi.string().allow("").required(),
1743
- users: Joi.any().required(),
1814
+ users: Joi.object().pattern(/\S/, Joi.any()).required(),
1744
1815
  aggregator: Joi.string().allow("").required(),
1745
1816
  unique_transfer_no: Joi.string().allow("").required(),
1746
1817
  is_active: Joi.boolean().required(),
1747
- bank_details: Joi.any().required(),
1818
+ bank_details: Joi.object().pattern(/\S/, Joi.any()).required(),
1748
1819
  success: Joi.boolean().required(),
1749
1820
  transfer_type: Joi.string().allow("").required(),
1750
1821
  created: Joi.boolean().required(),
1751
- payouts: Joi.any().required(),
1822
+ payouts: Joi.object().pattern(/\S/, Joi.any()).required(),
1752
1823
  });
1753
1824
  }
1754
1825
 
1755
- /** @returns {UpdatePayoutResponse} */
1756
- static UpdatePayoutResponse() {
1826
+ /** @returns {UpdatePayoutDetails} */
1827
+ static UpdatePayoutDetails() {
1757
1828
  return Joi.object({
1758
1829
  is_default: Joi.boolean().required(),
1759
1830
  is_active: Joi.boolean().required(),
@@ -1761,8 +1832,8 @@ class PaymentPlatformModel {
1761
1832
  });
1762
1833
  }
1763
1834
 
1764
- /** @returns {UpdatePayoutRequest} */
1765
- static UpdatePayoutRequest() {
1835
+ /** @returns {UpdatePayoutCreation} */
1836
+ static UpdatePayoutCreation() {
1766
1837
  return Joi.object({
1767
1838
  is_default: Joi.boolean().required(),
1768
1839
  is_active: Joi.boolean().required(),
@@ -1770,58 +1841,58 @@ class PaymentPlatformModel {
1770
1841
  });
1771
1842
  }
1772
1843
 
1773
- /** @returns {DeletePayoutResponse} */
1774
- static DeletePayoutResponse() {
1844
+ /** @returns {DeletePayoutDetails} */
1845
+ static DeletePayoutDetails() {
1775
1846
  return Joi.object({
1776
1847
  success: Joi.boolean().required(),
1777
1848
  });
1778
1849
  }
1779
1850
 
1780
- /** @returns {SubscriptionPaymentMethodResponse} */
1781
- static SubscriptionPaymentMethodResponse() {
1851
+ /** @returns {SubscriptionPaymentMethodDetails} */
1852
+ static SubscriptionPaymentMethodDetails() {
1782
1853
  return Joi.object({
1783
1854
  data: Joi.array().items(Joi.any()).required(),
1784
1855
  success: Joi.boolean().required(),
1785
1856
  });
1786
1857
  }
1787
1858
 
1788
- /** @returns {DeleteSubscriptionPaymentMethodResponse} */
1789
- static DeleteSubscriptionPaymentMethodResponse() {
1859
+ /** @returns {DeleteSubscriptionPaymentMethodDetails} */
1860
+ static DeleteSubscriptionPaymentMethodDetails() {
1790
1861
  return Joi.object({
1791
1862
  success: Joi.boolean().required(),
1792
1863
  });
1793
1864
  }
1794
1865
 
1795
- /** @returns {SubscriptionConfigResponse} */
1796
- static SubscriptionConfigResponse() {
1866
+ /** @returns {SubscriptionConfigDetails} */
1867
+ static SubscriptionConfigDetails() {
1797
1868
  return Joi.object({
1798
1869
  aggregator: Joi.string().allow("").required(),
1799
- config: Joi.any().required(),
1870
+ config: Joi.object().pattern(/\S/, Joi.any()).required(),
1800
1871
  success: Joi.boolean().required(),
1801
1872
  });
1802
1873
  }
1803
1874
 
1804
- /** @returns {SaveSubscriptionSetupIntentRequest} */
1805
- static SaveSubscriptionSetupIntentRequest() {
1875
+ /** @returns {SaveSubscriptionSetupIntentCreation} */
1876
+ static SaveSubscriptionSetupIntentCreation() {
1806
1877
  return Joi.object({
1807
1878
  unique_external_id: Joi.string().allow("").required(),
1808
1879
  });
1809
1880
  }
1810
1881
 
1811
- /** @returns {SaveSubscriptionSetupIntentResponse} */
1812
- static SaveSubscriptionSetupIntentResponse() {
1882
+ /** @returns {SaveSubscriptionSetupIntentDetails} */
1883
+ static SaveSubscriptionSetupIntentDetails() {
1813
1884
  return Joi.object({
1814
- data: Joi.any().required(),
1885
+ data: Joi.object().pattern(/\S/, Joi.any()).required(),
1815
1886
  success: Joi.boolean().required(),
1816
1887
  });
1817
1888
  }
1818
1889
 
1819
- /** @returns {RefundAccountResponse} */
1820
- static RefundAccountResponse() {
1890
+ /** @returns {RefundAccountDetails} */
1891
+ static RefundAccountDetails() {
1821
1892
  return Joi.object({
1822
1893
  is_verified_flag: Joi.boolean(),
1823
1894
  message: Joi.string().allow(""),
1824
- data: Joi.any().required(),
1895
+ data: Joi.object().pattern(/\S/, Joi.any()).required(),
1825
1896
  success: Joi.boolean().required(),
1826
1897
  });
1827
1898
  }
@@ -1838,24 +1909,26 @@ class PaymentPlatformModel {
1838
1909
  /** @returns {BankDetailsForOTP} */
1839
1910
  static BankDetailsForOTP() {
1840
1911
  return Joi.object({
1841
- ifsc_code: Joi.string().allow("").required(),
1842
- account_no: Joi.string().allow("").required(),
1843
- branch_name: Joi.string().allow("").required(),
1844
- bank_name: Joi.string().allow("").required(),
1845
- account_holder: Joi.string().allow("").required(),
1912
+ ifsc_code: Joi.string().allow(""),
1913
+ account_no: Joi.string().allow(""),
1914
+ branch_name: Joi.string().allow(""),
1915
+ bank_name: Joi.string().allow(""),
1916
+ account_holder: Joi.string().allow(""),
1917
+ upi: Joi.string().allow("").allow(null),
1846
1918
  });
1847
1919
  }
1848
1920
 
1849
- /** @returns {AddBeneficiaryDetailsOTPRequest} */
1850
- static AddBeneficiaryDetailsOTPRequest() {
1921
+ /** @returns {AddBeneficiaryDetailsOTPCreation} */
1922
+ static AddBeneficiaryDetailsOTPCreation() {
1851
1923
  return Joi.object({
1852
1924
  order_id: Joi.string().allow("").required(),
1925
+ shipment_id: Joi.string().allow(""),
1853
1926
  details: PaymentPlatformModel.BankDetailsForOTP().required(),
1854
1927
  });
1855
1928
  }
1856
1929
 
1857
- /** @returns {IfscCodeResponse} */
1858
- static IfscCodeResponse() {
1930
+ /** @returns {IfscCodeDetails} */
1931
+ static IfscCodeDetails() {
1859
1932
  return Joi.object({
1860
1933
  branch_name: Joi.string().allow("").required(),
1861
1934
  success: Joi.boolean(),
@@ -1888,8 +1961,8 @@ class PaymentPlatformModel {
1888
1961
  });
1889
1962
  }
1890
1963
 
1891
- /** @returns {OrderBeneficiaryResponse} */
1892
- static OrderBeneficiaryResponse() {
1964
+ /** @returns {OrderBeneficiaryFetchResults} */
1965
+ static OrderBeneficiaryFetchResults() {
1893
1966
  return Joi.object({
1894
1967
  beneficiaries: Joi.array()
1895
1968
  .items(PaymentPlatformModel.OrderBeneficiaryDetails())
@@ -1901,7 +1974,7 @@ class PaymentPlatformModel {
1901
1974
  /** @returns {MultiTenderPaymentMeta} */
1902
1975
  static MultiTenderPaymentMeta() {
1903
1976
  return Joi.object({
1904
- extra_meta: Joi.any().allow(null),
1977
+ extra_meta: Joi.object().pattern(/\S/, Joi.any()).allow(null, ""),
1905
1978
  order_id: Joi.string().allow(""),
1906
1979
  payment_id: Joi.string().allow(""),
1907
1980
  current_status: Joi.string().allow(""),
@@ -1920,8 +1993,8 @@ class PaymentPlatformModel {
1920
1993
  });
1921
1994
  }
1922
1995
 
1923
- /** @returns {PaymentConfirmationRequest} */
1924
- static PaymentConfirmationRequest() {
1996
+ /** @returns {PaymentConfirmationCreation} */
1997
+ static PaymentConfirmationCreation() {
1925
1998
  return Joi.object({
1926
1999
  order_id: Joi.string().allow("").required(),
1927
2000
  payment_methods: Joi.array()
@@ -1930,8 +2003,8 @@ class PaymentPlatformModel {
1930
2003
  });
1931
2004
  }
1932
2005
 
1933
- /** @returns {PaymentConfirmationResponse} */
1934
- static PaymentConfirmationResponse() {
2006
+ /** @returns {PaymentConfirmationDetails} */
2007
+ static PaymentConfirmationDetails() {
1935
2008
  return Joi.object({
1936
2009
  order_id: Joi.string().allow("").required(),
1937
2010
  message: Joi.string().allow("").required(),
@@ -1970,8 +2043,8 @@ class PaymentPlatformModel {
1970
2043
  });
1971
2044
  }
1972
2045
 
1973
- /** @returns {GetUserBULimitResponse} */
1974
- static GetUserBULimitResponse() {
2046
+ /** @returns {GetUserBULimitResponseSchema} */
2047
+ static GetUserBULimitResponseSchema() {
1975
2048
  return Joi.object({
1976
2049
  business_unit: Joi.string().allow("").required(),
1977
2050
  display_name: Joi.string().allow("").required(),
@@ -1979,19 +2052,19 @@ class PaymentPlatformModel {
1979
2052
  });
1980
2053
  }
1981
2054
 
1982
- /** @returns {GetUserCODLimitResponse} */
1983
- static GetUserCODLimitResponse() {
2055
+ /** @returns {GetUserCODLimitDetails} */
2056
+ static GetUserCODLimitDetails() {
1984
2057
  return Joi.object({
1985
2058
  items: Joi.array()
1986
- .items(PaymentPlatformModel.GetUserBULimitResponse())
2059
+ .items(PaymentPlatformModel.GetUserBULimitResponseSchema())
1987
2060
  .required(),
1988
2061
  success: Joi.boolean().required(),
1989
2062
  message: Joi.string().allow(""),
1990
2063
  });
1991
2064
  }
1992
2065
 
1993
- /** @returns {SetCODForUserRequest} */
1994
- static SetCODForUserRequest() {
2066
+ /** @returns {SetCODForUserCreation} */
2067
+ static SetCODForUserCreation() {
1995
2068
  return Joi.object({
1996
2069
  business_unit: Joi.string().allow(""),
1997
2070
  mobileno: Joi.string().allow("").required(),
@@ -2000,136 +2073,16 @@ class PaymentPlatformModel {
2000
2073
  });
2001
2074
  }
2002
2075
 
2003
- /** @returns {SetCODOptionResponse} */
2004
- static SetCODOptionResponse() {
2076
+ /** @returns {SetCODOptionDetails} */
2077
+ static SetCODOptionDetails() {
2005
2078
  return Joi.object({
2006
2079
  message: Joi.string().allow("").required(),
2007
2080
  success: Joi.boolean().required(),
2008
2081
  });
2009
2082
  }
2010
2083
 
2011
- /** @returns {EdcModelData} */
2012
- static EdcModelData() {
2013
- return Joi.object({
2014
- aggregator: Joi.string().allow("").required(),
2015
- aggregator_id: Joi.number().required(),
2016
- models: Joi.array().items(Joi.string().allow("")).required(),
2017
- });
2018
- }
2019
-
2020
- /** @returns {EdcAggregatorAndModelListResponse} */
2021
- static EdcAggregatorAndModelListResponse() {
2022
- return Joi.object({
2023
- data: Joi.array().items(PaymentPlatformModel.EdcModelData()).required(),
2024
- success: Joi.boolean().required(),
2025
- });
2026
- }
2027
-
2028
- /** @returns {StatisticsData} */
2029
- static StatisticsData() {
2030
- return Joi.object({
2031
- inactive_device_count: Joi.number().required(),
2032
- active_device_count: Joi.number().required(),
2033
- });
2034
- }
2035
-
2036
- /** @returns {EdcDeviceStatsResponse} */
2037
- static EdcDeviceStatsResponse() {
2038
- return Joi.object({
2039
- statistics: PaymentPlatformModel.StatisticsData().required(),
2040
- success: Joi.boolean().required(),
2041
- });
2042
- }
2043
-
2044
- /** @returns {EdcAddRequest} */
2045
- static EdcAddRequest() {
2046
- return Joi.object({
2047
- edc_model: Joi.string().allow("").required(),
2048
- store_id: Joi.number().required(),
2049
- aggregator_id: Joi.number().required(),
2050
- edc_device_serial_no: Joi.string().allow("").required(),
2051
- terminal_serial_no: Joi.string().allow("").required(),
2052
- device_tag: Joi.string().allow("").allow(null),
2053
- });
2054
- }
2055
-
2056
- /** @returns {EdcDevice} */
2057
- static EdcDevice() {
2058
- return Joi.object({
2059
- edc_model: Joi.string().allow(""),
2060
- store_id: Joi.number().required(),
2061
- aggregator_id: Joi.number().required(),
2062
- terminal_unique_identifier: Joi.string().allow("").required(),
2063
- edc_device_serial_no: Joi.string().allow("").required(),
2064
- is_active: Joi.boolean().required(),
2065
- aggregator_name: Joi.string().allow(""),
2066
- terminal_serial_no: Joi.string().allow("").required(),
2067
- merchant_store_pos_code: Joi.string().allow("").allow(null),
2068
- device_tag: Joi.string().allow("").required(),
2069
- application_id: Joi.string().allow("").required(),
2070
- });
2071
- }
2072
-
2073
- /** @returns {EdcDeviceAddResponse} */
2074
- static EdcDeviceAddResponse() {
2075
- return Joi.object({
2076
- data: PaymentPlatformModel.EdcDevice().required(),
2077
- success: Joi.boolean().required(),
2078
- });
2079
- }
2080
-
2081
- /** @returns {EdcDeviceDetailsResponse} */
2082
- static EdcDeviceDetailsResponse() {
2083
- return Joi.object({
2084
- data: PaymentPlatformModel.EdcDevice().required(),
2085
- success: Joi.boolean().required(),
2086
- });
2087
- }
2088
-
2089
- /** @returns {EdcUpdateRequest} */
2090
- static EdcUpdateRequest() {
2091
- return Joi.object({
2092
- edc_model: Joi.string().allow(""),
2093
- store_id: Joi.number(),
2094
- aggregator_id: Joi.number(),
2095
- edc_device_serial_no: Joi.string().allow(""),
2096
- is_active: Joi.boolean(),
2097
- merchant_store_pos_code: Joi.string().allow(""),
2098
- device_tag: Joi.string().allow("").allow(null),
2099
- });
2100
- }
2101
-
2102
- /** @returns {EdcDeviceUpdateResponse} */
2103
- static EdcDeviceUpdateResponse() {
2104
- return Joi.object({
2105
- success: Joi.boolean().required(),
2106
- });
2107
- }
2108
-
2109
- /** @returns {Page} */
2110
- static Page() {
2111
- return Joi.object({
2112
- item_total: Joi.number(),
2113
- next_id: Joi.string().allow(""),
2114
- has_previous: Joi.boolean(),
2115
- has_next: Joi.boolean(),
2116
- current: Joi.number(),
2117
- type: Joi.string().allow("").required(),
2118
- size: Joi.number(),
2119
- });
2120
- }
2121
-
2122
- /** @returns {EdcDeviceListResponse} */
2123
- static EdcDeviceListResponse() {
2124
- return Joi.object({
2125
- items: Joi.array().items(PaymentPlatformModel.EdcDevice()).required(),
2126
- page: PaymentPlatformModel.Page().required(),
2127
- success: Joi.boolean().required(),
2128
- });
2129
- }
2130
-
2131
- /** @returns {PaymentInitializationRequest} */
2132
- static PaymentInitializationRequest() {
2084
+ /** @returns {PaymentInitializationCreation} */
2085
+ static PaymentInitializationCreation() {
2133
2086
  return Joi.object({
2134
2087
  razorpay_payment_id: Joi.string().allow("").allow(null),
2135
2088
  device_id: Joi.string().allow("").allow(null),
@@ -2139,7 +2092,7 @@ class PaymentPlatformModel {
2139
2092
  aggregator: Joi.string().allow("").required(),
2140
2093
  order_id: Joi.string().allow("").required(),
2141
2094
  currency: Joi.string().allow("").required(),
2142
- amount: Joi.number().allow(null).required(),
2095
+ amount: Joi.number().required(),
2143
2096
  contact: Joi.string().allow("").required(),
2144
2097
  timeout: Joi.number().allow(null),
2145
2098
  merchant_order_id: Joi.string().allow("").required(),
@@ -2147,8 +2100,8 @@ class PaymentPlatformModel {
2147
2100
  });
2148
2101
  }
2149
2102
 
2150
- /** @returns {PaymentInitializationResponse} */
2151
- static PaymentInitializationResponse() {
2103
+ /** @returns {PaymentInitializationDetails} */
2104
+ static PaymentInitializationDetails() {
2152
2105
  return Joi.object({
2153
2106
  razorpay_payment_id: Joi.string().allow("").allow(null),
2154
2107
  device_id: Joi.string().allow("").allow(null),
@@ -2170,8 +2123,8 @@ class PaymentPlatformModel {
2170
2123
  });
2171
2124
  }
2172
2125
 
2173
- /** @returns {PaymentStatusUpdateRequest} */
2174
- static PaymentStatusUpdateRequest() {
2126
+ /** @returns {PaymentStatusUpdateCreation} */
2127
+ static PaymentStatusUpdateCreation() {
2175
2128
  return Joi.object({
2176
2129
  device_id: Joi.string().allow("").allow(null),
2177
2130
  email: Joi.string().allow("").required(),
@@ -2180,7 +2133,7 @@ class PaymentPlatformModel {
2180
2133
  aggregator: Joi.string().allow("").required(),
2181
2134
  order_id: Joi.string().allow("").required(),
2182
2135
  currency: Joi.string().allow("").required(),
2183
- amount: Joi.number().allow(null).required(),
2136
+ amount: Joi.number().required(),
2184
2137
  contact: Joi.string().allow("").required(),
2185
2138
  merchant_order_id: Joi.string().allow("").required(),
2186
2139
  status: Joi.string().allow("").required(),
@@ -2189,8 +2142,8 @@ class PaymentPlatformModel {
2189
2142
  });
2190
2143
  }
2191
2144
 
2192
- /** @returns {PaymentStatusUpdateResponse} */
2193
- static PaymentStatusUpdateResponse() {
2145
+ /** @returns {PaymentStatusUpdateDetails} */
2146
+ static PaymentStatusUpdateDetails() {
2194
2147
  return Joi.object({
2195
2148
  redirect_url: Joi.string().allow("").allow(null),
2196
2149
  retry: Joi.boolean().required(),
@@ -2200,8 +2153,8 @@ class PaymentPlatformModel {
2200
2153
  });
2201
2154
  }
2202
2155
 
2203
- /** @returns {ResendOrCancelPaymentRequest} */
2204
- static ResendOrCancelPaymentRequest() {
2156
+ /** @returns {ResendOrCancelPaymentCreation} */
2157
+ static ResendOrCancelPaymentCreation() {
2205
2158
  return Joi.object({
2206
2159
  order_id: Joi.string().allow("").required(),
2207
2160
  device_id: Joi.string().allow("").allow(null),
@@ -2218,34 +2171,36 @@ class PaymentPlatformModel {
2218
2171
  });
2219
2172
  }
2220
2173
 
2221
- /** @returns {ResendOrCancelPaymentResponse} */
2222
- static ResendOrCancelPaymentResponse() {
2174
+ /** @returns {ResendOrCancelPaymentDetails} */
2175
+ static ResendOrCancelPaymentDetails() {
2223
2176
  return Joi.object({
2224
2177
  data: PaymentPlatformModel.LinkStatus().required(),
2225
2178
  success: Joi.boolean().required(),
2226
2179
  });
2227
2180
  }
2228
2181
 
2229
- /** @returns {PaymentStatusBulkHandlerRequest} */
2230
- static PaymentStatusBulkHandlerRequest() {
2182
+ /** @returns {PaymentStatusBulkHandlerCreation} */
2183
+ static PaymentStatusBulkHandlerCreation() {
2231
2184
  return Joi.object({
2232
2185
  merchant_order_id: Joi.array().items(Joi.string().allow("")).required(),
2233
2186
  });
2234
2187
  }
2235
2188
 
2236
- /** @returns {PaymentObjectListSerializer} */
2237
- static PaymentObjectListSerializer() {
2189
+ /** @returns {PaymentObjectList} */
2190
+ static PaymentObjectList() {
2238
2191
  return Joi.object({
2239
- user_object: Joi.any().required(),
2192
+ user_object: Joi.object().pattern(/\S/, Joi.any()).required(),
2240
2193
  modified_on: Joi.string().allow("").required(),
2241
2194
  collected_by: Joi.string().allow("").required(),
2242
2195
  created_on: Joi.string().allow("").required(),
2243
- refund_object: Joi.any().allow(null),
2196
+ refund_object: Joi.object().pattern(/\S/, Joi.any()).allow(null, ""),
2244
2197
  id: Joi.string().allow("").required(),
2245
2198
  payment_id: Joi.string().allow("").allow(null),
2246
2199
  currency: Joi.string().allow("").required(),
2247
2200
  current_status: Joi.string().allow("").required(),
2248
- aggregator_payment_object: Joi.any().allow(null),
2201
+ aggregator_payment_object: Joi.object()
2202
+ .pattern(/\S/, Joi.any())
2203
+ .allow(null, ""),
2249
2204
  payment_mode: Joi.string().allow("").required(),
2250
2205
  refunded_by: Joi.string().allow("").required(),
2251
2206
  amount_in_paisa: Joi.string().allow("").required(),
@@ -2262,13 +2217,13 @@ class PaymentPlatformModel {
2262
2217
  return Joi.object({
2263
2218
  merchant_order_id: Joi.string().allow("").required(),
2264
2219
  payment_object_list: Joi.array().items(
2265
- PaymentPlatformModel.PaymentObjectListSerializer()
2220
+ PaymentPlatformModel.PaymentObjectList()
2266
2221
  ),
2267
2222
  });
2268
2223
  }
2269
2224
 
2270
- /** @returns {PaymentStatusBulkHandlerResponse} */
2271
- static PaymentStatusBulkHandlerResponse() {
2225
+ /** @returns {PaymentStatusBulkHandlerDetails} */
2226
+ static PaymentStatusBulkHandlerDetails() {
2272
2227
  return Joi.object({
2273
2228
  count: Joi.number(),
2274
2229
  data: Joi.array().items(PaymentPlatformModel.PaymentStatusObject()),
@@ -2278,8 +2233,8 @@ class PaymentPlatformModel {
2278
2233
  });
2279
2234
  }
2280
2235
 
2281
- /** @returns {GetOauthUrlResponse} */
2282
- static GetOauthUrlResponse() {
2236
+ /** @returns {GetOauthUrlDetails} */
2237
+ static GetOauthUrlDetails() {
2283
2238
  return Joi.object({
2284
2239
  url: Joi.string().allow("").required(),
2285
2240
  success: Joi.boolean().required(),
@@ -2294,87 +2249,31 @@ class PaymentPlatformModel {
2294
2249
  });
2295
2250
  }
2296
2251
 
2297
- /** @returns {RepaymentRequestDetails} */
2298
- static RepaymentRequestDetails() {
2299
- return Joi.object({
2300
- fwd_shipment_id: Joi.string().allow("").required(),
2301
- aggregator: Joi.string().allow("").required(),
2302
- current_status: Joi.string().allow("").required(),
2303
- merchant_order_id: Joi.string().allow("").required(),
2304
- amount: Joi.number().required(),
2305
- payment_mode: Joi.string().allow("").required(),
2306
- outstanding_details_id: Joi.number().required(),
2307
- aggregator_transaction_id: Joi.string().allow("").required(),
2308
- aggregator_order_id: Joi.string().allow("").required(),
2309
- payment_mode_identifier: Joi.string().allow("").required(),
2310
- });
2311
- }
2312
-
2313
- /** @returns {RepaymentDetailsSerialiserPayAll} */
2314
- static RepaymentDetailsSerialiserPayAll() {
2315
- return Joi.object({
2316
- total_amount: Joi.number().required(),
2317
- extension_order_id: Joi.string().allow("").allow(null).required(),
2318
- aggregator_transaction_id: Joi.string().allow("").required(),
2319
- aggregator_order_id: Joi.string().allow("").required(),
2320
- shipment_details: Joi.array().items(
2321
- PaymentPlatformModel.RepaymentRequestDetails()
2322
- ),
2323
- });
2324
- }
2325
-
2326
- /** @returns {RepaymentResponse} */
2327
- static RepaymentResponse() {
2328
- return Joi.object({
2329
- data: Joi.any().required(),
2330
- success: Joi.boolean().required(),
2331
- });
2332
- }
2333
-
2334
- /** @returns {MerchantOnBoardingRequest} */
2335
- static MerchantOnBoardingRequest() {
2336
- return Joi.object({
2337
- credit_line_id: Joi.string().allow("").required(),
2338
- aggregator: Joi.string().allow("").required(),
2339
- app_id: Joi.string().allow("").required(),
2340
- user_id: Joi.string().allow("").required(),
2341
- status: Joi.string().allow("").required(),
2342
- });
2343
- }
2344
-
2345
- /** @returns {MerchantOnBoardingResponse} */
2346
- static MerchantOnBoardingResponse() {
2347
- return Joi.object({
2348
- data: Joi.any().required(),
2349
- success: Joi.boolean().required(),
2350
- });
2351
- }
2352
-
2353
- /** @returns {ValidateCustomerRequest} */
2354
- static ValidateCustomerRequest() {
2252
+ /** @returns {ValidateCustomerCreation} */
2253
+ static ValidateCustomerCreation() {
2355
2254
  return Joi.object({
2356
2255
  phone_number: Joi.string().allow("").required(),
2357
2256
  aggregator: Joi.string().allow("").required(),
2358
2257
  payload: Joi.string().allow("").allow(null),
2359
- delivery_address: Joi.any(),
2258
+ delivery_address: Joi.object().pattern(/\S/, Joi.any()),
2360
2259
  transaction_amount_in_paise: Joi.number().required(),
2361
2260
  order_items: Joi.array().items(Joi.any()),
2362
- merchant_params: Joi.any(),
2363
- billing_address: Joi.any(),
2261
+ merchant_params: Joi.object().pattern(/\S/, Joi.any()),
2262
+ billing_address: Joi.object().pattern(/\S/, Joi.any()),
2364
2263
  });
2365
2264
  }
2366
2265
 
2367
- /** @returns {ValidateCustomerResponse} */
2368
- static ValidateCustomerResponse() {
2266
+ /** @returns {ValidateCustomerDetails} */
2267
+ static ValidateCustomerDetails() {
2369
2268
  return Joi.object({
2370
2269
  message: Joi.string().allow("").required(),
2371
- data: Joi.any(),
2270
+ data: Joi.object().pattern(/\S/, Joi.any()),
2372
2271
  success: Joi.boolean().required(),
2373
2272
  });
2374
2273
  }
2375
2274
 
2376
- /** @returns {GetPaymentLinkResponse} */
2377
- static GetPaymentLinkResponse() {
2275
+ /** @returns {GetPaymentLinkDetails} */
2276
+ static GetPaymentLinkDetails() {
2378
2277
  return Joi.object({
2379
2278
  message: Joi.string().allow("").required(),
2380
2279
  status_code: Joi.number().required(),
@@ -2402,8 +2301,8 @@ class PaymentPlatformModel {
2402
2301
  });
2403
2302
  }
2404
2303
 
2405
- /** @returns {ErrorResponse} */
2406
- static ErrorResponse() {
2304
+ /** @returns {ErrorDetails} */
2305
+ static ErrorDetails() {
2407
2306
  return Joi.object({
2408
2307
  status_code: Joi.number().required(),
2409
2308
  error: PaymentPlatformModel.ErrorDescription(),
@@ -2422,8 +2321,8 @@ class PaymentPlatformModel {
2422
2321
  });
2423
2322
  }
2424
2323
 
2425
- /** @returns {CreatePaymentLinkRequest} */
2426
- static CreatePaymentLinkRequest() {
2324
+ /** @returns {CreatePaymentLinkCreation} */
2325
+ static CreatePaymentLinkCreation() {
2427
2326
  return Joi.object({
2428
2327
  email: Joi.string().allow("").required(),
2429
2328
  amount: Joi.number().required(),
@@ -2432,11 +2331,14 @@ class PaymentPlatformModel {
2432
2331
  description: Joi.string().allow("").allow(null),
2433
2332
  meta: PaymentPlatformModel.CreatePaymentLinkMeta().required(),
2434
2333
  external_order_id: Joi.string().allow("").required(),
2334
+ success_redirection_url: Joi.string().allow(""),
2335
+ failure_redirection_url: Joi.string().allow(""),
2336
+ send_communication: Joi.boolean(),
2435
2337
  });
2436
2338
  }
2437
2339
 
2438
- /** @returns {CreatePaymentLinkResponse} */
2439
- static CreatePaymentLinkResponse() {
2340
+ /** @returns {CreatePaymentLinkDetails} */
2341
+ static CreatePaymentLinkDetails() {
2440
2342
  return Joi.object({
2441
2343
  message: Joi.string().allow("").required(),
2442
2344
  status_code: Joi.number().required(),
@@ -2447,8 +2349,8 @@ class PaymentPlatformModel {
2447
2349
  });
2448
2350
  }
2449
2351
 
2450
- /** @returns {PollingPaymentLinkResponse} */
2451
- static PollingPaymentLinkResponse() {
2352
+ /** @returns {PollingPaymentLinkDetails} */
2353
+ static PollingPaymentLinkDetails() {
2452
2354
  return Joi.object({
2453
2355
  message: Joi.string().allow("").allow(null),
2454
2356
  http_status: Joi.number().allow(null),
@@ -2463,15 +2365,15 @@ class PaymentPlatformModel {
2463
2365
  });
2464
2366
  }
2465
2367
 
2466
- /** @returns {CancelOrResendPaymentLinkRequest} */
2467
- static CancelOrResendPaymentLinkRequest() {
2368
+ /** @returns {CancelOrResendPaymentLinkCreation} */
2369
+ static CancelOrResendPaymentLinkCreation() {
2468
2370
  return Joi.object({
2469
2371
  payment_link_id: Joi.string().allow("").required(),
2470
2372
  });
2471
2373
  }
2472
2374
 
2473
- /** @returns {ResendPaymentLinkResponse} */
2474
- static ResendPaymentLinkResponse() {
2375
+ /** @returns {ResendPaymentLinkDetails} */
2376
+ static ResendPaymentLinkDetails() {
2475
2377
  return Joi.object({
2476
2378
  status_code: Joi.number().required(),
2477
2379
  message: Joi.string().allow("").required(),
@@ -2480,8 +2382,8 @@ class PaymentPlatformModel {
2480
2382
  });
2481
2383
  }
2482
2384
 
2483
- /** @returns {CancelPaymentLinkResponse} */
2484
- static CancelPaymentLinkResponse() {
2385
+ /** @returns {CancelPaymentLinkDetails} */
2386
+ static CancelPaymentLinkDetails() {
2485
2387
  return Joi.object({
2486
2388
  status_code: Joi.number().required(),
2487
2389
  message: Joi.string().allow("").required(),
@@ -2515,16 +2417,16 @@ class PaymentPlatformModel {
2515
2417
  });
2516
2418
  }
2517
2419
 
2518
- /** @returns {GetPaymentCodeResponse} */
2519
- static GetPaymentCodeResponse() {
2420
+ /** @returns {GetPaymentCodeDetails} */
2421
+ static GetPaymentCodeDetails() {
2520
2422
  return Joi.object({
2521
2423
  data: PaymentPlatformModel.GetPaymentCode().required(),
2522
2424
  success: Joi.boolean().required(),
2523
2425
  });
2524
2426
  }
2525
2427
 
2526
- /** @returns {PlatformPaymentModeResponse} */
2527
- static PlatformPaymentModeResponse() {
2428
+ /** @returns {PlatformPaymentModeDetails} */
2429
+ static PlatformPaymentModeDetails() {
2528
2430
  return Joi.object({
2529
2431
  message: Joi.string().allow("").allow(null),
2530
2432
  items: Joi.array().items(Joi.any()).allow(null, ""),
@@ -2532,11 +2434,125 @@ class PaymentPlatformModel {
2532
2434
  });
2533
2435
  }
2534
2436
 
2535
- /** @returns {MerchnatPaymentModeRequest} */
2536
- static MerchnatPaymentModeRequest() {
2437
+ /** @returns {PaymentModeConfig} */
2438
+ static PaymentModeConfig() {
2439
+ return Joi.object({
2440
+ business_unit: Joi.string().allow(""),
2441
+ device: Joi.string().allow(""),
2442
+ is_active: Joi.boolean(),
2443
+ items: Joi.array().items(PaymentPlatformModel.PaymentModeItems()),
2444
+ });
2445
+ }
2446
+
2447
+ /** @returns {PaymentModeItems} */
2448
+ static PaymentModeItems() {
2537
2449
  return Joi.object({
2538
- offline: Joi.any().allow(null),
2539
- online: Joi.any().allow(null),
2450
+ id: Joi.number(),
2451
+ name: Joi.string().allow(""),
2452
+ short_code: Joi.string().allow(""),
2453
+ logos: PaymentPlatformModel.LogoSet(),
2454
+ is_active: Joi.boolean(),
2455
+ sub_payment_mode: Joi.array().items(
2456
+ PaymentPlatformModel.SubPaymentMode()
2457
+ ),
2458
+ is_active_at_pg: Joi.boolean(),
2459
+ fulfillment_options: Joi.object().pattern(/\S/, Joi.any()),
2460
+ });
2461
+ }
2462
+
2463
+ /** @returns {SubPaymentMode} */
2464
+ static SubPaymentMode() {
2465
+ return Joi.object({
2466
+ code: Joi.string().allow(""),
2467
+ is_active: Joi.boolean(),
2468
+ priority: Joi.number(),
2469
+ logos: PaymentPlatformModel.LogoSet(),
2470
+ name: Joi.string().allow(""),
2471
+ is_active_at_pg: Joi.boolean(),
2472
+ });
2473
+ }
2474
+
2475
+ /** @returns {LogoSet} */
2476
+ static LogoSet() {
2477
+ return Joi.object({
2478
+ large: Joi.string().allow(""),
2479
+ small: Joi.string().allow(""),
2480
+ });
2481
+ }
2482
+
2483
+ /** @returns {PlatformLogoSet} */
2484
+ static PlatformLogoSet() {
2485
+ return Joi.object({
2486
+ large: Joi.string().allow(""),
2487
+ small: Joi.string().allow(""),
2488
+ });
2489
+ }
2490
+
2491
+ /** @returns {PlatformConfigPaymentModeDetails} */
2492
+ static PlatformConfigPaymentModeDetails() {
2493
+ return Joi.object({
2494
+ business_unit: Joi.string().allow(""),
2495
+ device: Joi.string().allow(""),
2496
+ fulfillment_options: Joi.object().pattern(/\S/, Joi.any()),
2497
+ is_active: Joi.boolean(),
2498
+ items: Joi.array().items(PaymentPlatformModel.PlatformPaymentModeItem()),
2499
+ });
2500
+ }
2501
+
2502
+ /** @returns {PlatformPaymentModeItem} */
2503
+ static PlatformPaymentModeItem() {
2504
+ return Joi.object({
2505
+ id: Joi.number(),
2506
+ name: Joi.string().allow(""),
2507
+ short_code: Joi.string().allow(""),
2508
+ logos: PaymentPlatformModel.PlatformLogoSet(),
2509
+ is_active: Joi.boolean(),
2510
+ is_active_at_pg: Joi.boolean(),
2511
+ sub_payment_mode: Joi.array().items(
2512
+ PaymentPlatformModel.PlatformSubPaymentMode()
2513
+ ),
2514
+ });
2515
+ }
2516
+
2517
+ /** @returns {PlatformSubPaymentMode} */
2518
+ static PlatformSubPaymentMode() {
2519
+ return Joi.object({
2520
+ code: Joi.string().allow(""),
2521
+ name: Joi.string().allow(""),
2522
+ is_active: Joi.boolean(),
2523
+ is_active_at_pg: Joi.boolean(),
2524
+ priority: Joi.number(),
2525
+ logos: PaymentPlatformModel.PlatformLogoSet(),
2526
+ });
2527
+ }
2528
+
2529
+ /** @returns {MerchnatPaymentModeCreation} */
2530
+ static MerchnatPaymentModeCreation() {
2531
+ return Joi.object({
2532
+ offline: Joi.object().pattern(/\S/, Joi.any()).allow(null, ""),
2533
+ online: Joi.object().pattern(/\S/, Joi.any()).allow(null, ""),
2534
+ });
2535
+ }
2536
+
2537
+ /** @returns {SkuDetails} */
2538
+ static SkuDetails() {
2539
+ return Joi.object({
2540
+ identifier: Joi.string().allow(""),
2541
+ sku_id: Joi.string().allow(""),
2542
+ sku_name: Joi.string().allow(""),
2543
+ });
2544
+ }
2545
+
2546
+ /** @returns {AppliedOffer} */
2547
+ static AppliedOffer() {
2548
+ return Joi.object({
2549
+ is_mop: Joi.boolean(),
2550
+ offer_type: Joi.string().allow(""),
2551
+ offer_id: Joi.string().allow(""),
2552
+ description: Joi.string().allow(""),
2553
+ amount: Joi.number(),
2554
+ meta: Joi.object().pattern(/\S/, Joi.any()),
2555
+ sku_details: Joi.array().items(PaymentPlatformModel.SkuDetails()),
2540
2556
  });
2541
2557
  }
2542
2558
 
@@ -2547,22 +2563,25 @@ class PaymentPlatformModel {
2547
2563
  amount: Joi.number().required(),
2548
2564
  status: Joi.string().allow("").required(),
2549
2565
  currency: Joi.string().allow("").required(),
2550
- aggregator_order_details: Joi.any().required(),
2566
+ aggregator_order_details: Joi.object()
2567
+ .pattern(/\S/, Joi.any())
2568
+ .required(),
2551
2569
  aggregator: Joi.string().allow("").required(),
2570
+ applied_offers: Joi.array().items(PaymentPlatformModel.AppliedOffer()),
2552
2571
  });
2553
2572
  }
2554
2573
 
2555
2574
  /** @returns {AddressDetail} */
2556
2575
  static AddressDetail() {
2557
2576
  return Joi.object({
2558
- google_map_point: Joi.any(),
2577
+ google_map_point: Joi.object().pattern(/\S/, Joi.any()),
2559
2578
  landmark: Joi.string().allow(""),
2560
2579
  phone: Joi.string().allow("").required(),
2561
2580
  country_iso_code: Joi.string().allow("").required(),
2562
2581
  area_code: Joi.string().allow("").required(),
2563
2582
  country: Joi.string().allow("").required(),
2564
2583
  expire_at: Joi.string().allow(""),
2565
- geo_location: Joi.any(),
2584
+ geo_location: Joi.object().pattern(/\S/, Joi.any()),
2566
2585
  state: Joi.string().allow("").required(),
2567
2586
  area: Joi.string().allow("").required(),
2568
2587
  g_address_id: Joi.string().allow("").required(),
@@ -2577,6 +2596,14 @@ class PaymentPlatformModel {
2577
2596
  });
2578
2597
  }
2579
2598
 
2599
+ /** @returns {ReasonDetail} */
2600
+ static ReasonDetail() {
2601
+ return Joi.object({
2602
+ code: Joi.string().allow(""),
2603
+ description: Joi.string().allow(""),
2604
+ });
2605
+ }
2606
+
2580
2607
  /** @returns {PaymentSessionDetail} */
2581
2608
  static PaymentSessionDetail() {
2582
2609
  return Joi.object({
@@ -2600,15 +2627,16 @@ class PaymentPlatformModel {
2600
2627
  kind: Joi.string().allow(""),
2601
2628
  billing_address: PaymentPlatformModel.AddressDetail(),
2602
2629
  captured: Joi.boolean(),
2603
- meta: Joi.any(),
2630
+ meta: Joi.object().pattern(/\S/, Joi.any()),
2604
2631
  status: Joi.string().allow("").required(),
2632
+ reason: PaymentPlatformModel.ReasonDetail(),
2605
2633
  });
2606
2634
  }
2607
2635
 
2608
- /** @returns {PaymentSessionRequestSerializer} */
2609
- static PaymentSessionRequestSerializer() {
2636
+ /** @returns {PaymentSessionCreation} */
2637
+ static PaymentSessionCreation() {
2610
2638
  return Joi.object({
2611
- meta: Joi.any(),
2639
+ meta: Joi.object().pattern(/\S/, Joi.any()),
2612
2640
  gid: Joi.string().allow("").required(),
2613
2641
  order_details: PaymentPlatformModel.OrderDetail().required(),
2614
2642
  status: Joi.string().allow("").required(),
@@ -2622,8 +2650,8 @@ class PaymentPlatformModel {
2622
2650
  });
2623
2651
  }
2624
2652
 
2625
- /** @returns {PaymentSessionResponseSerializer} */
2626
- static PaymentSessionResponseSerializer() {
2653
+ /** @returns {PaymentSessionPutDetails} */
2654
+ static PaymentSessionPutDetails() {
2627
2655
  return Joi.object({
2628
2656
  gid: Joi.string().allow("").required(),
2629
2657
  platform_transaction_details: Joi.array().items(Joi.any()).required(),
@@ -2652,10 +2680,10 @@ class PaymentPlatformModel {
2652
2680
  });
2653
2681
  }
2654
2682
 
2655
- /** @returns {RefundSessionRequestSerializer} */
2656
- static RefundSessionRequestSerializer() {
2683
+ /** @returns {RefundSessionCreation} */
2684
+ static RefundSessionCreation() {
2657
2685
  return Joi.object({
2658
- meta: Joi.any(),
2686
+ meta: Joi.object().pattern(/\S/, Joi.any()),
2659
2687
  gid: Joi.string().allow("").required(),
2660
2688
  status: Joi.string().allow("").required(),
2661
2689
  currency: Joi.string().allow("").required(),
@@ -2670,8 +2698,8 @@ class PaymentPlatformModel {
2670
2698
  });
2671
2699
  }
2672
2700
 
2673
- /** @returns {RefundSessionResponseSerializer} */
2674
- static RefundSessionResponseSerializer() {
2701
+ /** @returns {RefundSessionDetails} */
2702
+ static RefundSessionDetails() {
2675
2703
  return Joi.object({
2676
2704
  gid: Joi.string().allow("").required(),
2677
2705
  status: Joi.string().allow("").required(),
@@ -2681,8 +2709,8 @@ class PaymentPlatformModel {
2681
2709
  });
2682
2710
  }
2683
2711
 
2684
- /** @returns {PaymentDetailsSerializer} */
2685
- static PaymentDetailsSerializer() {
2712
+ /** @returns {PaymentDetails} */
2713
+ static PaymentDetails() {
2686
2714
  return Joi.object({
2687
2715
  payment_methods: Joi.array().items(Joi.any()).required(),
2688
2716
  gid: Joi.string().allow("").required(),
@@ -2690,7 +2718,7 @@ class PaymentPlatformModel {
2690
2718
  currency: Joi.string().allow("").required(),
2691
2719
  mode: Joi.string().allow("").required(),
2692
2720
  merchant_locale: Joi.string().allow(""),
2693
- meta: Joi.any().allow(null),
2721
+ meta: Joi.object().pattern(/\S/, Joi.any()).allow(null, ""),
2694
2722
  kind: Joi.string().allow(""),
2695
2723
  success_url: Joi.string().allow(""),
2696
2724
  status: Joi.string().allow("").required(),
@@ -2707,10 +2735,10 @@ class PaymentPlatformModel {
2707
2735
  });
2708
2736
  }
2709
2737
 
2710
- /** @returns {CartDetailsSerializer} */
2711
- static CartDetailsSerializer() {
2738
+ /** @returns {CartDetails} */
2739
+ static CartDetails() {
2712
2740
  return Joi.object({
2713
- items: Joi.any().required(),
2741
+ items: Joi.object().pattern(/\S/, Joi.any()).required(),
2714
2742
  articles: Joi.array().items(Joi.any()).required(),
2715
2743
  cart_value: Joi.number().required(),
2716
2744
  total_quantity: Joi.number(),
@@ -2718,8 +2746,8 @@ class PaymentPlatformModel {
2718
2746
  });
2719
2747
  }
2720
2748
 
2721
- /** @returns {RefundDetailsSerializer} */
2722
- static RefundDetailsSerializer() {
2749
+ /** @returns {RefundDetails} */
2750
+ static RefundDetails() {
2723
2751
  return Joi.object({
2724
2752
  amount: Joi.number().required(),
2725
2753
  currency: Joi.string().allow("").required(),
@@ -2730,17 +2758,17 @@ class PaymentPlatformModel {
2730
2758
  });
2731
2759
  }
2732
2760
 
2733
- /** @returns {PaymentSessionSerializer} */
2734
- static PaymentSessionSerializer() {
2761
+ /** @returns {PaymentSessionFetchDetails} */
2762
+ static PaymentSessionFetchDetails() {
2735
2763
  return Joi.object({
2736
2764
  payment_details: Joi.any().required(),
2737
2765
  currency: Joi.string().allow("").allow(null),
2738
2766
  status: Joi.string().allow("").required(),
2739
2767
  total_amount: Joi.number().required(),
2740
- gid: Joi.string().allow("").allow(null).required(),
2741
- cart_details: PaymentPlatformModel.CartDetailsSerializer(),
2768
+ gid: Joi.string().allow("").required(),
2769
+ cart_details: PaymentPlatformModel.CartDetails(),
2742
2770
  refund_details: Joi.array()
2743
- .items(PaymentPlatformModel.RefundDetailsSerializer())
2771
+ .items(PaymentPlatformModel.RefundDetails())
2744
2772
  .required(),
2745
2773
  });
2746
2774
  }
@@ -2754,8 +2782,8 @@ class PaymentPlatformModel {
2754
2782
  });
2755
2783
  }
2756
2784
 
2757
- /** @returns {RefundPriorityResponseSerializer} */
2758
- static RefundPriorityResponseSerializer() {
2785
+ /** @returns {RefundPriorityDetails} */
2786
+ static RefundPriorityDetails() {
2759
2787
  return Joi.object({
2760
2788
  configuration: Joi.string().allow("").required(),
2761
2789
  success: Joi.boolean().required(),
@@ -2767,8 +2795,8 @@ class PaymentPlatformModel {
2767
2795
  });
2768
2796
  }
2769
2797
 
2770
- /** @returns {RefundPriorityRequestSerializer} */
2771
- static RefundPriorityRequestSerializer() {
2798
+ /** @returns {RefundPriorityCreation} */
2799
+ static RefundPriorityCreation() {
2772
2800
  return Joi.object({
2773
2801
  apportion: Joi.boolean().required(),
2774
2802
  refund_sources_priority: Joi.array()
@@ -2777,12 +2805,12 @@ class PaymentPlatformModel {
2777
2805
  });
2778
2806
  }
2779
2807
 
2780
- /** @returns {MerchantPaymentModeRequest} */
2781
- static MerchantPaymentModeRequest() {
2808
+ /** @returns {MerchantPaymentModeCreation} */
2809
+ static MerchantPaymentModeCreation() {
2782
2810
  return Joi.object({
2783
2811
  business_unit: Joi.string().allow("").required(),
2784
2812
  items: Joi.array().items(Joi.any()).required(),
2785
- device: Joi.any().required(),
2813
+ device: Joi.object().pattern(/\S/, Joi.any()).required(),
2786
2814
  });
2787
2815
  }
2788
2816
 
@@ -2802,8 +2830,8 @@ class PaymentPlatformModel {
2802
2830
  });
2803
2831
  }
2804
2832
 
2805
- /** @returns {PlatformPaymentModeCopyConfigRequest} */
2806
- static PlatformPaymentModeCopyConfigRequest() {
2833
+ /** @returns {PlatformPaymentModeCopyConfigCreation} */
2834
+ static PlatformPaymentModeCopyConfigCreation() {
2807
2835
  return Joi.object({
2808
2836
  from_config: PaymentPlatformModel.FromConfig().required(),
2809
2837
  to_config: PaymentPlatformModel.ToConfig().required(),
@@ -2830,8 +2858,8 @@ class PaymentPlatformModel {
2830
2858
  });
2831
2859
  }
2832
2860
 
2833
- /** @returns {PaymentOrderRequest} */
2834
- static PaymentOrderRequest() {
2861
+ /** @returns {PaymentOrderCreation} */
2862
+ static PaymentOrderCreation() {
2835
2863
  return Joi.object({
2836
2864
  order_id: Joi.string().allow("").required(),
2837
2865
  payment_methods: Joi.array().items(
@@ -2857,8 +2885,8 @@ class PaymentPlatformModel {
2857
2885
  });
2858
2886
  }
2859
2887
 
2860
- /** @returns {PaymentOrderResponse} */
2861
- static PaymentOrderResponse() {
2888
+ /** @returns {PaymentOrderDetails} */
2889
+ static PaymentOrderDetails() {
2862
2890
  return Joi.object({
2863
2891
  message: Joi.string().allow("").required(),
2864
2892
  success: Joi.boolean().required(),
@@ -2879,8 +2907,8 @@ class PaymentPlatformModel {
2879
2907
  });
2880
2908
  }
2881
2909
 
2882
- /** @returns {AggregatorVersionResponse} */
2883
- static AggregatorVersionResponse() {
2910
+ /** @returns {AggregatorVersionDetails} */
2911
+ static AggregatorVersionDetails() {
2884
2912
  return Joi.object({
2885
2913
  message: Joi.string().allow("").required(),
2886
2914
  success: Joi.boolean().required(),
@@ -2897,8 +2925,8 @@ class PaymentPlatformModel {
2897
2925
  });
2898
2926
  }
2899
2927
 
2900
- /** @returns {AggregatorControlRequest} */
2901
- static AggregatorControlRequest() {
2928
+ /** @returns {PatchAggregatorControl} */
2929
+ static PatchAggregatorControl() {
2902
2930
  return Joi.object({
2903
2931
  business_unit: Joi.string().allow(""),
2904
2932
  items: Joi.array().items(Joi.any()),
@@ -2980,5 +3008,57 @@ class PaymentPlatformModel {
2980
3008
  .required(),
2981
3009
  });
2982
3010
  }
3011
+
3012
+ /** @returns {CustomerValidationSchema} */
3013
+ static CustomerValidationSchema() {
3014
+ return Joi.object({
3015
+ aggregator: Joi.string().allow("").required(),
3016
+ transaction_amount: Joi.number().required(),
3017
+ cart_id: Joi.string().allow(""),
3018
+ user_id: Joi.string().allow(""),
3019
+ });
3020
+ }
3021
+
3022
+ /** @returns {UserCreditSchema} */
3023
+ static UserCreditSchema() {
3024
+ return Joi.object({
3025
+ amount: Joi.number().required(),
3026
+ currency: Joi.string().allow("").required(),
3027
+ unique_id: Joi.string().allow(""),
3028
+ });
3029
+ }
3030
+
3031
+ /** @returns {CreditAccountSummary} */
3032
+ static CreditAccountSummary() {
3033
+ return Joi.object({
3034
+ account_id: Joi.string().allow("").required(),
3035
+ status: Joi.string().allow("").required(),
3036
+ redeemable_balance: PaymentPlatformModel.UserCreditSchema(),
3037
+ available_balance: PaymentPlatformModel.UserCreditSchema(),
3038
+ amount_on_hold: Joi.array().items(
3039
+ PaymentPlatformModel.UserCreditSchema()
3040
+ ),
3041
+ });
3042
+ }
3043
+
3044
+ /** @returns {ValidateCustomerCreditSchema} */
3045
+ static ValidateCustomerCreditSchema() {
3046
+ return Joi.object({
3047
+ success: Joi.boolean().required(),
3048
+ is_eligible: Joi.boolean().required(),
3049
+ is_applied: Joi.boolean(),
3050
+ message: Joi.string().allow("").required(),
3051
+ cart_id: Joi.string().allow(""),
3052
+ account: PaymentPlatformModel.CreditAccountSummary(),
3053
+ });
3054
+ }
3055
+
3056
+ /** @returns {OperationResponseSchema} */
3057
+ static OperationResponseSchema() {
3058
+ return Joi.object({
3059
+ success: Joi.boolean().required(),
3060
+ message: Joi.string().allow(""),
3061
+ });
3062
+ }
2983
3063
  }
2984
3064
  module.exports = PaymentPlatformModel;