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

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (242) hide show
  1. package/README.md +1 -1
  2. package/package.json +1 -1
  3. package/sdk/application/ApplicationClient.d.ts +0 -2
  4. package/sdk/application/ApplicationClient.js +0 -2
  5. package/sdk/application/Cart/CartApplicationClient.d.ts +48 -68
  6. package/sdk/application/Cart/CartApplicationClient.js +27 -117
  7. package/sdk/application/Catalog/CatalogApplicationClient.d.ts +58 -59
  8. package/sdk/application/Catalog/CatalogApplicationClient.js +29 -30
  9. package/sdk/application/Common/CommonApplicationClient.d.ts +2 -2
  10. package/sdk/application/Common/CommonApplicationClient.js +1 -1
  11. package/sdk/application/Configuration/ConfigurationApplicationClient.d.ts +20 -20
  12. package/sdk/application/Configuration/ConfigurationApplicationClient.js +10 -10
  13. package/sdk/application/Content/ContentApplicationClient.d.ts +30 -51
  14. package/sdk/application/Content/ContentApplicationClient.js +56 -161
  15. package/sdk/application/FileStorage/FileStorageApplicationClient.d.ts +11 -9
  16. package/sdk/application/FileStorage/FileStorageApplicationClient.js +10 -7
  17. package/sdk/application/Lead/LeadApplicationClient.d.ts +2 -2
  18. package/sdk/application/Lead/LeadApplicationClient.js +1 -1
  19. package/sdk/application/Logistic/LogisticApplicationClient.d.ts +15 -35
  20. package/sdk/application/Logistic/LogisticApplicationClient.js +8 -101
  21. package/sdk/application/Order/OrderApplicationClient.d.ts +12 -22
  22. package/sdk/application/Order/OrderApplicationClient.js +8 -56
  23. package/sdk/application/Payment/PaymentApplicationClient.d.ts +87 -87
  24. package/sdk/application/Payment/PaymentApplicationClient.js +46 -46
  25. package/sdk/application/Rewards/RewardsApplicationClient.d.ts +13 -13
  26. package/sdk/application/Rewards/RewardsApplicationClient.js +7 -7
  27. package/sdk/application/Theme/ThemeApplicationClient.d.ts +2 -2
  28. package/sdk/application/Theme/ThemeApplicationClient.js +2 -4
  29. package/sdk/application/User/UserApplicationClient.d.ts +10 -10
  30. package/sdk/application/User/UserApplicationClient.js +6 -6
  31. package/sdk/application/Webhook/WebhookApplicationClient.d.ts +4 -4
  32. package/sdk/application/Webhook/WebhookApplicationClient.js +3 -3
  33. package/sdk/common/Utility.js +6 -3
  34. package/sdk/common/utils.d.ts +0 -1
  35. package/sdk/common/utils.js +0 -14
  36. package/sdk/partner/FileStorage/FileStoragePartnerClient.d.ts +12 -86
  37. package/sdk/partner/FileStorage/FileStoragePartnerClient.js +24 -582
  38. package/sdk/partner/FileStorage/FileStoragePartnerModel.d.ts +21 -116
  39. package/sdk/partner/FileStorage/FileStoragePartnerModel.js +16 -121
  40. package/sdk/partner/FileStorage/FileStoragePartnerValidator.d.ts +1 -8
  41. package/sdk/partner/FileStorage/FileStoragePartnerValidator.js +4 -51
  42. package/sdk/partner/Lead/LeadPartnerClient.d.ts +2 -2
  43. package/sdk/partner/Lead/LeadPartnerClient.js +2 -2
  44. package/sdk/partner/Lead/LeadPartnerModel.d.ts +5 -5
  45. package/sdk/partner/Lead/LeadPartnerModel.js +15 -15
  46. package/sdk/partner/Logistics/LogisticsPartnerClient.d.ts +20 -126
  47. package/sdk/partner/Logistics/LogisticsPartnerClient.js +20 -970
  48. package/sdk/partner/Logistics/LogisticsPartnerModel.d.ts +167 -1200
  49. package/sdk/partner/Logistics/LogisticsPartnerModel.js +160 -571
  50. package/sdk/partner/Logistics/LogisticsPartnerValidator.d.ts +0 -10
  51. package/sdk/partner/Logistics/LogisticsPartnerValidator.js +7 -121
  52. package/sdk/partner/Theme/ThemePartnerClient.d.ts +10 -8
  53. package/sdk/partner/Theme/ThemePartnerClient.js +16 -14
  54. package/sdk/partner/Theme/ThemePartnerModel.d.ts +37 -96
  55. package/sdk/partner/Theme/ThemePartnerModel.js +36 -90
  56. package/sdk/partner/Theme/ThemePartnerValidator.js +4 -4
  57. package/sdk/partner/Webhook/WebhookPartnerClient.d.ts +18 -28
  58. package/sdk/partner/Webhook/WebhookPartnerClient.js +18 -103
  59. package/sdk/partner/Webhook/WebhookPartnerModel.d.ts +179 -612
  60. package/sdk/partner/Webhook/WebhookPartnerModel.js +150 -253
  61. package/sdk/partner/Webhook/WebhookPartnerValidator.d.ts +0 -1
  62. package/sdk/partner/Webhook/WebhookPartnerValidator.js +3 -11
  63. package/sdk/platform/Analytics/AnalyticsPlatformApplicationClient.d.ts +4 -5
  64. package/sdk/platform/Analytics/AnalyticsPlatformApplicationClient.js +8 -14
  65. package/sdk/platform/Analytics/AnalyticsPlatformModel.d.ts +9 -59
  66. package/sdk/platform/Analytics/AnalyticsPlatformModel.js +4 -40
  67. package/sdk/platform/AuditTrail/AuditTrailPlatformClient.d.ts +32 -2
  68. package/sdk/platform/AuditTrail/AuditTrailPlatformClient.js +243 -3
  69. package/sdk/platform/AuditTrail/AuditTrailPlatformModel.d.ts +130 -11
  70. package/sdk/platform/AuditTrail/AuditTrailPlatformModel.js +152 -12
  71. package/sdk/platform/AuditTrail/AuditTrailPlatformValidator.d.ts +39 -1
  72. package/sdk/platform/AuditTrail/AuditTrailPlatformValidator.js +35 -0
  73. package/sdk/platform/Billing/BillingPlatformClient.d.ts +12 -12
  74. package/sdk/platform/Billing/BillingPlatformClient.js +15 -15
  75. package/sdk/platform/Billing/BillingPlatformModel.d.ts +388 -443
  76. package/sdk/platform/Billing/BillingPlatformModel.js +263 -280
  77. package/sdk/platform/Billing/BillingPlatformValidator.d.ts +18 -16
  78. package/sdk/platform/Billing/BillingPlatformValidator.js +9 -8
  79. package/sdk/platform/Cart/CartPlatformApplicationClient.d.ts +103 -134
  80. package/sdk/platform/Cart/CartPlatformApplicationClient.js +115 -419
  81. package/sdk/platform/Cart/CartPlatformApplicationValidator.d.ts +65 -121
  82. package/sdk/platform/Cart/CartPlatformApplicationValidator.js +44 -109
  83. package/sdk/platform/Cart/CartPlatformModel.d.ts +1294 -5068
  84. package/sdk/platform/Cart/CartPlatformModel.js +1217 -1992
  85. package/sdk/platform/Catalog/CatalogPlatformApplicationClient.d.ts +183 -209
  86. package/sdk/platform/Catalog/CatalogPlatformApplicationClient.js +400 -457
  87. package/sdk/platform/Catalog/CatalogPlatformApplicationValidator.d.ts +142 -185
  88. package/sdk/platform/Catalog/CatalogPlatformApplicationValidator.js +78 -96
  89. package/sdk/platform/Catalog/CatalogPlatformClient.d.ts +117 -154
  90. package/sdk/platform/Catalog/CatalogPlatformClient.js +172 -292
  91. package/sdk/platform/Catalog/CatalogPlatformModel.d.ts +1647 -6389
  92. package/sdk/platform/Catalog/CatalogPlatformModel.js +1681 -3222
  93. package/sdk/platform/Catalog/CatalogPlatformValidator.d.ts +31 -72
  94. package/sdk/platform/Catalog/CatalogPlatformValidator.js +24 -50
  95. package/sdk/platform/Common/CommonPlatformClient.d.ts +2 -3
  96. package/sdk/platform/Common/CommonPlatformClient.js +2 -3
  97. package/sdk/platform/Common/CommonPlatformModel.d.ts +9 -9
  98. package/sdk/platform/Common/CommonPlatformModel.js +6 -6
  99. package/sdk/platform/Communication/CommunicationPlatformApplicationClient.d.ts +17 -16
  100. package/sdk/platform/Communication/CommunicationPlatformApplicationClient.js +17 -16
  101. package/sdk/platform/Communication/CommunicationPlatformApplicationValidator.d.ts +8 -8
  102. package/sdk/platform/Communication/CommunicationPlatformApplicationValidator.js +8 -8
  103. package/sdk/platform/Communication/CommunicationPlatformModel.d.ts +33 -43
  104. package/sdk/platform/Communication/CommunicationPlatformModel.js +34 -38
  105. package/sdk/platform/CompanyProfile/CompanyProfilePlatformClient.d.ts +42 -46
  106. package/sdk/platform/CompanyProfile/CompanyProfilePlatformClient.js +43 -47
  107. package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.d.ts +223 -223
  108. package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.js +212 -210
  109. package/sdk/platform/CompanyProfile/CompanyProfilePlatformValidator.d.ts +12 -12
  110. package/sdk/platform/CompanyProfile/CompanyProfilePlatformValidator.js +12 -12
  111. package/sdk/platform/Configuration/ConfigurationPlatformApplicationClient.d.ts +33 -46
  112. package/sdk/platform/Configuration/ConfigurationPlatformApplicationClient.js +54 -67
  113. package/sdk/platform/Configuration/ConfigurationPlatformApplicationValidator.d.ts +18 -18
  114. package/sdk/platform/Configuration/ConfigurationPlatformApplicationValidator.js +18 -18
  115. package/sdk/platform/Configuration/ConfigurationPlatformClient.d.ts +24 -45
  116. package/sdk/platform/Configuration/ConfigurationPlatformClient.js +30 -134
  117. package/sdk/platform/Configuration/ConfigurationPlatformModel.d.ts +131 -283
  118. package/sdk/platform/Configuration/ConfigurationPlatformModel.js +97 -219
  119. package/sdk/platform/Configuration/ConfigurationPlatformValidator.d.ts +9 -37
  120. package/sdk/platform/Configuration/ConfigurationPlatformValidator.js +8 -27
  121. package/sdk/platform/Content/ContentPlatformApplicationClient.d.ts +141 -204
  122. package/sdk/platform/Content/ContentPlatformApplicationClient.js +475 -1073
  123. package/sdk/platform/Content/ContentPlatformApplicationValidator.d.ts +141 -253
  124. package/sdk/platform/Content/ContentPlatformApplicationValidator.js +130 -256
  125. package/sdk/platform/Content/ContentPlatformClient.d.ts +106 -142
  126. package/sdk/platform/Content/ContentPlatformClient.js +336 -523
  127. package/sdk/platform/Content/ContentPlatformModel.d.ts +403 -1375
  128. package/sdk/platform/Content/ContentPlatformModel.js +394 -631
  129. package/sdk/platform/Content/ContentPlatformValidator.d.ts +117 -168
  130. package/sdk/platform/Content/ContentPlatformValidator.js +108 -162
  131. package/sdk/platform/Discount/DiscountPlatformClient.d.ts +12 -14
  132. package/sdk/platform/Discount/DiscountPlatformClient.js +12 -14
  133. package/sdk/platform/Discount/DiscountPlatformModel.d.ts +13 -13
  134. package/sdk/platform/Discount/DiscountPlatformModel.js +12 -12
  135. package/sdk/platform/Discount/DiscountPlatformValidator.d.ts +2 -2
  136. package/sdk/platform/Discount/DiscountPlatformValidator.js +2 -2
  137. package/sdk/platform/FileStorage/FileStoragePlatformApplicationClient.d.ts +39 -95
  138. package/sdk/platform/FileStorage/FileStoragePlatformApplicationClient.js +63 -462
  139. package/sdk/platform/FileStorage/FileStoragePlatformApplicationValidator.d.ts +15 -62
  140. package/sdk/platform/FileStorage/FileStoragePlatformApplicationValidator.js +13 -75
  141. package/sdk/platform/FileStorage/FileStoragePlatformClient.d.ts +22 -20
  142. package/sdk/platform/FileStorage/FileStoragePlatformClient.js +24 -21
  143. package/sdk/platform/FileStorage/FileStoragePlatformModel.d.ts +116 -370
  144. package/sdk/platform/FileStorage/FileStoragePlatformModel.js +104 -313
  145. package/sdk/platform/FileStorage/FileStoragePlatformValidator.d.ts +6 -6
  146. package/sdk/platform/FileStorage/FileStoragePlatformValidator.js +6 -6
  147. package/sdk/platform/Finance/FinancePlatformClient.d.ts +320 -0
  148. package/sdk/platform/Finance/FinancePlatformClient.js +2333 -0
  149. package/sdk/platform/Finance/FinancePlatformModel.d.ts +2890 -0
  150. package/sdk/platform/Finance/FinancePlatformModel.js +2148 -0
  151. package/sdk/platform/Finance/FinancePlatformValidator.d.ts +284 -0
  152. package/sdk/platform/Finance/FinancePlatformValidator.js +354 -0
  153. package/sdk/platform/Lead/LeadPlatformClient.d.ts +2 -2
  154. package/sdk/platform/Lead/LeadPlatformClient.js +2 -2
  155. package/sdk/platform/Lead/LeadPlatformModel.d.ts +5 -5
  156. package/sdk/platform/Lead/LeadPlatformModel.js +16 -16
  157. package/sdk/platform/Order/OrderPlatformApplicationClient.d.ts +6 -17
  158. package/sdk/platform/Order/OrderPlatformApplicationClient.js +7 -85
  159. package/sdk/platform/Order/OrderPlatformApplicationValidator.d.ts +24 -95
  160. package/sdk/platform/Order/OrderPlatformApplicationValidator.js +19 -39
  161. package/sdk/platform/Order/OrderPlatformClient.d.ts +96 -153
  162. package/sdk/platform/Order/OrderPlatformClient.js +198 -416
  163. package/sdk/platform/Order/OrderPlatformModel.d.ts +1286 -7619
  164. package/sdk/platform/Order/OrderPlatformModel.js +1265 -3922
  165. package/sdk/platform/Order/OrderPlatformValidator.d.ts +109 -270
  166. package/sdk/platform/Order/OrderPlatformValidator.js +77 -135
  167. package/sdk/platform/Partner/PartnerPlatformApplicationClient.d.ts +4 -6
  168. package/sdk/platform/Partner/PartnerPlatformApplicationClient.js +7 -9
  169. package/sdk/platform/Partner/PartnerPlatformModel.d.ts +9 -9
  170. package/sdk/platform/Partner/PartnerPlatformModel.js +8 -8
  171. package/sdk/platform/Payment/PaymentPlatformApplicationClient.d.ts +105 -93
  172. package/sdk/platform/Payment/PaymentPlatformApplicationClient.js +141 -129
  173. package/sdk/platform/Payment/PaymentPlatformApplicationValidator.d.ts +48 -48
  174. package/sdk/platform/Payment/PaymentPlatformApplicationValidator.js +48 -48
  175. package/sdk/platform/Payment/PaymentPlatformClient.d.ts +20 -20
  176. package/sdk/platform/Payment/PaymentPlatformClient.js +20 -20
  177. package/sdk/platform/Payment/PaymentPlatformModel.d.ts +319 -333
  178. package/sdk/platform/Payment/PaymentPlatformModel.js +278 -288
  179. package/sdk/platform/Payment/PaymentPlatformValidator.d.ts +8 -8
  180. package/sdk/platform/Payment/PaymentPlatformValidator.js +8 -8
  181. package/sdk/platform/PlatformClient.d.ts +2 -0
  182. package/sdk/platform/PlatformClient.js +4 -0
  183. package/sdk/platform/Rewards/RewardsPlatformApplicationClient.d.ts +2 -2
  184. package/sdk/platform/Rewards/RewardsPlatformApplicationClient.js +2 -2
  185. package/sdk/platform/Rewards/RewardsPlatformApplicationValidator.d.ts +2 -2
  186. package/sdk/platform/Rewards/RewardsPlatformApplicationValidator.js +2 -2
  187. package/sdk/platform/Rewards/RewardsPlatformModel.d.ts +9 -9
  188. package/sdk/platform/Rewards/RewardsPlatformModel.js +8 -8
  189. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationClient.d.ts +36 -46
  190. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationClient.js +41 -132
  191. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationValidator.d.ts +17 -46
  192. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationValidator.js +14 -34
  193. package/sdk/platform/Serviceability/ServiceabilityPlatformClient.d.ts +46 -40
  194. package/sdk/platform/Serviceability/ServiceabilityPlatformClient.js +68 -62
  195. package/sdk/platform/Serviceability/ServiceabilityPlatformModel.d.ts +612 -1845
  196. package/sdk/platform/Serviceability/ServiceabilityPlatformModel.js +554 -886
  197. package/sdk/platform/Serviceability/ServiceabilityPlatformValidator.d.ts +49 -45
  198. package/sdk/platform/Serviceability/ServiceabilityPlatformValidator.js +30 -28
  199. package/sdk/platform/Share/SharePlatformApplicationClient.d.ts +5 -5
  200. package/sdk/platform/Share/SharePlatformApplicationClient.js +9 -9
  201. package/sdk/platform/Share/SharePlatformApplicationValidator.d.ts +6 -3
  202. package/sdk/platform/Share/SharePlatformApplicationValidator.js +2 -2
  203. package/sdk/platform/Share/SharePlatformModel.d.ts +7 -46
  204. package/sdk/platform/Share/SharePlatformModel.js +6 -31
  205. package/sdk/platform/Theme/ThemePlatformApplicationClient.d.ts +3 -3
  206. package/sdk/platform/Theme/ThemePlatformApplicationClient.js +4 -8
  207. package/sdk/platform/Theme/ThemePlatformApplicationValidator.d.ts +0 -5
  208. package/sdk/platform/Theme/ThemePlatformApplicationValidator.js +0 -2
  209. package/sdk/platform/Theme/ThemePlatformModel.d.ts +11 -37
  210. package/sdk/platform/Theme/ThemePlatformModel.js +15 -33
  211. package/sdk/platform/User/UserPlatformApplicationClient.d.ts +12 -12
  212. package/sdk/platform/User/UserPlatformApplicationClient.js +12 -12
  213. package/sdk/platform/User/UserPlatformApplicationValidator.d.ts +2 -2
  214. package/sdk/platform/User/UserPlatformApplicationValidator.js +2 -2
  215. package/sdk/platform/User/UserPlatformModel.d.ts +21 -21
  216. package/sdk/platform/User/UserPlatformModel.js +23 -23
  217. package/sdk/platform/Webhook/WebhookPlatformClient.d.ts +78 -25
  218. package/sdk/platform/Webhook/WebhookPlatformClient.js +470 -75
  219. package/sdk/platform/Webhook/WebhookPlatformModel.d.ts +427 -720
  220. package/sdk/platform/Webhook/WebhookPlatformModel.js +386 -410
  221. package/sdk/platform/Webhook/WebhookPlatformValidator.d.ts +55 -10
  222. package/sdk/platform/Webhook/WebhookPlatformValidator.js +72 -12
  223. package/sdk/platform/index.d.ts +1 -0
  224. package/sdk/platform/index.js +2 -0
  225. package/sdk/public/Configuration/ConfigurationPublicClient.d.ts +2 -3
  226. package/sdk/public/Configuration/ConfigurationPublicClient.js +5 -6
  227. package/sdk/public/Configuration/ConfigurationPublicModel.d.ts +9 -9
  228. package/sdk/public/Configuration/ConfigurationPublicModel.js +6 -6
  229. package/sdk/public/Content/ContentPublicClient.d.ts +2 -112
  230. package/sdk/public/Content/ContentPublicClient.js +6 -810
  231. package/sdk/public/Content/ContentPublicModel.d.ts +3 -549
  232. package/sdk/public/Content/ContentPublicModel.js +3 -649
  233. package/sdk/public/Content/ContentPublicValidator.d.ts +3 -69
  234. package/sdk/public/Content/ContentPublicValidator.js +2 -88
  235. package/sdk/public/Webhook/WebhookPublicClient.d.ts +8 -8
  236. package/sdk/public/Webhook/WebhookPublicClient.js +8 -8
  237. package/sdk/public/Webhook/WebhookPublicModel.d.ts +21 -21
  238. package/sdk/public/Webhook/WebhookPublicModel.js +15 -15
  239. package/sdk/public/Webhook/WebhookPublicValidator.d.ts +4 -4
  240. package/sdk/public/Webhook/WebhookPublicValidator.js +4 -4
  241. package/sdk/application/Finance/FinanceApplicationClient.d.ts +0 -29
  242. package/sdk/application/Finance/FinanceApplicationClient.js +0 -111
