@gofynd/fdk-client-javascript 1.4.2-beta.2 → 1.4.2-beta.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (126) hide show
  1. package/README.md +1 -1
  2. package/package.json +1 -1
  3. package/sdk/application/Cart/CartApplicationModel.d.ts +1742 -1726
  4. package/sdk/application/Cart/CartApplicationModel.js +1497 -1481
  5. package/sdk/application/Catalog/CatalogApplicationModel.d.ts +1917 -1917
  6. package/sdk/application/Catalog/CatalogApplicationModel.js +1611 -1611
  7. package/sdk/application/Common/CommonApplicationModel.d.ts +235 -235
  8. package/sdk/application/Common/CommonApplicationModel.js +172 -172
  9. package/sdk/application/Communication/CommunicationApplicationModel.d.ts +72 -72
  10. package/sdk/application/Communication/CommunicationApplicationModel.js +64 -64
  11. package/sdk/application/Configuration/ConfigurationApplicationModel.d.ts +1614 -1614
  12. package/sdk/application/Configuration/ConfigurationApplicationModel.js +1151 -1151
  13. package/sdk/application/Content/ContentApplicationModel.d.ts +797 -797
  14. package/sdk/application/Content/ContentApplicationModel.js +757 -757
  15. package/sdk/application/FileStorage/FileStorageApplicationModel.d.ts +79 -79
  16. package/sdk/application/FileStorage/FileStorageApplicationModel.js +84 -84
  17. package/sdk/application/Lead/LeadApplicationModel.d.ts +417 -417
  18. package/sdk/application/Lead/LeadApplicationModel.js +301 -301
  19. package/sdk/application/Logistic/LogisticApplicationModel.d.ts +666 -666
  20. package/sdk/application/Logistic/LogisticApplicationModel.js +601 -601
  21. package/sdk/application/Order/OrderApplicationModel.d.ts +852 -846
  22. package/sdk/application/Order/OrderApplicationModel.js +828 -822
  23. package/sdk/application/Payment/PaymentApplicationClient.d.ts +5 -5
  24. package/sdk/application/Payment/PaymentApplicationClient.js +10 -10
  25. package/sdk/application/Payment/PaymentApplicationModel.d.ts +2176 -2145
  26. package/sdk/application/Payment/PaymentApplicationModel.js +1474 -1453
  27. package/sdk/application/Payment/PaymentApplicationValidator.d.ts +5 -5
  28. package/sdk/application/Payment/PaymentApplicationValidator.js +3 -3
  29. package/sdk/application/PosCart/PosCartApplicationModel.d.ts +1462 -1462
  30. package/sdk/application/PosCart/PosCartApplicationModel.js +1260 -1260
  31. package/sdk/application/Rewards/RewardsApplicationModel.d.ts +214 -214
  32. package/sdk/application/Rewards/RewardsApplicationModel.js +211 -211
  33. package/sdk/application/Share/ShareApplicationModel.d.ts +114 -114
  34. package/sdk/application/Share/ShareApplicationModel.js +121 -121
  35. package/sdk/application/Theme/ThemeApplicationModel.d.ts +895 -895
  36. package/sdk/application/Theme/ThemeApplicationModel.js +684 -684
  37. package/sdk/application/User/UserApplicationClient.d.ts +2 -2
  38. package/sdk/application/User/UserApplicationClient.js +4 -7
  39. package/sdk/application/User/UserApplicationModel.d.ts +769 -764
  40. package/sdk/application/User/UserApplicationModel.js +731 -741
  41. package/sdk/partner/FileStorage/FileStoragePartnerModel.d.ts +63 -63
  42. package/sdk/partner/FileStorage/FileStoragePartnerModel.js +65 -65
  43. package/sdk/partner/Lead/LeadPartnerModel.d.ts +661 -661
  44. package/sdk/partner/Lead/LeadPartnerModel.js +491 -491
  45. package/sdk/partner/Logistics/LogisticsPartnerModel.d.ts +223 -223
  46. package/sdk/partner/Logistics/LogisticsPartnerModel.js +235 -235
  47. package/sdk/partner/Theme/ThemePartnerModel.d.ts +1087 -1087
  48. package/sdk/partner/Theme/ThemePartnerModel.js +819 -819
  49. package/sdk/partner/Webhook/WebhookPartnerModel.d.ts +386 -386
  50. package/sdk/partner/Webhook/WebhookPartnerModel.js +342 -342
  51. package/sdk/platform/AuditTrail/AuditTrailPlatformModel.d.ts +123 -123
  52. package/sdk/platform/AuditTrail/AuditTrailPlatformModel.js +109 -109
  53. package/sdk/platform/Billing/BillingPlatformModel.d.ts +801 -801
  54. package/sdk/platform/Billing/BillingPlatformModel.js +783 -783
  55. package/sdk/platform/Cart/CartPlatformModel.d.ts +3333 -3317
  56. package/sdk/platform/Cart/CartPlatformModel.js +2936 -2920
  57. package/sdk/platform/Catalog/CatalogPlatformApplicationClient.d.ts +26 -0
  58. package/sdk/platform/Catalog/CatalogPlatformApplicationClient.js +182 -0
  59. package/sdk/platform/Catalog/CatalogPlatformApplicationValidator.d.ts +70 -1
  60. package/sdk/platform/Catalog/CatalogPlatformApplicationValidator.js +44 -0
  61. package/sdk/platform/Catalog/CatalogPlatformModel.d.ts +1013 -980
  62. package/sdk/platform/Catalog/CatalogPlatformModel.js +977 -933
  63. package/sdk/platform/Common/CommonPlatformModel.d.ts +255 -255
  64. package/sdk/platform/Common/CommonPlatformModel.js +187 -187
  65. package/sdk/platform/Communication/CommunicationPlatformModel.d.ts +1238 -1238
  66. package/sdk/platform/Communication/CommunicationPlatformModel.js +1273 -1273
  67. package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.d.ts +661 -661
  68. package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.js +692 -692
  69. package/sdk/platform/Configuration/ConfigurationPlatformModel.d.ts +3198 -3198
  70. package/sdk/platform/Configuration/ConfigurationPlatformModel.js +2247 -2247
  71. package/sdk/platform/Content/ContentPlatformModel.d.ts +1842 -1825
  72. package/sdk/platform/Content/ContentPlatformModel.js +1868 -1848
  73. package/sdk/platform/Discount/DiscountPlatformModel.d.ts +245 -245
  74. package/sdk/platform/Discount/DiscountPlatformModel.js +248 -248
  75. package/sdk/platform/FileStorage/FileStoragePlatformApplicationClient.d.ts +1 -1
  76. package/sdk/platform/FileStorage/FileStoragePlatformApplicationClient.js +4 -1
  77. package/sdk/platform/FileStorage/FileStoragePlatformApplicationValidator.d.ts +2 -0
  78. package/sdk/platform/FileStorage/FileStoragePlatformApplicationValidator.js +2 -0
  79. package/sdk/platform/FileStorage/FileStoragePlatformClient.d.ts +2 -2
  80. package/sdk/platform/FileStorage/FileStoragePlatformClient.js +7 -4
  81. package/sdk/platform/FileStorage/FileStoragePlatformModel.d.ts +882 -869
  82. package/sdk/platform/FileStorage/FileStoragePlatformModel.js +894 -878
  83. package/sdk/platform/Finance/FinancePlatformModel.d.ts +1044 -1044
  84. package/sdk/platform/Finance/FinancePlatformModel.js +974 -974
  85. package/sdk/platform/Inventory/InventoryPlatformModel.d.ts +942 -942
  86. package/sdk/platform/Inventory/InventoryPlatformModel.js +1003 -1003
  87. package/sdk/platform/Lead/LeadPlatformModel.d.ts +608 -608
  88. package/sdk/platform/Lead/LeadPlatformModel.js +465 -465
  89. package/sdk/platform/Order/OrderPlatformModel.d.ts +5192 -5176
  90. package/sdk/platform/Order/OrderPlatformModel.js +4752 -4736
  91. package/sdk/platform/Partner/PartnerPlatformModel.d.ts +22 -22
  92. package/sdk/platform/Partner/PartnerPlatformModel.js +22 -22
  93. package/sdk/platform/Payment/PaymentPlatformModel.d.ts +2693 -2657
  94. package/sdk/platform/Payment/PaymentPlatformModel.js +1842 -1819
  95. package/sdk/platform/Rewards/RewardsPlatformModel.d.ts +204 -204
  96. package/sdk/platform/Rewards/RewardsPlatformModel.js +199 -199
  97. package/sdk/platform/Serviceability/ServiceabilityPlatformClient.d.ts +7 -6
  98. package/sdk/platform/Serviceability/ServiceabilityPlatformClient.js +11 -10
  99. package/sdk/platform/Serviceability/ServiceabilityPlatformModel.d.ts +1674 -1539
  100. package/sdk/platform/Serviceability/ServiceabilityPlatformModel.js +1663 -1534
  101. package/sdk/platform/Serviceability/ServiceabilityPlatformValidator.d.ts +4 -4
  102. package/sdk/platform/Serviceability/ServiceabilityPlatformValidator.js +4 -4
  103. package/sdk/platform/Share/SharePlatformApplicationClient.d.ts +1 -1
  104. package/sdk/platform/Share/SharePlatformApplicationClient.js +19 -6
  105. package/sdk/platform/Share/SharePlatformApplicationValidator.d.ts +13 -3
  106. package/sdk/platform/Share/SharePlatformApplicationValidator.js +6 -2
  107. package/sdk/platform/Share/SharePlatformModel.d.ts +147 -147
  108. package/sdk/platform/Share/SharePlatformModel.js +139 -139
  109. package/sdk/platform/Theme/ThemePlatformModel.d.ts +1046 -1046
  110. package/sdk/platform/Theme/ThemePlatformModel.js +789 -789
  111. package/sdk/platform/User/UserPlatformModel.d.ts +823 -753
  112. package/sdk/platform/User/UserPlatformModel.js +731 -661
  113. package/sdk/platform/Webhook/WebhookPlatformModel.d.ts +439 -439
  114. package/sdk/platform/Webhook/WebhookPlatformModel.js +364 -364
  115. package/sdk/public/Billing/BillingPublicModel.d.ts +55 -55
  116. package/sdk/public/Billing/BillingPublicModel.js +51 -51
  117. package/sdk/public/Configuration/ConfigurationPublicModel.d.ts +237 -237
  118. package/sdk/public/Configuration/ConfigurationPublicModel.js +174 -174
  119. package/sdk/public/Content/ContentPublicModel.d.ts +26 -26
  120. package/sdk/public/Content/ContentPublicModel.js +28 -28
  121. package/sdk/public/Inventory/InventoryPublicModel.d.ts +237 -237
  122. package/sdk/public/Inventory/InventoryPublicModel.js +257 -257
  123. package/sdk/public/Partner/PartnerPublicModel.d.ts +104 -104
  124. package/sdk/public/Partner/PartnerPublicModel.js +113 -113
  125. package/sdk/public/Webhook/WebhookPublicModel.d.ts +87 -87
  126. package/sdk/public/Webhook/WebhookPublicModel.js +93 -93
@@ -1,898 +1,810 @@
1
1
  const Joi = require("joi");
2
2
 
3
3
  /**
4
- * @typedef AddressResponse
5
- * @property {string} [address1]
6
- * @property {string} [address2]
7
- * @property {string} [city]
8
- * @property {string} [country]
9
- * @property {string} [landmark]
10
- * @property {number} [latitude]
11
- * @property {number} [longitude]
12
- * @property {number} [pincode]
13
- * @property {string} [state]
14
- */
15
-
16
- /**
17
- * @typedef ApplicationConfig
18
- * @property {string[]} [rule_ids]
19
- * @property {string[]} [sort]
20
- * @property {ZoneConfig} [zones]
21
- */
22
-
23
- /**
24
- * @typedef ApplicationSelfShipConfig
25
- * @property {Object} [self_ship]
4
+ * @typedef UpdateZoneConfigRequest
5
+ * @property {string} [serviceability_type]
26
6
  */
27
7
 
28
8
  /**
29
- * @typedef ApplicationSelfShipConfigResponse
30
- * @property {ApplicationSelfShipConfig} [data]
31
- * @property {ServiceabilityErrorResponse} [error]
32
- * @property {boolean} success
9
+ * @typedef ServiceabilityErrorResponse
10
+ * @property {string} message
11
+ * @property {string} value
12
+ * @property {string} type
33
13
  */
34
14
 
35
15
  /**
36
16
  * @typedef ApplicationServiceabilityConfig
37
17
  * @property {string} channel_id
38
- * @property {string} channel_type
39
18
  * @property {string} serviceability_type
19
+ * @property {string} channel_type
40
20
  */
41
21
 
42
22
  /**
43
23
  * @typedef ApplicationServiceabilityConfigResponse
44
- * @property {ApplicationServiceabilityConfig} [data]
45
24
  * @property {ServiceabilityErrorResponse} [error]
25
+ * @property {ApplicationServiceabilityConfig} [data]
46
26
  * @property {boolean} success
47
27
  */
48
28
 
49
29
  /**
50
- * @typedef ArithmeticOperations
51
- * @property {number} [gt]
52
- * @property {number} [gte]
53
- * @property {number} [lt]
54
- * @property {number} [lte]
30
+ * @typedef EntityRegionView_Request
31
+ * @property {string[]} sub_type
32
+ * @property {string[]} [parent_id]
55
33
  */
56
34
 
57
35
  /**
58
- * @typedef BulkRegionJobSerializer
59
- * @property {string} action
60
- * @property {string} country
61
- * @property {string} [file_path]
62
- * @property {string} region
36
+ * @typedef EntityRegionView_Error
37
+ * @property {string} [message]
38
+ * @property {string} [value]
39
+ * @property {string} [type]
63
40
  */
64
41
 
65
42
  /**
66
- * @typedef BulkRegionResponse
67
- * @property {BulkRegionResponseItemData[]} items
68
- * @property {Page} page
43
+ * @typedef EntityRegionView_page
44
+ * @property {string} type
45
+ * @property {boolean} has_next
46
+ * @property {number} item_total
47
+ * @property {number} size
48
+ * @property {number} current
69
49
  */
70
50
 
71
51
  /**
72
- * @typedef BulkRegionResponseItemData
73
- * @property {string} action
74
- * @property {string} batch_id
75
- * @property {string} country
76
- * @property {string} [error_file_path]
77
- * @property {number} [failed]
78
- * @property {Object[]} [failed_records]
79
- * @property {string} file_path
80
- * @property {string} region
81
- * @property {string} status
82
- * @property {number} [success]
83
- * @property {number} [total]
52
+ * @typedef getAppRegionZonesResponse
53
+ * @property {PageSchema[]} page
54
+ * @property {ListViewItems[]} items
84
55
  */
85
56
 
86
57
  /**
87
- * @typedef Channel
88
- * @property {string} [id]
89
- * @property {string} [type]
58
+ * @typedef PageSchema
59
+ * @property {boolean} has_next
60
+ * @property {number} item_total
61
+ * @property {number} size
62
+ * @property {number} current
63
+ * @property {string} type
90
64
  */
91
65
 
92
66
  /**
93
- * @typedef CommonError
94
- * @property {Object} [error]
95
- * @property {string} [status_code]
96
- * @property {string} [success]
67
+ * @typedef EntityRegionView_Items
68
+ * @property {string} sub_type
69
+ * @property {string} uid
70
+ * @property {string} name
97
71
  */
98
72
 
99
73
  /**
100
- * @typedef CompanyConfig
101
- * @property {boolean} [logistics_as_actual]
102
- * @property {string[]} rule_ids
103
- * @property {string[]} sort
74
+ * @typedef EntityRegionView_Response
75
+ * @property {EntityRegionView_Error} error
76
+ * @property {EntityRegionView_page} page
77
+ * @property {EntityRegionView_Items[]} data
78
+ * @property {boolean} success
104
79
  */
105
80
 
106
81
  /**
107
- * @typedef CompanyCourierPartnerAccountListResponse
108
- * @property {CourierAccountResponse[]} items
109
- * @property {Page} page
82
+ * @typedef ListViewSummary
83
+ * @property {number} total_zones
84
+ * @property {number} total_pincodes_served
85
+ * @property {number} total_active_zones
110
86
  */
111
87
 
112
88
  /**
113
- * @typedef CompanyStoreView_PageItems
114
- * @property {number} current
89
+ * @typedef ZoneDataItem
115
90
  * @property {boolean} has_next
116
91
  * @property {number} item_total
117
92
  * @property {number} size
93
+ * @property {number} current
118
94
  * @property {string} type
119
95
  */
120
96
 
121
97
  /**
122
- * @typedef CompanyStoreView_Response
123
- * @property {Object[]} [items]
124
- * @property {CompanyStoreView_PageItems[]} page
98
+ * @typedef ListViewProduct
99
+ * @property {number} count
100
+ * @property {string} type
125
101
  */
126
102
 
127
103
  /**
128
- * @typedef ContactNumberResponse
129
- * @property {number} [country_code]
130
- * @property {string} [number]
104
+ * @typedef ListViewChannels
105
+ * @property {string} channel_id
106
+ * @property {string} channel_type
131
107
  */
132
108
 
133
109
  /**
134
- * @typedef CourierAccount
135
- * @property {string} account_id
136
- * @property {string} extension_id
137
- * @property {boolean} is_own_account
138
- * @property {boolean} is_self_ship
139
- * @property {string} scheme_id
140
- * @property {string} stage
110
+ * @typedef ListViewItems
111
+ * @property {string} zone_id
112
+ * @property {string} name
113
+ * @property {string} slug
114
+ * @property {number} stores_count
115
+ * @property {boolean} is_active
116
+ * @property {number} regions_count
117
+ * @property {number} company_id
118
+ * @property {ListViewChannels[]} channels
141
119
  */
142
120
 
143
121
  /**
144
- * @typedef CourierAccountResponse
145
- * @property {string} account_id
146
- * @property {boolean} is_own_account
147
- * @property {boolean} is_self_ship
148
- * @property {string} scheme_id
149
- * @property {CourierPartnerSchemeModel} scheme_rules
150
- * @property {string} stage
122
+ * @typedef ListViewResponse
123
+ * @property {ZoneDataItem} page
124
+ * @property {ListViewItems[]} items
151
125
  */
152
126
 
153
127
  /**
154
- * @typedef CourierPartnerAccountFailureResponse
155
- * @property {ErrorResponse[]} error
156
- * @property {boolean} success
128
+ * @typedef CompanyStoreView_PageItems
129
+ * @property {string} type
130
+ * @property {boolean} has_next
131
+ * @property {number} item_total
132
+ * @property {number} size
133
+ * @property {number} current
157
134
  */
158
135
 
159
136
  /**
160
- * @typedef CourierPartnerList
161
- * @property {string} account_id
162
- * @property {string} extension_id
163
- * @property {boolean} is_self_ship
164
- * @property {string} name
137
+ * @typedef CompanyStoreView_Response
138
+ * @property {CompanyStoreView_PageItems[]} page
139
+ * @property {Object[]} [items]
165
140
  */
166
141
 
167
142
  /**
168
- * @typedef CourierPartnerRule
169
- * @property {CourierPartnerRuleConditions} conditions
170
- * @property {CourierPartnerList[]} [cp_list]
171
- * @property {boolean} is_active
172
- * @property {string} name
173
- * @property {string[]} sort
143
+ * @typedef GetZoneDataViewChannels
144
+ * @property {string} channel_id
145
+ * @property {string} channel_type
174
146
  */
175
147
 
176
148
  /**
177
- * @typedef CourierPartnerRuleConditions
178
- * @property {IntComparisonOperations} [brand_ids]
179
- * @property {IntComparisonOperations} [category_ids]
180
- * @property {IntComparisonOperations} [department_ids]
181
- * @property {LocationRule} [forward]
182
- * @property {ArithmeticOperations} [order_place_date]
183
- * @property {StringComparisonOperations} [payment_mode]
184
- * @property {IntComparisonOperations} [product_ids]
185
- * @property {StringComparisonOperations} [product_tags]
186
- * @property {LocationRule} [reverse]
187
- * @property {ArithmeticOperations} [shipment_cost]
188
- * @property {ArithmeticOperations} [shipment_volumetric_weight]
189
- * @property {ArithmeticOperations} [shipment_weight]
190
- * @property {IntComparisonOperations} [store_ids]
191
- * @property {StringComparisonOperations} [store_tags]
192
- * @property {StringComparisonOperations} [store_type]
193
- * @property {StringComparisonOperations} [zone_ids]
149
+ * @typedef ZoneProductTypes
150
+ * @property {string} type
151
+ * @property {string[]} tags
194
152
  */
195
153
 
196
154
  /**
197
- * @typedef CourierPartnerRulesListResponse
198
- * @property {CourierPartnerRule[]} items
199
- * @property {Page} page
155
+ * @typedef ZoneMappingType
156
+ * @property {string} country
157
+ * @property {string[]} [pincode]
158
+ * @property {string[]} [state]
200
159
  */
201
160
 
202
161
  /**
203
- * @typedef CourierPartnerSchemeFeatures
204
- * @property {boolean} [cold_storage_goods]
205
- * @property {boolean} [dangerous_goods]
206
- * @property {boolean} [doorstep_exchange]
207
- * @property {boolean} [doorstep_qc]
208
- * @property {boolean} [doorstep_return]
209
- * @property {boolean} [ewaybill]
210
- * @property {boolean} [fragile_goods]
211
- * @property {boolean} [mps]
212
- * @property {boolean} [multi_pick_multi_drop]
213
- * @property {boolean} [multi_pick_single_drop]
214
- * @property {boolean} [ndr]
215
- * @property {number} [ndr_attempts]
216
- * @property {boolean} [openbox_delivery]
217
- * @property {boolean} [product_installation]
218
- * @property {boolean} [qr]
219
- * @property {boolean} [restricted_goods]
220
- * @property {boolean} [single_pick_multi_drop]
221
- * @property {string} [status_updates]
162
+ * @typedef UpdateZoneData
163
+ * @property {string} zone_id
164
+ * @property {string} name
165
+ * @property {string} slug
166
+ * @property {number} company_id
167
+ * @property {boolean} is_active
168
+ * @property {GetZoneDataViewChannels[]} channels
169
+ * @property {ZoneProductTypes} product
170
+ * @property {number[]} store_ids
171
+ * @property {string} region_type
172
+ * @property {ZoneMappingType[]} mapping
173
+ * @property {string} [assignment_preference]
222
174
  */
223
175
 
224
176
  /**
225
- * @typedef CourierPartnerSchemeModel
226
- * @property {string} delivery_type
227
- * @property {string} extension_id
228
- * @property {CourierPartnerSchemeFeatures} feature
229
- * @property {string[]} payment_mode
230
- * @property {string} region
231
- * @property {string} scheme_id
232
- * @property {string} stage
233
- * @property {string} transport_type
234
- * @property {ArithmeticOperations} weight
177
+ * @typedef ZoneUpdateRequest
178
+ * @property {string} identifier
179
+ * @property {UpdateZoneData} data
235
180
  */
236
181
 
237
182
  /**
238
- * @typedef CreatedByResponse
239
- * @property {string} [user_id]
240
- * @property {string} [username]
183
+ * @typedef ZoneSuccessResponse
184
+ * @property {number} status_code
185
+ * @property {boolean} success
241
186
  */
242
187
 
