@gofynd/fdk-client-javascript 1.4.16-beta.3 → 1.4.16-beta.4

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 (242) hide show
  1. package/README.md +1 -1
  2. package/package.json +1 -1
  3. package/sdk/application/ApplicationClient.d.ts +0 -2
  4. package/sdk/application/ApplicationClient.js +0 -2
  5. package/sdk/application/Cart/CartApplicationClient.d.ts +48 -68
  6. package/sdk/application/Cart/CartApplicationClient.js +27 -117
  7. package/sdk/application/Catalog/CatalogApplicationClient.d.ts +58 -59
  8. package/sdk/application/Catalog/CatalogApplicationClient.js +29 -30
  9. package/sdk/application/Common/CommonApplicationClient.d.ts +2 -2
  10. package/sdk/application/Common/CommonApplicationClient.js +1 -1
  11. package/sdk/application/Configuration/ConfigurationApplicationClient.d.ts +20 -20
  12. package/sdk/application/Configuration/ConfigurationApplicationClient.js +10 -10
  13. package/sdk/application/Content/ContentApplicationClient.d.ts +30 -51
  14. package/sdk/application/Content/ContentApplicationClient.js +56 -161
  15. package/sdk/application/FileStorage/FileStorageApplicationClient.d.ts +11 -9
  16. package/sdk/application/FileStorage/FileStorageApplicationClient.js +10 -7
  17. package/sdk/application/Lead/LeadApplicationClient.d.ts +2 -2
  18. package/sdk/application/Lead/LeadApplicationClient.js +1 -1
  19. package/sdk/application/Logistic/LogisticApplicationClient.d.ts +15 -35
  20. package/sdk/application/Logistic/LogisticApplicationClient.js +8 -101
  21. package/sdk/application/Order/OrderApplicationClient.d.ts +12 -22
  22. package/sdk/application/Order/OrderApplicationClient.js +8 -56
  23. package/sdk/application/Payment/PaymentApplicationClient.d.ts +87 -87
  24. package/sdk/application/Payment/PaymentApplicationClient.js +46 -46
  25. package/sdk/application/Rewards/RewardsApplicationClient.d.ts +13 -13
  26. package/sdk/application/Rewards/RewardsApplicationClient.js +7 -7
  27. package/sdk/application/Theme/ThemeApplicationClient.d.ts +2 -2
  28. package/sdk/application/Theme/ThemeApplicationClient.js +2 -4
  29. package/sdk/application/User/UserApplicationClient.d.ts +10 -10
  30. package/sdk/application/User/UserApplicationClient.js +6 -6
  31. package/sdk/application/Webhook/WebhookApplicationClient.d.ts +4 -4
  32. package/sdk/application/Webhook/WebhookApplicationClient.js +3 -3
  33. package/sdk/common/Utility.js +6 -3
  34. package/sdk/common/utils.d.ts +0 -1
  35. package/sdk/common/utils.js +0 -14
  36. package/sdk/partner/FileStorage/FileStoragePartnerClient.d.ts +12 -86
  37. package/sdk/partner/FileStorage/FileStoragePartnerClient.js +24 -582
  38. package/sdk/partner/FileStorage/FileStoragePartnerModel.d.ts +21 -116
  39. package/sdk/partner/FileStorage/FileStoragePartnerModel.js +16 -121
  40. package/sdk/partner/FileStorage/FileStoragePartnerValidator.d.ts +1 -8
  41. package/sdk/partner/FileStorage/FileStoragePartnerValidator.js +4 -51
  42. package/sdk/partner/Lead/LeadPartnerClient.d.ts +2 -2
  43. package/sdk/partner/Lead/LeadPartnerClient.js +2 -2
  44. package/sdk/partner/Lead/LeadPartnerModel.d.ts +5 -5
  45. package/sdk/partner/Lead/LeadPartnerModel.js +15 -15
  46. package/sdk/partner/Logistics/LogisticsPartnerClient.d.ts +20 -126
  47. package/sdk/partner/Logistics/LogisticsPartnerClient.js +20 -970
  48. package/sdk/partner/Logistics/LogisticsPartnerModel.d.ts +167 -1200
  49. package/sdk/partner/Logistics/LogisticsPartnerModel.js +160 -571
  50. package/sdk/partner/Logistics/LogisticsPartnerValidator.d.ts +0 -10
  51. package/sdk/partner/Logistics/LogisticsPartnerValidator.js +7 -121
  52. package/sdk/partner/Theme/ThemePartnerClient.d.ts +10 -8
  53. package/sdk/partner/Theme/ThemePartnerClient.js +16 -14
  54. package/sdk/partner/Theme/ThemePartnerModel.d.ts +37 -96
  55. package/sdk/partner/Theme/ThemePartnerModel.js +36 -90
  56. package/sdk/partner/Theme/ThemePartnerValidator.js +4 -4
  57. package/sdk/partner/Webhook/WebhookPartnerClient.d.ts +18 -28
  58. package/sdk/partner/Webhook/WebhookPartnerClient.js +18 -103
  59. package/sdk/partner/Webhook/WebhookPartnerModel.d.ts +179 -612
  60. package/sdk/partner/Webhook/WebhookPartnerModel.js +150 -253
  61. package/sdk/partner/Webhook/WebhookPartnerValidator.d.ts +0 -1
  62. package/sdk/partner/Webhook/WebhookPartnerValidator.js +3 -11
  63. package/sdk/platform/Analytics/AnalyticsPlatformApplicationClient.d.ts +4 -5
  64. package/sdk/platform/Analytics/AnalyticsPlatformApplicationClient.js +8 -14
  65. package/sdk/platform/Analytics/AnalyticsPlatformModel.d.ts +9 -59
  66. package/sdk/platform/Analytics/AnalyticsPlatformModel.js +4 -40
  67. package/sdk/platform/AuditTrail/AuditTrailPlatformClient.d.ts +32 -2
  68. package/sdk/platform/AuditTrail/AuditTrailPlatformClient.js +243 -3
  69. package/sdk/platform/AuditTrail/AuditTrailPlatformModel.d.ts +130 -11
  70. package/sdk/platform/AuditTrail/AuditTrailPlatformModel.js +152 -12
  71. package/sdk/platform/AuditTrail/AuditTrailPlatformValidator.d.ts +39 -1
  72. package/sdk/platform/AuditTrail/AuditTrailPlatformValidator.js +35 -0
  73. package/sdk/platform/Billing/BillingPlatformClient.d.ts +12 -12
  74. package/sdk/platform/Billing/BillingPlatformClient.js +15 -15
  75. package/sdk/platform/Billing/BillingPlatformModel.d.ts +388 -443
  76. package/sdk/platform/Billing/BillingPlatformModel.js +263 -280
  77. package/sdk/platform/Billing/BillingPlatformValidator.d.ts +18 -16
  78. package/sdk/platform/Billing/BillingPlatformValidator.js +9 -8
  79. package/sdk/platform/Cart/CartPlatformApplicationClient.d.ts +103 -134
  80. package/sdk/platform/Cart/CartPlatformApplicationClient.js +115 -419
  81. package/sdk/platform/Cart/CartPlatformApplicationValidator.d.ts +65 -121
  82. package/sdk/platform/Cart/CartPlatformApplicationValidator.js +44 -109
  83. package/sdk/platform/Cart/CartPlatformModel.d.ts +1294 -5068
  84. package/sdk/platform/Cart/CartPlatformModel.js +1217 -1992
  85. package/sdk/platform/Catalog/CatalogPlatformApplicationClient.d.ts +183 -209
  86. package/sdk/platform/Catalog/CatalogPlatformApplicationClient.js +400 -457
  87. package/sdk/platform/Catalog/CatalogPlatformApplicationValidator.d.ts +142 -185
  88. package/sdk/platform/Catalog/CatalogPlatformApplicationValidator.js +78 -96
  89. package/sdk/platform/Catalog/CatalogPlatformClient.d.ts +117 -154
  90. package/sdk/platform/Catalog/CatalogPlatformClient.js +172 -292
  91. package/sdk/platform/Catalog/CatalogPlatformModel.d.ts +1647 -6389
  92. package/sdk/platform/Catalog/CatalogPlatformModel.js +1681 -3222
  93. package/sdk/platform/Catalog/CatalogPlatformValidator.d.ts +31 -72
  94. package/sdk/platform/Catalog/CatalogPlatformValidator.js +24 -50
  95. package/sdk/platform/Common/CommonPlatformClient.d.ts +2 -3
  96. package/sdk/platform/Common/CommonPlatformClient.js +2 -3
  97. package/sdk/platform/Common/CommonPlatformModel.d.ts +9 -9
  98. package/sdk/platform/Common/CommonPlatformModel.js +6 -6
  99. package/sdk/platform/Communication/CommunicationPlatformApplicationClient.d.ts +17 -16
  100. package/sdk/platform/Communication/CommunicationPlatformApplicationClient.js +17 -16
  101. package/sdk/platform/Communication/CommunicationPlatformApplicationValidator.d.ts +8 -8
  102. package/sdk/platform/Communication/CommunicationPlatformApplicationValidator.js +8 -8
  103. package/sdk/platform/Communication/CommunicationPlatformModel.d.ts +33 -43
  104. package/sdk/platform/Communication/CommunicationPlatformModel.js +34 -38
  105. package/sdk/platform/CompanyProfile/CompanyProfilePlatformClient.d.ts +42 -46
  106. package/sdk/platform/CompanyProfile/CompanyProfilePlatformClient.js +43 -47
  107. package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.d.ts +223 -223
  108. package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.js +212 -210
  109. package/sdk/platform/CompanyProfile/CompanyProfilePlatformValidator.d.ts +12 -12
  110. package/sdk/platform/CompanyProfile/CompanyProfilePlatformValidator.js +12 -12
  111. package/sdk/platform/Configuration/ConfigurationPlatformApplicationClient.d.ts +33 -46
  112. package/sdk/platform/Configuration/ConfigurationPlatformApplicationClient.js +54 -67
  113. package/sdk/platform/Configuration/ConfigurationPlatformApplicationValidator.d.ts +18 -18
  114. package/sdk/platform/Configuration/ConfigurationPlatformApplicationValidator.js +18 -18
  115. package/sdk/platform/Configuration/ConfigurationPlatformClient.d.ts +24 -45
  116. package/sdk/platform/Configuration/ConfigurationPlatformClient.js +30 -134
  117. package/sdk/platform/Configuration/ConfigurationPlatformModel.d.ts +131 -283
  118. package/sdk/platform/Configuration/ConfigurationPlatformModel.js +97 -219
  119. package/sdk/platform/Configuration/ConfigurationPlatformValidator.d.ts +9 -37
  120. package/sdk/platform/Configuration/ConfigurationPlatformValidator.js +8 -27
  121. package/sdk/platform/Content/ContentPlatformApplicationClient.d.ts +141 -204
  122. package/sdk/platform/Content/ContentPlatformApplicationClient.js +475 -1073
  123. package/sdk/platform/Content/ContentPlatformApplicationValidator.d.ts +141 -253
  124. package/sdk/platform/Content/ContentPlatformApplicationValidator.js +130 -256
  125. package/sdk/platform/Content/ContentPlatformClient.d.ts +106 -142
  126. package/sdk/platform/Content/ContentPlatformClient.js +336 -523
  127. package/sdk/platform/Content/ContentPlatformModel.d.ts +403 -1375
  128. package/sdk/platform/Content/ContentPlatformModel.js +394 -631
  129. package/sdk/platform/Content/ContentPlatformValidator.d.ts +117 -168
  130. package/sdk/platform/Content/ContentPlatformValidator.js +108 -162
  131. package/sdk/platform/Discount/DiscountPlatformClient.d.ts +12 -14
  132. package/sdk/platform/Discount/DiscountPlatformClient.js +12 -14
  133. package/sdk/platform/Discount/DiscountPlatformModel.d.ts +13 -13
  134. package/sdk/platform/Discount/DiscountPlatformModel.js +12 -12
  135. package/sdk/platform/Discount/DiscountPlatformValidator.d.ts +2 -2
  136. package/sdk/platform/Discount/DiscountPlatformValidator.js +2 -2
  137. package/sdk/platform/FileStorage/FileStoragePlatformApplicationClient.d.ts +39 -95
  138. package/sdk/platform/FileStorage/FileStoragePlatformApplicationClient.js +63 -462
  139. package/sdk/platform/FileStorage/FileStoragePlatformApplicationValidator.d.ts +15 -62
  140. package/sdk/platform/FileStorage/FileStoragePlatformApplicationValidator.js +13 -75
  141. package/sdk/platform/FileStorage/FileStoragePlatformClient.d.ts +22 -20
  142. package/sdk/platform/FileStorage/FileStoragePlatformClient.js +24 -21
  143. package/sdk/platform/FileStorage/FileStoragePlatformModel.d.ts +116 -370
  144. package/sdk/platform/FileStorage/FileStoragePlatformModel.js +104 -313
  145. package/sdk/platform/FileStorage/FileStoragePlatformValidator.d.ts +6 -6
  146. package/sdk/platform/FileStorage/FileStoragePlatformValidator.js +6 -6
  147. package/sdk/platform/Finance/FinancePlatformClient.d.ts +320 -0
  148. package/sdk/platform/Finance/FinancePlatformClient.js +2333 -0
  149. package/sdk/platform/Finance/FinancePlatformModel.d.ts +2890 -0
  150. package/sdk/platform/Finance/FinancePlatformModel.js +2148 -0
  151. package/sdk/platform/Finance/FinancePlatformValidator.d.ts +284 -0
  152. package/sdk/platform/Finance/FinancePlatformValidator.js +354 -0
  153. package/sdk/platform/Lead/LeadPlatformClient.d.ts +2 -2
  154. package/sdk/platform/Lead/LeadPlatformClient.js +2 -2
  155. package/sdk/platform/Lead/LeadPlatformModel.d.ts +5 -5
  156. package/sdk/platform/Lead/LeadPlatformModel.js +16 -16
  157. package/sdk/platform/Order/OrderPlatformApplicationClient.d.ts +6 -17
  158. package/sdk/platform/Order/OrderPlatformApplicationClient.js +7 -85
  159. package/sdk/platform/Order/OrderPlatformApplicationValidator.d.ts +24 -95
  160. package/sdk/platform/Order/OrderPlatformApplicationValidator.js +19 -39
  161. package/sdk/platform/Order/OrderPlatformClient.d.ts +96 -153
  162. package/sdk/platform/Order/OrderPlatformClient.js +198 -416
  163. package/sdk/platform/Order/OrderPlatformModel.d.ts +1286 -7619
  164. package/sdk/platform/Order/OrderPlatformModel.js +1265 -3922
  165. package/sdk/platform/Order/OrderPlatformValidator.d.ts +109 -270
  166. package/sdk/platform/Order/OrderPlatformValidator.js +77 -135
  167. package/sdk/platform/Partner/PartnerPlatformApplicationClient.d.ts +4 -6
  168. package/sdk/platform/Partner/PartnerPlatformApplicationClient.js +7 -9
  169. package/sdk/platform/Partner/PartnerPlatformModel.d.ts +9 -9
  170. package/sdk/platform/Partner/PartnerPlatformModel.js +8 -8
  171. package/sdk/platform/Payment/PaymentPlatformApplicationClient.d.ts +105 -93
  172. package/sdk/platform/Payment/PaymentPlatformApplicationClient.js +141 -129
  173. package/sdk/platform/Payment/PaymentPlatformApplicationValidator.d.ts +48 -48
  174. package/sdk/platform/Payment/PaymentPlatformApplicationValidator.js +48 -48
  175. package/sdk/platform/Payment/PaymentPlatformClient.d.ts +20 -20
  176. package/sdk/platform/Payment/PaymentPlatformClient.js +20 -20
  177. package/sdk/platform/Payment/PaymentPlatformModel.d.ts +319 -333
  178. package/sdk/platform/Payment/PaymentPlatformModel.js +278 -288
  179. package/sdk/platform/Payment/PaymentPlatformValidator.d.ts +8 -8
  180. package/sdk/platform/Payment/PaymentPlatformValidator.js +8 -8
  181. package/sdk/platform/PlatformClient.d.ts +2 -0
  182. package/sdk/platform/PlatformClient.js +4 -0
  183. package/sdk/platform/Rewards/RewardsPlatformApplicationClient.d.ts +2 -2
  184. package/sdk/platform/Rewards/RewardsPlatformApplicationClient.js +2 -2
  185. package/sdk/platform/Rewards/RewardsPlatformApplicationValidator.d.ts +2 -2
  186. package/sdk/platform/Rewards/RewardsPlatformApplicationValidator.js +2 -2
  187. package/sdk/platform/Rewards/RewardsPlatformModel.d.ts +9 -9
  188. package/sdk/platform/Rewards/RewardsPlatformModel.js +8 -8
  189. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationClient.d.ts +36 -46
  190. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationClient.js +41 -132
  191. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationValidator.d.ts +17 -46
  192. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationValidator.js +14 -34
  193. package/sdk/platform/Serviceability/ServiceabilityPlatformClient.d.ts +46 -40
  194. package/sdk/platform/Serviceability/ServiceabilityPlatformClient.js +68 -62
  195. package/sdk/platform/Serviceability/ServiceabilityPlatformModel.d.ts +612 -1845
  196. package/sdk/platform/Serviceability/ServiceabilityPlatformModel.js +554 -886
  197. package/sdk/platform/Serviceability/ServiceabilityPlatformValidator.d.ts +49 -45
  198. package/sdk/platform/Serviceability/ServiceabilityPlatformValidator.js +30 -28
  199. package/sdk/platform/Share/SharePlatformApplicationClient.d.ts +5 -5
  200. package/sdk/platform/Share/SharePlatformApplicationClient.js +9 -9
  201. package/sdk/platform/Share/SharePlatformApplicationValidator.d.ts +6 -3
  202. package/sdk/platform/Share/SharePlatformApplicationValidator.js +2 -2
  203. package/sdk/platform/Share/SharePlatformModel.d.ts +7 -46
  204. package/sdk/platform/Share/SharePlatformModel.js +6 -31
  205. package/sdk/platform/Theme/ThemePlatformApplicationClient.d.ts +3 -3
  206. package/sdk/platform/Theme/ThemePlatformApplicationClient.js +4 -8
  207. package/sdk/platform/Theme/ThemePlatformApplicationValidator.d.ts +0 -5
  208. package/sdk/platform/Theme/ThemePlatformApplicationValidator.js +0 -2
  209. package/sdk/platform/Theme/ThemePlatformModel.d.ts +11 -37
  210. package/sdk/platform/Theme/ThemePlatformModel.js +15 -33
  211. package/sdk/platform/User/UserPlatformApplicationClient.d.ts +12 -12
  212. package/sdk/platform/User/UserPlatformApplicationClient.js +12 -12
  213. package/sdk/platform/User/UserPlatformApplicationValidator.d.ts +2 -2
  214. package/sdk/platform/User/UserPlatformApplicationValidator.js +2 -2
  215. package/sdk/platform/User/UserPlatformModel.d.ts +21 -21
  216. package/sdk/platform/User/UserPlatformModel.js +23 -23
  217. package/sdk/platform/Webhook/WebhookPlatformClient.d.ts +78 -25
  218. package/sdk/platform/Webhook/WebhookPlatformClient.js +470 -75
  219. package/sdk/platform/Webhook/WebhookPlatformModel.d.ts +427 -720
  220. package/sdk/platform/Webhook/WebhookPlatformModel.js +386 -410
  221. package/sdk/platform/Webhook/WebhookPlatformValidator.d.ts +55 -10
  222. package/sdk/platform/Webhook/WebhookPlatformValidator.js +72 -12
  223. package/sdk/platform/index.d.ts +1 -0
  224. package/sdk/platform/index.js +2 -0
  225. package/sdk/public/Configuration/ConfigurationPublicClient.d.ts +2 -3
  226. package/sdk/public/Configuration/ConfigurationPublicClient.js +5 -6
  227. package/sdk/public/Configuration/ConfigurationPublicModel.d.ts +9 -9
  228. package/sdk/public/Configuration/ConfigurationPublicModel.js +6 -6
  229. package/sdk/public/Content/ContentPublicClient.d.ts +2 -112
  230. package/sdk/public/Content/ContentPublicClient.js +6 -810
  231. package/sdk/public/Content/ContentPublicModel.d.ts +3 -549
  232. package/sdk/public/Content/ContentPublicModel.js +3 -649
  233. package/sdk/public/Content/ContentPublicValidator.d.ts +3 -69
  234. package/sdk/public/Content/ContentPublicValidator.js +2 -88
  235. package/sdk/public/Webhook/WebhookPublicClient.d.ts +8 -8
  236. package/sdk/public/Webhook/WebhookPublicClient.js +8 -8
  237. package/sdk/public/Webhook/WebhookPublicModel.d.ts +21 -21
  238. package/sdk/public/Webhook/WebhookPublicModel.js +15 -15
  239. package/sdk/public/Webhook/WebhookPublicValidator.d.ts +4 -4
  240. package/sdk/public/Webhook/WebhookPublicValidator.js +4 -4
  241. package/sdk/application/Finance/FinanceApplicationClient.d.ts +0 -29
  242. package/sdk/application/Finance/FinanceApplicationClient.js +0 -111
