@gofynd/fdk-client-javascript 1.2.0 → 1.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (262) hide show
  1. package/README.md +44 -7
  2. package/package.json +1 -2
  3. package/sdk/application/ApplicationAPIClient.d.ts +3 -3
  4. package/sdk/application/ApplicationAPIClient.js +6 -4
  5. package/sdk/application/ApplicationClient.d.ts +2 -3
  6. package/sdk/application/ApplicationClient.js +1 -45
  7. package/sdk/application/ApplicationConfig.d.ts +46 -6
  8. package/sdk/application/ApplicationConfig.js +15 -16
  9. package/sdk/application/Cart/CartApplicationClient.d.ts +61 -33
  10. package/sdk/application/Cart/CartApplicationClient.js +225 -134
  11. package/sdk/application/Cart/CartApplicationModel.d.ts +4 -4
  12. package/sdk/application/Cart/CartApplicationModel.js +4 -4
  13. package/sdk/application/Catalog/CatalogApplicationClient.d.ts +61 -30
  14. package/sdk/application/Catalog/CatalogApplicationClient.js +234 -146
  15. package/sdk/application/Catalog/CatalogApplicationModel.d.ts +115 -13
  16. package/sdk/application/Catalog/CatalogApplicationModel.js +77 -12
  17. package/sdk/application/Common/CommonApplicationClient.d.ts +5 -3
  18. package/sdk/application/Common/CommonApplicationClient.js +13 -11
  19. package/sdk/application/Common/CommonApplicationModel.d.ts +3 -83
  20. package/sdk/application/Common/CommonApplicationModel.js +2 -58
  21. package/sdk/application/Communication/CommunicationApplicationClient.d.ts +9 -3
  22. package/sdk/application/Communication/CommunicationApplicationClient.js +25 -13
  23. package/sdk/application/Communication/CommunicationApplicationModel.d.ts +1 -34
  24. package/sdk/application/Communication/CommunicationApplicationModel.js +0 -36
  25. package/sdk/application/Configuration/ConfigurationApplicationClient.d.ts +46 -16
  26. package/sdk/application/Configuration/ConfigurationApplicationClient.js +144 -68
  27. package/sdk/application/Configuration/ConfigurationApplicationModel.d.ts +1 -219
  28. package/sdk/application/Configuration/ConfigurationApplicationModel.js +0 -226
  29. package/sdk/application/Content/ContentApplicationClient.d.ts +49 -21
  30. package/sdk/application/Content/ContentApplicationClient.js +159 -80
  31. package/sdk/application/Content/ContentApplicationModel.d.ts +5 -622
  32. package/sdk/application/Content/ContentApplicationModel.js +11 -763
  33. package/sdk/application/FileStorage/FileStorageApplicationClient.d.ts +6 -3
  34. package/sdk/application/FileStorage/FileStorageApplicationClient.js +20 -14
  35. package/sdk/application/FileStorage/FileStorageApplicationModel.d.ts +1 -152
  36. package/sdk/application/FileStorage/FileStorageApplicationModel.js +0 -180
  37. package/sdk/application/Lead/LeadApplicationClient.d.ts +14 -7
  38. package/sdk/application/Lead/LeadApplicationClient.js +50 -31
  39. package/sdk/application/Lead/LeadApplicationModel.d.ts +22 -741
  40. package/sdk/application/Lead/LeadApplicationModel.js +21 -481
  41. package/sdk/application/Logistic/LogisticApplicationClient.d.ts +11 -5
  42. package/sdk/application/Logistic/LogisticApplicationClient.js +41 -20
  43. package/sdk/application/Order/OrderApplicationClient.d.ts +24 -12
  44. package/sdk/application/Order/OrderApplicationClient.js +88 -56
  45. package/sdk/application/Payment/PaymentApplicationClient.d.ts +91 -42
  46. package/sdk/application/Payment/PaymentApplicationClient.js +293 -194
  47. package/sdk/application/Payment/PaymentApplicationModel.d.ts +36 -36
  48. package/sdk/application/Payment/PaymentApplicationModel.js +36 -36
  49. package/sdk/application/PosCart/PosCartApplicationClient.d.ts +59 -32
  50. package/sdk/application/PosCart/PosCartApplicationClient.js +214 -130
  51. package/sdk/application/PosCart/PosCartApplicationModel.d.ts +2 -2
  52. package/sdk/application/PosCart/PosCartApplicationModel.js +2 -2
  53. package/sdk/application/Rewards/RewardsApplicationClient.d.ts +16 -7
  54. package/sdk/application/Rewards/RewardsApplicationClient.js +56 -29
  55. package/sdk/application/Share/ShareApplicationClient.d.ts +15 -7
  56. package/sdk/application/Share/ShareApplicationClient.js +51 -31
  57. package/sdk/application/Share/ShareApplicationModel.d.ts +1 -33
  58. package/sdk/application/Share/ShareApplicationModel.js +0 -38
  59. package/sdk/application/Theme/ThemeApplicationClient.d.ts +9 -4
  60. package/sdk/application/Theme/ThemeApplicationClient.js +35 -18
  61. package/sdk/application/Theme/ThemeApplicationModel.d.ts +982 -312
  62. package/sdk/application/Theme/ThemeApplicationModel.js +621 -284
  63. package/sdk/application/User/UserApplicationClient.d.ts +74 -35
  64. package/sdk/application/User/UserApplicationClient.js +252 -161
  65. package/sdk/application/User/UserApplicationModel.d.ts +3 -401
  66. package/sdk/application/User/UserApplicationModel.js +2 -490
  67. package/sdk/common/AxiosHelper.js +1 -2
  68. package/sdk/common/FDKError.d.ts +3 -0
  69. package/sdk/common/FDKError.js +8 -0
  70. package/sdk/common/utils.d.ts +3 -0
  71. package/sdk/common/utils.js +29 -0
  72. package/sdk/partner/PartnerAPIClient.d.ts +5 -4
  73. package/sdk/partner/PartnerAPIClient.js +7 -4
  74. package/sdk/partner/PartnerClient.d.ts +2 -0
  75. package/sdk/partner/PartnerClient.js +3 -0
  76. package/sdk/partner/Theme/ThemePartnerClient.d.ts +299 -0
  77. package/sdk/partner/Theme/ThemePartnerClient.js +768 -0
  78. package/sdk/partner/Theme/ThemePartnerModel.d.ts +1706 -0
  79. package/sdk/partner/Theme/ThemePartnerModel.js +1409 -0
  80. package/sdk/partner/Theme/ThemePartnerValidator.d.ts +22 -0
  81. package/sdk/partner/Theme/ThemePartnerValidator.js +157 -0
  82. package/sdk/partner/index.d.ts +3 -1
  83. package/sdk/partner/index.js +3 -1
  84. package/sdk/platform/AuditTrail/AuditTrailPlatformClient.d.ts +8 -4
  85. package/sdk/platform/AuditTrail/AuditTrailPlatformClient.js +38 -16
  86. package/sdk/platform/AuditTrail/AuditTrailPlatformModel.d.ts +1 -13
  87. package/sdk/platform/AuditTrail/AuditTrailPlatformModel.js +0 -12
  88. package/sdk/platform/AuditTrail/AuditTrailPlatformValidator.d.ts +10 -0
  89. package/sdk/platform/AuditTrail/AuditTrailPlatformValidator.js +4 -0
  90. package/sdk/platform/Billing/BillingPlatformClient.d.ts +59 -14
  91. package/sdk/platform/Billing/BillingPlatformClient.js +315 -64
  92. package/sdk/platform/Billing/BillingPlatformModel.d.ts +56 -196
  93. package/sdk/platform/Billing/BillingPlatformModel.js +63 -217
  94. package/sdk/platform/Billing/BillingPlatformValidator.d.ts +23 -1
  95. package/sdk/platform/Billing/BillingPlatformValidator.js +31 -0
  96. package/sdk/platform/Cart/CartPlatformApplicationClient.d.ts +124 -63
  97. package/sdk/platform/Cart/CartPlatformApplicationClient.js +431 -265
  98. package/sdk/platform/Cart/CartPlatformModel.d.ts +253 -53
  99. package/sdk/platform/Cart/CartPlatformModel.js +104 -54
  100. package/sdk/platform/Catalog/CatalogPlatformApplicationClient.d.ts +120 -53
  101. package/sdk/platform/Catalog/CatalogPlatformApplicationClient.js +398 -247
  102. package/sdk/platform/Catalog/CatalogPlatformClient.d.ts +155 -78
  103. package/sdk/platform/Catalog/CatalogPlatformClient.js +561 -355
  104. package/sdk/platform/Catalog/CatalogPlatformModel.d.ts +10 -12
  105. package/sdk/platform/Catalog/CatalogPlatformModel.js +10 -12
  106. package/sdk/platform/Catalog/CatalogPlatformValidator.d.ts +30 -0
  107. package/sdk/platform/Catalog/CatalogPlatformValidator.js +13 -0
  108. package/sdk/platform/Common/CommonPlatformClient.d.ts +5 -3
  109. package/sdk/platform/Common/CommonPlatformClient.js +13 -11
  110. package/sdk/platform/Common/CommonPlatformModel.d.ts +39 -64
  111. package/sdk/platform/Common/CommonPlatformModel.js +23 -57
  112. package/sdk/platform/Common/CommonPlatformValidator.d.ts +5 -10
  113. package/sdk/platform/Common/CommonPlatformValidator.js +3 -4
  114. package/sdk/platform/Communication/CommunicationPlatformApplicationClient.d.ts +370 -120
  115. package/sdk/platform/Communication/CommunicationPlatformApplicationClient.js +2328 -888
  116. package/sdk/platform/Communication/CommunicationPlatformApplicationValidator.d.ts +143 -24
  117. package/sdk/platform/Communication/CommunicationPlatformApplicationValidator.js +179 -15
  118. package/sdk/platform/Communication/CommunicationPlatformClient.d.ts +2 -1
  119. package/sdk/platform/Communication/CommunicationPlatformClient.js +6 -5
  120. package/sdk/platform/Communication/CommunicationPlatformModel.d.ts +386 -308
  121. package/sdk/platform/Communication/CommunicationPlatformModel.js +415 -355
  122. package/sdk/platform/CompanyProfile/CompanyProfilePlatformClient.d.ts +38 -13
  123. package/sdk/platform/CompanyProfile/CompanyProfilePlatformClient.js +171 -57
  124. package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.d.ts +53 -1
  125. package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.js +54 -0
  126. package/sdk/platform/CompanyProfile/CompanyProfilePlatformValidator.d.ts +5 -1
  127. package/sdk/platform/CompanyProfile/CompanyProfilePlatformValidator.js +7 -0
  128. package/sdk/platform/Configuration/ConfigurationPlatformApplicationClient.d.ts +96 -29
  129. package/sdk/platform/Configuration/ConfigurationPlatformApplicationClient.js +311 -126
  130. package/sdk/platform/Configuration/ConfigurationPlatformApplicationValidator.d.ts +5 -1
  131. package/sdk/platform/Configuration/ConfigurationPlatformApplicationValidator.js +7 -0
  132. package/sdk/platform/Configuration/ConfigurationPlatformClient.d.ts +36 -18
  133. package/sdk/platform/Configuration/ConfigurationPlatformClient.js +121 -86
  134. package/sdk/platform/Configuration/ConfigurationPlatformModel.d.ts +13 -180
  135. package/sdk/platform/Configuration/ConfigurationPlatformModel.js +5 -113
  136. package/sdk/platform/Content/ContentPlatformApplicationClient.d.ts +162 -70
  137. package/sdk/platform/Content/ContentPlatformApplicationClient.js +528 -309
  138. package/sdk/platform/Content/ContentPlatformModel.d.ts +9 -198
  139. package/sdk/platform/Content/ContentPlatformModel.js +8 -231
  140. package/sdk/platform/Discount/DiscountPlatformClient.d.ts +48 -11
  141. package/sdk/platform/Discount/DiscountPlatformClient.js +142 -48
  142. package/sdk/platform/Discount/DiscountPlatformModel.d.ts +40 -1
  143. package/sdk/platform/Discount/DiscountPlatformModel.js +27 -0
  144. package/sdk/platform/FileStorage/FileStoragePlatformApplicationClient.d.ts +84 -18
  145. package/sdk/platform/FileStorage/FileStoragePlatformApplicationClient.js +486 -53
  146. package/sdk/platform/FileStorage/FileStoragePlatformApplicationValidator.d.ts +71 -7
  147. package/sdk/platform/FileStorage/FileStoragePlatformApplicationValidator.js +81 -5
  148. package/sdk/platform/FileStorage/FileStoragePlatformClient.d.ts +13 -18
  149. package/sdk/platform/FileStorage/FileStoragePlatformClient.js +58 -65
  150. package/sdk/platform/FileStorage/FileStoragePlatformModel.d.ts +198 -71
  151. package/sdk/platform/FileStorage/FileStoragePlatformModel.js +212 -64
  152. package/sdk/platform/FileStorage/FileStoragePlatformValidator.d.ts +18 -10
  153. package/sdk/platform/FileStorage/FileStoragePlatformValidator.js +11 -6
  154. package/sdk/platform/Finance/FinancePlatformClient.d.ts +177 -40
  155. package/sdk/platform/Finance/FinancePlatformClient.js +1028 -132
  156. package/sdk/platform/Finance/FinancePlatformModel.d.ts +670 -22
  157. package/sdk/platform/Finance/FinancePlatformModel.js +809 -23
  158. package/sdk/platform/Finance/FinancePlatformValidator.d.ts +111 -1
  159. package/sdk/platform/Finance/FinancePlatformValidator.js +134 -0
  160. package/sdk/platform/Inventory/InventoryPlatformClient.d.ts +24 -12
  161. package/sdk/platform/Inventory/InventoryPlatformClient.js +94 -52
  162. package/sdk/platform/Lead/LeadPlatformApplicationClient.d.ts +27 -13
  163. package/sdk/platform/Lead/LeadPlatformApplicationClient.js +101 -55
  164. package/sdk/platform/Lead/LeadPlatformClient.d.ts +50 -39
  165. package/sdk/platform/Lead/LeadPlatformClient.js +171 -112
  166. package/sdk/platform/Lead/LeadPlatformModel.d.ts +32 -390
  167. package/sdk/platform/Lead/LeadPlatformModel.js +31 -214
  168. package/sdk/platform/Lead/LeadPlatformValidator.d.ts +33 -33
  169. package/sdk/platform/Lead/LeadPlatformValidator.js +23 -23
  170. package/sdk/platform/OAuthClient.js +6 -2
  171. package/sdk/platform/Order/OrderPlatformApplicationClient.d.ts +4 -2
  172. package/sdk/platform/Order/OrderPlatformApplicationClient.js +12 -10
  173. package/sdk/platform/Order/OrderPlatformClient.d.ts +165 -71
  174. package/sdk/platform/Order/OrderPlatformClient.js +738 -205
  175. package/sdk/platform/Order/OrderPlatformModel.d.ts +261 -3
  176. package/sdk/platform/Order/OrderPlatformModel.js +225 -2
  177. package/sdk/platform/Order/OrderPlatformValidator.d.ts +104 -3
  178. package/sdk/platform/Order/OrderPlatformValidator.js +85 -2
  179. package/sdk/platform/Partner/PartnerPlatformApplicationClient.d.ts +4 -22
  180. package/sdk/platform/Partner/PartnerPlatformApplicationClient.js +12 -159
  181. package/sdk/platform/Partner/PartnerPlatformApplicationValidator.d.ts +1 -30
  182. package/sdk/platform/Partner/PartnerPlatformApplicationValidator.js +0 -26
  183. package/sdk/platform/Partner/PartnerPlatformModel.d.ts +1 -690
  184. package/sdk/platform/Partner/PartnerPlatformModel.js +0 -809
  185. package/sdk/platform/Payment/PaymentPlatformApplicationClient.d.ts +167 -32
  186. package/sdk/platform/Payment/PaymentPlatformApplicationClient.js +793 -145
  187. package/sdk/platform/Payment/PaymentPlatformApplicationValidator.d.ts +91 -1
  188. package/sdk/platform/Payment/PaymentPlatformApplicationValidator.js +91 -0
  189. package/sdk/platform/Payment/PaymentPlatformClient.d.ts +20 -10
  190. package/sdk/platform/Payment/PaymentPlatformClient.js +68 -47
  191. package/sdk/platform/Payment/PaymentPlatformModel.d.ts +549 -7
  192. package/sdk/platform/Payment/PaymentPlatformModel.js +305 -6
  193. package/sdk/platform/PlatformAPIClient.d.ts +3 -3
  194. package/sdk/platform/PlatformAPIClient.js +2 -2
  195. package/sdk/platform/PlatformClient.d.ts +2 -2
  196. package/sdk/platform/PlatformClient.js +4 -4
  197. package/sdk/platform/Rewards/RewardsPlatformApplicationClient.d.ts +28 -12
  198. package/sdk/platform/Rewards/RewardsPlatformApplicationClient.js +90 -53
  199. package/sdk/platform/Rewards/RewardsPlatformModel.d.ts +1 -12
  200. package/sdk/platform/Rewards/RewardsPlatformModel.js +0 -14
  201. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationClient.d.ts +62 -26
  202. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationClient.js +210 -93
  203. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationValidator.d.ts +20 -11
  204. package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationValidator.js +23 -11
  205. package/sdk/platform/Serviceability/ServiceabilityPlatformClient.d.ts +36 -18
  206. package/sdk/platform/Serviceability/ServiceabilityPlatformClient.js +142 -78
  207. package/sdk/platform/Serviceability/ServiceabilityPlatformModel.d.ts +12 -3
  208. package/sdk/platform/Serviceability/ServiceabilityPlatformModel.js +14 -2
  209. package/sdk/platform/Share/SharePlatformApplicationClient.d.ts +10 -26
  210. package/sdk/platform/Share/SharePlatformApplicationClient.js +36 -67
  211. package/sdk/platform/Share/SharePlatformModel.d.ts +4 -4
  212. package/sdk/platform/Share/SharePlatformModel.js +4 -4
  213. package/sdk/platform/Theme/ThemePlatformApplicationClient.d.ts +127 -57
  214. package/sdk/platform/Theme/ThemePlatformApplicationClient.js +564 -189
  215. package/sdk/platform/Theme/ThemePlatformApplicationValidator.d.ts +63 -26
  216. package/sdk/platform/Theme/ThemePlatformApplicationValidator.js +62 -22
  217. package/sdk/platform/Theme/ThemePlatformClient.d.ts +37 -0
  218. package/sdk/platform/Theme/ThemePlatformClient.js +235 -0
  219. package/sdk/platform/Theme/ThemePlatformModel.d.ts +1167 -261
  220. package/sdk/platform/Theme/ThemePlatformModel.js +801 -244
  221. package/sdk/platform/Theme/ThemePlatformValidator.d.ts +32 -0
  222. package/sdk/platform/Theme/ThemePlatformValidator.js +38 -0
  223. package/sdk/platform/User/UserPlatformApplicationClient.d.ts +35 -17
  224. package/sdk/platform/User/UserPlatformApplicationClient.js +132 -73
  225. package/sdk/platform/User/UserPlatformApplicationValidator.d.ts +7 -0
  226. package/sdk/platform/User/UserPlatformApplicationValidator.js +3 -0
  227. package/sdk/platform/User/UserPlatformModel.d.ts +1 -738
  228. package/sdk/platform/User/UserPlatformModel.js +3 -899
  229. package/sdk/platform/Webhook/WebhookPlatformClient.d.ts +120 -7
  230. package/sdk/platform/Webhook/WebhookPlatformClient.js +799 -41
  231. package/sdk/platform/Webhook/WebhookPlatformModel.d.ts +476 -86
  232. package/sdk/platform/Webhook/WebhookPlatformModel.js +388 -89
  233. package/sdk/platform/Webhook/WebhookPlatformValidator.d.ts +96 -9
  234. package/sdk/platform/Webhook/WebhookPlatformValidator.js +117 -5
  235. package/sdk/public/Configuration/ConfigurationPublicClient.d.ts +5 -3
  236. package/sdk/public/Configuration/ConfigurationPublicClient.js +13 -11
  237. package/sdk/public/Configuration/ConfigurationPublicModel.d.ts +3 -106
  238. package/sdk/public/Configuration/ConfigurationPublicModel.js +2 -59
  239. package/sdk/public/Inventory/InventoryPublicClient.d.ts +12 -6
  240. package/sdk/public/Inventory/InventoryPublicClient.js +42 -27
  241. package/sdk/public/Partner/PartnerPublicClient.d.ts +22 -0
  242. package/sdk/public/Partner/PartnerPublicClient.js +110 -0
  243. package/sdk/public/Partner/PartnerPublicModel.d.ts +240 -0
  244. package/sdk/public/Partner/PartnerPublicModel.js +280 -0
  245. package/sdk/public/Partner/PartnerPublicValidator.d.ts +18 -0
  246. package/sdk/public/Partner/PartnerPublicValidator.js +19 -0
  247. package/sdk/public/PublicAPIClient.d.ts +14 -1
  248. package/sdk/public/PublicAPIClient.js +7 -1
  249. package/sdk/public/PublicClient.d.ts +2 -0
  250. package/sdk/public/PublicClient.js +4 -0
  251. package/sdk/public/Webhook/WebhookPublicClient.d.ts +5 -2
  252. package/sdk/public/Webhook/WebhookPublicClient.js +15 -9
  253. package/sdk/public/Webhook/WebhookPublicModel.d.ts +1 -191
  254. package/sdk/public/Webhook/WebhookPublicModel.js +0 -229
  255. package/sdk/public/index.d.ts +1 -0
  256. package/sdk/public/index.js +2 -0
  257. package/sdk/application/ApplicationModels.d.ts +0 -48
  258. package/sdk/application/ApplicationModels.js +0 -38
  259. package/sdk/platform/Partner/PartnerPlatformClient.d.ts +0 -106
  260. package/sdk/platform/Partner/PartnerPlatformClient.js +0 -878
  261. package/sdk/platform/Partner/PartnerPlatformValidator.d.ts +0 -208
  262. package/sdk/platform/Partner/PartnerPlatformValidator.js +0 -169