243
188
  /**
244
- * @typedef CreateStoreRuleRequestSchema
245
- * @property {StoreRuleConditionSchema} [conditions]
246
- * @property {boolean} [is_active]
247
- * @property {string} [name]
248
- * @property {string[]} [sort]
249
- * @property {StorePrioritySchema[]} [store_priority]
250
- * @property {string[]} [tag_based_priority]
251
- * @property {string[]} [type_based_priority]
252
- */
253
-
254
- /**
255
- * @typedef CreateZoneData
256
- * @property {string} [assignment_preference]
257
- * @property {GetZoneDataViewChannels[]} channels
258
- * @property {number} company_id
259
- * @property {boolean} is_active
260
- * @property {ZoneMappingType[]} mapping
189
+ * @typedef GetZoneDataViewItems
190
+ * @property {string} zone_id
261
191
  * @property {string} name
262
- * @property {string} region_type
263
192
  * @property {string} slug
193
+ * @property {number} [company_id]
194
+ * @property {boolean} is_active
195
+ * @property {GetZoneDataViewChannels[]} channels
196
+ * @property {ZoneProductTypes} product
264
197
  * @property {number[]} store_ids
198
+ * @property {string} [region_type]
199
+ * @property {ZoneMappingType[]} mapping
200
+ * @property {string} [assignment_preference]
201
+ * @property {number} stores_count
265
202
  */
266
203
 
267
204
  /**
268
- * @typedef CustomerRadiusSchema
269
- * @property {number} [gt]
270
- * @property {number} [gte]
271
- * @property {number} [lt]
272
- * @property {number} [lte]
273
- * @property {string} unit
205
+ * @typedef GetSingleZoneDataViewResponse
206
+ * @property {GetZoneDataViewItems} data
274
207
  */
275
208
 
276
209
  /**
277
- * @typedef DocumentsResponse
278
- * @property {string} [legal_name]
279
- * @property {string} [type]
280
- * @property {string} [value]
281
- * @property {boolean} [verified]
210
+ * @typedef GetZoneByIdSchema
211
+ * @property {string} zone_id
212
+ * @property {string} name
213
+ * @property {string} slug
214
+ * @property {number} [company_id]
215
+ * @property {boolean} is_active
216
+ * @property {GetZoneDataViewChannels[]} channels
217
+ * @property {ZoneProductTypes} product
218
+ * @property {number[]} store_ids
219
+ * @property {string} region_type
220
+ * @property {ZoneMappingType[]} mapping
221
+ * @property {string} [assignment_preference]
222
+ * @property {number} stores_count
282
223
  */
283
224
 
284
225
  /**
285
- * @typedef Dp
286
- * @property {number} [area_code]
287
- * @property {boolean} [assign_dp_from_sb]
288
- * @property {string} [external_account_id]
289
- * @property {number} [fm_priority]
290
- * @property {string} [internal_account_id]
291
- * @property {number} [lm_priority]
292
- * @property {string[]} [operations]
293
- * @property {string} [payment_mode]
294
- * @property {number} [rvp_priority]
295
- * @property {string} [transport_mode]
226
+ * @typedef CreateZoneData
227
+ * @property {string} name
228
+ * @property {string} slug
229
+ * @property {number} company_id
230
+ * @property {boolean} is_active
231
+ * @property {GetZoneDataViewChannels[]} channels
232
+ * @property {number[]} store_ids
233
+ * @property {string} region_type
234
+ * @property {ZoneMappingType[]} mapping
235
+ * @property {string} [assignment_preference]
296
236
  */
297
237
 
298
238
  /**
299
- * @typedef EinvoiceResponse
300
- * @property {boolean} [enabled]
239
+ * @typedef ZoneResponse
240
+ * @property {number} status_code
241
+ * @property {string} zone_id
242
+ * @property {boolean} success
301
243
  */
302
244
 
303
245
  /**
304
- * @typedef EntityRegionView_Error
305
- * @property {string} [message]
306
- * @property {string} [type]
307
- * @property {string} [value]
246
+ * @typedef GetZoneFromPincodeViewRequest
247
+ * @property {string} country
248
+ * @property {string} pincode
308
249
  */
309
250
 
310
251
  /**
311
- * @typedef EntityRegionView_Items
252
+ * @typedef Zone
253
+ * @property {string} zone_id
254
+ * @property {string} type
312
255
  * @property {string} name
313
- * @property {string} sub_type
314
- * @property {string} uid
256
+ * @property {string[]} tags
257
+ * @property {string} slug
258
+ * @property {boolean} is_active
259
+ * @property {number[]} store_ids
260
+ * @property {string} assignment_preference
315
261
  */
316
262
 
317
263
  /**
318
- * @typedef EntityRegionView_page
319
- * @property {number} current
320
- * @property {boolean} has_next
321
- * @property {number} item_total
322
- * @property {number} size
323
- * @property {string} type
264
+ * @typedef GetZoneFromPincodeViewResponse
265
+ * @property {string} serviceability_type
266
+ * @property {Zone[]} zones
324
267
  */
325
268
 
326
269
  /**
327
- * @typedef EntityRegionView_Request
328
- * @property {string[]} [parent_id]
329
- * @property {string[]} sub_type
270
+ * @typedef GetZoneFromApplicationIdViewResponse
271
+ * @property {ZoneDataItem[]} page
272
+ * @property {ListViewItems[]} items
330
273
  */
331
274
 
332
275
  /**
333
- * @typedef EntityRegionView_Response
334
- * @property {EntityRegionView_Items[]} data
335
- * @property {EntityRegionView_Error} error
336
- * @property {EntityRegionView_page} page
337
- * @property {boolean} success
276
+ * @typedef ServiceabilityPageResponse
277
+ * @property {string} [type]
278
+ * @property {boolean} [has_next]
279
+ * @property {number} [item_total]
280
+ * @property {number} [size]
281
+ * @property {number} [current]
338
282
  */
339
283
 
340
284
  /**
341
- * @typedef Error
342
- * @property {string} [message]
343
- * @property {string} [type]
344
- * @property {string} [value]
285
+ * @typedef MobileNo
286
+ * @property {string} [number]
287
+ * @property {number} [country_code]
345
288
  */
346
289
 
347
290
  /**
348
- * @typedef ErrorResponse
349
- * @property {string} message
350
- * @property {string} type
351
- * @property {string} value
291
+ * @typedef ManagerResponse
292
+ * @property {string} [email]
293
+ * @property {MobileNo} [mobile_no]
294
+ * @property {string} [name]
352
295
  */
353
296
 
354
297
  /**
355
- * @typedef EwayBillResponse
356
- * @property {boolean} [enabled]
298
+ * @typedef ModifiedByResponse
299
+ * @property {string} [username]
300
+ * @property {string} [user_id]
357
301
  */
358
302
 
359
303
  /**
360
- * @typedef FailureResponse
361
- * @property {ErrorResponse[]} error
362
- * @property {boolean} success
304
+ * @typedef IntegrationTypeResponse
305
+ * @property {string} [inventory]
306
+ * @property {string} [order]
363
307
  */
364
308
 
365
309
  /**
366
- * @typedef getAppRegionZonesResponse
367
- * @property {ListViewItems[]} items
368
- * @property {PageSchema[]} page
310
+ * @typedef ProductReturnConfigResponse
311
+ * @property {boolean} [on_same_store]
369
312
  */
370
313
 
371
314
  /**
372
- * @typedef GetSingleZoneDataViewResponse
373
- * @property {GetZoneDataViewItems} data
315
+ * @typedef ContactNumberResponse
316
+ * @property {string} [number]
317
+ * @property {number} [country_code]
374
318
  */
375
319
 
376
320
  /**
377
- * @typedef GetStoreRulesApiResponse
378
- * @property {StoreRuleDataSchema[]} [items]
379
- * @property {Page} [page]
321
+ * @typedef AddressResponse
322
+ * @property {string} [city]
323
+ * @property {string} [address1]
324
+ * @property {number} [pincode]
325
+ * @property {string} [address2]
326
+ * @property {string} [landmark]
327
+ * @property {string} [state]
328
+ * @property {string} [country]
329
+ * @property {number} [latitude]
330
+ * @property {number} [longitude]
380
331
  */
381
332
 
382
333
  /**
383
- * @typedef GetStoresViewResponse
384
- * @property {ItemResponse[]} [items]
385
- * @property {ServiceabilityPageResponse} page
334
+ * @typedef CreatedByResponse
335
+ * @property {string} [username]
336
+ * @property {string} [user_id]
386
337
  */
387
338
 
388
339
  /**
389
- * @typedef GetZoneByIdSchema
390
- * @property {string} [assignment_preference]
391
- * @property {GetZoneDataViewChannels[]} channels
392
- * @property {number} [company_id]
393
- * @property {boolean} is_active
394
- * @property {ZoneMappingType[]} mapping
395
- * @property {string} name
396
- * @property {ZoneProductTypes} product
397
- * @property {string} region_type
398
- * @property {string} slug
399
- * @property {number[]} store_ids
400
- * @property {number} stores_count
401
- * @property {string} zone_id
340
+ * @typedef EwayBillResponse
341
+ * @property {boolean} [enabled]
402
342
  */
403
343
 
404
344
  /**
405
- * @typedef GetZoneDataViewChannels
406
- * @property {string} channel_id
407
- * @property {string} channel_type
345
+ * @typedef EinvoiceResponse
346
+ * @property {boolean} [enabled]
408
347
  */
409
348
 
410
349
  /**
411
- * @typedef GetZoneDataViewItems
412
- * @property {string} [assignment_preference]
413
- * @property {GetZoneDataViewChannels[]} channels
414
- * @property {number} [company_id]
415
- * @property {boolean} is_active
416
- * @property {ZoneMappingType[]} mapping
417
- * @property {string} name
418
- * @property {ZoneProductTypes} product
419
- * @property {string} [region_type]
420
- * @property {string} slug
421
- * @property {number[]} store_ids
422
- * @property {number} stores_count
423
- * @property {string} zone_id
350
+ * @typedef GstCredentialsResponse
351
+ * @property {EwayBillResponse} [e_waybill]
352
+ * @property {EinvoiceResponse} [e_invoice]
424
353
  */
425
354
 
426
355
  /**
427
- * @typedef GetZoneFromApplicationIdViewResponse
428
- * @property {ListViewItems[]} items
429
- * @property {ZoneDataItem[]} page
356
+ * @typedef WarningsResponse
357
+ * @property {string} [store_address]
430
358
  */
431
359
 
432
360
  /**
433
- * @typedef GetZoneFromPincodeViewRequest
434
- * @property {string} country
435
- * @property {string} pincode
361
+ * @typedef OpeningClosing
362
+ * @property {number} [minute]
363
+ * @property {number} [hour]
436
364
  */
437
365
 
438
366
  /**
439
- * @typedef GetZoneFromPincodeViewResponse
440
- * @property {string} serviceability_type
441
- * @property {Zone[]} zones
367
+ * @typedef TimmingResponse
368
+ * @property {boolean} [open]
369
+ * @property {string} [weekday]
370
+ * @property {OpeningClosing} [closing]
371
+ * @property {OpeningClosing} [opening]
442
372
  */
443
373
 
444
374
  /**
445
- * @typedef GstCredentialsResponse
446
- * @property {EinvoiceResponse} [e_invoice]
447
- * @property {EwayBillResponse} [e_waybill]
375
+ * @typedef DocumentsResponse
376
+ * @property {string} [legal_name]
377
+ * @property {string} [value]
378
+ * @property {string} [type]
379
+ * @property {boolean} [verified]
448
380
  */
449
381
 
450
382
  /**
451
- * @typedef IntComparisonOperations
452
- * @property {number[]} [includes]
383
+ * @typedef Dp
384
+ * @property {number} [fm_priority]
385
+ * @property {number} [rvp_priority]
386
+ * @property {number} [lm_priority]
387
+ * @property {string} [internal_account_id]
388
+ * @property {number} [area_code]
389
+ * @property {string} [payment_mode]
390
+ * @property {string[]} [operations]
391
+ * @property {string} [external_account_id]
392
+ * @property {string} [transport_mode]
393
+ * @property {boolean} [assign_dp_from_sb]
453
394
  */
454
395
 
455
396
  /**
456
- * @typedef IntegrationTypeResponse
457
- * @property {string} [inventory]
458
- * @property {string} [order]
397
+ * @typedef LogisticsResponse
398
+ * @property {boolean} [override]
399
+ * @property {Dp} [dp]
459
400
  */
460
401
 
461
402
  /**
462
403
  * @typedef ItemResponse
463
- * @property {string} [_cls]
464
- * @property {Object} [_custom_json]
465
- * @property {AddressResponse} [address]
466
- * @property {string} [code]
467
- * @property {number} [company]
468
- * @property {number} [company_id]
469
- * @property {ContactNumberResponse[]} [contact_numbers]
470
- * @property {CreatedByResponse} [created_by]
471
404
  * @property {string} [created_on]
472
- * @property {string} [display_name]
473
- * @property {DocumentsResponse[]} [documents]
474
- * @property {GstCredentialsResponse} [gst_credentials]
475
- * @property {IntegrationTypeResponse} [integration_type]
476
- * @property {LogisticsResponse} [logistics]
477
405
  * @property {ManagerResponse} [manager]
478
406
  * @property {ModifiedByResponse} [modified_by]
479
- * @property {string} [modified_on]
480
- * @property {string} [name]
481
- * @property {string[]} [notification_emails]
407
+ * @property {IntegrationTypeResponse} [integration_type]
408
+ * @property {string} [verified_on]
482
409
  * @property {ProductReturnConfigResponse} [product_return_config]
410
+ * @property {ContactNumberResponse[]} [contact_numbers]
411
+ * @property {ModifiedByResponse} [verified_by]
483
412
  * @property {string} [stage]
484
- * @property {string} [store_type]
485
- * @property {string} [sub_type]
486
- * @property {TimmingResponse[]} [timing]
413
+ * @property {AddressResponse} [address]
414
+ * @property {string} [modified_on]
415
+ * @property {CreatedByResponse} [created_by]
416
+ * @property {GstCredentialsResponse} [gst_credentials]
417
+ * @property {string} [display_name]
418
+ * @property {number} [company_id]
487
419
  * @property {number} [uid]
488
- * @property {ModifiedByResponse} [verified_by]
489
- * @property {string} [verified_on]
420
+ * @property {Object} [_custom_json]
421
+ * @property {string} [code]
490
422
  * @property {WarningsResponse} [warnings]
423
+ * @property {string} [name]
424
+ * @property {TimmingResponse[]} [timing]
425
+ * @property {DocumentsResponse[]} [documents]
426
+ * @property {string} [store_type]
427
+ * @property {string} [sub_type]
428
+ * @property {number} [company]
429
+ * @property {string} [_cls]
430
+ * @property {LogisticsResponse} [logistics]
431
+ * @property {string[]} [notification_emails]
491
432
  */
492
433
 
493
434
  /**
494
- * @typedef ListViewChannels
495
- * @property {string} channel_id
496
- * @property {string} channel_type
497
- */
498
-
499
- /**
500
- * @typedef ListViewItems
501
- * @property {ListViewChannels[]} channels
502
- * @property {number} company_id
503
- * @property {boolean} is_active
504
- * @property {string} name
505
- * @property {ListViewProduct} product
506
- * @property {number} regions_count
507
- * @property {string} slug
508
- * @property {number} stores_count
509
- * @property {string} zone_id
435
+ * @typedef GetStoresViewResponse
436
+ * @property {ServiceabilityPageResponse} page
437
+ * @property {ItemResponse[]} [items]
510
438
  */
511
439
 
512
440
  /**
513
- * @typedef ListViewProduct
514
- * @property {number} count
515
- * @property {string} type
441
+ * @typedef PincodeMopData
442
+ * @property {number[]} pincodes
443
+ * @property {string} country
444
+ * @property {string} action
516
445
  */
517
446
 
518
447
  /**
519
- * @typedef ListViewResponse
520
- * @property {ListViewItems[]} items
521
- * @property {ZoneDataItem[]} page
448
+ * @typedef PincodeMopUpdateResponse
449
+ * @property {number} pincode
450
+ * @property {string} channel_id
451
+ * @property {string} country
452
+ * @property {boolean} is_active
522
453
  */
523
454
 
524
455
  /**
525
- * @typedef ListViewSummary
526
- * @property {number} total_active_zones
527
- * @property {number} total_pincodes_served
528
- * @property {number} total_zones
456
+ * @typedef PincodeMOPresponse
457
+ * @property {boolean} success
458
+ * @property {number} status_code
459
+ * @property {string} batch_id
460
+ * @property {string} country
461
+ * @property {string} action
462
+ * @property {number[]} [pincodes]
463
+ * @property {PincodeMopUpdateResponse[]} [updated_pincodes]
529
464
  */
530
465
 
531
466
  /**
532
- * @typedef LocationRule
533
- * @property {LocationRuleValues[]} [includes]
534
- * @property {string} [type]
467
+ * @typedef CommonError
468
+ * @property {string} [status_code]
469
+ * @property {Object} [error]
470
+ * @property {string} [success]
535
471
  */
536
472
 
537
473
  /**
538
- * @typedef LocationRuleValues
539
- * @property {string} [display_name]
540
- * @property {string} id
541
- * @property {string} [name]
542
- * @property {string} [parent_id]
543
- * @property {string[]} [parent_ids]
544
- * @property {string} [sub_type]
474
+ * @typedef PincodeMopBulkData
475
+ * @property {string} batch_id
476
+ * @property {string} s3_url
545
477
  */
546
478
 
547
479
  /**
548
- * @typedef LogisticsResponse
549
- * @property {Dp} [dp]
550
- * @property {boolean} [override]
480
+ * @typedef PincodeBulkViewResponse
481
+ * @property {string} batch_id
482
+ * @property {string} s3_url
551
483
  */
552
484
 
553
485
  /**
554
- * @typedef ManagerResponse
555
- * @property {string} [email]
556
- * @property {MobileNo} [mobile_no]
557
- * @property {string} [name]
486
+ * @typedef PincodeCodStatusListingRequest
487
+ * @property {string} [country]
488
+ * @property {boolean} [is_active]
489
+ * @property {number} [pincode]
490
+ * @property {number} [current]
491
+ * @property {number} [page_size]
558
492
  */
559
493
 
560
494
  /**
561
- * @typedef MobileNo
562
- * @property {number} [country_code]
563
- * @property {string} [number]
495
+ * @typedef PincodeCodStatusListingResponse
496
+ * @property {string} country
497
+ * @property {PincodeCodStatusListingResponse[]} data
498
+ * @property {boolean} success
499
+ * @property {Error[]} [errors]
500
+ * @property {PincodeCodStatusListingPage} page
501
+ * @property {PincodeCodStatusListingSummary} summary
564
502
  */
565
503
 
566
504
  /**
567
- * @typedef ModifiedByResponse
568
- * @property {string} [user_id]
569
- * @property {string} [username]
505
+ * @typedef Error
506
+ * @property {string} [type]
507
+ * @property {string} [value]
508
+ * @property {string} [message]
570
509
  */
571
510
 
572
511
  /**
573
- * @typedef OpeningClosing
574
- * @property {number} [hour]
575
- * @property {number} [minute]
512
+ * @typedef PincodeCodStatusListingPage
513
+ * @property {string} type
514
+ * @property {boolean} has_next
515
+ * @property {number} item_total
516
+ * @property {number} size
517
+ * @property {number} current
576
518
  */
577
519
 
578
520
  /**
579
- * @typedef PackageMaterial
580
- * @property {boolean} [auto_calculate]
581
- * @property {Channel[]} channels
582
- * @property {number} error_rate
583
- * @property {number} height
584
- * @property {number} length
585
- * @property {number} [max_weight]
586
- * @property {string[]} [media]
587
- * @property {string} name
588
- * @property {string} package_type
589
- * @property {number} [package_vol_weight]
590
- * @property {PackageMaterialRule[]} [rules]
591
- * @property {string} size
592
- * @property {string} status
593
- * @property {number[]} store_ids
594
- * @property {boolean} [track_inventory]
595
- * @property {number} weight
596
- * @property {number} width
521
+ * @typedef PincodeCodStatusListingSummary
522
+ * @property {number} total_active_pincodes
523
+ * @property {number} total_inactive_pincodes
597
524
  */
598
525
 
599
526
  /**
600
- * @typedef PackageMaterialList
601
- * @property {PackageMaterialResponse} [items]
602
- * @property {Page} [page]
527
+ * @typedef PincodeMopUpdateAuditHistoryRequest
528
+ * @property {string} entity_type
529
+ * @property {string} [file_name]
603
530
  */
604
531
 
605
532
  /**
606
- * @typedef PackageMaterialResponse
607
- * @property {boolean} [auto_calculate]
608
- * @property {Channel[]} channels
609
- * @property {number} error_rate
610
- * @property {number} height
611
- * @property {string} [id]
612
- * @property {number} [item_id]
613
- * @property {number} length
614
- * @property {number} [max_weight]
615
- * @property {string[]} [media]
616
- * @property {string} name
617
- * @property {string} package_type
618
- * @property {number} [package_vol_weight]
619
- * @property {PackageMaterialRule[]} [rules]
620
- * @property {string} size
621
- * @property {string} status
622
- * @property {number[]} store_ids
623
- * @property {boolean} [track_inventory]
624
- * @property {number} weight
625
- * @property {number} width
533
+ * @typedef PincodeMopUpdateAuditHistoryPaging
534
+ * @property {string} [type]
535
+ * @property {number} [size]
536
+ * @property {number} [current]
537
+ * @property {boolean} [has_next]
538
+ * @property {number} [item_total]
626
539
  */
627
540
 
628
541
  /**
629
- * @typedef PackageMaterialRule
630
- * @property {PackageMaterialRuleQuantity} [quantity]
631
- * @property {string} [rule_id]
632
- * @property {number} [weight]
542
+ * @typedef PincodeMopUpdateAuditHistoryResponse
543
+ * @property {string} [batch_id]
544
+ * @property {string} [entity_type]
545
+ * @property {string} [error_file_s3_url]
546
+ * @property {string} [s3_url]
547
+ * @property {string} [file_name]
548
+ * @property {string} [updated_at]
549
+ * @property {string} [updated_by]
550
+ * @property {boolean} [success]
633
551
  */
634
552
 
635
553
  /**
636
- * @typedef PackageMaterialRuleList
637
- * @property {PackageRuleResponse} [items]
638
- * @property {Page} [page]
554
+ * @typedef PincodeMopUpdateAuditHistoryResponseData
555
+ * @property {string} [entity_type]
556
+ * @property {PincodeMopUpdateAuditHistoryPaging} page
557
+ * @property {PincodeMopUpdateAuditHistoryResponse[]} data
639
558
  */
640
559
 
641
560
  /**
642
- * @typedef PackageMaterialRuleQuantity
643
- * @property {number} [max]
644
- * @property {number} [min]
561
+ * @typedef ArithmeticOperations
562
+ * @property {number} [lt]
563
+ * @property {number} [gt]
564
+ * @property {number} [lte]
565
+ * @property {number} [gte]
645
566
  */
646
567
 
647
568
  /**
648
- * @typedef PackageRule
649
- * @property {PackageRuleCategory} [category_id]
650
- * @property {number} company_id
651
- * @property {boolean} [is_active]
652
- * @property {string} name
653
- * @property {PackageRuleProduct} [product_id]
654
- * @property {PackageRuleProductTag} [product_tag]
655
- * @property {string} type
569
+ * @typedef SchemeRulesFeatures
570
+ * @property {boolean} [quality_check]
571
+ * @property {boolean} [quick_response_code]
572
+ * @property {boolean} [e_waybill]
573
+ * @property {boolean} [multi_part_shipments]
574
+ * @property {boolean} [flammable]
575
+ * @property {boolean} [hazmat]
576
+ * @property {boolean} [battery_operated]
656
577
  */
