@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.
Files changed (146) hide show
  1. package/README.md +1 -1
  2. package/package.json +1 -1
  3. package/sdk/application/Cart/CartApplicationClient.d.ts +5 -5
  4. package/sdk/application/Cart/CartApplicationClient.js +26 -268
  5. package/sdk/application/Catalog/CatalogApplicationClient.d.ts +20 -20
  6. package/sdk/application/Catalog/CatalogApplicationClient.js +98 -347
  7. package/sdk/application/Common/CommonApplicationClient.js +1 -16
  8. package/sdk/application/Communication/CommunicationApplicationClient.js +1 -24
  9. package/sdk/application/Configuration/ConfigurationApplicationClient.d.ts +24 -2
  10. package/sdk/application/Configuration/ConfigurationApplicationClient.js +58 -137
  11. package/sdk/application/Content/ContentApplicationClient.d.ts +47 -7
  12. package/sdk/application/Content/ContentApplicationClient.js +222 -191
  13. package/sdk/application/FileStorage/FileStorageApplicationClient.d.ts +2 -2
  14. package/sdk/application/FileStorage/FileStorageApplicationClient.js +11 -30
  15. package/sdk/application/Finance/FinanceApplicationClient.js +1 -16
  16. package/sdk/application/Lead/LeadApplicationClient.d.ts +4 -4
  17. package/sdk/application/Lead/LeadApplicationClient.js +21 -52
  18. package/sdk/application/Logistic/LogisticApplicationClient.d.ts +16 -56
  19. package/sdk/application/Logistic/LogisticApplicationClient.js +57 -332
  20. package/sdk/application/Order/OrderApplicationClient.d.ts +11 -11
  21. package/sdk/application/Order/OrderApplicationClient.js +68 -153
  22. package/sdk/application/Payment/PaymentApplicationClient.d.ts +2 -12
  23. package/sdk/application/Payment/PaymentApplicationClient.js +7 -487
  24. package/sdk/application/Rewards/RewardsApplicationClient.d.ts +1 -1
  25. package/sdk/application/Rewards/RewardsApplicationClient.js +6 -59
  26. package/sdk/application/Share/ShareApplicationClient.d.ts +4 -4
  27. package/sdk/application/Share/ShareApplicationClient.js +21 -75
  28. package/sdk/application/Theme/ThemeApplicationClient.d.ts +3 -3
  29. package/sdk/application/Theme/ThemeApplicationClient.js +19 -47
  30. package/sdk/application/User/UserApplicationClient.js +1 -407
  31. package/sdk/application/Webhook/WebhookApplicationClient.js +1 -8
  32. package/sdk/common/Utility.d.ts +1 -1
  33. package/sdk/common/Utility.js +4 -4
  34. package/sdk/common/Validator.d.ts +1 -0
  35. package/sdk/common/Validator.js +20 -0
  36. package/sdk/partner/FileStorage/FileStoragePartnerClient.d.ts +1 -55
  37. package/sdk/partner/FileStorage/FileStoragePartnerClient.js +1 -408
  38. package/sdk/partner/FileStorage/FileStoragePartnerValidator.d.ts +0 -5
  39. package/sdk/partner/FileStorage/FileStoragePartnerValidator.js +0 -37
  40. package/sdk/partner/Lead/LeadPartnerModel.d.ts +5 -0
  41. package/sdk/partner/Lead/LeadPartnerModel.js +2 -0
  42. package/sdk/partner/Logistics/LogisticsPartnerClient.d.ts +29 -25
  43. package/sdk/partner/Logistics/LogisticsPartnerClient.js +65 -42
  44. package/sdk/partner/Logistics/LogisticsPartnerModel.d.ts +1008 -794
  45. package/sdk/partner/Logistics/LogisticsPartnerModel.js +573 -460
  46. package/sdk/partner/Logistics/LogisticsPartnerValidator.js +10 -5
  47. package/sdk/partner/Webhook/WebhookPartnerModel.d.ts +64 -1
  48. package/sdk/partner/Webhook/WebhookPartnerModel.js +36 -0
  49. package/sdk/platform/Analytics/AnalyticsPlatformModel.d.ts +5 -0
  50. package/sdk/platform/Analytics/AnalyticsPlatformModel.js +2 -0
  51. package/sdk/platform/Cart/CartPlatformModel.d.ts +67 -9
  52. package/sdk/platform/Cart/CartPlatformModel.js +38 -5
  53. package/sdk/platform/Catalog/CatalogPlatformApplicationClient.js +1 -1
  54. package/sdk/platform/Catalog/CatalogPlatformClient.js +4 -4
  55. package/sdk/platform/Catalog/CatalogPlatformModel.d.ts +47 -13
  56. package/sdk/platform/Catalog/CatalogPlatformModel.js +29 -7
  57. package/sdk/platform/Communication/CommunicationPlatformApplicationClient.d.ts +2 -2
  58. package/sdk/platform/Communication/CommunicationPlatformApplicationClient.js +7 -4
  59. package/sdk/platform/Communication/CommunicationPlatformModel.d.ts +71 -7
  60. package/sdk/platform/Communication/CommunicationPlatformModel.js +70 -6
  61. package/sdk/platform/CompanyProfile/CompanyProfilePlatformClient.d.ts +0 -27
  62. package/sdk/platform/CompanyProfile/CompanyProfilePlatformClient.js +8 -60
  63. package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.d.ts +31 -20
  64. package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.js +18 -18
  65. package/sdk/platform/Configuration/ConfigurationPlatformApplicationClient.d.ts +1 -1
  66. package/sdk/platform/Configuration/ConfigurationPlatformApplicationClient.js +3 -3
  67. package/sdk/platform/Configuration/ConfigurationPlatformClient.d.ts +13 -0
  68. package/sdk/platform/Configuration/ConfigurationPlatformClient.js +30 -1
  69. package/sdk/platform/Configuration/ConfigurationPlatformModel.d.ts +68 -11
  70. package/sdk/platform/Configuration/ConfigurationPlatformModel.js +49 -7
  71. package/sdk/platform/Content/ContentPlatformApplicationClient.d.ts +169 -0
  72. package/sdk/platform/Content/ContentPlatformApplicationClient.js +1279 -132
  73. package/sdk/platform/Content/ContentPlatformApplicationValidator.d.ts +156 -1
  74. package/sdk/platform/Content/ContentPlatformApplicationValidator.js +180 -0
  75. package/sdk/platform/Content/ContentPlatformClient.d.ts +162 -0
  76. package/sdk/platform/Content/ContentPlatformClient.js +1697 -497
  77. package/sdk/platform/Content/ContentPlatformModel.d.ts +1053 -35
  78. package/sdk/platform/Content/ContentPlatformModel.js +717 -34
  79. package/sdk/platform/Content/ContentPlatformValidator.d.ts +127 -1
  80. package/sdk/platform/Content/ContentPlatformValidator.js +171 -0
  81. package/sdk/platform/Discount/DiscountPlatformClient.d.ts +34 -0
  82. package/sdk/platform/Discount/DiscountPlatformClient.js +59 -0
  83. package/sdk/platform/Discount/DiscountPlatformModel.d.ts +365 -93
  84. package/sdk/platform/Discount/DiscountPlatformModel.js +98 -93
  85. package/sdk/platform/Discount/DiscountPlatformValidator.d.ts +54 -34
  86. package/sdk/platform/Discount/DiscountPlatformValidator.js +27 -17
  87. package/sdk/platform/FileStorage/FileStoragePlatformApplicationClient.d.ts +0 -156
  88. package/sdk/platform/FileStorage/FileStoragePlatformApplicationClient.js +0 -1072
  89. package/sdk/platform/FileStorage/FileStoragePlatformApplicationValidator.d.ts +1 -137
  90. package/sdk/platform/FileStorage/FileStoragePlatformApplicationValidator.js +0 -173
  91. package/sdk/platform/FileStorage/FileStoragePlatformModel.d.ts +1 -1105
  92. package/sdk/platform/FileStorage/FileStoragePlatformModel.js +0 -1125
  93. package/sdk/platform/Lead/LeadPlatformModel.d.ts +5 -0
  94. package/sdk/platform/Lead/LeadPlatformModel.js +2 -0
  95. package/sdk/platform/Order/OrderPlatformApplicationClient.d.ts +0 -10
  96. package/sdk/platform/Order/OrderPlatformApplicationClient.js +0 -92
  97. package/sdk/platform/Order/OrderPlatformApplicationValidator.d.ts +1 -28
  98. package/sdk/platform/Order/OrderPlatformApplicationValidator.js +0 -18
  99. package/sdk/platform/Order/OrderPlatformClient.d.ts +212 -0
  100. package/sdk/platform/Order/OrderPlatformClient.js +397 -0
  101. package/sdk/platform/Order/OrderPlatformModel.d.ts +66 -10
  102. package/sdk/platform/Order/OrderPlatformModel.js +39 -7
  103. package/sdk/platform/Order/OrderPlatformValidator.d.ts +33 -1
  104. package/sdk/platform/Order/OrderPlatformValidator.js +20 -0
  105. package/sdk/platform/Partner/PartnerPlatformModel.d.ts +58 -10
  106. package/sdk/platform/Partner/PartnerPlatformModel.js +19 -10
  107. package/sdk/platform/Payment/PaymentPlatformModel.d.ts +12 -2
  108. package/sdk/platform/Payment/PaymentPlatformModel.js +8 -2
  109. package/sdk/platform/Rewards/RewardsPlatformModel.d.ts +5 -0
  110. package/sdk/platform/Rewards/RewardsPlatformModel.js +2 -0
  111. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationClient.d.ts +240 -24
  112. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationClient.js +1753 -277
  113. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationValidator.d.ts +320 -22
  114. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationValidator.js +269 -19
  115. package/sdk/platform/Serviceability/ServiceabilityPlatformClient.d.ts +53 -104
  116. package/sdk/platform/Serviceability/ServiceabilityPlatformClient.js +201 -629
  117. package/sdk/platform/Serviceability/ServiceabilityPlatformModel.d.ts +5720 -2891
  118. package/sdk/platform/Serviceability/ServiceabilityPlatformModel.js +3414 -2181
  119. package/sdk/platform/Serviceability/ServiceabilityPlatformValidator.d.ts +138 -216
  120. package/sdk/platform/Serviceability/ServiceabilityPlatformValidator.js +81 -148
  121. package/sdk/platform/Share/SharePlatformModel.d.ts +5 -0
  122. package/sdk/platform/Share/SharePlatformModel.js +2 -0
  123. package/sdk/platform/User/UserPlatformApplicationClient.d.ts +73 -0
  124. package/sdk/platform/User/UserPlatformApplicationClient.js +543 -0
  125. package/sdk/platform/User/UserPlatformApplicationValidator.d.ts +129 -1
  126. package/sdk/platform/User/UserPlatformApplicationValidator.js +97 -0
  127. package/sdk/platform/User/UserPlatformModel.d.ts +269 -6
  128. package/sdk/platform/User/UserPlatformModel.js +187 -5
  129. package/sdk/platform/Webhook/WebhookPlatformModel.d.ts +64 -1
  130. package/sdk/platform/Webhook/WebhookPlatformModel.js +36 -0
  131. package/sdk/public/Catalog/CatalogPublicClient.d.ts +1 -1
  132. package/sdk/public/Catalog/CatalogPublicClient.js +6 -11
  133. package/sdk/public/Configuration/ConfigurationPublicClient.js +1 -16
  134. package/sdk/public/Content/ContentPublicClient.d.ts +36 -3
  135. package/sdk/public/Content/ContentPublicClient.js +261 -104
  136. package/sdk/public/Content/ContentPublicModel.d.ts +155 -1
  137. package/sdk/public/Content/ContentPublicModel.js +102 -0
  138. package/sdk/public/Content/ContentPublicValidator.d.ts +18 -1
  139. package/sdk/public/Content/ContentPublicValidator.js +26 -0
  140. package/sdk/public/Partner/PartnerPublicClient.d.ts +1 -1
  141. package/sdk/public/Partner/PartnerPublicClient.js +6 -11
  142. package/sdk/public/Partner/PartnerPublicModel.d.ts +248 -72
  143. package/sdk/public/Partner/PartnerPublicModel.js +81 -71
  144. package/sdk/public/Partner/PartnerPublicValidator.d.ts +2 -2
  145. package/sdk/public/Partner/PartnerPublicValidator.js +1 -1
  146. package/sdk/public/Webhook/WebhookPublicClient.js +1 -40