@@ -416,6 +416,93 @@ class Content {
416
416
  return response;
417
417
  }
418
418
 
419
+ /**
420
+ * @param {ContentPlatformApplicationValidator.CreateAppCustomFieldByResourceIdParam} arg
421
+ * - Arg object
422
+ *
423
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
424
+ * @param {import("../PlatformAPIClient").Options} - Options
425
+ * @returns {Promise<ContentPlatformModel.CustomFieldsResponseByResourceIdSchema>}
426
+ * - Success response
427
+ *
428
+ * @name createAppCustomFieldByResourceId
429
+ * @summary: Create custom field entries for gives resource and resource_id
430
+ * @description: You can add a custom field using this endpoint to any resource by providing the resource ID. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/createAppCustomFieldByResourceId/).
431
+ */
432
+ async createAppCustomFieldByResourceId(
433
+ { resource, resourceId, body, requestHeaders } = { requestHeaders: {} },
434
+ { responseHeaders } = { responseHeaders: false }
435
+ ) {
436
+ const {
437
+ error,
438
+ } = ContentPlatformApplicationValidator.createAppCustomFieldByResourceId().validate(
439
+ {
440
+ resource,
441
+ resourceId,
442
+ body,
443
+ },
444
+ { abortEarly: false, allowUnknown: true }
445
+ );
446
+ if (error) {
447
+ return Promise.reject(new FDKClientValidationError(error));
448
+ }
449
+
450
+ // Showing warrnings if extra unknown parameters are found
451
+ const {
452
+ error: warrning,
453
+ } = ContentPlatformApplicationValidator.createAppCustomFieldByResourceId().validate(
454
+ {
455
+ resource,
456
+ resourceId,
457
+ body,
458
+ },
459
+ { abortEarly: false, allowUnknown: false }
460
+ );
461
+ if (warrning) {
462
+ Logger({
463
+ level: "WARN",
464
+ message: `Parameter Validation warrnings for platform > Content > createAppCustomFieldByResourceId \n ${warrning}`,
465
+ });
466
+ }
467
+
468
+ const query_params = {};
469
+
470
+ const response = await PlatformAPIClient.execute(
471
+ this.config,
472
+ "put",
473
+ `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/metafields/${resource}/${resourceId}`,
474
+ query_params,
475
+ body,
476
+ requestHeaders,
477
+ { responseHeaders }
478
+ );
479
+
480
+ let responseData = response;
481
+ if (responseHeaders) {
482
+ responseData = response[0];
483
+ }
484
+
485
+ const {
486
+ error: res_error,
487
+ } = ContentPlatformModel.CustomFieldsResponseByResourceIdSchema().validate(
488
+ responseData,
489
+ { abortEarly: false, allowUnknown: true }
490
+ );
491
+
492
+ if (res_error) {
493
+ if (this.config.options.strictResponseCheck === true) {
494
+ return Promise.reject(new FDKResponseValidationError(res_error));
495
+ } else {
496
+ Logger({
497
+ level: "WARN",
498
+ message: `Response Validation Warnings for platform > Content > createAppCustomFieldByResourceId \n ${res_error}`,
499
+ });
500
+ }
501
+ }
502
+
503
+ return response;
504
+ }
505
+
419
506
  /**
420
507
  * @param {ContentPlatformApplicationValidator.CreateAppCustomFieldDefinitionParam} arg
421
508
  * - Arg object
@@ -426,18 +513,17 @@ class Content {
426
513
  * - Success response
427
514
  *
428
515
  * @name createAppCustomFieldDefinition
429
- * @summary: Create custom field definition for a given resource type
516
+ * @summary: Create custom field definition
430
517
  * @description: You can create custom fields definition to any resource so you can extend property of resource. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/createAppCustomFieldDefinition/).
431
518
  */
