@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,225 +1,824 @@
1
1
  const Joi = require("joi");
2
2
 
3
3
  /**
4
- * @typedef BulkRegionServiceabilityTatRequest
5
- * @property {string} country
6
- * @property {string} region
7
- * @property {string} type
4
+ * @typedef RateZoneConfigurationDetails
5
+ * @property {StandardRateZone[]} [standard_zone_mapping] - List of standard
6
+ * zones with name-slug pairs.
7
+ * @property {string[]} [custom_zones] - List of custom zone names.
8
8
  */
9
9
 
10
10
  /**
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]
11
+ * @typedef RateCardSampleFile
12
+ * @property {string} [type] - Denotes the type of action performed.
13
+ * @property {string} [file_path] - CDN path of the file.
14
+ * @property {string} [status] - Current status of the request.
19
15
  */
20
16
 
21
17
  /**
22
- * @typedef ErrorResponse
23
- * @property {string} value
24
- * @property {string} message
25
- * @property {string} type
18
+ * @typedef CourierPartnerSchemeModelSchema
19
+ * @property {CreatedBy} [created_by]
20
+ * @property {string} [created_on] - The timestamp when the record was created.
21
+ * @property {ModifiedBy} [modified_by]
22
+ * @property {string} [modified_on] - The timestamp when the record last modified.
23
+ * @property {string} [extension_id] - Unique identifier of courier partner extension.
24
+ * @property {string} [scheme_id] - Unique identifier for the scheme, used to
25
+ * fetch or modify scheme details.
26
+ * @property {string} [company_id] - The unique identifier of the company.
27
+ * @property {string} name - Name of the scheme.
28
+ * @property {ArithmeticOperations} weight
29
+ * @property {ArithmeticOperations} [volumetric_weight]
30
+ * @property {string} transport_type - Mode of transport associated with the
31
+ * courier partner scheme.
32
+ * @property {string} region - Serviceable region associated with the courier
33
+ * partner scheme.
34
+ * @property {string} delivery_type - Type of delivery associated with the
35
+ * courier partner scheme.
36
+ * @property {string[]} payment_mode - Mode of payment associated with the
37
+ * courier partner scheme.
38
+ * @property {string} stage - Indicates if the courier partner scheme is
39
+ * currently active or inactive.
40
+ * @property {string} [status_updates] - Describes the type of status updates
41
+ * provided by the courier partner (e.g., real-time, periodic).
42
+ * @property {number} [ndr_attempts] - Indicates if the Non-Delivery Report
43
+ * (NDR) feature is supported by the courier partner.
44
+ * @property {number} [qc_shipment_item_quantity] - Defines the maximum quantity
45
+ * of items allowed in a quality check shipment.
46
+ * @property {number} [non_qc_shipment_item_quantity] - Defines the maximum
47
+ * quantity of items allowed in a non-quality check shipment.
48
+ * @property {CourierPartnerSchemeFeatures} feature
49
+ * @property {string} [default_forward_pickup_cutoff] - Default cutoff time for
50
+ * forward pickup (nullable), having 24hour time format HH:MM.
51
+ * @property {string} [default_reverse_pickup_cutoff] - Default cutoff time for
52
+ * reverse pickup (nullable), having 24hour time format HH:MM.
53
+ * @property {string} [default_cutoff_timezone] - Timezone for default cutoff time.
54
+ * @property {CourierPartnerSchemeDefaultTat} [default_tat]
55
+ */
56
+
57
+ /**
58
+ * @typedef BulkRegionServiceabilityTatDetails
59
+ * @property {string} country - Country involved in the operation.
60
+ * @property {string} region - Region involved in the operation.
61
+ * @property {string} type - Type of operation, either serviceability or TAT.
62
+ */
63
+
64
+ /**
65
+ * @typedef BulkRegionServiceabilityTatResultItemData
66
+ * @property {string} [country] - Name of the country.
67
+ * @property {string} [region] - Name of the region for which the
68
+ * tat/serviceability file needs to be downloaded.
69
+ * @property {string} [type] - Denotes the type of data.
70
+ * @property {string} [batch_id] - A unique identifier for the performed batch operation.
71
+ * @property {string} [status] - Current status of the request.
72
+ * @property {Object[]} [failed_records] - Information of records which failed
73
+ * @property {string} [file_path] - CDN path of the file.
74
+ */
75
+
76
+ /**
77
+ * @typedef CommonErrorResult
78
+ * @property {Error[]} [error] - An array of items referencing the ErrorResult
79
+ * schema, which likely contains detailed information about the errors.
80
+ */
81
+
82
+ /**
83
+ * @typedef BulkFailureResult
84
+ * @property {boolean} [success] - Whether operation was successful.
85
+ * @property {Error[]} error - An array containing error details.
26
86
  */
27
87
 
28
88
  /**
29
- * @typedef FailureResponse
30
- * @property {boolean} success
31
- * @property {ErrorResponse[]} error
89
+ * @typedef FailureResult
90
+ * @property {boolean} [success] - Whether operation was successful.
91
+ * @property {Error[]} [error] - Array of error details.
32
92
  */
33
93
 
34
94
  /**
35
- * @typedef BulkRegionServiceabilityTatResponse
36
- * @property {BulkRegionServiceabilityTatResponseItemData[]} [items]
95
+ * @typedef BulkRegionServiceabilityTatResult
96
+ * @property {BulkRegionServiceabilityTatResultItemData[]} [items] - Array of
97
+ * bulk region serviceability or TAT result items.
37
98
  * @property {Page} [page]
38
99
  */
39
100
 
40
101
  /**
41
- * @typedef Page
42
- * @property {number} [item_total] - The total number of items on the page.
43
- * @property {string} [next_id] - The identifier for the next page.
44
- * @property {boolean} [has_previous] - Indicates whether there is a previous page.
45
- * @property {boolean} [has_next] - Indicates whether there is a next page.
46
- * @property {number} [current] - The current page number.
47
- * @property {string} type - The type of the page, such as 'PageType'.
48
- * @property {number} [size] - The number of items per page.
102
+ * @typedef BulkRateCardJob
103
+ * @property {string} type - Denotes the type of data.
104
+ * @property {number} total - Total number of items in the batch.
105
+ * @property {number} failed - Number of failed items in the batch.
106
+ * @property {number} success - Number of successful items in the batch.
107
+ * @property {string} [action] - Action type for the bulk operation, either
108
+ * import or export.
109
+ * @property {string} batch_id - A unique identifier for the performed batch operation.
110
+ * @property {string} status - Current status of the request.
111
+ * @property {Object[]} [failed_records] - Array of objects containing
112
+ * validation error details for records that failed during bulk import or
113
+ * export operations. Each object includes error messages describing missing
114
+ * required fields or validation failures for individual records.
115
+ * @property {string} [file_path] - CDN path of the file.
116
+ * @property {string} [created_on] - The timestamp when the record was created.
117
+ * @property {string} [modified_on] - The timestamp when the record was last modified.
118
+ */
119
+
120
+ /**
121
+ * @typedef BulkRateCardJobDetails
122
+ * @property {string} [file_path] - Path to the file used in the bulk operation.
123
+ * @property {string} rate_card_type - Rate card type for which bulk operation
124
+ * will be performed.
125
+ * @property {string} action - Action type for the bulk operation, either import
126
+ * or export.
127
+ * @property {number[]} [company_ids] - List of company IDs for which rate card
128
+ * needs to be applied.
129
+ */
130
+
131
+ /**
132
+ * @typedef SampleFileRateZoneRequestSchema
133
+ * @property {string} [zone_type] - Rate zone for which the sample file to be downloaded.
134
+ * @property {string} [country] - Name of the country.
135
+ * @property {string} [region] - Region for which the sample file to be downloaded.
136
+ */
137
+
138
+ /**
139
+ * @typedef RateZoneBulkJobDetails
140
+ * @property {string} [action] - Action type for the bulk operation, either
141
+ * import or export.
142
+ * @property {string} [file_path] - CDN path of the file.
143
+ * @property {string} [zone_type] - Rate zone for the bulk action.
144
+ * @property {string} [country] - Name of the country.
145
+ * @property {string} [region] - Region for the import and export.
49
146
  */
50
147
 
51
148
  /**
52
- * @typedef BulkRegionJobSerializer
53
- * @property {string} [file_path]
54
- * @property {string} country
55
- * @property {string} action
56
- * @property {string} region
149
+ * @typedef RateZoneBulkJobList
150
+ * @property {BulkRateCardJob[]} [items] - Array of bulk rate zone result items.
151
+ * @property {Page} [page]
57
152
  */
58
153
 
59
154
  /**
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]
155
+ * @typedef RegionTatItemResult
156
+ * @property {RegionTatResult[]} items - An array that contains items of region tat.
157
+ * @property {Page} page
72
158
  */
73
159
 
74
160
  /**
75
- * @typedef BulkRegionResponse
76
- * @property {BulkRegionResponseItemData[]} items
161
+ * @typedef RegionServiceabilityItemResult
162
+ * @property {RegionServiceabilityResult[]} items - An array that contains items
163
+ * of region serviceability.
77
164
  * @property {Page} page
78
165
  */
79
166
 