@@ -484,13 +484,13 @@ const Joi = require("joi");
484
484
  /**
485
485
  * @typedef EventSubscriptionTemplateSms
486
486
  * @property {boolean} [subscribed]
487
- * @property {string} [template]
487
+ * @property {SmsTemplate} [template]
488
488
  */
489
489
 
490
490
  /**
491
491
  * @typedef EventSubscriptionTemplateEmail
492
492
  * @property {boolean} [subscribed]
493
- * @property {string} [template]
493
+ * @property {EmailTemplate} [template]
494
494
  */
495
495
 
496
496
  /**
@@ -505,13 +505,35 @@ const Joi = require("joi");
505
505
  * @property {boolean} [is_default]
506
506
  * @property {string} [_id]
507
507
  * @property {string} [application]
508
- * @property {string} [event]
508
+ * @property {EventSubscriptionEvents} [event]
509
509
  * @property {string} [slug]
510
510
  * @property {string} [created_at]
511
511
  * @property {string} [updated_at]
512
512
  * @property {number} [__v]
513
513
  */
514
514
 
515
+ /**
516
+ * @typedef EventSubscriptionEvents
517
+ * @property {string} [category]
518
+ * @property {string} [event_name]
519
+ * @property {string} [group]
520
+ * @property {string} [slug]
521
+ * @property {EventTemplate} [template]
522
+ */
523
+
524
+ /**
525
+ * @typedef EventTemplate
526
+ * @property {EventProviderTemplates} [email]
527
+ * @property {EventProviderTemplates} [pushnotification]
528
+ * @property {EventProviderTemplates} [sms]
529
+ */
530
+
531
+ /**
532
+ * @typedef EventProviderTemplates
533
+ * @property {string} [provider_type] - Provider type for the event template
534
+ * @property {string} [template] - This is the unique id of the template
535
+ */
536
+
515
537
  /**
516
538
  * @typedef EventSubscriptions
517
539
  * @property {EventSubscription[]} [items]
@@ -841,6 +863,11 @@ const Joi = require("joi");
841
863
 
842
864
  /**
843
865
  * @typedef SystemSmsTemplates
866
+ * @property {SystemSmsTemplate[]} [items] - An array of system SMS templates
867
+ */
868
+
869
+ /**
870
+ * @typedef SystemSmsTemplate
844
871
  * @property {EnabledObj} [url_shorten]
845
872
  * @property {string} [_id]
846
873
  * @property {boolean} [is_system]
@@ -921,6 +948,7 @@ const Joi = require("joi");
921
948
  * @property {number} [current] - The current page number.
922
949
  * @property {string} type - The type of the page, such as 'PageType'.
923
950
  * @property {number} [size] - The number of items per page.
951
+ * @property {number} [page_size] - The number of items per page.
924
952
  */