@@ -1,41 +1,39 @@
1
1
  const Joi = require("joi");
2
2
 
3
3
  /**
4
- * @typedef BulkRegionServiceabilityTatDetails
5
- * @property {string} country - Name of the country.
6
- * @property {string} region - Name of the region for which the
7
- * tat/serviceability file needs to be downloaded.
8
- * @property {string} type - Denotes the type of file.
4
+ * @typedef BulkRegionServiceabilityTatRequest
5
+ * @property {string} country
6
+ * @property {string} region
7
+ * @property {string} type
9
8
  */
10
9
 
11
10
  /**
12
- * @typedef BulkRegionServiceabilityTatResultItemData
13
- * @property {string} [country] - Name of the country.
14
- * @property {string} [region] - Name of the region for which the
15
- * tat/serviceability file needs to be downloaded.
16
- * @property {string} [type] - Denotes the type of data.
17
- * @property {string} [batch_id] - Unique identifier identifying the perticular request.
18
- * @property {string} [status] - Current status of the request.
19
- * @property {Object[]} [failed_records] - Information of records which failed
20
- * @property {string} [file_path] - CDN path of the file.
11
+ * @typedef BulkRegionServiceabilityTatResponseItemData
12
+ * @property {string} [country]
13
+ * @property {string} [region]
14
+ * @property {string} [type]
15
+ * @property {string} [batch_id]
16
+ * @property {string} [status]
17
+ * @property {Object[]} [failed_records]
18
+ * @property {string} [file_path]
21
19
  */