80
167
  /**
81
- * @typedef CourierAccount
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
168
+ * @typedef ServiceabilityDetailsResult
169
+ * @property {string} [pickup_cutoff] - Time of day by which pickups must be
170
+ * scheduled to be processed on the same day.
171
+ * @property {string} [country_code] - ISO2 code representing the country where
172
+ * the serviceability is being specified.
173
+ * @property {string} [state_code] - Code representing the state or province
174
+ * within the country where the serviceability is being specified.
175
+ * @property {string} [city_code] - Code representing the city within the state
176
+ * where the serviceability is being specified.
177
+ * @property {string} [sector_code] - Code representing a specific sector or
178
+ * district within the city where the serviceability is being specified.
179
+ * @property {string} [pincode] - A string indicating the postal code or PIN
180
+ * code of the address area.
181
+ * @property {boolean} [first_mile] - Boolean value indicating whether
182
+ * first-mile service is available or not.
183
+ * @property {boolean} [last_mile] - Boolean value indicating whether last-mile
184
+ * service is available or not.
185
+ * @property {number} [cod_limit] - Limit on the amount of cash on delivery
186
+ * (COD) payments allowed in the specified region.
187
+ * @property {number} [prepaid_limit] - Limit on the amount of prepaid payments
188
+ * allowed in the specified region.
189
+ * @property {boolean} [doorstep_return] - Indicates if doorstep return service
190
+ * is available. This refers to the ability to return items directly from the
191
+ * customer's doorstep.
192
+ * @property {boolean} [doorstep_qc] - Indicates if doorstep quality check
193
+ * service is available. This refers to the ability to perform quality checks
194
+ * on items at the customer's doorstep.
195
+ * @property {string} [forward_pickup_cutoff] - Time of day by which pickups
196
+ * must be scheduled to be processed on the same day in the forward journey.
197
+ * @property {string} [reverse_pickup_cutoff] - Time of day by which pickups
198
+ * must be scheduled to be processed on the same day in the reverse journey.
199
+ * @property {boolean} [hand_to_hand_exchange] - Indicates whether the product
200
+ * exchange happens directly between the buyer and seller (e.g., in person),
201
+ * instead of through a third-party service.
202
+ * @property {string[]} [holiday_list] - List of holidays for a courier partner scheme.
203
+ * @property {boolean} [reverse_pickup] - Boolean value indicating whether
204
+ * reverse pickup services is available.
205
+ * @property {boolean} [installation] - Boolean value indicating whether
206
+ * installation services are available in the specified region or not.
207
+ * @property {string} [id] - A string serving as the unique identifier.
208
+ */
209
+
210
+ /**
211
+ * @typedef ServiceabilityDetails
212
+ * @property {boolean} [first_mile] - Boolean value indicating whether
213
+ * first-mile service is available or not.
214
+ * @property {boolean} [last_mile] - Boolean value indicating whether last-mile
215
+ * service is available or not.
216
+ * @property {number} [cod_limit] - Limit on the amount of cash on delivery
217
+ * (COD) payments allowed in the specified region.
218
+ * @property {boolean} [doorstep_return] - Indicates if doorstep return service
219
+ * is available. This refers to the ability to return items directly from the
220
+ * customer's doorstep.
221
+ * @property {boolean} [doorstep_qc] - Indicates if doorstep quality check
222
+ * service is available. This refers to the ability to perform quality checks
223
+ * on items at the customer's doorstep.
224
+ * @property {string} [forward_pickup_cutoff] - Time of day by which pickups
225
+ * must be scheduled to be processed on the same day in the forward journey.
226
+ * @property {string} [reverse_pickup_cutoff] - Time of day by which pickups
227
+ * must be scheduled to be processed on the same day in the reverse journey.
228
+ * @property {boolean} [hand_to_hand_exchange] - Indicates whether the product
229
+ * exchange happens directly between the buyer and seller (e.g., in person),
230
+ * instead of through a third-party service.
231
+ * @property {string[]} [holiday_list] - List of holidays for a courier partner scheme.
232
+ * @property {boolean} [installation] - Boolean value indicating whether
233
+ * installation services are available in the specified region or not.
234
+ * @property {string} [pickup_cutoff] - Time of day by which pickups must be
235
+ * scheduled to be processed on the same day.
236
+ */
237
+
238
+ /**
239
+ * @typedef RegionServiceabilityResult
240
+ * @property {string} [pickup_cutoff] - Time of day by which pickups must be
241
+ * scheduled to be processed on the same day.
242
+ * @property {string} country_code - ISO2 code representing the country where
243
+ * the serviceability is being specified.
244
+ * @property {string} [state_code] - Code representing the state or province
245
+ * within the country where the serviceability is being specified.
246
+ * @property {string} [city_code] - Code representing the city within the state
247
+ * where the serviceability is being specified.
248
+ * @property {string} [sector_code] - Code representing a specific sector or
249
+ * district within the city where the serviceability is being specified.
250
+ * @property {string} [pincode] - A string indicating the postal code or PIN
251
+ * code of the address area.
252
+ * @property {boolean} [first_mile] - Boolean value indicating whether
253
+ * first-mile service is available or not.
254
+ * @property {boolean} [last_mile] - Boolean value indicating whether last-mile
255
+ * service is available or not.
256
+ * @property {number} [cod_limit] - Limit on the amount of cash on delivery
257
+ * (COD) payments allowed in the specified region.
258
+ * @property {number} [prepaid_limit] - Limit on the amount of prepaid payments
259
+ * allowed in the specified region.
260
+ * @property {boolean} [doorstep_return] - Indicates if doorstep return service
261
+ * is available. This refers to the ability to return items directly from the
262
+ * customer's doorstep.
263
+ * @property {boolean} [doorstep_qc] - Indicates if doorstep quality check
264
+ * service is available. This refers to the ability to perform quality checks
265
+ * on items at the customer's doorstep.
266
+ * @property {boolean} [reverse_pickup] - Indicates if reverse pickup is available.
267
+ * @property {string} [forward_pickup_cutoff] - Time of day by which pickups
268
+ * must be scheduled to be processed on the same day in the forward journey.
269
+ * @property {string} [reverse_pickup_cutoff] - Time of day by which pickups
270
+ * must be scheduled to be processed on the same day in the reverse journey.
271
+ * @property {boolean} [hand_to_hand_exchange] - Indicates whether the product
272
+ * exchange happens directly between the buyer and seller (e.g., in person),
273
+ * instead of through a third-party service.
274
+ * @property {string[]} [holiday_list] - List of holidays for a courier partner scheme.
275
+ * @property {boolean} [installation] - Boolean value indicating whether
276
+ * installation services are available in the specified region or not.
277
+ * @property {string} id - A string serving as the unique identifier.
278
+ */
279
+
280
+ /**
281
+ * @typedef RegionServiceabilityDetails
282
+ * @property {string} country_code - ISO2 code representing the country where
283
+ * the serviceability is being specified.
284
+ * @property {string} [state_code] - Code representing the state or province
285
+ * within the country where the serviceability is being specified.
286
+ * @property {string} [city_code] - Code representing the city within the state
287
+ * where the serviceability is being specified.
288
+ * @property {string} [sector_code] - Code representing a specific sector or
289
+ * district within the city where the serviceability is being specified.
290
+ * @property {string} [pincode] - A string indicating the postal code or PIN
291
+ * code of the address area.
292
+ * @property {boolean} [first_mile] - Boolean value indicating whether
293
+ * first-mile service is available or not.
294
+ * @property {boolean} [last_mile] - Boolean value indicating whether last-mile
295
+ * service is available or not.
296
+ * @property {number} [cod_limit] - Limit on the amount of cash on delivery
297
+ * (COD) payments allowed in the specified region.
298
+ * @property {boolean} [doorstep_return] - Indicates if doorstep return service
299
+ * is available. This refers to the ability to return items directly from the
300
+ * customer's doorstep.
301
+ * @property {boolean} [doorstep_qc] - Indicates if doorstep quality check
302
+ * service is available. This refers to the ability to perform quality checks
303
+ * on items at the customer's doorstep.
304
+ * @property {string} [forward_pickup_cutoff] - Time of day by which pickups
305
+ * must be scheduled to be processed on the same day in the forward journey.
306
+ * @property {string} [pickup_cutoff] - Time of day by which pickups must be
307
+ * scheduled to be processed on the same day.
308
+ * @property {string} [reverse_pickup_cutoff] - Time of day by which pickups
309
+ * must be scheduled to be processed on the same day in the reverse journey.
310
+ * @property {boolean} [hand_to_hand_exchange] - Indicates whether the product
311
+ * exchange happens directly between the buyer and seller (e.g., in person),
312
+ * instead of through a third-party service.
313
+ * @property {number} [prepaid_limit] - Limit on the amount of prepaid payments
314
+ * allowed in the specified region.
315
+ * @property {string[]} [holiday_list] - List of holidays for a courier partner scheme.
316
+ * @property {boolean} [installation] - Boolean value indicating whether
317
+ * installation services are available in the specified region or not.
318
+ */
319
+
320
+ /**
321
+ * @typedef RegionTatDetails
322
+ * @property {number} [max_delivery_time] - Maximum time required for delivery
323
+ * from the origin to the destination in seconds.
324
+ * @property {number} [min_delivery_time] - Minimum time required for delivery
325
+ * from the origin to the destination in seconds.
326
+ * @property {string} from_country_code - ISO2 code representing the country of
327
+ * origin for the delivery.
328
+ * @property {string} [from_state_code] - Code representing the state or
329
+ * province of origin within the country.
330
+ * @property {string} [from_city_code] - Code representing the city of origin
331
+ * within the state.
332
+ * @property {string} [from_sector_code] - Code representing a specific sector
333
+ * or district within the city of origin.
334
+ * @property {string} [from_pincode] - A string indicating the postal code or
335
+ * PIN code of the address area.
336
+ * @property {string} to_country_code - ISO2 code representing the destination country.
337
+ * @property {string} [to_state_code] - Code representing the state or province
338
+ * of the destination within the country.
339
+ * @property {string} [to_city_code] - Code representing the city of destination
340
+ * within the state.
341
+ * @property {string} [to_sector_code] - Code representing a specific sector or
342
+ * district within the city of destination.
343
+ * @property {string} [to_pincode] - A string indicating the postal code or PIN
344
+ * code of the address area.
345
+ * @property {TATDetails} [forward]
346
+ * @property {TATDetails} [reverse]
347
+ */
348
+
349
+ /**
350
+ * @typedef RegionTatResult
351
+ * @property {number} [min_delivery_time] - Minimum time required for delivery
352
+ * from the origin to the destination in seconds.
353
+ * @property {number} [max_delivery_time] - Maximum time required for delivery
354
+ * from the origin to the destination in seconds.
355
+ * @property {string} from_country_code - ISO2 code representing the country of
356
+ * origin for the delivery.
357
+ * @property {string} [from_state_code] - Code representing the state or
358
+ * province of origin within the country.
359
+ * @property {string} [from_city_code] - Code representing the city of origin
360
+ * within the state.
361
+ * @property {string} [from_sector_code] - Code representing a specific sector
362
+ * or district within the city of origin.
363
+ * @property {string} [from_pincode] - A string indicating the postal code or
364
+ * PIN code of the address area.
365
+ * @property {string} to_country_code - ISO2 code representing the destination country.
366
+ * @property {string} [to_state_code] - Code representing the state or province
367
+ * of the destination within the country.
368
+ * @property {string} [to_city_code] - Code representing the city of destination
369
+ * within the state.
370
+ * @property {string} [to_sector_code] - Code representing a specific sector or
371
+ * district within the city of destination.
372
+ * @property {string} [to_pincode] - A string indicating the postal code or PIN
373
+ * code of the address area.
374
+ * @property {TATDetails} [forward]
375
+ * @property {TATDetails} [reverse]
376
+ * @property {string} id - A string serving as the unique identifier.
88
377
  */