@@ -12,15 +12,21 @@ class Lead {
12
12
  }
13
13
 
14
14
  /**
15
- * @param {LeadPlatformValidator.CreateHistoryParam} arg - Arg object
15
+ * @param {LeadPlatformValidator.CreatePlatformTicketHistoryParam} arg - Arg object
16
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
16
17
  * @param {import("../PlatformAPIClient").Options} - Options
17
18
  * @returns {Promise<LeadPlatformModel.TicketHistory>} - Success response
18
- * @name createHistory
19
+ * @name createPlatformTicketHistory
19
20
  * @summary: Create history for specific company level ticket
20
- * @description: Create history for specific company level ticket, this history is seen on ticket detail page, this can be comment, log or rating. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/lead/createHistory/).
21
+ * @description: Create history for specific company level ticket, this history is seen on ticket detail page, this can be comment, log or rating. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/lead/createPlatformTicketHistory/).
21
22
  */
22
- async createHistory({ id, body } = {}, { headers } = { headers: false }) {
23
- const { error } = LeadPlatformValidator.createHistory().validate(
23
+ async createPlatformTicketHistory(
24
+ { id, body, requestHeaders } = { requestHeaders: {} },
25
+ { responseHeaders } = { responseHeaders: false }
26
+ ) {
27
+ const {
28
+ error,
29
+ } = LeadPlatformValidator.createPlatformTicketHistory().validate(
24
30
  {
25
31
  id,
26
32
  body,
@@ -32,7 +38,9 @@ class Lead {
32
38
  }
33
39
 
34
40
  // Showing warrnings if extra unknown parameters are found
35
- const { error: warrning } = LeadPlatformValidator.createHistory().validate(
41
+ const {
42
+ error: warrning,
43
+ } = LeadPlatformValidator.createPlatformTicketHistory().validate(
36
44
  {
37
45
  id,
38
46
  body,
@@ -42,7 +50,7 @@ class Lead {
42
50
  if (warrning) {
43
51
  Logger({
44
52
  level: "WARN",
45
- message: `Parameter Validation warrnings for platform > Lead > createHistory \n ${warrning}`,
53
+ message: `Parameter Validation warrnings for platform > Lead > createPlatformTicketHistory \n ${warrning}`,
46
54
  });
47
55
  }
48
56
 
@@ -56,12 +64,12 @@ class Lead {
56
64
  `/service/platform/lead/v1.0/company/${this.config.companyId}/ticket/${id}/history`,
57
65
  query_params,
58
66
  body,
59
- xHeaders,
60
- { headers }
67
+ { ...xHeaders, ...requestHeaders },
68
+ { responseHeaders }
61
69
  );
62
70
 
63
71
  let responseData = response;
64
- if (headers) {
72
+ if (responseHeaders) {
65
73
  responseData = response[0];
66
74
  }
67
75
 
@@ -75,7 +83,7 @@ class Lead {
75
83
  if (res_error) {
76
84
  Logger({
77
85
  level: "WARN",
78
- message: `Response Validation Warnnings for platform > Lead > createHistory \n ${res_error}`,
86
+ message: `Response Validation Warnnings for platform > Lead > createPlatformTicketHistory \n ${res_error}`,
79
87
  });
80
88
  }
81
89
 
@@ -84,13 +92,17 @@ class Lead {
84
92
 
85
93
  /**
86
94
  * @param {LeadPlatformValidator.CreateTicketParam} arg - Arg object
95
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
87
96
  * @param {import("../PlatformAPIClient").Options} - Options
88
97
  * @returns {Promise<LeadPlatformModel.Ticket>} - Success response
89
98
  * @name createTicket
90
99
  * @summary: Creates a company level ticket
91
100
  * @description: Creates a company level ticket - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/lead/createTicket/).
92
101
  */
93
- async createTicket({ body } = {}, { headers } = { headers: false }) {
102
+ async createTicket(
103
+ { body, requestHeaders } = { requestHeaders: {} },
104
+ { responseHeaders } = { responseHeaders: false }
105
+ ) {
94
106
  const { error } = LeadPlatformValidator.createTicket().validate(
95
107
  {
96
108
  body,
@@ -125,12 +137,12 @@ class Lead {
125
137
  `/service/platform/lead/v1.0/company/${this.config.companyId}/ticket`,
126
138
  query_params,
127
139
  body,
128
- xHeaders,
129
- { headers }
140
+ { ...xHeaders, ...requestHeaders },
141
+ { responseHeaders }
130
142
  );
131
143
 
132
144
  let responseData = response;
133
- if (headers) {
145
+ if (responseHeaders) {
134
146
  responseData = response[0];
135
147
  }
136
148
 
@@ -152,15 +164,19 @@ class Lead {
152
164
  }
153
165
 
154
166
  /**
155
- * @param {LeadPlatformValidator.EditTicketParam} arg - Arg object
167
+ * @param {LeadPlatformValidator.EditPlatformTicketParam} arg - Arg object
168
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
156
169
  * @param {import("../PlatformAPIClient").Options} - Options
157
170
  * @returns {Promise<LeadPlatformModel.Ticket>} - Success response
158
- * @name editTicket
171
+ * @name editPlatformTicket
159
172
  * @summary: Edits ticket details of a company level ticket
160
- * @description: Edits ticket details of a company level ticket such as status, priority, category, tags, attachments, assigne & ticket content changes - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/lead/editTicket/).
173
+ * @description: Edits ticket details of a company level ticket such as status, priority, category, tags, attachments, assigne & ticket content changes - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/lead/editPlatformTicket/).
161
174
  */
162
- async editTicket({ id, body } = {}, { headers } = { headers: false }) {
163
- const { error } = LeadPlatformValidator.editTicket().validate(
175
+ async editPlatformTicket(
176
+ { id, body, requestHeaders } = { requestHeaders: {} },
177
+ { responseHeaders } = { responseHeaders: false }
178
+ ) {
179
+ const { error } = LeadPlatformValidator.editPlatformTicket().validate(
164
180
  {
165
181
  id,
166
182
  body,
@@ -172,7 +188,9 @@ class Lead {
172
188
  }
173
189
 
174
190
  // Showing warrnings if extra unknown parameters are found
175
- const { error: warrning } = LeadPlatformValidator.editTicket().validate(
191
+ const {
192
+ error: warrning,
193
+ } = LeadPlatformValidator.editPlatformTicket().validate(
176
194
  {
177
195
  id,
178
196
  body,
@@ -182,7 +200,7 @@ class Lead {
182
200
  if (warrning) {
183
201
  Logger({
184
202
  level: "WARN",
185
- message: `Parameter Validation warrnings for platform > Lead > editTicket \n ${warrning}`,
203
+ message: `Parameter Validation warrnings for platform > Lead > editPlatformTicket \n ${warrning}`,
186
204
  });
187
205
  }
188
206
 
@@ -196,12 +214,12 @@ class Lead {
196
214
  `/service/platform/lead/v1.0/company/${this.config.companyId}/ticket/${id}`,
197
215
  query_params,
198
216
  body,
199
- xHeaders,
200
- { headers }
217
+ { ...xHeaders, ...requestHeaders },
218
+ { responseHeaders }
201
219
  );
202
220
 
203
221
  let responseData = response;
204
- if (headers) {
222
+ if (responseHeaders) {
205
223
  responseData = response[0];
206
224
  }
207
225
 
@@ -215,7 +233,7 @@ class Lead {
215
233
  if (res_error) {
216
234
  Logger({
217
235
  level: "WARN",
218
- message: `Response Validation Warnnings for platform > Lead > editTicket \n ${res_error}`,
236
+ message: `Response Validation Warnnings for platform > Lead > editPlatformTicket \n ${res_error}`,
219
237
  });
220
238
  }
221
239
 
@@ -224,13 +242,17 @@ class Lead {
224
242
 
225
243
  /**
226
244
  * @param {LeadPlatformValidator.GetFeedbacksParam} arg - Arg object
245
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
227
246
  * @param {import("../PlatformAPIClient").Options} - Options
228
247
  * @returns {Promise<LeadPlatformModel.TicketFeedbackList>} - Success response
229
248
  * @name getFeedbacks
230
249
  * @summary: Gets a list of feedback submitted against that ticket
231
250
  * @description: Gets a list of feedback submitted against that ticket - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/lead/getFeedbacks/).
232
251
  */
233
- async getFeedbacks({ id } = {}, { headers } = { headers: false }) {
252
+ async getFeedbacks(
253
+ { id, requestHeaders } = { requestHeaders: {} },
254
+ { responseHeaders } = { responseHeaders: false }
255
+ ) {
234
256
  const { error } = LeadPlatformValidator.getFeedbacks().validate(
235
257
  {
236
258
  id,
@@ -265,12 +287,12 @@ class Lead {
265
287
  `/service/platform/lead/v1.0/company/${this.config.companyId}/ticket/${id}/feedback`,
266
288
  query_params,
267
289
  undefined,
268
- xHeaders,
269
- { headers }
290
+ { ...xHeaders, ...requestHeaders },
291
+ { responseHeaders }
270
292
  );
271
293
 
272
294
  let responseData = response;
273
- if (headers) {
295
+ if (responseHeaders) {
274
296
  responseData = response[0];
275
297
  }
276
298
 
@@ -293,13 +315,17 @@ class Lead {
293
315
 
294
316
  /**
295
317
  * @param {LeadPlatformValidator.GetGeneralConfigParam} arg - Arg object
318
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
296
319
  * @param {import("../PlatformAPIClient").Options} - Options
297
320
  * @returns {Promise<LeadPlatformModel.CloseVideoRoomResponse>} - Success response
298
321
  * @name getGeneralConfig
299
322
  * @summary: Get general support configuration.
300
323
  * @description: Get general support configuration. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/lead/getGeneralConfig/).
301
324
  */
302
- async getGeneralConfig({ headers } = { headers: false }) {
325
+ async getGeneralConfig(
326
+ { requestHeaders } = { requestHeaders: {} },
327
+ { responseHeaders } = { responseHeaders: false }
328
+ ) {
303
329
  const { error } = LeadPlatformValidator.getGeneralConfig().validate(
304
330
  {},
305
331
  { abortEarly: false, allowUnknown: true }
@@ -332,12 +358,12 @@ class Lead {
332
358
  `/service/platform/lead/v1.0/company/${this.config.companyId}/general-config`,
333
359
  query_params,
334
360
  undefined,
335
- xHeaders,
336
- { headers }
361
+ { ...xHeaders, ...requestHeaders },
362
+ { responseHeaders }
337
363
  );
338
364
 
339
365
  let responseData = response;
340
- if (headers) {
366
+ if (responseHeaders) {
341
367
  responseData = response[0];
342
368
  }
343
369
 
@@ -359,15 +385,19 @@ class Lead {
359
385
  }
360
386
 
361
387
  /**
362
- * @param {LeadPlatformValidator.GetTicketParam} arg - Arg object
388
+ * @param {LeadPlatformValidator.GetPlatformTicketParam} arg - Arg object
389
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
363
390
  * @param {import("../PlatformAPIClient").Options} - Options
364
391
  * @returns {Promise<LeadPlatformModel.Ticket>} - Success response
365
- * @name getTicket
392
+ * @name getPlatformTicket
366
393
  * @summary: Retreives ticket details of a company level ticket with ticket ID
367
- * @description: Retreives ticket details of a company level ticket - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/lead/getTicket/).
394
+ * @description: Retreives ticket details of a company level ticket - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/lead/getPlatformTicket/).
368
395
  */
369
- async getTicket({ id } = {}, { headers } = { headers: false }) {
370
- const { error } = LeadPlatformValidator.getTicket().validate(
396
+ async getPlatformTicket(
397
+ { id, requestHeaders } = { requestHeaders: {} },
398
+ { responseHeaders } = { responseHeaders: false }
399
+ ) {
400
+ const { error } = LeadPlatformValidator.getPlatformTicket().validate(
371
401
  {
372
402
  id,
373
403
  },
@@ -378,7 +408,9 @@ class Lead {
378
408
  }
379
409
 
380
410
  // Showing warrnings if extra unknown parameters are found
381
- const { error: warrning } = LeadPlatformValidator.getTicket().validate(
411
+ const {
412
+ error: warrning,
413
+ } = LeadPlatformValidator.getPlatformTicket().validate(
382
414
  {
383
415
  id,
384
416
  },
@@ -387,7 +419,7 @@ class Lead {
387
419
  if (warrning) {
388
420
  Logger({
389
421
  level: "WARN",
390
- message: `Parameter Validation warrnings for platform > Lead > getTicket \n ${warrning}`,
422
+ message: `Parameter Validation warrnings for platform > Lead > getPlatformTicket \n ${warrning}`,
391
423
  });
392
424
  }
393
425
 
@@ -401,12 +433,12 @@ class Lead {
401
433
  `/service/platform/lead/v1.0/company/${this.config.companyId}/ticket/${id}`,
402
434
  query_params,
403
435
  undefined,
404
- xHeaders,
405
- { headers }
436
+ { ...xHeaders, ...requestHeaders },
437
+ { responseHeaders }
406
438
  );
407
439
 
408
440
  let responseData = response;
409
- if (headers) {
441
+ if (responseHeaders) {
410
442
  responseData = response[0];
411
443
  }
412
444
 
@@ -420,7 +452,7 @@ class Lead {
420
452
  if (res_error) {
421
453
  Logger({
422
454
  level: "WARN",
423
- message: `Response Validation Warnnings for platform > Lead > getTicket \n ${res_error}`,
455
+ message: `Response Validation Warnnings for platform > Lead > getPlatformTicket \n ${res_error}`,
424
456
  });
425
457
  }
426
458
 
@@ -428,15 +460,19 @@ class Lead {
428
460
  }
429
461
 
430
462
  /**
431
- * @param {LeadPlatformValidator.GetTicketHistoryParam} arg - Arg object
463
+ * @param {LeadPlatformValidator.GetPlatformTicketHistoryParam} arg - Arg object
464
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
432
465
  * @param {import("../PlatformAPIClient").Options} - Options
433
466
  * @returns {Promise<LeadPlatformModel.TicketHistoryList>} - Success response
434
- * @name getTicketHistory
467
+ * @name getPlatformTicketHistory
435
468
  * @summary: Gets history list for specific company level ticket
436
- * @description: Gets history list for specific company level ticket, this history is seen on ticket detail page, this can be comment, log or rating. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/lead/getTicketHistory/).
469
+ * @description: Gets history list for specific company level ticket, this history is seen on ticket detail page, this can be comment, log or rating. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/lead/getPlatformTicketHistory/).
437
470
  */
438
- async getTicketHistory({ id } = {}, { headers } = { headers: false }) {
439
- const { error } = LeadPlatformValidator.getTicketHistory().validate(
471
+ async getPlatformTicketHistory(
472
+ { id, requestHeaders } = { requestHeaders: {} },
473
+ { responseHeaders } = { responseHeaders: false }
474
+ ) {
475
+ const { error } = LeadPlatformValidator.getPlatformTicketHistory().validate(
440
476
  {
441
477
  id,
442
478
  },
@@ -449,7 +485,7 @@ class Lead {
449
485
  // Showing warrnings if extra unknown parameters are found
450
486
  const {
451
487
  error: warrning,
452
- } = LeadPlatformValidator.getTicketHistory().validate(
488
+ } = LeadPlatformValidator.getPlatformTicketHistory().validate(
453
489
  {
454
490
  id,
455
491
  },
@@ -458,7 +494,7 @@ class Lead {
458
494
  if (warrning) {
459
495
  Logger({
460
496
  level: "WARN",
461
- message: `Parameter Validation warrnings for platform > Lead > getTicketHistory \n ${warrning}`,
497
+ message: `Parameter Validation warrnings for platform > Lead > getPlatformTicketHistory \n ${warrning}`,
462
498
  });
463
499
  }
464
500
 
@@ -472,12 +508,12 @@ class Lead {
472
508
  `/service/platform/lead/v1.0/company/${this.config.companyId}/ticket/${id}/history`,
473
509
  query_params,
474
510
  undefined,
475
- xHeaders,
476
- { headers }
511
+ { ...xHeaders, ...requestHeaders },
512
+ { responseHeaders }
477
513
  );
478
514
 
479
515
  let responseData = response;
480
- if (headers) {
516
+ if (responseHeaders) {
481
517
  responseData = response[0];
482
518
  }
483
519
 
@@ -491,7 +527,7 @@ class Lead {
491
527
  if (res_error) {
492
528
  Logger({
493
529
  level: "WARN",
494
- message: `Response Validation Warnnings for platform > Lead > getTicketHistory \n ${res_error}`,
530
+ message: `Response Validation Warnnings for platform > Lead > getPlatformTicketHistory \n ${res_error}`,
495
531
  });
496
532
  }
497
533
 
@@ -499,18 +535,29 @@ class Lead {
499
535
  }
500
536
 
501
537
  /**
502
- * @param {LeadPlatformValidator.GetTicketsParam} arg - Arg object
538
+ * @param {LeadPlatformValidator.GetPlatformTicketsParam} arg - Arg object
539
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
503
540
  * @param {import("../PlatformAPIClient").Options} - Options
504
541
  * @returns {Promise<LeadPlatformModel.TicketList>} - Success response
505
- * @name getTickets
542
+ * @name getPlatformTickets
506
543
  * @summary: Gets the list of company level tickets and/or ticket filters depending on query params
507
- * @description: Gets the list of company level tickets and/or ticket filters - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/lead/getTickets/).
544
+ * @description: Gets the list of company level tickets and/or ticket filters - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/lead/getPlatformTickets/).
508
545
  */
509
- async getTickets(
510
- { items, filters, q, status, priority, category, pageNo, pageSize } = {},
511
- { headers } = { headers: false }
546
+ async getPlatformTickets(
547
+ {
548
+ items,
549
+ filters,
550
+ q,
551
+ status,
552
+ priority,
553
+ category,
554
+ pageNo,
555
+ pageSize,
556
+ requestHeaders,
557
+ } = { requestHeaders: {} },
558
+ { responseHeaders } = { responseHeaders: false }
512
559
  ) {
513
- const { error } = LeadPlatformValidator.getTickets().validate(
560
+ const { error } = LeadPlatformValidator.getPlatformTickets().validate(
514
561
  {
515
562
  items,
516
563
  filters,
@@ -528,7 +575,9 @@ class Lead {
528
575
  }
529
576
 
530
577
  // Showing warrnings if extra unknown parameters are found
531
- const { error: warrning } = LeadPlatformValidator.getTickets().validate(
578
+ const {
579
+ error: warrning,
580
+ } = LeadPlatformValidator.getPlatformTickets().validate(
532
581
  {
533
582
  items,
534
583
  filters,
@@ -544,7 +593,7 @@ class Lead {
544
593
  if (warrning) {
545
594
  Logger({
546
595
  level: "WARN",
547
- message: `Parameter Validation warrnings for platform > Lead > getTickets \n ${warrning}`,
596
+ message: `Parameter Validation warrnings for platform > Lead > getPlatformTickets \n ${warrning}`,
548
597
  });
549
598
  }
550
599
 
@@ -566,12 +615,12 @@ class Lead {
566
615
  `/service/platform/lead/v1.0/company/${this.config.companyId}/ticket`,
567
616
  query_params,
568
617
  undefined,
569
- xHeaders,
570
- { headers }
618
+ { ...xHeaders, ...requestHeaders },
619
+ { responseHeaders }
571
620
  );
572
621
 
573
622
  let responseData = response;
574
- if (headers) {
623
+ if (responseHeaders) {
575
624
  responseData = response[0];
576
625
  }
577
626
 
@@ -585,7 +634,7 @@ class Lead {
585
634
  if (res_error) {
586
635
  Logger({
587
636
  level: "WARN",
588
- message: `Response Validation Warnnings for platform > Lead > getTickets \n ${res_error}`,
637
+ message: `Response Validation Warnnings for platform > Lead > getPlatformTickets \n ${res_error}`,
589
638
  });
590
639
  }
591
640
 
@@ -608,7 +657,7 @@ class Lead {
608
657
  * @summary: Gets the list of company level tickets and/or ticket filters depending on query params
609
658
  * @description: Gets the list of company level tickets and/or ticket filters
610
659
  */
611
- getTicketsPaginator({
660
+ getPlatformTicketsPaginator({
612
661
  items,
613
662
  filters,
614
663
  q,
@@ -622,7 +671,7 @@ class Lead {
622
671
  const pageId = paginator.nextId;
623
672
  const pageNo = paginator.pageNo;
624
673
  const pageType = "number";
625
- const data = await this.getTickets({
674
+ const data = await this.getPlatformTickets({
626
675
  items: items,
627
676
  filters: filters,
628
677
  q: q,
@@ -643,19 +692,23 @@ class Lead {
643
692
  }
644
693
 
645
694
  /**
646
- * @param {LeadPlatformValidator.GetTokenForVideoRoomParam} arg - Arg object
695
+ * @param {LeadPlatformValidator.GetPlatformVideoParticipantsParam} arg - Arg object
696
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
647
697
  * @param {import("../PlatformAPIClient").Options} - Options
648
- * @returns {Promise<LeadPlatformModel.GetTokenForVideoRoomResponse>} -
649
- * Success response
650
- * @name getTokenForVideoRoom
651
- * @summary: Get Token to join a specific Video Room using it's unqiue name
652
- * @description: Get Token to join a specific Video Room using it's unqiue name, this Token is your ticket to Room and also creates your identity there. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/lead/getTokenForVideoRoom/).
698
+ * @returns {Promise<LeadPlatformModel.GetParticipantsInsideVideoRoomResponse>}
699
+ * - Success response
700
+ *
701
+ * @name getPlatformVideoParticipants
702
+ * @summary: Get participants of a specific Video Room using it's unique name
703
+ * @description: Get participants of a specific Video Room using it's unique name, this can be used to check if people are already there in the room and also to show their names. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/lead/getPlatformVideoParticipants/).
653
704
  */
654
- async getTokenForVideoRoom(
655
- { uniqueName } = {},
656
- { headers } = { headers: false }
705
+ async getPlatformVideoParticipants(
706
+ { uniqueName, requestHeaders } = { requestHeaders: {} },
707
+ { responseHeaders } = { responseHeaders: false }
657
708
  ) {
658
- const { error } = LeadPlatformValidator.getTokenForVideoRoom().validate(
709
+ const {
710
+ error,
711
+ } = LeadPlatformValidator.getPlatformVideoParticipants().validate(
659
712
  {
660
713
  uniqueName,
661
714
  },
@@ -668,7 +721,7 @@ class Lead {
668
721
  // Showing warrnings if extra unknown parameters are found
669
722
  const {
670
723
  error: warrning,
671
- } = LeadPlatformValidator.getTokenForVideoRoom().validate(
724
+ } = LeadPlatformValidator.getPlatformVideoParticipants().validate(
672
725
  {
673
726
  uniqueName,
674
727
  },
@@ -677,7 +730,7 @@ class Lead {
677
730
  if (warrning) {
678
731
  Logger({
679
732
  level: "WARN",
680
- message: `Parameter Validation warrnings for platform > Lead > getTokenForVideoRoom \n ${warrning}`,
733
+ message: `Parameter Validation warrnings for platform > Lead > getPlatformVideoParticipants \n ${warrning}`,
681
734
  });
682
735
  }
683
736
 
@@ -688,21 +741,21 @@ class Lead {
688
741
  const response = await PlatformAPIClient.execute(
689
742
  this.config,
690
743
  "get",
691
- `/service/platform/lead/v1.0/company/${this.config.companyId}/video/room/${uniqueName}/token`,
744
+ `/service/platform/lead/v1.0/company/${this.config.companyId}/video/room/${uniqueName}/participants`,
692
745
  query_params,
693
746
  undefined,
694
- xHeaders,
695
- { headers }
747
+ { ...xHeaders, ...requestHeaders },
748
+ { responseHeaders }
696
749
  );
697
750
 
698
751
  let responseData = response;
699
- if (headers) {
752
+ if (responseHeaders) {
700
753
  responseData = response[0];
701
754
  }
702
755
 
703
756
  const {
704
757
  error: res_error,
705
- } = LeadPlatformModel.GetTokenForVideoRoomResponse().validate(
758
+ } = LeadPlatformModel.GetParticipantsInsideVideoRoomResponse().validate(
706
759
  responseData,
707
760
  { abortEarly: false, allowUnknown: false }
708
761
  );
@@ -710,7 +763,7 @@ class Lead {
710
763
  if (res_error) {
711
764
  Logger({
712
765
  level: "WARN",
713
- message: `Response Validation Warnnings for platform > Lead > getTokenForVideoRoom \n ${res_error}`,
766
+ message: `Response Validation Warnnings for platform > Lead > getPlatformVideoParticipants \n ${res_error}`,
714
767
  });
715
768
  }
716
769
 
@@ -718,20 +771,22 @@ class Lead {
718
771
  }
719
772
 
720
773
  /**
721
- * @param {LeadPlatformValidator.GetVideoParticipantsParam} arg - Arg object
774
+ * @param {LeadPlatformValidator.GetTokenForPlatformVideoRoomParam} arg - Arg object
775
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
722
776
  * @param {import("../PlatformAPIClient").Options} - Options
723
- * @returns {Promise<LeadPlatformModel.GetParticipantsInsideVideoRoomResponse>}
724
- * - Success response
725
- *
726
- * @name getVideoParticipants
727
- * @summary: Get participants of a specific Video Room using it's unique name
728
- * @description: Get participants of a specific Video Room using it's unique name, this can be used to check if people are already there in the room and also to show their names. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/lead/getVideoParticipants/).
777
+ * @returns {Promise<LeadPlatformModel.GetTokenForVideoRoomResponse>} -
778
+ * Success response
779
+ * @name getTokenForPlatformVideoRoom
780
+ * @summary: Get Token to join a specific Video Room using it's unqiue name
781
+ * @description: Get Token to join a specific Video Room using it's unqiue name, this Token is your ticket to Room and also creates your identity there. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/lead/getTokenForPlatformVideoRoom/).
729
782
  */
730
- async getVideoParticipants(
731
- { uniqueName } = {},
732
- { headers } = { headers: false }
783
+ async getTokenForPlatformVideoRoom(
784
+ { uniqueName, requestHeaders } = { requestHeaders: {} },
785
+ { responseHeaders } = { responseHeaders: false }
733
786
  ) {
734
- const { error } = LeadPlatformValidator.getVideoParticipants().validate(
787
+ const {
788
+ error,
789
+ } = LeadPlatformValidator.getTokenForPlatformVideoRoom().validate(
735
790
  {
736
791
  uniqueName,
737
792
  },
@@ -744,7 +799,7 @@ class Lead {
744
799
  // Showing warrnings if extra unknown parameters are found
745
800
  const {
746
801
  error: warrning,
747
- } = LeadPlatformValidator.getVideoParticipants().validate(
802
+ } = LeadPlatformValidator.getTokenForPlatformVideoRoom().validate(
748
803
  {
749
804
  uniqueName,
750
805
  },
@@ -753,7 +808,7 @@ class Lead {
753
808
  if (warrning) {
754
809
  Logger({
755
810
  level: "WARN",
756
- message: `Parameter Validation warrnings for platform > Lead > getVideoParticipants \n ${warrning}`,
811
+ message: `Parameter Validation warrnings for platform > Lead > getTokenForPlatformVideoRoom \n ${warrning}`,
757
812
  });
758
813
  }
759
814
 
@@ -764,21 +819,21 @@ class Lead {
764
819
  const response = await PlatformAPIClient.execute(
765
820
  this.config,
766
821
  "get",
767
- `/service/platform/lead/v1.0/company/${this.config.companyId}/video/room/${uniqueName}/participants`,
822
+ `/service/platform/lead/v1.0/company/${this.config.companyId}/video/room/${uniqueName}/token`,
768
823
  query_params,
769
824
  undefined,
770
- xHeaders,
771
- { headers }
825
+ { ...xHeaders, ...requestHeaders },
826
+ { responseHeaders }
772
827
  );
773
828
 
774
829
  let responseData = response;
775
- if (headers) {
830
+ if (responseHeaders) {
776
831
  responseData = response[0];
777
832
  }
778
833
 
779
834
  const {
780
835
  error: res_error,
781
- } = LeadPlatformModel.GetParticipantsInsideVideoRoomResponse().validate(
836
+ } = LeadPlatformModel.GetTokenForVideoRoomResponse().validate(
782
837
  responseData,
783
838
  { abortEarly: false, allowUnknown: false }
784
839
  );
@@ -786,7 +841,7 @@ class Lead {
786
841
  if (res_error) {
787
842
  Logger({
788
843
  level: "WARN",
789
- message: `Response Validation Warnnings for platform > Lead > getVideoParticipants \n ${res_error}`,
844
+ message: `Response Validation Warnnings for platform > Lead > getTokenForPlatformVideoRoom \n ${res_error}`,
790
845
  });
791
846
  }
792
847
 
@@ -795,13 +850,17 @@ class Lead {
795
850
 
796
851
  /**
797
852
  * @param {LeadPlatformValidator.SubmitFeedbackParam} arg - Arg object
853
+ * @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
798
854
  * @param {import("../PlatformAPIClient").Options} - Options
799
855
  * @returns {Promise<LeadPlatformModel.TicketFeedback>} - Success response
800
856
  * @name submitFeedback
801
857
  * @summary: Submit a response for feeback form against that ticket
802
858
  * @description: Submit a response for feeback form against that ticket - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/lead/submitFeedback/).
803
859
  */
804
- async submitFeedback({ id, body } = {}, { headers } = { headers: false }) {
860
+ async submitFeedback(
861
+ { id, body, requestHeaders } = { requestHeaders: {} },
862
+ { responseHeaders } = { responseHeaders: false }
863
+ ) {
805
864
  const { error } = LeadPlatformValidator.submitFeedback().validate(
806
865
  {
807
866
  id,
@@ -838,12 +897,12 @@ class Lead {
838
897
  `/service/platform/lead/v1.0/company/${this.config.companyId}/ticket/${id}/feedback`,
839
898
  query_params,
840
899
  body,
841
- xHeaders,
842
- { headers }
900
+ { ...xHeaders, ...requestHeaders },
901
+ { responseHeaders }
843
902
  );
844
903
 
845
904
  let responseData = response;
846
- if (headers) {
905
+ if (responseHeaders) {
847
906
  responseData = response[0];
848
907
  }
849
908