22
20
 
23
21
  /**
24
- * @typedef ErrorResult
25
- * @property {string} value - Fields containing the error.
26
- * @property {string} message - Description of the error.
27
- * @property {string} type - Type of the error.
22
+ * @typedef ErrorResponse
23
+ * @property {string} value
24
+ * @property {string} message
25
+ * @property {string} type
28
26
  */
29
27
 
30
28
  /**
31
- * @typedef FailureResult
32
- * @property {boolean} success - Denotes if the request was successfully executed.
33
- * @property {ErrorResult[]} error
29
+ * @typedef FailureResponse
30
+ * @property {boolean} success
31
+ * @property {ErrorResponse[]} error
34
32
  */
35
33
 
36
34
  /**
37
- * @typedef BulkRegionServiceabilityTatResult
38
- * @property {BulkRegionServiceabilityTatResultItemData[]} [items]
35
+ * @typedef BulkRegionServiceabilityTatResponse
36
+ * @property {BulkRegionServiceabilityTatResponseItemData[]} [items]
39
37
  * @property {Page} [page]
40
38
  */
41
39
 
@@ -51,353 +49,124 @@ const Joi = require("joi");
51
49
  */
52
50
 
53
51
  /**
54
- * @typedef CourierAccountUpdateDetails
55
- * @property {string} extension_id - Unique identifier of courier partner extension.
56
- * @property {string} scheme_id - Unique identifier of courier partner scheme.
57
- * @property {boolean} is_self_ship - Denotes if the account is of self delivery type.
58
- * @property {string} stage - Denotes whether the account is in enabled or disabled stage.
59
- * @property {boolean} is_own_account - Denotes whether it is the seller's own
60
- * account or not.
61
- */
62
-
63
- /**
64
- * @typedef RegionTatItemResult
65
- * @property {RegionTatResult[]} items
66
- * @property {Page} page
67
- */
68
-
69
- /**
70
- * @typedef RegionServiceabilityItemResult
71
- * @property {RegionServiceabilityResult[]} items
72
- * @property {Page} page
73
- */
74
-
75
- /**
76
- * @typedef ServiceabilityDetailsResult
77
- * @property {boolean} [first_mile] - Boolean value indicating whether
78
- * first-mile service is available or not.
79
- * @property {boolean} [last_mile] - Boolean value indicating whether last-mile
80
- * service is available or not.
81
- * @property {number} [cod_limit] - Limit on the amount of cash on delivery
82
- * (COD) payments allowed in the specified region.
83
- * @property {boolean} [doorstep_return] - Indicates if doorstep return service
84
- * is available. This refers to the ability to return items directly from the
85
- * customer's doorstep.
86
- * @property {boolean} [doorstep_qc] - Indicates if doorstep quality check
87
- * service is available. This refers to the ability to perform quality checks
88
- * on items at the customer's doorstep.
89
- * @property {string} [pickup_cutoff] - Time of day by which pickups must be
90
- * scheduled to be processed on the same day.
91
- * @property {boolean} [installation] - Boolean value indicating whether
92
- * installation services are available in the specified region or not.
93
- * @property {string} [id] - Unique identifier for the serviceability record.
94
- */
95
-
96
- /**
97
- * @typedef ServiceabilityDetails
98
- * @property {boolean} [first_mile] - Boolean value indicating whether
99
- * first-mile service is available or not.
100
- * @property {boolean} [last_mile] - Boolean value indicating whether last-mile
101
- * service is available or not.
102
- * @property {number} [cod_limit] - Limit on the amount of cash on delivery
103
- * (COD) payments allowed in the specified region.
104
- * @property {boolean} [doorstep_return] - Indicates if doorstep return service
105
- * is available. This refers to the ability to return items directly from the
106
- * customer's doorstep.
107
- * @property {boolean} [doorstep_qc] - Indicates if doorstep quality check
108
- * service is available. This refers to the ability to perform quality checks
109
- * on items at the customer's doorstep.
110
- * @property {string} [pickup_cutoff] - Time of day by which pickups must be
111
- * scheduled to be processed on the same day.
112
- * @property {boolean} [installation] - Boolean value indicating whether
113
- * installation services are available in the specified region or not.
114
- */
115
-
116
- /**
117
- * @typedef RegionServiceabilityResult
118
- * @property {string} country_code - ISO2 code representing the country where
119
- * the serviceability is being specified.
120
- * @property {string} [state_code] - Code representing the state or province
121
- * within the country where the serviceability is being specified.
122
- * @property {string} [city_code] - Code representing the city within the state
123
- * where the serviceability is being specified.
124
- * @property {string} [sector_code] - Code representing a specific sector or
125
- * district within the city where the serviceability is being specified.
126
- * @property {string} [pincode] - Postal or ZIP code for the specific area
127
- * within the city where the serviceability is being specified.
128
- * @property {boolean} [first_mile] - Boolean value indicating whether
129
- * first-mile service is available or not.
130
- * @property {boolean} [last_mile] - Boolean value indicating whether last-mile
131
- * service is available or not.
132
- * @property {number} [cod_limit] - Limit on the amount of cash on delivery
133
- * (COD) payments allowed in the specified region.
134
- * @property {boolean} [doorstep_return] - Indicates if doorstep return service
135
- * is available. This refers to the ability to return items directly from the
136
- * customer's doorstep.
137
- * @property {boolean} [doorstep_qc] - Indicates if doorstep quality check
138
- * service is available. This refers to the ability to perform quality checks
139
- * on items at the customer's doorstep.
140
- * @property {string} [pickup_cutoff] - Time of day by which pickups must be
141
- * scheduled to be processed on the same day.
142
- * @property {boolean} [installation] - Boolean value indicating whether
143
- * installation services are available in the specified region or not.
144
- * @property {string} id - Unique identifier for the serviceability record.
145
- */
146
-
147
- /**
148
- * @typedef RegionServiceabilityDetails
149
- * @property {string} country_code - ISO2 code representing the country where
150
- * the serviceability is being specified.
151
- * @property {string} [state_code] - Code representing the state or province
152
- * within the country where the serviceability is being specified.
153
- * @property {string} [city_code] - Code representing the city within the state
154
- * where the serviceability is being specified.
155
- * @property {string} [sector_code] - Code representing a specific sector or
156
- * district within the city where the serviceability is being specified.
157
- * @property {string} [pincode] - Postal or ZIP code for the specific area
158
- * within the city where the serviceability is being specified.
159
- * @property {boolean} [first_mile] - Boolean value indicating whether
160
- * first-mile service is available or not.
161
- * @property {boolean} [last_mile] - Boolean value indicating whether last-mile
162
- * service is available or not.
163
- * @property {number} [cod_limit] - Limit on the amount of cash on delivery
164
- * (COD) payments allowed in the specified region.
165
- * @property {boolean} [doorstep_return] - Indicates if doorstep return service
166
- * is available. This refers to the ability to return items directly from the
167
- * customer's doorstep.
168
- * @property {boolean} [doorstep_qc] - Indicates if doorstep quality check
169
- * service is available. This refers to the ability to perform quality checks
170
- * on items at the customer's doorstep.
171
- * @property {string} [pickup_cutoff] - Time of day by which pickups must be
172
- * scheduled to be processed on the same day.
173
- * @property {boolean} [installation] - Boolean value indicating whether
174
- * installation services are available in the specified region or not.
175
- */
176
-
177
- /**
178
- * @typedef RegionTatDetails
179
- * @property {string} from_country_code - ISO2 code representing the country of
180
- * origin for the delivery.
181
- * @property {string} [from_state_code] - Code representing the state or
182
- * province of origin within the country.
183
- * @property {string} [from_city_code] - Code representing the city of origin
184
- * within the state.
185
- * @property {string} [from_sector_code] - Code representing a specific sector
186
- * or district within the city of origin.
187
- * @property {string} [from_pincode] - Postal or ZIP code of the origin area.
188
- * @property {string} to_country_code - ISO2 code representing the destination country.
189
- * @property {string} [to_state_code] - Code representing the state or province
190
- * of the destination within the country.
191
- * @property {string} [to_city_code] - Code representing the city of destination
192
- * within the state.
193
- * @property {string} [to_sector_code] - Code representing a specific sector or
194
- * district within the city of destination.
195
- * @property {string} [to_pincode] - Postal or ZIP code of the destination area.
196
- * @property {number} [max_delivery_time] - Maximum time required for delivery
197
- * from the origin to the destination in seconds.
198
- * @property {number} [min_delivery_time] - Minimum time required for delivery
199
- * from the origin to the destination in seconds.
200
- */
201
-
202
- /**
203
- * @typedef RegionTatUpdateDetails
204
- * @property {number} [max_delivery_time] - Maximum time required for delivery
205
- * from the origin to the destination in seconds.
206
- * @property {number} [min_delivery_time] - Minimum time required for delivery
207
- * from the origin to the destination in seconds.
208
- */
209
-
210
- /**
211
- * @typedef RegionTatResult
212
- * @property {string} from_country_code - ISO2 code representing the country of
213
- * origin for the delivery.
214
- * @property {string} [from_state_code] - Code representing the state or
215
- * province of origin within the country.
216
- * @property {string} [from_city_code] - Code representing the city of origin
217
- * within the state.
218
- * @property {string} [from_sector_code] - Code representing a specific sector
219
- * or district within the city of origin.
220
- * @property {string} [from_pincode] - Postal or ZIP code of the origin area.
221
- * @property {string} to_country_code - ISO2 code representing the destination country.
222
- * @property {string} [to_state_code] - Code representing the state or province
223
- * of the destination within the country.
224
- * @property {string} [to_city_code] - Code representing the city of destination
225
- * within the state.
226
- * @property {string} [to_sector_code] - Code representing a specific sector or
227
- * district within the city of destination.
228
- * @property {string} [to_pincode] - Postal or ZIP code of the destination area.
229
- * @property {number} [max_delivery_time] - Maximum time required for delivery
230
- * from the origin to the destination in seconds.
231
- * @property {number} [min_delivery_time] - Minimum time required for delivery
232
- * from the origin to the destination in seconds.
233
- * @property {string} id - Unique identifier for the delivery time record.
234
- */
235
-
236
- /**
237
- * @typedef BulkRegionJobDetails
238
- * @property {string} [file_path] - CDN path of the uploaded csv file for bulk import.
239
- * @property {string} country - Country for which the tat or serviceability is
240
- * to be imported or exported.
241
- * @property {string} action - Denotes the import or export action to be performed.
242
- * @property {string} region - Region of the country for which import or export
243
- * is triggered.
52
+ * @typedef BulkRegionJobSerializer
53
+ * @property {string} [file_path]
54
+ * @property {string} country
55
+ * @property {string} action
56
+ * @property {string} region
244
57
  */