657
578
 
658
579
  /**
659
- * @typedef PackageRuleCategory
660
- * @property {number[]} [includes]
580
+ * @typedef SchemeRules
581
+ * @property {ArithmeticOperations} [weight]
582
+ * @property {string[]} [transport_type]
583
+ * @property {string} [region]
584
+ * @property {string[]} [payment_mode]
585
+ * @property {SchemeRulesFeatures} [feature]
661
586
  */
662
587
 
663
588
  /**
664
- * @typedef PackageRuleProduct
665
- * @property {number[]} [includes]
589
+ * @typedef CourierAccount
590
+ * @property {string} extension_id
591
+ * @property {string} account_id
592
+ * @property {string} scheme_id
593
+ * @property {boolean} is_self_ship
594
+ * @property {string} stage
595
+ * @property {boolean} is_own_account
666
596
  */
667
597
 
668
598
  /**
669
- * @typedef PackageRuleProductTag
670
- * @property {string[]} [includes]
599
+ * @typedef ErrorResponse
600
+ * @property {string} value
601
+ * @property {string} message
602
+ * @property {string} type
671
603
  */
672
604
 
673
605
  /**
674
- * @typedef PackageRuleResponse
675
- * @property {PackageRuleCategory} [category_id]
676
- * @property {number} company_id
677
- * @property {string} [id]
678
- * @property {boolean} [is_active]
679
- * @property {string} name
680
- * @property {PackageRuleProduct} [product_id]
681
- * @property {PackageRuleProductTag} [product_tag]
682
- * @property {string} type
606
+ * @typedef CourierPartnerAccountFailureResponse
607
+ * @property {boolean} success
608
+ * @property {ErrorResponse[]} error
683
609
  */
684
610
 
685
611
  /**
686
612
  * @typedef Page
687
- * @property {number} [current]
688
- * @property {boolean} [has_next]
689
- * @property {boolean} [has_previous]
690
613
  * @property {number} [item_total]
691
614
  * @property {string} [next_id]
692
- * @property {number} [size]
615
+ * @property {boolean} [has_previous]
616
+ * @property {boolean} [has_next]
617
+ * @property {number} [current]
693
618
  * @property {string} type
619
+ * @property {number} [size]
694
620
  */
695
621
 
696
622
  /**
697
- * @typedef PageSchema
698
- * @property {number} current
699
- * @property {boolean} has_next
700
- * @property {number} item_total
701
- * @property {number} size
702
- * @property {string} type
623
+ * @typedef CourierPartnerList
624
+ * @property {string} extension_id
625
+ * @property {string} account_id
626
+ * @property {string} name
627
+ * @property {boolean} is_self_ship
703
628
  */
704
629
 
705
630
  /**
706
- * @typedef PincodeBulkViewResponse
707
- * @property {string} batch_id
708
- * @property {string} s3_url
631
+ * @typedef LocationRuleValues
632
+ * @property {string} id
633
+ * @property {string} [sub_type]
634
+ * @property {string} [name]
635
+ * @property {string} [display_name]
636
+ * @property {string} [parent_id]
637
+ * @property {string[]} [parent_ids]
709
638
  */
710
639
 
711
640
  /**
712
- * @typedef PincodeCodStatusListingPage
713
- * @property {number} current
714
- * @property {boolean} has_next
715
- * @property {number} item_total
716
- * @property {number} size
717
- * @property {string} type
641
+ * @typedef LocationRule
642
+ * @property {string} [type]
643
+ * @property {LocationRuleValues[]} [includes]
718
644
  */
719
645
 
720
646
  /**
721
- * @typedef PincodeCodStatusListingRequest
722
- * @property {string} [country]
723
- * @property {number} [current]
724
- * @property {boolean} [is_active]
725
- * @property {number} [page_size]
726
- * @property {number} [pincode]
647
+ * @typedef StringComparisonOperations
648
+ * @property {string[]} [includes]
727
649
  */
728
650
 
729
651
  /**
730
- * @typedef PincodeCodStatusListingResponse
731
- * @property {string} country
732
- * @property {PincodeCodStatusListingResponse[]} data
733
- * @property {Error[]} [errors]
734
- * @property {PincodeCodStatusListingPage} page
735
- * @property {boolean} success
736
- * @property {PincodeCodStatusListingSummary} summary
652
+ * @typedef IntComparisonOperations
653
+ * @property {number[]} [includes]
737
654
  */
738
655
 
739
656
  /**
740
- * @typedef PincodeCodStatusListingSummary
741
- * @property {number} total_active_pincodes
742
- * @property {number} total_inactive_pincodes
657
+ * @typedef CourierPartnerRuleConditions
658
+ * @property {LocationRule} [forward]
659
+ * @property {LocationRule} [reverse]
660
+ * @property {StringComparisonOperations} [payment_mode]
661
+ * @property {IntComparisonOperations} [category_ids]
662
+ * @property {IntComparisonOperations} [product_ids]
663
+ * @property {StringComparisonOperations} [product_tags]
664
+ * @property {StringComparisonOperations} [zone_ids]
665
+ * @property {IntComparisonOperations} [department_ids]
666
+ * @property {IntComparisonOperations} [brand_ids]
667
+ * @property {ArithmeticOperations} [order_place_date]
668
+ * @property {IntComparisonOperations} [store_ids]
669
+ * @property {StringComparisonOperations} [store_type]
670
+ * @property {StringComparisonOperations} [store_tags]
671
+ * @property {ArithmeticOperations} [shipment_weight]
672
+ * @property {ArithmeticOperations} [shipment_cost]
673
+ * @property {ArithmeticOperations} [shipment_volumetric_weight]
743
674
  */
744
675
 
745
676
  /**
746
- * @typedef PincodeMopBulkData
747
- * @property {string} batch_id
748
- * @property {string} s3_url
677
+ * @typedef CourierPartnerRule
678
+ * @property {boolean} is_active
679
+ * @property {CourierPartnerList[]} [cp_list]
680
+ * @property {string} name
681
+ * @property {CourierPartnerRuleConditions} conditions
682
+ * @property {string[]} sort
749
683
  */
750
684
 
751
685
  /**
752
- * @typedef PincodeMopData
753
- * @property {string} action
754
- * @property {string} country
755
- * @property {number[]} pincodes
686
+ * @typedef FailureResponse
687
+ * @property {boolean} success
688
+ * @property {ErrorResponse[]} error
756
689
  */
757
690
 
758
691
  /**
759
- * @typedef PincodeMOPresponse
760
- * @property {string} action
761
- * @property {string} batch_id
762
- * @property {string} country
763
- * @property {number[]} [pincodes]
764
- * @property {number} status_code
765
- * @property {boolean} success
766
- * @property {PincodeMopUpdateResponse[]} [updated_pincodes]
692
+ * @typedef CourierPartnerRulesListResponse
693
+ * @property {CourierPartnerRule[]} items
694
+ * @property {Page} page
767
695
  */
768
696
 
769
697
  /**
770
- * @typedef PincodeMopUpdateAuditHistoryPaging
771
- * @property {number} [current]
772
- * @property {boolean} [has_next]
773
- * @property {number} [item_total]
774
- * @property {number} [size]
775
- * @property {string} [type]
698
+ * @typedef CompanyConfig
699
+ * @property {string[]} rule_ids
700
+ * @property {string[]} sort
701
+ * @property {boolean} [logistics_as_actual]
776
702
  */
777
703
 
778
704
  /**
779
- * @typedef PincodeMopUpdateAuditHistoryRequest
780
- * @property {string} entity_type
781
- * @property {string} [file_name]
705
+ * @typedef ZoneConfig
706
+ * @property {string} [serviceability_type]
782
707
  */
783
708
 
784
709
  /**
785
- * @typedef PincodeMopUpdateAuditHistoryResponse
786
- * @property {string} [batch_id]
787
- * @property {string} [entity_type]
788
- * @property {string} [error_file_s3_url]
789
- * @property {string} [file_name]
790
- * @property {string} [s3_url]
791
- * @property {boolean} [success]
792
- * @property {string} [updated_at]
793
- * @property {string} [updated_by]
710
+ * @typedef ApplicationConfig
711
+ * @property {string[]} [rule_ids]
712
+ * @property {string[]} [sort]
713
+ * @property {ZoneConfig} [zones]
794
714
  */
795
715
 
796
716
  /**
797
- * @typedef PincodeMopUpdateAuditHistoryResponseData
798
- * @property {PincodeMopUpdateAuditHistoryResponse[]} data
799
- * @property {string} [entity_type]
800
- * @property {PincodeMopUpdateAuditHistoryPaging} page
717
+ * @typedef BulkRegionJobSerializer
718
+ * @property {string} [file_path]
719
+ * @property {string} country
720
+ * @property {string} action
721
+ * @property {string} region
801
722
  */
802
723
 
803
724
  /**
804
- * @typedef PincodeMopUpdateResponse
805
- * @property {string} channel_id
725
+ * @typedef BulkRegionResponseItemData
726
+ * @property {string} file_path
727
+ * @property {number} [failed]
728
+ * @property {Object[]} [failed_records]
729
+ * @property {string} action
730
+ * @property {string} batch_id
806
731
  * @property {string} country
807
- * @property {boolean} is_active
808
- * @property {number} pincode
732
+ * @property {number} [success]
733
+ * @property {string} region
734
+ * @property {string} status
735
+ * @property {number} [total]
736
+ * @property {string} [error_file_path]
809
737
  */
810
738
 
811
739
  /**
812
- * @typedef ProductReturnConfigResponse
813
- * @property {boolean} [on_same_store]
740
+ * @typedef BulkRegionResponse
741
+ * @property {BulkRegionResponseItemData[]} items
742
+ * @property {Page} page
814
743
  */
815
744
 
816
745
  /**
817
- * @typedef ReAssignStoreRequest
818
- * @property {Object[]} articles
819
- * @property {Object} configuration
820
- * @property {string} identifier
821
- * @property {string[]} ignored_locations
822
- * @property {string} to_pincode
746
+ * @typedef SelfShipResponse
747
+ * @property {boolean} is_active
748
+ * @property {number} tat
823
749
  */
824
750
 
825
751
  /**
826
- * @typedef ReAssignStoreResponse
827
- * @property {Object[]} [articles]
828
- * @property {Object} error
829
- * @property {boolean} success
830
- * @property {string} to_pincode
752
+ * @typedef ApplicationSelfShipConfig
753
+ * @property {Object} [self_ship]
831
754
  */
832
755
 
833
756
  /**
834
- * @typedef RulePriorityRequest
835
- * @property {number} priority
836
- * @property {string} rule_id
757
+ * @typedef ApplicationSelfShipConfigResponse
758
+ * @property {ServiceabilityErrorResponse} [error]
759
+ * @property {ApplicationSelfShipConfig} [data]
760
+ * @property {boolean} success
837
761
  */
838
762
 
839
763
  /**
840
- * @typedef RulePriorityResponse
841
- * @property {boolean} [success]
764
+ * @typedef StoreRuleConfigData
765
+ * @property {string[]} [rule_ids]
766
+ * @property {string[]} [type_based_priority]
767
+ * @property {string[]} [tag_based_priority]
768
+ * @property {StorePrioritySchema[]} [store_priority]
769
+ * @property {string[]} [sort]
842
770
  */
843
771
 
844
772
  /**
845
- * @typedef SchemeRules
846
- * @property {SchemeRulesFeatures} [feature]
847
- * @property {string[]} [payment_mode]
848
- * @property {string} [region]
849
- * @property {string[]} [transport_type]
850
- * @property {ArithmeticOperations} [weight]
773
+ * @typedef CustomerRadiusSchema
774
+ * @property {string} unit
775
+ * @property {number} [lt]
776
+ * @property {number} [lte]
777
+ * @property {number} [gt]
778
+ * @property {number} [gte]
851
779
  */
852
780
 
853
781
  /**
854
- * @typedef SchemeRulesFeatures
855
- * @property {boolean} [battery_operated]
856
- * @property {boolean} [e_waybill]
857
- * @property {boolean} [flammable]
858
- * @property {boolean} [hazmat]
859
- * @property {boolean} [multi_part_shipments]
860
- * @property {boolean} [quality_check]
861
- * @property {boolean} [quick_response_code]
782
+ * @typedef StoreRuleConditionSchema
783
+ * @property {IntComparisonOperations} [department_ids]
784
+ * @property {IntComparisonOperations} [category_ids]
785
+ * @property {IntComparisonOperations} [brand_ids]
786
+ * @property {LocationRule} [to_location]
787
+ * @property {CustomerRadiusSchema} [customer_radius]
788
+ * @property {StringComparisonOperations} [store_type]
789
+ * @property {StringComparisonOperations} [product_tags]
790
+ * @property {IntComparisonOperations} [product_ids]
791
+ * @property {StringComparisonOperations} [store_tags]
792
+ * @property {ArithmeticOperations} [order_place_date]
793
+ * @property {StringComparisonOperations} [zone_ids]
862
794
  */
863
795
 
864
796
  /**
865
- * @typedef SelfShipResponse
866
- * @property {boolean} is_active
867
- * @property {number} tat
868
- */
869
-
870
- /**
871
- * @typedef ServiceabilityErrorResponse
872
- * @property {string} message
873
- * @property {string} type
874
- * @property {string} value
875
- */
876
-
877
- /**
878
- * @typedef ServiceabilityModel
879
- * @property {boolean} is_first_mile
880
- * @property {boolean} is_installation
881
- * @property {boolean} is_last_mile
882
- * @property {boolean} is_qc
883
- * @property {boolean} is_return
884
- * @property {number} lm_cod_limit
885
- * @property {string} pickup_cutoff
886
- * @property {string} route_code
887
- */
888
-
889
- /**
890
- * @typedef ServiceabilityPageResponse
891
- * @property {number} [current]
892
- * @property {boolean} [has_next]
893
- * @property {number} [item_total]
894
- * @property {number} [size]
895
- * @property {string} [type]
797
+ * @typedef StoreRuleDataSchema
798
+ * @property {string} [id]
799
+ * @property {string} [name]
800
+ * @property {number} [company_id]
801
+ * @property {string} [application_id]
802
+ * @property {string[]} [type_based_priority]
803
+ * @property {string[]} [tag_based_priority]
804
+ * @property {StorePrioritySchema[]} [store_priority]
805
+ * @property {string[]} [sort]
806
+ * @property {StoreRuleConditionSchema} [conditions]
807
+ * @property {boolean} [is_active]
896
808
  */
897
809
 
898
810
  /**
@@ -902,205 +814,326 @@ const Joi = require("joi");
902
814
  */
903
815
 
904
816
  /**
905
- * @typedef StoreRuleConditionSchema
906
- * @property {IntComparisonOperations} [brand_ids]
907
- * @property {IntComparisonOperations} [category_ids]
908
- * @property {CustomerRadiusSchema} [customer_radius]
909
- * @property {IntComparisonOperations} [department_ids]
910
- * @property {ArithmeticOperations} [order_place_date]
911
- * @property {IntComparisonOperations} [product_ids]
912
- * @property {StringComparisonOperations} [product_tags]
913
- * @property {StringComparisonOperations} [store_tags]
914
- * @property {StringComparisonOperations} [store_type]
915
- * @property {LocationRule} [to_location]
916
- * @property {StringComparisonOperations} [zone_ids]
917
- */
918
-
919
- /**
920
- * @typedef StoreRuleConfigData
921
- * @property {string[]} [rule_ids]
922
- * @property {string[]} [sort]
923
- * @property {StorePrioritySchema[]} [store_priority]
924
- * @property {string[]} [tag_based_priority]
925
- * @property {string[]} [type_based_priority]
817
+ * @typedef GetStoreRulesApiResponse
818
+ * @property {StoreRuleDataSchema[]} [items]
819
+ * @property {Page} [page]
926
820
  */
927
821
 
928
822
  /**
929
- * @typedef StoreRuleDataSchema
930
- * @property {string} [application_id]
931
- * @property {number} [company_id]
932
- * @property {StoreRuleConditionSchema} [conditions]
933
- * @property {string} [id]
934
- * @property {boolean} [is_active]
823
+ * @typedef CreateStoreRuleRequestSchema
935
824
  * @property {string} [name]
936
- * @property {string[]} [sort]
937
- * @property {StorePrioritySchema[]} [store_priority]
938
- * @property {string[]} [tag_based_priority]
825
+ * @property {boolean} [is_active]
826
+ * @property {StoreRuleConditionSchema} [conditions]
939
827
  * @property {string[]} [type_based_priority]
828
+ * @property {string[]} [tag_based_priority]
829
+ * @property {StorePrioritySchema[]} [store_priority]
830
+ * @property {string[]} [sort]
940
831
  */
941
832
 
942
833
  /**
943
834
  * @typedef StoreRuleResponseSchema
944
- * @property {StoreRuleConditionSchema} [conditions]
945
835
  * @property {string} [id]
946
- * @property {boolean} [is_active]
947
836
  * @property {string} [name]
948
- * @property {string[]} [sort]
949
- * @property {StorePrioritySchema[]} [store_priority]
950
- * @property {string[]} [tag_based_priority]
951
837
  * @property {string} [type]
952
838
  * @property {string[]} [type_based_priority]
839
+ * @property {string[]} [tag_based_priority]
840
+ * @property {StorePrioritySchema[]} [store_priority]
841
+ * @property {string[]} [sort]
842
+ * @property {StoreRuleConditionSchema} [conditions]
843
+ * @property {boolean} [is_active]
953
844
  */
954
845
 
955
846
  /**
956
847
  * @typedef StoreRuleUpdateResponseSchema
957
- * @property {string} [application_id]
958
- * @property {number} [company_id]
959
- * @property {StoreRuleConditionSchema} [conditions]
960
848
  * @property {string} [id]
961
- * @property {boolean} [is_active]
962
849
  * @property {string} [name]
963
- * @property {string[]} [sort]
964
- * @property {StorePrioritySchema[]} [store_priority]
965
- * @property {string[]} [tag_based_priority]
966
850
  * @property {string} [type]
967
851
  * @property {string[]} [type_based_priority]
852
+ * @property {string[]} [tag_based_priority]
853
+ * @property {StorePrioritySchema[]} [store_priority]
854
+ * @property {string[]} [sort]
855
+ * @property {StoreRuleConditionSchema} [conditions]
856
+ * @property {boolean} [is_active]
857
+ * @property {number} [company_id]
858
+ * @property {string} [application_id]
968
859
  */
969
860
 
970
861
  /**
971
- * @typedef StringComparisonOperations
972
- * @property {string[]} [includes]
862
+ * @typedef ServiceabilityModel
863
+ * @property {number} lm_cod_limit
864
+ * @property {boolean} is_qc
865
+ * @property {string} pickup_cutoff
866
+ * @property {string} route_code
867
+ * @property {boolean} is_first_mile
868
+ * @property {boolean} is_return
869
+ * @property {boolean} is_installation
870
+ * @property {boolean} is_last_mile
973
871
  */
974
872
 
975
873
  /**
976
- * @typedef TimmingResponse
977
- * @property {OpeningClosing} [closing]
978
- * @property {boolean} [open]
979
- * @property {OpeningClosing} [opening]
980
- * @property {string} [weekday]
874
+ * @typedef CourierPartnerSchemeFeatures
875
+ * @property {boolean} [doorstep_qc]
876
+ * @property {boolean} [qr]
877
+ * @property {boolean} [mps]
878
+ * @property {boolean} [ndr]
879
+ * @property {number} [ndr_attempts]
880
+ * @property {boolean} [dangerous_goods]
881
+ * @property {boolean} [fragile_goods]
882
+ * @property {boolean} [restricted_goods]
883
+ * @property {boolean} [cold_storage_goods]
884
+ * @property {boolean} [doorstep_exchange]
885
+ * @property {boolean} [doorstep_return]
886
+ * @property {boolean} [product_installation]
887
+ * @property {boolean} [openbox_delivery]
888
+ * @property {string} [status_updates]
889
+ * @property {boolean} [multi_pick_single_drop]
890
+ * @property {boolean} [single_pick_multi_drop]
891
+ * @property {boolean} [multi_pick_multi_drop]
892
+ * @property {boolean} [ewaybill]
981
893
  */
982
894
 
983
895
  /**
984
- * @typedef UpdateZoneConfigRequest
985
- * @property {string} [serviceability_type]
896
+ * @typedef CourierPartnerSchemeModel
897
+ * @property {string} extension_id
898
+ * @property {string} scheme_id
899
+ * @property {ArithmeticOperations} weight
900
+ * @property {string} transport_type
901
+ * @property {string} region
902
+ * @property {string} delivery_type
903
+ * @property {string[]} payment_mode
904
+ * @property {string} stage
905
+ * @property {CourierPartnerSchemeFeatures} feature
986
906
  */
987
907
 
988
908
  /**
989
- * @typedef UpdateZoneData
990
- * @property {string} [assignment_preference]
991
- * @property {GetZoneDataViewChannels[]} channels
992
- * @property {number} company_id
993
- * @property {boolean} is_active
994
- * @property {ZoneMappingType[]} mapping
995
- * @property {string} name
996
- * @property {ZoneProductTypes} product
997
- * @property {string} region_type
998
- * @property {string} slug
999
- * @property {number[]} store_ids
1000
- * @property {string} zone_id
909
+ * @typedef CourierAccountResponse
910
+ * @property {string} account_id
911
+ * @property {string} scheme_id
912
+ * @property {boolean} is_self_ship
913
+ * @property {string} stage
914
+ * @property {boolean} is_own_account
915
+ * @property {CourierPartnerSchemeModel} scheme_rules
1001
916
  */
1002
917
 
1003
918
  /**
1004
- * @typedef WarningsResponse
1005
- * @property {string} [store_address]
919
+ * @typedef CompanyCourierPartnerAccountListResponse
920
+ * @property {CourierAccountResponse[]} items
921
+ * @property {Page} page
1006
922
  */
1007
923
 
1008
924
  /**
1009
- * @typedef Zone
1010
- * @property {string} assignment_preference
1011
- * @property {boolean} is_active
925
+ * @typedef PackageMaterial
1012
926
  * @property {string} name
1013
- * @property {string} slug
927
+ * @property {number} width
928
+ * @property {number} height
929
+ * @property {number} length
930
+ * @property {PackageMaterialRule[]} [rules]
1014
931
  * @property {number[]} store_ids
1015
- * @property {string[]} tags
1016
- * @property {string} type
1017
- * @property {string} zone_id
932
+ * @property {number} weight
933
+ * @property {number} error_rate
934
+ * @property {string} package_type
935
+ * @property {string} size
936
+ * @property {string[]} [media]
937
+ * @property {Channel[]} channels
938
+ * @property {boolean} [track_inventory]
939
+ * @property {string} status
940
+ * @property {number} [max_weight]
941
+ * @property {number} [package_vol_weight]
942
+ * @property {boolean} [auto_calculate]
1018
943
  */
1019
944
 
1020
945
  /**
1021
- * @typedef ZoneConfig
1022
- * @property {string} [serviceability_type]
946
+ * @typedef PackageMaterialResponse
947
+ * @property {string} name
948
+ * @property {string} [id]
949
+ * @property {number} [item_id]
950
+ * @property {number} width
951
+ * @property {number} height
952
+ * @property {number} length
953
+ * @property {PackageMaterialRule[]} [rules]
954
+ * @property {number[]} store_ids
955
+ * @property {number} weight
956
+ * @property {number} error_rate
957
+ * @property {string} package_type
958
+ * @property {string} size
959
+ * @property {string[]} [media]
960
+ * @property {Channel[]} channels
961
+ * @property {boolean} [track_inventory]
962
+ * @property {string} status
963
+ * @property {number} [max_weight]
964
+ * @property {number} [package_vol_weight]
965
+ * @property {boolean} [auto_calculate]
1023
966
  */