925
953
 
926
954
  /**
@@ -1595,7 +1623,7 @@ class CommunicationPlatformModel {
1595
1623
  static EventSubscriptionTemplateSms() {
1596
1624
  return Joi.object({
1597
1625
  subscribed: Joi.boolean(),
1598
- template: Joi.string().allow(""),
1626
+ template: CommunicationPlatformModel.SmsTemplate(),
1599
1627
  });
1600
1628
  }
1601
1629
 
@@ -1603,7 +1631,7 @@ class CommunicationPlatformModel {
1603
1631
  static EventSubscriptionTemplateEmail() {
1604
1632
  return Joi.object({
1605
1633
  subscribed: Joi.boolean(),
1606
- template: Joi.string().allow(""),
1634
+ template: CommunicationPlatformModel.EmailTemplate(),
1607
1635
  });
1608
1636
  }
1609
1637
 
@@ -1622,7 +1650,7 @@ class CommunicationPlatformModel {
1622
1650
  is_default: Joi.boolean(),
1623
1651
  _id: Joi.string().allow(""),
1624
1652
  application: Joi.string().allow(""),
1625
- event: Joi.string().allow(""),
1653
+ event: CommunicationPlatformModel.EventSubscriptionEvents(),
1626
1654
  slug: Joi.string().allow(""),
1627
1655
  created_at: Joi.string().allow(""),
1628
1656
  updated_at: Joi.string().allow(""),
@@ -1630,6 +1658,34 @@ class CommunicationPlatformModel {
1630
1658
  });
1631
1659
  }
1632
1660
 
1661
+ /** @returns {EventSubscriptionEvents} */
1662
+ static EventSubscriptionEvents() {
1663
+ return Joi.object({
1664
+ category: Joi.string().allow(""),
1665
+ event_name: Joi.string().allow(""),
1666
+ group: Joi.string().allow(""),
1667
+ slug: Joi.string().allow(""),
1668
+ template: CommunicationPlatformModel.EventTemplate(),
1669
+ });
1670
+ }
1671
+
1672
+ /** @returns {EventTemplate} */
1673
+ static EventTemplate() {
1674
+ return Joi.object({
1675
+ email: CommunicationPlatformModel.EventProviderTemplates(),
1676
+ pushnotification: CommunicationPlatformModel.EventProviderTemplates(),
1677
+ sms: CommunicationPlatformModel.EventProviderTemplates(),
1678
+ });
1679
+ }
1680
+
1681
+ /** @returns {EventProviderTemplates} */
1682
+ static EventProviderTemplates() {
1683
+ return Joi.object({
1684
+ provider_type: Joi.string().allow("").allow(null),
1685
+ template: Joi.string().allow("").allow(null),
1686
+ });
1687
+ }
1688
+
1633
1689
  /** @returns {EventSubscriptions} */