89
378
 
90
379
  /**
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
380
+ * @typedef BulkRegionJobDetails
381
+ * @property {string} [file_path] - Path to the file used in the bulk operation.
382
+ * @property {string} country - Country involved in the bulk operation.
383
+ * @property {string} action - Action type for the bulk operation, either import
384
+ * or export.
385
+ * @property {string} region - Region involved in the bulk operation.
98
386
  */
99
387
 
100
388
  /**
101
- * @typedef CourierPartnerAccountFailureResponse
102
- * @property {boolean} success
103
- * @property {ErrorResponse[]} error
389
+ * @typedef BulkRegionResultItemData
390
+ * @property {string} file_path - Path to the file associated with the result item.
391
+ * @property {number} [failed] - Number of failed records in the operation.
392
+ * @property {Object[]} [failed_records] - Array of failed records with
393
+ * additional properties.
394
+ * @property {string} action - Action type for the result item.
395
+ * @property {string} batch_id - A unique identifier for the performed batch operation.
396
+ * @property {string} country - Country associated with the result item.
397
+ * @property {number} [success] - Number of successful records in the operation.
398
+ * @property {string} region - Region associated with the result item.
399
+ * @property {string} status - Current status of the result item.
400
+ * @property {number} [total] - Total number of records processed.
401
+ * @property {string} [error_file_path] - Path to the file containing error details.
402
+ * @property {string} [modified_on] - The timestamp when the record last modified.
403
+ * @property {string} [created_on] - The timestamp when the record was created.
104
404
  */
105
405
 
106
406
  /**
107
- * @typedef CompanyCourierPartnerAccountListResponse
108
- * @property {CourierAccountResponse[]} items
407
+ * @typedef BulkRegionResult
408
+ * @property {BulkRegionResultItemData[]} items - Array of bulk region result items.
109
409
  * @property {Page} page
110
410
  */
111
411
 
112
412
  /**
113
- * @typedef CourierAccountResponse
114
- * @property {string} account_id
115
- * @property {string} scheme_id
116
- * @property {boolean} is_self_ship
117
- * @property {string} stage
118
- * @property {boolean} is_own_account
119
- * @property {CourierPartnerSchemeModel} scheme_rules
413
+ * @typedef CourierAccountDetailsBody
414
+ * @property {string} extension_id - The unique identifier for the extension
415
+ * linked to the courier account.
416
+ * @property {string} [account_id] - The unique identifier for the courier account.
417
+ * @property {string} scheme_id - The identifier for the scheme associated with
418
+ * the courier account.
419
+ * @property {boolean} is_self_ship - Indicates whether the courier account
420
+ * supports self-shipping (true if it does, false otherwise).
421
+ * @property {string} stage - The current stage of the courier account, either
422
+ * 'enabled' or 'disabled'.
423
+ * @property {boolean} is_own_account - Indicates whether the courier account is
424
+ * an own account (true if it is, false otherwise).
120
425
  */
121
426
 
122
427
  /**
123
- * @typedef CourierPartnerSchemeModel
124
- * @property {string} extension_id
125
- * @property {string} scheme_id
126
- * @property {string} name
127
- * @property {ArithmeticOperations} weight
128
- * @property {string} transport_type
129
- * @property {string} region
130
- * @property {string} delivery_type
131
- * @property {string[]} payment_mode
132
- * @property {string} stage
133
- * @property {CourierPartnerSchemeFeatures} feature
428
+ * @typedef CompanyCourierPartnerAccountListResult
429
+ * @property {CourierAccountResult[]} items - An array containing multiple
430
+ * instances of CourierAccountResult, which details individual courier accounts.
431
+ * @property {Page} page
432
+ */
433
+
434
+ /**
435
+ * @typedef CourierAccountResult
436
+ * @property {string} account_id - A string that uniquely identifies the courier account.
437
+ * @property {number} [company_id] - The unique identifier of the company.
438
+ * @property {string} scheme_id - A string that specifies the unique identifier
439
+ * for the scheme associated with the account
440
+ * @property {string} [extension_id] - A string that uniquely identifies the
441
+ * courier partner extension.
442
+ * @property {boolean} is_self_ship - A boolean indicating whether the account
443
+ * is for self-shipping.
444
+ * @property {string} stage - A string indicating the current stage of the
445
+ * account, which can be either enabled or disabled.
446
+ * @property {boolean} is_own_account - A boolean indicating whether the account
447
+ * is owned by the company.
448
+ * @property {CourierPartnerSchemeModel} scheme_rules
134
449
  */
135
450
 
136
451
  /**
137
- * @typedef CourierPartnerSchemeRequestModel
138
- * @property {string} extension_id
139
- * @property {string} [scheme_id]
140
- * @property {string} name
452
+ * @typedef CourierPartnerSchemeDetailsModel
453
+ * @property {string} extension_id - Unique identifier of courier partner extension.
454
+ * @property {string} [scheme_id] - Unique identifier for the scheme, used to
455
+ * fetch or modify scheme details.
456
+ * @property {string} name - Name of the scheme.
457
+ * @property {string} [default_forward_pickup_cutoff] - Default cutoff time for
458
+ * forward pickup (nullable), having 24hour time format HH:MM.
459
+ * @property {string} [default_reverse_pickup_cutoff] - Default cutoff time for
460
+ * reverse pickup (nullable), having 24hour time format HH:MM.
461
+ * @property {string} [default_cutoff_timezone] - Timezone for default cutoff time.
462
+ * @property {CourierPartnerSchemeDefaultTat} [default_tat]
141
463
  * @property {ArithmeticOperations} weight
142
- * @property {string} transport_type
143
- * @property {string} region
144
- * @property {string} delivery_type
145
- * @property {string[]} payment_mode
146
- * @property {string} stage
464
+ * @property {ArithmeticOperations} [volumetric_weight]
465
+ * @property {string} transport_type - Mode of transport associated with the
466
+ * courier partner scheme.
467
+ * @property {string} region - Serviceable region associated with the courier
468
+ * partner scheme.
469
+ * @property {string} delivery_type - Type of delivery associated with the
470
+ * courier partner scheme.
471
+ * @property {string[]} payment_mode - Mode of payment associated with the
472
+ * courier partner scheme.
473
+ * @property {string} stage - Indicates if the courier partner scheme is
474
+ * currently active or inactive.
475
+ * @property {string} [status_updates] - Describes the type of status updates
476
+ * provided by the courier partner (e.g., real-time, periodic).
477
+ * @property {number} [ndr_attempts] - Indicates if the Non-Delivery Report
478
+ * (NDR) feature is supported by the courier partner.
479
+ * @property {number} [qc_shipment_item_quantity] - Defines the maximum quantity
480
+ * of items allowed in a quality check shipment.
481
+ * @property {number} [non_qc_shipment_item_quantity] - Defines the maximum
482
+ * quantity of items allowed in a non-quality check shipment.
147
483
  * @property {CourierPartnerSchemeFeatures} feature
148
484
  */
149
485
 
150
486
  /**
151
- * @typedef CourierPartnerSchemeFeatures
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]
487
+ * @typedef CourierPartnerPutSchema
488
+ * @property {string} [extension_id] - Unique identifier of courier partner extension.
489
+ * @property {CreatedBy} [created_by]
490
+ * @property {ModifiedBy} [modified_by]
491
+ * @property {string} [created_on] - The timestamp when the record was created.
492
+ * @property {string} [modified_on] - The timestamp when the record last modified.
493
+ * @property {string} [scheme_id] - Unique identifier of courier partner scheme.
494
+ * @property {string} [company_id] - The unique identifier of the company.
495
+ * @property {string} name - Name of the scheme.
496
+ * @property {ArithmeticOperations} weight
497
+ * @property {ArithmeticOperations} [volumetric_weight]
498
+ * @property {string} transport_type - Mode of transport associated with the
499
+ * courier partner scheme.
500
+ * @property {string} region - Serviceable region associated with the courier
501
+ * partner scheme.
502
+ * @property {string} delivery_type - Type of delivery associated with the
503
+ * courier partner scheme.
504
+ * @property {string[]} payment_mode - Mode of payment associated with the
505
+ * courier partner scheme.
506
+ * @property {string} stage - Indicates if the courier partner scheme is
507
+ * currently active or inactive.
508
+ * @property {string} [status_updates] - Describes the type of status updates
509
+ * provided by the courier partner (e.g., real-time, periodic).
510
+ * @property {number} [ndr_attempts] - Indicates if the Non-Delivery Report
511
+ * (NDR) feature is supported by the courier partner.
512
+ * @property {number} [qc_shipment_item_quantity] - Defines the maximum quantity
513
+ * of items allowed in a quality check shipment.
514
+ * @property {number} [non_qc_shipment_item_quantity] - Defines the maximum
515
+ * quantity of items allowed in a non-quality check shipment.
516
+ * @property {CourierPartnerSchemeFeatures} feature
517
+ * @property {string} [default_forward_pickup_cutoff] - Default cutoff time for
518
+ * forward pickup (nullable), having 24hour time format HH:MM.
519
+ * @property {string} [default_reverse_pickup_cutoff] - Default cutoff time for
520
+ * reverse pickup (nullable), having 24hour time format HH:MM.
521
+ * @property {string} [default_cutoff_timezone] - Timezone for default cutoff time.
522
+ * @property {CourierPartnerSchemeDefaultTat} [default_tat]
170
523
  */