432
519
  async createAppCustomFieldDefinition(
433
- { resource, body, requestHeaders } = { requestHeaders: {} },
520
+ { body, requestHeaders } = { requestHeaders: {} },
434
521
  { responseHeaders } = { responseHeaders: false }
435
522
  ) {
436
523
  const {
437
524
  error,
438
525
  } = ContentPlatformApplicationValidator.createAppCustomFieldDefinition().validate(
439
526
  {
440
- resource,
441
527
  body,
442
528
  },
443
529
  { abortEarly: false, allowUnknown: true }
@@ -451,7 +537,6 @@ class Content {
451
537
  error: warrning,
452
538
  } = ContentPlatformApplicationValidator.createAppCustomFieldDefinition().validate(
453
539
  {
454
- resource,
455
540
  body,
456
541
  },
457
542
  { abortEarly: false, allowUnknown: false }
@@ -468,7 +553,7 @@ class Content {
468
553
  const response = await PlatformAPIClient.execute(
469
554
  this.config,
470
555
  "post",
471
- `/service/platform/content/v2.0/company/${this.config.companyId}/application/${this.applicationId}/customfields/resource/${resource}/definition`,
556
+ `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/metafields/definitions`,
472
557
  query_params,
473
558
  body,
474
559
  requestHeaders,
@@ -502,25 +587,24 @@ class Content {
502
587
  }
503
588
 
504
589
  /**
505
- * @param {ContentPlatformApplicationValidator.CreateAppCustomObjectBySlugParam} arg
590
+ * @param {ContentPlatformApplicationValidator.CreateAppCustomObjectParam} arg
506
591
  * - Arg object
507
592
  *
508
593
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
509
594
  * @param {import("../PlatformAPIClient").Options} - Options
510
595
  * @returns {Promise<ContentPlatformModel.CustomObjectSchema>} - Success response
511
- * @name createAppCustomObjectBySlug
596
+ * @name createAppCustomObject
512
597
  * @summary: Create custom object entries
513
- * @description: Custom object entries against the custom object definition can be added using this API. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/createAppCustomObjectBySlug/).
598
+ * @description: Custom object entries against the custom object definition can be added using this API. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/createAppCustomObject/).
514
599
  */
515
- async createAppCustomObjectBySlug(
516
- { definitionSlug, body, requestHeaders } = { requestHeaders: {} },
600
+ async createAppCustomObject(
601
+ { body, requestHeaders } = { requestHeaders: {} },
517
602
  { responseHeaders } = { responseHeaders: false }
518
603
  ) {
519
604
  const {
520
605
  error,
521
- } = ContentPlatformApplicationValidator.createAppCustomObjectBySlug().validate(
606
+ } = ContentPlatformApplicationValidator.createAppCustomObject().validate(
522
607
  {
523
- definitionSlug,
524
608
  body,
525
609
  },
526
610
  { abortEarly: false, allowUnknown: true }
@@ -532,9 +616,8 @@ class Content {
532
616
  // Showing warrnings if extra unknown parameters are found
533
617
  const {
534
618
  error: warrning,
535
- } = ContentPlatformApplicationValidator.createAppCustomObjectBySlug().validate(
619
+ } = ContentPlatformApplicationValidator.createAppCustomObject().validate(
536
620
  {
537
- definitionSlug,
538
621
  body,
539
622
  },
540
623
  { abortEarly: false, allowUnknown: false }
@@ -542,7 +625,7 @@ class Content {
542
625
  if (warrning) {
543
626
  Logger({
544
627
  level: "WARN",
545
- message: `Parameter Validation warrnings for platform > Content > createAppCustomObjectBySlug \n ${warrning}`,
628
+ message: `Parameter Validation warrnings for platform > Content > createAppCustomObject \n ${warrning}`,
546
629
  });
547
630
  }
548
631
 
@@ -551,7 +634,7 @@ class Content {
551
634
  const response = await PlatformAPIClient.execute(
552
635
  this.config,
553
636
  "post",
554
- `/service/platform/content/v2.0/company/${this.config.companyId}/application/${this.applicationId}/customobjects/definition/${definitionSlug}/entries`,
637
+ `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/metaobjects`,
555
638
  query_params,
556
639
  body,
557
640
  requestHeaders,
@@ -576,7 +659,7 @@ class Content {
576
659
  } else {
577
660
  Logger({
578
661
  level: "WARN",
579
- message: `Response Validation Warnings for platform > Content > createAppCustomObjectBySlug \n ${res_error}`,
662
+ message: `Response Validation Warnings for platform > Content > createAppCustomObject \n ${res_error}`,
580
663
  });
581
664
  }
582
665
  }
@@ -590,9 +673,8 @@ class Content {
590
673
  *
591
674
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
592
675
  * @param {import("../PlatformAPIClient").Options} - Options
593
- * @returns {Promise<ContentPlatformModel.CustomObjectDefinitionSlugSchema>}
594
- * - Success response
595
- *
676
+ * @returns {Promise<ContentPlatformModel.CustomObjectDefinitionSchema>} -
677
+ * Success response
596
678
  * @name createAppCustomObjectDefinition
597
679
  * @summary: Create custom object definition
598
680
  * @description: Create a custom object that will have a collection of custom fields and can be used anywhere in the custom field for any resource. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/createAppCustomObjectDefinition/).
@@ -634,7 +716,7 @@ class Content {
634
716
  const response = await PlatformAPIClient.execute(
635
717
  this.config,
636
718
  "post",
637
- `/service/platform/content/v2.0/company/${this.config.companyId}/application/${this.applicationId}/customobjects/definition`,
719
+ `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/metaobjects/definitions`,
638
720
  query_params,
639
721
  body,
640
722
  requestHeaders,
@@ -648,7 +730,7 @@ class Content {
648
730
 
649
731
  const {
650
732
  error: res_error,
651
- } = ContentPlatformModel.CustomObjectDefinitionSlugSchema().validate(
733
+ } = ContentPlatformModel.CustomObjectDefinitionSchema().validate(
652
734
  responseData,
653
735
  { abortEarly: false, allowUnknown: true }
654
736
  );
@@ -1224,86 +1306,6 @@ class Content {
1224
1306
  return response;
1225
1307
  }
1226
1308
 
1227
- /**
1228
- * @param {ContentPlatformApplicationValidator.CreateSitemapParam} arg - Arg object
1229
- * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
1230
- * @param {import("../PlatformAPIClient").Options} - Options
1231
- * @returns {Promise<ContentPlatformModel.SitemapConfig>} - Success response
1232
- * @name createSitemap
1233
- * @summary: Create a new sitemap configuration
1234
- * @description: Create a new sitemap configuration for a specific company and application. The name must be unique within the scope of the application. The sitemap XML data must be valid XML following the sitemap protocol specification. Once created, the configuration can be activated or deactivated using the is_active flag.
1235
- * - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/createSitemap/).
1236
- */
1237
- async createSitemap(
1238
- { body, requestHeaders } = { requestHeaders: {} },
1239
- { responseHeaders } = { responseHeaders: false }
1240
- ) {
1241
- const {
1242
- error,
1243
- } = ContentPlatformApplicationValidator.createSitemap().validate(
1244
- {
1245
- body,
1246
- },
1247
- { abortEarly: false, allowUnknown: true }
1248
- );
1249
- if (error) {
1250
- return Promise.reject(new FDKClientValidationError(error));
1251
- }
1252
-
1253
- // Showing warrnings if extra unknown parameters are found
1254
- const {
1255
- error: warrning,
1256
- } = ContentPlatformApplicationValidator.createSitemap().validate(
1257
- {
1258
- body,
1259
- },
1260
- { abortEarly: false, allowUnknown: false }
1261
- );
1262
- if (warrning) {
1263
- Logger({
1264
- level: "WARN",
1265
- message: `Parameter Validation warrnings for platform > Content > createSitemap \n ${warrning}`,
1266
- });
1267
- }
1268
-
1269
- const query_params = {};
1270
-
1271
- const response = await PlatformAPIClient.execute(
1272
- this.config,
1273
- "post",
1274
- `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/seo/sitemaps`,
1275
- query_params,
1276
- body,
1277
- requestHeaders,
1278
- { responseHeaders }
1279
- );
1280
-
1281
- let responseData = response;
1282
- if (responseHeaders) {
1283
- responseData = response[0];
1284
- }
1285
-
1286
- const {
1287
- error: res_error,
1288
- } = ContentPlatformModel.SitemapConfig().validate(responseData, {
1289
- abortEarly: false,
1290
- allowUnknown: true,
1291
- });
1292
-
1293
- if (res_error) {
1294
- if (this.config.options.strictResponseCheck === true) {
1295
- return Promise.reject(new FDKResponseValidationError(res_error));
1296
- } else {
1297
- Logger({
1298
- level: "WARN",
1299
- message: `Response Validation Warnings for platform > Content > createSitemap \n ${res_error}`,
1300
- });
1301
- }
1302
- }
1303
-
1304
- return response;
1305
- }
1306
-
1307
1309
  /**
1308
1310
  * @param {ContentPlatformApplicationValidator.CreateSlideshowParam} arg - Arg object
1309
1311
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
@@ -1466,27 +1468,25 @@ class Content {
1466
1468
  }
1467
1469
 
1468
1470
  /**
1469
- * @param {ContentPlatformApplicationValidator.DeleteAppCustomFieldDefinitionBySlugParam} arg
1471
+ * @param {ContentPlatformApplicationValidator.DeleteAppCustomFieldDefinitionParam} arg
1470
1472
  * - Arg object
1471
1473
  *
1472
1474
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
1473
1475
  * @param {import("../PlatformAPIClient").Options} - Options
1474
1476
  * @returns {Promise<ContentPlatformModel.CustomDataDeleteSchema>} - Success response
1475
- * @name deleteAppCustomFieldDefinitionBySlug
1477
+ * @name deleteAppCustomFieldDefinition
1476
1478
  * @summary: Delete custom fields definition
1477
- * @description: Custom field definition and its assosiated custom fields value can be deleted using this api on the basis of definition id. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/deleteAppCustomFieldDefinitionBySlug/).
1479
+ * @description: Custom field definition and its assosiated custom fields value can be deleted using this api on the basis of definition id. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/deleteAppCustomFieldDefinition/).
1478
1480
  */
1479
- async deleteAppCustomFieldDefinitionBySlug(
1480
- { slug, resource, namespace, requestHeaders } = { requestHeaders: {} },
1481
+ async deleteAppCustomFieldDefinition(
1482
+ { definitionId, requestHeaders } = { requestHeaders: {} },
1481
1483
  { responseHeaders } = { responseHeaders: false }
1482
1484
  ) {
1483
1485
  const {
1484
1486
  error,
1485
- } = ContentPlatformApplicationValidator.deleteAppCustomFieldDefinitionBySlug().validate(
1487
+ } = ContentPlatformApplicationValidator.deleteAppCustomFieldDefinition().validate(
1486
1488
  {
1487
- slug,
1488
- resource,
1489
- namespace,
1489
+ definitionId,
1490
1490
  },
1491
1491
  { abortEarly: false, allowUnknown: true }
1492
1492
  );
@@ -1497,18 +1497,16 @@ class Content {
1497
1497
  // Showing warrnings if extra unknown parameters are found
1498
1498
  const {
1499
1499
  error: warrning,
1500
- } = ContentPlatformApplicationValidator.deleteAppCustomFieldDefinitionBySlug().validate(
1500
+ } = ContentPlatformApplicationValidator.deleteAppCustomFieldDefinition().validate(
1501
1501
  {
1502
- slug,
1503
- resource,
1504
- namespace,
1502
+ definitionId,
1505
1503
  },
1506
1504
  { abortEarly: false, allowUnknown: false }
1507
1505
  );
1508
1506
  if (warrning) {
1509
1507
  Logger({
1510
1508
  level: "WARN",
1511
- message: `Parameter Validation warrnings for platform > Content > deleteAppCustomFieldDefinitionBySlug \n ${warrning}`,
1509
+ message: `Parameter Validation warrnings for platform > Content > deleteAppCustomFieldDefinition \n ${warrning}`,
1512
1510
  });
1513
1511
  }
1514
1512
 
@@ -1517,7 +1515,7 @@ class Content {
1517
1515
  const response = await PlatformAPIClient.execute(
1518
1516
  this.config,
1519
1517
  "delete",
1520
- `/service/platform/content/v2.0/company/${this.config.companyId}/application/${this.applicationId}/customfields/resource/${resource}/namespace/${namespace}/definition/${slug}`,
1518
+ `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/metafields/definitions/${definitionId}`,
1521
1519
  query_params,
1522
1520
  undefined,
1523
1521
  requestHeaders,
@@ -1542,7 +1540,7 @@ class Content {
1542
1540
  } else {
1543
1541
  Logger({
1544
1542
  level: "WARN",
1545
- message: `Response Validation Warnings for platform > Content > deleteAppCustomFieldDefinitionBySlug \n ${res_error}`,
1543
+ message: `Response Validation Warnings for platform > Content > deleteAppCustomFieldDefinition \n ${res_error}`,
1546
1544
  });
1547
1545
  }
1548
1546
  }
@@ -1551,26 +1549,25 @@ class Content {
1551
1549
  }
1552
1550
 
1553
1551
  /**
1554
- * @param {ContentPlatformApplicationValidator.DeleteAppCustomObjectBySlugParam} arg
1552
+ * @param {ContentPlatformApplicationValidator.DeleteAppCustomObjectParam} arg
1555
1553
  * - Arg object
1556
1554
  *
1557
1555
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
1558
1556
  * @param {import("../PlatformAPIClient").Options} - Options
1559
1557
  * @returns {Promise<ContentPlatformModel.CustomDataDeleteSchema>} - Success response
1560
- * @name deleteAppCustomObjectBySlug
1558
+ * @name deleteAppCustomObject
1561
1559
  * @summary: Delete custom object
1562
- * @description: A Custom object entry can be deleted by providing the custom object definition slug and custom object entry slug using this endpoint. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/deleteAppCustomObjectBySlug/).
1560
+ * @description: Custom object entries can be deleted by providing the delete ID using this endpoint. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/deleteAppCustomObject/).
1563
1561
  */
1564
- async deleteAppCustomObjectBySlug(
1565
- { definitionSlug, slug, requestHeaders } = { requestHeaders: {} },
1562
+ async deleteAppCustomObject(
1563
+ { metaobjectId, requestHeaders } = { requestHeaders: {} },
1566
1564
  { responseHeaders } = { responseHeaders: false }
1567
1565
  ) {
1568
1566
  const {
1569
1567
  error,
1570
- } = ContentPlatformApplicationValidator.deleteAppCustomObjectBySlug().validate(
1568
+ } = ContentPlatformApplicationValidator.deleteAppCustomObject().validate(
1571
1569
  {
1572
- definitionSlug,
1573
- slug,
1570
+ metaobjectId,
1574
1571
  },
1575
1572
  { abortEarly: false, allowUnknown: true }
1576
1573
  );
@@ -1581,17 +1578,16 @@ class Content {
1581
1578
  // Showing warrnings if extra unknown parameters are found
1582
1579
  const {
1583
1580
  error: warrning,
1584
- } = ContentPlatformApplicationValidator.deleteAppCustomObjectBySlug().validate(
1581
+ } = ContentPlatformApplicationValidator.deleteAppCustomObject().validate(
1585
1582
  {
1586
- definitionSlug,
1587
- slug,
1583
+ metaobjectId,
1588
1584
  },
1589
1585
  { abortEarly: false, allowUnknown: false }
1590
1586
  );
1591
1587
  if (warrning) {
1592
1588
  Logger({
1593
1589
  level: "WARN",
1594
- message: `Parameter Validation warrnings for platform > Content > deleteAppCustomObjectBySlug \n ${warrning}`,
1590
+ message: `Parameter Validation warrnings for platform > Content > deleteAppCustomObject \n ${warrning}`,
1595
1591
  });
1596
1592
  }
1597
1593
 
@@ -1600,7 +1596,7 @@ class Content {
1600
1596
  const response = await PlatformAPIClient.execute(
1601
1597
  this.config,
1602
1598
  "delete",
1603
- `/service/platform/content/v2.0/company/${this.config.companyId}/application/${this.applicationId}/customobjects/definition/${definitionSlug}/entries/${slug}`,
1599
+ `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/metaobjects/${metaobjectId}`,
1604
1600
  query_params,
1605
1601
  undefined,
1606
1602
  requestHeaders,
@@ -1625,7 +1621,7 @@ class Content {
1625
1621
  } else {
1626
1622
  Logger({
1627
1623
  level: "WARN",
1628
- message: `Response Validation Warnings for platform > Content > deleteAppCustomObjectBySlug \n ${res_error}`,
1624
+ message: `Response Validation Warnings for platform > Content > deleteAppCustomObject \n ${res_error}`,
1629
1625
  });
1630
1626
  }
1631
1627
  }
@@ -1634,7 +1630,7 @@ class Content {
1634
1630
  }
1635
1631
 
1636
1632
  /**
1637
- * @param {ContentPlatformApplicationValidator.DeleteAppCustomObjectDefinitionBySlugParam} arg
1633
+ * @param {ContentPlatformApplicationValidator.DeleteAppCustomObjectDefinitionParam} arg
1638
1634
  * - Arg object
1639
1635
  *
1640
1636
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
@@ -1642,19 +1638,19 @@ class Content {
1642
1638
  * @returns {Promise<ContentPlatformModel.CustomObjectDefinitionDeleteResponseSchema>}
1643
1639
  * - Success response
1644
1640
  *
1645
- * @name deleteAppCustomObjectDefinitionBySlug
1641
+ * @name deleteAppCustomObjectDefinition
1646
1642
  * @summary: Delete custom object definition
1647
- * @description: Custom object definitions can be deleted using this endpoint by providing the definition ID. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/deleteAppCustomObjectDefinitionBySlug/).
1643
+ * @description: Custom object definitions can be deleted using this endpoint by providing the definition ID. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/deleteAppCustomObjectDefinition/).
1648
1644
  */
1649
- async deleteAppCustomObjectDefinitionBySlug(
1650
- { slug, requestHeaders } = { requestHeaders: {} },
1645
+ async deleteAppCustomObjectDefinition(
1646
+ { definitionId, requestHeaders } = { requestHeaders: {} },
1651
1647
  { responseHeaders } = { responseHeaders: false }
1652
1648
  ) {
1653
1649
  const {
1654
1650
  error,
1655
- } = ContentPlatformApplicationValidator.deleteAppCustomObjectDefinitionBySlug().validate(
1651
+ } = ContentPlatformApplicationValidator.deleteAppCustomObjectDefinition().validate(
1656
1652
  {
1657
- slug,
1653
+ definitionId,
1658
1654
  },
1659
1655
  { abortEarly: false, allowUnknown: true }
1660
1656
  );
@@ -1665,16 +1661,16 @@ class Content {
1665
1661
  // Showing warrnings if extra unknown parameters are found
1666
1662
  const {
1667
1663
  error: warrning,
1668
- } = ContentPlatformApplicationValidator.deleteAppCustomObjectDefinitionBySlug().validate(
1664
+ } = ContentPlatformApplicationValidator.deleteAppCustomObjectDefinition().validate(
1669
1665
  {
1670
- slug,
1666
+ definitionId,
1671
1667
  },
1672
1668
  { abortEarly: false, allowUnknown: false }
1673
1669
  );
1674
1670
  if (warrning) {
1675
1671
  Logger({
1676
1672
  level: "WARN",
1677
- message: `Parameter Validation warrnings for platform > Content > deleteAppCustomObjectDefinitionBySlug \n ${warrning}`,
1673
+ message: `Parameter Validation warrnings for platform > Content > deleteAppCustomObjectDefinition \n ${warrning}`,
1678
1674
  });
1679
1675
  }
1680
1676
 
@@ -1683,7 +1679,7 @@ class Content {
1683
1679
  const response = await PlatformAPIClient.execute(
1684
1680
  this.config,
1685
1681
  "delete",
1686
- `/service/platform/content/v2.0/company/${this.config.companyId}/application/${this.applicationId}/customobjects/definition/${slug}`,
1682
+ `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/metaobjects/definitions/${definitionId}`,
1687
1683
  query_params,
1688
1684
  undefined,
1689
1685
  requestHeaders,
@@ -1708,7 +1704,7 @@ class Content {
1708
1704
  } else {
1709
1705
  Logger({
1710
1706
  level: "WARN",
1711
- message: `Response Validation Warnings for platform > Content > deleteAppCustomObjectDefinitionBySlug \n ${res_error}`,
1707
+ message: `Response Validation Warnings for platform > Content > deleteAppCustomObjectDefinition \n ${res_error}`,
1712
1708
  });
1713
1709
  }
1714
1710
  }
@@ -2430,86 +2426,6 @@ class Content {
2430
2426
  return response;
2431
2427
  }
2432
2428
 
2433
- /**
2434
- * @param {ContentPlatformApplicationValidator.DeleteSitemapParam} arg - Arg object
2435
- * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
2436
- * @param {import("../PlatformAPIClient").Options} - Options
2437
- * @returns {Promise<ContentPlatformModel.SitemapConfig>} - Success response
2438
- * @name deleteSitemap
2439
- * @summary: Delete a specific sitemap configuration
2440
- * @description: Permanently delete a sitemap configuration identified by its name. This action cannot be undone. All associated data including the sitemap XML data will be removed.
2441
- * - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/deleteSitemap/).
2442
- */
2443
- async deleteSitemap(
2444
- { name, requestHeaders } = { requestHeaders: {} },
2445
- { responseHeaders } = { responseHeaders: false }
2446
- ) {
2447
- const {
2448
- error,
2449
- } = ContentPlatformApplicationValidator.deleteSitemap().validate(
2450
- {
2451
- name,
2452
- },
2453
- { abortEarly: false, allowUnknown: true }
2454
- );
2455
- if (error) {
2456
- return Promise.reject(new FDKClientValidationError(error));
2457
- }
2458
-
2459
- // Showing warrnings if extra unknown parameters are found
2460
- const {
2461
- error: warrning,
2462
- } = ContentPlatformApplicationValidator.deleteSitemap().validate(
2463
- {
2464
- name,
2465
- },
2466
- { abortEarly: false, allowUnknown: false }
2467
- );
2468
- if (warrning) {
2469
- Logger({
2470
- level: "WARN",
2471
- message: `Parameter Validation warrnings for platform > Content > deleteSitemap \n ${warrning}`,
2472
- });
2473
- }
2474
-
2475
- const query_params = {};
2476
-
2477
- const response = await PlatformAPIClient.execute(
2478
- this.config,
2479
- "delete",
2480
- `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/seo/sitemaps/${name}`,
2481
- query_params,
2482
- undefined,
2483
- requestHeaders,
2484
- { responseHeaders }
2485
- );
2486
-
2487
- let responseData = response;
2488
- if (responseHeaders) {
2489
- responseData = response[0];
2490
- }
2491
-
2492
- const {
2493
- error: res_error,
2494
- } = ContentPlatformModel.SitemapConfig().validate(responseData, {
2495
- abortEarly: false,
2496
- allowUnknown: true,
2497
- });
2498
-
2499
- if (res_error) {
2500
- if (this.config.options.strictResponseCheck === true) {
2501
- return Promise.reject(new FDKResponseValidationError(res_error));
2502
- } else {
2503
- Logger({
2504
- level: "WARN",
2505
- message: `Response Validation Warnings for platform > Content > deleteSitemap \n ${res_error}`,
2506
- });
2507
- }
2508
- }
2509
-
2510
- return response;
2511
- }
2512
-
2513
2429
  /**
2514
2430
  * @param {ContentPlatformApplicationValidator.DeleteSlideshowParam} arg - Arg object
2515
2431
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
@@ -2838,7 +2754,7 @@ class Content {
2838
2754
  }
2839
2755
 
2840
2756
  /**
2841
- * @param {ContentPlatformApplicationValidator.ExportAppCustomObjectEntriesBySlugParam} arg
2757
+ * @param {ContentPlatformApplicationValidator.ExportAppCustomObjectEntriesParam} arg
2842
2758
  * - Arg object
2843
2759
  *
2844
2760
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
@@ -2846,19 +2762,19 @@ class Content {
2846
2762
  * @returns {Promise<ContentPlatformModel.CustomObjectBulkEntryInitiateDownload>}
2847
2763
  * - Success response
2848
2764
  *
2849
- * @name exportAppCustomObjectEntriesBySlug
2765
+ * @name exportAppCustomObjectEntries
2850
2766
  * @summary: Initiate download for bulk custom object entries
2851
- * @description: Custom object bulk export of bulk entries can be perform using this endpoint. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/exportAppCustomObjectEntriesBySlug/).
2767
+ * @description: Custom object bulk export of bulk entries can be perform using this endpoint. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/exportAppCustomObjectEntries/).
2852
2768
  */
2853
- async exportAppCustomObjectEntriesBySlug(
2854
- { slug, requestHeaders } = { requestHeaders: {} },
2769
+ async exportAppCustomObjectEntries(
2770
+ { definitionId, requestHeaders } = { requestHeaders: {} },
2855
2771
  { responseHeaders } = { responseHeaders: false }
2856
2772
  ) {
2857
2773
  const {
2858
2774
  error,
2859
- } = ContentPlatformApplicationValidator.exportAppCustomObjectEntriesBySlug().validate(
2775
+ } = ContentPlatformApplicationValidator.exportAppCustomObjectEntries().validate(
2860
2776
  {
2861
- slug,
2777
+ definitionId,
2862
2778
  },
2863
2779
  { abortEarly: false, allowUnknown: true }
2864
2780
  );
@@ -2869,16 +2785,16 @@ class Content {
2869
2785
  // Showing warrnings if extra unknown parameters are found
2870
2786
  const {
2871
2787
  error: warrning,
2872
- } = ContentPlatformApplicationValidator.exportAppCustomObjectEntriesBySlug().validate(
2788
+ } = ContentPlatformApplicationValidator.exportAppCustomObjectEntries().validate(
2873
2789
  {
2874
- slug,
2790
+ definitionId,
2875
2791
  },
2876
2792
  { abortEarly: false, allowUnknown: false }
2877
2793
  );
2878
2794
  if (warrning) {
2879
2795
  Logger({
2880
2796
  level: "WARN",
2881
- message: `Parameter Validation warrnings for platform > Content > exportAppCustomObjectEntriesBySlug \n ${warrning}`,
2797
+ message: `Parameter Validation warrnings for platform > Content > exportAppCustomObjectEntries \n ${warrning}`,
2882
2798
  });
2883
2799
  }
2884
2800
 
@@ -2887,7 +2803,7 @@ class Content {
2887
2803
  const response = await PlatformAPIClient.execute(
2888
2804
  this.config,
2889
2805
  "get",
2890
- `/service/platform/content/v2.0/company/${this.config.companyId}/application/${this.applicationId}/customobjects/definition/${slug}/bulk/download`,
2806
+ `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/metaobjects/bulk/${definitionId}/download`,
2891
2807
  query_params,
2892
2808
  undefined,
2893
2809
  requestHeaders,
@@ -2912,7 +2828,7 @@ class Content {
2912
2828
  } else {
2913
2829
  Logger({
2914
2830
  level: "WARN",
2915
- message: `Response Validation Warnings for platform > Content > exportAppCustomObjectEntriesBySlug \n ${res_error}`,
2831
+ message: `Response Validation Warnings for platform > Content > exportAppCustomObjectEntries \n ${res_error}`,
2916
2832
  });
2917
2833
  }
2918
2834
  }
@@ -3169,41 +3085,27 @@ class Content {
3169
3085
  }
3170
3086
 
3171
3087
  /**
3172
- * @param {ContentPlatformApplicationValidator.GetAppCustomFieldDefinitionByResourceParam} arg
3088
+ * @param {ContentPlatformApplicationValidator.GetAppCustomFieldDefinitionParam} arg
3173
3089
  * - Arg object
3174
3090
  *
3175
3091
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
3176
3092
  * @param {import("../PlatformAPIClient").Options} - Options
3177
- * @returns {Promise<ContentPlatformModel.CustomFieldDefinitionsSchema>} -
3178
- * Success response
3179
- * @name getAppCustomFieldDefinitionByResource
3180
- * @summary: Get custom fields definitions for a given resource type
3181
- * @description: Custom field definitions enable you to include data validation for custom fields, and enable sellers to add custom fields values for resources. With the help of this seller can retrive list of custom field definitions list. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/getAppCustomFieldDefinitionByResource/).
3093
+ * @returns {Promise<ContentPlatformModel.CustomFieldDefinitionDetailResSchema>}
3094
+ * - Success response
3095
+ *
3096
+ * @name getAppCustomFieldDefinition
3097
+ * @summary: Get custom fields definition
3098
+ * @description: Custom field definitions can be fetch using definition id. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/getAppCustomFieldDefinition/).
3182
3099
  */
3183
- async getAppCustomFieldDefinitionByResource(
3184
- {
3185
- pageNo,
3186
- pageSize,
3187
- resource,
3188
- types,
3189
- search,
3190
- slugs,
3191
- namespaces,
3192
- requestHeaders,
3193
- } = { requestHeaders: {} },
3100
+ async getAppCustomFieldDefinition(
3101
+ { definitionId, requestHeaders } = { requestHeaders: {} },
3194
3102
  { responseHeaders } = { responseHeaders: false }
3195
3103
  ) {
3196
3104
  const {
3197
3105
  error,
3198
- } = ContentPlatformApplicationValidator.getAppCustomFieldDefinitionByResource().validate(
3106
+ } = ContentPlatformApplicationValidator.getAppCustomFieldDefinition().validate(
3199
3107
  {
3200
- pageNo,
3201
- pageSize,
3202
- resource,
3203
- types,
3204
- search,
3205
- slugs,
3206
- namespaces,
3108
+ definitionId,
3207
3109
  },
3208
3110
  { abortEarly: false, allowUnknown: true }
3209
3111
  );
@@ -3214,37 +3116,25 @@ class Content {
3214
3116
  // Showing warrnings if extra unknown parameters are found
3215
3117
  const {
3216
3118
  error: warrning,
3217
- } = ContentPlatformApplicationValidator.getAppCustomFieldDefinitionByResource().validate(
3119
+ } = ContentPlatformApplicationValidator.getAppCustomFieldDefinition().validate(
3218
3120
  {
3219
- pageNo,
3220
- pageSize,
3221
- resource,
3222
- types,
3223
- search,
3224
- slugs,
3225
- namespaces,
3121
+ definitionId,
3226
3122
  },
3227
3123
  { abortEarly: false, allowUnknown: false }
3228
3124
  );
3229
3125
  if (warrning) {
3230
3126
  Logger({
3231
3127
  level: "WARN",
3232
- message: `Parameter Validation warrnings for platform > Content > getAppCustomFieldDefinitionByResource \n ${warrning}`,
3128
+ message: `Parameter Validation warrnings for platform > Content > getAppCustomFieldDefinition \n ${warrning}`,
3233
3129
  });
3234
3130
  }
3235
3131
 
3236
3132
  const query_params = {};
3237
- query_params["page_no"] = pageNo;
3238
- query_params["page_size"] = pageSize;
3239
- query_params["types"] = types;
3240
- query_params["search"] = search;
3241
- query_params["slugs"] = slugs;
3242
- query_params["namespaces"] = namespaces;
3243
3133
 
3244
3134
  const response = await PlatformAPIClient.execute(
3245
3135
  this.config,
3246
3136
  "get",
3247
- `/service/platform/content/v2.0/company/${this.config.companyId}/application/${this.applicationId}/customfields/resource/${resource}/definition`,
3137
+ `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/metafields/definitions/${definitionId}`,
3248
3138
  query_params,
3249
3139
  undefined,
3250
3140
  requestHeaders,
@@ -3258,7 +3148,7 @@ class Content {
3258
3148
 
3259
3149
  const {
3260
3150
  error: res_error,
3261
- } = ContentPlatformModel.CustomFieldDefinitionsSchema().validate(
3151
+ } = ContentPlatformModel.CustomFieldDefinitionDetailResSchema().validate(
3262
3152
  responseData,
3263
3153
  { abortEarly: false, allowUnknown: true }
3264
3154
  );
@@ -3269,7 +3159,7 @@ class Content {
3269
3159
  } else {
3270
3160
  Logger({
3271
3161
  level: "WARN",
3272
- message: `Response Validation Warnings for platform > Content > getAppCustomFieldDefinitionByResource \n ${res_error}`,
3162
+ message: `Response Validation Warnings for platform > Content > getAppCustomFieldDefinition \n ${res_error}`,
3273
3163
  });
3274
3164
  }
3275
3165
  }
@@ -3278,29 +3168,32 @@ class Content {
3278
3168
  }
3279
3169
 
3280
3170
  /**
3281
- * @param {ContentPlatformApplicationValidator.GetAppCustomFieldDefinitionBySlugParam} arg
3171
+ * @param {ContentPlatformApplicationValidator.GetAppCustomFieldDefinitionsParam} arg
3282
3172
  * - Arg object
3283
3173
  *
3284
3174
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
3285
3175
  * @param {import("../PlatformAPIClient").Options} - Options
3286
- * @returns {Promise<ContentPlatformModel.MetaFieldDefinitionDetailResSchema>}
3287
- * - Success response
3288
- *
3289
- * @name getAppCustomFieldDefinitionBySlug
3290
- * @summary: Get custom fields definition by resource, slug and namespace
3291
- * @description: Custom field definitions can be retrived from this using its slug, namespace and resource - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/getAppCustomFieldDefinitionBySlug/).
3176
+ * @returns {Promise<ContentPlatformModel.CustomFieldDefinitionsSchema>} -
3177
+ * Success response
3178
+ * @name getAppCustomFieldDefinitions
3179
+ * @summary: Get custom fields definitions
3180
+ * @description: Custom field definitions enable you to include data validation for custom fields, and enable sellers to add custom fields values for resources. With the help of this seller can retrive list of custom field definitions list. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/getAppCustomFieldDefinitions/).
3292
3181
  */
3293
- async getAppCustomFieldDefinitionBySlug(
3294
- { slug, resource, namespace, requestHeaders } = { requestHeaders: {} },
3182
+ async getAppCustomFieldDefinitions(
3183
+ { pageNo, pageSize, resource, type, search, requestHeaders } = {
3184
+ requestHeaders: {},
3185
+ },
3295
3186
  { responseHeaders } = { responseHeaders: false }
3296
3187
  ) {
3297
3188
  const {
3298
3189
  error,
3299
- } = ContentPlatformApplicationValidator.getAppCustomFieldDefinitionBySlug().validate(
3190
+ } = ContentPlatformApplicationValidator.getAppCustomFieldDefinitions().validate(
3300
3191
  {
3301
- slug,
3192
+ pageNo,
3193
+ pageSize,
3302
3194
  resource,
3303
- namespace,
3195
+ type,
3196
+ search,
3304
3197
  },
3305
3198
  { abortEarly: false, allowUnknown: true }
3306
3199
  );
@@ -3311,27 +3204,34 @@ class Content {
3311
3204
  // Showing warrnings if extra unknown parameters are found
3312
3205
  const {
3313
3206
  error: warrning,
3314
- } = ContentPlatformApplicationValidator.getAppCustomFieldDefinitionBySlug().validate(
3207
+ } = ContentPlatformApplicationValidator.getAppCustomFieldDefinitions().validate(
3315
3208
  {
3316
- slug,
3209
+ pageNo,
3210
+ pageSize,
3317
3211
  resource,
3318
- namespace,
3212
+ type,
3213
+ search,
3319
3214
  },
3320
3215
  { abortEarly: false, allowUnknown: false }
3321
3216
  );
3322
3217
  if (warrning) {
3323
3218
  Logger({
3324
3219
  level: "WARN",
3325
- message: `Parameter Validation warrnings for platform > Content > getAppCustomFieldDefinitionBySlug \n ${warrning}`,
3220
+ message: `Parameter Validation warrnings for platform > Content > getAppCustomFieldDefinitions \n ${warrning}`,
3326
3221
  });
3327
3222
  }
3328
3223
 
3329
3224
  const query_params = {};
3225
+ query_params["page_no"] = pageNo;
3226
+ query_params["page_size"] = pageSize;
3227
+ query_params["resource"] = resource;
3228
+ query_params["type"] = type;
3229
+ query_params["search"] = search;
3330
3230
 
3331
3231
  const response = await PlatformAPIClient.execute(
3332
3232
  this.config,
3333
3233
  "get",
3334
- `/service/platform/content/v2.0/company/${this.config.companyId}/application/${this.applicationId}/customfields/resource/${resource}/namespace/${namespace}/definition/${slug}`,
3234
+ `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/metafields/definitions`,
3335
3235
  query_params,
3336
3236
  undefined,
3337
3237
  requestHeaders,
@@ -3345,7 +3245,7 @@ class Content {
3345
3245
 
3346
3246
  const {
3347
3247
  error: res_error,
3348
- } = ContentPlatformModel.MetaFieldDefinitionDetailResSchema().validate(
3248
+ } = ContentPlatformModel.CustomFieldDefinitionsSchema().validate(
3349
3249
  responseData,
3350
3250
  { abortEarly: false, allowUnknown: true }
3351
3251
  );
@@ -3356,7 +3256,7 @@ class Content {
3356
3256
  } else {
3357
3257
  Logger({
3358
3258
  level: "WARN",
3359
- message: `Response Validation Warnings for platform > Content > getAppCustomFieldDefinitionBySlug \n ${res_error}`,
3259
+ message: `Response Validation Warnings for platform > Content > getAppCustomFieldDefinitions \n ${res_error}`,
3360
3260
  });
3361
3261
  }
3362
3262
  }
@@ -3365,42 +3265,24 @@ class Content {
3365
3265
  }
3366
3266
 
3367
3267
  /**
3368
- * @param {ContentPlatformApplicationValidator.GetAppCustomFieldDefinitionsParam} arg
3268
+ * @param {ContentPlatformApplicationValidator.GetAppCustomFieldTypesParam} arg
3369
3269
  * - Arg object
3370
3270
  *
3371
3271
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
3372
3272
  * @param {import("../PlatformAPIClient").Options} - Options
3373
- * @returns {Promise<ContentPlatformModel.CustomFieldDefinitionsSchema>} -
3374
- * Success response
3375
- * @name getAppCustomFieldDefinitions
3376
- * @summary: Get custom fields definitions
3377
- * @description: Custom field definitions enable you to include data validation for custom fields, and enable sellers to add custom fields values for resources. With the help of this seller can retrive list of custom field definitions list. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/getAppCustomFieldDefinitions/).
3273
+ * @returns {Promise<ContentPlatformModel.CustomObjectByIdSchema>} - Success response
3274
+ * @name getAppCustomFieldTypes
3275
+ * @summary: Get custom field types
3276
+ * @description: Each custom field and custom field definition has a type, which defines the type of information that it can store. The custom field types have built-in validation. This api will give list of supported custom fields types - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/getAppCustomFieldTypes/).
3378
3277
  */
3379
- async getAppCustomFieldDefinitions(
3380
- {
3381
- pageNo,
3382
- pageSize,
3383
- resources,
3384
- types,
3385
- search,
3386
- slugs,
3387
- namespaces,
3388
- requestHeaders,
3389
- } = { requestHeaders: {} },
3278
+ async getAppCustomFieldTypes(
3279
+ { requestHeaders } = { requestHeaders: {} },
3390
3280
  { responseHeaders } = { responseHeaders: false }
3391
3281
  ) {
3392
3282
  const {
3393
3283
  error,
3394
- } = ContentPlatformApplicationValidator.getAppCustomFieldDefinitions().validate(
3395
- {
3396
- pageNo,
3397
- pageSize,
3398
- resources,
3399
- types,
3400
- search,
3401
- slugs,
3402
- namespaces,
3403
- },
3284
+ } = ContentPlatformApplicationValidator.getAppCustomFieldTypes().validate(
3285
+ {},
3404
3286
  { abortEarly: false, allowUnknown: true }
3405
3287
  );
3406
3288
  if (error) {
@@ -3410,38 +3292,23 @@ class Content {
3410
3292
  // Showing warrnings if extra unknown parameters are found
3411
3293
  const {
3412
3294
  error: warrning,
3413
- } = ContentPlatformApplicationValidator.getAppCustomFieldDefinitions().validate(
3414
- {
3415
- pageNo,
3416
- pageSize,
3417
- resources,
3418
- types,
3419
- search,
3420
- slugs,
3421
- namespaces,
3422
- },
3295
+ } = ContentPlatformApplicationValidator.getAppCustomFieldTypes().validate(
3296
+ {},
3423
3297
  { abortEarly: false, allowUnknown: false }
3424
3298
  );
3425
3299
  if (warrning) {
3426
3300
  Logger({
3427
3301
  level: "WARN",
3428
- message: `Parameter Validation warrnings for platform > Content > getAppCustomFieldDefinitions \n ${warrning}`,
3302
+ message: `Parameter Validation warrnings for platform > Content > getAppCustomFieldTypes \n ${warrning}`,
3429
3303
  });
3430
3304
  }
3431
3305
 
3432
3306
  const query_params = {};
3433
- query_params["page_no"] = pageNo;
3434
- query_params["page_size"] = pageSize;
3435
- query_params["resources"] = resources;
3436
- query_params["types"] = types;
3437
- query_params["search"] = search;
3438
- query_params["slugs"] = slugs;
3439
- query_params["namespaces"] = namespaces;
3440
3307
 
3441
3308
  const response = await PlatformAPIClient.execute(
3442
3309
  this.config,
3443
3310
  "get",
3444
- `/service/platform/content/v2.0/company/${this.config.companyId}/application/${this.applicationId}/customfields/definition`,
3311
+ `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/metafields/types`,
3445
3312
  query_params,
3446
3313
  undefined,
3447
3314
  requestHeaders,
@@ -3455,10 +3322,10 @@ class Content {
3455
3322
 
3456
3323
  const {
3457
3324
  error: res_error,
3458
- } = ContentPlatformModel.CustomFieldDefinitionsSchema().validate(
3459
- responseData,
3460
- { abortEarly: false, allowUnknown: true }
3461
- );
3325
+ } = ContentPlatformModel.CustomObjectByIdSchema().validate(responseData, {
3326
+ abortEarly: false,
3327
+ allowUnknown: true,
3328
+ });
3462
3329
 
3463
3330
  if (res_error) {
3464
3331
  if (this.config.options.strictResponseCheck === true) {
@@ -3466,7 +3333,7 @@ class Content {
3466
3333
  } else {
3467
3334
  Logger({
3468
3335
  level: "WARN",
3469
- message: `Response Validation Warnings for platform > Content > getAppCustomFieldDefinitions \n ${res_error}`,
3336
+ message: `Response Validation Warnings for platform > Content > getAppCustomFieldTypes \n ${res_error}`,
3470
3337
  });
3471
3338
  }
3472
3339
  }
@@ -3475,24 +3342,27 @@ class Content {
3475
3342
  }
3476
3343
 
3477
3344
  /**
3478
- * @param {ContentPlatformApplicationValidator.GetAppCustomFieldTypesParam} arg
3345
+ * @param {ContentPlatformApplicationValidator.GetAppCustomFieldsParam} arg
3479
3346
  * - Arg object
3480
3347
  *
3481
3348
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
3482
3349
  * @param {import("../PlatformAPIClient").Options} - Options
3483
- * @returns {Promise<ContentPlatformModel.MetafieldTypesSchema>} - Success response
3484
- * @name getAppCustomFieldTypes
3485
- * @summary: Get custom field types
3486
- * @description: Each custom field and custom field definition has a type, which defines the type of information that it can store. The custom field types have built-in validation. This api will give list of supported custom fields types - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/getAppCustomFieldTypes/).
3350
+ * @returns {Promise<ContentPlatformModel.CustomFieldsResponseSchema>} -
3351
+ * Success response
3352
+ * @name getAppCustomFields
3353
+ * @summary: Get list of custom fields of gives resource
3354
+ * @description: Retrieves a list of custom fields attached to a particular resource by using the resource. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/getAppCustomFields/).
3487
3355
  */
3488
- async getAppCustomFieldTypes(
3489
- { requestHeaders } = { requestHeaders: {} },
3356
+ async getAppCustomFields(
3357
+ { resource, requestHeaders } = { requestHeaders: {} },
3490
3358
  { responseHeaders } = { responseHeaders: false }
3491
3359
  ) {
3492
3360
  const {
3493
3361
  error,
3494
- } = ContentPlatformApplicationValidator.getAppCustomFieldTypes().validate(
3495
- {},
3362
+ } = ContentPlatformApplicationValidator.getAppCustomFields().validate(
3363
+ {
3364
+ resource,
3365
+ },
3496
3366
  { abortEarly: false, allowUnknown: true }
3497
3367
  );
3498
3368
  if (error) {
@@ -3502,14 +3372,16 @@ class Content {
3502
3372
  // Showing warrnings if extra unknown parameters are found
3503
3373
  const {
3504
3374
  error: warrning,
3505
- } = ContentPlatformApplicationValidator.getAppCustomFieldTypes().validate(
3506
- {},
3375
+ } = ContentPlatformApplicationValidator.getAppCustomFields().validate(
3376
+ {
3377
+ resource,
3378
+ },
3507
3379
  { abortEarly: false, allowUnknown: false }
3508
3380
  );
3509
3381
  if (warrning) {
3510
3382
  Logger({
3511
3383
  level: "WARN",
3512
- message: `Parameter Validation warrnings for platform > Content > getAppCustomFieldTypes \n ${warrning}`,
3384
+ message: `Parameter Validation warrnings for platform > Content > getAppCustomFields \n ${warrning}`,
3513
3385
  });
3514
3386
  }
3515
3387
 
@@ -3518,7 +3390,7 @@ class Content {
3518
3390
  const response = await PlatformAPIClient.execute(
3519
3391
  this.config,
3520
3392
  "get",
3521
- `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/metafields/types`,
3393
+ `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/metafields/${resource}`,
3522
3394
  query_params,
3523
3395
  undefined,
3524
3396
  requestHeaders,
@@ -3532,10 +3404,10 @@ class Content {
3532
3404
 
3533
3405
  const {
3534
3406
  error: res_error,
3535
- } = ContentPlatformModel.MetafieldTypesSchema().validate(responseData, {
3536
- abortEarly: false,
3537
- allowUnknown: true,
3538
- });
3407
+ } = ContentPlatformModel.CustomFieldsResponseSchema().validate(
3408
+ responseData,
3409
+ { abortEarly: false, allowUnknown: true }
3410
+ );
3539
3411
 
3540
3412
  if (res_error) {
3541
3413
  if (this.config.options.strictResponseCheck === true) {
@@ -3543,7 +3415,7 @@ class Content {
3543
3415
  } else {
3544
3416
  Logger({
3545
3417
  level: "WARN",
3546
- message: `Response Validation Warnings for platform > Content > getAppCustomFieldTypes \n ${res_error}`,
3418
+ message: `Response Validation Warnings for platform > Content > getAppCustomFields \n ${res_error}`,
3547
3419
  });
3548
3420
  }
3549
3421
  }
@@ -3552,7 +3424,7 @@ class Content {
3552
3424
  }
3553
3425
 
3554
3426
  /**
3555
- * @param {ContentPlatformApplicationValidator.GetAppCustomFieldsByResourceSlugParam} arg
3427
+ * @param {ContentPlatformApplicationValidator.GetAppCustomFieldsByResourceIdParam} arg
3556
3428
  * - Arg object
3557
3429
  *
3558
3430
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
@@ -3560,20 +3432,20 @@ class Content {
3560
3432
  * @returns {Promise<ContentPlatformModel.CustomFieldsResponseByResourceIdSchema>}
3561
3433
  * - Success response
3562
3434
  *
3563
- * @name getAppCustomFieldsByResourceSlug
3564
- * @summary: Get list of custom fields of given resource and resource slug
3565
- * @description: Retrieves a list of custom fields attached to a particular resource by using the resource and resource slug. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/getAppCustomFieldsByResourceSlug/).
3435
+ * @name getAppCustomFieldsByResourceId
3436
+ * @summary: Get list of custom fields of given resource and resource id
3437
+ * @description: Retrieves a list of custom fields attached to a particular resource by using the resource and resource id. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/getAppCustomFieldsByResourceId/).
3566
3438
  */
3567
- async getAppCustomFieldsByResourceSlug(
3568
- { resource, resourceSlug, requestHeaders } = { requestHeaders: {} },
3439
+ async getAppCustomFieldsByResourceId(
3440
+ { resource, resourceId, requestHeaders } = { requestHeaders: {} },
3569
3441
  { responseHeaders } = { responseHeaders: false }
3570
3442
  ) {
3571
3443
  const {
3572
3444
  error,
3573
- } = ContentPlatformApplicationValidator.getAppCustomFieldsByResourceSlug().validate(
3445
+ } = ContentPlatformApplicationValidator.getAppCustomFieldsByResourceId().validate(
3574
3446
  {
3575
3447
  resource,
3576
- resourceSlug,
3448
+ resourceId,
3577
3449
  },
3578
3450
  { abortEarly: false, allowUnknown: true }
3579
3451
  );
@@ -3584,17 +3456,17 @@ class Content {
3584
3456
  // Showing warrnings if extra unknown parameters are found
3585
3457
  const {
3586
3458
  error: warrning,
3587
- } = ContentPlatformApplicationValidator.getAppCustomFieldsByResourceSlug().validate(
3459
+ } = ContentPlatformApplicationValidator.getAppCustomFieldsByResourceId().validate(
3588
3460
  {
3589
3461
  resource,
3590
- resourceSlug,
3462
+ resourceId,
3591
3463
  },
3592
3464
  { abortEarly: false, allowUnknown: false }
3593
3465
  );
3594
3466
  if (warrning) {
3595
3467
  Logger({
3596
3468
  level: "WARN",
3597
- message: `Parameter Validation warrnings for platform > Content > getAppCustomFieldsByResourceSlug \n ${warrning}`,
3469
+ message: `Parameter Validation warrnings for platform > Content > getAppCustomFieldsByResourceId \n ${warrning}`,
3598
3470
  });
3599
3471
  }
3600
3472
 
@@ -3603,7 +3475,7 @@ class Content {
3603
3475
  const response = await PlatformAPIClient.execute(
3604
3476
  this.config,
3605
3477
  "get",
3606
- `/service/platform/content/v2.0/company/${this.config.companyId}/application/${this.applicationId}/customfields/resource/${resource}/${resourceSlug}`,
3478
+ `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/metafields/${resource}/${resourceId}`,
3607
3479
  query_params,
3608
3480
  undefined,
3609
3481
  requestHeaders,
@@ -3628,7 +3500,7 @@ class Content {
3628
3500
  } else {
3629
3501
  Logger({
3630
3502
  level: "WARN",
3631
- message: `Response Validation Warnings for platform > Content > getAppCustomFieldsByResourceSlug \n ${res_error}`,
3503
+ message: `Response Validation Warnings for platform > Content > getAppCustomFieldsByResourceId \n ${res_error}`,
3632
3504
  });
3633
3505
  }
3634
3506
  }
@@ -3637,27 +3509,25 @@ class Content {
3637
3509
  }
3638
3510
 
3639
3511
  /**
3640
- * @param {ContentPlatformApplicationValidator.GetAppCustomObjectBySlugParam} arg
3512
+ * @param {ContentPlatformApplicationValidator.GetAppCustomObjectParam} arg
3641
3513
  * - Arg object
3642
3514
  *
3643
3515
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
3644
3516
  * @param {import("../PlatformAPIClient").Options} - Options
3645
- * @returns {Promise<ContentPlatformModel.CustomObjectBySlugSchema>} -
3646
- * Success response
3647
- * @name getAppCustomObjectBySlug
3517
+ * @returns {Promise<ContentPlatformModel.CustomObjectByIdSchema>} - Success response
3518
+ * @name getAppCustomObject
3648
3519
  * @summary: Get custom object details
3649
- * @description: Details of a custom object entry can be obtained using this endpoint. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/getAppCustomObjectBySlug/).
3520
+ * @description: Details of custom objects, their field details, definitions, and references can be obtained using this endpoint. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/getAppCustomObject/).
3650
3521
  */
3651
- async getAppCustomObjectBySlug(
3652
- { definitionSlug, slug, requestHeaders } = { requestHeaders: {} },
3522
+ async getAppCustomObject(
3523
+ { metaobjectId, requestHeaders } = { requestHeaders: {} },
3653
3524
  { responseHeaders } = { responseHeaders: false }
3654
3525
  ) {
3655
3526
  const {
3656
3527
  error,
3657
- } = ContentPlatformApplicationValidator.getAppCustomObjectBySlug().validate(
3528
+ } = ContentPlatformApplicationValidator.getAppCustomObject().validate(
3658
3529
  {
3659
- definitionSlug,
3660
- slug,
3530
+ metaobjectId,
3661
3531
  },
3662
3532
  { abortEarly: false, allowUnknown: true }
3663
3533
  );
@@ -3668,17 +3538,16 @@ class Content {
3668
3538
  // Showing warrnings if extra unknown parameters are found
3669
3539
  const {
3670
3540
  error: warrning,
3671
- } = ContentPlatformApplicationValidator.getAppCustomObjectBySlug().validate(
3541
+ } = ContentPlatformApplicationValidator.getAppCustomObject().validate(
3672
3542
  {
3673
- definitionSlug,
3674
- slug,
3543
+ metaobjectId,
3675
3544
  },
3676
3545
  { abortEarly: false, allowUnknown: false }
3677
3546
  );
3678
3547
  if (warrning) {
3679
3548
  Logger({
3680
3549
  level: "WARN",
3681
- message: `Parameter Validation warrnings for platform > Content > getAppCustomObjectBySlug \n ${warrning}`,
3550
+ message: `Parameter Validation warrnings for platform > Content > getAppCustomObject \n ${warrning}`,
3682
3551
  });
3683
3552
  }
3684
3553
 
@@ -3687,7 +3556,7 @@ class Content {
3687
3556
  const response = await PlatformAPIClient.execute(
3688
3557
  this.config,
3689
3558
  "get",
3690
- `/service/platform/content/v2.0/company/${this.config.companyId}/application/${this.applicationId}/customobjects/definition/${definitionSlug}/entries/${slug}`,
3559
+ `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/metaobjects/${metaobjectId}`,
3691
3560
  query_params,
3692
3561
  undefined,
3693
3562
  requestHeaders,
@@ -3701,7 +3570,7 @@ class Content {
3701
3570
 
3702
3571
  const {
3703
3572
  error: res_error,
3704
- } = ContentPlatformModel.CustomObjectBySlugSchema().validate(responseData, {
3573
+ } = ContentPlatformModel.CustomObjectByIdSchema().validate(responseData, {
3705
3574
  abortEarly: false,
3706
3575
  allowUnknown: true,
3707
3576
  });
@@ -3712,7 +3581,7 @@ class Content {
3712
3581
  } else {
3713
3582
  Logger({
3714
3583
  level: "WARN",
3715
- message: `Response Validation Warnings for platform > Content > getAppCustomObjectBySlug \n ${res_error}`,
3584
+ message: `Response Validation Warnings for platform > Content > getAppCustomObject \n ${res_error}`,
3716
3585
  });
3717
3586
  }
3718
3587
  }
@@ -3721,27 +3590,26 @@ class Content {
3721
3590
  }
3722
3591
 
3723
3592
  /**
3724
- * @param {ContentPlatformApplicationValidator.GetAppCustomObjectDefinitionBySlugParam} arg
3593
+ * @param {ContentPlatformApplicationValidator.GetAppCustomObjectDefinitionParam} arg
3725
3594
  * - Arg object
3726
3595
  *
3727
3596
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
3728
3597
  * @param {import("../PlatformAPIClient").Options} - Options
3729
- * @returns {Promise<ContentPlatformModel.CustomObjectDefinitionSlugSchema>}
3730
- * - Success response
3731
- *
3732
- * @name getAppCustomObjectDefinitionBySlug
3598
+ * @returns {Promise<ContentPlatformModel.CustomObjectDefinitionSchema>} -
3599
+ * Success response
3600
+ * @name getAppCustomObjectDefinition
3733
3601
  * @summary: Get custom object definition
3734
- * @description: Custom object definitions can be fetched using their custom object definition slug. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/getAppCustomObjectDefinitionBySlug/).
3602
+ * @description: Custom object definitions can be fetched using their definition ID. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/getAppCustomObjectDefinition/).
3735
3603
  */
3736
- async getAppCustomObjectDefinitionBySlug(
3737
- { slug, requestHeaders } = { requestHeaders: {} },
3604
+ async getAppCustomObjectDefinition(
3605
+ { definitionId, requestHeaders } = { requestHeaders: {} },
3738
3606
  { responseHeaders } = { responseHeaders: false }
3739
3607
  ) {
3740
3608
  const {
3741
3609
  error,
3742
- } = ContentPlatformApplicationValidator.getAppCustomObjectDefinitionBySlug().validate(
3610
+ } = ContentPlatformApplicationValidator.getAppCustomObjectDefinition().validate(
3743
3611
  {
3744
- slug,
3612
+ definitionId,
3745
3613
  },
3746
3614
  { abortEarly: false, allowUnknown: true }
3747
3615
  );
@@ -3752,16 +3620,16 @@ class Content {
3752
3620
  // Showing warrnings if extra unknown parameters are found
3753
3621
  const {
3754
3622
  error: warrning,
3755
- } = ContentPlatformApplicationValidator.getAppCustomObjectDefinitionBySlug().validate(
3623
+ } = ContentPlatformApplicationValidator.getAppCustomObjectDefinition().validate(
3756
3624
  {
3757
- slug,
3625
+ definitionId,
3758
3626
  },
3759
3627
  { abortEarly: false, allowUnknown: false }
3760
3628
  );
3761
3629
  if (warrning) {
3762
3630
  Logger({
3763
3631
  level: "WARN",
3764
- message: `Parameter Validation warrnings for platform > Content > getAppCustomObjectDefinitionBySlug \n ${warrning}`,
3632
+ message: `Parameter Validation warrnings for platform > Content > getAppCustomObjectDefinition \n ${warrning}`,
3765
3633
  });
3766
3634
  }
3767
3635
 
@@ -3770,7 +3638,7 @@ class Content {
3770
3638
  const response = await PlatformAPIClient.execute(
3771
3639
  this.config,
3772
3640
  "get",
3773
- `/service/platform/content/v2.0/company/${this.config.companyId}/application/${this.applicationId}/customobjects/definition/${slug}`,
3641
+ `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/metaobjects/definitions/${definitionId}`,
3774
3642
  query_params,
3775
3643
  undefined,
3776
3644
  requestHeaders,
@@ -3784,7 +3652,7 @@ class Content {
3784
3652
 
3785
3653
  const {
3786
3654
  error: res_error,
3787
- } = ContentPlatformModel.CustomObjectDefinitionSlugSchema().validate(
3655
+ } = ContentPlatformModel.CustomObjectDefinitionSchema().validate(
3788
3656
  responseData,
3789
3657
  { abortEarly: false, allowUnknown: true }
3790
3658
  );
@@ -3795,7 +3663,7 @@ class Content {
3795
3663
  } else {
3796
3664
  Logger({
3797
3665
  level: "WARN",
3798
- message: `Response Validation Warnings for platform > Content > getAppCustomObjectDefinitionBySlug \n ${res_error}`,
3666
+ message: `Response Validation Warnings for platform > Content > getAppCustomObjectDefinition \n ${res_error}`,
3799
3667
  });
3800
3668
  }
3801
3669
  }
@@ -3859,7 +3727,7 @@ class Content {
3859
3727
  const response = await PlatformAPIClient.execute(
3860
3728
  this.config,
3861
3729
  "get",
3862
- `/service/platform/content/v2.0/company/${this.config.companyId}/application/${this.applicationId}/customobjects/definition`,
3730
+ `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/metaobjects/definitions`,
3863
3731
  query_params,
3864
3732
  undefined,
3865
3733
  requestHeaders,
@@ -3893,29 +3761,27 @@ class Content {
3893
3761
  }
3894
3762
 
3895
3763
  /**
3896
- * @param {ContentPlatformApplicationValidator.GetAppCustomObjectsBySlugParam} arg
3764
+ * @param {ContentPlatformApplicationValidator.GetAppCustomObjectsParam} arg
3897
3765
  * - Arg object
3898
3766
  *
3899
3767
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
3900
3768
  * @param {import("../PlatformAPIClient").Options} - Options
3901
3769
  * @returns {Promise<ContentPlatformModel.CustomObjectsSchema>} - Success response
3902
- * @name getAppCustomObjectsBySlug
3770
+ * @name getAppCustomObjects
3903
3771
  * @summary: Get list of custom objects
3904
- * @description: Custom object entries can fetch using this endpoint. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/getAppCustomObjectsBySlug/).
3772
+ * @description: Custom object entries can fetch using this endpoint. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/getAppCustomObjects/).
3905
3773
  */
3906
- async getAppCustomObjectsBySlug(
3907
- { pageNo, pageSize, definitionSlug, requestHeaders } = {
3908
- requestHeaders: {},
3909
- },
3774
+ async getAppCustomObjects(
3775
+ { pageNo, pageSize, definitionId, requestHeaders } = { requestHeaders: {} },
3910
3776
  { responseHeaders } = { responseHeaders: false }
3911
3777
  ) {
3912
3778
  const {
3913
3779
  error,
3914
- } = ContentPlatformApplicationValidator.getAppCustomObjectsBySlug().validate(
3780
+ } = ContentPlatformApplicationValidator.getAppCustomObjects().validate(
3915
3781
  {
3916
3782
  pageNo,
3917
3783
  pageSize,
3918
- definitionSlug,
3784
+ definitionId,
3919
3785
  },
3920
3786
  { abortEarly: false, allowUnknown: true }
3921
3787
  );
@@ -3926,29 +3792,30 @@ class Content {
3926
3792
  // Showing warrnings if extra unknown parameters are found
3927
3793
  const {
3928
3794
  error: warrning,
3929
- } = ContentPlatformApplicationValidator.getAppCustomObjectsBySlug().validate(
3795
+ } = ContentPlatformApplicationValidator.getAppCustomObjects().validate(
3930
3796
  {
3931
3797
  pageNo,
3932
3798
  pageSize,
3933
- definitionSlug,
3799
+ definitionId,
3934
3800
  },
3935
3801
  { abortEarly: false, allowUnknown: false }
3936
3802
  );
3937
3803
  if (warrning) {
3938
3804
  Logger({
3939
3805
  level: "WARN",
3940
- message: `Parameter Validation warrnings for platform > Content > getAppCustomObjectsBySlug \n ${warrning}`,
3806
+ message: `Parameter Validation warrnings for platform > Content > getAppCustomObjects \n ${warrning}`,
3941
3807
  });
3942
3808
  }
3943
3809
 
3944
3810
  const query_params = {};
3811
+ query_params["definition_id"] = definitionId;
3945
3812
  query_params["page_no"] = pageNo;
3946
3813
  query_params["page_size"] = pageSize;
3947
3814
 
3948
3815
  const response = await PlatformAPIClient.execute(
3949
3816
  this.config,
3950
3817
  "get",
3951
- `/service/platform/content/v2.0/company/${this.config.companyId}/application/${this.applicationId}/customobjects/definition/${definitionSlug}/entries`,
3818
+ `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/metaobjects`,
3952
3819
  query_params,
3953
3820
  undefined,
3954
3821
  requestHeaders,
@@ -3973,7 +3840,7 @@ class Content {
3973
3840
  } else {
3974
3841
  Logger({
3975
3842
  level: "WARN",
3976
- message: `Response Validation Warnings for platform > Content > getAppCustomObjectsBySlug \n ${res_error}`,
3843
+ message: `Response Validation Warnings for platform > Content > getAppCustomObjects \n ${res_error}`,
3977
3844
  });
3978
3845
  }
3979
3846
  }
@@ -4223,7 +4090,7 @@ class Content {
4223
4090
  * @param {ContentPlatformApplicationValidator.GetBlogsParam} arg - Arg object
4224
4091
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
4225
4092
  * @param {import("../PlatformAPIClient").Options} - Options
4226
- * @returns {Promise<ContentPlatformModel.BlogGetDetails>} - Success response
4093
+ * @returns {Promise<ContentPlatformModel.BlogGetResponse>} - Success response
4227
4094
  * @name getBlogs
4228
4095
  * @summary: List blogs
4229
4096
  * @description: List all blogs - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/getBlogs/).
@@ -4298,7 +4165,7 @@ class Content {
4298
4165
 
4299
4166
  const {
4300
4167
  error: res_error,
4301
- } = ContentPlatformModel.BlogGetDetails().validate(responseData, {
4168
+ } = ContentPlatformModel.BlogGetResponse().validate(responseData, {
4302
4169
  abortEarly: false,
4303
4170
  allowUnknown: true,
4304
4171
  });
@@ -4480,7 +4347,7 @@ class Content {
4480
4347
  *
4481
4348
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
4482
4349
  * @param {import("../PlatformAPIClient").Options} - Options
4483
- * @returns {Promise<ContentPlatformModel.DefaultNavigationDetails>} -
4350
+ * @returns {Promise<ContentPlatformModel.DefaultNavigationResponse>} -
4484
4351
  * Success response
4485
4352
  * @name getDefaultNavigations
4486
4353
  * @summary: Get default navigations
@@ -4533,10 +4400,10 @@ class Content {
4533
4400
 
4534
4401
  const {
4535
4402
  error: res_error,
4536
- } = ContentPlatformModel.DefaultNavigationDetails().validate(responseData, {
4537
- abortEarly: false,
4538
- allowUnknown: true,
4539
- });
4403
+ } = ContentPlatformModel.DefaultNavigationResponse().validate(
4404
+ responseData,
4405
+ { abortEarly: false, allowUnknown: true }
4406
+ );
4540
4407
 
4541
4408
  if (res_error) {
4542
4409
  if (this.config.options.strictResponseCheck === true) {
@@ -4634,83 +4501,6 @@ class Content {
4634
4501
  return response;
4635
4502
  }
4636
4503
 
4637
- /**
4638
- * @param {ContentPlatformApplicationValidator.GetDefaultSitemapConfigParam} arg
4639
- * - Arg object
4640
- *
4641
- * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
4642
- * @param {import("../PlatformAPIClient").Options} - Options
4643
- * @returns {Promise<ContentPlatformModel.DefaultSitemapConfig>} - Success response
4644
- * @name getDefaultSitemapConfig
4645
- * @summary: Get default sitemap configuration
4646
- * @description: Retrieves the current default sitemap configuration settings - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/getDefaultSitemapConfig/).
4647
- */
4648
- async getDefaultSitemapConfig(
4649
- { requestHeaders } = { requestHeaders: {} },
4650
- { responseHeaders } = { responseHeaders: false }
4651
- ) {
4652
- const {
4653
- error,
4654
- } = ContentPlatformApplicationValidator.getDefaultSitemapConfig().validate(
4655
- {},
4656
- { abortEarly: false, allowUnknown: true }
4657
- );
4658
- if (error) {
4659
- return Promise.reject(new FDKClientValidationError(error));
4660
- }
4661
-
4662
- // Showing warrnings if extra unknown parameters are found
4663
- const {
4664
- error: warrning,
4665
- } = ContentPlatformApplicationValidator.getDefaultSitemapConfig().validate(
4666
- {},
4667
- { abortEarly: false, allowUnknown: false }
4668
- );
4669
- if (warrning) {
4670
- Logger({
4671
- level: "WARN",
4672
- message: `Parameter Validation warrnings for platform > Content > getDefaultSitemapConfig \n ${warrning}`,
4673
- });
4674
- }
4675
-
4676
- const query_params = {};
4677
-
4678
- const response = await PlatformAPIClient.execute(
4679
- this.config,
4680
- "get",
4681
- `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/seo/sitemap/default`,
4682
- query_params,
4683
- undefined,
4684
- requestHeaders,
4685
- { responseHeaders }
4686
- );
4687
-
4688
- let responseData = response;
4689
- if (responseHeaders) {
4690
- responseData = response[0];
4691
- }
4692
-
4693
- const {
4694
- error: res_error,
4695
- } = ContentPlatformModel.DefaultSitemapConfig().validate(responseData, {
4696
- abortEarly: false,
4697
- allowUnknown: true,
4698
- });
4699
-
4700
- if (res_error) {
4701
- if (this.config.options.strictResponseCheck === true) {
4702
- return Promise.reject(new FDKResponseValidationError(res_error));
4703
- } else {
4704
- Logger({
4705
- level: "WARN",
4706
- message: `Response Validation Warnings for platform > Content > getDefaultSitemapConfig \n ${res_error}`,
4707
- });
4708
- }
4709
- }
4710
-
4711
- return response;
4712
- }
4713
-
4714
4504
  /**
4715
4505
  * @param {ContentPlatformApplicationValidator.GetFaqByIdOrSlugParam} arg - Arg object
4716
4506
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
@@ -5114,7 +4904,7 @@ class Content {
5114
4904
  * @param {ContentPlatformApplicationValidator.GetLandingPagesParam} arg - Arg object
5115
4905
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
5116
4906
  * @param {import("../PlatformAPIClient").Options} - Options
5117
- * @returns {Promise<ContentPlatformModel.LandingPageGetDetails>} - Success response
4907
+ * @returns {Promise<ContentPlatformModel.LandingPageGetResponse>} - Success response
5118
4908
  * @name getLandingPages
5119
4909
  * @summary: Get landing pages
5120
4910
  * @description: Lists a list landing pages as per device types - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/getLandingPages/).
@@ -5174,7 +4964,7 @@ class Content {
5174
4964
 
5175
4965
  const {
5176
4966
  error: res_error,
5177
- } = ContentPlatformModel.LandingPageGetDetails().validate(responseData, {
4967
+ } = ContentPlatformModel.LandingPageGetResponse().validate(responseData, {
5178
4968
  abortEarly: false,
5179
4969
  allowUnknown: true,
5180
4970
  });
@@ -5358,7 +5148,7 @@ class Content {
5358
5148
  * @param {ContentPlatformApplicationValidator.GetNavigationsParam} arg - Arg object
5359
5149
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
5360
5150
  * @param {import("../PlatformAPIClient").Options} - Options
5361
- * @returns {Promise<ContentPlatformModel.NavigationGetDetails>} - Success response
5151
+ * @returns {Promise<ContentPlatformModel.NavigationGetResponse>} - Success response
5362
5152
  * @name getNavigations
5363
5153
  * @summary: Get navigation items
5364
5154
  * @description: Retrieve a list of navigational elements. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/getNavigations/).
@@ -5423,7 +5213,7 @@ class Content {
5423
5213
 
5424
5214
  const {
5425
5215
  error: res_error,
5426
- } = ContentPlatformModel.NavigationGetDetails().validate(responseData, {
5216
+ } = ContentPlatformModel.NavigationGetResponse().validate(responseData, {
5427
5217
  abortEarly: false,
5428
5218
  allowUnknown: true,
5429
5219
  });
@@ -5675,7 +5465,7 @@ class Content {
5675
5465
  * @param {ContentPlatformApplicationValidator.GetPagesParam} arg - Arg object
5676
5466
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
5677
5467
  * @param {import("../PlatformAPIClient").Options} - Options
5678
- * @returns {Promise<ContentPlatformModel.PageGetDetails>} - Success response
5468
+ * @returns {Promise<ContentPlatformModel.PageGetResponse>} - Success response
5679
5469
  * @name getPages
5680
5470
  * @summary: Get pages
5681
5471
  * @description: Retrieve a list of available pages. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/getPages/).
@@ -5733,7 +5523,7 @@ class Content {
5733
5523
 
5734
5524
  const {
5735
5525
  error: res_error,
5736
- } = ContentPlatformModel.PageGetDetails().validate(responseData, {
5526
+ } = ContentPlatformModel.PageGetResponse().validate(responseData, {
5737
5527
  abortEarly: false,
5738
5528
  allowUnknown: true,
5739
5529
  });
@@ -6170,22 +5960,26 @@ class Content {
6170
5960
  }
6171
5961
 
6172
5962
  /**
6173
- * @param {ContentPlatformApplicationValidator.GetSitemapParam} arg - Arg object
5963
+ * @param {ContentPlatformApplicationValidator.GetSlideshowBySlugParam} arg
5964
+ * - Arg object
5965
+ *
6174
5966
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
6175
5967
  * @param {import("../PlatformAPIClient").Options} - Options
6176
- * @returns {Promise<ContentPlatformModel.SitemapConfig>} - Success response
6177
- * @name getSitemap
6178
- * @summary: Get a specific sitemap configuration
6179
- * @description: Retrieve a specific sitemap configuration by its name. Returns the complete configuration including the sitemap XML data, activation status, and timestamps.
6180
- * - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/getSitemap/).
5968
+ * @returns {Promise<ContentPlatformModel.SlideshowSchema>} - Success response
5969
+ * @name getSlideshowBySlug
5970
+ * @summary: Get Slideshow
5971
+ * @description: Use this API to get the details of a slideshow by its slug. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/getSlideshowBySlug/).
6181
5972
  */
6182
- async getSitemap(
6183
- { name, requestHeaders } = { requestHeaders: {} },
5973
+ async getSlideshowBySlug(
5974
+ { slug, devicePlatform, requestHeaders } = { requestHeaders: {} },
6184
5975
  { responseHeaders } = { responseHeaders: false }
6185
5976
  ) {
6186
- const { error } = ContentPlatformApplicationValidator.getSitemap().validate(
5977
+ const {
5978
+ error,
5979
+ } = ContentPlatformApplicationValidator.getSlideshowBySlug().validate(
6187
5980
  {
6188
- name,
5981
+ slug,
5982
+ devicePlatform,
6189
5983
  },
6190
5984
  { abortEarly: false, allowUnknown: true }
6191
5985
  );
@@ -6196,25 +5990,27 @@ class Content {
6196
5990
  // Showing warrnings if extra unknown parameters are found
6197
5991
  const {
6198
5992
  error: warrning,
6199
- } = ContentPlatformApplicationValidator.getSitemap().validate(
5993
+ } = ContentPlatformApplicationValidator.getSlideshowBySlug().validate(
6200
5994
  {
6201
- name,
5995
+ slug,
5996
+ devicePlatform,
6202
5997
  },
6203
5998
  { abortEarly: false, allowUnknown: false }
6204
5999
  );
6205
6000
  if (warrning) {
6206
6001
  Logger({
6207
6002
  level: "WARN",
6208
- message: `Parameter Validation warrnings for platform > Content > getSitemap \n ${warrning}`,
6003
+ message: `Parameter Validation warrnings for platform > Content > getSlideshowBySlug \n ${warrning}`,
6209
6004
  });
6210
6005
  }
6211
6006
 
6212
6007
  const query_params = {};
6008
+ query_params["device_platform"] = devicePlatform;
6213
6009
 
6214
6010
  const response = await PlatformAPIClient.execute(
6215
6011
  this.config,
6216
6012
  "get",
6217
- `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/seo/sitemaps/${name}`,
6013
+ `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/slideshows/${slug}`,
6218
6014
  query_params,
6219
6015
  undefined,
6220
6016
  requestHeaders,
@@ -6228,7 +6024,7 @@ class Content {
6228
6024
 
6229
6025
  const {
6230
6026
  error: res_error,
6231
- } = ContentPlatformModel.SitemapConfig().validate(responseData, {
6027
+ } = ContentPlatformModel.SlideshowSchema().validate(responseData, {
6232
6028
  abortEarly: false,
6233
6029
  allowUnknown: true,
6234
6030
  });
@@ -6239,7 +6035,7 @@ class Content {
6239
6035
  } else {
6240
6036
  Logger({
6241
6037
  level: "WARN",
6242
- message: `Response Validation Warnings for platform > Content > getSitemap \n ${res_error}`,
6038
+ message: `Response Validation Warnings for platform > Content > getSlideshowBySlug \n ${res_error}`,
6243
6039
  });
6244
6040
  }
6245
6041
  }
@@ -6248,30 +6044,27 @@ class Content {
6248
6044
  }
6249
6045
 
6250
6046
  /**
6251
- * @param {ContentPlatformApplicationValidator.GetSitemapsParam} arg - Arg object
6047
+ * @param {ContentPlatformApplicationValidator.GetSlideshowsParam} arg - Arg object
6252
6048
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
6253
6049
  * @param {import("../PlatformAPIClient").Options} - Options
6254
- * @returns {Promise<ContentPlatformModel.SitemapConfigurationList>} -
6255
- * Success response
6256
- * @name getSitemaps
6257
- * @summary: List sitemap configurations
6258
- * @description: Retrieve a list of sitemap configurations for a specific company and application. Each configuration contains the sitemap XML data and its activation status.
6259
- * - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/getSitemaps/).
6050
+ * @returns {Promise<ContentPlatformModel.SlideshowGetResponse>} - Success response
6051
+ * @name getSlideshows
6052
+ * @summary: List Slideshows
6053
+ * @description: Use this API to list all Slideshows - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/getSlideshows/).
6260
6054
  */
6261
- async getSitemaps(
6262
- { pageNo, pageSize, isActive, name, requestHeaders } = {
6055
+ async getSlideshows(
6056
+ { devicePlatform, pageNo, pageSize, requestHeaders } = {
6263
6057
  requestHeaders: {},
6264
6058
  },
6265
6059
  { responseHeaders } = { responseHeaders: false }
6266
6060
  ) {
6267
6061
  const {
6268
6062
  error,
6269
- } = ContentPlatformApplicationValidator.getSitemaps().validate(
6063
+ } = ContentPlatformApplicationValidator.getSlideshows().validate(
6270
6064
  {
6065
+ devicePlatform,
6271
6066
  pageNo,
6272
6067
  pageSize,
6273
- isActive,
6274
- name,
6275
6068
  },
6276
6069
  { abortEarly: false, allowUnknown: true }
6277
6070
  );
@@ -6282,32 +6075,30 @@ class Content {
6282
6075
  // Showing warrnings if extra unknown parameters are found
6283
6076
  const {
6284
6077
  error: warrning,
6285
- } = ContentPlatformApplicationValidator.getSitemaps().validate(
6078
+ } = ContentPlatformApplicationValidator.getSlideshows().validate(
6286
6079
  {
6080
+ devicePlatform,
6287
6081
  pageNo,
6288
6082
  pageSize,
6289
- isActive,
6290
- name,
6291
6083
  },
6292
6084
  { abortEarly: false, allowUnknown: false }
6293
6085
  );
6294
6086
  if (warrning) {
6295
6087
  Logger({
6296
6088
  level: "WARN",
6297
- message: `Parameter Validation warrnings for platform > Content > getSitemaps \n ${warrning}`,
6089
+ message: `Parameter Validation warrnings for platform > Content > getSlideshows \n ${warrning}`,
6298
6090
  });
6299
6091
  }
6300
6092
 
6301
6093
  const query_params = {};
6094
+ query_params["device_platform"] = devicePlatform;
6302
6095
  query_params["page_no"] = pageNo;
6303
6096
  query_params["page_size"] = pageSize;
6304
- query_params["is_active"] = isActive;
6305
- query_params["name"] = name;
6306
6097
 
6307
6098
  const response = await PlatformAPIClient.execute(
6308
6099
  this.config,
6309
6100
  "get",
6310
- `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/seo/sitemaps`,
6101
+ `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/slideshows`,
6311
6102
  query_params,
6312
6103
  undefined,
6313
6104
  requestHeaders,
@@ -6321,7 +6112,7 @@ class Content {
6321
6112
 
6322
6113
  const {
6323
6114
  error: res_error,
6324
- } = ContentPlatformModel.SitemapConfigurationList().validate(responseData, {
6115
+ } = ContentPlatformModel.SlideshowGetResponse().validate(responseData, {
6325
6116
  abortEarly: false,
6326
6117
  allowUnknown: true,
6327
6118
  });
@@ -6332,7 +6123,7 @@ class Content {
6332
6123
  } else {
6333
6124
  Logger({
6334
6125
  level: "WARN",
6335
- message: `Response Validation Warnings for platform > Content > getSitemaps \n ${res_error}`,
6126
+ message: `Response Validation Warnings for platform > Content > getSlideshows \n ${res_error}`,
6336
6127
  });
6337
6128
  }
6338
6129
  }
@@ -6341,27 +6132,66 @@ class Content {
6341
6132
  }
6342
6133
 
6343
6134
  /**
6344
- * @param {ContentPlatformApplicationValidator.GetSlideshowBySlugParam} arg
6135
+ * @param {Object} arg - Arg object.
6136
+ * @param {string} arg.companyId - Numeric ID allotted to a business account
6137
+ * on Fynd Platform
6138
+ * @param {string} arg.applicationId - Numeric ID allotted to an application
6139
+ * created within a business account.
6140
+ * @param {string} arg.devicePlatform - Filter slideshows by platform.
6141
+ * Acceptable values are: web, android, ios and all
6142
+ * @param {number} [arg.pageSize] - The number of items to retrieve in each
6143
+ * page. Default value is 10.
6144
+ * @returns {Paginator<ContentPlatformModel.SlideshowGetResponse>}
6145
+ * @summary: List Slideshows
6146
+ * @description: Use this API to list all Slideshows
6147
+ */
6148
+ getSlideshowsPaginator({
6149
+ companyId,
6150
+ applicationId,
6151
+ devicePlatform,
6152
+ pageSize,
6153
+ } = {}) {
6154
+ const paginator = new Paginator();
6155
+ const callback = async () => {
6156
+ const pageId = paginator.nextId;
6157
+ const pageNo = paginator.pageNo;
6158
+ const pageType = "number";
6159
+ const data = await this.getSlideshows({
6160
+ companyId: companyId,
6161
+ applicationId: applicationId,
6162
+ devicePlatform: devicePlatform,
6163
+ pageNo: pageNo,
6164
+ pageSize: pageSize,
6165
+ });
6166
+ paginator.setPaginator({
6167
+ hasNext: data.page.has_next ? true : false,
6168
+ nextId: data.page.next_id,
6169
+ });
6170
+ return data;
6171
+ };
6172
+ paginator.setCallback(callback.bind(this));
6173
+ return paginator;
6174
+ }
6175
+
6176
+ /**
6177
+ * @param {ContentPlatformApplicationValidator.GetSupportInformationParam} arg
6345
6178
  * - Arg object
6346
6179
  *
6347
6180
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
6348
6181
  * @param {import("../PlatformAPIClient").Options} - Options
6349
- * @returns {Promise<ContentPlatformModel.SlideshowSchema>} - Success response
6350
- * @name getSlideshowBySlug
6351
- * @summary: Get Slideshow
6352
- * @description: Use this API to get the details of a slideshow by its slug. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/getSlideshowBySlug/).
6182
+ * @returns {Promise<ContentPlatformModel.Support>} - Success response
6183
+ * @name getSupportInformation
6184
+ * @summary: Get support information
6185
+ * @description: Retrieve information related to customer support. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/getSupportInformation/).
6353
6186
  */
6354
- async getSlideshowBySlug(
6355
- { slug, devicePlatform, requestHeaders } = { requestHeaders: {} },
6187
+ async getSupportInformation(
6188
+ { requestHeaders } = { requestHeaders: {} },
6356
6189
  { responseHeaders } = { responseHeaders: false }
6357
6190
  ) {
6358
6191
  const {
6359
6192
  error,
6360
- } = ContentPlatformApplicationValidator.getSlideshowBySlug().validate(
6361
- {
6362
- slug,
6363
- devicePlatform,
6364
- },
6193
+ } = ContentPlatformApplicationValidator.getSupportInformation().validate(
6194
+ {},
6365
6195
  { abortEarly: false, allowUnknown: true }
6366
6196
  );
6367
6197
  if (error) {
@@ -6371,27 +6201,23 @@ class Content {
6371
6201
  // Showing warrnings if extra unknown parameters are found
6372
6202
  const {
6373
6203
  error: warrning,
6374
- } = ContentPlatformApplicationValidator.getSlideshowBySlug().validate(
6375
- {
6376
- slug,
6377
- devicePlatform,
6378
- },
6204
+ } = ContentPlatformApplicationValidator.getSupportInformation().validate(
6205
+ {},
6379
6206
  { abortEarly: false, allowUnknown: false }
6380
6207
  );
6381
6208
  if (warrning) {
6382
6209
  Logger({
6383
6210
  level: "WARN",
6384
- message: `Parameter Validation warrnings for platform > Content > getSlideshowBySlug \n ${warrning}`,
6211
+ message: `Parameter Validation warrnings for platform > Content > getSupportInformation \n ${warrning}`,
6385
6212
  });
6386
6213
  }
6387
6214
 
6388
6215
  const query_params = {};
6389
- query_params["device_platform"] = devicePlatform;
6390
6216
 
6391
6217
  const response = await PlatformAPIClient.execute(
6392
6218
  this.config,
6393
6219
  "get",
6394
- `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/slideshows/${slug}`,
6220
+ `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/support`,
6395
6221
  query_params,
6396
6222
  undefined,
6397
6223
  requestHeaders,
@@ -6405,7 +6231,7 @@ class Content {
6405
6231
 
6406
6232
  const {
6407
6233
  error: res_error,
6408
- } = ContentPlatformModel.SlideshowSchema().validate(responseData, {
6234
+ } = ContentPlatformModel.Support().validate(responseData, {
6409
6235
  abortEarly: false,
6410
6236
  allowUnknown: true,
6411
6237
  });
@@ -6416,7 +6242,7 @@ class Content {
6416
6242
  } else {
6417
6243
  Logger({
6418
6244
  level: "WARN",
6419
- message: `Response Validation Warnings for platform > Content > getSlideshowBySlug \n ${res_error}`,
6245
+ message: `Response Validation Warnings for platform > Content > getSupportInformation \n ${res_error}`,
6420
6246
  });
6421
6247
  }
6422
6248
  }
@@ -6425,192 +6251,27 @@ class Content {
6425
6251
  }
6426
6252
 
6427
6253
  /**
6428
- * @param {ContentPlatformApplicationValidator.GetSlideshowsParam} arg - Arg object
6254
+ * @param {ContentPlatformApplicationValidator.ImportAppCustomObjectEntriesParam} arg
6255
+ * - Arg object
6256
+ *
6429
6257
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
6430
6258
  * @param {import("../PlatformAPIClient").Options} - Options
6431
- * @returns {Promise<ContentPlatformModel.SlideshowGetDetails>} - Success response
6432
- * @name getSlideshows
6433
- * @summary: List Slideshows
6434
- * @description: Use this API to list all Slideshows - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/getSlideshows/).
6435
- */
6436
- async getSlideshows(
6437
- { devicePlatform, pageNo, pageSize, requestHeaders } = {
6438
- requestHeaders: {},
6439
- },
6440
- { responseHeaders } = { responseHeaders: false }
6441
- ) {
6442
- const {
6443
- error,
6444
- } = ContentPlatformApplicationValidator.getSlideshows().validate(
6445
- {
6446
- devicePlatform,
6447
- pageNo,
6448
- pageSize,
6449
- },
6450
- { abortEarly: false, allowUnknown: true }
6451
- );
6452
- if (error) {
6453
- return Promise.reject(new FDKClientValidationError(error));
6454
- }
6455
-
6456
- // Showing warrnings if extra unknown parameters are found
6457
- const {
6458
- error: warrning,
6459
- } = ContentPlatformApplicationValidator.getSlideshows().validate(
6460
- {
6461
- devicePlatform,
6462
- pageNo,
6463
- pageSize,
6464
- },
6465
- { abortEarly: false, allowUnknown: false }
6466
- );
6467
- if (warrning) {
6468
- Logger({
6469
- level: "WARN",
6470
- message: `Parameter Validation warrnings for platform > Content > getSlideshows \n ${warrning}`,
6471
- });
6472
- }
6473
-
6474
- const query_params = {};
6475
- query_params["device_platform"] = devicePlatform;
6476
- query_params["page_no"] = pageNo;
6477
- query_params["page_size"] = pageSize;
6478
-
6479
- const response = await PlatformAPIClient.execute(
6480
- this.config,
6481
- "get",
6482
- `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/slideshows`,
6483
- query_params,
6484
- undefined,
6485
- requestHeaders,
6486
- { responseHeaders }
6487
- );
6488
-
6489
- let responseData = response;
6490
- if (responseHeaders) {
6491
- responseData = response[0];
6492
- }
6493
-
6494
- const {
6495
- error: res_error,
6496
- } = ContentPlatformModel.SlideshowGetDetails().validate(responseData, {
6497
- abortEarly: false,
6498
- allowUnknown: true,
6499
- });
6500
-
6501
- if (res_error) {
6502
- if (this.config.options.strictResponseCheck === true) {
6503
- return Promise.reject(new FDKResponseValidationError(res_error));
6504
- } else {
6505
- Logger({
6506
- level: "WARN",
6507
- message: `Response Validation Warnings for platform > Content > getSlideshows \n ${res_error}`,
6508
- });
6509
- }
6510
- }
6511
-
6512
- return response;
6513
- }
6514
-
6515
- /**
6516
- * @param {ContentPlatformApplicationValidator.GetSupportInformationParam} arg
6517
- * - Arg object
6518
- *
6519
- * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
6520
- * @param {import("../PlatformAPIClient").Options} - Options
6521
- * @returns {Promise<ContentPlatformModel.Support>} - Success response
6522
- * @name getSupportInformation
6523
- * @summary: Get support information
6524
- * @description: Retrieve information related to customer support. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/getSupportInformation/).
6525
- */
6526
- async getSupportInformation(
6527
- { requestHeaders } = { requestHeaders: {} },
6528
- { responseHeaders } = { responseHeaders: false }
6529
- ) {
6530
- const {
6531
- error,
6532
- } = ContentPlatformApplicationValidator.getSupportInformation().validate(
6533
- {},
6534
- { abortEarly: false, allowUnknown: true }
6535
- );
6536
- if (error) {
6537
- return Promise.reject(new FDKClientValidationError(error));
6538
- }
6539
-
6540
- // Showing warrnings if extra unknown parameters are found
6541
- const {
6542
- error: warrning,
6543
- } = ContentPlatformApplicationValidator.getSupportInformation().validate(
6544
- {},
6545
- { abortEarly: false, allowUnknown: false }
6546
- );
6547
- if (warrning) {
6548
- Logger({
6549
- level: "WARN",
6550
- message: `Parameter Validation warrnings for platform > Content > getSupportInformation \n ${warrning}`,
6551
- });
6552
- }
6553
-
6554
- const query_params = {};
6555
-
6556
- const response = await PlatformAPIClient.execute(
6557
- this.config,
6558
- "get",
6559
- `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/support`,
6560
- query_params,
6561
- undefined,
6562
- requestHeaders,
6563
- { responseHeaders }
6564
- );
6565
-
6566
- let responseData = response;
6567
- if (responseHeaders) {
6568
- responseData = response[0];
6569
- }
6570
-
6571
- const {
6572
- error: res_error,
6573
- } = ContentPlatformModel.Support().validate(responseData, {
6574
- abortEarly: false,
6575
- allowUnknown: true,
6576
- });
6577
-
6578
- if (res_error) {
6579
- if (this.config.options.strictResponseCheck === true) {
6580
- return Promise.reject(new FDKResponseValidationError(res_error));
6581
- } else {
6582
- Logger({
6583
- level: "WARN",
6584
- message: `Response Validation Warnings for platform > Content > getSupportInformation \n ${res_error}`,
6585
- });
6586
- }
6587
- }
6588
-
6589
- return response;
6590
- }
6591
-
6592
- /**
6593
- * @param {ContentPlatformApplicationValidator.ImportAppCustomObjectEntriesBySlugParam} arg
6594
- * - Arg object
6595
- *
6596
- * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
6597
- * @param {import("../PlatformAPIClient").Options} - Options
6598
- * @returns {Promise<ContentPlatformModel.CustomObjectEntryBulkUploadDetails>}
6259
+ * @returns {Promise<ContentPlatformModel.CustomObjectEntryBulkUploadResponse>}
6599
6260
  * - Success response
6600
6261
  *
6601
- * @name importAppCustomObjectEntriesBySlug
6262
+ * @name importAppCustomObjectEntries
6602
6263
  * @summary: Bulk custom object entries upload
6603
- * @description: Custom object bulk import of bulk entries can be performed using this endpoint. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/importAppCustomObjectEntriesBySlug/).
6264
+ * @description: Custom object bulk import of bulk entries can be performed using this endpoint. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/importAppCustomObjectEntries/).
6604
6265
  */
6605
- async importAppCustomObjectEntriesBySlug(
6606
- { slug, body, requestHeaders } = { requestHeaders: {} },
6266
+ async importAppCustomObjectEntries(
6267
+ { definitionId, body, requestHeaders } = { requestHeaders: {} },
6607
6268
  { responseHeaders } = { responseHeaders: false }
6608
6269
  ) {
6609
6270
  const {
6610
6271
  error,
6611
- } = ContentPlatformApplicationValidator.importAppCustomObjectEntriesBySlug().validate(
6272
+ } = ContentPlatformApplicationValidator.importAppCustomObjectEntries().validate(
6612
6273
  {
6613
- slug,
6274
+ definitionId,
6614
6275
  body,
6615
6276
  },
6616
6277
  { abortEarly: false, allowUnknown: true }
@@ -6622,9 +6283,9 @@ class Content {
6622
6283
  // Showing warrnings if extra unknown parameters are found
6623
6284
  const {
6624
6285
  error: warrning,
6625
- } = ContentPlatformApplicationValidator.importAppCustomObjectEntriesBySlug().validate(
6286
+ } = ContentPlatformApplicationValidator.importAppCustomObjectEntries().validate(
6626
6287
  {
6627
- slug,
6288
+ definitionId,
6628
6289
  body,
6629
6290
  },
6630
6291
  { abortEarly: false, allowUnknown: false }
@@ -6632,7 +6293,7 @@ class Content {
6632
6293
  if (warrning) {
6633
6294
  Logger({
6634
6295
  level: "WARN",
6635
- message: `Parameter Validation warrnings for platform > Content > importAppCustomObjectEntriesBySlug \n ${warrning}`,
6296
+ message: `Parameter Validation warrnings for platform > Content > importAppCustomObjectEntries \n ${warrning}`,
6636
6297
  });
6637
6298
  }
6638
6299
 
@@ -6641,7 +6302,7 @@ class Content {
6641
6302
  const response = await PlatformAPIClient.execute(
6642
6303
  this.config,
6643
6304
  "post",
6644
- `/service/platform/content/v2.0/company/${this.config.companyId}/application/${this.applicationId}/customobjects/definition/${slug}/bulk/upload`,
6305
+ `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/metaobjects/bulk/${definitionId}/upload`,
6645
6306
  query_params,
6646
6307
  body,
6647
6308
  requestHeaders,
@@ -6655,7 +6316,7 @@ class Content {
6655
6316
 
6656
6317
  const {
6657
6318
  error: res_error,
6658
- } = ContentPlatformModel.CustomObjectEntryBulkUploadDetails().validate(
6319
+ } = ContentPlatformModel.CustomObjectEntryBulkUploadResponse().validate(
6659
6320
  responseData,
6660
6321
  { abortEarly: false, allowUnknown: true }
6661
6322
  );
@@ -6666,7 +6327,7 @@ class Content {
6666
6327
  } else {
6667
6328
  Logger({
6668
6329
  level: "WARN",
6669
- message: `Response Validation Warnings for platform > Content > importAppCustomObjectEntriesBySlug \n ${res_error}`,
6330
+ message: `Response Validation Warnings for platform > Content > importAppCustomObjectEntries \n ${res_error}`,
6670
6331
  });
6671
6332
  }
6672
6333
  }
@@ -6680,7 +6341,8 @@ class Content {
6680
6341
  *
6681
6342
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
6682
6343
  * @param {import("../PlatformAPIClient").Options} - Options
6683
- * @returns {Promise<ContentPlatformModel.TagDeleteSuccessDetails>} - Success response
6344
+ * @returns {Promise<ContentPlatformModel.TagDeleteSuccessResponse>} -
6345
+ * Success response
6684
6346
  * @name removeInjectableTag
6685
6347
  * @summary: Remove HTML tag
6686
6348
  * @description: Delete a specific injectable tag. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/removeInjectableTag/).
@@ -6736,7 +6398,7 @@ class Content {
6736
6398
 
6737
6399
  const {
6738
6400
  error: res_error,
6739
- } = ContentPlatformModel.TagDeleteSuccessDetails().validate(responseData, {
6401
+ } = ContentPlatformModel.TagDeleteSuccessResponse().validate(responseData, {
6740
6402
  abortEarly: false,
6741
6403
  allowUnknown: true,
6742
6404
  });
@@ -6838,25 +6500,25 @@ class Content {
6838
6500
  }
6839
6501
 
6840
6502
  /**
6841
- * @param {ContentPlatformApplicationValidator.SampleAppCustomObjectBulkEntryBySlugParam} arg
6503
+ * @param {ContentPlatformApplicationValidator.SampleAppCustomObjectBulkEntryParam} arg
6842
6504
  * - Arg object
6843
6505
  *
6844
6506
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
6845
6507
  * @param {import("../PlatformAPIClient").Options} - Options
6846
6508
  * @returns {Promise<string>} - Success response
6847
- * @name sampleAppCustomObjectBulkEntryBySlug
6509
+ * @name sampleAppCustomObjectBulkEntry
6848
6510
  * @summary: Download sample for custom object bulk entry
6849
- * @description: Sample files for custom object bulk import can be obtained from this endpoint. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/sampleAppCustomObjectBulkEntryBySlug/).
6511
+ * @description: Sample files for custom object bulk import can be obtained from this endpoint. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/sampleAppCustomObjectBulkEntry/).
6850
6512
  */
6851
- async sampleAppCustomObjectBulkEntryBySlug(
6852
- { slug, requestHeaders } = { requestHeaders: {} },
6513
+ async sampleAppCustomObjectBulkEntry(
6514
+ { definitionId, requestHeaders } = { requestHeaders: {} },
6853
6515
  { responseHeaders } = { responseHeaders: false }
6854
6516
  ) {
6855
6517
  const {
6856
6518
  error,
6857
- } = ContentPlatformApplicationValidator.sampleAppCustomObjectBulkEntryBySlug().validate(
6519
+ } = ContentPlatformApplicationValidator.sampleAppCustomObjectBulkEntry().validate(
6858
6520
  {
6859
- slug,
6521
+ definitionId,
6860
6522
  },
6861
6523
  { abortEarly: false, allowUnknown: true }
6862
6524
  );
@@ -6867,16 +6529,16 @@ class Content {
6867
6529
  // Showing warrnings if extra unknown parameters are found
6868
6530
  const {
6869
6531
  error: warrning,
6870
- } = ContentPlatformApplicationValidator.sampleAppCustomObjectBulkEntryBySlug().validate(
6532
+ } = ContentPlatformApplicationValidator.sampleAppCustomObjectBulkEntry().validate(
6871
6533
  {
6872
- slug,
6534
+ definitionId,
6873
6535
  },
6874
6536
  { abortEarly: false, allowUnknown: false }
6875
6537
  );
6876
6538
  if (warrning) {
6877
6539
  Logger({
6878
6540
  level: "WARN",
6879
- message: `Parameter Validation warrnings for platform > Content > sampleAppCustomObjectBulkEntryBySlug \n ${warrning}`,
6541
+ message: `Parameter Validation warrnings for platform > Content > sampleAppCustomObjectBulkEntry \n ${warrning}`,
6880
6542
  });
6881
6543
  }
6882
6544
 
@@ -6885,7 +6547,7 @@ class Content {
6885
6547
  const response = await PlatformAPIClient.execute(
6886
6548
  this.config,
6887
6549
  "get",
6888
- `/service/platform/content/v2.0/company/${this.config.companyId}/application/${this.applicationId}/customobjects/definition/${slug}/bulk/sample`,
6550
+ `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/metaobjects/bulk/${definitionId}/sample`,
6889
6551
  query_params,
6890
6552
  undefined,
6891
6553
  requestHeaders,
@@ -6907,7 +6569,7 @@ class Content {
6907
6569
  } else {
6908
6570
  Logger({
6909
6571
  level: "WARN",
6910
- message: `Response Validation Warnings for platform > Content > sampleAppCustomObjectBulkEntryBySlug \n ${res_error}`,
6572
+ message: `Response Validation Warnings for platform > Content > sampleAppCustomObjectBulkEntry \n ${res_error}`,
6911
6573
  });
6912
6574
  }
6913
6575
  }
@@ -7164,94 +6826,7 @@ class Content {
7164
6826
  }
7165
6827
 
7166
6828
  /**
7167
- * @param {ContentPlatformApplicationValidator.UpdateAppCustomFieldByResourceSlugParam} arg
7168
- * - Arg object
7169
- *
7170
- * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
7171
- * @param {import("../PlatformAPIClient").Options} - Options
7172
- * @returns {Promise<ContentPlatformModel.CustomFieldsResponseByResourceIdSchema>}
7173
- * - Success response
7174
- *
7175
- * @name updateAppCustomFieldByResourceSlug
7176
- * @summary: Create custom field entries for gives resource and resource slug
7177
- * @description: You can add a custom field using this endpoint to any resource by providing the resource slug. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/updateAppCustomFieldByResourceSlug/).
7178
- */
7179
- async updateAppCustomFieldByResourceSlug(
7180
- { resource, resourceSlug, body, requestHeaders } = { requestHeaders: {} },
7181
- { responseHeaders } = { responseHeaders: false }
7182
- ) {
7183
- const {
7184
- error,
7185
- } = ContentPlatformApplicationValidator.updateAppCustomFieldByResourceSlug().validate(
7186
- {
7187
- resource,
7188
- resourceSlug,
7189
- body,
7190
- },
7191
- { abortEarly: false, allowUnknown: true }
7192
- );
7193
- if (error) {
7194
- return Promise.reject(new FDKClientValidationError(error));
7195
- }
7196
-
7197
- // Showing warrnings if extra unknown parameters are found
7198
- const {
7199
- error: warrning,
7200
- } = ContentPlatformApplicationValidator.updateAppCustomFieldByResourceSlug().validate(
7201
- {
7202
- resource,
7203
- resourceSlug,
7204
- body,
7205
- },
7206
- { abortEarly: false, allowUnknown: false }
7207
- );
7208
- if (warrning) {
7209
- Logger({
7210
- level: "WARN",
7211
- message: `Parameter Validation warrnings for platform > Content > updateAppCustomFieldByResourceSlug \n ${warrning}`,
7212
- });
7213
- }
7214
-
7215
- const query_params = {};
7216
-
7217
- const response = await PlatformAPIClient.execute(
7218
- this.config,
7219
- "put",
7220
- `/service/platform/content/v2.0/company/${this.config.companyId}/application/${this.applicationId}/customfields/resource/${resource}/${resourceSlug}`,
7221
- query_params,
7222
- body,
7223
- requestHeaders,
7224
- { responseHeaders }
7225
- );
7226
-
7227
- let responseData = response;
7228
- if (responseHeaders) {
7229
- responseData = response[0];
7230
- }
7231
-
7232
- const {
7233
- error: res_error,
7234
- } = ContentPlatformModel.CustomFieldsResponseByResourceIdSchema().validate(
7235
- responseData,
7236
- { abortEarly: false, allowUnknown: true }
7237
- );
7238
-
7239
- if (res_error) {
7240
- if (this.config.options.strictResponseCheck === true) {
7241
- return Promise.reject(new FDKResponseValidationError(res_error));
7242
- } else {
7243
- Logger({
7244
- level: "WARN",
7245
- message: `Response Validation Warnings for platform > Content > updateAppCustomFieldByResourceSlug \n ${res_error}`,
7246
- });
7247
- }
7248
- }
7249
-
7250
- return response;
7251
- }
7252
-
7253
- /**
7254
- * @param {ContentPlatformApplicationValidator.UpdateAppCustomFieldDefinitionBySlugParam} arg
6829
+ * @param {ContentPlatformApplicationValidator.UpdateAppCustomFieldDefinitionParam} arg
7255
6830
  * - Arg object
7256
6831
  *
7257
6832
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
@@ -7259,23 +6834,19 @@ class Content {
7259
6834
  * @returns {Promise<ContentPlatformModel.CustomFieldDefinitionDetailResSchema>}
7260
6835
  * - Success response
7261
6836
  *
7262
- * @name updateAppCustomFieldDefinitionBySlug
6837
+ * @name updateAppCustomFieldDefinition
7263
6838
  * @summary: Update custom field definition
7264
- * @description: Custom fields definition can be update using this api, You can update custom field definition name and description. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/updateAppCustomFieldDefinitionBySlug/).
6839
+ * @description: Custom fields definition can be update using this api, You can update custom field definition name and description. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/updateAppCustomFieldDefinition/).
7265
6840
  */
7266
- async updateAppCustomFieldDefinitionBySlug(
7267
- { slug, resource, namespace, body, requestHeaders } = {
7268
- requestHeaders: {},
7269
- },
6841
+ async updateAppCustomFieldDefinition(
6842
+ { definitionId, body, requestHeaders } = { requestHeaders: {} },
7270
6843
  { responseHeaders } = { responseHeaders: false }
7271
6844
  ) {
7272
6845
  const {
7273
6846
  error,
7274
- } = ContentPlatformApplicationValidator.updateAppCustomFieldDefinitionBySlug().validate(
6847
+ } = ContentPlatformApplicationValidator.updateAppCustomFieldDefinition().validate(
7275
6848
  {
7276
- slug,
7277
- resource,
7278
- namespace,
6849
+ definitionId,
7279
6850
  body,
7280
6851
  },
7281
6852
  { abortEarly: false, allowUnknown: true }
@@ -7287,11 +6858,9 @@ class Content {
7287
6858
  // Showing warrnings if extra unknown parameters are found
7288
6859
  const {
7289
6860
  error: warrning,
7290
- } = ContentPlatformApplicationValidator.updateAppCustomFieldDefinitionBySlug().validate(
6861
+ } = ContentPlatformApplicationValidator.updateAppCustomFieldDefinition().validate(
7291
6862
  {
7292
- slug,
7293
- resource,
7294
- namespace,
6863
+ definitionId,
7295
6864
  body,
7296
6865
  },
7297
6866
  { abortEarly: false, allowUnknown: false }
@@ -7299,7 +6868,7 @@ class Content {
7299
6868
  if (warrning) {
7300
6869
  Logger({
7301
6870
  level: "WARN",
7302
- message: `Parameter Validation warrnings for platform > Content > updateAppCustomFieldDefinitionBySlug \n ${warrning}`,
6871
+ message: `Parameter Validation warrnings for platform > Content > updateAppCustomFieldDefinition \n ${warrning}`,
7303
6872
  });
7304
6873
  }
7305
6874
 
@@ -7308,7 +6877,7 @@ class Content {
7308
6877
  const response = await PlatformAPIClient.execute(
7309
6878
  this.config,
7310
6879
  "put",
7311
- `/service/platform/content/v2.0/company/${this.config.companyId}/application/${this.applicationId}/customfields/resource/${resource}/namespace/${namespace}/definition/${slug}`,
6880
+ `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/metafields/definitions/${definitionId}`,
7312
6881
  query_params,
7313
6882
  body,
7314
6883
  requestHeaders,
@@ -7333,7 +6902,7 @@ class Content {
7333
6902
  } else {
7334
6903
  Logger({
7335
6904
  level: "WARN",
7336
- message: `Response Validation Warnings for platform > Content > updateAppCustomFieldDefinitionBySlug \n ${res_error}`,
6905
+ message: `Response Validation Warnings for platform > Content > updateAppCustomFieldDefinition \n ${res_error}`,
7337
6906
  });
7338
6907
  }
7339
6908
  }
@@ -7342,27 +6911,25 @@ class Content {
7342
6911
  }
7343
6912
 
7344
6913
  /**
7345
- * @param {ContentPlatformApplicationValidator.UpdateAppCustomObjectBySlugParam} arg
6914
+ * @param {ContentPlatformApplicationValidator.UpdateAppCustomObjectParam} arg
7346
6915
  * - Arg object
7347
6916
  *
7348
6917
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
7349
6918
  * @param {import("../PlatformAPIClient").Options} - Options
7350
- * @returns {Promise<ContentPlatformModel.CustomObjectBySlugSchema>} -
7351
- * Success response
7352
- * @name updateAppCustomObjectBySlug
6919
+ * @returns {Promise<ContentPlatformModel.CustomObjectByIdSchema>} - Success response
6920
+ * @name updateAppCustomObject
7353
6921
  * @summary: Update custom object details
7354
- * @description: Custom object entries can be updated using this endpoint. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/updateAppCustomObjectBySlug/).
6922
+ * @description: Custom object entries can be updated using this endpoint. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/updateAppCustomObject/).
7355
6923
  */
7356
- async updateAppCustomObjectBySlug(
7357
- { definitionSlug, slug, body, requestHeaders } = { requestHeaders: {} },
6924
+ async updateAppCustomObject(
6925
+ { metaobjectId, body, requestHeaders } = { requestHeaders: {} },
7358
6926
  { responseHeaders } = { responseHeaders: false }
7359
6927
  ) {
7360
6928
  const {
7361
6929
  error,
7362
- } = ContentPlatformApplicationValidator.updateAppCustomObjectBySlug().validate(
6930
+ } = ContentPlatformApplicationValidator.updateAppCustomObject().validate(
7363
6931
  {
7364
- definitionSlug,
7365
- slug,
6932
+ metaobjectId,
7366
6933
  body,
7367
6934
  },
7368
6935
  { abortEarly: false, allowUnknown: true }
@@ -7374,10 +6941,9 @@ class Content {
7374
6941
  // Showing warrnings if extra unknown parameters are found
7375
6942
  const {
7376
6943
  error: warrning,
7377
- } = ContentPlatformApplicationValidator.updateAppCustomObjectBySlug().validate(
6944
+ } = ContentPlatformApplicationValidator.updateAppCustomObject().validate(
7378
6945
  {
7379
- definitionSlug,
7380
- slug,
6946
+ metaobjectId,
7381
6947
  body,
7382
6948
  },
7383
6949
  { abortEarly: false, allowUnknown: false }
@@ -7385,7 +6951,7 @@ class Content {
7385
6951
  if (warrning) {
7386
6952
  Logger({
7387
6953
  level: "WARN",
7388
- message: `Parameter Validation warrnings for platform > Content > updateAppCustomObjectBySlug \n ${warrning}`,
6954
+ message: `Parameter Validation warrnings for platform > Content > updateAppCustomObject \n ${warrning}`,
7389
6955
  });
7390
6956
  }
7391
6957
 
@@ -7394,7 +6960,7 @@ class Content {
7394
6960
  const response = await PlatformAPIClient.execute(
7395
6961
  this.config,
7396
6962
  "put",
7397
- `/service/platform/content/v2.0/company/${this.config.companyId}/application/${this.applicationId}/customobjects/definition/${definitionSlug}/entries/${slug}`,
6963
+ `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/metaobjects/${metaobjectId}`,
7398
6964
  query_params,
7399
6965
  body,
7400
6966
  requestHeaders,
@@ -7408,7 +6974,7 @@ class Content {
7408
6974
 
7409
6975
  const {
7410
6976
  error: res_error,
7411
- } = ContentPlatformModel.CustomObjectBySlugSchema().validate(responseData, {
6977
+ } = ContentPlatformModel.CustomObjectByIdSchema().validate(responseData, {
7412
6978
  abortEarly: false,
7413
6979
  allowUnknown: true,
7414
6980
  });
@@ -7419,7 +6985,7 @@ class Content {
7419
6985
  } else {
7420
6986
  Logger({
7421
6987
  level: "WARN",
7422
- message: `Response Validation Warnings for platform > Content > updateAppCustomObjectBySlug \n ${res_error}`,
6988
+ message: `Response Validation Warnings for platform > Content > updateAppCustomObject \n ${res_error}`,
7423
6989
  });
7424
6990
  }
7425
6991
  }
@@ -7428,27 +6994,26 @@ class Content {
7428
6994
  }
7429
6995
 
7430
6996
  /**
7431
- * @param {ContentPlatformApplicationValidator.UpdateAppCustomObjectDefinitionBySlugParam} arg
6997
+ * @param {ContentPlatformApplicationValidator.UpdateAppCustomObjectDefinitionParam} arg
7432
6998
  * - Arg object
7433
6999
  *
7434
7000
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
7435
7001
  * @param {import("../PlatformAPIClient").Options} - Options
7436
- * @returns {Promise<ContentPlatformModel.CustomObjectDefinitionSlugSchema>}
7437
- * - Success response
7438
- *
7439
- * @name updateAppCustomObjectDefinitionBySlug
7002
+ * @returns {Promise<ContentPlatformModel.CustomObjectDefinitionSchema>} -
7003
+ * Success response
7004
+ * @name updateAppCustomObjectDefinition
7440
7005
  * @summary: Update custom object definition
7441
- * @description: Custom object definitions can be updated using this endpoint. You can update the name and description of the custom object and add more custom field definitions to the existing custom object. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/updateAppCustomObjectDefinitionBySlug/).
7006
+ * @description: Custom object definitions can be updated using this endpoint. You can update the name and description of the custom object and add more custom field definitions to the existing custom object. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/updateAppCustomObjectDefinition/).
7442
7007
  */
7443
- async updateAppCustomObjectDefinitionBySlug(
7444
- { slug, body, requestHeaders } = { requestHeaders: {} },
7008
+ async updateAppCustomObjectDefinition(
7009
+ { definitionId, body, requestHeaders } = { requestHeaders: {} },
7445
7010
  { responseHeaders } = { responseHeaders: false }
7446
7011
  ) {
7447
7012
  const {
7448
7013
  error,
7449
- } = ContentPlatformApplicationValidator.updateAppCustomObjectDefinitionBySlug().validate(
7014
+ } = ContentPlatformApplicationValidator.updateAppCustomObjectDefinition().validate(
7450
7015
  {
7451
- slug,
7016
+ definitionId,
7452
7017
  body,
7453
7018
  },
7454
7019
  { abortEarly: false, allowUnknown: true }
@@ -7460,9 +7025,9 @@ class Content {
7460
7025
  // Showing warrnings if extra unknown parameters are found
7461
7026
  const {
7462
7027
  error: warrning,
7463
- } = ContentPlatformApplicationValidator.updateAppCustomObjectDefinitionBySlug().validate(
7028
+ } = ContentPlatformApplicationValidator.updateAppCustomObjectDefinition().validate(
7464
7029
  {
7465
- slug,
7030
+ definitionId,
7466
7031
  body,
7467
7032
  },
7468
7033
  { abortEarly: false, allowUnknown: false }
@@ -7470,7 +7035,7 @@ class Content {
7470
7035
  if (warrning) {
7471
7036
  Logger({
7472
7037
  level: "WARN",
7473
- message: `Parameter Validation warrnings for platform > Content > updateAppCustomObjectDefinitionBySlug \n ${warrning}`,
7038
+ message: `Parameter Validation warrnings for platform > Content > updateAppCustomObjectDefinition \n ${warrning}`,
7474
7039
  });
7475
7040
  }
7476
7041
 
@@ -7479,7 +7044,7 @@ class Content {
7479
7044
  const response = await PlatformAPIClient.execute(
7480
7045
  this.config,
7481
7046
  "put",
7482
- `/service/platform/content/v2.0/company/${this.config.companyId}/application/${this.applicationId}/customobjects/definition/${slug}`,
7047
+ `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/metaobjects/definitions/${definitionId}`,
7483
7048
  query_params,
7484
7049
  body,
7485
7050
  requestHeaders,
@@ -7493,7 +7058,7 @@ class Content {
7493
7058
 
7494
7059
  const {
7495
7060
  error: res_error,
7496
- } = ContentPlatformModel.CustomObjectDefinitionSlugSchema().validate(
7061
+ } = ContentPlatformModel.CustomObjectDefinitionSchema().validate(
7497
7062
  responseData,
7498
7063
  { abortEarly: false, allowUnknown: true }
7499
7064
  );
@@ -7504,7 +7069,7 @@ class Content {
7504
7069
  } else {
7505
7070
  Logger({
7506
7071
  level: "WARN",
7507
- message: `Response Validation Warnings for platform > Content > updateAppCustomObjectDefinitionBySlug \n ${res_error}`,
7072
+ message: `Response Validation Warnings for platform > Content > updateAppCustomObjectDefinition \n ${res_error}`,
7508
7073
  });
7509
7074
  }
7510
7075
  }
@@ -7591,87 +7156,6 @@ class Content {
7591
7156
  return response;
7592
7157
  }
7593
7158
 
7594
- /**
7595
- * @param {ContentPlatformApplicationValidator.UpdateDefaultSitemapConfigParam} arg
7596
- * - Arg object
7597
- *
7598
- * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
7599
- * @param {import("../PlatformAPIClient").Options} - Options
7600
- * @returns {Promise<ContentPlatformModel.DefaultSitemapConfig>} - Success response
7601
- * @name updateDefaultSitemapConfig
7602
- * @summary: Update default sitemap configuration
7603
- * @description: Updates the default sitemap configuration settings - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/updateDefaultSitemapConfig/).
7604
- */
7605
- async updateDefaultSitemapConfig(
7606
- { body, requestHeaders } = { requestHeaders: {} },
7607
- { responseHeaders } = { responseHeaders: false }
7608
- ) {
7609
- const {
7610
- error,
7611
- } = ContentPlatformApplicationValidator.updateDefaultSitemapConfig().validate(
7612
- {
7613
- body,
7614
- },
7615
- { abortEarly: false, allowUnknown: true }
7616
- );
7617
- if (error) {
7618
- return Promise.reject(new FDKClientValidationError(error));
7619
- }
7620
-
7621
- // Showing warrnings if extra unknown parameters are found
7622
- const {
7623
- error: warrning,
7624
- } = ContentPlatformApplicationValidator.updateDefaultSitemapConfig().validate(
7625
- {
7626
- body,
7627
- },
7628
- { abortEarly: false, allowUnknown: false }
7629
- );
7630
- if (warrning) {
7631
- Logger({
7632
- level: "WARN",
7633
- message: `Parameter Validation warrnings for platform > Content > updateDefaultSitemapConfig \n ${warrning}`,
7634
- });
7635
- }
7636
-
7637
- const query_params = {};
7638
-
7639
- const response = await PlatformAPIClient.execute(
7640
- this.config,
7641
- "put",
7642
- `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/seo/sitemap/default`,
7643
- query_params,
7644
- body,
7645
- requestHeaders,
7646
- { responseHeaders }
7647
- );
7648
-
7649
- let responseData = response;
7650
- if (responseHeaders) {
7651
- responseData = response[0];
7652
- }
7653
-
7654
- const {
7655
- error: res_error,
7656
- } = ContentPlatformModel.DefaultSitemapConfig().validate(responseData, {
7657
- abortEarly: false,
7658
- allowUnknown: true,
7659
- });
7660
-
7661
- if (res_error) {
7662
- if (this.config.options.strictResponseCheck === true) {
7663
- return Promise.reject(new FDKResponseValidationError(res_error));
7664
- } else {
7665
- Logger({
7666
- level: "WARN",
7667
- message: `Response Validation Warnings for platform > Content > updateDefaultSitemapConfig \n ${res_error}`,
7668
- });
7669
- }
7670
- }
7671
-
7672
- return response;
7673
- }
7674
-
7675
7159
  /**
7676
7160
  * @param {ContentPlatformApplicationValidator.UpdateFaqParam} arg - Arg object
7677
7161
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
@@ -8488,88 +7972,6 @@ class Content {
8488
7972
  return response;
8489
7973
  }
8490
7974
 
8491
- /**
8492
- * @param {ContentPlatformApplicationValidator.UpdateSitemapParam} arg - Arg object
8493
- * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
8494
- * @param {import("../PlatformAPIClient").Options} - Options
8495
- * @returns {Promise<ContentPlatformModel.SitemapConfig>} - Success response
8496
- * @name updateSitemap
8497
- * @summary: Update a specific sitemap configuration
8498
- * @description: Update an existing sitemap configuration identified by its name. You can update the activation status and/or the sitemap XML data. The name cannot be modified once the configuration is created. The updated sitemap XML data must be valid XML following the sitemap protocol specification.
8499
- * - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/content/updateSitemap/).
8500
- */
8501
- async updateSitemap(
8502
- { name, body, requestHeaders } = { requestHeaders: {} },
8503
- { responseHeaders } = { responseHeaders: false }
8504
- ) {
8505
- const {
8506
- error,
8507
- } = ContentPlatformApplicationValidator.updateSitemap().validate(
8508
- {
8509
- name,
8510
- body,
8511
- },
8512
- { abortEarly: false, allowUnknown: true }
8513
- );
8514
- if (error) {
8515
- return Promise.reject(new FDKClientValidationError(error));
8516
- }
8517
-
8518
- // Showing warrnings if extra unknown parameters are found
8519
- const {
8520
- error: warrning,
8521
- } = ContentPlatformApplicationValidator.updateSitemap().validate(
8522
- {
8523
- name,
8524
- body,
8525
- },
8526
- { abortEarly: false, allowUnknown: false }
8527
- );
8528
- if (warrning) {
8529
- Logger({
8530
- level: "WARN",
8531
- message: `Parameter Validation warrnings for platform > Content > updateSitemap \n ${warrning}`,
8532
- });
8533
- }
8534
-
8535
- const query_params = {};
8536
-
8537
- const response = await PlatformAPIClient.execute(
8538
- this.config,
8539
- "put",
8540
- `/service/platform/content/v1.0/company/${this.config.companyId}/application/${this.applicationId}/seo/sitemaps/${name}`,
8541
- query_params,
8542
- body,
8543
- requestHeaders,
8544
- { responseHeaders }
8545
- );
8546
-
8547
- let responseData = response;
8548
- if (responseHeaders) {
8549
- responseData = response[0];
8550
- }
8551
-
8552
- const {
8553
- error: res_error,
8554
- } = ContentPlatformModel.SitemapConfig().validate(responseData, {
8555
- abortEarly: false,
8556
- allowUnknown: true,
8557
- });
8558
-
8559
- if (res_error) {
8560
- if (this.config.options.strictResponseCheck === true) {
8561
- return Promise.reject(new FDKResponseValidationError(res_error));
8562
- } else {
8563
- Logger({
8564
- level: "WARN",
8565
- message: `Response Validation Warnings for platform > Content > updateSitemap \n ${res_error}`,
8566
- });
8567
- }
8568
- }
8569
-
8570
- return response;
8571
- }
8572
-
8573
7975
  /**
8574
7976
  * @param {ContentPlatformApplicationValidator.UpdateSlideshowParam} arg - Arg object
8575
7977
  * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`