245
58
 
246
59
  /**
247
- * @typedef BulkRegionResultItemData
248
- * @property {string} [file_path] - CDN path of the file which was used for bulk import.
249
- * @property {number} [failed] - Count of the failed records.
250
- * @property {Object[]} [failed_records] - Information of records which failed.
251
- * @property {string} action - Denotes the import or export action performed.
252
- * @property {string} batch_id - Unique id to identify the import or export query.
253
- * @property {string} country - Country for which the import or export action is
254
- * performed.
255
- * @property {number} [success] - Denoted if the import or export was successful
256
- * or failure.
257
- * @property {string} region - Region of the country for which import or export
258
- * is triggered.
259
- * @property {string} status - Current status of the import or export action performed.
260
- * @property {number} [total] - Count of total records.
261
- * @property {string} [error_file_path] - Path of the error file.
60
+ * @typedef BulkRegionResponseItemData
61
+ * @property {string} file_path
62
+ * @property {number} [failed]
63
+ * @property {Object[]} [failed_records]
64
+ * @property {string} action
65
+ * @property {string} batch_id
66
+ * @property {string} country
67
+ * @property {number} [success]
68
+ * @property {string} region
69
+ * @property {string} status
70
+ * @property {number} [total]
71
+ * @property {string} [error_file_path]
262
72
  */