171
524
 
172
525
  /**
173
- * @typedef ArithmeticOperations
174
- * @property {number} [lt]
175
- * @property {number} [gt]
176
- * @property {number} [lte]
177
- * @property {number} [gte]
526
+ * @typedef CourierPartnerSchemeList
527
+ * @property {CourierPartnerSchemeModelSchema[]} items - List of courier partner schemes
528
+ * @property {Page} page
178
529
  */
179
530
 
180
531
  /**
181
- * @typedef CourierPartnerSchemeUpdateRequest
182
- * @property {string} name
532
+ * @typedef CourierPartnerSchemeUpdateDetails
533
+ * @property {string} name - Name of the scheme.
183
534
  * @property {ArithmeticOperations} weight
184
- * @property {string} transport_type
185
- * @property {string} region
186
- * @property {string} delivery_type
187
- * @property {string[]} payment_mode
188
- * @property {string} stage
535
+ * @property {ArithmeticOperations} [volumetric_weight]
536
+ * @property {string} transport_type - Mode of transport associated with the
537
+ * courier partner scheme.
538
+ * @property {string} region - Serviceable region associated with the courier
539
+ * partner scheme.
540
+ * @property {string} delivery_type - Type of delivery associated with the
541
+ * courier partner scheme.
542
+ * @property {string[]} payment_mode - Mode of payment associated with the
543
+ * courier partner scheme.
544
+ * @property {string} stage - Indicates if the courier partner scheme is
545
+ * currently active or inactive.
546
+ * @property {string} [status_updates] - Describes the type of status updates
547
+ * provided by the courier partner (e.g., real-time, periodic).
548
+ * @property {number} [ndr_attempts] - Indicates if the Non-Delivery Report
549
+ * (NDR) feature is supported by the courier partner.
550
+ * @property {number} [qc_shipment_item_quantity] - Defines the maximum quantity
551
+ * of items allowed in a quality check shipment.
552
+ * @property {number} [non_qc_shipment_item_quantity] - Defines the maximum
553
+ * quantity of items allowed in a non-quality check shipment.
189
554
  * @property {CourierPartnerSchemeFeatures} feature
555
+ * @property {string} [default_forward_pickup_cutoff] - Default cutoff time for
556
+ * forward pickup (nullable), having 24hour time format HH:MM.
557
+ * @property {string} [default_reverse_pickup_cutoff] - Default cutoff time for
558
+ * reverse pickup (nullable), having 24hour time format HH:MM.
559
+ * @property {string} [default_cutoff_timezone] - Timezone for default cutoff time.
560
+ * @property {CourierPartnerSchemeDefaultTat} [default_tat]
190
561
  */
191
562
 
192
563
  /**
193
564
  * @typedef GetCountries
194
- * @property {GetCountriesItems[]} items
565
+ * @property {GetCountriesItems[]} items - A list of country objects containing
566
+ * detailed information about each country.
195
567
  * @property {Page} page
196
568
  */
197
569
 
570
+ /**
571
+ * @typedef TATUpdateDetails
572
+ * @property {number} [max_delivery_time] - Maximum time required for delivery
573
+ * from the origin to the destination in seconds.
574
+ * @property {number} [min_delivery_time] - Minimum time required for delivery
575
+ * from the origin to the destination in seconds.
576
+ * @property {TATDetails} [forward]
577
+ * @property {TATDetails} [reverse]
578
+ */
579
+
580
+ /**
581
+ * @typedef StandardError
582
+ * @property {string} message - A brief description of the error.
583
+ */
584
+
585
+ /**
586
+ * @typedef ValidationErrors
587
+ * @property {ValidationError[]} errors - A list of validation errors in the request.
588
+ */
589
+
590
+ /**
591
+ * @typedef StandardRateZone
592
+ * @property {string} [zone_name] - User defined name of the zone for a particular slug.
593
+ * @property {string} [zone_slug] - Pre-defined slug for the standard zones.
594
+ */
595
+
596
+ /**
597
+ * @typedef CreatedBy
598
+ * @property {string} [id] - Identifier of the user or system that created the object.
599
+ */
600
+
601
+ /**
602
+ * @typedef ModifiedBy
603
+ * @property {string} [id] - Identifier of the user or system that created the object.
604
+ */
605
+
606
+ /**
607
+ * @typedef ArithmeticOperations
608
+ * @property {number} [lt] - Specifies a less than operation, comparing values
609
+ * smaller than the provided value.
610
+ * @property {number} [gt] - Specifies a greater than operation, comparing
611
+ * values larger than the provided value.
612
+ * @property {number} [lte] - Specifies a less than or equal to operation,
613
+ * comparing values smaller than or equal to the provided value.
614
+ * @property {number} [gte] - Specifies a greater than or equal to operation,
615
+ * comparing values larger than or equal to the provided value.
616
+ */
617
+
618
+ /**
619
+ * @typedef CourierPartnerSchemeFeatures
620
+ * @property {boolean} [doorstep_qc] - Indicates if the courier partner offers
621
+ * doorstep quality check services.
622
+ * @property {boolean} [qr] - Specifies whether the courier partner supports QR
623
+ * code-based operations.
624
+ * @property {boolean} [mps] - Denotes if the courier partner supports
625
+ * multi-part shipment services.
626
+ * @property {boolean} [b2b] - Denotes if courier partner is business-to-business or not.
627
+ * @property {boolean} [ndr] - Indicates if the Non-Delivery Report (NDR)
628
+ * feature is supported by the courier partner.
629
+ * @property {number} [ndr_attempts] - Number of attempts allowed for resolving
630
+ * Non-Delivery Reports (NDR).
631
+ * @property {boolean} [dangerous_goods] - Specifies if the courier partner
632
+ * handles the transportation of dangerous goods.
633
+ * @property {boolean} [fragile_goods] - Indicates whether the courier partner
634
+ * manages the shipment of fragile goods.
635
+ * @property {boolean} [restricted_goods] - Indicates if the courier partner
636
+ * handles restricted goods, as per regulatory guidelines.
637
+ * @property {boolean} [cold_storage_goods] - Denotes if the courier partner
638
+ * provides cold storage facilities for goods.
639
+ * @property {boolean} [doorstep_exchange] - Indicates if the courier partner
640
+ * supports doorstep exchange services.
641
+ * @property {boolean} [doorstep_return] - Specifies if the courier partner
642
+ * offers doorstep return services.
643
+ * @property {boolean} [product_installation] - Indicates if the courier partner
644
+ * provides product installation services upon delivery.
645
+ * @property {boolean} [openbox_delivery] - Specifies whether the courier
646
+ * partner supports open-box delivery, allowing customers to inspect goods
647
+ * before accepting.
648
+ * @property {string} [status_updates] - Describes the type of status updates
649
+ * provided by the courier partner (e.g., real-time, periodic).
650
+ * @property {boolean} [multi_pick_single_drop] - Indicates if the courier
651
+ * partner supports multiple pickups to a single drop location.
652
+ * @property {boolean} [single_pick_multi_drop] - Indicates whether the courier
653
+ * partner supports single pickup to multiple drop locations.
654
+ * @property {boolean} [multi_pick_multi_drop] - Denotes if the courier partner
655
+ * offers services for multiple pickups to multiple drop locations.
656
+ * @property {boolean} [ewaybill] - Specifies if the courier partner requires or
657
+ * supports the generation of e-waybills for shipments.
658
+ * @property {number} [qc_shipment_item_quantity] - Defines the maximum quantity
659
+ * of items allowed in a quality check shipment.
660
+ * @property {number} [non_qc_shipment_item_quantity] - Defines the maximum
661
+ * quantity of items allowed in a non-quality check shipment.
662
+ */
663
+
664
+ /**
665
+ * @typedef CourierPartnerSchemeDefaultTat
666
+ * @property {boolean} [enabled] - Indicates whether the default turn around
667
+ * time (tat) to be used for the given scheme or not.
668
+ * @property {CourierPartnerSchemeTat} [tat]
669
+ */
670
+
671
+ /**
672
+ * @typedef CourierPartnerSchemeTat
673
+ * @property {number} [min] - Minimum turn around time (tat) value for a scheme.
674
+ * @property {number} [max] - Maximum turn around time (tat) value for a scheme.
675
+ * @property {string} [unit] - Unit for the turn around time (tat) values for a scheme.
676
+ */
677
+
678
+ /**
679
+ * @typedef Error
680
+ * @property {string} [type] - The type of the error.
681
+ * @property {string} [value] - The value associated with the error.
682
+ * @property {string} [message] - The error message describing the issue.
683
+ */
684
+
685
+ /**
686
+ * @typedef Page
687
+ * @property {number} [item_total] - The total number of all items across all pages.
688
+ * @property {string} [next_id] - The identifier for the next page.
689
+ * @property {boolean} [has_previous] - Indicates whether there is a previous page.
690
+ * @property {boolean} [has_next] - Indicates whether there is a next page.
691
+ * @property {number} [current] - The current page number.
692
+ * @property {string} type - The type of the page, can be 'cursor' or 'number'.
693
+ * @property {number} [size] - The number of items per page.
694
+ * @property {number} [page_size] - The number of items per page.
695
+ */
696
+
697
+ /**
698
+ * @typedef TATDetails
699
+ * @property {number} [max_delivery_time] - Maximum time required for delivery
700
+ * from the origin to the destination in seconds.
701
+ * @property {number} [min_delivery_time] - Minimum time required for delivery
702
+ * from the origin to the destination in seconds.
703
+ */
704
+
705
+ /**
706
+ * @typedef CourierPartnerSchemeModel
707
+ * @property {string} extension_id - Unique identifier of courier partner extension.
708
+ * @property {string} scheme_id - A string representing the unique identifier
709
+ * for the scheme. This is a required field.
710
+ * @property {string} name - A string that specifies the name of the scheme.
711
+ * This is a required field.
712
+ * @property {ArithmeticOperations} weight
713
+ * @property {ArithmeticOperations} [volumetric_weight]
714
+ * @property {string} transport_type - A string that specifies the type of transport.
715
+ * @property {string} region - A string that indicates the region type.
716
+ * @property {string} delivery_type - A string that defines the delivery type.
717
+ * @property {string[]} payment_mode - An array of strings specifying the
718
+ * payment modes available.
719
+ * @property {string} stage - A string indicating the current stage of the scheme.
720
+ * @property {CourierPartnerSchemeFeatures} feature
721
+ */
722
+
198
723
  /**
199
724
  * @typedef GetCountriesItems
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]
725
+ * @property {string} [id] - A string serving as the unique identifier.
726
+ * @property {string} [sub_type] - A category for classifying the country into a
727
+ * specific subtype.
728
+ * @property {string} [uid] - A globally unique identifier for the country.
729
+ * @property {string} [name] - The official or widely recognized name of the
730
+ * country used in general contexts.
731
+ * @property {string} [iso2] - The 2-letter ISO code for the country.
732
+ * @property {string} [iso3] - The 3-letter ISO code for the country.
733
+ * @property {string[]} [timezones] - A list of timezones associated with the country.
734
+ * @property {HierarchyItems[]} [hierarchy] - A hierarchical list of items
735
+ * representing organizational levels within the country.
736
+ * @property {string} [phone_code] - A country-specific phone code.
737
+ * @property {CurrencyObject} [currency]
738
+ * @property {string} [type] - The type or classification of the country (e.g.,
739
+ * sovereign or dependent).
740
+ * @property {string} [latitude] - The latitude of the central point of the country.
741
+ * @property {string} [longitude] - The longitude of the central point of the country.
742
+ * @property {string} [display_name] - A user-friendly name for the country,
743
+ * typically for display purposes.
744
+ * @property {boolean} [has_next_hierarchy] - A boolean indicating whether
745
+ * additional hierarchical regions or divisions are present.
212
746
  */