1024
967
 
1025
968
  /**
1026
- * @typedef ZoneDataItem
1027
- * @property {number} current
1028
- * @property {boolean} has_next
1029
- * @property {number} item_total
1030
- * @property {number} size
1031
- * @property {string} type
969
+ * @typedef PackageMaterialRule
970
+ * @property {string} [rule_id]
971
+ * @property {PackageMaterialRuleQuantity} [quantity]
972
+ * @property {number} [weight]
1032
973
  */
1033
974
 
1034
975
  /**
1035
- * @typedef ZoneMappingType
1036
- * @property {string} country
1037
- * @property {string[]} [pincode]
1038
- * @property {string[]} [state]
976
+ * @typedef PackageRule
977
+ * @property {string} name
978
+ * @property {number} company_id
979
+ * @property {string} type
980
+ * @property {boolean} [is_active]
981
+ * @property {PackageRuleProductTag} [product_tag]
982
+ * @property {PackageRuleProduct} [product_id]
983
+ * @property {PackageRuleCategory} [category_id]
1039
984
  */
1040
985
 
1041
986
  /**
1042
- * @typedef ZoneProductTypes
1043
- * @property {string[]} tags
987
+ * @typedef PackageRuleResponse
988
+ * @property {string} [id]
989
+ * @property {string} name
990
+ * @property {number} company_id
1044
991
  * @property {string} type
992
+ * @property {boolean} [is_active]
993
+ * @property {PackageRuleProductTag} [product_tag]
994
+ * @property {PackageRuleProduct} [product_id]
995
+ * @property {PackageRuleCategory} [category_id]
1045
996
  */
1046
997
 
1047
998
  /**
1048
- * @typedef ZoneResponse
1049
- * @property {number} status_code
1050
- * @property {boolean} success
1051
- * @property {string} zone_id
999
+ * @typedef Channel
1000
+ * @property {string} [type]
1001
+ * @property {string} [id]
1052
1002
  */
1053
1003
 
1054
1004
  /**
1055
- * @typedef ZoneSuccessResponse
1056
- * @property {number} status_code
1057
- * @property {boolean} success
1005
+ * @typedef PackageMaterialRuleList
1006
+ * @property {PackageRuleResponse} [items]
1007
+ * @property {Page} [page]
1058
1008
  */
1059
1009
 
1060
1010
  /**
1061
- * @typedef ZoneUpdateRequest
1062
- * @property {UpdateZoneData} data
1063
- * @property {string} identifier
1011
+ * @typedef PackageMaterialList
1012
+ * @property {PackageMaterialResponse} [items]
1013
+ * @property {Page} [page]
1064
1014
  */
1065
1015
 