263
73
 
264
74
  /**
265
- * @typedef BulkRegionResult
266
- * @property {BulkRegionResultItemData[]} items
75
+ * @typedef BulkRegionResponse
76
+ * @property {BulkRegionResponseItemData[]} items
267
77
  * @property {Page} page
268
78
  */
269
79
 
270
80
  /**
271
81
  * @typedef CourierAccount
272
- * @property {string} extension_id - Unique identifier of courier partner extension.
273
- * @property {string} account_id - Unique identifier of courier partner scheme
274
- * and company id combination.
275
- * @property {string} scheme_id - Unique identifier of courier partner scheme.
276
- * @property {boolean} is_self_ship - Denotes if the account is of self delivery type.
277
- * @property {string} stage - Denotes whether the account is in enabled or disabled stage.
278
- * @property {boolean} is_own_account - Denotes whether it is the seller's own
279
- * account or not.
82
+ * @property {string} extension_id
83
+ * @property {string} account_id
84
+ * @property {string} scheme_id
85
+ * @property {boolean} is_self_ship
86
+ * @property {string} stage
87
+ * @property {boolean} is_own_account
280
88
  */
281
89
 
282
90
  /**
283
- * @typedef CourierAccountDetailsBody
284
- * @property {string} extension_id - Unique identifier of courier partner extension.
285
- * @property {string} [account_id] - Unique identifier of courier partner scheme
286
- * and company id combination.
287
- * @property {string} scheme_id - Unique identifier of courier account.
288
- * @property {boolean} is_self_ship - Denotes if the account is of self delivery type.
289
- * @property {string} stage - Denotes whether the courier account is in enabled
290
- * or disabled stage.
291
- * @property {boolean} is_own_account - Denotes whether it is the seller's own
292
- * account or not.
91
+ * @typedef CourierAccountRequestBody
92
+ * @property {string} extension_id
93
+ * @property {string} [account_id]
94
+ * @property {string} scheme_id
95
+ * @property {boolean} is_self_ship
96
+ * @property {string} stage
97
+ * @property {boolean} is_own_account
293
98
  */
294
99
 
295
100
  /**
296
- * @typedef CourierPartnerAccountFailureResult
101
+ * @typedef CourierPartnerAccountFailureResponse
297
102
  * @property {boolean} success
298
- * @property {ErrorResult[]} error
103
+ * @property {ErrorResponse[]} error
299
104
  */
300
105
 
301
106
  /**
302
- * @typedef CompanyCourierPartnerAccountListResult
303
- * @property {CourierAccountResult[]} items
107
+ * @typedef CompanyCourierPartnerAccountListResponse
108
+ * @property {CourierAccountResponse[]} items
304
109
  * @property {Page} page
305
110
  */
306
111
 
307
112
  /**
308
- * @typedef CourierAccountResult
309
- * @property {string} account_id - Unique identifier of courier partner scheme
310
- * and company id combination.
311
- * @property {string} scheme_id - Unique identifier of courier partner scheme.
113
+ * @typedef CourierAccountResponse
114
+ * @property {string} account_id
115
+ * @property {string} scheme_id
312
116
  * @property {boolean} is_self_ship
313
- * @property {string} stage - Denotes whether the courier account is in enabled
314
- * or disabled stage.
315
- * @property {boolean} is_own_account - Denotes whether it is the seller's own
316
- * account or not.
117
+ * @property {string} stage
118
+ * @property {boolean} is_own_account
317
119
  * @property {CourierPartnerSchemeModel} scheme_rules
318
120
  */
319
121
 
320
122
  /**
321
123
  * @typedef CourierPartnerSchemeModel
322
- * @property {string} extension_id - Unique identifier of courier partner extension.
323
- * @property {string} scheme_id - Unique identifier of courier partner scheme.
324
- * @property {string} name - Name of the scheme
124
+ * @property {string} extension_id
125
+ * @property {string} scheme_id
126
+ * @property {string} name
325
127
  * @property {ArithmeticOperations} weight
326
- * @property {string} transport_type - Mode of transport associated with the
327
- * courier partner scheme.
328
- * @property {string} region - Serviceable region associated with the courier
329
- * partner scheme.
330
- * @property {string} delivery_type - Type of delivery associated with the
331
- * courier partner scheme.
332
- * @property {string[]} payment_mode - Mode of payment associated with the
333
- * courier partner scheme.
334
- * @property {string} stage - Denotes whether the courier partner scheme is in
335
- * enabled or disabled stage.
128
+ * @property {string} transport_type
129
+ * @property {string} region
130
+ * @property {string} delivery_type
131
+ * @property {string[]} payment_mode
132
+ * @property {string} stage
336
133
  * @property {CourierPartnerSchemeFeatures} feature
337
134
  */
338
135
 