213
747
 
214
748
  /**
215
749
  * @typedef HierarchyItems
216
- * @property {string} [display_name]
217
- * @property {string} [slug]
750
+ * @property {string} [name] - The name of the item as displayed to the user,
751
+ * usually in a UI or listing.
752
+ * @property {string} [display_name] - It represent a country display name.
753
+ * @property {string} [slug] - A slug is a human-readable URL segment, typically
754
+ * generated from a title with special characters removed.
755
+ */
756
+
757
+ /**
758
+ * @typedef CurrencyObject
759
+ * @property {string} [code] - A string representing the currency code.
760
+ * @property {string} [name] - A string representing the currency name.
761
+ * @property {string} [symbol] - A string representing the currency symbol.
762
+ */
763
+
764
+ /**
765
+ * @typedef ValidationError
766
+ * @property {string} message - A brief description of the error encountered.
767
+ * @property {string} field - The field in the request that caused the error.
218
768
  */
219
769
 
220
770
  class LogisticsPartnerModel {
221
- /** @returns {BulkRegionServiceabilityTatRequest} */
222
- static BulkRegionServiceabilityTatRequest() {
771
+ /** @returns {RateZoneConfigurationDetails} */
772
+ static RateZoneConfigurationDetails() {
773
+ return Joi.object({
774
+ standard_zone_mapping: Joi.array().items(
775
+ LogisticsPartnerModel.StandardRateZone()
776
+ ),
777
+ custom_zones: Joi.array().items(Joi.string().allow("")),
778
+ });
779
+ }
780
+
781
+ /** @returns {RateCardSampleFile} */
782
+ static RateCardSampleFile() {
783
+ return Joi.object({
784
+ type: Joi.string().allow(""),
785
+ file_path: Joi.string().allow("").allow(null),
786
+ status: Joi.string().allow(""),
787
+ });
788
+ }
789
+
790
+ /** @returns {CourierPartnerSchemeModelSchema} */
791
+ static CourierPartnerSchemeModelSchema() {
792
+ return Joi.object({
793
+ created_by: LogisticsPartnerModel.CreatedBy(),
794
+ created_on: Joi.string().allow(""),
795
+ modified_by: LogisticsPartnerModel.ModifiedBy(),
796
+ modified_on: Joi.string().allow(""),
797
+ extension_id: Joi.string().allow(""),
798
+ scheme_id: Joi.string().allow(""),
799
+ company_id: Joi.string().allow(""),
800
+ name: Joi.string().allow("").required(),
801
+ weight: LogisticsPartnerModel.ArithmeticOperations().required(),
802
+ volumetric_weight: LogisticsPartnerModel.ArithmeticOperations(),
803
+ transport_type: Joi.string().allow("").required(),
804
+ region: Joi.string().allow("").required(),
805
+ delivery_type: Joi.string().allow("").required(),
806
+ payment_mode: Joi.array().items(Joi.string().allow("")).required(),
807
+ stage: Joi.string().allow("").required(),
808
+ status_updates: Joi.string().allow(""),
809
+ ndr_attempts: Joi.number(),
810
+ qc_shipment_item_quantity: Joi.number().allow(null),
811
+ non_qc_shipment_item_quantity: Joi.number().allow(null),
812
+ feature: LogisticsPartnerModel.CourierPartnerSchemeFeatures().required(),
813
+ default_forward_pickup_cutoff: Joi.string().allow("").allow(null),
814
+ default_reverse_pickup_cutoff: Joi.string().allow("").allow(null),
815
+ default_cutoff_timezone: Joi.string().allow("").allow(null),
816
+ default_tat: LogisticsPartnerModel.CourierPartnerSchemeDefaultTat(),
817
+ });
818
+ }
819
+
820
+ /** @returns {BulkRegionServiceabilityTatDetails} */
821
+ static BulkRegionServiceabilityTatDetails() {
223
822
  return Joi.object({
224
823
  country: Joi.string().allow("").required(),
225
824
  region: Joi.string().allow("").required(),
@@ -227,63 +826,260 @@ class LogisticsPartnerModel {
227
826
  });
228
827
  }
229
828
 
230
- /** @returns {BulkRegionServiceabilityTatResponseItemData} */
231
- static BulkRegionServiceabilityTatResponseItemData() {
829
+ /** @returns {BulkRegionServiceabilityTatResultItemData} */
830
+ static BulkRegionServiceabilityTatResultItemData() {
232
831
  return Joi.object({
233
832
  country: Joi.string().allow(""),
234
833
  region: Joi.string().allow(""),
235
834
  type: Joi.string().allow(""),
236
835
  batch_id: Joi.string().allow(""),
237
836
  status: Joi.string().allow(""),
238
- failed_records: Joi.array().items(Joi.any()),
239
- file_path: Joi.string().allow(""),
837
+ failed_records: Joi.array().items(Joi.object().pattern(/\S/, Joi.any())),
838
+ file_path: Joi.string().allow("").allow(null),
240
839
  });
241
840
  }
242
841
 
243
- /** @returns {ErrorResponse} */
244
- static ErrorResponse() {
842
+ /** @returns {CommonErrorResult} */
843
+ static CommonErrorResult() {
245
844
  return Joi.object({
246
- value: Joi.string().allow("").required(),
247
- message: Joi.string().allow("").required(),
248
- type: Joi.string().allow("").required(),
845
+ error: Joi.array().items(LogisticsPartnerModel.Error()),
249
846
  });
250
847
  }
251
848
 
252
- /** @returns {FailureResponse} */
253
- static FailureResponse() {
849
+ /** @returns {BulkFailureResult} */
850
+ static BulkFailureResult() {
254
851
  return Joi.object({
255
- success: Joi.boolean().required(),
256
- error: Joi.array()
257
- .items(LogisticsPartnerModel.ErrorResponse())
258
- .required(),
852
+ success: Joi.boolean(),
853
+ error: Joi.array().items(LogisticsPartnerModel.Error()).required(),
854
+ });
855
+ }
856
+
857
+ /** @returns {FailureResult} */
858
+ static FailureResult() {
859
+ return Joi.object({
860
+ success: Joi.boolean(),
861
+ error: Joi.array().items(LogisticsPartnerModel.Error()),
259
862
  });
260
863
  }
261
864
 
262
- /** @returns {BulkRegionServiceabilityTatResponse} */
263
- static BulkRegionServiceabilityTatResponse() {
865
+ /** @returns {BulkRegionServiceabilityTatResult} */
866
+ static BulkRegionServiceabilityTatResult() {
264
867
  return Joi.object({
265
868
  items: Joi.array().items(
266
- LogisticsPartnerModel.BulkRegionServiceabilityTatResponseItemData()
869
+ LogisticsPartnerModel.BulkRegionServiceabilityTatResultItemData()
267
870
  ),
268
871
  page: LogisticsPartnerModel.Page(),
269
872
  });
270
873
  }
271
874
 
272
- /** @returns {Page} */
273
- static Page() {
875
+ /** @returns {BulkRateCardJob} */
876
+ static BulkRateCardJob() {
274
877
  return Joi.object({
275
- item_total: Joi.number(),
276
- next_id: Joi.string().allow(""),
277
- has_previous: Joi.boolean(),
278
- has_next: Joi.boolean(),
279
- current: Joi.number(),
280
878
  type: Joi.string().allow("").required(),
281
- size: Joi.number(),
879
+ total: Joi.number().required(),
880
+ failed: Joi.number().required(),
881
+ success: Joi.number().required(),
882
+ action: Joi.string().allow(""),
883
+ batch_id: Joi.string().allow("").required(),
884
+ status: Joi.string().allow("").required(),
885
+ failed_records: Joi.array().items(Joi.object().pattern(/\S/, Joi.any())),
886
+ file_path: Joi.string().allow("").allow(null),
887
+ created_on: Joi.string().allow(""),
888
+ modified_on: Joi.string().allow(""),
889
+ });
890
+ }
891
+
892
+ /** @returns {BulkRateCardJobDetails} */
893
+ static BulkRateCardJobDetails() {
894
+ return Joi.object({
895
+ file_path: Joi.string().allow(""),
896
+ rate_card_type: Joi.string().allow("").required(),
897
+ action: Joi.string().allow("").required(),
898
+ company_ids: Joi.array().items(Joi.number()),
899
+ });
900
+ }
901
+
902
+ /** @returns {SampleFileRateZoneRequestSchema} */
903
+ static SampleFileRateZoneRequestSchema() {
904
+ return Joi.object({
905
+ zone_type: Joi.string().allow(""),
906
+ country: Joi.string().allow(""),
907
+ region: Joi.string().allow(""),
908
+ });
909
+ }
910
+
911
+ /** @returns {RateZoneBulkJobDetails} */
912
+ static RateZoneBulkJobDetails() {
913
+ return Joi.object({
914
+ action: Joi.string().allow(""),
915
+ file_path: Joi.string().allow("").allow(null),
916
+ zone_type: Joi.string().allow(""),
917
+ country: Joi.string().allow(""),
918
+ region: Joi.string().allow(""),
919
+ });
920
+ }
921
+
922
+ /** @returns {RateZoneBulkJobList} */
923
+ static RateZoneBulkJobList() {
924
+ return Joi.object({
925
+ items: Joi.array().items(LogisticsPartnerModel.BulkRateCardJob()),
926
+ page: LogisticsPartnerModel.Page(),
927
+ });
928
+ }
929
+
930
+ /** @returns {RegionTatItemResult} */
931
+ static RegionTatItemResult() {
932
+ return Joi.object({
933
+ items: Joi.array()
934
+ .items(LogisticsPartnerModel.RegionTatResult())
935
+ .required(),
936
+ page: LogisticsPartnerModel.Page().required(),
937
+ });
938
+ }
939
+
940
+ /** @returns {RegionServiceabilityItemResult} */
941
+ static RegionServiceabilityItemResult() {
942
+ return Joi.object({
943
+ items: Joi.array()
944
+ .items(LogisticsPartnerModel.RegionServiceabilityResult())
945
+ .required(),
946
+ page: LogisticsPartnerModel.Page().required(),
947
+ });
948
+ }
949
+
950
+ /** @returns {ServiceabilityDetailsResult} */
951
+ static ServiceabilityDetailsResult() {
952
+ return Joi.object({
953
+ pickup_cutoff: Joi.string().allow("").allow(null),
954
+ country_code: Joi.string().allow(""),
955
+ state_code: Joi.string().allow(""),
956
+ city_code: Joi.string().allow(""),
957
+ sector_code: Joi.string().allow(""),
958
+ pincode: Joi.string().allow(""),
959
+ first_mile: Joi.boolean(),
960
+ last_mile: Joi.boolean(),
961
+ cod_limit: Joi.number(),
962
+ prepaid_limit: Joi.number(),
963
+ doorstep_return: Joi.boolean(),
964
+ doorstep_qc: Joi.boolean(),
965
+ forward_pickup_cutoff: Joi.string().allow(""),
966
+ reverse_pickup_cutoff: Joi.string().allow(""),
967
+ hand_to_hand_exchange: Joi.boolean(),
968
+ holiday_list: Joi.array().items(Joi.string().allow("")),
969
+ reverse_pickup: Joi.boolean().allow(null),
970
+ installation: Joi.boolean(),
971
+ id: Joi.string().allow(""),
972
+ });
973
+ }
974
+
975
+ /** @returns {ServiceabilityDetails} */
976
+ static ServiceabilityDetails() {
977
+ return Joi.object({
978
+ first_mile: Joi.boolean(),
979
+ last_mile: Joi.boolean(),
980
+ cod_limit: Joi.number(),
981
+ doorstep_return: Joi.boolean(),
982
+ doorstep_qc: Joi.boolean(),
983
+ forward_pickup_cutoff: Joi.string().allow(""),
984
+ reverse_pickup_cutoff: Joi.string().allow(""),
985
+ hand_to_hand_exchange: Joi.boolean(),
986
+ holiday_list: Joi.array().items(Joi.string().allow("")),
987
+ installation: Joi.boolean(),
988
+ pickup_cutoff: Joi.string().allow("").allow(null),
282
989
  });
283
990
  }
284
991
 
285
- /** @returns {BulkRegionJobSerializer} */
286
- static BulkRegionJobSerializer() {
992
+ /** @returns {RegionServiceabilityResult} */
993
+ static RegionServiceabilityResult() {
994
+ return Joi.object({
995
+ pickup_cutoff: Joi.string().allow("").allow(null),
996
+ country_code: Joi.string().allow("").required(),
997
+ state_code: Joi.string().allow(""),
998
+ city_code: Joi.string().allow(""),
999
+ sector_code: Joi.string().allow(""),
1000
+ pincode: Joi.string().allow(""),
1001
+ first_mile: Joi.boolean(),
1002
+ last_mile: Joi.boolean(),
1003
+ cod_limit: Joi.number(),
1004
+ prepaid_limit: Joi.number(),
1005
+ doorstep_return: Joi.boolean(),
1006
+ doorstep_qc: Joi.boolean(),
1007
+ reverse_pickup: Joi.boolean().allow(null),
1008
+ forward_pickup_cutoff: Joi.string().allow(""),
1009
+ reverse_pickup_cutoff: Joi.string().allow(""),
1010
+ hand_to_hand_exchange: Joi.boolean(),
1011
+ holiday_list: Joi.array().items(Joi.string().allow("")),
1012
+ installation: Joi.boolean(),
1013
+ id: Joi.string().allow("").required(),
1014
+ });
1015
+ }
1016
+
1017
+ /** @returns {RegionServiceabilityDetails} */
1018
+ static RegionServiceabilityDetails() {
1019
+ return Joi.object({
1020
+ country_code: Joi.string().allow("").required(),
1021
+ state_code: Joi.string().allow(""),
1022
+ city_code: Joi.string().allow(""),
1023
+ sector_code: Joi.string().allow(""),
1024
+ pincode: Joi.string().allow(""),
1025
+ first_mile: Joi.boolean(),
1026
+ last_mile: Joi.boolean(),
1027
+ cod_limit: Joi.number(),
1028
+ doorstep_return: Joi.boolean(),
1029
+ doorstep_qc: Joi.boolean(),
1030
+ forward_pickup_cutoff: Joi.string().allow(""),
1031
+ pickup_cutoff: Joi.string().allow("").allow(null),
1032
+ reverse_pickup_cutoff: Joi.string().allow(""),
1033
+ hand_to_hand_exchange: Joi.boolean(),
1034
+ prepaid_limit: Joi.number(),
1035
+ holiday_list: Joi.array().items(Joi.string().allow("")),
1036
+ installation: Joi.boolean(),
1037
+ });
1038
+ }
1039
+
1040
+ /** @returns {RegionTatDetails} */
1041
+ static RegionTatDetails() {
1042
+ return Joi.object({
1043
+ max_delivery_time: Joi.number().allow(null),
1044
+ min_delivery_time: Joi.number().allow(null),
1045
+ from_country_code: Joi.string().allow("").required(),
1046
+ from_state_code: Joi.string().allow(""),
1047
+ from_city_code: Joi.string().allow(""),
1048
+ from_sector_code: Joi.string().allow(""),
1049
+ from_pincode: Joi.string().allow(""),
1050
+ to_country_code: Joi.string().allow("").required(),
1051
+ to_state_code: Joi.string().allow(""),
1052
+ to_city_code: Joi.string().allow(""),
1053
+ to_sector_code: Joi.string().allow(""),
1054
+ to_pincode: Joi.string().allow(""),
1055
+ forward: LogisticsPartnerModel.TATDetails(),
1056
+ reverse: LogisticsPartnerModel.TATDetails(),
1057
+ });
1058
+ }
1059
+
1060
+ /** @returns {RegionTatResult} */
1061
+ static RegionTatResult() {
1062
+ return Joi.object({
1063
+ min_delivery_time: Joi.number().allow(null),
1064
+ max_delivery_time: Joi.number().allow(null),
1065
+ from_country_code: Joi.string().allow("").required(),
1066
+ from_state_code: Joi.string().allow(""),
1067
+ from_city_code: Joi.string().allow(""),
1068
+ from_sector_code: Joi.string().allow(""),
1069
+ from_pincode: Joi.string().allow(""),
1070
+ to_country_code: Joi.string().allow("").required(),
1071
+ to_state_code: Joi.string().allow(""),
1072
+ to_city_code: Joi.string().allow(""),
1073
+ to_sector_code: Joi.string().allow(""),
1074
+ to_pincode: Joi.string().allow(""),
1075
+ forward: LogisticsPartnerModel.TATDetails(),
1076
+ reverse: LogisticsPartnerModel.TATDetails(),
1077
+ id: Joi.string().allow("").required(),
1078
+ });
1079
+ }
1080
+
1081
+ /** @returns {BulkRegionJobDetails} */
1082
+ static BulkRegionJobDetails() {
287
1083
  return Joi.object({
288
1084
  file_path: Joi.string().allow(""),
289
1085
  country: Joi.string().allow("").required(),
@@ -292,12 +1088,12 @@ class LogisticsPartnerModel {
292
1088
  });
293
1089
  }
294
1090
 
295
- /** @returns {BulkRegionResponseItemData} */
296
- static BulkRegionResponseItemData() {
1091
+ /** @returns {BulkRegionResultItemData} */
1092
+ static BulkRegionResultItemData() {
297
1093
  return Joi.object({
298
1094
  file_path: Joi.string().allow("").required(),
299
1095
  failed: Joi.number(),
300
- failed_records: Joi.array().items(Joi.any()),
1096
+ failed_records: Joi.array().items(Joi.object().pattern(/\S/, Joi.any())),
301
1097
  action: Joi.string().allow("").required(),
302
1098
  batch_id: Joi.string().allow("").required(),
303
1099
  country: Joi.string().allow("").required(),
@@ -306,33 +1102,23 @@ class LogisticsPartnerModel {
306
1102
  status: Joi.string().allow("").required(),
307
1103
  total: Joi.number(),
308
1104
  error_file_path: Joi.string().allow(""),
1105
+ modified_on: Joi.string().allow(""),
1106
+ created_on: Joi.string().allow(""),
309
1107
  });
310
1108
  }
311
1109
 
312
- /** @returns {BulkRegionResponse} */
313
- static BulkRegionResponse() {
1110
+ /** @returns {BulkRegionResult} */
1111
+ static BulkRegionResult() {
314
1112
  return Joi.object({
315
1113
  items: Joi.array()
316
- .items(LogisticsPartnerModel.BulkRegionResponseItemData())
1114
+ .items(LogisticsPartnerModel.BulkRegionResultItemData())
317
1115
  .required(),
318
1116
  page: LogisticsPartnerModel.Page().required(),
319
1117
  });
320
1118
  }
321
1119
 
322
- /** @returns {CourierAccount} */
323
- static CourierAccount() {
324
- return Joi.object({
325
- extension_id: Joi.string().allow("").required(),
326
- account_id: Joi.string().allow("").required(),
327
- scheme_id: Joi.string().allow("").required(),
328
- is_self_ship: Joi.boolean().required(),
329
- stage: Joi.string().allow("").required(),
330
- is_own_account: Joi.boolean().required(),
331
- });
332
- }
333
-
334
- /** @returns {CourierAccountRequestBody} */
335
- static CourierAccountRequestBody() {
1120
+ /** @returns {CourierAccountDetailsBody} */
1121
+ static CourierAccountDetailsBody() {
336
1122
  return Joi.object({
337
1123
  extension_id: Joi.string().allow("").required(),
338
1124
  account_id: Joi.string().allow(""),
@@ -343,31 +1129,23 @@ class LogisticsPartnerModel {
343
1129
  });
344
1130
  }
345
1131
 
346
- /** @returns {CourierPartnerAccountFailureResponse} */
347
- static CourierPartnerAccountFailureResponse() {
348
- return Joi.object({
349
- success: Joi.boolean().required(),
350
- error: Joi.array()
351
- .items(LogisticsPartnerModel.ErrorResponse())
352
- .required(),
353
- });
354
- }
355
-
356
- /** @returns {CompanyCourierPartnerAccountListResponse} */
357
- static CompanyCourierPartnerAccountListResponse() {
1132
+ /** @returns {CompanyCourierPartnerAccountListResult} */
1133
+ static CompanyCourierPartnerAccountListResult() {
358
1134
  return Joi.object({
359
1135
  items: Joi.array()
360
- .items(LogisticsPartnerModel.CourierAccountResponse())
1136
+ .items(LogisticsPartnerModel.CourierAccountResult())
361
1137
  .required(),
362
1138
  page: LogisticsPartnerModel.Page().required(),
363
1139
  });
364
1140
  }
365
1141
 
366
- /** @returns {CourierAccountResponse} */
367
- static CourierAccountResponse() {
1142
+ /** @returns {CourierAccountResult} */
1143
+ static CourierAccountResult() {
368
1144
  return Joi.object({
369
1145
  account_id: Joi.string().allow("").required(),
1146
+ company_id: Joi.number(),
370
1147
  scheme_id: Joi.string().allow("").required(),
1148
+ extension_id: Joi.string().allow(""),
371
1149
  is_self_ship: Joi.boolean().required(),
372
1150
  stage: Joi.string().allow("").required(),
373
1151
  is_own_account: Joi.boolean().required(),
@@ -375,35 +1153,159 @@ class LogisticsPartnerModel {
375
1153
  });
376
1154
  }
377
1155
 
378
- /** @returns {CourierPartnerSchemeModel} */
379
- static CourierPartnerSchemeModel() {
1156
+ /** @returns {CourierPartnerSchemeDetailsModel} */
1157
+ static CourierPartnerSchemeDetailsModel() {
380
1158
  return Joi.object({
381
1159
  extension_id: Joi.string().allow("").required(),
382
- scheme_id: Joi.string().allow("").required(),
1160
+ scheme_id: Joi.string().allow(""),
383
1161
  name: Joi.string().allow("").required(),
1162
+ default_forward_pickup_cutoff: Joi.string().allow("").allow(null),
1163
+ default_reverse_pickup_cutoff: Joi.string().allow("").allow(null),
1164
+ default_cutoff_timezone: Joi.string().allow("").allow(null),
1165
+ default_tat: LogisticsPartnerModel.CourierPartnerSchemeDefaultTat(),
384
1166
  weight: LogisticsPartnerModel.ArithmeticOperations().required(),
1167
+ volumetric_weight: LogisticsPartnerModel.ArithmeticOperations(),
385
1168
  transport_type: Joi.string().allow("").required(),
386
1169
  region: Joi.string().allow("").required(),
387
1170
  delivery_type: Joi.string().allow("").required(),
388
1171
  payment_mode: Joi.array().items(Joi.string().allow("")).required(),
389
1172
  stage: Joi.string().allow("").required(),
1173
+ status_updates: Joi.string().allow(""),
1174
+ ndr_attempts: Joi.number(),
1175
+ qc_shipment_item_quantity: Joi.number().allow(null),
1176
+ non_qc_shipment_item_quantity: Joi.number().allow(null),
390
1177
  feature: LogisticsPartnerModel.CourierPartnerSchemeFeatures().required(),
391
1178
  });
392
1179
  }
393
1180
 
394
- /** @returns {CourierPartnerSchemeRequestModel} */
395
- static CourierPartnerSchemeRequestModel() {
1181
+ /** @returns {CourierPartnerPutSchema} */
1182
+ static CourierPartnerPutSchema() {
396
1183
  return Joi.object({
397
- extension_id: Joi.string().allow("").required(),
1184
+ extension_id: Joi.string().allow(""),
1185
+ created_by: LogisticsPartnerModel.CreatedBy(),
1186
+ modified_by: LogisticsPartnerModel.ModifiedBy(),
1187
+ created_on: Joi.string().allow(""),
1188
+ modified_on: Joi.string().allow(""),
398
1189
  scheme_id: Joi.string().allow(""),
1190
+ company_id: Joi.string().allow(""),
399
1191
  name: Joi.string().allow("").required(),
400
1192
  weight: LogisticsPartnerModel.ArithmeticOperations().required(),
1193
+ volumetric_weight: LogisticsPartnerModel.ArithmeticOperations(),
401
1194
  transport_type: Joi.string().allow("").required(),
402
1195
  region: Joi.string().allow("").required(),
403
1196
  delivery_type: Joi.string().allow("").required(),
404
1197
  payment_mode: Joi.array().items(Joi.string().allow("")).required(),
405
1198
  stage: Joi.string().allow("").required(),
1199
+ status_updates: Joi.string().allow(""),
1200
+ ndr_attempts: Joi.number(),
1201
+ qc_shipment_item_quantity: Joi.number().allow(null),
1202
+ non_qc_shipment_item_quantity: Joi.number().allow(null),
406
1203
  feature: LogisticsPartnerModel.CourierPartnerSchemeFeatures().required(),
1204
+ default_forward_pickup_cutoff: Joi.string().allow("").allow(null),
1205
+ default_reverse_pickup_cutoff: Joi.string().allow("").allow(null),
1206
+ default_cutoff_timezone: Joi.string().allow("").allow(null),
1207
+ default_tat: LogisticsPartnerModel.CourierPartnerSchemeDefaultTat(),
1208
+ });
1209
+ }
1210
+
1211
+ /** @returns {CourierPartnerSchemeList} */
1212
+ static CourierPartnerSchemeList() {
1213
+ return Joi.object({
1214
+ items: Joi.array()
1215
+ .items(LogisticsPartnerModel.CourierPartnerSchemeModelSchema())
1216
+ .required(),
1217
+ page: LogisticsPartnerModel.Page().required(),
1218
+ });
1219
+ }
1220
+
1221
+ /** @returns {CourierPartnerSchemeUpdateDetails} */
1222
+ static CourierPartnerSchemeUpdateDetails() {
1223
+ return Joi.object({
1224
+ name: Joi.string().allow("").required(),
1225
+ weight: LogisticsPartnerModel.ArithmeticOperations().required(),
1226
+ volumetric_weight: LogisticsPartnerModel.ArithmeticOperations(),
1227
+ transport_type: Joi.string().allow("").required(),
1228
+ region: Joi.string().allow("").required(),
1229
+ delivery_type: Joi.string().allow("").required(),
1230
+ payment_mode: Joi.array().items(Joi.string().allow("")).required(),
1231
+ stage: Joi.string().allow("").required(),
1232
+ status_updates: Joi.string().allow(""),
1233
+ ndr_attempts: Joi.number(),
1234
+ qc_shipment_item_quantity: Joi.number().allow(null),
1235
+ non_qc_shipment_item_quantity: Joi.number().allow(null),
1236
+ feature: LogisticsPartnerModel.CourierPartnerSchemeFeatures().required(),
1237
+ default_forward_pickup_cutoff: Joi.string().allow("").allow(null),
1238
+ default_reverse_pickup_cutoff: Joi.string().allow("").allow(null),
1239
+ default_cutoff_timezone: Joi.string().allow("").allow(null),
1240
+ default_tat: LogisticsPartnerModel.CourierPartnerSchemeDefaultTat(),
1241
+ });
1242
+ }
1243
+
1244
+ /** @returns {GetCountries} */
1245
+ static GetCountries() {
1246
+ return Joi.object({
1247
+ items: Joi.array()
1248
+ .items(LogisticsPartnerModel.GetCountriesItems())
1249
+ .required(),
1250
+ page: LogisticsPartnerModel.Page().required(),
1251
+ });
1252
+ }
1253
+
1254
+ /** @returns {TATUpdateDetails} */
1255
+ static TATUpdateDetails() {
1256
+ return Joi.object({
1257
+ max_delivery_time: Joi.number().allow(null),
1258
+ min_delivery_time: Joi.number().allow(null),
1259
+ forward: LogisticsPartnerModel.TATDetails(),
1260
+ reverse: LogisticsPartnerModel.TATDetails(),
1261
+ });
1262
+ }
1263
+
1264
+ /** @returns {StandardError} */
1265
+ static StandardError() {
1266
+ return Joi.object({
1267
+ message: Joi.string().allow("").required(),
1268
+ });
1269
+ }
1270
+
1271
+ /** @returns {ValidationErrors} */
1272
+ static ValidationErrors() {
1273
+ return Joi.object({
1274
+ errors: Joi.array()
1275
+ .items(LogisticsPartnerModel.ValidationError())
1276
+ .required(),
1277
+ });
1278
+ }
1279
+
1280
+ /** @returns {StandardRateZone} */
1281
+ static StandardRateZone() {
1282
+ return Joi.object({
1283
+ zone_name: Joi.string().allow(""),
1284
+ zone_slug: Joi.string().allow(""),
1285
+ });
1286
+ }
1287
+
1288
+ /** @returns {CreatedBy} */
1289
+ static CreatedBy() {
1290
+ return Joi.object({
1291
+ id: Joi.string().allow("").allow(null),
1292
+ }).allow(null);
1293
+ }
1294
+
1295
+ /** @returns {ModifiedBy} */
1296
+ static ModifiedBy() {
1297
+ return Joi.object({
1298
+ id: Joi.string().allow("").allow(null),
1299
+ }).allow(null);
1300
+ }
1301
+
1302
+ /** @returns {ArithmeticOperations} */
1303
+ static ArithmeticOperations() {
1304
+ return Joi.object({
1305
+ lt: Joi.number().allow(null),
1306
+ gt: Joi.number().allow(null),
1307
+ lte: Joi.number().allow(null),
1308
+ gte: Joi.number().allow(null),
407
1309
  });
408
1310
  }
409
1311
 
@@ -413,6 +1315,7 @@ class LogisticsPartnerModel {
413
1315
  doorstep_qc: Joi.boolean(),
414
1316
  qr: Joi.boolean(),
415
1317
  mps: Joi.boolean(),
1318
+ b2b: Joi.boolean(),
416
1319
  ndr: Joi.boolean(),
417
1320
  ndr_attempts: Joi.number(),
418
1321
  dangerous_goods: Joi.boolean(),
@@ -428,24 +1331,67 @@ class LogisticsPartnerModel {
428
1331
  single_pick_multi_drop: Joi.boolean(),
429
1332
  multi_pick_multi_drop: Joi.boolean(),
430
1333
  ewaybill: Joi.boolean(),
1334
+ qc_shipment_item_quantity: Joi.number().allow(null),
1335
+ non_qc_shipment_item_quantity: Joi.number().allow(null),
431
1336
  });
432
1337
  }
433
1338
 
434
- /** @returns {ArithmeticOperations} */
435
- static ArithmeticOperations() {
1339
+ /** @returns {CourierPartnerSchemeDefaultTat} */
1340
+ static CourierPartnerSchemeDefaultTat() {
436
1341
  return Joi.object({
437
- lt: Joi.number().allow(null),
438
- gt: Joi.number().allow(null),
439
- lte: Joi.number().allow(null),
440
- gte: Joi.number().allow(null),
1342
+ enabled: Joi.boolean(),
1343
+ tat: LogisticsPartnerModel.CourierPartnerSchemeTat(),
1344
+ });
1345
+ }
1346
+
1347
+ /** @returns {CourierPartnerSchemeTat} */
1348
+ static CourierPartnerSchemeTat() {
1349
+ return Joi.object({
1350
+ min: Joi.number(),
1351
+ max: Joi.number(),
1352
+ unit: Joi.string().allow(""),
1353
+ });
1354
+ }
1355
+
1356
+ /** @returns {Error} */
1357
+ static Error() {
1358
+ return Joi.object({
1359
+ type: Joi.string().allow("").allow(null),
1360
+ value: Joi.string().allow("").allow(null),
1361
+ message: Joi.string().allow("").allow(null),
1362
+ });
1363
+ }
1364
+
1365
+ /** @returns {Page} */
1366
+ static Page() {
1367
+ return Joi.object({
1368
+ item_total: Joi.number(),
1369
+ next_id: Joi.string().allow(""),
1370
+ has_previous: Joi.boolean(),
1371
+ has_next: Joi.boolean(),
1372
+ current: Joi.number(),
1373
+ type: Joi.string().allow("").required(),
1374
+ size: Joi.number(),
1375
+ page_size: Joi.number(),
441
1376
  });
442
1377
  }
443
1378
 
444
- /** @returns {CourierPartnerSchemeUpdateRequest} */
445
- static CourierPartnerSchemeUpdateRequest() {
1379
+ /** @returns {TATDetails} */
1380
+ static TATDetails() {
1381
+ return Joi.object({
1382
+ max_delivery_time: Joi.number(),
1383
+ min_delivery_time: Joi.number(),
1384
+ });
1385
+ }
1386
+
1387
+ /** @returns {CourierPartnerSchemeModel} */
1388
+ static CourierPartnerSchemeModel() {
446
1389
  return Joi.object({
1390
+ extension_id: Joi.string().allow("").required(),
1391
+ scheme_id: Joi.string().allow("").required(),
447
1392
  name: Joi.string().allow("").required(),
448
1393
  weight: LogisticsPartnerModel.ArithmeticOperations().required(),
1394
+ volumetric_weight: LogisticsPartnerModel.ArithmeticOperations(),
449
1395
  transport_type: Joi.string().allow("").required(),
450
1396
  region: Joi.string().allow("").required(),
451
1397
  delivery_type: Joi.string().allow("").required(),
@@ -455,40 +1401,51 @@ class LogisticsPartnerModel {
455
1401
  });
456
1402
  }
457
1403
 
458
- /** @returns {GetCountries} */
459
- static GetCountries() {
460
- return Joi.object({
461
- items: Joi.array()
462
- .items(LogisticsPartnerModel.GetCountriesItems())
463
- .required(),
464
- page: LogisticsPartnerModel.Page().required(),
465
- });
466
- }
467
-
468
1404
  /** @returns {GetCountriesItems} */
469
1405
  static GetCountriesItems() {
470
1406
  return Joi.object({
471
1407
  id: Joi.string().allow(""),
1408
+ sub_type: Joi.string().allow(""),
1409
+ uid: Joi.string().allow(""),
472
1410
  name: Joi.string().allow(""),
473
1411
  iso2: Joi.string().allow(""),
474
1412
  iso3: Joi.string().allow(""),
475
1413
  timezones: Joi.array().items(Joi.string().allow("")),
476
1414
  hierarchy: Joi.array().items(LogisticsPartnerModel.HierarchyItems()),
477
1415
  phone_code: Joi.string().allow(""),
478
- currency: Joi.string().allow(""),
1416
+ currency: LogisticsPartnerModel.CurrencyObject(),
479
1417
  type: Joi.string().allow(""),
480
1418
  latitude: Joi.string().allow(""),
481
1419
  longitude: Joi.string().allow(""),
482
1420
  display_name: Joi.string().allow(""),
1421
+ has_next_hierarchy: Joi.boolean(),
483
1422
  });
484
1423
  }
485
1424
 
486
1425
  /** @returns {HierarchyItems} */
487
1426
  static HierarchyItems() {
488
1427
  return Joi.object({
1428
+ name: Joi.string().allow(""),
489
1429
  display_name: Joi.string().allow(""),
490
1430
  slug: Joi.string().allow(""),
491
1431
  });
492
1432
  }
1433
+
1434
+ /** @returns {CurrencyObject} */
1435
+ static CurrencyObject() {
1436
+ return Joi.object({
1437
+ code: Joi.string().allow(""),
1438
+ name: Joi.string().allow(""),
1439
+ symbol: Joi.string().allow(""),
1440
+ });
1441
+ }
1442
+
1443
+ /** @returns {ValidationError} */
1444
+ static ValidationError() {
1445
+ return Joi.object({
1446
+ message: Joi.string().allow("").required(),
1447
+ field: Joi.string().allow("").required(),
1448
+ });
1449
+ }
493
1450
  }
494
1451
  module.exports = LogisticsPartnerModel;