1634
1690
  static EventSubscriptions() {
1635
1691
  return Joi.object({
@@ -2035,6 +2091,13 @@ class CommunicationPlatformModel {
2035
2091
 
2036
2092
  /** @returns {SystemSmsTemplates} */
2037
2093
  static SystemSmsTemplates() {
2094
+ return Joi.object({
2095
+ items: Joi.array().items(CommunicationPlatformModel.SystemSmsTemplate()),
2096
+ });
2097
+ }
2098
+
2099
+ /** @returns {SystemSmsTemplate} */
2100
+ static SystemSmsTemplate() {
2038
2101
  return Joi.object({
2039
2102
  url_shorten: CommunicationPlatformModel.EnabledObj(),
2040
2103
  _id: Joi.string().allow(""),
@@ -2130,6 +2193,7 @@ class CommunicationPlatformModel {
2130
2193
  current: Joi.number(),
2131
2194
  type: Joi.string().allow("").required(),
2132
2195
  size: Joi.number(),
2196
+ page_size: Joi.number(),
2133
2197
  });
2134
2198
  }
2135
2199
 
@@ -155,33 +155,6 @@ declare class CompanyProfile {
155
155
  * @description: Retrieve a list of locations associated with the company. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/companyprofile/getLocations/).
156
156
  */
157
157
  getLocations({ storeType, q, stage, pageNo, pageSize, locationIds, types, tags, requestHeaders, }?: CompanyProfilePlatformValidator.GetLocationsParam, { responseHeaders }?: object): Promise<CompanyProfilePlatformModel.LocationListSchema>;
158
- /**
159
- * @param {Object} arg - Arg object.
160
- * @param {string} [arg.storeType] - Helps to sort the location list on the
161
- * basis of location type.
162
- * @param {string} [arg.q] - Query that is to be searched.
163
- * @param {string} [arg.stage] - To filter companies on basis of verified or
164
- * unverified companies.
165
- * @param {number} [arg.pageSize] - Number of items to retrieve in each
166
- * page. Default is 10.
167
- * @param {number[]} [arg.locationIds] - Helps to filter stores on the basis of uids.
168
- * @param {string[]} [arg.types] - Helps to get the location list on the
169
- * basis of multiple location type.
170
- * @param {string[]} [arg.tags] - Helps to get the location list on the
171
- * basis of multiple location tag.
172
- * @returns {Paginator<CompanyProfilePlatformModel.LocationListSchema>}
173
- * @summary: Get company specific stores
174
- * @description: Retrieve a list of locations associated with the company.
175
- */
176
- getLocationsPaginator({ storeType, q, stage, pageSize, locationIds, types, tags, }?: {
177
- storeType?: string;
178
- q?: string;
179
- stage?: string;
180
- pageSize?: number;
181
- locationIds?: number[];
182
- types?: string[];
183
- tags?: string[];
184
- }): Paginator<CompanyProfilePlatformModel.LocationListSchema>;
185
158
  /**
186
159
  * @param {CompanyProfilePlatformValidator.UpdateCompanyParam} arg - Arg object
187
160
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
@@ -58,7 +58,7 @@ class CompanyProfile {
58
58
  const response = await PlatformAPIClient.execute(
59
59
  this.config,
60
60
  "get",
61
- `/service/platform/company-profile/v1.0/company/${this.config.companyId}`,
61
+ `/service/platform/company-profile/v2.0/company/${this.config.companyId}`,
62
62
  query_params,
63
63
  undefined,
64
64
  { ...xHeaders, ...requestHeaders },
@@ -224,7 +224,7 @@ class CompanyProfile {
224
224
  const response = await PlatformAPIClient.execute(
225
225
  this.config,
226
226
  "post",
227
- `/service/platform/company-profile/v1.0/company/${this.config.companyId}/company-brand`,
227
+ `/service/platform/company-profile/v2.0/company/${this.config.companyId}/company-brand`,
228
228
  query_params,
229
229
  body,
230
230
  { ...xHeaders, ...requestHeaders },
@@ -305,7 +305,7 @@ class CompanyProfile {
305
305
  const response = await PlatformAPIClient.execute(
306
306
  this.config,
307
307
  "post",
308
- `/service/platform/company-profile/v1.0/company/${this.config.companyId}/location`,
308
+ `/service/platform/company-profile/v2.0/company/${this.config.companyId}/location`,
309
309
  query_params,
310
310
  body,
311
311
  { ...xHeaders, ...requestHeaders },
@@ -638,7 +638,7 @@ class CompanyProfile {
638
638
  const response = await PlatformAPIClient.execute(
639
639
  this.config,
640
640
  "get",
641
- `/service/platform/company-profile/v1.0/company/${this.config.companyId}/company-brand`,
641
+ `/service/platform/company-profile/v2.0/company/${this.config.companyId}/company-brand`,
642
642
  query_params,
643
643
  undefined,
644
644
  { ...xHeaders, ...requestHeaders },
@@ -827,7 +827,7 @@ class CompanyProfile {
827
827
  const response = await PlatformAPIClient.execute(
828
828
  this.config,
829
829
  "get",
830
- `/service/platform/company-profile/v1.0/company/${this.config.companyId}/location/${locationId}`,
830
+ `/service/platform/company-profile/v2.0/company/${this.config.companyId}/location/${locationId}`,
831
831
  query_params,
832
832
  undefined,
833
833
  { ...xHeaders, ...requestHeaders },
@@ -1018,7 +1018,7 @@ class CompanyProfile {
1018
1018
  const response = await PlatformAPIClient.execute(
1019
1019
  this.config,
1020
1020
  "get",
1021
- `/service/platform/company-profile/v1.0/company/${this.config.companyId}/location`,
1021
+ `/service/platform/company-profile/v2.0/company/${this.config.companyId}/location`,
1022
1022
  query_params,
1023
1023
  undefined,
1024
1024
  { ...xHeaders, ...requestHeaders },
@@ -1051,58 +1051,6 @@ class CompanyProfile {
1051
1051
  return response;
1052
1052
  }
1053
1053
 
1054
- /**
1055
- * @param {Object} arg - Arg object.
1056
- * @param {string} [arg.storeType] - Helps to sort the location list on the
1057
- * basis of location type.
1058
- * @param {string} [arg.q] - Query that is to be searched.
1059
- * @param {string} [arg.stage] - To filter companies on basis of verified or
1060
- * unverified companies.
1061
- * @param {number} [arg.pageSize] - Number of items to retrieve in each
1062
- * page. Default is 10.
1063
- * @param {number[]} [arg.locationIds] - Helps to filter stores on the basis of uids.
1064
- * @param {string[]} [arg.types] - Helps to get the location list on the
1065
- * basis of multiple location type.
1066
- * @param {string[]} [arg.tags] - Helps to get the location list on the
1067
- * basis of multiple location tag.
1068
- * @returns {Paginator<CompanyProfilePlatformModel.LocationListSchema>}
1069
- * @summary: Get company specific stores
1070
- * @description: Retrieve a list of locations associated with the company.
1071
- */
1072
- getLocationsPaginator({
1073
- storeType,
1074
- q,
1075
- stage,
1076
- pageSize,
1077
- locationIds,
1078
- types,
1079
- tags,
1080
- } = {}) {
1081
- const paginator = new Paginator();
1082
- const callback = async () => {
1083
- const pageId = paginator.nextId;
1084
- const pageNo = paginator.pageNo;
1085
- const pageType = "number";
1086
- const data = await this.getLocations({
1087
- storeType: storeType,
1088
- q: q,
1089
- stage: stage,
1090
- pageNo: pageNo,
1091
- pageSize: pageSize,
1092
- locationIds: locationIds,
1093
- types: types,
1094
- tags: tags,
1095
- });
1096
- paginator.setPaginator({
1097
- hasNext: data.page.has_next ? true : false,
1098
- nextId: data.page.next_id,
1099
- });
1100
- return data;
1101
- };
1102
- paginator.setCallback(callback.bind(this));
1103
- return paginator;
1104
- }
1105
-
1106
1054
  /**
1107
1055
  * @param {CompanyProfilePlatformValidator.UpdateCompanyParam} arg - Arg object
1108
1056
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
@@ -1151,7 +1099,7 @@ class CompanyProfile {
1151
1099
  const response = await PlatformAPIClient.execute(
1152
1100
  this.config,
1153
1101
  "patch",
1154
- `/service/platform/company-profile/v1.0/company/${this.config.companyId}`,
1102
+ `/service/platform/company-profile/v2.0/company/${this.config.companyId}`,
1155
1103
  query_params,
1156
1104
  body,
1157
1105
  { ...xHeaders, ...requestHeaders },
@@ -1234,7 +1182,7 @@ class CompanyProfile {
1234
1182
  const response = await PlatformAPIClient.execute(
1235
1183
  this.config,
1236
1184
  "put",
1237
- `/service/platform/company-profile/v1.0/company/${this.config.companyId}/location/${locationId}`,
1185
+ `/service/platform/company-profile/v2.0/company/${this.config.companyId}/location/${locationId}`,
1238
1186
  query_params,
1239
1187
  body,
1240
1188
  { ...xHeaders, ...requestHeaders },
@@ -54,7 +54,7 @@ export = CompanyProfilePlatformModel;
54
54
  * @typedef GetAddressSchema
55
55
  * @property {string} [landmark]
56
56
  * @property {string} [country_code]
57
- * @property {number} [pincode]
57
+ * @property {string} [pincode]
58
58
  * @property {string} [address_type]
59
59
  * @property {number} longitude
60
60
  * @property {string} [country]
@@ -94,13 +94,13 @@ export = CompanyProfilePlatformModel;
94
94
  */
95
95
  /**
96
96
  * @typedef ErrorResponseSchema
97
- * @property {string} [message]
98
- * @property {string} [code]
99
- * @property {number} [status]
100
- * @property {Object} [meta]
97
+ * @property {string} [message] - A descriptive message providing details about
98
+ * the error, intended to convey the nature and context of the issue.
99
+ * @property {Object} [error] - An object containing additional error details,
100
+ * which may vary depending on the error type.
101
101
  */
102
102
  /**
103
- * @typedef CompanyTaxesSerializer1
103
+ * @typedef CompanyRequestTaxesSchema
104
104
  * @property {string} [effective_date]
105
105
  * @property {number} [rate]
106
106
  * @property {boolean} [enable]
@@ -109,7 +109,7 @@ export = CompanyProfilePlatformModel;
109
109
  * @typedef CreateUpdateAddressSchema
110
110
  * @property {string} [landmark]
111
111
  * @property {string} [country_code]
112
- * @property {number} pincode
112
+ * @property {string} pincode
113
113
  * @property {string} address_type
114
114
  * @property {number} longitude
115
115
  * @property {string} country
@@ -126,7 +126,7 @@ export = CompanyProfilePlatformModel;
126
126
  * @property {Object} [warnings]
127
127
  * @property {string} [company_type]
128
128
  * @property {Object} [_custom_json]
129
- * @property {CompanyTaxesSerializer1[]} [taxes]
129
+ * @property {CompanyRequestTaxesSchema[]} [taxes]
130
130
  * @property {BusinessDetails} [business_details]
131
131
  * @property {Document[]} [documents]
132
132
  * @property {string} [business_type]
@@ -266,6 +266,7 @@ export = CompanyProfilePlatformModel;
266
266
  * @property {number} [current] - The current page number.
267
267
  * @property {string} type - The type of the page, such as 'PageType'.
268
268
  * @property {number} [size] - The number of items per page.
269
+ * @property {number} [page_size] - The number of items per page.
269
270
  */
270
271
  /**
271
272
  * @typedef CompanyBrandListSchema
@@ -384,7 +385,7 @@ export = CompanyProfilePlatformModel;
384
385
  * @typedef AddressSchema
385
386
  * @property {string} [landmark]
386
387
  * @property {string} country_code
387
- * @property {number} [pincode]
388
+ * @property {string} [pincode]
388
389
  * @property {string} [address_type]
389
390
  * @property {number} longitude
390
391
  * @property {string} [country]
@@ -444,7 +445,7 @@ export = CompanyProfilePlatformModel;
444
445
  declare class CompanyProfilePlatformModel {
445
446
  }
446
447
  declare namespace CompanyProfilePlatformModel {
447
- export { CompanyTaxesSchema, UserSchema, Website, BusinessDetails, SellerPhoneNumber, ContactDetails, CountryCurrencyInfo, BusinessCountryInfo, Document, GetAddressSchema, GetCompanyProfileSerializerResponseSchema, ErrorResponseSchema, CompanyTaxesSerializer1, CreateUpdateAddressSchema, UpdateCompany, ProfileSuccessResponseSchema, DocumentsObj, MetricsSchema, BrandBannerSchema, GetBrandResponseSchema, CreateBrandRequestSchema, UpdateBrandRequestSchema, CompanySocialAccounts, CompanyDetails, CompanySchema, CompanyBrandSchema, Page, CompanyBrandListSchema, CompanyBrandPostRequestSchema, InvoiceCredSchema, InvoiceDetailsSchema, GetCompanySchema, LocationManagerSchema, LocationTimingSchema, LocationDayWiseSchema, HolidayDateSchema, HolidaySchemaSchema, ProductReturnConfigSchema, GetLocationSchema, LocationListSchema, AddressSchema, LocationSchema, BulkLocationSchema, AverageOrderProcessingTime, StoreTagsResponseSchema };
448
+ export { CompanyTaxesSchema, UserSchema, Website, BusinessDetails, SellerPhoneNumber, ContactDetails, CountryCurrencyInfo, BusinessCountryInfo, Document, GetAddressSchema, GetCompanyProfileSerializerResponseSchema, ErrorResponseSchema, CompanyRequestTaxesSchema, CreateUpdateAddressSchema, UpdateCompany, ProfileSuccessResponseSchema, DocumentsObj, MetricsSchema, BrandBannerSchema, GetBrandResponseSchema, CreateBrandRequestSchema, UpdateBrandRequestSchema, CompanySocialAccounts, CompanyDetails, CompanySchema, CompanyBrandSchema, Page, CompanyBrandListSchema, CompanyBrandPostRequestSchema, InvoiceCredSchema, InvoiceDetailsSchema, GetCompanySchema, LocationManagerSchema, LocationTimingSchema, LocationDayWiseSchema, HolidayDateSchema, HolidaySchemaSchema, ProductReturnConfigSchema, GetLocationSchema, LocationListSchema, AddressSchema, LocationSchema, BulkLocationSchema, AverageOrderProcessingTime, StoreTagsResponseSchema };
448
449
  }
449
450
  /** @returns {CompanyTaxesSchema} */
450
451
  declare function CompanyTaxesSchema(): CompanyTaxesSchema;
@@ -511,7 +512,7 @@ declare function GetAddressSchema(): GetAddressSchema;
511
512
  type GetAddressSchema = {
512
513
  landmark?: string;
513
514
  country_code?: string;
514
- pincode?: number;
515
+ pincode?: string;
515
516
  address_type?: string;
516
517
  longitude: number;
517
518
  country?: string;
@@ -553,14 +554,20 @@ type GetCompanyProfileSerializerResponseSchema = {
553
554
  /** @returns {ErrorResponseSchema} */
554
555
  declare function ErrorResponseSchema(): ErrorResponseSchema;
555
556
  type ErrorResponseSchema = {
557
+ /**
558
+ * - A descriptive message providing details about
559
+ * the error, intended to convey the nature and context of the issue.
560
+ */
556
561
  message?: string;
557
- code?: string;
558
- status?: number;
559
- meta?: any;
562
+ /**
563
+ * - An object containing additional error details,
564
+ * which may vary depending on the error type.
565
+ */
566
+ error?: any;
560
567
  };
561
- /** @returns {CompanyTaxesSerializer1} */
562
- declare function CompanyTaxesSerializer1(): CompanyTaxesSerializer1;
563
- type CompanyTaxesSerializer1 = {
568
+ /** @returns {CompanyRequestTaxesSchema} */
569
+ declare function CompanyRequestTaxesSchema(): CompanyRequestTaxesSchema;
570
+ type CompanyRequestTaxesSchema = {
564
571
  effective_date?: string;
565
572
  rate?: number;
566
573
  enable?: boolean;
@@ -570,7 +577,7 @@ declare function CreateUpdateAddressSchema(): CreateUpdateAddressSchema;
570
577
  type CreateUpdateAddressSchema = {
571
578
  landmark?: string;
572
579
  country_code?: string;
573
- pincode: number;
580
+ pincode: string;
574
581
  address_type: string;
575
582
  longitude: number;
576
583
  country: string;
@@ -588,7 +595,7 @@ type UpdateCompany = {
588
595
  warnings?: any;
589
596
  company_type?: string;
590
597
  _custom_json?: any;
591
- taxes?: CompanyTaxesSerializer1[];
598
+ taxes?: CompanyRequestTaxesSchema[];
592
599
  business_details?: BusinessDetails;
593
600
  documents?: Document[];
594
601
  business_type?: string;
@@ -761,6 +768,10 @@ type Page = {
761
768
  * - The number of items per page.
762
769
  */
763
770
  size?: number;
771
+ /**
772
+ * - The number of items per page.
773
+ */
774
+ page_size?: number;
764
775
  };
765
776
  /** @returns {CompanyBrandListSchema} */
766
777
  declare function CompanyBrandListSchema(): CompanyBrandListSchema;
@@ -893,7 +904,7 @@ declare function AddressSchema(): AddressSchema;
893
904
  type AddressSchema = {
894
905
  landmark?: string;
895
906
  country_code: string;
896
- pincode?: number;
907
+ pincode?: string;
897
908
  address_type?: string;
898
909
  longitude: number;
899
910
  country?: string;
@@ -64,7 +64,7 @@ const Joi = require("joi");
64
64
  * @typedef GetAddressSchema
65
65
  * @property {string} [landmark]
66
66
  * @property {string} [country_code]
67
- * @property {number} [pincode]
67
+ * @property {string} [pincode]
68
68
  * @property {string} [address_type]
69
69
  * @property {number} longitude
70
70
  * @property {string} [country]
@@ -106,14 +106,14 @@ const Joi = require("joi");
106
106
 
107
107
  /**
108
108
  * @typedef ErrorResponseSchema
109
- * @property {string} [message]
110
- * @property {string} [code]
111
- * @property {number} [status]
112
- * @property {Object} [meta]
109
+ * @property {string} [message] - A descriptive message providing details about
110
+ * the error, intended to convey the nature and context of the issue.
111
+ * @property {Object} [error] - An object containing additional error details,
112
+ * which may vary depending on the error type.
113
113
  */
114
114
 
115
115
  /**
116
- * @typedef CompanyTaxesSerializer1
116
+ * @typedef CompanyRequestTaxesSchema
117
117
  * @property {string} [effective_date]
118
118
  * @property {number} [rate]
119
119
  * @property {boolean} [enable]
@@ -123,7 +123,7 @@ const Joi = require("joi");
123
123
  * @typedef CreateUpdateAddressSchema
124
124
  * @property {string} [landmark]
125
125
  * @property {string} [country_code]
126
- * @property {number} pincode
126
+ * @property {string} pincode
127
127
  * @property {string} address_type
128
128
  * @property {number} longitude
129
129
  * @property {string} country
@@ -141,7 +141,7 @@ const Joi = require("joi");
141
141
  * @property {Object} [warnings]
142
142
  * @property {string} [company_type]
143
143
  * @property {Object} [_custom_json]
144
- * @property {CompanyTaxesSerializer1[]} [taxes]
144
+ * @property {CompanyRequestTaxesSchema[]} [taxes]
145
145
  * @property {BusinessDetails} [business_details]
146
146
  * @property {Document[]} [documents]
147
147
  * @property {string} [business_type]
@@ -293,6 +293,7 @@ const Joi = require("joi");
293
293
  * @property {number} [current] - The current page number.
294
294
  * @property {string} type - The type of the page, such as 'PageType'.
295
295
  * @property {number} [size] - The number of items per page.
296
+ * @property {number} [page_size] - The number of items per page.
296
297
  */
297
298
 
298
299
  /**
@@ -425,7 +426,7 @@ const Joi = require("joi");
425
426
  * @typedef AddressSchema
426
427
  * @property {string} [landmark]
427
428
  * @property {string} country_code
428
- * @property {number} [pincode]
429
+ * @property {string} [pincode]
429
430
  * @property {string} [address_type]
430
431
  * @property {number} longitude
431
432
  * @property {string} [country]
@@ -571,7 +572,7 @@ class CompanyProfilePlatformModel {
571
572
  return Joi.object({
572
573
  landmark: Joi.string().allow(""),
573
574
  country_code: Joi.string().allow(""),
574
- pincode: Joi.number(),
575
+ pincode: Joi.string().allow(""),
575
576
  address_type: Joi.string().allow(""),
576
577
  longitude: Joi.number().required(),
577
578
  country: Joi.string().allow(""),
@@ -622,14 +623,12 @@ class CompanyProfilePlatformModel {
622
623
  static ErrorResponseSchema() {
623
624
  return Joi.object({
624
625
  message: Joi.string().allow(""),
625
- code: Joi.string().allow(""),
626
- status: Joi.number(),
627
- meta: Joi.object().pattern(/\S/, Joi.any()),
626
+ error: Joi.object().pattern(/\S/, Joi.any()),
628
627
  });
629
628
  }
630
629
 
631
- /** @returns {CompanyTaxesSerializer1} */
632
- static CompanyTaxesSerializer1() {
630
+ /** @returns {CompanyRequestTaxesSchema} */
631
+ static CompanyRequestTaxesSchema() {
633
632
  return Joi.object({
634
633
  effective_date: Joi.string().allow(""),
635
634
  rate: Joi.number(),
@@ -642,7 +641,7 @@ class CompanyProfilePlatformModel {
642
641
  return Joi.object({
643
642
  landmark: Joi.string().allow(""),
644
643
  country_code: Joi.string().allow(""),
645
- pincode: Joi.number().required(),
644
+ pincode: Joi.string().allow("").required(),
646
645
  address_type: Joi.string().allow("").required(),
647
646
  longitude: Joi.number().required(),
648
647
  country: Joi.string().allow("").required(),
@@ -663,7 +662,7 @@ class CompanyProfilePlatformModel {
663
662
  company_type: Joi.string().allow(""),
664
663
  _custom_json: Joi.object().pattern(/\S/, Joi.any()),
665
664
  taxes: Joi.array().items(
666
- CompanyProfilePlatformModel.CompanyTaxesSerializer1()
665
+ CompanyProfilePlatformModel.CompanyRequestTaxesSchema()
667
666
  ),
668
667
  business_details: CompanyProfilePlatformModel.BusinessDetails(),
669
668
  documents: Joi.array().items(CompanyProfilePlatformModel.Document()),
@@ -846,6 +845,7 @@ class CompanyProfilePlatformModel {
846
845
  current: Joi.number(),
847
846
  type: Joi.string().allow("").required(),
848
847
  size: Joi.number(),
848
+ page_size: Joi.number(),
849
849
  });
850
850
  }
851
851
 
@@ -1018,7 +1018,7 @@ class CompanyProfilePlatformModel {
1018
1018
  return Joi.object({
1019
1019
  landmark: Joi.string().allow(""),
1020
1020
  country_code: Joi.string().allow("").required(),
1021
- pincode: Joi.number(),
1021
+ pincode: Joi.string().allow(""),
1022
1022
  address_type: Joi.string().allow(""),
1023
1023
  longitude: Joi.number().required(),
1024
1024
  country: Joi.string().allow(""),
@@ -178,7 +178,7 @@ declare class Configuration {
178
178
  * Success response
179
179
  * @name getDomains
180
180
  * @summary: List domains
181
- * @description: Retrieve a list of existing domains by its sales channel id. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/configuration/getDomains/).
181
+ * @description: Retrieve a list of existing domains by its sales channel. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/configuration/getDomains/).
182
182
  */
183
183
  getDomains({ requestHeaders }?: any, { responseHeaders }?: object): Promise<ConfigurationPlatformModel.DomainsResponseSchema>;
184
184
  /**
@@ -1070,7 +1070,7 @@ class Configuration {
1070
1070
  * Success response
1071
1071
  * @name getDomains
1072
1072
  * @summary: List domains
1073
- * @description: Retrieve a list of existing domains by its sales channel id. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/configuration/getDomains/).
1073
+ * @description: Retrieve a list of existing domains by its sales channel. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/configuration/getDomains/).
1074
1074
  */
1075
1075
  async getDomains(
1076
1076
  { requestHeaders } = { requestHeaders: {} },
@@ -1431,7 +1431,7 @@ class Configuration {
1431
1431
  const response = await PlatformAPIClient.execute(
1432
1432
  this.config,
1433
1433
  "post",
1434
- `/service/platform/configuration/v1.0/company/${this.config.companyId}/application/${this.applicationId}/ordering-store/stores/filter`,
1434
+ `/service/platform/configuration/v2.0/company/${this.config.companyId}/application/${this.applicationId}/ordering-store/stores/filter`,
1435
1435
  query_params,
1436
1436
  body,
1437
1437
  requestHeaders,
@@ -1603,7 +1603,7 @@ class Configuration {
1603
1603
  const response = await PlatformAPIClient.execute(
1604
1604
  this.config,
1605
1605
  "get",
1606
- `/service/platform/configuration/v1.0/company/${this.config.companyId}/application/${this.applicationId}/ordering-store/staff-stores`,
1606
+ `/service/platform/configuration/v2.0/company/${this.config.companyId}/application/${this.applicationId}/ordering-store/staff-stores`,
1607
1607
  query_params,
1608
1608
  undefined,
1609
1609
  requestHeaders,
@@ -25,6 +25,18 @@ declare class Configuration {
25
25
  * @description: Retrieve a list of available sales channels. sales channels are sales channel websites which can be configured, personalized and customised. Use this API to fetch a list of sales channels created within a company. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/configuration/getApplications/).
26
26
  */
27
27
  getApplications({ pageNo, pageSize, q, requestHeaders }?: ConfigurationPlatformValidator.GetApplicationsParam, { responseHeaders }?: object): Promise<ConfigurationPlatformModel.ApplicationsResponseSchema>;
28
+ /**
29
+ * @param {Object} arg - Arg object.
30
+ * @param {number} [arg.pageSize] -
31
+ * @param {string} [arg.q] - Search param by name or domain
32
+ * @returns {Paginator<ConfigurationPlatformModel.ApplicationsResponseSchema>}
33
+ * @summary: List sales channel stores
34
+ * @description: Retrieve a list of available sales channels. sales channels are sales channel websites which can be configured, personalized and customised. Use this API to fetch a list of sales channels created within a company.
35
+ */
36
+ getApplicationsPaginator({ pageSize, q }?: {
37
+ pageSize?: number;
38
+ q?: string;
39
+ }): Paginator<ConfigurationPlatformModel.ApplicationsResponseSchema>;
28
40
  /**
29
41
  * @param {ConfigurationPlatformValidator.GetBrandsByCompanyParam} arg - Arg object
30
42
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
@@ -141,3 +153,4 @@ declare class Configuration {
141
153
  }
142
154
  import ConfigurationPlatformValidator = require("./ConfigurationPlatformValidator");
143
155
  import ConfigurationPlatformModel = require("./ConfigurationPlatformModel");
156
+ import Paginator = require("../../common/Paginator");