339
136
  /**
340
- * @typedef CourierPartnerSchemeDetailsModel
341
- * @property {string} extension_id - Unique identifier of courier partner extension.
342
- * @property {string} [scheme_id] - Unique identifier of courier partner scheme.
343
- * @property {string} name - Name of the courier partner scheme.
137
+ * @typedef CourierPartnerSchemeRequestModel
138
+ * @property {string} extension_id
139
+ * @property {string} [scheme_id]
140
+ * @property {string} name
344
141
  * @property {ArithmeticOperations} weight
345
- * @property {string} transport_type - Mode of transport associated with the
346
- * courier partner scheme.
347
- * @property {string} region - Serviceable region associated with the courier
348
- * partner scheme.
349
- * @property {string} delivery_type - Type of delivery associated with the
350
- * courier partner scheme.
351
- * @property {string[]} payment_mode - Mode of payment associated with the
352
- * courier partner scheme.
353
- * @property {string} stage - Denotes whether the courier partner scheme is in
354
- * enabled or disabled stage.
142
+ * @property {string} transport_type
143
+ * @property {string} region
144
+ * @property {string} delivery_type
145
+ * @property {string[]} payment_mode
146
+ * @property {string} stage
355
147
  * @property {CourierPartnerSchemeFeatures} feature
356
148
  */
357
149
 
358
150
  /**
359
151
  * @typedef CourierPartnerSchemeFeatures
360
- * @property {boolean} [doorstep_qc] - Indicates if the courier partner offers
361
- * doorstep quality check services.
362
- * @property {boolean} [qr] - Specifies whether the courier partner supports QR
363
- * code-based operations.
364
- * @property {boolean} [mps] - Denotes if the courier partner supports
365
- * multi-part shipment services.
366
- * @property {boolean} [ndr] - Indicates if the Non-Delivery Report (NDR)
367
- * feature is supported by the courier partner.
368
- * @property {number} [ndr_attempts] - Number of attempts allowed for resolving
369
- * Non-Delivery Reports (NDR).
370
- * @property {boolean} [dangerous_goods] - Specifies if the courier partner
371
- * handles the transportation of dangerous goods.
372
- * @property {boolean} [fragile_goods] - Indicates whether the courier partner
373
- * manages the shipment of fragile goods.
374
- * @property {boolean} [restricted_goods] - Indicates if the courier partner
375
- * handles restricted goods, as per regulatory guidelines.
376
- * @property {boolean} [cold_storage_goods] - Denotes if the courier partner
377
- * provides cold storage facilities for goods.
378
- * @property {boolean} [doorstep_exchange] - Indicates if the courier partner
379
- * supports doorstep exchange services.
380
- * @property {boolean} [doorstep_return] - Specifies if the courier partner
381
- * offers doorstep return services.
382
- * @property {boolean} [product_installation] - Indicates if the courier partner
383
- * provides product installation services upon delivery.
384
- * @property {boolean} [openbox_delivery] - Specifies whether the courier
385
- * partner supports open-box delivery, allowing customers to inspect goods
386
- * before accepting.
387
- * @property {string} [status_updates] - Describes the type of status updates
388
- * provided by the courier partner (e.g., real-time, periodic).
389
- * @property {boolean} [multi_pick_single_drop] - Indicates if the courier
390
- * partner supports multiple pickups to a single drop location.
391
- * @property {boolean} [single_pick_multi_drop] - Indicates whether the courier
392
- * partner supports single pickup to multiple drop locations.
393
- * @property {boolean} [multi_pick_multi_drop] - Denotes if the courier partner
394
- * offers services for multiple pickups to multiple drop locations.
395
- * @property {boolean} [ewaybill] - Specifies if the courier partner requires or
396
- * supports the generation of e-waybills for shipments.
397
- * @property {number} [qc_shipment_item_quantity] - Defines the maximum quantity
398
- * of items allowed in a quality check shipment.
399
- * @property {number} [non_qc_shipment_item_quantity] - Defines the maximum
400
- * quantity of items allowed in a non-quality check shipment.
152
+ * @property {boolean} [doorstep_qc]
153
+ * @property {boolean} [qr]
154
+ * @property {boolean} [mps]
155
+ * @property {boolean} [ndr]
156
+ * @property {number} [ndr_attempts]
157
+ * @property {boolean} [dangerous_goods]
158
+ * @property {boolean} [fragile_goods]
159
+ * @property {boolean} [restricted_goods]
160
+ * @property {boolean} [cold_storage_goods]
161
+ * @property {boolean} [doorstep_exchange]
162
+ * @property {boolean} [doorstep_return]
163
+ * @property {boolean} [product_installation]
164
+ * @property {boolean} [openbox_delivery]
165
+ * @property {string} [status_updates]
166
+ * @property {boolean} [multi_pick_single_drop]
167
+ * @property {boolean} [single_pick_multi_drop]
168
+ * @property {boolean} [multi_pick_multi_drop]
169
+ * @property {boolean} [ewaybill]
401
170
  */
402
171
 
403
172
  /**
@@ -409,19 +178,14 @@ const Joi = require("joi");
409
178
  */
410
179
 
411
180
  /**
412
- * @typedef CourierPartnerSchemeUpdateDetails
413
- * @property {string} name - Name of the scheme.
181
+ * @typedef CourierPartnerSchemeUpdateRequest
182
+ * @property {string} name
414
183
  * @property {ArithmeticOperations} weight
415
- * @property {string} transport_type - Mode of transport associated with the
416
- * courier partner scheme.
417
- * @property {string} region - Serviceable region associated with the courier
418
- * partner scheme.
419
- * @property {string} delivery_type - Type of delivery associated with the
420
- * courier partner scheme.
421
- * @property {string[]} payment_mode - Mode of payment associated with the
422
- * courier partner scheme.
423
- * @property {string} stage - Denotes whether the courier partner scheme is in
424
- * enabled or disabled stage.
184
+ * @property {string} transport_type
185
+ * @property {string} region
186
+ * @property {string} delivery_type
187
+ * @property {string[]} payment_mode
188
+ * @property {string} stage
425
189
  * @property {CourierPartnerSchemeFeatures} feature
426
190
  */
427
191
 
@@ -433,50 +197,29 @@ const Joi = require("joi");
433
197
 
434
198
  /**
435
199
  * @typedef GetCountriesItems
436
- * @property {string} [id] - Unique identifier of the country.
437
- * @property {string} [name] - Name of the country.
438
- * @property {string} [iso2] - Two-letter ISO code representing the country.
439
- * @property {string} [iso3] - Three-letter ISO code representing the country.
440
- * @property {string[]} [timezones] - List of time zones used in the country
441
- * (e.g., ["America/New_York", "America/Los_Angeles"]).
442
- * @property {HierarchyItems[]} [hierarchy] - Levels within the country (e.g.,
443
- * states, cities) and their slugs (e.g., [{"name": "State", "slug": "state"},
444
- * {"name": "City", "slug": "city"}]).
445
- * @property {string} [phone_code] - International dialing code for the country
446
- * (e.g., "+1").
447
- * @property {string} [currency] - Indicates currency for the country (e.g., "INR").
448
- * @property {string} [type] - Indicates the type of object (e.g., "country").
449
- * @property {string} [latitude] - Geographical latitude of the country (e.g., "37.0902").
450
- * @property {string} [longitude] - Geographical longitude of the country (e.g.,
451
- * "-95.7129").
452
- * @property {string} [display_name] - User-friendly version of the geographical
453
- * data, which may be more descriptive or formatted differently.
454
- * @property {boolean} [has_next_hierarchy] - More detailed hierarchical data is
455
- * available, meaning states, cities, or other regions within the country have
456
- * been populated in the system.
200
+ * @property {string} [id]
201
+ * @property {string} [name]
202
+ * @property {string} [iso2]
203
+ * @property {string} [iso3]
204
+ * @property {string[]} [timezones]
205
+ * @property {HierarchyItems[]} [hierarchy]
206
+ * @property {string} [phone_code]
207
+ * @property {string} [currency]
208
+ * @property {string} [type]
209
+ * @property {string} [latitude]
210
+ * @property {string} [longitude]
211
+ * @property {string} [display_name]
457
212
  */
