@gofynd/fdk-client-javascript 1.6.3 → 2.0.0
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.
- package/README.md +1 -1
- package/package.json +1 -1
- package/sdk/application/Cart/CartApplicationClient.d.ts +5 -5
- package/sdk/application/Cart/CartApplicationClient.js +26 -268
- package/sdk/application/Catalog/CatalogApplicationClient.d.ts +20 -20
- package/sdk/application/Catalog/CatalogApplicationClient.js +98 -347
- package/sdk/application/Common/CommonApplicationClient.js +1 -16
- package/sdk/application/Communication/CommunicationApplicationClient.js +1 -24
- package/sdk/application/Configuration/ConfigurationApplicationClient.d.ts +24 -2
- package/sdk/application/Configuration/ConfigurationApplicationClient.js +58 -137
- package/sdk/application/Content/ContentApplicationClient.d.ts +47 -7
- package/sdk/application/Content/ContentApplicationClient.js +222 -191
- package/sdk/application/FileStorage/FileStorageApplicationClient.d.ts +2 -2
- package/sdk/application/FileStorage/FileStorageApplicationClient.js +11 -30
- package/sdk/application/Finance/FinanceApplicationClient.js +1 -16
- package/sdk/application/Lead/LeadApplicationClient.d.ts +4 -4
- package/sdk/application/Lead/LeadApplicationClient.js +21 -52
- package/sdk/application/Logistic/LogisticApplicationClient.d.ts +16 -56
- package/sdk/application/Logistic/LogisticApplicationClient.js +57 -332
- package/sdk/application/Order/OrderApplicationClient.d.ts +11 -11
- package/sdk/application/Order/OrderApplicationClient.js +68 -153
- package/sdk/application/Payment/PaymentApplicationClient.d.ts +2 -12
- package/sdk/application/Payment/PaymentApplicationClient.js +7 -487
- package/sdk/application/Rewards/RewardsApplicationClient.d.ts +1 -1
- package/sdk/application/Rewards/RewardsApplicationClient.js +6 -59
- package/sdk/application/Share/ShareApplicationClient.d.ts +4 -4
- package/sdk/application/Share/ShareApplicationClient.js +21 -75
- package/sdk/application/Theme/ThemeApplicationClient.d.ts +3 -3
- package/sdk/application/Theme/ThemeApplicationClient.js +19 -47
- package/sdk/application/User/UserApplicationClient.js +1 -407
- package/sdk/application/Webhook/WebhookApplicationClient.js +1 -8
- package/sdk/common/Utility.d.ts +1 -1
- package/sdk/common/Utility.js +4 -4
- package/sdk/common/Validator.d.ts +1 -0
- package/sdk/common/Validator.js +20 -0
- package/sdk/partner/FileStorage/FileStoragePartnerClient.d.ts +1 -55
- package/sdk/partner/FileStorage/FileStoragePartnerClient.js +1 -408
- package/sdk/partner/FileStorage/FileStoragePartnerValidator.d.ts +0 -5
- package/sdk/partner/FileStorage/FileStoragePartnerValidator.js +0 -37
- package/sdk/partner/Lead/LeadPartnerModel.d.ts +5 -0
- package/sdk/partner/Lead/LeadPartnerModel.js +2 -0
- package/sdk/partner/Logistics/LogisticsPartnerClient.d.ts +29 -25
- package/sdk/partner/Logistics/LogisticsPartnerClient.js +65 -42
- package/sdk/partner/Logistics/LogisticsPartnerModel.d.ts +1008 -794
- package/sdk/partner/Logistics/LogisticsPartnerModel.js +573 -460
- package/sdk/partner/Logistics/LogisticsPartnerValidator.js +10 -5
- package/sdk/partner/Webhook/WebhookPartnerModel.d.ts +64 -1
- package/sdk/partner/Webhook/WebhookPartnerModel.js +36 -0
- package/sdk/platform/Analytics/AnalyticsPlatformModel.d.ts +5 -0
- package/sdk/platform/Analytics/AnalyticsPlatformModel.js +2 -0
- package/sdk/platform/Cart/CartPlatformModel.d.ts +67 -9
- package/sdk/platform/Cart/CartPlatformModel.js +38 -5
- package/sdk/platform/Catalog/CatalogPlatformApplicationClient.js +1 -1
- package/sdk/platform/Catalog/CatalogPlatformClient.js +4 -4
- package/sdk/platform/Catalog/CatalogPlatformModel.d.ts +47 -13
- package/sdk/platform/Catalog/CatalogPlatformModel.js +29 -7
- package/sdk/platform/Communication/CommunicationPlatformApplicationClient.d.ts +2 -2
- package/sdk/platform/Communication/CommunicationPlatformApplicationClient.js +7 -4
- package/sdk/platform/Communication/CommunicationPlatformModel.d.ts +71 -7
- package/sdk/platform/Communication/CommunicationPlatformModel.js +70 -6
- package/sdk/platform/CompanyProfile/CompanyProfilePlatformClient.d.ts +0 -27
- package/sdk/platform/CompanyProfile/CompanyProfilePlatformClient.js +8 -60
- package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.d.ts +31 -20
- package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.js +18 -18
- package/sdk/platform/Configuration/ConfigurationPlatformApplicationClient.d.ts +1 -1
- package/sdk/platform/Configuration/ConfigurationPlatformApplicationClient.js +3 -3
- package/sdk/platform/Configuration/ConfigurationPlatformClient.d.ts +13 -0
- package/sdk/platform/Configuration/ConfigurationPlatformClient.js +30 -1
- package/sdk/platform/Configuration/ConfigurationPlatformModel.d.ts +68 -11
- package/sdk/platform/Configuration/ConfigurationPlatformModel.js +49 -7
- package/sdk/platform/Content/ContentPlatformApplicationClient.d.ts +169 -0
- package/sdk/platform/Content/ContentPlatformApplicationClient.js +1279 -132
- package/sdk/platform/Content/ContentPlatformApplicationValidator.d.ts +156 -1
- package/sdk/platform/Content/ContentPlatformApplicationValidator.js +180 -0
- package/sdk/platform/Content/ContentPlatformClient.d.ts +162 -0
- package/sdk/platform/Content/ContentPlatformClient.js +1697 -497
- package/sdk/platform/Content/ContentPlatformModel.d.ts +1053 -35
- package/sdk/platform/Content/ContentPlatformModel.js +717 -34
- package/sdk/platform/Content/ContentPlatformValidator.d.ts +127 -1
- package/sdk/platform/Content/ContentPlatformValidator.js +171 -0
- package/sdk/platform/Discount/DiscountPlatformClient.d.ts +34 -0
- package/sdk/platform/Discount/DiscountPlatformClient.js +59 -0
- package/sdk/platform/Discount/DiscountPlatformModel.d.ts +365 -93
- package/sdk/platform/Discount/DiscountPlatformModel.js +98 -93
- package/sdk/platform/Discount/DiscountPlatformValidator.d.ts +54 -34
- package/sdk/platform/Discount/DiscountPlatformValidator.js +27 -17
- package/sdk/platform/FileStorage/FileStoragePlatformApplicationClient.d.ts +0 -156
- package/sdk/platform/FileStorage/FileStoragePlatformApplicationClient.js +0 -1072
- package/sdk/platform/FileStorage/FileStoragePlatformApplicationValidator.d.ts +1 -137
- package/sdk/platform/FileStorage/FileStoragePlatformApplicationValidator.js +0 -173
- package/sdk/platform/FileStorage/FileStoragePlatformModel.d.ts +1 -1105
- package/sdk/platform/FileStorage/FileStoragePlatformModel.js +0 -1125
- package/sdk/platform/Lead/LeadPlatformModel.d.ts +5 -0
- package/sdk/platform/Lead/LeadPlatformModel.js +2 -0
- package/sdk/platform/Order/OrderPlatformApplicationClient.d.ts +0 -10
- package/sdk/platform/Order/OrderPlatformApplicationClient.js +0 -92
- package/sdk/platform/Order/OrderPlatformApplicationValidator.d.ts +1 -28
- package/sdk/platform/Order/OrderPlatformApplicationValidator.js +0 -18
- package/sdk/platform/Order/OrderPlatformClient.d.ts +212 -0
- package/sdk/platform/Order/OrderPlatformClient.js +397 -0
- package/sdk/platform/Order/OrderPlatformModel.d.ts +66 -10
- package/sdk/platform/Order/OrderPlatformModel.js +39 -7
- package/sdk/platform/Order/OrderPlatformValidator.d.ts +33 -1
- package/sdk/platform/Order/OrderPlatformValidator.js +20 -0
- package/sdk/platform/Partner/PartnerPlatformModel.d.ts +58 -10
- package/sdk/platform/Partner/PartnerPlatformModel.js +19 -10
- package/sdk/platform/Payment/PaymentPlatformModel.d.ts +12 -2
- package/sdk/platform/Payment/PaymentPlatformModel.js +8 -2
- package/sdk/platform/Rewards/RewardsPlatformModel.d.ts +5 -0
- package/sdk/platform/Rewards/RewardsPlatformModel.js +2 -0
- package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationClient.d.ts +240 -24
- package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationClient.js +1753 -277
- package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationValidator.d.ts +320 -22
- package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationValidator.js +269 -19
- package/sdk/platform/Serviceability/ServiceabilityPlatformClient.d.ts +53 -104
- package/sdk/platform/Serviceability/ServiceabilityPlatformClient.js +201 -629
- package/sdk/platform/Serviceability/ServiceabilityPlatformModel.d.ts +5720 -2891
- package/sdk/platform/Serviceability/ServiceabilityPlatformModel.js +3414 -2181
- package/sdk/platform/Serviceability/ServiceabilityPlatformValidator.d.ts +138 -216
- package/sdk/platform/Serviceability/ServiceabilityPlatformValidator.js +81 -148
- package/sdk/platform/Share/SharePlatformModel.d.ts +5 -0
- package/sdk/platform/Share/SharePlatformModel.js +2 -0
- package/sdk/platform/User/UserPlatformApplicationClient.d.ts +73 -0
- package/sdk/platform/User/UserPlatformApplicationClient.js +543 -0
- package/sdk/platform/User/UserPlatformApplicationValidator.d.ts +129 -1
- package/sdk/platform/User/UserPlatformApplicationValidator.js +97 -0
- package/sdk/platform/User/UserPlatformModel.d.ts +269 -6
- package/sdk/platform/User/UserPlatformModel.js +187 -5
- package/sdk/platform/Webhook/WebhookPlatformModel.d.ts +64 -1
- package/sdk/platform/Webhook/WebhookPlatformModel.js +36 -0
- package/sdk/public/Catalog/CatalogPublicClient.d.ts +1 -1
- package/sdk/public/Catalog/CatalogPublicClient.js +6 -11
- package/sdk/public/Configuration/ConfigurationPublicClient.js +1 -16
- package/sdk/public/Content/ContentPublicClient.d.ts +36 -3
- package/sdk/public/Content/ContentPublicClient.js +261 -104
- package/sdk/public/Content/ContentPublicModel.d.ts +155 -1
- package/sdk/public/Content/ContentPublicModel.js +102 -0
- package/sdk/public/Content/ContentPublicValidator.d.ts +18 -1
- package/sdk/public/Content/ContentPublicValidator.js +26 -0
- package/sdk/public/Partner/PartnerPublicClient.d.ts +1 -1
- package/sdk/public/Partner/PartnerPublicClient.js +6 -11
- package/sdk/public/Partner/PartnerPublicModel.d.ts +248 -72
- package/sdk/public/Partner/PartnerPublicModel.js +81 -71
- package/sdk/public/Partner/PartnerPublicValidator.d.ts +2 -2
- package/sdk/public/Partner/PartnerPublicValidator.js +1 -1
- package/sdk/public/Webhook/WebhookPublicClient.js +1 -40
|
@@ -84,7 +84,7 @@ class LogisticsValidator {
|
|
|
84
84
|
courierPartnerExtensionId: Joi.string().allow("").required(),
|
|
85
85
|
schemeId: Joi.string().allow("").required(),
|
|
86
86
|
id: Joi.string().allow("").required(),
|
|
87
|
-
body: LogisticsModel.
|
|
87
|
+
body: LogisticsModel.TATUpdateDetails().required(),
|
|
88
88
|
}).required();
|
|
89
89
|
}
|
|
90
90
|
|
|
@@ -193,6 +193,10 @@ class LogisticsValidator {
|
|
|
193
193
|
stage: Joi.string().allow(""),
|
|
194
194
|
paymentMode: Joi.string().allow(""),
|
|
195
195
|
transportType: Joi.string().allow(""),
|
|
196
|
+
accountIds: Joi.array().items(Joi.string().allow("")),
|
|
197
|
+
selfShip: Joi.boolean(),
|
|
198
|
+
ownAccount: Joi.boolean(),
|
|
199
|
+
q: Joi.string().allow(""),
|
|
196
200
|
}).required();
|
|
197
201
|
}
|
|
198
202
|
|
|
@@ -200,7 +204,7 @@ class LogisticsValidator {
|
|
|
200
204
|
return Joi.object({
|
|
201
205
|
companyId: Joi.number().required(),
|
|
202
206
|
accountId: Joi.string().allow("").required(),
|
|
203
|
-
body: LogisticsModel.
|
|
207
|
+
body: LogisticsModel.CourierAccountDetailsBody().required(),
|
|
204
208
|
}).required();
|
|
205
209
|
}
|
|
206
210
|
|
|
@@ -213,16 +217,17 @@ class LogisticsValidator {
|
|
|
213
217
|
|
|
214
218
|
static getCountries() {
|
|
215
219
|
return Joi.object({
|
|
216
|
-
|
|
220
|
+
onboard: Joi.boolean(),
|
|
217
221
|
pageNo: Joi.number(),
|
|
218
222
|
pageSize: Joi.number(),
|
|
219
223
|
q: Joi.string().allow(""),
|
|
224
|
+
hierarchy: Joi.string().allow(""),
|
|
220
225
|
}).required();
|
|
221
226
|
}
|
|
222
227
|
|
|
223
228
|
static createCourierPartnerScheme() {
|
|
224
229
|
return Joi.object({
|
|
225
|
-
body: LogisticsModel.
|
|
230
|
+
body: LogisticsModel.CourierPartnerSchemeDetailsModel().required(),
|
|
226
231
|
}).required();
|
|
227
232
|
}
|
|
228
233
|
|
|
@@ -238,7 +243,7 @@ class LogisticsValidator {
|
|
|
238
243
|
static updateCourierPartnerScheme() {
|
|
239
244
|
return Joi.object({
|
|
240
245
|
schemeId: Joi.string().allow("").required(),
|
|
241
|
-
body: LogisticsModel.
|
|
246
|
+
body: LogisticsModel.CourierPartnerSchemeUpdateDetails().required(),
|
|
242
247
|
}).required();
|
|
243
248
|
}
|
|
244
249
|
|
|
@@ -44,10 +44,31 @@ export = WebhookPartnerModel;
|
|
|
44
44
|
* the subscriber.
|
|
45
45
|
* @property {number} [subscriber_id] - The identifier for the subscriber
|
|
46
46
|
* involved in the mapping.
|
|
47
|
+
* @property {FilterSchema} [filters]
|
|
48
|
+
* @property {Object} [reducer] - The reducer property allows users to customize
|
|
49
|
+
* the JSON structure of the webhook payload using JSONPath queries. They can
|
|
50
|
+
* also create new properties by mapping existing ones. Note that it overrides
|
|
51
|
+
* the entire JSON structure of the webhook payload sent via the webhook. See
|
|
52
|
+
* the partner documentation's filter and reducer section for details.
|
|
47
53
|
* @property {BroadcasterConfig} [broadcaster_config]
|
|
48
54
|
* @property {string} [created_on] - The timestamp indicating when the
|
|
49
55
|
* subscriber event mapping was created.
|
|
50
56
|
*/
|
|
57
|
+
/**
|
|
58
|
+
* @typedef FilterSchema
|
|
59
|
+
* @property {string} [query] - JSONPath expression that specifies the property
|
|
60
|
+
* in the webhook payload to filter on. This enables targeting specific data
|
|
61
|
+
* within the payload.
|
|
62
|
+
* @property {string} [condition] - JavaScript function used to evaluate the
|
|
63
|
+
* specified property in the webhook payload against a condition. This
|
|
64
|
+
* function determines whether the filter passes based on its return value.
|
|
65
|
+
* @property {string} [logic] - Logical operator used to combine multiple
|
|
66
|
+
* conditions in the `conditions` array. Supported values are `AND` and `OR`.
|
|
67
|
+
* @property {Object[]} [conditions] - An array of filter objects to be
|
|
68
|
+
* evaluated using the specified logical operator. This array will contain
|
|
69
|
+
* more filters including a combination of single condition mode and logical
|
|
70
|
+
* group mode filters.
|
|
71
|
+
*/
|
|
51
72
|
/**
|
|
52
73
|
* @typedef EventConfigDetails
|
|
53
74
|
* @property {number} [id] - The unique identifier for the event configuration.
|
|
@@ -235,6 +256,7 @@ export = WebhookPartnerModel;
|
|
|
235
256
|
* @property {number} [current] - The current page number.
|
|
236
257
|
* @property {string} type - The type of the page, such as 'PageType'.
|
|
237
258
|
* @property {number} [size] - The number of items per page.
|
|
259
|
+
* @property {number} [page_size] - The number of items per page.
|
|
238
260
|
*/
|
|
239
261
|
/**
|
|
240
262
|
* @typedef DeliveryEventLevelSchema
|
|
@@ -300,7 +322,7 @@ export = WebhookPartnerModel;
|
|
|
300
322
|
declare class WebhookPartnerModel {
|
|
301
323
|
}
|
|
302
324
|
declare namespace WebhookPartnerModel {
|
|
303
|
-
export { SubscriberUpdate, SubscriberUpdateResult, Association, AuthMeta, BroadcasterConfig, SubscriberEventMapping, EventConfigDetails, SubscriberConfigDetails, InvalidEventsPayload, InvalidEventsResult, HistoryFilters, Url, CdnObject, UploadServiceObject, HistoryAssociation, HistoryItems, HistoryResult, HistoryPayload, CancelDownloadResult, FilterReportResult, DeliveryTsResult, DeliveryTsSchema, DeliveryDetailsPayload, EventDeliveryDetailSchema, DeliveryDetailsResult, EventProcessReportObject, Page, DeliveryEventLevelSchema, ResponseTimeTs, AvgResponseTime, DeliverySummaryResult, DeliverySummarySchema, ItemSchema };
|
|
325
|
+
export { SubscriberUpdate, SubscriberUpdateResult, Association, AuthMeta, BroadcasterConfig, SubscriberEventMapping, FilterSchema, EventConfigDetails, SubscriberConfigDetails, InvalidEventsPayload, InvalidEventsResult, HistoryFilters, Url, CdnObject, UploadServiceObject, HistoryAssociation, HistoryItems, HistoryResult, HistoryPayload, CancelDownloadResult, FilterReportResult, DeliveryTsResult, DeliveryTsSchema, DeliveryDetailsPayload, EventDeliveryDetailSchema, DeliveryDetailsResult, EventProcessReportObject, Page, DeliveryEventLevelSchema, ResponseTimeTs, AvgResponseTime, DeliverySummaryResult, DeliverySummarySchema, ItemSchema };
|
|
304
326
|
}
|
|
305
327
|
/** @returns {SubscriberUpdate} */
|
|
306
328
|
declare function SubscriberUpdate(): SubscriberUpdate;
|
|
@@ -404,6 +426,15 @@ type SubscriberEventMapping = {
|
|
|
404
426
|
* involved in the mapping.
|
|
405
427
|
*/
|
|
406
428
|
subscriber_id?: number;
|
|
429
|
+
filters?: FilterSchema;
|
|
430
|
+
/**
|
|
431
|
+
* - The reducer property allows users to customize
|
|
432
|
+
* the JSON structure of the webhook payload using JSONPath queries. They can
|
|
433
|
+
* also create new properties by mapping existing ones. Note that it overrides
|
|
434
|
+
* the entire JSON structure of the webhook payload sent via the webhook. See
|
|
435
|
+
* the partner documentation's filter and reducer section for details.
|
|
436
|
+
*/
|
|
437
|
+
reducer?: any;
|
|
407
438
|
broadcaster_config?: BroadcasterConfig;
|
|
408
439
|
/**
|
|
409
440
|
* - The timestamp indicating when the
|
|
@@ -411,6 +442,34 @@ type SubscriberEventMapping = {
|
|
|
411
442
|
*/
|
|
412
443
|
created_on?: string;
|
|
413
444
|
};
|
|
445
|
+
/** @returns {FilterSchema} */
|
|
446
|
+
declare function FilterSchema(): FilterSchema;
|
|
447
|
+
type FilterSchema = {
|
|
448
|
+
/**
|
|
449
|
+
* - JSONPath expression that specifies the property
|
|
450
|
+
* in the webhook payload to filter on. This enables targeting specific data
|
|
451
|
+
* within the payload.
|
|
452
|
+
*/
|
|
453
|
+
query?: string;
|
|
454
|
+
/**
|
|
455
|
+
* - JavaScript function used to evaluate the
|
|
456
|
+
* specified property in the webhook payload against a condition. This
|
|
457
|
+
* function determines whether the filter passes based on its return value.
|
|
458
|
+
*/
|
|
459
|
+
condition?: string;
|
|
460
|
+
/**
|
|
461
|
+
* - Logical operator used to combine multiple
|
|
462
|
+
* conditions in the `conditions` array. Supported values are `AND` and `OR`.
|
|
463
|
+
*/
|
|
464
|
+
logic?: string;
|
|
465
|
+
/**
|
|
466
|
+
* - An array of filter objects to be
|
|
467
|
+
* evaluated using the specified logical operator. This array will contain
|
|
468
|
+
* more filters including a combination of single condition mode and logical
|
|
469
|
+
* group mode filters.
|
|
470
|
+
*/
|
|
471
|
+
conditions?: any[];
|
|
472
|
+
};
|
|
414
473
|
/** @returns {EventConfigDetails} */
|
|
415
474
|
declare function EventConfigDetails(): EventConfigDetails;
|
|
416
475
|
type EventConfigDetails = {
|
|
@@ -874,6 +933,10 @@ type Page = {
|
|
|
874
933
|
* - The number of items per page.
|
|
875
934
|
*/
|
|
876
935
|
size?: number;
|
|
936
|
+
/**
|
|
937
|
+
* - The number of items per page.
|
|
938
|
+
*/
|
|
939
|
+
page_size?: number;
|
|
877
940
|
};
|
|
878
941
|
/** @returns {DeliveryEventLevelSchema} */
|
|
879
942
|
declare function DeliveryEventLevelSchema(): DeliveryEventLevelSchema;
|
|
@@ -50,11 +50,33 @@ const Joi = require("joi");
|
|
|
50
50
|
* the subscriber.
|
|
51
51
|
* @property {number} [subscriber_id] - The identifier for the subscriber
|
|
52
52
|
* involved in the mapping.
|
|
53
|
+
* @property {FilterSchema} [filters]
|
|
54
|
+
* @property {Object} [reducer] - The reducer property allows users to customize
|
|
55
|
+
* the JSON structure of the webhook payload using JSONPath queries. They can
|
|
56
|
+
* also create new properties by mapping existing ones. Note that it overrides
|
|
57
|
+
* the entire JSON structure of the webhook payload sent via the webhook. See
|
|
58
|
+
* the partner documentation's filter and reducer section for details.
|
|
53
59
|
* @property {BroadcasterConfig} [broadcaster_config]
|
|
54
60
|
* @property {string} [created_on] - The timestamp indicating when the
|
|
55
61
|
* subscriber event mapping was created.
|
|
56
62
|
*/
|
|
57
63
|
|
|
64
|
+
/**
|
|
65
|
+
* @typedef FilterSchema
|
|
66
|
+
* @property {string} [query] - JSONPath expression that specifies the property
|
|
67
|
+
* in the webhook payload to filter on. This enables targeting specific data
|
|
68
|
+
* within the payload.
|
|
69
|
+
* @property {string} [condition] - JavaScript function used to evaluate the
|
|
70
|
+
* specified property in the webhook payload against a condition. This
|
|
71
|
+
* function determines whether the filter passes based on its return value.
|
|
72
|
+
* @property {string} [logic] - Logical operator used to combine multiple
|
|
73
|
+
* conditions in the `conditions` array. Supported values are `AND` and `OR`.
|
|
74
|
+
* @property {Object[]} [conditions] - An array of filter objects to be
|
|
75
|
+
* evaluated using the specified logical operator. This array will contain
|
|
76
|
+
* more filters including a combination of single condition mode and logical
|
|
77
|
+
* group mode filters.
|
|
78
|
+
*/
|
|
79
|
+
|
|
58
80
|
/**
|
|
59
81
|
* @typedef EventConfigDetails
|
|
60
82
|
* @property {number} [id] - The unique identifier for the event configuration.
|
|
@@ -262,6 +284,7 @@ const Joi = require("joi");
|
|
|
262
284
|
* @property {number} [current] - The current page number.
|
|
263
285
|
* @property {string} type - The type of the page, such as 'PageType'.
|
|
264
286
|
* @property {number} [size] - The number of items per page.
|
|
287
|
+
* @property {number} [page_size] - The number of items per page.
|
|
265
288
|
*/
|
|
266
289
|
|
|
267
290
|
/**
|
|
@@ -382,11 +405,23 @@ class WebhookPartnerModel {
|
|
|
382
405
|
id: Joi.number(),
|
|
383
406
|
event_id: Joi.number(),
|
|
384
407
|
subscriber_id: Joi.number(),
|
|
408
|
+
filters: WebhookPartnerModel.FilterSchema(),
|
|
409
|
+
reducer: Joi.object().pattern(/\S/, Joi.any()).allow(null, ""),
|
|
385
410
|
broadcaster_config: WebhookPartnerModel.BroadcasterConfig(),
|
|
386
411
|
created_on: Joi.string().allow(""),
|
|
387
412
|
});
|
|
388
413
|
}
|
|
389
414
|
|
|
415
|
+
/** @returns {FilterSchema} */
|
|
416
|
+
static FilterSchema() {
|
|
417
|
+
return Joi.object({
|
|
418
|
+
query: Joi.string().allow(""),
|
|
419
|
+
condition: Joi.string().allow(""),
|
|
420
|
+
logic: Joi.string().allow(""),
|
|
421
|
+
conditions: Joi.array().items(Joi.object().pattern(/\S/, Joi.any())),
|
|
422
|
+
}).allow(null);
|
|
423
|
+
}
|
|
424
|
+
|
|
390
425
|
/** @returns {EventConfigDetails} */
|
|
391
426
|
static EventConfigDetails() {
|
|
392
427
|
return Joi.object({
|
|
@@ -603,6 +638,7 @@ class WebhookPartnerModel {
|
|
|
603
638
|
current: Joi.number(),
|
|
604
639
|
type: Joi.string().allow("").required(),
|
|
605
640
|
size: Joi.number(),
|
|
641
|
+
page_size: Joi.number(),
|
|
606
642
|
});
|
|
607
643
|
}
|
|
608
644
|
|
|
@@ -8,6 +8,7 @@ export = AnalyticsPlatformModel;
|
|
|
8
8
|
* @property {number} [current] - The current page number.
|
|
9
9
|
* @property {string} type - The type of the page, such as 'PageType'.
|
|
10
10
|
* @property {number} [size] - The number of items per page.
|
|
11
|
+
* @property {number} [page_size] - The number of items per page.
|
|
11
12
|
*/
|
|
12
13
|
/**
|
|
13
14
|
* @typedef FileDownloadRequestBody
|
|
@@ -71,6 +72,10 @@ type Page = {
|
|
|
71
72
|
* - The number of items per page.
|
|
72
73
|
*/
|
|
73
74
|
size?: number;
|
|
75
|
+
/**
|
|
76
|
+
* - The number of items per page.
|
|
77
|
+
*/
|
|
78
|
+
page_size?: number;
|
|
74
79
|
};
|
|
75
80
|
/** @returns {FileDownloadRequestBody} */
|
|
76
81
|
declare function FileDownloadRequestBody(): FileDownloadRequestBody;
|
|
@@ -9,6 +9,7 @@ const Joi = require("joi");
|
|
|
9
9
|
* @property {number} [current] - The current page number.
|
|
10
10
|
* @property {string} type - The type of the page, such as 'PageType'.
|
|
11
11
|
* @property {number} [size] - The number of items per page.
|
|
12
|
+
* @property {number} [page_size] - The number of items per page.
|
|
12
13
|
*/
|
|
13
14
|
|
|
14
15
|
/**
|
|
@@ -52,6 +53,7 @@ class AnalyticsPlatformModel {
|
|
|
52
53
|
current: Joi.number(),
|
|
53
54
|
type: Joi.string().allow("").required(),
|
|
54
55
|
size: Joi.number(),
|
|
56
|
+
page_size: Joi.number(),
|
|
55
57
|
});
|
|
56
58
|
}
|
|
57
59
|
|
|
@@ -191,6 +191,7 @@ export = CartPlatformModel;
|
|
|
191
191
|
* @property {number} [current] - The current page number.
|
|
192
192
|
* @property {string} type - The type of the page, such as 'PageType'.
|
|
193
193
|
* @property {number} [size] - The number of items per page.
|
|
194
|
+
* @property {number} [page_size] - The number of items per page.
|
|
194
195
|
*/
|
|
195
196
|
/**
|
|
196
197
|
* @typedef CouponsResult
|
|
@@ -661,6 +662,8 @@ export = CartPlatformModel;
|
|
|
661
662
|
* @property {number} [quantity] - Total quantity of the article to be
|
|
662
663
|
* considered (currently used only in discount type)
|
|
663
664
|
* @property {Object} [meta] - Meta data related to article
|
|
665
|
+
* @property {boolean} [allowed_refund] - Flag indicating whether refunds are
|
|
666
|
+
* allowed at article level
|
|
664
667
|
*/
|
|
665
668
|
/**
|
|
666
669
|
* @typedef PriceAdjustmentRestrictions
|
|
@@ -686,7 +689,7 @@ export = CartPlatformModel;
|
|
|
686
689
|
* @property {Collection} collection
|
|
687
690
|
* @property {string} type - Type of price adjusment like charge, mop, discount etc.
|
|
688
691
|
* @property {boolean} [allowed_refund] - Flag indicating whether refunds are
|
|
689
|
-
* allowed
|
|
692
|
+
* allowed at cart level
|
|
690
693
|
* @property {boolean} is_authenticated - Flag indicating whether the user is
|
|
691
694
|
* authenticated
|
|
692
695
|
* @property {Article[]} article_ids - The list of article object in the price adjustment
|
|
@@ -710,7 +713,7 @@ export = CartPlatformModel;
|
|
|
710
713
|
* @property {Collection} collection
|
|
711
714
|
* @property {string} type - Type of price adjusment like charge, discount, mop etc.
|
|
712
715
|
* @property {boolean} [allowed_refund] - Flag indicating whether refunds are
|
|
713
|
-
* allowed
|
|
716
|
+
* allowed at cart level
|
|
714
717
|
* @property {boolean} is_authenticated - Flag indicating whether the user is
|
|
715
718
|
* authenticated
|
|
716
719
|
* @property {Article[]} article_ids - The list of article object in the price adjustment
|
|
@@ -742,7 +745,7 @@ export = CartPlatformModel;
|
|
|
742
745
|
* @property {Collection} collection
|
|
743
746
|
* @property {string} type - Type of price adjusment
|
|
744
747
|
* @property {boolean} [allowed_refund] - Flag indicating whether refunds are
|
|
745
|
-
* allowed
|
|
748
|
+
* allowed at cart level
|
|
746
749
|
* @property {boolean} is_authenticated - Flag indicating whether the user is
|
|
747
750
|
* authenticated
|
|
748
751
|
* @property {Article[]} article_ids - The list of article object in the price adjustment
|
|
@@ -1000,6 +1003,8 @@ export = CartPlatformModel;
|
|
|
1000
1003
|
* @property {BuyRules[]} [buy_rules] - Buy rules for promotions
|
|
1001
1004
|
* @property {string} [offer_text] - Offer text of current promotion
|
|
1002
1005
|
* @property {number} [amount] - Per unit discount amount applied with current promotion
|
|
1006
|
+
* @property {string} [float_amount] - Per unit discount amount with decimal
|
|
1007
|
+
* values applied with current promotion.
|
|
1003
1008
|
* @property {string} [promotion_type] - Promotion type of current promotion
|
|
1004
1009
|
* @property {boolean} [mrp_promotion] - If applied promotion is applied on
|
|
1005
1010
|
* product MRP or ESP
|
|
@@ -1053,6 +1058,16 @@ export = CartPlatformModel;
|
|
|
1053
1058
|
* @property {ProductPrice} [converted]
|
|
1054
1059
|
* @property {ProductPrice} [base]
|
|
1055
1060
|
*/
|
|
1061
|
+
/**
|
|
1062
|
+
* @typedef ProductMaxQuantityInfo
|
|
1063
|
+
* @property {number} [item] - The total quantity of the item available across
|
|
1064
|
+
* all stores for all sellers. If no data is available, this field will be null.
|
|
1065
|
+
* @property {number} [item_seller] - The total quantity of the item available
|
|
1066
|
+
* across all stores for the specified seller. If no seller data is available,
|
|
1067
|
+
* this field will be null.
|
|
1068
|
+
* @property {number} [item_store] - The total quantity of the item available
|
|
1069
|
+
* for a specific store. If no store data is available, this field will be null.
|
|
1070
|
+
*/
|
|
1056
1071
|
/**
|
|
1057
1072
|
* @typedef CartProductIdentifer
|
|
1058
1073
|
* @property {string} [identifier] - Article idenfier generated by cart
|
|
@@ -1108,6 +1123,7 @@ export = CartPlatformModel;
|
|
|
1108
1123
|
* @property {ProductAvailability} [availability]
|
|
1109
1124
|
* @property {Object} [moq] - An Integer indication the Minimum Order Quantity
|
|
1110
1125
|
* of a product, e.g. 100.
|
|
1126
|
+
* @property {ProductMaxQuantityInfo} [max_quantity]
|
|
1111
1127
|
* @property {ProductPriceInfo} [price_per_unit]
|
|
1112
1128
|
* @property {PromoMeta} [promo_meta]
|
|
1113
1129
|
* @property {Object} [custom_order] - Whether MTO (Make to Order) is enabled or not.
|
|
@@ -1791,6 +1807,8 @@ export = CartPlatformModel;
|
|
|
1791
1807
|
*/
|
|
1792
1808
|
/**
|
|
1793
1809
|
* @typedef PlatformGetAddressesDetails
|
|
1810
|
+
* @property {boolean} [pii_masking] - Personally Identifiable Information
|
|
1811
|
+
* masking flag to denote if the user data in address is masked or not.
|
|
1794
1812
|
* @property {PlatformAddress[]} [address] - List of all address saved by customer
|
|
1795
1813
|
* @property {ValidationConfig} [validation_config]
|
|
1796
1814
|
*/
|
|
@@ -2179,7 +2197,7 @@ export = CartPlatformModel;
|
|
|
2179
2197
|
* customer address, customer phone, customer email, customer pincode,
|
|
2180
2198
|
* customer landmark and customer name
|
|
2181
2199
|
* @property {string} [callback_url] - Callback url after payment received/failed
|
|
2182
|
-
* @property {string} user_id - The user id of user cart
|
|
2200
|
+
* @property {string} [user_id] - The user id of user cart
|
|
2183
2201
|
* @property {Object} [extra_meta] - Extra meta to be added while checkout in order
|
|
2184
2202
|
* @property {string} order_type - Order type of the order being placed like
|
|
2185
2203
|
* pickAtStore or HomeDelivery
|
|
@@ -2290,7 +2308,7 @@ export = CartPlatformModel;
|
|
|
2290
2308
|
declare class CartPlatformModel {
|
|
2291
2309
|
}
|
|
2292
2310
|
declare namespace CartPlatformModel {
|
|
2293
|
-
export { CouponDateMeta, Ownership, CouponAuthor, State, PaymentAllowValue, PaymentModes, PriceRange, PostOrder, BulkBundleRestriction, UsesRemaining, UsesRestriction, Restrictions, Validation, CouponAction, CouponSchedule, Rule, DisplayMetaDict, DisplayMeta, Identifier, Validity, RuleDefinition, CouponAdd, Page, CouponsResult, SuccessMessage, OperationErrorResult, CouponUpdate, CouponPartialUpdate, CouponCreateResult, DisplayMeta1, Ownership1, CompareObject, ItemSizeMapping, ItemCriteria, DiscountOffer, DiscountRule, PaymentAllowValue1, PromotionPaymentModes, UserRegistered, PostOrder1, UsesRemaining1, UsesRestriction1, Restrictions1, PromotionSchedule, PromotionAction, PromotionAuthor, Visibility, PromotionDateMeta, PromotionListItem, PromotionsResult, PromotionAdd, PromotionAddResult, PromotionUpdate, PromotionUpdateResult, PromotionPartialUpdate, ActivePromosResult, Charges, DeliveryCharges, CartMetaConfigUpdate, CartMetaConfigAdd, Article, PriceAdjustmentRestrictions, Collection, PriceAdjustmentUpdate, PriceAdjustment, PriceAdjustmentResult, GetPriceAdjustmentResult, PriceAdjustmentAdd, DistributionRule, Distribution, DistributionLogic, CartItem, OpenapiCartDetailsCreation, CouponBreakup, DisplayBreakup, LoyaltyPoints, RawBreakup, CartBreakup, ProductImage, Tags, BaseInfo, ActionQuery, ProductActionParams, ProductActionPage, ProductAction, CategoryInfo, CartProduct, BasePrice, ArticlePriceInfo, StoreInfo, ProductArticle, Ownership2, DiscountRulesApp, AppliedFreeArticles, BuyRules, AppliedPromotion, PromiseFormatted, PromiseISOFormat, PromiseTimestamp, ShipmentPromise, CouponDetails, ProductPrice, ProductPriceInfo, CartProductIdentifer, ProductAvailabilitySize, ProductAvailability, PromoMeta, CartProductInfo, OpenapiCartDetailsResult, OpenApiErrorResult, ShippingAddress, OpenApiCartServiceabilityCreation, OpenApiCartServiceabilityResult, OpenApiFiles, CartItemMeta, MultiTenderPaymentMeta, MultiTenderPaymentMethod, OpenApiOrderItem, OpenApiPlatformCheckoutReq, OpenApiCheckoutResult, AbandonedCart, AbandonedCartResult, PaymentSelectionLock, CartCurrency, CartDetailCoupon, ChargesThreshold, DeliveryChargesConfig, CartCommonConfig, CartDetailResult, AddProductCart, AddCartCreation, AddCartDetailResult, CartItemInfo, UpdateProductCart, FreeGiftItemCreation, UpdateCartCreation, UpdateCartDetailResult, OverrideCartItemPromo, OverrideCartItem, OverrideCheckoutReq, OverrideCheckoutResult, GetShareCartLinkCreation, GetShareCartLinkResult, SharedCartDetails, SharedCart, SharedCartResult, CartList, MultiCartResult, UpdateUserCartMapping, UserInfo, UserCartMappingResult, PlatformAddCartDetails, PlatformUpdateCartDetails, DeleteCartDetails, DeleteCartDetailResult, CartItemCountResult, Coupon, PageCoupon, GetCouponResult, ApplyCouponDetails, GeoLocation, PlatformAddress, ValidationConfig, PlatformGetAddressesDetails, SaveAddressDetails, UpdateAddressDetails, DeleteAddressResult, PlatformSelectCartAddress, ShipmentArticle, PlatformShipmentDetails, PlatformCartShipmentsResult, UpdateCartShipmentItem, UpdateCartShipmentCreation, PlatformCartMetaCreation, CartMetaDetails, CartMetaMissingDetails, StaffCheckout, CustomerDetails, Files, CartCheckoutCustomMeta, OrderTag, PlatformCartCheckoutDetailCreation, CheckCart, CartCheckoutDetails, CartCheckoutResult, CartDeliveryModesDetails, PickupStoreDetail, StoreDetails, CartPaymentUpdate, CouponValidity, PaymentCouponValidate, PaymentMeta, PaymentMethod, PlatformCartCheckoutDetailV2Creation, UpdateCartPaymentRequestV2, PriceMinMax, ItemPriceDetails, ArticlePriceDetails, FreeGiftItems, PromotionOffer, PromotionOffersDetails, PromotionPaymentOffer, PromotionPaymentOffersDetails, ValidationError };
|
|
2311
|
+
export { CouponDateMeta, Ownership, CouponAuthor, State, PaymentAllowValue, PaymentModes, PriceRange, PostOrder, BulkBundleRestriction, UsesRemaining, UsesRestriction, Restrictions, Validation, CouponAction, CouponSchedule, Rule, DisplayMetaDict, DisplayMeta, Identifier, Validity, RuleDefinition, CouponAdd, Page, CouponsResult, SuccessMessage, OperationErrorResult, CouponUpdate, CouponPartialUpdate, CouponCreateResult, DisplayMeta1, Ownership1, CompareObject, ItemSizeMapping, ItemCriteria, DiscountOffer, DiscountRule, PaymentAllowValue1, PromotionPaymentModes, UserRegistered, PostOrder1, UsesRemaining1, UsesRestriction1, Restrictions1, PromotionSchedule, PromotionAction, PromotionAuthor, Visibility, PromotionDateMeta, PromotionListItem, PromotionsResult, PromotionAdd, PromotionAddResult, PromotionUpdate, PromotionUpdateResult, PromotionPartialUpdate, ActivePromosResult, Charges, DeliveryCharges, CartMetaConfigUpdate, CartMetaConfigAdd, Article, PriceAdjustmentRestrictions, Collection, PriceAdjustmentUpdate, PriceAdjustment, PriceAdjustmentResult, GetPriceAdjustmentResult, PriceAdjustmentAdd, DistributionRule, Distribution, DistributionLogic, CartItem, OpenapiCartDetailsCreation, CouponBreakup, DisplayBreakup, LoyaltyPoints, RawBreakup, CartBreakup, ProductImage, Tags, BaseInfo, ActionQuery, ProductActionParams, ProductActionPage, ProductAction, CategoryInfo, CartProduct, BasePrice, ArticlePriceInfo, StoreInfo, ProductArticle, Ownership2, DiscountRulesApp, AppliedFreeArticles, BuyRules, AppliedPromotion, PromiseFormatted, PromiseISOFormat, PromiseTimestamp, ShipmentPromise, CouponDetails, ProductPrice, ProductPriceInfo, ProductMaxQuantityInfo, CartProductIdentifer, ProductAvailabilitySize, ProductAvailability, PromoMeta, CartProductInfo, OpenapiCartDetailsResult, OpenApiErrorResult, ShippingAddress, OpenApiCartServiceabilityCreation, OpenApiCartServiceabilityResult, OpenApiFiles, CartItemMeta, MultiTenderPaymentMeta, MultiTenderPaymentMethod, OpenApiOrderItem, OpenApiPlatformCheckoutReq, OpenApiCheckoutResult, AbandonedCart, AbandonedCartResult, PaymentSelectionLock, CartCurrency, CartDetailCoupon, ChargesThreshold, DeliveryChargesConfig, CartCommonConfig, CartDetailResult, AddProductCart, AddCartCreation, AddCartDetailResult, CartItemInfo, UpdateProductCart, FreeGiftItemCreation, UpdateCartCreation, UpdateCartDetailResult, OverrideCartItemPromo, OverrideCartItem, OverrideCheckoutReq, OverrideCheckoutResult, GetShareCartLinkCreation, GetShareCartLinkResult, SharedCartDetails, SharedCart, SharedCartResult, CartList, MultiCartResult, UpdateUserCartMapping, UserInfo, UserCartMappingResult, PlatformAddCartDetails, PlatformUpdateCartDetails, DeleteCartDetails, DeleteCartDetailResult, CartItemCountResult, Coupon, PageCoupon, GetCouponResult, ApplyCouponDetails, GeoLocation, PlatformAddress, ValidationConfig, PlatformGetAddressesDetails, SaveAddressDetails, UpdateAddressDetails, DeleteAddressResult, PlatformSelectCartAddress, ShipmentArticle, PlatformShipmentDetails, PlatformCartShipmentsResult, UpdateCartShipmentItem, UpdateCartShipmentCreation, PlatformCartMetaCreation, CartMetaDetails, CartMetaMissingDetails, StaffCheckout, CustomerDetails, Files, CartCheckoutCustomMeta, OrderTag, PlatformCartCheckoutDetailCreation, CheckCart, CartCheckoutDetails, CartCheckoutResult, CartDeliveryModesDetails, PickupStoreDetail, StoreDetails, CartPaymentUpdate, CouponValidity, PaymentCouponValidate, PaymentMeta, PaymentMethod, PlatformCartCheckoutDetailV2Creation, UpdateCartPaymentRequestV2, PriceMinMax, ItemPriceDetails, ArticlePriceDetails, FreeGiftItems, PromotionOffer, PromotionOffersDetails, PromotionPaymentOffer, PromotionPaymentOffersDetails, ValidationError };
|
|
2294
2312
|
}
|
|
2295
2313
|
/** @returns {CouponDateMeta} */
|
|
2296
2314
|
declare function CouponDateMeta(): CouponDateMeta;
|
|
@@ -2765,6 +2783,10 @@ type Page = {
|
|
|
2765
2783
|
* - The number of items per page.
|
|
2766
2784
|
*/
|
|
2767
2785
|
size?: number;
|
|
2786
|
+
/**
|
|
2787
|
+
* - The number of items per page.
|
|
2788
|
+
*/
|
|
2789
|
+
page_size?: number;
|
|
2768
2790
|
};
|
|
2769
2791
|
/** @returns {CouponsResult} */
|
|
2770
2792
|
declare function CouponsResult(): CouponsResult;
|
|
@@ -3912,6 +3934,11 @@ type Article = {
|
|
|
3912
3934
|
* - Meta data related to article
|
|
3913
3935
|
*/
|
|
3914
3936
|
meta?: any;
|
|
3937
|
+
/**
|
|
3938
|
+
* - Flag indicating whether refunds are
|
|
3939
|
+
* allowed at article level
|
|
3940
|
+
*/
|
|
3941
|
+
allowed_refund?: boolean;
|
|
3915
3942
|
};
|
|
3916
3943
|
/** @returns {PriceAdjustmentRestrictions} */
|
|
3917
3944
|
declare function PriceAdjustmentRestrictions(): PriceAdjustmentRestrictions;
|
|
@@ -3971,7 +3998,7 @@ type PriceAdjustmentUpdate = {
|
|
|
3971
3998
|
type: string;
|
|
3972
3999
|
/**
|
|
3973
4000
|
* - Flag indicating whether refunds are
|
|
3974
|
-
* allowed
|
|
4001
|
+
* allowed at cart level
|
|
3975
4002
|
*/
|
|
3976
4003
|
allowed_refund?: boolean;
|
|
3977
4004
|
/**
|
|
@@ -4035,7 +4062,7 @@ type PriceAdjustment = {
|
|
|
4035
4062
|
type: string;
|
|
4036
4063
|
/**
|
|
4037
4064
|
* - Flag indicating whether refunds are
|
|
4038
|
-
* allowed
|
|
4065
|
+
* allowed at cart level
|
|
4039
4066
|
*/
|
|
4040
4067
|
allowed_refund?: boolean;
|
|
4041
4068
|
/**
|
|
@@ -4109,7 +4136,7 @@ type PriceAdjustmentAdd = {
|
|
|
4109
4136
|
type: string;
|
|
4110
4137
|
/**
|
|
4111
4138
|
* - Flag indicating whether refunds are
|
|
4112
|
-
* allowed
|
|
4139
|
+
* allowed at cart level
|
|
4113
4140
|
*/
|
|
4114
4141
|
allowed_refund?: boolean;
|
|
4115
4142
|
/**
|
|
@@ -4745,6 +4772,11 @@ type AppliedPromotion = {
|
|
|
4745
4772
|
* - Per unit discount amount applied with current promotion
|
|
4746
4773
|
*/
|
|
4747
4774
|
amount?: number;
|
|
4775
|
+
/**
|
|
4776
|
+
* - Per unit discount amount with decimal
|
|
4777
|
+
* values applied with current promotion.
|
|
4778
|
+
*/
|
|
4779
|
+
float_amount?: string;
|
|
4748
4780
|
/**
|
|
4749
4781
|
* - Promotion type of current promotion
|
|
4750
4782
|
*/
|
|
@@ -4868,6 +4900,26 @@ type ProductPriceInfo = {
|
|
|
4868
4900
|
converted?: ProductPrice;
|
|
4869
4901
|
base?: ProductPrice;
|
|
4870
4902
|
};
|
|
4903
|
+
/** @returns {ProductMaxQuantityInfo} */
|
|
4904
|
+
declare function ProductMaxQuantityInfo(): ProductMaxQuantityInfo;
|
|
4905
|
+
type ProductMaxQuantityInfo = {
|
|
4906
|
+
/**
|
|
4907
|
+
* - The total quantity of the item available across
|
|
4908
|
+
* all stores for all sellers. If no data is available, this field will be null.
|
|
4909
|
+
*/
|
|
4910
|
+
item?: number;
|
|
4911
|
+
/**
|
|
4912
|
+
* - The total quantity of the item available
|
|
4913
|
+
* across all stores for the specified seller. If no seller data is available,
|
|
4914
|
+
* this field will be null.
|
|
4915
|
+
*/
|
|
4916
|
+
item_seller?: number;
|
|
4917
|
+
/**
|
|
4918
|
+
* - The total quantity of the item available
|
|
4919
|
+
* for a specific store. If no store data is available, this field will be null.
|
|
4920
|
+
*/
|
|
4921
|
+
item_store?: number;
|
|
4922
|
+
};
|
|
4871
4923
|
/** @returns {CartProductIdentifer} */
|
|
4872
4924
|
declare function CartProductIdentifer(): CartProductIdentifer;
|
|
4873
4925
|
type CartProductIdentifer = {
|
|
@@ -4994,6 +5046,7 @@ type CartProductInfo = {
|
|
|
4994
5046
|
* of a product, e.g. 100.
|
|
4995
5047
|
*/
|
|
4996
5048
|
moq?: any;
|
|
5049
|
+
max_quantity?: ProductMaxQuantityInfo;
|
|
4997
5050
|
price_per_unit?: ProductPriceInfo;
|
|
4998
5051
|
promo_meta?: PromoMeta;
|
|
4999
5052
|
/**
|
|
@@ -6822,6 +6875,11 @@ type ValidationConfig = {
|
|
|
6822
6875
|
/** @returns {PlatformGetAddressesDetails} */
|
|
6823
6876
|
declare function PlatformGetAddressesDetails(): PlatformGetAddressesDetails;
|
|
6824
6877
|
type PlatformGetAddressesDetails = {
|
|
6878
|
+
/**
|
|
6879
|
+
* - Personally Identifiable Information
|
|
6880
|
+
* masking flag to denote if the user data in address is masked or not.
|
|
6881
|
+
*/
|
|
6882
|
+
pii_masking?: boolean;
|
|
6825
6883
|
/**
|
|
6826
6884
|
* - List of all address saved by customer
|
|
6827
6885
|
*/
|
|
@@ -7774,7 +7832,7 @@ type PlatformCartCheckoutDetailV2Creation = {
|
|
|
7774
7832
|
/**
|
|
7775
7833
|
* - The user id of user cart
|
|
7776
7834
|
*/
|
|
7777
|
-
user_id
|
|
7835
|
+
user_id?: string;
|
|
7778
7836
|
/**
|
|
7779
7837
|
* - Extra meta to be added while checkout in order
|
|
7780
7838
|
*/
|
|
@@ -214,6 +214,7 @@ const Joi = require("joi");
|
|
|
214
214
|
* @property {number} [current] - The current page number.
|
|
215
215
|
* @property {string} type - The type of the page, such as 'PageType'.
|
|
216
216
|
* @property {number} [size] - The number of items per page.
|
|
217
|
+
* @property {number} [page_size] - The number of items per page.
|
|
217
218
|
*/
|
|
218
219
|
|
|
219
220
|
/**
|
|
@@ -722,6 +723,8 @@ const Joi = require("joi");
|
|
|
722
723
|
* @property {number} [quantity] - Total quantity of the article to be
|
|
723
724
|
* considered (currently used only in discount type)
|
|
724
725
|
* @property {Object} [meta] - Meta data related to article
|
|
726
|
+
* @property {boolean} [allowed_refund] - Flag indicating whether refunds are
|
|
727
|
+
* allowed at article level
|
|
725
728
|
*/
|
|
726
729
|
|
|
727
730
|
/**
|
|
@@ -750,7 +753,7 @@ const Joi = require("joi");
|
|
|
750
753
|
* @property {Collection} collection
|
|
751
754
|
* @property {string} type - Type of price adjusment like charge, mop, discount etc.
|
|
752
755
|
* @property {boolean} [allowed_refund] - Flag indicating whether refunds are
|
|
753
|
-
* allowed
|
|
756
|
+
* allowed at cart level
|
|
754
757
|
* @property {boolean} is_authenticated - Flag indicating whether the user is
|
|
755
758
|
* authenticated
|
|
756
759
|
* @property {Article[]} article_ids - The list of article object in the price adjustment
|
|
@@ -775,7 +778,7 @@ const Joi = require("joi");
|
|
|
775
778
|
* @property {Collection} collection
|
|
776
779
|
* @property {string} type - Type of price adjusment like charge, discount, mop etc.
|
|
777
780
|
* @property {boolean} [allowed_refund] - Flag indicating whether refunds are
|
|
778
|
-
* allowed
|
|
781
|
+
* allowed at cart level
|
|
779
782
|
* @property {boolean} is_authenticated - Flag indicating whether the user is
|
|
780
783
|
* authenticated
|
|
781
784
|
* @property {Article[]} article_ids - The list of article object in the price adjustment
|
|
@@ -810,7 +813,7 @@ const Joi = require("joi");
|
|
|
810
813
|
* @property {Collection} collection
|
|
811
814
|
* @property {string} type - Type of price adjusment
|
|
812
815
|
* @property {boolean} [allowed_refund] - Flag indicating whether refunds are
|
|
813
|
-
* allowed
|
|
816
|
+
* allowed at cart level
|
|
814
817
|
* @property {boolean} is_authenticated - Flag indicating whether the user is
|
|
815
818
|
* authenticated
|
|
816
819
|
* @property {Article[]} article_ids - The list of article object in the price adjustment
|
|
@@ -1096,6 +1099,8 @@ const Joi = require("joi");
|
|
|
1096
1099
|
* @property {BuyRules[]} [buy_rules] - Buy rules for promotions
|
|
1097
1100
|
* @property {string} [offer_text] - Offer text of current promotion
|
|
1098
1101
|
* @property {number} [amount] - Per unit discount amount applied with current promotion
|
|
1102
|
+
* @property {string} [float_amount] - Per unit discount amount with decimal
|
|
1103
|
+
* values applied with current promotion.
|
|
1099
1104
|
* @property {string} [promotion_type] - Promotion type of current promotion
|
|
1100
1105
|
* @property {boolean} [mrp_promotion] - If applied promotion is applied on
|
|
1101
1106
|
* product MRP or ESP
|
|
@@ -1157,6 +1162,17 @@ const Joi = require("joi");
|
|
|
1157
1162
|
* @property {ProductPrice} [base]
|
|
1158
1163
|
*/
|
|
1159
1164
|
|
|
1165
|
+
/**
|
|
1166
|
+
* @typedef ProductMaxQuantityInfo
|
|
1167
|
+
* @property {number} [item] - The total quantity of the item available across
|
|
1168
|
+
* all stores for all sellers. If no data is available, this field will be null.
|
|
1169
|
+
* @property {number} [item_seller] - The total quantity of the item available
|
|
1170
|
+
* across all stores for the specified seller. If no seller data is available,
|
|
1171
|
+
* this field will be null.
|
|
1172
|
+
* @property {number} [item_store] - The total quantity of the item available
|
|
1173
|
+
* for a specific store. If no store data is available, this field will be null.
|
|
1174
|
+
*/
|
|
1175
|
+
|
|
1160
1176
|
/**
|
|
1161
1177
|
* @typedef CartProductIdentifer
|
|
1162
1178
|
* @property {string} [identifier] - Article idenfier generated by cart
|
|
@@ -1216,6 +1232,7 @@ const Joi = require("joi");
|
|
|
1216
1232
|
* @property {ProductAvailability} [availability]
|
|
1217
1233
|
* @property {Object} [moq] - An Integer indication the Minimum Order Quantity
|
|
1218
1234
|
* of a product, e.g. 100.
|
|
1235
|
+
* @property {ProductMaxQuantityInfo} [max_quantity]
|
|
1219
1236
|
* @property {ProductPriceInfo} [price_per_unit]
|
|
1220
1237
|
* @property {PromoMeta} [promo_meta]
|
|
1221
1238
|
* @property {Object} [custom_order] - Whether MTO (Make to Order) is enabled or not.
|
|
@@ -1955,6 +1972,8 @@ const Joi = require("joi");
|
|
|
1955
1972
|
|
|
1956
1973
|
/**
|
|
1957
1974
|
* @typedef PlatformGetAddressesDetails
|
|
1975
|
+
* @property {boolean} [pii_masking] - Personally Identifiable Information
|
|
1976
|
+
* masking flag to denote if the user data in address is masked or not.
|
|
1958
1977
|
* @property {PlatformAddress[]} [address] - List of all address saved by customer
|
|
1959
1978
|
* @property {ValidationConfig} [validation_config]
|
|
1960
1979
|
*/
|
|
@@ -2373,7 +2392,7 @@ const Joi = require("joi");
|
|
|
2373
2392
|
* customer address, customer phone, customer email, customer pincode,
|
|
2374
2393
|
* customer landmark and customer name
|
|
2375
2394
|
* @property {string} [callback_url] - Callback url after payment received/failed
|
|
2376
|
-
* @property {string} user_id - The user id of user cart
|
|
2395
|
+
* @property {string} [user_id] - The user id of user cart
|
|
2377
2396
|
* @property {Object} [extra_meta] - Extra meta to be added while checkout in order
|
|
2378
2397
|
* @property {string} order_type - Order type of the order being placed like
|
|
2379
2398
|
* pickAtStore or HomeDelivery
|
|
@@ -2739,6 +2758,7 @@ class CartPlatformModel {
|
|
|
2739
2758
|
current: Joi.number(),
|
|
2740
2759
|
type: Joi.string().allow("").required(),
|
|
2741
2760
|
size: Joi.number(),
|
|
2761
|
+
page_size: Joi.number(),
|
|
2742
2762
|
});
|
|
2743
2763
|
}
|
|
2744
2764
|
|
|
@@ -3261,6 +3281,7 @@ class CartPlatformModel {
|
|
|
3261
3281
|
article_id: Joi.string().allow("").required(),
|
|
3262
3282
|
quantity: Joi.number(),
|
|
3263
3283
|
meta: Joi.object().pattern(/\S/, Joi.any()),
|
|
3284
|
+
allowed_refund: Joi.boolean(),
|
|
3264
3285
|
});
|
|
3265
3286
|
}
|
|
3266
3287
|
|
|
@@ -3651,6 +3672,7 @@ class CartPlatformModel {
|
|
|
3651
3672
|
buy_rules: Joi.array().items(CartPlatformModel.BuyRules()),
|
|
3652
3673
|
offer_text: Joi.string().allow(""),
|
|
3653
3674
|
amount: Joi.number(),
|
|
3675
|
+
float_amount: Joi.string().allow(""),
|
|
3654
3676
|
promotion_type: Joi.string().allow(""),
|
|
3655
3677
|
mrp_promotion: Joi.boolean(),
|
|
3656
3678
|
promotion_group: Joi.string().allow(""),
|
|
@@ -3722,6 +3744,15 @@ class CartPlatformModel {
|
|
|
3722
3744
|
});
|
|
3723
3745
|
}
|
|
3724
3746
|
|
|
3747
|
+
/** @returns {ProductMaxQuantityInfo} */
|
|
3748
|
+
static ProductMaxQuantityInfo() {
|
|
3749
|
+
return Joi.object({
|
|
3750
|
+
item: Joi.number().allow(null),
|
|
3751
|
+
item_seller: Joi.number().allow(null),
|
|
3752
|
+
item_store: Joi.number().allow(null),
|
|
3753
|
+
});
|
|
3754
|
+
}
|
|
3755
|
+
|
|
3725
3756
|
/** @returns {CartProductIdentifer} */
|
|
3726
3757
|
static CartProductIdentifer() {
|
|
3727
3758
|
return Joi.object({
|
|
@@ -3782,6 +3813,7 @@ class CartPlatformModel {
|
|
|
3782
3813
|
discount: Joi.string().allow(""),
|
|
3783
3814
|
availability: CartPlatformModel.ProductAvailability(),
|
|
3784
3815
|
moq: Joi.object().pattern(/\S/, Joi.any()),
|
|
3816
|
+
max_quantity: CartPlatformModel.ProductMaxQuantityInfo(),
|
|
3785
3817
|
price_per_unit: CartPlatformModel.ProductPriceInfo(),
|
|
3786
3818
|
promo_meta: CartPlatformModel.PromoMeta(),
|
|
3787
3819
|
custom_order: Joi.object().pattern(/\S/, Joi.any()),
|
|
@@ -4537,6 +4569,7 @@ class CartPlatformModel {
|
|
|
4537
4569
|
/** @returns {PlatformGetAddressesDetails} */
|
|
4538
4570
|
static PlatformGetAddressesDetails() {
|
|
4539
4571
|
return Joi.object({
|
|
4572
|
+
pii_masking: Joi.boolean(),
|
|
4540
4573
|
address: Joi.array().items(CartPlatformModel.PlatformAddress()),
|
|
4541
4574
|
validation_config: CartPlatformModel.ValidationConfig(),
|
|
4542
4575
|
});
|
|
@@ -4956,7 +4989,7 @@ class CartPlatformModel {
|
|
|
4956
4989
|
employee_code: Joi.string().allow("").allow(null),
|
|
4957
4990
|
billing_address: Joi.object().pattern(/\S/, Joi.any()),
|
|
4958
4991
|
callback_url: Joi.string().allow("").allow(null),
|
|
4959
|
-
user_id: Joi.string().allow("")
|
|
4992
|
+
user_id: Joi.string().allow(""),
|
|
4960
4993
|
extra_meta: Joi.object().pattern(/\S/, Joi.any()),
|
|
4961
4994
|
order_type: Joi.string().allow("").required(),
|
|
4962
4995
|
files: Joi.array().items(CartPlatformModel.Files()),
|
|
@@ -2064,7 +2064,7 @@ class Catalog {
|
|
|
2064
2064
|
const response = await PlatformAPIClient.execute(
|
|
2065
2065
|
this.config,
|
|
2066
2066
|
"get",
|
|
2067
|
-
`/service/platform/catalog/
|
|
2067
|
+
`/service/platform/catalog/v2.0/company/${this.config.companyId}/application/${this.applicationId}/locations`,
|
|
2068
2068
|
query_params,
|
|
2069
2069
|
undefined,
|
|
2070
2070
|
requestHeaders,
|