1066
- class ServiceabilityPlatformModel {
1067
- /** @returns {AddressResponse} */
1068
- static AddressResponse() {
1069
- return Joi.object({
1070
- address1: Joi.string().allow(""),
1071
- address2: Joi.string().allow(""),
1072
- city: Joi.string().allow(""),
1073
- country: Joi.string().allow(""),
1074
- landmark: Joi.string().allow(""),
1075
- latitude: Joi.number(),
1076
- longitude: Joi.number(),
1077
- pincode: Joi.number(),
1078
- state: Joi.string().allow(""),
1079
- });
1080
- }
1016
+ /**
1017
+ * @typedef PackageRuleProduct
1018
+ * @property {number[]} [includes]
1019
+ */
1081
1020
 
1082
- /** @returns {ApplicationConfig} */
1083
- static ApplicationConfig() {
1084
- return Joi.object({
1085
- rule_ids: Joi.array().items(Joi.string().allow("")),
1086
- sort: Joi.array().items(Joi.string().allow("")),
1087
- zones: ServiceabilityPlatformModel.ZoneConfig(),
1088
- });
1089
- }
1021
+ /**
1022
+ * @typedef PackageRuleProductTag
1023
+ * @property {string[]} [includes]
1024
+ */
1090
1025
 
1091
- /** @returns {ApplicationSelfShipConfig} */
1092
- static ApplicationSelfShipConfig() {
1026
+ /**
1027
+ * @typedef PackageRuleCategory
1028
+ * @property {number[]} [includes]
1029
+ */
1030
+
1031
+ /**
1032
+ * @typedef PackageMaterialRuleQuantity
1033
+ * @property {number} [min]
1034
+ * @property {number} [max]
1035
+ */
1036
+
1037
+ /**
1038
+ * @typedef RulePriorityRequest
1039
+ * @property {string} rule_id
1040
+ * @property {number} priority
1041
+ */
1042
+
1043
+ /**
1044
+ * @typedef RulePriorityResponse
1045
+ * @property {boolean} [success]
1046
+ */
1047
+
1048
+ /**
1049
+ * @typedef ArticleAssignment
1050
+ * @property {string} [level]
1051
+ * @property {string} [strategy] - The strategy parameter allows users to
1052
+ * specify the desired approach or criteria for selecting optimal locations.
1053
+ */
1054
+
1055
+ /**
1056
+ * @typedef ServiceabilityLocation
1057
+ * @property {string} longitude - The longitude of the serviceability location.
1058
+ * @property {string} latitude - The latitude of the serviceability location.
1059
+ */
1060
+
1061
+ /**
1062
+ * @typedef LocationDetailsServiceability
1063
+ * @property {string} [pincode] - The pincode of the serviceability location.
1064
+ * @property {string} [sector] - The sector of the serviceability location.
1065
+ * @property {string} [state] - The state of the serviceability location.
1066
+ * @property {string} country - The country of the serviceability location.
1067
+ * @property {string} [city] - The city of the serviceability location.
1068
+ * @property {string} country_iso_code - The ISO code of the country.
1069
+ * @property {ServiceabilityLocation} [location]
1070
+ */
1071
+
1072
+ /**
1073
+ * @typedef OptimalLocationsArticles
1074
+ * @property {number} item_id
1075
+ * @property {string} size
1076
+ * @property {string} quantity
1077
+ * @property {string} [group_id]
1078
+ * @property {boolean} [is_primary_item]
1079
+ * @property {Object} [meta]
1080
+ * @property {ArticleAssignment} article_assignment
1081
+ * @property {number[]} ignore_locations
1082
+ * @property {number[]} assign_locations
1083
+ * @property {number} [seller_id]
1084
+ */
1085
+
1086
+ /**
1087
+ * @typedef OptimlLocationsRequestSchema
1088
+ * @property {string} channel_id
1089
+ * @property {string} channel_type
1090
+ * @property {LocationDetailsServiceability} to_serviceability
1091
+ * @property {OptimalLocationsArticles} [article]
1092
+ */
1093
+
1094
+ /**
1095
+ * @typedef OptimalLocationArticlesResponse
1096
+ * @property {number} item_id
1097
+ * @property {string} size
1098
+ * @property {number} quantity
1099
+ * @property {string} [group_id]
1100
+ * @property {boolean} [is_primary_item]
1101
+ * @property {Object} [meta]
1102
+ * @property {ArticleAssignment} article_assignment
1103
+ * @property {number} [seller_id]
1104
+ * @property {number[]} ignore_locations
1105
+ * @property {number[]} assign_locations
1106
+ * @property {number} price_effective
1107
+ * @property {number} mto_quantity
1108
+ * @property {string} _id
1109
+ * @property {string} uid
1110
+ */
1111
+
1112
+ /**
1113
+ * @typedef OptimalLocationAssignedStoresResponse
1114
+ * @property {number} store_id
1115
+ * @property {OptimalLocationArticlesResponse[]} articles
1116
+ */
1117
+
1118
+ /**
1119
+ * @typedef OptimalLocationsResponse
1120
+ * @property {OptimalLocationAssignedStoresResponse[]} assigned_stores
1121
+ */
1122
+
1123
+ class ServiceabilityPlatformModel {
1124
+ /** @returns {UpdateZoneConfigRequest} */
1125
+ static UpdateZoneConfigRequest() {
1093
1126
  return Joi.object({
1094
- self_ship: Joi.any().allow(null),
1127
+ serviceability_type: Joi.string().allow(""),
1095
1128
  });
1096
1129
  }
1097
1130
 
1098
- /** @returns {ApplicationSelfShipConfigResponse} */
1099
- static ApplicationSelfShipConfigResponse() {
1131
+ /** @returns {ServiceabilityErrorResponse} */
1132
+ static ServiceabilityErrorResponse() {
1100
1133
  return Joi.object({
1101
- data: ServiceabilityPlatformModel.ApplicationSelfShipConfig(),
1102
- error: ServiceabilityPlatformModel.ServiceabilityErrorResponse(),
1103
- success: Joi.boolean().required(),
1134
+ message: Joi.string().allow("").required(),
1135
+ value: Joi.string().allow("").required(),
1136
+ type: Joi.string().allow("").required(),
1104
1137
  });
1105
1138
  }
1106
1139
 
@@ -1108,1350 +1141,1446 @@ class ServiceabilityPlatformModel {
1108
1141
  static ApplicationServiceabilityConfig() {
1109
1142
  return Joi.object({
1110
1143
  channel_id: Joi.string().allow("").required(),
1111
- channel_type: Joi.string().allow("").required(),
1112
1144
  serviceability_type: Joi.string().allow("").required(),
1145
+ channel_type: Joi.string().allow("").required(),
1113
1146
  });
1114
1147
  }
1115
1148
 
1116
1149
  /** @returns {ApplicationServiceabilityConfigResponse} */
1117
1150
  static ApplicationServiceabilityConfigResponse() {
1118
1151
  return Joi.object({
1119
- data: ServiceabilityPlatformModel.ApplicationServiceabilityConfig(),
1120
1152
  error: ServiceabilityPlatformModel.ServiceabilityErrorResponse(),
1153
+ data: ServiceabilityPlatformModel.ApplicationServiceabilityConfig(),
1121
1154
  success: Joi.boolean().required(),
1122
1155
  });
1123
1156
  }
1124
1157
 
1125
- /** @returns {ArithmeticOperations} */
1126
- static ArithmeticOperations() {
1158
+ /** @returns {EntityRegionView_Request} */
1159
+ static EntityRegionView_Request() {
1127
1160
  return Joi.object({
1128
- gt: Joi.number(),
1129
- gte: Joi.number(),
1130
- lt: Joi.number(),
1131
- lte: Joi.number(),
1161
+ sub_type: Joi.array().items(Joi.string().allow("")).required(),
1162
+ parent_id: Joi.array().items(Joi.string().allow("")),
1132
1163
  });
1133
1164
  }
1134
1165
 
1135
- /** @returns {BulkRegionJobSerializer} */
1136
- static BulkRegionJobSerializer() {
1166
+ /** @returns {EntityRegionView_Error} */
1167
+ static EntityRegionView_Error() {
1137
1168
  return Joi.object({
1138
- action: Joi.string().allow("").required(),
1139
- country: Joi.string().allow("").required(),
1140
- file_path: Joi.string().allow(""),
1141
- region: Joi.string().allow("").required(),
1169
+ message: Joi.string().allow(""),
1170
+ value: Joi.string().allow(""),
1171
+ type: Joi.string().allow(""),
1142
1172
  });
1143
1173
  }
1144
1174
 
1145
- /** @returns {BulkRegionResponse} */
1146
- static BulkRegionResponse() {
1175
+ /** @returns {EntityRegionView_page} */
1176
+ static EntityRegionView_page() {
1177
+ return Joi.object({
1178
+ type: Joi.string().allow("").required(),
1179
+ has_next: Joi.boolean().required(),
1180
+ item_total: Joi.number().required(),
1181
+ size: Joi.number().required(),
1182
+ current: Joi.number().required(),
1183
+ });
1184
+ }
1185
+
1186
+ /** @returns {getAppRegionZonesResponse} */
1187
+ static getAppRegionZonesResponse() {
1147
1188
  return Joi.object({
1189
+ page: Joi.array()
1190
+ .items(ServiceabilityPlatformModel.PageSchema())
1191
+ .required(),
1148
1192
  items: Joi.array()
1149
- .items(ServiceabilityPlatformModel.BulkRegionResponseItemData())
1193
+ .items(ServiceabilityPlatformModel.ListViewItems())
1150
1194
  .required(),
1151
- page: ServiceabilityPlatformModel.Page().required(),
1152
1195
  });
1153
1196
  }
1154
1197
 
1155
- /** @returns {BulkRegionResponseItemData} */
1156
- static BulkRegionResponseItemData() {
1198
+ /** @returns {PageSchema} */
1199
+ static PageSchema() {
1157
1200
  return Joi.object({
1158
- action: Joi.string().allow("").required(),
1159
- batch_id: Joi.string().allow("").required(),
1160
- country: Joi.string().allow("").required(),
1161
- error_file_path: Joi.string().allow(""),
1162
- failed: Joi.number(),
1163
- failed_records: Joi.array().items(Joi.any()),
1164
- file_path: Joi.string().allow("").required(),
1165
- region: Joi.string().allow("").required(),
1166
- status: Joi.string().allow("").required(),
1167
- success: Joi.number(),
1168
- total: Joi.number(),
1201
+ has_next: Joi.boolean().required(),
1202
+ item_total: Joi.number().required(),
1203
+ size: Joi.number().required(),
1204
+ current: Joi.number().required(),
1205
+ type: Joi.string().allow("").required(),
1169
1206
  });
1170
1207
  }
1171
1208
 
1172
- /** @returns {Channel} */
1173
- static Channel() {
1209
+ /** @returns {EntityRegionView_Items} */
1210
+ static EntityRegionView_Items() {
1174
1211
  return Joi.object({
1175
- id: Joi.string().allow(""),
1176
- type: Joi.string().allow(""),
1212
+ sub_type: Joi.string().allow("").required(),
1213
+ uid: Joi.string().allow("").required(),
1214
+ name: Joi.string().allow("").required(),
1177
1215
  });
1178
1216
  }
1179
1217
 
1180
- /** @returns {CommonError} */
1181
- static CommonError() {
1218
+ /** @returns {EntityRegionView_Response} */
1219
+ static EntityRegionView_Response() {
1182
1220
  return Joi.object({
1183
- error: Joi.any(),
1184
- status_code: Joi.string().allow(""),
1185
- success: Joi.string().allow(""),
1221
+ error: ServiceabilityPlatformModel.EntityRegionView_Error().required(),
1222
+ page: ServiceabilityPlatformModel.EntityRegionView_page().required(),
1223
+ data: Joi.array()
1224
+ .items(ServiceabilityPlatformModel.EntityRegionView_Items())
1225
+ .required(),
1226
+ success: Joi.boolean().required(),
1186
1227
  });
1187
1228
  }
1188
1229
 
1189
- /** @returns {CompanyConfig} */
1190
- static CompanyConfig() {
1230
+ /** @returns {ListViewSummary} */
1231
+ static ListViewSummary() {
1191
1232
  return Joi.object({
1192
- logistics_as_actual: Joi.boolean(),
1193
- rule_ids: Joi.array().items(Joi.string().allow("")).required(),
1194
- sort: Joi.array().items(Joi.string().allow("")).required(),
1233
+ total_zones: Joi.number().required(),
1234
+ total_pincodes_served: Joi.number().required(),
1235
+ total_active_zones: Joi.number().required(),
1195
1236
  });
1196
1237
  }
1197
1238
 
1198
- /** @returns {CompanyCourierPartnerAccountListResponse} */
1199
- static CompanyCourierPartnerAccountListResponse() {
1239
+ /** @returns {ZoneDataItem} */
1240
+ static ZoneDataItem() {
1241
+ return Joi.object({
1242
+ has_next: Joi.boolean().required(),
1243
+ item_total: Joi.number().required(),
1244
+ size: Joi.number().required(),
1245
+ current: Joi.number().required(),
1246
+ type: Joi.string().allow("").required(),
1247
+ });
1248
+ }
1249
+
1250
+ /** @returns {ListViewProduct} */
1251
+ static ListViewProduct() {
1252
+ return Joi.object({
1253
+ count: Joi.number().required(),
1254
+ type: Joi.string().allow("").required(),
1255
+ });
1256
+ }
1257
+
1258
+ /** @returns {ListViewChannels} */
1259
+ static ListViewChannels() {
1260
+ return Joi.object({
1261
+ channel_id: Joi.string().allow("").required(),
1262
+ channel_type: Joi.string().allow("").required(),
1263
+ });
1264
+ }
1265
+
1266
+ /** @returns {ListViewItems} */
1267
+ static ListViewItems() {
1268
+ return Joi.object({
1269
+ zone_id: Joi.string().allow("").required(),
1270
+ name: Joi.string().allow("").required(),
1271
+ slug: Joi.string().allow("").required(),
1272
+ stores_count: Joi.number().required(),
1273
+ is_active: Joi.boolean().required(),
1274
+ regions_count: Joi.number().required(),
1275
+ company_id: Joi.number().required(),
1276
+ channels: Joi.array()
1277
+ .items(ServiceabilityPlatformModel.ListViewChannels())
1278
+ .required(),
1279
+ });
1280
+ }
1281
+
1282
+ /** @returns {ListViewResponse} */
1283
+ static ListViewResponse() {
1200
1284
  return Joi.object({
1285
+ page: ServiceabilityPlatformModel.ZoneDataItem().required(),
1201
1286
  items: Joi.array()
1202
- .items(ServiceabilityPlatformModel.CourierAccountResponse())
1287
+ .items(ServiceabilityPlatformModel.ListViewItems())
1203
1288
  .required(),
1204
- page: ServiceabilityPlatformModel.Page().required(),
1205
1289
  });
1206
1290
  }
1207
1291
 
1208
1292
  /** @returns {CompanyStoreView_PageItems} */
1209
1293
  static CompanyStoreView_PageItems() {
1210
1294
  return Joi.object({
1211
- current: Joi.number().required(),
1295
+ type: Joi.string().allow("").required(),
1212
1296
  has_next: Joi.boolean().required(),
1213
1297
  item_total: Joi.number().required(),
1214
1298
  size: Joi.number().required(),
1215
- type: Joi.string().allow("").required(),
1299
+ current: Joi.number().required(),
1216
1300
  });
1217
1301
  }
1218
1302
 
1219
1303
  /** @returns {CompanyStoreView_Response} */
1220
1304
  static CompanyStoreView_Response() {
1221
1305
  return Joi.object({
1222
- items: Joi.array().items(Joi.any()),
1223
1306
  page: Joi.array()
1224
1307
  .items(ServiceabilityPlatformModel.CompanyStoreView_PageItems())
1225
1308
  .required(),
1309
+ items: Joi.array().items(Joi.any()),
1226
1310
  });
1227
1311
  }
1228
1312
 
1229
- /** @returns {ContactNumberResponse} */
1230
- static ContactNumberResponse() {
1313
+ /** @returns {GetZoneDataViewChannels} */
1314
+ static GetZoneDataViewChannels() {
1231
1315
  return Joi.object({
1232
- country_code: Joi.number(),
1233
- number: Joi.string().allow(""),
1316
+ channel_id: Joi.string().allow("").required(),
1317
+ channel_type: Joi.string().allow("").required(),
1234
1318
  });
1235
1319
  }
1236
1320
 
1237
- /** @returns {CourierAccount} */
1238
- static CourierAccount() {
1321
+ /** @returns {ZoneProductTypes} */
1322
+ static ZoneProductTypes() {
1239
1323
  return Joi.object({
1240
- account_id: Joi.string().allow("").required(),
1241
- extension_id: Joi.string().allow("").required(),
1242
- is_own_account: Joi.boolean().required(),
1243
- is_self_ship: Joi.boolean().required(),
1244
- scheme_id: Joi.string().allow("").required(),
1245
- stage: Joi.string().allow("").required(),
1324
+ type: Joi.string().allow("").required(),
1325
+ tags: Joi.array().items(Joi.string().allow("")).required(),
1246
1326
  });
1247
1327
  }
1248
1328
 
1249
- /** @returns {CourierAccountResponse} */
1250
- static CourierAccountResponse() {
1329
+ /** @returns {ZoneMappingType} */
1330
+ static ZoneMappingType() {
1251
1331
  return Joi.object({
1252
- account_id: Joi.string().allow("").required(),
1253
- is_own_account: Joi.boolean().required(),
1254
- is_self_ship: Joi.boolean().required(),
1255
- scheme_id: Joi.string().allow("").required(),
1256
- scheme_rules: ServiceabilityPlatformModel.CourierPartnerSchemeModel().required(),
1257
- stage: Joi.string().allow("").required(),
1332
+ country: Joi.string().allow("").required(),
1333
+ pincode: Joi.array().items(Joi.string().allow("")),
1334
+ state: Joi.array().items(Joi.string().allow("")),
1258
1335
  });
1259
1336
  }
1260
1337
 
1261
- /** @returns {CourierPartnerAccountFailureResponse} */
1262
- static CourierPartnerAccountFailureResponse() {
1338
+ /** @returns {UpdateZoneData} */
1339
+ static UpdateZoneData() {
1263
1340
  return Joi.object({
1264
- error: Joi.array()
1265
- .items(ServiceabilityPlatformModel.ErrorResponse())
1341
+ zone_id: Joi.string().allow("").required(),
1342
+ name: Joi.string().allow("").required(),
1343
+ slug: Joi.string().allow("").required(),
1344
+ company_id: Joi.number().required(),
1345
+ is_active: Joi.boolean().required(),
1346
+ channels: Joi.array()
1347
+ .items(ServiceabilityPlatformModel.GetZoneDataViewChannels())
1266
1348
  .required(),
1267
- success: Joi.boolean().required(),
1349
+ product: ServiceabilityPlatformModel.ZoneProductTypes().required(),
1350
+ store_ids: Joi.array().items(Joi.number()).required(),
1351
+ region_type: Joi.string().allow("").required(),
1352
+ mapping: Joi.array()
1353
+ .items(ServiceabilityPlatformModel.ZoneMappingType())
1354
+ .required(),
1355
+ assignment_preference: Joi.string().allow(""),
1268
1356
  });
1269
1357
  }
1270
1358
 
1271
- /** @returns {CourierPartnerList} */
1272
- static CourierPartnerList() {
1359
+ /** @returns {ZoneUpdateRequest} */
1360
+ static ZoneUpdateRequest() {
1273
1361
  return Joi.object({
1274
- account_id: Joi.string().allow("").required(),
1275
- extension_id: Joi.string().allow("").required(),
1276
- is_self_ship: Joi.boolean().required(),
1277
- name: Joi.string().allow("").required(),
1362
+ identifier: Joi.string().allow("").required(),
1363
+ data: ServiceabilityPlatformModel.UpdateZoneData().required(),
1278
1364
  });
1279
1365
  }
1280
1366
 
1281
- /** @returns {CourierPartnerRule} */
1282
- static CourierPartnerRule() {
1367
+ /** @returns {ZoneSuccessResponse} */
1368
+ static ZoneSuccessResponse() {
1283
1369
  return Joi.object({
1284
- conditions: ServiceabilityPlatformModel.CourierPartnerRuleConditions().required(),
1285
- cp_list: Joi.array().items(
1286
- ServiceabilityPlatformModel.CourierPartnerList()
1287
- ),
1288
- is_active: Joi.boolean().required(),
1289
- name: Joi.string().allow("").required(),
1290
- sort: Joi.array().items(Joi.string().allow("")).required(),
1370
+ status_code: Joi.number().required(),
1371
+ success: Joi.boolean().required(),
1291
1372
  });
1292
1373
  }
1293
1374
 
1294
- /** @returns {CourierPartnerRuleConditions} */
1295
- static CourierPartnerRuleConditions() {
1375
+ /** @returns {GetZoneDataViewItems} */
1376
+ static GetZoneDataViewItems() {
1296
1377
  return Joi.object({
1297
- brand_ids: ServiceabilityPlatformModel.IntComparisonOperations(),
1298
- category_ids: ServiceabilityPlatformModel.IntComparisonOperations(),
1299
- department_ids: ServiceabilityPlatformModel.IntComparisonOperations(),
1300
- forward: ServiceabilityPlatformModel.LocationRule(),
1301
- order_place_date: ServiceabilityPlatformModel.ArithmeticOperations(),
1302
- payment_mode: ServiceabilityPlatformModel.StringComparisonOperations(),
1303
- product_ids: ServiceabilityPlatformModel.IntComparisonOperations(),
1304
- product_tags: ServiceabilityPlatformModel.StringComparisonOperations(),
1305
- reverse: ServiceabilityPlatformModel.LocationRule(),
1306
- shipment_cost: ServiceabilityPlatformModel.ArithmeticOperations(),
1307
- shipment_volumetric_weight: ServiceabilityPlatformModel.ArithmeticOperations(),
1308
- shipment_weight: ServiceabilityPlatformModel.ArithmeticOperations(),
1309
- store_ids: ServiceabilityPlatformModel.IntComparisonOperations(),
1310
- store_tags: ServiceabilityPlatformModel.StringComparisonOperations(),
1311
- store_type: ServiceabilityPlatformModel.StringComparisonOperations(),
1312
- zone_ids: ServiceabilityPlatformModel.StringComparisonOperations(),
1378
+ zone_id: Joi.string().allow("").required(),
1379
+ name: Joi.string().allow("").required(),
1380
+ slug: Joi.string().allow("").required(),
1381
+ company_id: Joi.number(),
1382
+ is_active: Joi.boolean().required(),
1383
+ channels: Joi.array()
1384
+ .items(ServiceabilityPlatformModel.GetZoneDataViewChannels())
1385
+ .required(),
1386
+ product: ServiceabilityPlatformModel.ZoneProductTypes().required(),
1387
+ store_ids: Joi.array().items(Joi.number()).required(),
1388
+ region_type: Joi.string().allow(""),
1389
+ mapping: Joi.array()
1390
+ .items(ServiceabilityPlatformModel.ZoneMappingType())
1391
+ .required(),
1392
+ assignment_preference: Joi.string().allow(""),
1393
+ stores_count: Joi.number().required(),
1313
1394
  });
1314
1395
  }
1315
1396
 
1316
- /** @returns {CourierPartnerRulesListResponse} */
1317
- static CourierPartnerRulesListResponse() {
1397
+ /** @returns {GetSingleZoneDataViewResponse} */
1398
+ static GetSingleZoneDataViewResponse() {
1318
1399
  return Joi.object({
1319
- items: Joi.array()
1320
- .items(ServiceabilityPlatformModel.CourierPartnerRule())
1321
- .required(),
1322
- page: ServiceabilityPlatformModel.Page().required(),
1400
+ data: ServiceabilityPlatformModel.GetZoneDataViewItems().required(),
1323
1401
  });
1324
1402
  }
1325
1403
 
1326
- /** @returns {CourierPartnerSchemeFeatures} */
1327
- static CourierPartnerSchemeFeatures() {
1404
+ /** @returns {GetZoneByIdSchema} */
1405
+ static GetZoneByIdSchema() {
1328
1406
  return Joi.object({
1329
- cold_storage_goods: Joi.boolean(),
1330
- dangerous_goods: Joi.boolean(),
1331
- doorstep_exchange: Joi.boolean(),
1332
- doorstep_qc: Joi.boolean(),
1333
- doorstep_return: Joi.boolean(),
1334
- ewaybill: Joi.boolean(),
1335
- fragile_goods: Joi.boolean(),
1336
- mps: Joi.boolean(),
1337
- multi_pick_multi_drop: Joi.boolean(),
1338
- multi_pick_single_drop: Joi.boolean(),
1339
- ndr: Joi.boolean(),
1340
- ndr_attempts: Joi.number(),
1341
- openbox_delivery: Joi.boolean(),
1342
- product_installation: Joi.boolean(),
1343
- qr: Joi.boolean(),
1344
- restricted_goods: Joi.boolean(),
1345
- single_pick_multi_drop: Joi.boolean(),
1346
- status_updates: Joi.string().allow(""),
1407
+ zone_id: Joi.string().allow("").required(),
1408
+ name: Joi.string().allow("").required(),
1409
+ slug: Joi.string().allow("").required(),
1410
+ company_id: Joi.number(),
1411
+ is_active: Joi.boolean().required(),
1412
+ channels: Joi.array()
1413
+ .items(ServiceabilityPlatformModel.GetZoneDataViewChannels())
1414
+ .required(),
1415
+ product: ServiceabilityPlatformModel.ZoneProductTypes().required(),
1416
+ store_ids: Joi.array().items(Joi.number()).required(),
1417
+ region_type: Joi.string().allow("").required(),
1418
+ mapping: Joi.array()
1419
+ .items(ServiceabilityPlatformModel.ZoneMappingType())
1420
+ .required(),
1421
+ assignment_preference: Joi.string().allow(""),
1422
+ stores_count: Joi.number().required(),
1347
1423
  });
1348
1424
  }
1349
1425
 
1350
- /** @returns {CourierPartnerSchemeModel} */
1351
- static CourierPartnerSchemeModel() {
1426
+ /** @returns {CreateZoneData} */
1427
+ static CreateZoneData() {
1352
1428
  return Joi.object({
1353
- delivery_type: Joi.string().allow("").required(),
1354
- extension_id: Joi.string().allow("").required(),
1355
- feature: ServiceabilityPlatformModel.CourierPartnerSchemeFeatures().required(),
1356
- payment_mode: Joi.array().items(Joi.string().allow("")).required(),
1357
- region: Joi.string().allow("").required(),
1358
- scheme_id: Joi.string().allow("").required(),
1359
- stage: Joi.string().allow("").required(),
1360
- transport_type: Joi.string().allow("").required(),
1361
- weight: ServiceabilityPlatformModel.ArithmeticOperations().required(),
1429
+ name: Joi.string().allow("").required(),
1430
+ slug: Joi.string().allow("").required(),
1431
+ company_id: Joi.number().required(),
1432
+ is_active: Joi.boolean().required(),
1433
+ channels: Joi.array()
1434
+ .items(ServiceabilityPlatformModel.GetZoneDataViewChannels())
1435
+ .required(),
1436
+ store_ids: Joi.array().items(Joi.number()).required(),
1437
+ region_type: Joi.string().allow("").required(),
1438
+ mapping: Joi.array()
1439
+ .items(ServiceabilityPlatformModel.ZoneMappingType())
1440
+ .required(),
1441
+ assignment_preference: Joi.string().allow(""),
1362
1442
  });
1363
1443
  }
1364
1444
 
1365
- /** @returns {CreatedByResponse} */
1366
- static CreatedByResponse() {
1445
+ /** @returns {ZoneResponse} */
1446
+ static ZoneResponse() {
1367
1447
  return Joi.object({
1368
- user_id: Joi.string().allow(""),
1369
- username: Joi.string().allow(""),
1448
+ status_code: Joi.number().required(),
1449
+ zone_id: Joi.string().allow("").required(),
1450
+ success: Joi.boolean().required(),
1370
1451
  });
1371
1452
  }
1372
1453
 
1373
- /** @returns {CreateStoreRuleRequestSchema} */
1374
- static CreateStoreRuleRequestSchema() {
1454
+ /** @returns {GetZoneFromPincodeViewRequest} */
1455
+ static GetZoneFromPincodeViewRequest() {
1375
1456
  return Joi.object({
1376
- conditions: ServiceabilityPlatformModel.StoreRuleConditionSchema(),
1377
- is_active: Joi.boolean(),
1378
- name: Joi.string().allow(""),
1379
- sort: Joi.array().items(Joi.string().allow("")),
1380
- store_priority: Joi.array().items(
1381
- ServiceabilityPlatformModel.StorePrioritySchema()
1382
- ),
1383
- tag_based_priority: Joi.array().items(Joi.string().allow("")),
1384
- type_based_priority: Joi.array().items(Joi.string().allow("")),
1457
+ country: Joi.string().allow("").required(),
1458
+ pincode: Joi.string().allow("").required(),
1385
1459
  });
1386
1460
  }
1387
1461
 
1388
- /** @returns {CreateZoneData} */
1389
- static CreateZoneData() {
1462
+ /** @returns {Zone} */
1463
+ static Zone() {
1390
1464
  return Joi.object({
1391
- assignment_preference: Joi.string().allow(""),
1392
- channels: Joi.array()
1393
- .items(ServiceabilityPlatformModel.GetZoneDataViewChannels())
1394
- .required(),
1395
- company_id: Joi.number().required(),
1396
- is_active: Joi.boolean().required(),
1397
- mapping: Joi.array()
1398
- .items(ServiceabilityPlatformModel.ZoneMappingType())
1399
- .required(),
1465
+ zone_id: Joi.string().allow("").required(),
1466
+ type: Joi.string().allow("").required(),
1400
1467
  name: Joi.string().allow("").required(),
1401
- region_type: Joi.string().allow("").required(),
1468
+ tags: Joi.array().items(Joi.string().allow("")).required(),
1402
1469
  slug: Joi.string().allow("").required(),
1470
+ is_active: Joi.boolean().required(),
1403
1471
  store_ids: Joi.array().items(Joi.number()).required(),
1472
+ assignment_preference: Joi.string().allow("").required(),
1404
1473
  });
1405
1474
  }
1406
1475
 
1407
- /** @returns {CustomerRadiusSchema} */
1408
- static CustomerRadiusSchema() {
1476
+ /** @returns {GetZoneFromPincodeViewResponse} */
1477
+ static GetZoneFromPincodeViewResponse() {
1409
1478
  return Joi.object({
1410
- gt: Joi.number(),
1411
- gte: Joi.number(),
1412
- lt: Joi.number(),
1413
- lte: Joi.number(),
1414
- unit: Joi.string().allow("").required(),
1479
+ serviceability_type: Joi.string().allow("").required(),
1480
+ zones: Joi.array().items(ServiceabilityPlatformModel.Zone()).required(),
1415
1481
  });
1416
1482
  }
1417
1483
 
1418
- /** @returns {DocumentsResponse} */
1419
- static DocumentsResponse() {
1484
+ /** @returns {GetZoneFromApplicationIdViewResponse} */
1485
+ static GetZoneFromApplicationIdViewResponse() {
1486
+ return Joi.object({
1487
+ page: Joi.array()
1488
+ .items(ServiceabilityPlatformModel.ZoneDataItem())
1489
+ .required(),
1490
+ items: Joi.array()
1491
+ .items(ServiceabilityPlatformModel.ListViewItems())
1492
+ .required(),
1493
+ });
1494
+ }
1495
+
1496
+ /** @returns {ServiceabilityPageResponse} */
1497
+ static ServiceabilityPageResponse() {
1420
1498
  return Joi.object({
1421
- legal_name: Joi.string().allow(""),
1422
1499
  type: Joi.string().allow(""),
1423
- value: Joi.string().allow(""),
1424
- verified: Joi.boolean(),
1500
+ has_next: Joi.boolean(),
1501
+ item_total: Joi.number(),
1502
+ size: Joi.number(),
1503
+ current: Joi.number(),
1425
1504
  });
1426
1505
  }
1427
1506
 
1428
- /** @returns {Dp} */
1429
- static Dp() {
1507
+ /** @returns {MobileNo} */
1508
+ static MobileNo() {
1430
1509
  return Joi.object({
1431
- area_code: Joi.number().allow(null),
1432
- assign_dp_from_sb: Joi.boolean(),
1433
- external_account_id: Joi.string().allow("").allow(null),
1434
- fm_priority: Joi.number(),
1435
- internal_account_id: Joi.string().allow(""),
1436
- lm_priority: Joi.number(),
1437
- operations: Joi.array().items(Joi.string().allow("")),
1438
- payment_mode: Joi.string().allow(""),
1439
- rvp_priority: Joi.number(),
1440
- transport_mode: Joi.string().allow(""),
1510
+ number: Joi.string().allow(""),
1511
+ country_code: Joi.number(),
1441
1512
  });
1442
1513
  }
1443
1514
 
1444
- /** @returns {EinvoiceResponse} */
1445
- static EinvoiceResponse() {
1515
+ /** @returns {ManagerResponse} */
1516
+ static ManagerResponse() {
1446
1517
  return Joi.object({
1447
- enabled: Joi.boolean(),
1518
+ email: Joi.string().allow(""),
1519
+ mobile_no: ServiceabilityPlatformModel.MobileNo(),
1520
+ name: Joi.string().allow(""),
1448
1521
  });
1449
1522
  }
1450
1523
 
1451
- /** @returns {EntityRegionView_Error} */
1452
- static EntityRegionView_Error() {
1524
+ /** @returns {ModifiedByResponse} */
1525
+ static ModifiedByResponse() {
1453
1526
  return Joi.object({
1454
- message: Joi.string().allow(""),
1455
- type: Joi.string().allow(""),
1456
- value: Joi.string().allow(""),
1527
+ username: Joi.string().allow(""),
1528
+ user_id: Joi.string().allow(""),
1457
1529
  });
1458
1530
  }
1459
1531
 
1460
- /** @returns {EntityRegionView_Items} */
1461
- static EntityRegionView_Items() {
1532
+ /** @returns {IntegrationTypeResponse} */
1533
+ static IntegrationTypeResponse() {
1462
1534
  return Joi.object({
1463
- name: Joi.string().allow("").required(),
1464
- sub_type: Joi.string().allow("").required(),
1465
- uid: Joi.string().allow("").required(),
1535
+ inventory: Joi.string().allow(""),
1536
+ order: Joi.string().allow(""),
1466
1537
  });
1467
1538
  }
1468
1539
 
1469
- /** @returns {EntityRegionView_page} */
1470
- static EntityRegionView_page() {
1540
+ /** @returns {ProductReturnConfigResponse} */
1541
+ static ProductReturnConfigResponse() {
1471
1542
  return Joi.object({
1472
- current: Joi.number().required(),
1473
- has_next: Joi.boolean().required(),
1474
- item_total: Joi.number().required(),
1475
- size: Joi.number().required(),
1476
- type: Joi.string().allow("").required(),
1543
+ on_same_store: Joi.boolean(),
1477
1544
  });
1478
1545
  }
1479
1546
 
1480
- /** @returns {EntityRegionView_Request} */
1481
- static EntityRegionView_Request() {
1547
+ /** @returns {ContactNumberResponse} */
1548
+ static ContactNumberResponse() {
1482
1549
  return Joi.object({
1483
- parent_id: Joi.array().items(Joi.string().allow("")),
1484
- sub_type: Joi.array().items(Joi.string().allow("")).required(),
1550
+ number: Joi.string().allow(""),
1551
+ country_code: Joi.number(),
1485
1552
  });
1486
1553
  }
1487
1554
 
1488
- /** @returns {EntityRegionView_Response} */
1489
- static EntityRegionView_Response() {
1555
+ /** @returns {AddressResponse} */
1556
+ static AddressResponse() {
1490
1557
  return Joi.object({
1491
- data: Joi.array()
1492
- .items(ServiceabilityPlatformModel.EntityRegionView_Items())
1493
- .required(),
1494
- error: ServiceabilityPlatformModel.EntityRegionView_Error().required(),
1495
- page: ServiceabilityPlatformModel.EntityRegionView_page().required(),
1496
- success: Joi.boolean().required(),
1558
+ city: Joi.string().allow(""),
1559
+ address1: Joi.string().allow(""),
1560
+ pincode: Joi.number(),
1561
+ address2: Joi.string().allow(""),
1562
+ landmark: Joi.string().allow(""),
1563
+ state: Joi.string().allow(""),
1564
+ country: Joi.string().allow(""),
1565
+ latitude: Joi.number(),
1566
+ longitude: Joi.number(),
1497
1567
  });
1498
1568
  }
1499
1569
 
1500
- /** @returns {Error} */
1501
- static Error() {
1570
+ /** @returns {CreatedByResponse} */
1571
+ static CreatedByResponse() {
1502
1572
  return Joi.object({
1503
- message: Joi.string().allow("").allow(null),
1504
- type: Joi.string().allow("").allow(null),
1505
- value: Joi.string().allow("").allow(null),
1573
+ username: Joi.string().allow(""),
1574
+ user_id: Joi.string().allow(""),
1506
1575
  });
1507
1576
  }
1508
1577
 
1509
- /** @returns {ErrorResponse} */
1510
- static ErrorResponse() {
1578
+ /** @returns {EwayBillResponse} */
1579
+ static EwayBillResponse() {
1511
1580
  return Joi.object({
1512
- message: Joi.string().allow("").required(),
1513
- type: Joi.string().allow("").required(),
1514
- value: Joi.string().allow("").required(),
1581
+ enabled: Joi.boolean(),
1515
1582
  });
1516
1583
  }
1517
1584
 
1518
- /** @returns {EwayBillResponse} */
1519
- static EwayBillResponse() {
1585
+ /** @returns {EinvoiceResponse} */
1586
+ static EinvoiceResponse() {
1520
1587
  return Joi.object({
1521
1588
  enabled: Joi.boolean(),
1522
1589
  });
1523
1590
  }
1524
1591
 
1525
- /** @returns {FailureResponse} */
1526
- static FailureResponse() {
1592
+ /** @returns {GstCredentialsResponse} */
1593
+ static GstCredentialsResponse() {
1527
1594
  return Joi.object({
1528
- error: Joi.array()
1529
- .items(ServiceabilityPlatformModel.ErrorResponse())
1530
- .required(),
1531
- success: Joi.boolean().required(),
1595
+ e_waybill: ServiceabilityPlatformModel.EwayBillResponse(),
1596
+ e_invoice: ServiceabilityPlatformModel.EinvoiceResponse(),
1532
1597
  });
1533
1598
  }
1534
1599
 
1535
- /** @returns {getAppRegionZonesResponse} */
1536
- static getAppRegionZonesResponse() {
1600
+ /** @returns {WarningsResponse} */
1601
+ static WarningsResponse() {
1537
1602
  return Joi.object({
1538
- items: Joi.array()
1539
- .items(ServiceabilityPlatformModel.ListViewItems())
1540
- .required(),
1541
- page: Joi.array()
1542
- .items(ServiceabilityPlatformModel.PageSchema())
1543
- .required(),
1603
+ store_address: Joi.string().allow(""),
1544
1604
  });
1545
1605
  }
1546
1606
 
1547
- /** @returns {GetSingleZoneDataViewResponse} */
1548
- static GetSingleZoneDataViewResponse() {
1607
+ /** @returns {OpeningClosing} */
1608
+ static OpeningClosing() {
1549
1609
  return Joi.object({
1550
- data: ServiceabilityPlatformModel.GetZoneDataViewItems().required(),
1610
+ minute: Joi.number(),
1611
+ hour: Joi.number(),
1551
1612
  });
1552
1613
  }
1553
1614
 
1554
- /** @returns {GetStoreRulesApiResponse} */
1555
- static GetStoreRulesApiResponse() {
1615
+ /** @returns {TimmingResponse} */
1616
+ static TimmingResponse() {
1556
1617
  return Joi.object({
1557
- items: Joi.array().items(
1558
- ServiceabilityPlatformModel.StoreRuleDataSchema()
1559
- ),
1560
- page: ServiceabilityPlatformModel.Page(),
1618
+ open: Joi.boolean(),
1619
+ weekday: Joi.string().allow(""),
1620
+ closing: ServiceabilityPlatformModel.OpeningClosing(),
1621
+ opening: ServiceabilityPlatformModel.OpeningClosing(),
1561
1622
  });
1562
1623
  }
1563
1624
 
1564
- /** @returns {GetStoresViewResponse} */
1565
- static GetStoresViewResponse() {
1625
+ /** @returns {DocumentsResponse} */
1626
+ static DocumentsResponse() {
1566
1627
  return Joi.object({
1567
- items: Joi.array().items(ServiceabilityPlatformModel.ItemResponse()),
1568
- page: ServiceabilityPlatformModel.ServiceabilityPageResponse().required(),
1628
+ legal_name: Joi.string().allow(""),
1629
+ value: Joi.string().allow(""),
1630
+ type: Joi.string().allow(""),
1631
+ verified: Joi.boolean(),
1569
1632
  });
1570
1633
  }
1571
1634
 
1572
- /** @returns {GetZoneByIdSchema} */
1573
- static GetZoneByIdSchema() {
1635
+ /** @returns {Dp} */
1636
+ static Dp() {
1574
1637
  return Joi.object({
1575
- assignment_preference: Joi.string().allow(""),
1576
- channels: Joi.array()
1577
- .items(ServiceabilityPlatformModel.GetZoneDataViewChannels())
1578
- .required(),
1579
- company_id: Joi.number(),
1580
- is_active: Joi.boolean().required(),
1581
- mapping: Joi.array()
1582
- .items(ServiceabilityPlatformModel.ZoneMappingType())
1583
- .required(),
1584
- name: Joi.string().allow("").required(),
1585
- product: ServiceabilityPlatformModel.ZoneProductTypes().required(),
1586
- region_type: Joi.string().allow("").required(),
1587
- slug: Joi.string().allow("").required(),
1588
- store_ids: Joi.array().items(Joi.number()).required(),
1589
- stores_count: Joi.number().required(),
1590
- zone_id: Joi.string().allow("").required(),
1638
+ fm_priority: Joi.number(),
1639
+ rvp_priority: Joi.number(),
1640
+ lm_priority: Joi.number(),
1641
+ internal_account_id: Joi.string().allow(""),
1642
+ area_code: Joi.number().allow(null),
1643
+ payment_mode: Joi.string().allow(""),
1644
+ operations: Joi.array().items(Joi.string().allow("")),
1645
+ external_account_id: Joi.string().allow("").allow(null),
1646
+ transport_mode: Joi.string().allow(""),
1647
+ assign_dp_from_sb: Joi.boolean(),
1591
1648
  });
1592
1649
  }
1593
1650
 
1594
- /** @returns {GetZoneDataViewChannels} */
1595
- static GetZoneDataViewChannels() {
1651
+ /** @returns {LogisticsResponse} */
1652
+ static LogisticsResponse() {
1596
1653
  return Joi.object({
1597
- channel_id: Joi.string().allow("").required(),
1598
- channel_type: Joi.string().allow("").required(),
1654
+ override: Joi.boolean(),
1655
+ dp: ServiceabilityPlatformModel.Dp(),
1599
1656
  });
1600
1657
  }
1601
1658
 
1602
- /** @returns {GetZoneDataViewItems} */
1603
- static GetZoneDataViewItems() {
1659
+ /** @returns {ItemResponse} */
1660
+ static ItemResponse() {
1604
1661
  return Joi.object({
1605
- assignment_preference: Joi.string().allow(""),
1606
- channels: Joi.array()
1607
- .items(ServiceabilityPlatformModel.GetZoneDataViewChannels())
1608
- .required(),
1662
+ created_on: Joi.string().allow(""),
1663
+ manager: ServiceabilityPlatformModel.ManagerResponse(),
1664
+ modified_by: ServiceabilityPlatformModel.ModifiedByResponse(),
1665
+ integration_type: ServiceabilityPlatformModel.IntegrationTypeResponse(),
1666
+ verified_on: Joi.string().allow(""),
1667
+ product_return_config: ServiceabilityPlatformModel.ProductReturnConfigResponse(),
1668
+ contact_numbers: Joi.array().items(
1669
+ ServiceabilityPlatformModel.ContactNumberResponse()
1670
+ ),
1671
+ verified_by: ServiceabilityPlatformModel.ModifiedByResponse(),
1672
+ stage: Joi.string().allow(""),
1673
+ address: ServiceabilityPlatformModel.AddressResponse(),
1674
+ modified_on: Joi.string().allow(""),
1675
+ created_by: ServiceabilityPlatformModel.CreatedByResponse(),
1676
+ gst_credentials: ServiceabilityPlatformModel.GstCredentialsResponse(),
1677
+ display_name: Joi.string().allow(""),
1609
1678
  company_id: Joi.number(),
1610
- is_active: Joi.boolean().required(),
1611
- mapping: Joi.array()
1612
- .items(ServiceabilityPlatformModel.ZoneMappingType())
1613
- .required(),
1614
- name: Joi.string().allow("").required(),
1615
- product: ServiceabilityPlatformModel.ZoneProductTypes().required(),
1616
- region_type: Joi.string().allow(""),
1617
- slug: Joi.string().allow("").required(),
1618
- store_ids: Joi.array().items(Joi.number()).required(),
1619
- stores_count: Joi.number().required(),
1620
- zone_id: Joi.string().allow("").required(),
1679
+ uid: Joi.number(),
1680
+ _custom_json: Joi.any(),
1681
+ code: Joi.string().allow(""),
1682
+ warnings: ServiceabilityPlatformModel.WarningsResponse(),
1683
+ name: Joi.string().allow(""),
1684
+ timing: Joi.array().items(ServiceabilityPlatformModel.TimmingResponse()),
1685
+ documents: Joi.array().items(
1686
+ ServiceabilityPlatformModel.DocumentsResponse()
1687
+ ),
1688
+ store_type: Joi.string().allow(""),
1689
+ sub_type: Joi.string().allow(""),
1690
+ company: Joi.number(),
1691
+ _cls: Joi.string().allow(""),
1692
+ logistics: ServiceabilityPlatformModel.LogisticsResponse(),
1693
+ notification_emails: Joi.array().items(Joi.string().allow("")),
1621
1694
  });
1622
1695
  }
1623
1696
 
1624
- /** @returns {GetZoneFromApplicationIdViewResponse} */
1625
- static GetZoneFromApplicationIdViewResponse() {
1697
+ /** @returns {GetStoresViewResponse} */
1698
+ static GetStoresViewResponse() {
1626
1699
  return Joi.object({
1627
- items: Joi.array()
1628
- .items(ServiceabilityPlatformModel.ListViewItems())
1629
- .required(),
1630
- page: Joi.array()
1631
- .items(ServiceabilityPlatformModel.ZoneDataItem())
1632
- .required(),
1700
+ page: ServiceabilityPlatformModel.ServiceabilityPageResponse().required(),
1701
+ items: Joi.array().items(ServiceabilityPlatformModel.ItemResponse()),
1633
1702
  });
1634
1703
  }
1635
1704
 
1636
- /** @returns {GetZoneFromPincodeViewRequest} */
1637
- static GetZoneFromPincodeViewRequest() {
1705
+ /** @returns {PincodeMopData} */
1706
+ static PincodeMopData() {
1638
1707
  return Joi.object({
1708
+ pincodes: Joi.array().items(Joi.number()).required(),
1639
1709
  country: Joi.string().allow("").required(),
1640
- pincode: Joi.string().allow("").required(),
1710
+ action: Joi.string().allow("").required(),
1641
1711
  });
1642
1712
  }
1643
1713
 
1644
- /** @returns {GetZoneFromPincodeViewResponse} */
1645
- static GetZoneFromPincodeViewResponse() {
1714
+ /** @returns {PincodeMopUpdateResponse} */
1715
+ static PincodeMopUpdateResponse() {
1646
1716
  return Joi.object({
1647
- serviceability_type: Joi.string().allow("").required(),
1648
- zones: Joi.array().items(ServiceabilityPlatformModel.Zone()).required(),
1717
+ pincode: Joi.number().required(),
1718
+ channel_id: Joi.string().allow("").required(),
1719
+ country: Joi.string().allow("").required(),
1720
+ is_active: Joi.boolean().required(),
1649
1721
  });
1650
1722
  }
1651
1723
 
1652
- /** @returns {GstCredentialsResponse} */
1653
- static GstCredentialsResponse() {
1724
+ /** @returns {PincodeMOPresponse} */
1725
+ static PincodeMOPresponse() {
1654
1726
  return Joi.object({
1655
- e_invoice: ServiceabilityPlatformModel.EinvoiceResponse(),
1656
- e_waybill: ServiceabilityPlatformModel.EwayBillResponse(),
1727
+ success: Joi.boolean().required(),
1728
+ status_code: Joi.number().required(),
1729
+ batch_id: Joi.string().allow("").required(),
1730
+ country: Joi.string().allow("").required(),
1731
+ action: Joi.string().allow("").required(),
1732
+ pincodes: Joi.array().items(Joi.number()),
1733
+ updated_pincodes: Joi.array().items(
1734
+ ServiceabilityPlatformModel.PincodeMopUpdateResponse()
1735
+ ),
1657
1736
  });
1658
1737
  }
1659
1738
 
1660
- /** @returns {IntComparisonOperations} */
1661
- static IntComparisonOperations() {
1739
+ /** @returns {CommonError} */
1740
+ static CommonError() {
1662
1741
  return Joi.object({
1663
- includes: Joi.array().items(Joi.number()),
1742
+ status_code: Joi.string().allow(""),
1743
+ error: Joi.any(),
1744
+ success: Joi.string().allow(""),
1664
1745
  });
1665
1746
  }
1666
1747
 
1667
- /** @returns {IntegrationTypeResponse} */
1668
- static IntegrationTypeResponse() {
1748
+ /** @returns {PincodeMopBulkData} */
1749
+ static PincodeMopBulkData() {
1669
1750
  return Joi.object({
1670
- inventory: Joi.string().allow(""),
1671
- order: Joi.string().allow(""),
1751
+ batch_id: Joi.string().allow("").required(),
1752
+ s3_url: Joi.string().allow("").required(),
1672
1753
  });
1673
1754
  }
1674
1755
 
1675
- /** @returns {ItemResponse} */
1676
- static ItemResponse() {
1756
+ /** @returns {PincodeBulkViewResponse} */
1757
+ static PincodeBulkViewResponse() {
1677
1758
  return Joi.object({
1678
- _cls: Joi.string().allow(""),
1679
- _custom_json: Joi.any(),
1680
- address: ServiceabilityPlatformModel.AddressResponse(),
1681
- code: Joi.string().allow(""),
1682
- company: Joi.number(),
1683
- company_id: Joi.number(),
1684
- contact_numbers: Joi.array().items(
1685
- ServiceabilityPlatformModel.ContactNumberResponse()
1686
- ),
1687
- created_by: ServiceabilityPlatformModel.CreatedByResponse(),
1688
- created_on: Joi.string().allow(""),
1689
- display_name: Joi.string().allow(""),
1690
- documents: Joi.array().items(
1691
- ServiceabilityPlatformModel.DocumentsResponse()
1692
- ),
1693
- gst_credentials: ServiceabilityPlatformModel.GstCredentialsResponse(),
1694
- integration_type: ServiceabilityPlatformModel.IntegrationTypeResponse(),
1695
- logistics: ServiceabilityPlatformModel.LogisticsResponse(),
1696
- manager: ServiceabilityPlatformModel.ManagerResponse(),
1697
- modified_by: ServiceabilityPlatformModel.ModifiedByResponse(),
1698
- modified_on: Joi.string().allow(""),
1699
- name: Joi.string().allow(""),
1700
- notification_emails: Joi.array().items(Joi.string().allow("")),
1701
- product_return_config: ServiceabilityPlatformModel.ProductReturnConfigResponse(),
1702
- stage: Joi.string().allow(""),
1703
- store_type: Joi.string().allow(""),
1704
- sub_type: Joi.string().allow(""),
1705
- timing: Joi.array().items(ServiceabilityPlatformModel.TimmingResponse()),
1706
- uid: Joi.number(),
1707
- verified_by: ServiceabilityPlatformModel.ModifiedByResponse(),
1708
- verified_on: Joi.string().allow(""),
1709
- warnings: ServiceabilityPlatformModel.WarningsResponse(),
1759
+ batch_id: Joi.string().allow("").required(),
1760
+ s3_url: Joi.string().allow("").required(),
1710
1761
  });
1711
1762
  }
1712
1763
 
1713
- /** @returns {ListViewChannels} */
1714
- static ListViewChannels() {
1764
+ /** @returns {PincodeCodStatusListingRequest} */
1765
+ static PincodeCodStatusListingRequest() {
1715
1766
  return Joi.object({
1716
- channel_id: Joi.string().allow("").required(),
1717
- channel_type: Joi.string().allow("").required(),
1767
+ country: Joi.string().allow(""),
1768
+ is_active: Joi.boolean(),
1769
+ pincode: Joi.number().allow(null),
1770
+ current: Joi.number(),
1771
+ page_size: Joi.number(),
1718
1772
  });
1719
1773
  }
1720
1774
 
1721
- /** @returns {ListViewItems} */
1722
- static ListViewItems() {
1775
+ /** @returns {PincodeCodStatusListingResponse} */
1776
+ static PincodeCodStatusListingResponse() {
1723
1777
  return Joi.object({
1724
- channels: Joi.array()
1725
- .items(ServiceabilityPlatformModel.ListViewChannels())
1778
+ country: Joi.string().allow("").required(),
1779
+ data: Joi.array()
1780
+ .items(Joi.link("#PincodeCodStatusListingResponse"))
1726
1781
  .required(),
1727
- company_id: Joi.number().required(),
1728
- is_active: Joi.boolean().required(),
1729
- name: Joi.string().allow("").required(),
1730
- product: ServiceabilityPlatformModel.ListViewProduct().required(),
1731
- regions_count: Joi.number().required(),
1732
- slug: Joi.string().allow("").required(),
1733
- stores_count: Joi.number().required(),
1734
- zone_id: Joi.string().allow("").required(),
1782
+ success: Joi.boolean().required(),
1783
+ errors: Joi.array().items(ServiceabilityPlatformModel.Error()),
1784
+ page: ServiceabilityPlatformModel.PincodeCodStatusListingPage().required(),
1785
+ summary: ServiceabilityPlatformModel.PincodeCodStatusListingSummary().required(),
1735
1786
  });
1736
1787
  }
1737
1788
 
1738
- /** @returns {ListViewProduct} */
1739
- static ListViewProduct() {
1789
+ /** @returns {Error} */
1790
+ static Error() {
1740
1791
  return Joi.object({
1741
- count: Joi.number().required(),
1742
- type: Joi.string().allow("").required(),
1792
+ type: Joi.string().allow("").allow(null),
1793
+ value: Joi.string().allow("").allow(null),
1794
+ message: Joi.string().allow("").allow(null),
1743
1795
  });
1744
1796
  }
1745
1797
 
1746
- /** @returns {ListViewResponse} */
1747
- static ListViewResponse() {
1798
+ /** @returns {PincodeCodStatusListingPage} */
1799
+ static PincodeCodStatusListingPage() {
1748
1800
  return Joi.object({
1749
- items: Joi.array()
1750
- .items(ServiceabilityPlatformModel.ListViewItems())
1751
- .required(),
1752
- page: Joi.array()
1753
- .items(ServiceabilityPlatformModel.ZoneDataItem())
1754
- .required(),
1801
+ type: Joi.string().allow("").required(),
1802
+ has_next: Joi.boolean().required(),
1803
+ item_total: Joi.number().required(),
1804
+ size: Joi.number().required(),
1805
+ current: Joi.number().required(),
1755
1806
  });
1756
1807
  }
1757
1808
 
1758
- /** @returns {ListViewSummary} */
1759
- static ListViewSummary() {
1809
+ /** @returns {PincodeCodStatusListingSummary} */
1810
+ static PincodeCodStatusListingSummary() {
1760
1811
  return Joi.object({
1761
- total_active_zones: Joi.number().required(),
1762
- total_pincodes_served: Joi.number().required(),
1763
- total_zones: Joi.number().required(),
1812
+ total_active_pincodes: Joi.number().required(),
1813
+ total_inactive_pincodes: Joi.number().required(),
1764
1814
  });
1765
1815
  }
1766
1816
 
1767
- /** @returns {LocationRule} */
1768
- static LocationRule() {
1817
+ /** @returns {PincodeMopUpdateAuditHistoryRequest} */
1818
+ static PincodeMopUpdateAuditHistoryRequest() {
1769
1819
  return Joi.object({
1770
- includes: Joi.array().items(
1771
- ServiceabilityPlatformModel.LocationRuleValues()
1772
- ),
1773
- type: Joi.string().allow(""),
1820
+ entity_type: Joi.string().allow("").required(),
1821
+ file_name: Joi.string().allow(""),
1774
1822
  });
1775
1823
  }
1776
1824
 
1777
- /** @returns {LocationRuleValues} */
1778
- static LocationRuleValues() {
1825
+ /** @returns {PincodeMopUpdateAuditHistoryPaging} */
1826
+ static PincodeMopUpdateAuditHistoryPaging() {
1779
1827
  return Joi.object({
1780
- display_name: Joi.string().allow(""),
1781
- id: Joi.string().allow("").required(),
1782
- name: Joi.string().allow(""),
1783
- parent_id: Joi.string().allow(""),
1784
- parent_ids: Joi.array().items(Joi.string().allow("")),
1785
- sub_type: Joi.string().allow(""),
1828
+ type: Joi.string().allow(""),
1829
+ size: Joi.number(),
1830
+ current: Joi.number(),
1831
+ has_next: Joi.boolean(),
1832
+ item_total: Joi.number(),
1786
1833
  });
1787
1834
  }
1788
1835
 
1789
- /** @returns {LogisticsResponse} */
1790
- static LogisticsResponse() {
1836
+ /** @returns {PincodeMopUpdateAuditHistoryResponse} */
1837
+ static PincodeMopUpdateAuditHistoryResponse() {
1791
1838
  return Joi.object({
1792
- dp: ServiceabilityPlatformModel.Dp(),
1793
- override: Joi.boolean(),
1839
+ batch_id: Joi.string().allow(""),
1840
+ entity_type: Joi.string().allow(""),
1841
+ error_file_s3_url: Joi.string().allow(""),
1842
+ s3_url: Joi.string().allow(""),
1843
+ file_name: Joi.string().allow(""),
1844
+ updated_at: Joi.string().allow(""),
1845
+ updated_by: Joi.string().allow(""),
1846
+ success: Joi.boolean(),
1794
1847
  });
1795
1848
  }
1796
1849
 
1797
- /** @returns {ManagerResponse} */
1798
- static ManagerResponse() {
1850
+ /** @returns {PincodeMopUpdateAuditHistoryResponseData} */
1851
+ static PincodeMopUpdateAuditHistoryResponseData() {
1799
1852
  return Joi.object({
1800
- email: Joi.string().allow(""),
1801
- mobile_no: ServiceabilityPlatformModel.MobileNo(),
1802
- name: Joi.string().allow(""),
1853
+ entity_type: Joi.string().allow(""),
1854
+ page: ServiceabilityPlatformModel.PincodeMopUpdateAuditHistoryPaging().required(),
1855
+ data: Joi.array()
1856
+ .items(
1857
+ ServiceabilityPlatformModel.PincodeMopUpdateAuditHistoryResponse()
1858
+ )
1859
+ .required(),
1803
1860
  });
1804
1861
  }
1805
1862
 
1806
- /** @returns {MobileNo} */
1807
- static MobileNo() {
1863
+ /** @returns {ArithmeticOperations} */
1864
+ static ArithmeticOperations() {
1808
1865
  return Joi.object({
1809
- country_code: Joi.number(),
1810
- number: Joi.string().allow(""),
1866
+ lt: Joi.number(),
1867
+ gt: Joi.number(),
1868
+ lte: Joi.number(),
1869
+ gte: Joi.number(),
1811
1870
  });
1812
1871
  }
1813
1872
 
1814
- /** @returns {ModifiedByResponse} */
1815
- static ModifiedByResponse() {
1873
+ /** @returns {SchemeRulesFeatures} */
1874
+ static SchemeRulesFeatures() {
1816
1875
  return Joi.object({
1817
- user_id: Joi.string().allow(""),
1818
- username: Joi.string().allow(""),
1876
+ quality_check: Joi.boolean(),
1877
+ quick_response_code: Joi.boolean(),
1878
+ e_waybill: Joi.boolean(),
1879
+ multi_part_shipments: Joi.boolean(),
1880
+ flammable: Joi.boolean(),
1881
+ hazmat: Joi.boolean(),
1882
+ battery_operated: Joi.boolean(),
1819
1883
  });
1820
1884
  }
1821
1885
 
1822
- /** @returns {OpeningClosing} */
1823
- static OpeningClosing() {
1886
+ /** @returns {SchemeRules} */
1887
+ static SchemeRules() {
1824
1888
  return Joi.object({
1825
- hour: Joi.number(),
1826
- minute: Joi.number(),
1889
+ weight: ServiceabilityPlatformModel.ArithmeticOperations(),
1890
+ transport_type: Joi.array().items(Joi.string().allow("")),
1891
+ region: Joi.string().allow(""),
1892
+ payment_mode: Joi.array().items(Joi.string().allow("")),
1893
+ feature: ServiceabilityPlatformModel.SchemeRulesFeatures(),
1827
1894
  });
1828
1895
  }
1829
1896
 
1830
- /** @returns {PackageMaterial} */
1831
- static PackageMaterial() {
1897
+ /** @returns {CourierAccount} */
1898
+ static CourierAccount() {
1832
1899
  return Joi.object({
1833
- auto_calculate: Joi.boolean(),
1834
- channels: Joi.array()
1835
- .items(ServiceabilityPlatformModel.Channel())
1836
- .required(),
1837
- error_rate: Joi.number().required(),
1838
- height: Joi.number().required(),
1839
- length: Joi.number().required(),
1840
- max_weight: Joi.number(),
1841
- media: Joi.array().items(Joi.string().allow("")),
1842
- name: Joi.string().allow("").required(),
1843
- package_type: Joi.string().allow("").required(),
1844
- package_vol_weight: Joi.number(),
1845
- rules: Joi.array().items(
1846
- ServiceabilityPlatformModel.PackageMaterialRule()
1847
- ),
1848
- size: Joi.string().allow("").required(),
1849
- status: Joi.string().allow("").required(),
1850
- store_ids: Joi.array().items(Joi.number()).required(),
1851
- track_inventory: Joi.boolean(),
1852
- weight: Joi.number().required(),
1853
- width: Joi.number().required(),
1900
+ extension_id: Joi.string().allow("").required(),
1901
+ account_id: Joi.string().allow("").required(),
1902
+ scheme_id: Joi.string().allow("").required(),
1903
+ is_self_ship: Joi.boolean().required(),
1904
+ stage: Joi.string().allow("").required(),
1905
+ is_own_account: Joi.boolean().required(),
1854
1906
  });
1855
1907
  }
1856
1908
 
1857
- /** @returns {PackageMaterialList} */
1858
- static PackageMaterialList() {
1909
+ /** @returns {ErrorResponse} */
1910
+ static ErrorResponse() {
1859
1911
  return Joi.object({
1860
- items: ServiceabilityPlatformModel.PackageMaterialResponse(),
1861
- page: ServiceabilityPlatformModel.Page(),
1912
+ value: Joi.string().allow("").required(),
1913
+ message: Joi.string().allow("").required(),
1914
+ type: Joi.string().allow("").required(),
1862
1915
  });
1863
1916
  }
1864
1917
 
1865
- /** @returns {PackageMaterialResponse} */
1866
- static PackageMaterialResponse() {
1918
+ /** @returns {CourierPartnerAccountFailureResponse} */
1919
+ static CourierPartnerAccountFailureResponse() {
1867
1920
  return Joi.object({
1868
- auto_calculate: Joi.boolean(),
1869
- channels: Joi.array()
1870
- .items(ServiceabilityPlatformModel.Channel())
1921
+ success: Joi.boolean().required(),
1922
+ error: Joi.array()
1923
+ .items(ServiceabilityPlatformModel.ErrorResponse())
1871
1924
  .required(),
1872
- error_rate: Joi.number().required(),
1873
- height: Joi.number().required(),
1874
- id: Joi.string().allow(""),
1875
- item_id: Joi.number(),
1876
- length: Joi.number().required(),
1877
- max_weight: Joi.number(),
1878
- media: Joi.array().items(Joi.string().allow("")),
1879
- name: Joi.string().allow("").required(),
1880
- package_type: Joi.string().allow("").required(),
1881
- package_vol_weight: Joi.number(),
1882
- rules: Joi.array().items(
1883
- ServiceabilityPlatformModel.PackageMaterialRule()
1884
- ),
1885
- size: Joi.string().allow("").required(),
1886
- status: Joi.string().allow("").required(),
1887
- store_ids: Joi.array().items(Joi.number()).required(),
1888
- track_inventory: Joi.boolean(),
1889
- weight: Joi.number().required(),
1890
- width: Joi.number().required(),
1891
1925
  });
1892
1926
  }
1893
1927
 
1894
- /** @returns {PackageMaterialRule} */
1895
- static PackageMaterialRule() {
1928
+ /** @returns {Page} */
1929
+ static Page() {
1896
1930
  return Joi.object({
1897
- quantity: ServiceabilityPlatformModel.PackageMaterialRuleQuantity(),
1898
- rule_id: Joi.string().allow(""),
1899
- weight: Joi.number(),
1931
+ item_total: Joi.number(),
1932
+ next_id: Joi.string().allow(""),
1933
+ has_previous: Joi.boolean(),
1934
+ has_next: Joi.boolean(),
1935
+ current: Joi.number(),
1936
+ type: Joi.string().allow("").required(),
1937
+ size: Joi.number(),
1900
1938
  });
1901
1939
  }
1902
1940
 
1903
- /** @returns {PackageMaterialRuleList} */
1904
- static PackageMaterialRuleList() {
1941
+ /** @returns {CourierPartnerList} */
1942
+ static CourierPartnerList() {
1905
1943
  return Joi.object({
1906
- items: ServiceabilityPlatformModel.PackageRuleResponse(),
1907
- page: ServiceabilityPlatformModel.Page(),
1944
+ extension_id: Joi.string().allow("").required(),
1945
+ account_id: Joi.string().allow("").required(),
1946
+ name: Joi.string().allow("").required(),
1947
+ is_self_ship: Joi.boolean().required(),
1908
1948
  });
1909
1949
  }
1910
1950
 
1911
- /** @returns {PackageMaterialRuleQuantity} */
1912
- static PackageMaterialRuleQuantity() {
1951
+ /** @returns {LocationRuleValues} */
1952
+ static LocationRuleValues() {
1913
1953
  return Joi.object({
1914
- max: Joi.number(),
1915
- min: Joi.number(),
1954
+ id: Joi.string().allow("").required(),
1955
+ sub_type: Joi.string().allow(""),
1956
+ name: Joi.string().allow(""),
1957
+ display_name: Joi.string().allow(""),
1958
+ parent_id: Joi.string().allow(""),
1959
+ parent_ids: Joi.array().items(Joi.string().allow("")),
1916
1960
  });
1917
1961
  }
1918
1962
 
1919
- /** @returns {PackageRule} */
1920
- static PackageRule() {
1963
+ /** @returns {LocationRule} */
1964
+ static LocationRule() {
1921
1965
  return Joi.object({
1922
- category_id: ServiceabilityPlatformModel.PackageRuleCategory(),
1923
- company_id: Joi.number().required(),
1924
- is_active: Joi.boolean(),
1925
- name: Joi.string().allow("").required(),
1926
- product_id: ServiceabilityPlatformModel.PackageRuleProduct(),
1927
- product_tag: ServiceabilityPlatformModel.PackageRuleProductTag(),
1928
- type: Joi.string().allow("").required(),
1966
+ type: Joi.string().allow(""),
1967
+ includes: Joi.array().items(
1968
+ ServiceabilityPlatformModel.LocationRuleValues()
1969
+ ),
1929
1970
  });
1930
1971
  }
1931
1972
 
1932
- /** @returns {PackageRuleCategory} */
1933
- static PackageRuleCategory() {
1973
+ /** @returns {StringComparisonOperations} */
1974
+ static StringComparisonOperations() {
1934
1975
  return Joi.object({
1935
- includes: Joi.array().items(Joi.number()),
1976
+ includes: Joi.array().items(Joi.string().allow("")),
1936
1977
  });
1937
1978
  }
1938
1979
 
1939
- /** @returns {PackageRuleProduct} */
1940
- static PackageRuleProduct() {
1980
+ /** @returns {IntComparisonOperations} */
1981
+ static IntComparisonOperations() {
1941
1982
  return Joi.object({
1942
1983
  includes: Joi.array().items(Joi.number()),
1943
1984
  });
1944
1985
  }
1945
1986
 
1946
- /** @returns {PackageRuleProductTag} */
1947
- static PackageRuleProductTag() {
1987
+ /** @returns {CourierPartnerRuleConditions} */
1988
+ static CourierPartnerRuleConditions() {
1948
1989
  return Joi.object({
1949
- includes: Joi.array().items(Joi.string().allow("")),
1990
+ forward: ServiceabilityPlatformModel.LocationRule(),
1991
+ reverse: ServiceabilityPlatformModel.LocationRule(),
1992
+ payment_mode: ServiceabilityPlatformModel.StringComparisonOperations(),
1993
+ category_ids: ServiceabilityPlatformModel.IntComparisonOperations(),
1994
+ product_ids: ServiceabilityPlatformModel.IntComparisonOperations(),
1995
+ product_tags: ServiceabilityPlatformModel.StringComparisonOperations(),
1996
+ zone_ids: ServiceabilityPlatformModel.StringComparisonOperations(),
1997
+ department_ids: ServiceabilityPlatformModel.IntComparisonOperations(),
1998
+ brand_ids: ServiceabilityPlatformModel.IntComparisonOperations(),
1999
+ order_place_date: ServiceabilityPlatformModel.ArithmeticOperations(),
2000
+ store_ids: ServiceabilityPlatformModel.IntComparisonOperations(),
2001
+ store_type: ServiceabilityPlatformModel.StringComparisonOperations(),
2002
+ store_tags: ServiceabilityPlatformModel.StringComparisonOperations(),
2003
+ shipment_weight: ServiceabilityPlatformModel.ArithmeticOperations(),
2004
+ shipment_cost: ServiceabilityPlatformModel.ArithmeticOperations(),
2005
+ shipment_volumetric_weight: ServiceabilityPlatformModel.ArithmeticOperations(),
1950
2006
  });
1951
2007
  }
1952
2008
 
1953
- /** @returns {PackageRuleResponse} */
1954
- static PackageRuleResponse() {
2009
+ /** @returns {CourierPartnerRule} */
2010
+ static CourierPartnerRule() {
1955
2011
  return Joi.object({
1956
- category_id: ServiceabilityPlatformModel.PackageRuleCategory(),
1957
- company_id: Joi.number().required(),
1958
- id: Joi.string().allow(""),
1959
- is_active: Joi.boolean(),
2012
+ is_active: Joi.boolean().required(),
2013
+ cp_list: Joi.array().items(
2014
+ ServiceabilityPlatformModel.CourierPartnerList()
2015
+ ),
1960
2016
  name: Joi.string().allow("").required(),
1961
- product_id: ServiceabilityPlatformModel.PackageRuleProduct(),
1962
- product_tag: ServiceabilityPlatformModel.PackageRuleProductTag(),
1963
- type: Joi.string().allow("").required(),
2017
+ conditions: ServiceabilityPlatformModel.CourierPartnerRuleConditions().required(),
2018
+ sort: Joi.array().items(Joi.string().allow("")).required(),
1964
2019
  });
1965
2020
  }
1966
2021
 
1967
- /** @returns {Page} */
1968
- static Page() {
2022
+ /** @returns {FailureResponse} */
2023
+ static FailureResponse() {
1969
2024
  return Joi.object({
1970
- current: Joi.number(),
1971
- has_next: Joi.boolean(),
1972
- has_previous: Joi.boolean(),
1973
- item_total: Joi.number(),
1974
- next_id: Joi.string().allow(""),
1975
- size: Joi.number(),
1976
- type: Joi.string().allow("").required(),
2025
+ success: Joi.boolean().required(),
2026
+ error: Joi.array()
2027
+ .items(ServiceabilityPlatformModel.ErrorResponse())
2028
+ .required(),
1977
2029
  });
1978
2030
  }
1979
2031
 
1980
- /** @returns {PageSchema} */
1981
- static PageSchema() {
2032
+ /** @returns {CourierPartnerRulesListResponse} */
2033
+ static CourierPartnerRulesListResponse() {
1982
2034
  return Joi.object({
1983
- current: Joi.number().required(),
1984
- has_next: Joi.boolean().required(),
1985
- item_total: Joi.number().required(),
1986
- size: Joi.number().required(),
1987
- type: Joi.string().allow("").required(),
2035
+ items: Joi.array()
2036
+ .items(ServiceabilityPlatformModel.CourierPartnerRule())
2037
+ .required(),
2038
+ page: ServiceabilityPlatformModel.Page().required(),
1988
2039
  });
1989
2040
  }
1990
2041
 
1991
- /** @returns {PincodeBulkViewResponse} */
1992
- static PincodeBulkViewResponse() {
2042
+ /** @returns {CompanyConfig} */
2043
+ static CompanyConfig() {
1993
2044
  return Joi.object({
1994
- batch_id: Joi.string().allow("").required(),
1995
- s3_url: Joi.string().allow("").required(),
2045
+ rule_ids: Joi.array().items(Joi.string().allow("")).required(),
2046
+ sort: Joi.array().items(Joi.string().allow("")).required(),
2047
+ logistics_as_actual: Joi.boolean(),
1996
2048
  });
1997
2049
  }
1998
2050
 
1999
- /** @returns {PincodeCodStatusListingPage} */
2000
- static PincodeCodStatusListingPage() {
2051
+ /** @returns {ZoneConfig} */
2052
+ static ZoneConfig() {
2001
2053
  return Joi.object({
2002
- current: Joi.number().required(),
2003
- has_next: Joi.boolean().required(),
2004
- item_total: Joi.number().required(),
2005
- size: Joi.number().required(),
2006
- type: Joi.string().allow("").required(),
2054
+ serviceability_type: Joi.string().allow(""),
2007
2055
  });
2008
2056
  }
2009
2057
 
2010
- /** @returns {PincodeCodStatusListingRequest} */
2011
- static PincodeCodStatusListingRequest() {
2058
+ /** @returns {ApplicationConfig} */
2059
+ static ApplicationConfig() {
2012
2060
  return Joi.object({
2013
- country: Joi.string().allow(""),
2014
- current: Joi.number(),
2015
- is_active: Joi.boolean(),
2016
- page_size: Joi.number(),
2017
- pincode: Joi.number().allow(null),
2061
+ rule_ids: Joi.array().items(Joi.string().allow("")),
2062
+ sort: Joi.array().items(Joi.string().allow("")),
2063
+ zones: ServiceabilityPlatformModel.ZoneConfig(),
2018
2064
  });
2019
2065
  }
2020
2066
 
2021
- /** @returns {PincodeCodStatusListingResponse} */
2022
- static PincodeCodStatusListingResponse() {
2067
+ /** @returns {BulkRegionJobSerializer} */
2068
+ static BulkRegionJobSerializer() {
2023
2069
  return Joi.object({
2070
+ file_path: Joi.string().allow(""),
2024
2071
  country: Joi.string().allow("").required(),
2025
- data: Joi.array()
2026
- .items(Joi.link("#PincodeCodStatusListingResponse"))
2072
+ action: Joi.string().allow("").required(),
2073
+ region: Joi.string().allow("").required(),
2074
+ });
2075
+ }
2076
+
2077
+ /** @returns {BulkRegionResponseItemData} */
2078
+ static BulkRegionResponseItemData() {
2079
+ return Joi.object({
2080
+ file_path: Joi.string().allow("").required(),
2081
+ failed: Joi.number(),
2082
+ failed_records: Joi.array().items(Joi.any()),
2083
+ action: Joi.string().allow("").required(),
2084
+ batch_id: Joi.string().allow("").required(),
2085
+ country: Joi.string().allow("").required(),
2086
+ success: Joi.number(),
2087
+ region: Joi.string().allow("").required(),
2088
+ status: Joi.string().allow("").required(),
2089
+ total: Joi.number(),
2090
+ error_file_path: Joi.string().allow(""),
2091
+ });
2092
+ }
2093
+
2094
+ /** @returns {BulkRegionResponse} */
2095
+ static BulkRegionResponse() {
2096
+ return Joi.object({
2097
+ items: Joi.array()
2098
+ .items(ServiceabilityPlatformModel.BulkRegionResponseItemData())
2027
2099
  .required(),
2028
- errors: Joi.array().items(ServiceabilityPlatformModel.Error()),
2029
- page: ServiceabilityPlatformModel.PincodeCodStatusListingPage().required(),
2030
- success: Joi.boolean().required(),
2031
- summary: ServiceabilityPlatformModel.PincodeCodStatusListingSummary().required(),
2100
+ page: ServiceabilityPlatformModel.Page().required(),
2032
2101
  });
2033
2102
  }
2034
2103
 
2035
- /** @returns {PincodeCodStatusListingSummary} */
2036
- static PincodeCodStatusListingSummary() {
2104
+ /** @returns {SelfShipResponse} */
2105
+ static SelfShipResponse() {
2037
2106
  return Joi.object({
2038
- total_active_pincodes: Joi.number().required(),
2039
- total_inactive_pincodes: Joi.number().required(),
2107
+ is_active: Joi.boolean().required(),
2108
+ tat: Joi.number().required(),
2040
2109
  });
2041
2110
  }
2042
2111
 
2043
- /** @returns {PincodeMopBulkData} */
2044
- static PincodeMopBulkData() {
2112
+ /** @returns {ApplicationSelfShipConfig} */
2113
+ static ApplicationSelfShipConfig() {
2045
2114
  return Joi.object({
2046
- batch_id: Joi.string().allow("").required(),
2047
- s3_url: Joi.string().allow("").required(),
2115
+ self_ship: Joi.any().allow(null),
2048
2116
  });
2049
2117
  }
2050
2118
 
2051
- /** @returns {PincodeMopData} */
2052
- static PincodeMopData() {
2119
+ /** @returns {ApplicationSelfShipConfigResponse} */
2120
+ static ApplicationSelfShipConfigResponse() {
2053
2121
  return Joi.object({
2054
- action: Joi.string().allow("").required(),
2055
- country: Joi.string().allow("").required(),
2056
- pincodes: Joi.array().items(Joi.number()).required(),
2122
+ error: ServiceabilityPlatformModel.ServiceabilityErrorResponse(),
2123
+ data: ServiceabilityPlatformModel.ApplicationSelfShipConfig(),
2124
+ success: Joi.boolean().required(),
2057
2125
  });
2058
2126
  }
2059
2127
 
2060
- /** @returns {PincodeMOPresponse} */
2061
- static PincodeMOPresponse() {
2128
+ /** @returns {StoreRuleConfigData} */
2129
+ static StoreRuleConfigData() {
2062
2130
  return Joi.object({
2063
- action: Joi.string().allow("").required(),
2064
- batch_id: Joi.string().allow("").required(),
2065
- country: Joi.string().allow("").required(),
2066
- pincodes: Joi.array().items(Joi.number()),
2067
- status_code: Joi.number().required(),
2068
- success: Joi.boolean().required(),
2069
- updated_pincodes: Joi.array().items(
2070
- ServiceabilityPlatformModel.PincodeMopUpdateResponse()
2131
+ rule_ids: Joi.array().items(Joi.string().allow("")),
2132
+ type_based_priority: Joi.array().items(Joi.string().allow("")),
2133
+ tag_based_priority: Joi.array().items(Joi.string().allow("")),
2134
+ store_priority: Joi.array().items(
2135
+ ServiceabilityPlatformModel.StorePrioritySchema()
2071
2136
  ),
2137
+ sort: Joi.array().items(Joi.string().allow("")),
2072
2138
  });
2073
2139
  }
2074
2140
 
2075
- /** @returns {PincodeMopUpdateAuditHistoryPaging} */
2076
- static PincodeMopUpdateAuditHistoryPaging() {
2141
+ /** @returns {CustomerRadiusSchema} */
2142
+ static CustomerRadiusSchema() {
2077
2143
  return Joi.object({
2078
- current: Joi.number(),
2079
- has_next: Joi.boolean(),
2080
- item_total: Joi.number(),
2081
- size: Joi.number(),
2082
- type: Joi.string().allow(""),
2144
+ unit: Joi.string().allow("").required(),
2145
+ lt: Joi.number(),
2146
+ lte: Joi.number(),
2147
+ gt: Joi.number(),
2148
+ gte: Joi.number(),
2083
2149
  });
2084
2150
  }
2085
2151
 
2086
- /** @returns {PincodeMopUpdateAuditHistoryRequest} */
2087
- static PincodeMopUpdateAuditHistoryRequest() {
2152
+ /** @returns {StoreRuleConditionSchema} */
2153
+ static StoreRuleConditionSchema() {
2088
2154
  return Joi.object({
2089
- entity_type: Joi.string().allow("").required(),
2090
- file_name: Joi.string().allow(""),
2155
+ department_ids: ServiceabilityPlatformModel.IntComparisonOperations(),
2156
+ category_ids: ServiceabilityPlatformModel.IntComparisonOperations(),
2157
+ brand_ids: ServiceabilityPlatformModel.IntComparisonOperations(),
2158
+ to_location: ServiceabilityPlatformModel.LocationRule(),
2159
+ customer_radius: ServiceabilityPlatformModel.CustomerRadiusSchema(),
2160
+ store_type: ServiceabilityPlatformModel.StringComparisonOperations(),
2161
+ product_tags: ServiceabilityPlatformModel.StringComparisonOperations(),
2162
+ product_ids: ServiceabilityPlatformModel.IntComparisonOperations(),
2163
+ store_tags: ServiceabilityPlatformModel.StringComparisonOperations(),
2164
+ order_place_date: ServiceabilityPlatformModel.ArithmeticOperations(),
2165
+ zone_ids: ServiceabilityPlatformModel.StringComparisonOperations(),
2091
2166
  });
2092
2167
  }
2093
2168
 
2094
- /** @returns {PincodeMopUpdateAuditHistoryResponse} */
2095
- static PincodeMopUpdateAuditHistoryResponse() {
2169
+ /** @returns {StoreRuleDataSchema} */
2170
+ static StoreRuleDataSchema() {
2096
2171
  return Joi.object({
2097
- batch_id: Joi.string().allow(""),
2098
- entity_type: Joi.string().allow(""),
2099
- error_file_s3_url: Joi.string().allow(""),
2100
- file_name: Joi.string().allow(""),
2101
- s3_url: Joi.string().allow(""),
2102
- success: Joi.boolean(),
2103
- updated_at: Joi.string().allow(""),
2104
- updated_by: Joi.string().allow(""),
2172
+ id: Joi.string().allow(""),
2173
+ name: Joi.string().allow(""),
2174
+ company_id: Joi.number(),
2175
+ application_id: Joi.string().allow(""),
2176
+ type_based_priority: Joi.array().items(Joi.string().allow("")),
2177
+ tag_based_priority: Joi.array().items(Joi.string().allow("")),
2178
+ store_priority: Joi.array().items(
2179
+ ServiceabilityPlatformModel.StorePrioritySchema()
2180
+ ),
2181
+ sort: Joi.array().items(Joi.string().allow("")),
2182
+ conditions: ServiceabilityPlatformModel.StoreRuleConditionSchema(),
2183
+ is_active: Joi.boolean(),
2105
2184
  });
2106
2185
  }
2107
2186
 
2108
- /** @returns {PincodeMopUpdateAuditHistoryResponseData} */
2109
- static PincodeMopUpdateAuditHistoryResponseData() {
2187
+ /** @returns {StorePrioritySchema} */
2188
+ static StorePrioritySchema() {
2110
2189
  return Joi.object({
2111
- data: Joi.array()
2112
- .items(
2113
- ServiceabilityPlatformModel.PincodeMopUpdateAuditHistoryResponse()
2114
- )
2115
- .required(),
2116
- entity_type: Joi.string().allow(""),
2117
- page: ServiceabilityPlatformModel.PincodeMopUpdateAuditHistoryPaging().required(),
2190
+ id: Joi.string().allow(""),
2191
+ name: Joi.string().allow(""),
2118
2192
  });
2119
2193
  }
2120
2194
 
2121
- /** @returns {PincodeMopUpdateResponse} */
2122
- static PincodeMopUpdateResponse() {
2195
+ /** @returns {GetStoreRulesApiResponse} */
2196
+ static GetStoreRulesApiResponse() {
2123
2197
  return Joi.object({
2124
- channel_id: Joi.string().allow("").required(),
2125
- country: Joi.string().allow("").required(),
2126
- is_active: Joi.boolean().required(),
2127
- pincode: Joi.number().required(),
2198
+ items: Joi.array().items(
2199
+ ServiceabilityPlatformModel.StoreRuleDataSchema()
2200
+ ),
2201
+ page: ServiceabilityPlatformModel.Page(),
2128
2202
  });
2129
2203
  }
2130
2204
 
2131
- /** @returns {ProductReturnConfigResponse} */
2132
- static ProductReturnConfigResponse() {
2205
+ /** @returns {CreateStoreRuleRequestSchema} */
2206
+ static CreateStoreRuleRequestSchema() {
2133
2207
  return Joi.object({
2134
- on_same_store: Joi.boolean(),
2208
+ name: Joi.string().allow(""),
2209
+ is_active: Joi.boolean(),
2210
+ conditions: ServiceabilityPlatformModel.StoreRuleConditionSchema(),
2211
+ type_based_priority: Joi.array().items(Joi.string().allow("")),
2212
+ tag_based_priority: Joi.array().items(Joi.string().allow("")),
2213
+ store_priority: Joi.array().items(
2214
+ ServiceabilityPlatformModel.StorePrioritySchema()
2215
+ ),
2216
+ sort: Joi.array().items(Joi.string().allow("")),
2135
2217
  });
2136
2218
  }
2137
2219
 
2138
- /** @returns {ReAssignStoreRequest} */
2139
- static ReAssignStoreRequest() {
2220
+ /** @returns {StoreRuleResponseSchema} */
2221
+ static StoreRuleResponseSchema() {
2140
2222
  return Joi.object({
2141
- articles: Joi.array().items(Joi.any()).required(),
2142
- configuration: Joi.any().required(),
2143
- identifier: Joi.string().allow("").required(),
2144
- ignored_locations: Joi.array().items(Joi.string().allow("")).required(),
2145
- to_pincode: Joi.string().allow("").required(),
2223
+ id: Joi.string().allow(""),
2224
+ name: Joi.string().allow(""),
2225
+ type: Joi.string().allow(""),
2226
+ type_based_priority: Joi.array().items(Joi.string().allow("")),
2227
+ tag_based_priority: Joi.array().items(Joi.string().allow("")),
2228
+ store_priority: Joi.array().items(
2229
+ ServiceabilityPlatformModel.StorePrioritySchema()
2230
+ ),
2231
+ sort: Joi.array().items(Joi.string().allow("")),
2232
+ conditions: ServiceabilityPlatformModel.StoreRuleConditionSchema(),
2233
+ is_active: Joi.boolean(),
2146
2234
  });
2147
2235
  }
2148
2236
 
2149
- /** @returns {ReAssignStoreResponse} */
2150
- static ReAssignStoreResponse() {
2237
+ /** @returns {StoreRuleUpdateResponseSchema} */
2238
+ static StoreRuleUpdateResponseSchema() {
2151
2239
  return Joi.object({
2152
- articles: Joi.array().items(Joi.any()),
2153
- error: Joi.any().required(),
2154
- success: Joi.boolean().required(),
2155
- to_pincode: Joi.string().allow("").required(),
2240
+ id: Joi.string().allow(""),
2241
+ name: Joi.string().allow(""),
2242
+ type: Joi.string().allow(""),
2243
+ type_based_priority: Joi.array().items(Joi.string().allow("")),
2244
+ tag_based_priority: Joi.array().items(Joi.string().allow("")),
2245
+ store_priority: Joi.array().items(
2246
+ ServiceabilityPlatformModel.StorePrioritySchema()
2247
+ ),
2248
+ sort: Joi.array().items(Joi.string().allow("")),
2249
+ conditions: ServiceabilityPlatformModel.StoreRuleConditionSchema(),
2250
+ is_active: Joi.boolean(),
2251
+ company_id: Joi.number(),
2252
+ application_id: Joi.string().allow(""),
2156
2253
  });
2157
2254
  }
2158
2255
 
2159
- /** @returns {RulePriorityRequest} */
2160
- static RulePriorityRequest() {
2256
+ /** @returns {ServiceabilityModel} */
2257
+ static ServiceabilityModel() {
2161
2258
  return Joi.object({
2162
- priority: Joi.number().required(),
2163
- rule_id: Joi.string().allow("").required(),
2259
+ lm_cod_limit: Joi.number().required(),
2260
+ is_qc: Joi.boolean().required(),
2261
+ pickup_cutoff: Joi.string().allow("").allow(null).required(),
2262
+ route_code: Joi.string().allow("").allow(null).required(),
2263
+ is_first_mile: Joi.boolean().required(),
2264
+ is_return: Joi.boolean().required(),
2265
+ is_installation: Joi.boolean().required(),
2266
+ is_last_mile: Joi.boolean().required(),
2164
2267
  });
2165
2268
  }
2166
2269
 
2167
- /** @returns {RulePriorityResponse} */
2168
- static RulePriorityResponse() {
2270
+ /** @returns {CourierPartnerSchemeFeatures} */
2271
+ static CourierPartnerSchemeFeatures() {
2169
2272
  return Joi.object({
2170
- success: Joi.boolean(),
2273
+ doorstep_qc: Joi.boolean(),
2274
+ qr: Joi.boolean(),
2275
+ mps: Joi.boolean(),
2276
+ ndr: Joi.boolean(),
2277
+ ndr_attempts: Joi.number(),
2278
+ dangerous_goods: Joi.boolean(),
2279
+ fragile_goods: Joi.boolean(),
2280
+ restricted_goods: Joi.boolean(),
2281
+ cold_storage_goods: Joi.boolean(),
2282
+ doorstep_exchange: Joi.boolean(),
2283
+ doorstep_return: Joi.boolean(),
2284
+ product_installation: Joi.boolean(),
2285
+ openbox_delivery: Joi.boolean(),
2286
+ status_updates: Joi.string().allow(""),
2287
+ multi_pick_single_drop: Joi.boolean(),
2288
+ single_pick_multi_drop: Joi.boolean(),
2289
+ multi_pick_multi_drop: Joi.boolean(),
2290
+ ewaybill: Joi.boolean(),
2171
2291
  });
2172
2292
  }
2173
2293
 
2174
- /** @returns {SchemeRules} */
2175
- static SchemeRules() {
2294
+ /** @returns {CourierPartnerSchemeModel} */
2295
+ static CourierPartnerSchemeModel() {
2176
2296
  return Joi.object({
2177
- feature: ServiceabilityPlatformModel.SchemeRulesFeatures(),
2178
- payment_mode: Joi.array().items(Joi.string().allow("")),
2179
- region: Joi.string().allow(""),
2180
- transport_type: Joi.array().items(Joi.string().allow("")),
2181
- weight: ServiceabilityPlatformModel.ArithmeticOperations(),
2297
+ extension_id: Joi.string().allow("").required(),
2298
+ scheme_id: Joi.string().allow("").required(),
2299
+ weight: ServiceabilityPlatformModel.ArithmeticOperations().required(),
2300
+ transport_type: Joi.string().allow("").required(),
2301
+ region: Joi.string().allow("").required(),
2302
+ delivery_type: Joi.string().allow("").required(),
2303
+ payment_mode: Joi.array().items(Joi.string().allow("")).required(),
2304
+ stage: Joi.string().allow("").required(),
2305
+ feature: ServiceabilityPlatformModel.CourierPartnerSchemeFeatures().required(),
2182
2306
  });
2183
2307
  }
2184
2308
 
2185
- /** @returns {SchemeRulesFeatures} */
2186
- static SchemeRulesFeatures() {
2309
+ /** @returns {CourierAccountResponse} */
2310
+ static CourierAccountResponse() {
2187
2311
  return Joi.object({
2188
- battery_operated: Joi.boolean(),
2189
- e_waybill: Joi.boolean(),
2190
- flammable: Joi.boolean(),
2191
- hazmat: Joi.boolean(),
2192
- multi_part_shipments: Joi.boolean(),
2193
- quality_check: Joi.boolean(),
2194
- quick_response_code: Joi.boolean(),
2312
+ account_id: Joi.string().allow("").required(),
2313
+ scheme_id: Joi.string().allow("").required(),
2314
+ is_self_ship: Joi.boolean().required(),
2315
+ stage: Joi.string().allow("").required(),
2316
+ is_own_account: Joi.boolean().required(),
2317
+ scheme_rules: ServiceabilityPlatformModel.CourierPartnerSchemeModel().required(),
2195
2318
  });
2196
2319
  }
2197
2320
 
2198
- /** @returns {SelfShipResponse} */
2199
- static SelfShipResponse() {
2321
+ /** @returns {CompanyCourierPartnerAccountListResponse} */
2322
+ static CompanyCourierPartnerAccountListResponse() {
2200
2323
  return Joi.object({
2201
- is_active: Joi.boolean().required(),
2202
- tat: Joi.number().required(),
2324
+ items: Joi.array()
2325
+ .items(ServiceabilityPlatformModel.CourierAccountResponse())
2326
+ .required(),
2327
+ page: ServiceabilityPlatformModel.Page().required(),
2203
2328
  });
2204
2329
  }
2205
2330
 
2206
- /** @returns {ServiceabilityErrorResponse} */
2207
- static ServiceabilityErrorResponse() {
2331
+ /** @returns {PackageMaterial} */
2332
+ static PackageMaterial() {
2208
2333
  return Joi.object({
2209
- message: Joi.string().allow("").required(),
2210
- type: Joi.string().allow("").required(),
2211
- value: Joi.string().allow("").required(),
2334
+ name: Joi.string().allow("").required(),
2335
+ width: Joi.number().required(),
2336
+ height: Joi.number().required(),
2337
+ length: Joi.number().required(),
2338
+ rules: Joi.array().items(
2339
+ ServiceabilityPlatformModel.PackageMaterialRule()
2340
+ ),
2341
+ store_ids: Joi.array().items(Joi.number()).required(),
2342
+ weight: Joi.number().required(),
2343
+ error_rate: Joi.number().required(),
2344
+ package_type: Joi.string().allow("").required(),
2345
+ size: Joi.string().allow("").required(),
2346
+ media: Joi.array().items(Joi.string().allow("")),
2347
+ channels: Joi.array()
2348
+ .items(ServiceabilityPlatformModel.Channel())
2349
+ .required(),
2350
+ track_inventory: Joi.boolean(),
2351
+ status: Joi.string().allow("").required(),
2352
+ max_weight: Joi.number(),
2353
+ package_vol_weight: Joi.number(),
2354
+ auto_calculate: Joi.boolean(),
2212
2355
  });
2213
2356
  }
2214
2357
 
2215
- /** @returns {ServiceabilityModel} */
2216
- static ServiceabilityModel() {
2358
+ /** @returns {PackageMaterialResponse} */
2359
+ static PackageMaterialResponse() {
2217
2360
  return Joi.object({
2218
- is_first_mile: Joi.boolean().required(),
2219
- is_installation: Joi.boolean().required(),
2220
- is_last_mile: Joi.boolean().required(),
2221
- is_qc: Joi.boolean().required(),
2222
- is_return: Joi.boolean().required(),
2223
- lm_cod_limit: Joi.number().required(),
2224
- pickup_cutoff: Joi.string().allow("").allow(null).required(),
2225
- route_code: Joi.string().allow("").allow(null).required(),
2361
+ name: Joi.string().allow("").required(),
2362
+ id: Joi.string().allow(""),
2363
+ item_id: Joi.number(),
2364
+ width: Joi.number().required(),
2365
+ height: Joi.number().required(),
2366
+ length: Joi.number().required(),
2367
+ rules: Joi.array().items(
2368
+ ServiceabilityPlatformModel.PackageMaterialRule()
2369
+ ),
2370
+ store_ids: Joi.array().items(Joi.number()).required(),
2371
+ weight: Joi.number().required(),
2372
+ error_rate: Joi.number().required(),
2373
+ package_type: Joi.string().allow("").required(),
2374
+ size: Joi.string().allow("").required(),
2375
+ media: Joi.array().items(Joi.string().allow("")),
2376
+ channels: Joi.array()
2377
+ .items(ServiceabilityPlatformModel.Channel())
2378
+ .required(),
2379
+ track_inventory: Joi.boolean(),
2380
+ status: Joi.string().allow("").required(),
2381
+ max_weight: Joi.number(),
2382
+ package_vol_weight: Joi.number(),
2383
+ auto_calculate: Joi.boolean(),
2226
2384
  });
2227
2385
  }
2228
2386
 
2229
- /** @returns {ServiceabilityPageResponse} */
2230
- static ServiceabilityPageResponse() {
2387
+ /** @returns {PackageMaterialRule} */
2388
+ static PackageMaterialRule() {
2231
2389
  return Joi.object({
2232
- current: Joi.number(),
2233
- has_next: Joi.boolean(),
2234
- item_total: Joi.number(),
2235
- size: Joi.number(),
2236
- type: Joi.string().allow(""),
2390
+ rule_id: Joi.string().allow(""),
2391
+ quantity: ServiceabilityPlatformModel.PackageMaterialRuleQuantity(),
2392
+ weight: Joi.number(),
2237
2393
  });
2238
2394
  }
2239
2395
 
2240
- /** @returns {StorePrioritySchema} */
2241
- static StorePrioritySchema() {
2396
+ /** @returns {PackageRule} */
2397
+ static PackageRule() {
2242
2398
  return Joi.object({
2243
- id: Joi.string().allow(""),
2244
- name: Joi.string().allow(""),
2399
+ name: Joi.string().allow("").required(),
2400
+ company_id: Joi.number().required(),
2401
+ type: Joi.string().allow("").required(),
2402
+ is_active: Joi.boolean(),
2403
+ product_tag: ServiceabilityPlatformModel.PackageRuleProductTag(),
2404
+ product_id: ServiceabilityPlatformModel.PackageRuleProduct(),
2405
+ category_id: ServiceabilityPlatformModel.PackageRuleCategory(),
2245
2406
  });
2246
2407
  }
2247
2408
 
2248
- /** @returns {StoreRuleConditionSchema} */
2249
- static StoreRuleConditionSchema() {
2409
+ /** @returns {PackageRuleResponse} */
2410
+ static PackageRuleResponse() {
2250
2411
  return Joi.object({
2251
- brand_ids: ServiceabilityPlatformModel.IntComparisonOperations(),
2252
- category_ids: ServiceabilityPlatformModel.IntComparisonOperations(),
2253
- customer_radius: ServiceabilityPlatformModel.CustomerRadiusSchema(),
2254
- department_ids: ServiceabilityPlatformModel.IntComparisonOperations(),
2255
- order_place_date: ServiceabilityPlatformModel.ArithmeticOperations(),
2256
- product_ids: ServiceabilityPlatformModel.IntComparisonOperations(),
2257
- product_tags: ServiceabilityPlatformModel.StringComparisonOperations(),
2258
- store_tags: ServiceabilityPlatformModel.StringComparisonOperations(),
2259
- store_type: ServiceabilityPlatformModel.StringComparisonOperations(),
2260
- to_location: ServiceabilityPlatformModel.LocationRule(),
2261
- zone_ids: ServiceabilityPlatformModel.StringComparisonOperations(),
2412
+ id: Joi.string().allow(""),
2413
+ name: Joi.string().allow("").required(),
2414
+ company_id: Joi.number().required(),
2415
+ type: Joi.string().allow("").required(),
2416
+ is_active: Joi.boolean(),
2417
+ product_tag: ServiceabilityPlatformModel.PackageRuleProductTag(),
2418
+ product_id: ServiceabilityPlatformModel.PackageRuleProduct(),
2419
+ category_id: ServiceabilityPlatformModel.PackageRuleCategory(),
2262
2420
  });
2263
2421
  }
2264
2422
 
2265
- /** @returns {StoreRuleConfigData} */
2266
- static StoreRuleConfigData() {
2423
+ /** @returns {Channel} */
2424
+ static Channel() {
2267
2425
  return Joi.object({
2268
- rule_ids: Joi.array().items(Joi.string().allow("")),
2269
- sort: Joi.array().items(Joi.string().allow("")),
2270
- store_priority: Joi.array().items(
2271
- ServiceabilityPlatformModel.StorePrioritySchema()
2272
- ),
2273
- tag_based_priority: Joi.array().items(Joi.string().allow("")),
2274
- type_based_priority: Joi.array().items(Joi.string().allow("")),
2426
+ type: Joi.string().allow(""),
2427
+ id: Joi.string().allow(""),
2275
2428
  });
2276
2429
  }
2277
2430
 
2278
- /** @returns {StoreRuleDataSchema} */
2279
- static StoreRuleDataSchema() {
2431
+ /** @returns {PackageMaterialRuleList} */
2432
+ static PackageMaterialRuleList() {
2280
2433
  return Joi.object({
2281
- application_id: Joi.string().allow(""),
2282
- company_id: Joi.number(),
2283
- conditions: ServiceabilityPlatformModel.StoreRuleConditionSchema(),
2284
- id: Joi.string().allow(""),
2285
- is_active: Joi.boolean(),
2286
- name: Joi.string().allow(""),
2287
- sort: Joi.array().items(Joi.string().allow("")),
2288
- store_priority: Joi.array().items(
2289
- ServiceabilityPlatformModel.StorePrioritySchema()
2290
- ),
2291
- tag_based_priority: Joi.array().items(Joi.string().allow("")),
2292
- type_based_priority: Joi.array().items(Joi.string().allow("")),
2434
+ items: ServiceabilityPlatformModel.PackageRuleResponse(),
2435
+ page: ServiceabilityPlatformModel.Page(),
2293
2436
  });
2294
2437
  }
2295
2438
 
2296
- /** @returns {StoreRuleResponseSchema} */
2297
- static StoreRuleResponseSchema() {
2439
+ /** @returns {PackageMaterialList} */
2440
+ static PackageMaterialList() {
2298
2441
  return Joi.object({
2299
- conditions: ServiceabilityPlatformModel.StoreRuleConditionSchema(),
2300
- id: Joi.string().allow(""),
2301
- is_active: Joi.boolean(),
2302
- name: Joi.string().allow(""),
2303
- sort: Joi.array().items(Joi.string().allow("")),
2304
- store_priority: Joi.array().items(
2305
- ServiceabilityPlatformModel.StorePrioritySchema()
2306
- ),
2307
- tag_based_priority: Joi.array().items(Joi.string().allow("")),
2308
- type: Joi.string().allow(""),
2309
- type_based_priority: Joi.array().items(Joi.string().allow("")),
2442
+ items: ServiceabilityPlatformModel.PackageMaterialResponse(),
2443
+ page: ServiceabilityPlatformModel.Page(),
2310
2444
  });
2311
2445
  }
2312
2446
 
2313
- /** @returns {StoreRuleUpdateResponseSchema} */
2314
- static StoreRuleUpdateResponseSchema() {
2447
+ /** @returns {PackageRuleProduct} */
2448
+ static PackageRuleProduct() {
2315
2449
  return Joi.object({
2316
- application_id: Joi.string().allow(""),
2317
- company_id: Joi.number(),
2318
- conditions: ServiceabilityPlatformModel.StoreRuleConditionSchema(),
2319
- id: Joi.string().allow(""),
2320
- is_active: Joi.boolean(),
2321
- name: Joi.string().allow(""),
2322
- sort: Joi.array().items(Joi.string().allow("")),
2323
- store_priority: Joi.array().items(
2324
- ServiceabilityPlatformModel.StorePrioritySchema()
2325
- ),
2326
- tag_based_priority: Joi.array().items(Joi.string().allow("")),
2327
- type: Joi.string().allow(""),
2328
- type_based_priority: Joi.array().items(Joi.string().allow("")),
2450
+ includes: Joi.array().items(Joi.number()),
2329
2451
  });
2330
2452
  }
2331
2453
 
2332
- /** @returns {StringComparisonOperations} */
2333
- static StringComparisonOperations() {
2454
+ /** @returns {PackageRuleProductTag} */
2455
+ static PackageRuleProductTag() {
2334
2456
  return Joi.object({
2335
2457
  includes: Joi.array().items(Joi.string().allow("")),
2336
2458
  });
2337
2459
  }
2338
2460
 
2339
- /** @returns {TimmingResponse} */
2340
- static TimmingResponse() {
2461
+ /** @returns {PackageRuleCategory} */
2462
+ static PackageRuleCategory() {
2341
2463
  return Joi.object({
2342
- closing: ServiceabilityPlatformModel.OpeningClosing(),
2343
- open: Joi.boolean(),
2344
- opening: ServiceabilityPlatformModel.OpeningClosing(),
2345
- weekday: Joi.string().allow(""),
2464
+ includes: Joi.array().items(Joi.number()),
2346
2465
  });
2347
2466
  }
2348
2467
 
2349
- /** @returns {UpdateZoneConfigRequest} */
2350
- static UpdateZoneConfigRequest() {
2468
+ /** @returns {PackageMaterialRuleQuantity} */
2469
+ static PackageMaterialRuleQuantity() {
2351
2470
  return Joi.object({
2352
- serviceability_type: Joi.string().allow(""),
2471
+ min: Joi.number(),
2472
+ max: Joi.number(),
2353
2473
  });
2354
2474
  }
2355
2475
 
2356
- /** @returns {UpdateZoneData} */
2357
- static UpdateZoneData() {
2476
+ /** @returns {RulePriorityRequest} */
2477
+ static RulePriorityRequest() {
2358
2478
  return Joi.object({
2359
- assignment_preference: Joi.string().allow(""),
2360
- channels: Joi.array()
2361
- .items(ServiceabilityPlatformModel.GetZoneDataViewChannels())
2362
- .required(),
2363
- company_id: Joi.number().required(),
2364
- is_active: Joi.boolean().required(),
2365
- mapping: Joi.array()
2366
- .items(ServiceabilityPlatformModel.ZoneMappingType())
2367
- .required(),
2368
- name: Joi.string().allow("").required(),
2369
- product: ServiceabilityPlatformModel.ZoneProductTypes().required(),
2370
- region_type: Joi.string().allow("").required(),
2371
- slug: Joi.string().allow("").required(),
2372
- store_ids: Joi.array().items(Joi.number()).required(),
2373
- zone_id: Joi.string().allow("").required(),
2479
+ rule_id: Joi.string().allow("").required(),
2480
+ priority: Joi.number().required(),
2374
2481
  });
2375
2482
  }
2376
2483
 
2377
- /** @returns {WarningsResponse} */
2378
- static WarningsResponse() {
2484
+ /** @returns {RulePriorityResponse} */
2485
+ static RulePriorityResponse() {
2379
2486
  return Joi.object({
2380
- store_address: Joi.string().allow(""),
2487
+ success: Joi.boolean(),
2381
2488
  });
2382
2489
  }
2383
2490
 
2384
- /** @returns {Zone} */
2385
- static Zone() {
2491
+ /** @returns {ArticleAssignment} */
2492
+ static ArticleAssignment() {
2386
2493
  return Joi.object({
2387
- assignment_preference: Joi.string().allow("").required(),
2388
- is_active: Joi.boolean().required(),
2389
- name: Joi.string().allow("").required(),
2390
- slug: Joi.string().allow("").required(),
2391
- store_ids: Joi.array().items(Joi.number()).required(),
2392
- tags: Joi.array().items(Joi.string().allow("")).required(),
2393
- type: Joi.string().allow("").required(),
2394
- zone_id: Joi.string().allow("").required(),
2494
+ level: Joi.string().allow(""),
2495
+ strategy: Joi.string().allow(""),
2395
2496
  });
2396
2497
  }
2397
2498
 
2398
- /** @returns {ZoneConfig} */
2399
- static ZoneConfig() {
2499
+ /** @returns {ServiceabilityLocation} */
2500
+ static ServiceabilityLocation() {
2400
2501
  return Joi.object({
2401
- serviceability_type: Joi.string().allow(""),
2502
+ longitude: Joi.string().allow("").required(),
2503
+ latitude: Joi.string().allow("").required(),
2402
2504
  });
2403
2505
  }
2404
2506
 
2405
- /** @returns {ZoneDataItem} */
2406
- static ZoneDataItem() {
2507
+ /** @returns {LocationDetailsServiceability} */
2508
+ static LocationDetailsServiceability() {
2407
2509
  return Joi.object({
2408
- current: Joi.number().required(),
2409
- has_next: Joi.boolean().required(),
2410
- item_total: Joi.number().required(),
2411
- size: Joi.number().required(),
2412
- type: Joi.string().allow("").required(),
2510
+ pincode: Joi.string().allow(""),
2511
+ sector: Joi.string().allow(""),
2512
+ state: Joi.string().allow(""),
2513
+ country: Joi.string().allow("").required(),
2514
+ city: Joi.string().allow(""),
2515
+ country_iso_code: Joi.string().allow("").required(),
2516
+ location: ServiceabilityPlatformModel.ServiceabilityLocation(),
2413
2517
  });
2414
2518
  }
2415
2519
 
2416
- /** @returns {ZoneMappingType} */
2417
- static ZoneMappingType() {
2520
+ /** @returns {OptimalLocationsArticles} */
2521
+ static OptimalLocationsArticles() {
2418
2522
  return Joi.object({
2419
- country: Joi.string().allow("").required(),
2420
- pincode: Joi.array().items(Joi.string().allow("")),
2421
- state: Joi.array().items(Joi.string().allow("")),
2523
+ item_id: Joi.number().required(),
2524
+ size: Joi.string().allow("").required(),
2525
+ quantity: Joi.string().allow("").required(),
2526
+ group_id: Joi.string().allow(""),
2527
+ is_primary_item: Joi.boolean(),
2528
+ meta: Joi.any(),
2529
+ article_assignment: ServiceabilityPlatformModel.ArticleAssignment().required(),
2530
+ ignore_locations: Joi.array().items(Joi.number()).required(),
2531
+ assign_locations: Joi.array().items(Joi.number()).required(),
2532
+ seller_id: Joi.number(),
2422
2533
  });
2423
2534
  }
2424
2535
 
2425
- /** @returns {ZoneProductTypes} */
2426
- static ZoneProductTypes() {
2536
+ /** @returns {OptimlLocationsRequestSchema} */
2537
+ static OptimlLocationsRequestSchema() {
2427
2538
  return Joi.object({
2428
- tags: Joi.array().items(Joi.string().allow("")).required(),
2429
- type: Joi.string().allow("").required(),
2539
+ channel_id: Joi.string().allow("").required(),
2540
+ channel_type: Joi.string().allow("").required(),
2541
+ to_serviceability: ServiceabilityPlatformModel.LocationDetailsServiceability().required(),
2542
+ article: ServiceabilityPlatformModel.OptimalLocationsArticles(),
2430
2543
  });
2431
2544
  }
2432
2545
 
2433
- /** @returns {ZoneResponse} */
2434
- static ZoneResponse() {
2546
+ /** @returns {OptimalLocationArticlesResponse} */
2547
+ static OptimalLocationArticlesResponse() {
2435
2548
  return Joi.object({
2436
- status_code: Joi.number().required(),
2437
- success: Joi.boolean().required(),
2438
- zone_id: Joi.string().allow("").required(),
2549
+ item_id: Joi.number().required(),
2550
+ size: Joi.string().allow("").required(),
2551
+ quantity: Joi.number().required(),
2552
+ group_id: Joi.string().allow(""),
2553
+ is_primary_item: Joi.boolean(),
2554
+ meta: Joi.any(),
2555
+ article_assignment: ServiceabilityPlatformModel.ArticleAssignment().required(),
2556
+ seller_id: Joi.number(),
2557
+ ignore_locations: Joi.array().items(Joi.number()).required(),
2558
+ assign_locations: Joi.array().items(Joi.number()).required(),
2559
+ price_effective: Joi.number().required(),
2560
+ mto_quantity: Joi.number().required(),
2561
+ _id: Joi.string().allow("").required(),
2562
+ uid: Joi.string().allow("").required(),
2439
2563
  });
2440
2564
  }
2441
2565
 
2442
- /** @returns {ZoneSuccessResponse} */
2443
- static ZoneSuccessResponse() {
2566
+ /** @returns {OptimalLocationAssignedStoresResponse} */
2567
+ static OptimalLocationAssignedStoresResponse() {
2444
2568
  return Joi.object({
2445
- status_code: Joi.number().required(),
2446
- success: Joi.boolean().required(),
2569
+ store_id: Joi.number().required(),
2570
+ articles: Joi.array()
2571
+ .items(ServiceabilityPlatformModel.OptimalLocationArticlesResponse())
2572
+ .required(),
2447
2573
  });
2448
2574
  }
2449
2575
 
2450
- /** @returns {ZoneUpdateRequest} */
2451
- static ZoneUpdateRequest() {
2576
+ /** @returns {OptimalLocationsResponse} */
2577
+ static OptimalLocationsResponse() {
2452
2578
  return Joi.object({
2453
- data: ServiceabilityPlatformModel.UpdateZoneData().required(),
2454
- identifier: Joi.string().allow("").required(),
2579
+ assigned_stores: Joi.array()
2580
+ .items(
2581
+ ServiceabilityPlatformModel.OptimalLocationAssignedStoresResponse()
2582
+ )
2583
+ .required(),
2455
2584
  });
2456
2585
  }
2457
2586
  }