458
213
 
459
214
  /**
460
215
  * @typedef HierarchyItems
461
- * @property {string} [display_name] - It represent a country display name.
462
- * @property {string} [slug] - A URL-friendly version of the name, often used
463
- * for referencing or querying purposes.
464
- */
465
-
466
- /**
467
- * @typedef ValidationError
468
- * @property {string} message - A brief description of the error encountered.
469
- * @property {string} field - The field in the request that caused the error.
470
- */
471
-
472
- /**
473
- * @typedef StandardError
474
- * @property {string} message - A brief description of the error.
216
+ * @property {string} [display_name]
217
+ * @property {string} [slug]
475
218
  */
476
219
 
477
220
  class LogisticsPartnerModel {
478
- /** @returns {BulkRegionServiceabilityTatDetails} */
479
- static BulkRegionServiceabilityTatDetails() {
221
+ /** @returns {BulkRegionServiceabilityTatRequest} */
222
+ static BulkRegionServiceabilityTatRequest() {
480
223
  return Joi.object({
481
224
  country: Joi.string().allow("").required(),
482
225
  region: Joi.string().allow("").required(),
@@ -484,21 +227,21 @@ class LogisticsPartnerModel {
484
227
  });
485
228
  }
486
229
 
487
- /** @returns {BulkRegionServiceabilityTatResultItemData} */
488
- static BulkRegionServiceabilityTatResultItemData() {
230
+ /** @returns {BulkRegionServiceabilityTatResponseItemData} */
231
+ static BulkRegionServiceabilityTatResponseItemData() {
489
232
  return Joi.object({
490
233
  country: Joi.string().allow(""),
491
234
  region: Joi.string().allow(""),
492
235
  type: Joi.string().allow(""),
493
236
  batch_id: Joi.string().allow(""),
494
237
  status: Joi.string().allow(""),
495
- failed_records: Joi.array().items(Joi.object().pattern(/\S/, Joi.any())),
496
- file_path: Joi.string().allow("").allow(null),
238
+ failed_records: Joi.array().items(Joi.any()),
239
+ file_path: Joi.string().allow(""),
497
240
  });
498
241
  }
499
242
 
500
- /** @returns {ErrorResult} */
501
- static ErrorResult() {
243
+ /** @returns {ErrorResponse} */
244
+ static ErrorResponse() {
502
245
  return Joi.object({
503
246
  value: Joi.string().allow("").required(),
504
247
  message: Joi.string().allow("").required(),
@@ -506,19 +249,21 @@ class LogisticsPartnerModel {
506
249
  });
507
250
  }
508
251
 
509
- /** @returns {FailureResult} */
510
- static FailureResult() {
252
+ /** @returns {FailureResponse} */
253
+ static FailureResponse() {
511
254
  return Joi.object({
512
255
  success: Joi.boolean().required(),
513
- error: Joi.array().items(LogisticsPartnerModel.ErrorResult()).required(),
256
+ error: Joi.array()
257
+ .items(LogisticsPartnerModel.ErrorResponse())
258
+ .required(),
514
259
  });
515
260
  }
516
261
 
517
- /** @returns {BulkRegionServiceabilityTatResult} */
518
- static BulkRegionServiceabilityTatResult() {
262
+ /** @returns {BulkRegionServiceabilityTatResponse} */
263
+ static BulkRegionServiceabilityTatResponse() {
519
264
  return Joi.object({
520
265
  items: Joi.array().items(
521
- LogisticsPartnerModel.BulkRegionServiceabilityTatResultItemData()
266
+ LogisticsPartnerModel.BulkRegionServiceabilityTatResponseItemData()
522
267
  ),
523
268
  page: LogisticsPartnerModel.Page(),
524
269
  });
@@ -537,162 +282,22 @@ class LogisticsPartnerModel {
537
282
  });
538
283
  }
539
284
 
540
- /** @returns {CourierAccountUpdateDetails} */
541
- static CourierAccountUpdateDetails() {
542
- return Joi.object({
543
- extension_id: Joi.string().allow("").required(),
544
- scheme_id: Joi.string().allow("").required(),
545
- is_self_ship: Joi.boolean().required(),
546
- stage: Joi.string().allow("").required(),
547
- is_own_account: Joi.boolean().required(),
548
- });
549
- }
550
-
551
- /** @returns {RegionTatItemResult} */
552
- static RegionTatItemResult() {
553
- return Joi.object({
554
- items: Joi.array()
555
- .items(LogisticsPartnerModel.RegionTatResult())
556
- .required(),
557
- page: LogisticsPartnerModel.Page().required(),
558
- });
559
- }
560
-
561
- /** @returns {RegionServiceabilityItemResult} */
562
- static RegionServiceabilityItemResult() {
563
- return Joi.object({
564
- items: Joi.array()
565
- .items(LogisticsPartnerModel.RegionServiceabilityResult())
566
- .required(),
567
- page: LogisticsPartnerModel.Page().required(),
568
- });
569
- }
570
-
571
- /** @returns {ServiceabilityDetailsResult} */
572
- static ServiceabilityDetailsResult() {
573
- return Joi.object({
574
- first_mile: Joi.boolean(),
575
- last_mile: Joi.boolean(),
576
- cod_limit: Joi.number(),
577
- doorstep_return: Joi.boolean(),
578
- doorstep_qc: Joi.boolean(),
579
- pickup_cutoff: Joi.string().allow(""),
580
- installation: Joi.boolean(),
581
- id: Joi.string().allow(""),
582
- });
583
- }
584
-
585
- /** @returns {ServiceabilityDetails} */
586
- static ServiceabilityDetails() {
587
- return Joi.object({
588
- first_mile: Joi.boolean(),
589
- last_mile: Joi.boolean(),
590
- cod_limit: Joi.number(),
591
- doorstep_return: Joi.boolean(),
592
- doorstep_qc: Joi.boolean(),
593
- pickup_cutoff: Joi.string().allow(""),
594
- installation: Joi.boolean(),
595
- });
596
- }
597
-
598
- /** @returns {RegionServiceabilityResult} */
599
- static RegionServiceabilityResult() {
600
- return Joi.object({
601
- country_code: Joi.string().allow("").required(),
602
- state_code: Joi.string().allow(""),
603
- city_code: Joi.string().allow(""),
604
- sector_code: Joi.string().allow(""),
605
- pincode: Joi.string().allow(""),
606
- first_mile: Joi.boolean(),
607
- last_mile: Joi.boolean(),
608
- cod_limit: Joi.number(),
609
- doorstep_return: Joi.boolean(),
610
- doorstep_qc: Joi.boolean(),
611
- pickup_cutoff: Joi.string().allow(""),
612
- installation: Joi.boolean(),
613
- id: Joi.string().allow("").required(),
614
- });
615
- }
616
-
617
- /** @returns {RegionServiceabilityDetails} */
618
- static RegionServiceabilityDetails() {
619
- return Joi.object({
620
- country_code: Joi.string().allow("").required(),
621
- state_code: Joi.string().allow(""),
622
- city_code: Joi.string().allow(""),
623
- sector_code: Joi.string().allow(""),
624
- pincode: Joi.string().allow(""),
625
- first_mile: Joi.boolean(),
626
- last_mile: Joi.boolean(),
627
- cod_limit: Joi.number(),
628
- doorstep_return: Joi.boolean(),
629
- doorstep_qc: Joi.boolean(),
630
- pickup_cutoff: Joi.string().allow(""),
631
- installation: Joi.boolean(),
632
- });
633
- }
634
-
635
- /** @returns {RegionTatDetails} */
636
- static RegionTatDetails() {
637
- return Joi.object({
638
- from_country_code: Joi.string().allow("").required(),
639
- from_state_code: Joi.string().allow(""),
640
- from_city_code: Joi.string().allow(""),
641
- from_sector_code: Joi.string().allow(""),
642
- from_pincode: Joi.string().allow(""),
643
- to_country_code: Joi.string().allow("").required(),
644
- to_state_code: Joi.string().allow(""),
645
- to_city_code: Joi.string().allow(""),
646
- to_sector_code: Joi.string().allow(""),
647
- to_pincode: Joi.string().allow(""),
648
- max_delivery_time: Joi.number(),
649
- min_delivery_time: Joi.number(),
650
- });
651
- }
652
-
653
- /** @returns {RegionTatUpdateDetails} */
654
- static RegionTatUpdateDetails() {
285
+ /** @returns {BulkRegionJobSerializer} */
286
+ static BulkRegionJobSerializer() {
655
287
  return Joi.object({
656
- max_delivery_time: Joi.number(),
657
- min_delivery_time: Joi.number(),
658
- });
659
- }
660
-
661
- /** @returns {RegionTatResult} */
662
- static RegionTatResult() {
663
- return Joi.object({
664
- from_country_code: Joi.string().allow("").required(),
665
- from_state_code: Joi.string().allow(""),
666
- from_city_code: Joi.string().allow(""),
667
- from_sector_code: Joi.string().allow(""),
668
- from_pincode: Joi.string().allow(""),
669
- to_country_code: Joi.string().allow("").required(),
670
- to_state_code: Joi.string().allow(""),
671
- to_city_code: Joi.string().allow(""),
672
- to_sector_code: Joi.string().allow(""),
673
- to_pincode: Joi.string().allow(""),
674
- max_delivery_time: Joi.number(),
675
- min_delivery_time: Joi.number(),
676
- id: Joi.string().allow("").required(),
677
- });
678
- }
679
-
680
- /** @returns {BulkRegionJobDetails} */
681
- static BulkRegionJobDetails() {
682
- return Joi.object({
683
- file_path: Joi.string().allow("").allow(null),
288
+ file_path: Joi.string().allow(""),
684
289
  country: Joi.string().allow("").required(),
685
290
  action: Joi.string().allow("").required(),
686
291
  region: Joi.string().allow("").required(),
687
292
  });
688
293
  }
689
294
 
690
- /** @returns {BulkRegionResultItemData} */
691
- static BulkRegionResultItemData() {
295
+ /** @returns {BulkRegionResponseItemData} */
296
+ static BulkRegionResponseItemData() {
692
297
  return Joi.object({
693
- file_path: Joi.string().allow(""),
298
+ file_path: Joi.string().allow("").required(),
694
299
  failed: Joi.number(),
695
- failed_records: Joi.array().items(Joi.object().pattern(/\S/, Joi.any())),
300
+ failed_records: Joi.array().items(Joi.any()),
696
301
  action: Joi.string().allow("").required(),
697
302
  batch_id: Joi.string().allow("").required(),
698
303
  country: Joi.string().allow("").required(),
@@ -704,11 +309,11 @@ class LogisticsPartnerModel {
704
309
  });
705
310
  }
706
311
 
707
- /** @returns {BulkRegionResult} */
708
- static BulkRegionResult() {
312
+ /** @returns {BulkRegionResponse} */
313
+ static BulkRegionResponse() {
709
314
  return Joi.object({
710
315
  items: Joi.array()
711
- .items(LogisticsPartnerModel.BulkRegionResultItemData())
316
+ .items(LogisticsPartnerModel.BulkRegionResponseItemData())
712
317
  .required(),
713
318
  page: LogisticsPartnerModel.Page().required(),
714
319
  });
@@ -726,8 +331,8 @@ class LogisticsPartnerModel {
726
331
  });
727
332
  }
728
333
 
729
- /** @returns {CourierAccountDetailsBody} */
730
- static CourierAccountDetailsBody() {
334
+ /** @returns {CourierAccountRequestBody} */
335
+ static CourierAccountRequestBody() {
731
336
  return Joi.object({
732
337
  extension_id: Joi.string().allow("").required(),
733
338
  account_id: Joi.string().allow(""),
@@ -738,26 +343,28 @@ class LogisticsPartnerModel {
738
343
  });
739
344
  }
740
345
 
741
- /** @returns {CourierPartnerAccountFailureResult} */
742
- static CourierPartnerAccountFailureResult() {
346
+ /** @returns {CourierPartnerAccountFailureResponse} */
347
+ static CourierPartnerAccountFailureResponse() {
743
348
  return Joi.object({
744
349
  success: Joi.boolean().required(),
745
- error: Joi.array().items(LogisticsPartnerModel.ErrorResult()).required(),
350
+ error: Joi.array()
351
+ .items(LogisticsPartnerModel.ErrorResponse())
352
+ .required(),
746
353
  });
747
354
  }
748
355
 
749
- /** @returns {CompanyCourierPartnerAccountListResult} */
750
- static CompanyCourierPartnerAccountListResult() {
356
+ /** @returns {CompanyCourierPartnerAccountListResponse} */
357
+ static CompanyCourierPartnerAccountListResponse() {
751
358
  return Joi.object({
752
359
  items: Joi.array()
753
- .items(LogisticsPartnerModel.CourierAccountResult())
360
+ .items(LogisticsPartnerModel.CourierAccountResponse())
754
361
  .required(),
755
362
  page: LogisticsPartnerModel.Page().required(),
756
363
  });
757
364
  }
758
365
 
759
- /** @returns {CourierAccountResult} */
760
- static CourierAccountResult() {
366
+ /** @returns {CourierAccountResponse} */
367
+ static CourierAccountResponse() {
761
368
  return Joi.object({
762
369
  account_id: Joi.string().allow("").required(),
763
370
  scheme_id: Joi.string().allow("").required(),
@@ -784,8 +391,8 @@ class LogisticsPartnerModel {
784
391
  });
785
392
  }
786
393
 
787
- /** @returns {CourierPartnerSchemeDetailsModel} */
788
- static CourierPartnerSchemeDetailsModel() {
394
+ /** @returns {CourierPartnerSchemeRequestModel} */
395
+ static CourierPartnerSchemeRequestModel() {
789
396
  return Joi.object({
790
397
  extension_id: Joi.string().allow("").required(),
791
398
  scheme_id: Joi.string().allow(""),
@@ -821,8 +428,6 @@ class LogisticsPartnerModel {
821
428
  single_pick_multi_drop: Joi.boolean(),
822
429
  multi_pick_multi_drop: Joi.boolean(),
823
430
  ewaybill: Joi.boolean(),
824
- qc_shipment_item_quantity: Joi.number().allow(null),
825
- non_qc_shipment_item_quantity: Joi.number().allow(null),
826
431
  });
827
432
  }
828
433
 
@@ -836,8 +441,8 @@ class LogisticsPartnerModel {
836
441
  });
837
442
  }
838
443
 
839
- /** @returns {CourierPartnerSchemeUpdateDetails} */
840
- static CourierPartnerSchemeUpdateDetails() {
444
+ /** @returns {CourierPartnerSchemeUpdateRequest} */
445
+ static CourierPartnerSchemeUpdateRequest() {
841
446
  return Joi.object({
842
447
  name: Joi.string().allow("").required(),
843
448
  weight: LogisticsPartnerModel.ArithmeticOperations().required(),
@@ -875,7 +480,6 @@ class LogisticsPartnerModel {
875
480
  latitude: Joi.string().allow(""),
876
481
  longitude: Joi.string().allow(""),
877
482
  display_name: Joi.string().allow(""),
878
- has_next_hierarchy: Joi.boolean(),
879
483
  });
880
484
  }
881
485
 
@@ -886,20 +490,5 @@ class LogisticsPartnerModel {
886
490
  slug: Joi.string().allow(""),
887
491
  });
888
492
  }
889
-
890
- /** @returns {ValidationError} */
891
- static ValidationError() {
892
- return Joi.object({
893
- message: Joi.string().allow("").required(),
894
- field: Joi.string().allow("").required(),
895
- });
896
- }
897
-
898
- /** @returns {StandardError} */
899
- static StandardError() {
900
- return Joi.object({
901
- message: Joi.string().allow("").required(),
902
- });
903
- }
904
493
  }
905
494
  module.exports = LogisticsPartnerModel;