@webex/plugin-meetings 3.12.0-next.8 → 3.12.0-task-refactor.1

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 (201) hide show
  1. package/dist/annotation/index.js +5 -14
  2. package/dist/annotation/index.js.map +1 -1
  3. package/dist/breakouts/breakout.js +1 -1
  4. package/dist/breakouts/index.js +1 -1
  5. package/dist/config.js +2 -8
  6. package/dist/config.js.map +1 -1
  7. package/dist/constants.js +6 -29
  8. package/dist/constants.js.map +1 -1
  9. package/dist/hashTree/hashTreeParser.js +29 -1563
  10. package/dist/hashTree/hashTreeParser.js.map +1 -1
  11. package/dist/hashTree/types.js +3 -13
  12. package/dist/hashTree/types.js.map +1 -1
  13. package/dist/index.js +2 -11
  14. package/dist/index.js.map +1 -1
  15. package/dist/interceptors/index.js +0 -7
  16. package/dist/interceptors/index.js.map +1 -1
  17. package/dist/interceptors/locusRouteToken.js +5 -27
  18. package/dist/interceptors/locusRouteToken.js.map +1 -1
  19. package/dist/interpretation/index.js +2 -2
  20. package/dist/interpretation/index.js.map +1 -1
  21. package/dist/interpretation/siLanguage.js +1 -1
  22. package/dist/locus-info/controlsUtils.js +3 -7
  23. package/dist/locus-info/controlsUtils.js.map +1 -1
  24. package/dist/locus-info/index.js +247 -642
  25. package/dist/locus-info/index.js.map +1 -1
  26. package/dist/locus-info/selfUtils.js +0 -1
  27. package/dist/locus-info/selfUtils.js.map +1 -1
  28. package/dist/locus-info/types.js.map +1 -1
  29. package/dist/media/MediaConnectionAwaiter.js +1 -57
  30. package/dist/media/MediaConnectionAwaiter.js.map +1 -1
  31. package/dist/media/properties.js +2 -4
  32. package/dist/media/properties.js.map +1 -1
  33. package/dist/meeting/in-meeting-actions.js +1 -7
  34. package/dist/meeting/in-meeting-actions.js.map +1 -1
  35. package/dist/meeting/index.js +1036 -1481
  36. package/dist/meeting/index.js.map +1 -1
  37. package/dist/meeting/request.js +0 -50
  38. package/dist/meeting/request.js.map +1 -1
  39. package/dist/meeting/request.type.js.map +1 -1
  40. package/dist/meeting/util.js +3 -133
  41. package/dist/meeting/util.js.map +1 -1
  42. package/dist/meetings/index.js +59 -142
  43. package/dist/meetings/index.js.map +1 -1
  44. package/dist/meetings/util.js +7 -11
  45. package/dist/meetings/util.js.map +1 -1
  46. package/dist/member/index.js +0 -10
  47. package/dist/member/index.js.map +1 -1
  48. package/dist/member/util.js +0 -10
  49. package/dist/member/util.js.map +1 -1
  50. package/dist/metrics/constants.js +1 -7
  51. package/dist/metrics/constants.js.map +1 -1
  52. package/dist/multistream/mediaRequestManager.js +60 -9
  53. package/dist/multistream/mediaRequestManager.js.map +1 -1
  54. package/dist/multistream/remoteMediaManager.js +0 -11
  55. package/dist/multistream/remoteMediaManager.js.map +1 -1
  56. package/dist/multistream/sendSlotManager.js +2 -116
  57. package/dist/multistream/sendSlotManager.js.map +1 -1
  58. package/dist/reachability/clusterReachability.js +18 -171
  59. package/dist/reachability/clusterReachability.js.map +1 -1
  60. package/dist/reachability/index.js +11 -21
  61. package/dist/reachability/index.js.map +1 -1
  62. package/dist/reachability/reachabilityPeerConnection.js +1 -1
  63. package/dist/reachability/reachabilityPeerConnection.js.map +1 -1
  64. package/dist/reactions/reactions.type.js.map +1 -1
  65. package/dist/reconnection-manager/index.js +1 -0
  66. package/dist/reconnection-manager/index.js.map +1 -1
  67. package/dist/types/common/browser-detection.d.ts +0 -1
  68. package/dist/types/common/events/events-scope.d.ts +0 -1
  69. package/dist/types/common/events/events.d.ts +0 -1
  70. package/dist/types/config.d.ts +0 -5
  71. package/dist/types/constants.d.ts +1 -24
  72. package/dist/types/hashTree/hashTreeParser.d.ts +11 -260
  73. package/dist/types/hashTree/types.d.ts +0 -20
  74. package/dist/types/index.d.ts +0 -1
  75. package/dist/types/interceptors/index.d.ts +1 -2
  76. package/dist/types/interceptors/locusRouteToken.d.ts +0 -2
  77. package/dist/types/locus-info/index.d.ts +47 -68
  78. package/dist/types/locus-info/types.d.ts +12 -28
  79. package/dist/types/media/MediaConnectionAwaiter.d.ts +1 -10
  80. package/dist/types/media/properties.d.ts +1 -2
  81. package/dist/types/meeting/in-meeting-actions.d.ts +0 -6
  82. package/dist/types/meeting/index.d.ts +7 -86
  83. package/dist/types/meeting/request.d.ts +1 -16
  84. package/dist/types/meeting/request.type.d.ts +0 -5
  85. package/dist/types/meeting/util.d.ts +0 -31
  86. package/dist/types/meeting-info/util.d.ts +0 -1
  87. package/dist/types/meeting-info/utilv2.d.ts +0 -1
  88. package/dist/types/meetings/index.d.ts +2 -4
  89. package/dist/types/member/index.d.ts +0 -1
  90. package/dist/types/member/types.d.ts +4 -4
  91. package/dist/types/member/util.d.ts +0 -5
  92. package/dist/types/metrics/constants.d.ts +0 -6
  93. package/dist/types/multistream/mediaRequestManager.d.ts +23 -0
  94. package/dist/types/multistream/sendSlotManager.d.ts +1 -23
  95. package/dist/types/reachability/clusterReachability.d.ts +3 -30
  96. package/dist/types/reactions/reactions.type.d.ts +0 -1
  97. package/dist/types/recording-controller/util.d.ts +5 -5
  98. package/dist/types/roap/index.d.ts +1 -1
  99. package/dist/webinar/index.js +163 -438
  100. package/dist/webinar/index.js.map +1 -1
  101. package/package.json +24 -26
  102. package/src/annotation/index.ts +7 -27
  103. package/src/config.ts +0 -5
  104. package/src/constants.ts +1 -30
  105. package/src/hashTree/hashTreeParser.ts +25 -1523
  106. package/src/hashTree/types.ts +1 -24
  107. package/src/index.ts +1 -8
  108. package/src/interceptors/index.ts +1 -2
  109. package/src/interceptors/locusRouteToken.ts +5 -22
  110. package/src/interpretation/index.ts +2 -2
  111. package/src/locus-info/controlsUtils.ts +0 -17
  112. package/src/locus-info/index.ts +213 -707
  113. package/src/locus-info/selfUtils.ts +0 -1
  114. package/src/locus-info/types.ts +12 -27
  115. package/src/media/MediaConnectionAwaiter.ts +1 -41
  116. package/src/media/properties.ts +1 -3
  117. package/src/meeting/in-meeting-actions.ts +0 -12
  118. package/src/meeting/index.ts +84 -461
  119. package/src/meeting/request.ts +0 -42
  120. package/src/meeting/request.type.ts +0 -6
  121. package/src/meeting/util.ts +2 -160
  122. package/src/meetings/index.ts +60 -180
  123. package/src/meetings/util.ts +9 -10
  124. package/src/member/index.ts +0 -10
  125. package/src/member/util.ts +0 -12
  126. package/src/metrics/constants.ts +0 -7
  127. package/src/multistream/mediaRequestManager.ts +54 -4
  128. package/src/multistream/remoteMediaManager.ts +0 -13
  129. package/src/multistream/sendSlotManager.ts +3 -97
  130. package/src/reachability/clusterReachability.ts +27 -153
  131. package/src/reachability/index.ts +1 -15
  132. package/src/reachability/reachabilityPeerConnection.ts +1 -3
  133. package/src/reactions/reactions.type.ts +0 -1
  134. package/src/reconnection-manager/index.ts +1 -0
  135. package/src/webinar/index.ts +6 -265
  136. package/test/unit/spec/annotation/index.ts +7 -69
  137. package/test/unit/spec/interceptors/locusRouteToken.ts +0 -44
  138. package/test/unit/spec/locus-info/controlsUtils.js +1 -56
  139. package/test/unit/spec/locus-info/index.js +90 -1457
  140. package/test/unit/spec/media/MediaConnectionAwaiter.ts +1 -41
  141. package/test/unit/spec/media/properties.ts +3 -12
  142. package/test/unit/spec/meeting/in-meeting-actions.ts +2 -8
  143. package/test/unit/spec/meeting/index.js +128 -981
  144. package/test/unit/spec/meeting/request.js +0 -70
  145. package/test/unit/spec/meeting/utils.js +26 -438
  146. package/test/unit/spec/meetings/index.js +33 -845
  147. package/test/unit/spec/meetings/utils.js +1 -51
  148. package/test/unit/spec/member/index.js +4 -28
  149. package/test/unit/spec/member/util.js +27 -65
  150. package/test/unit/spec/multistream/mediaRequestManager.ts +85 -2
  151. package/test/unit/spec/multistream/remoteMediaManager.ts +0 -30
  152. package/test/unit/spec/multistream/sendSlotManager.ts +36 -135
  153. package/test/unit/spec/reachability/clusterReachability.ts +1 -125
  154. package/test/unit/spec/reachability/index.ts +3 -26
  155. package/test/unit/spec/reconnection-manager/index.js +8 -4
  156. package/test/unit/spec/webinar/index.ts +37 -534
  157. package/dist/aiEnableRequest/index.js +0 -184
  158. package/dist/aiEnableRequest/index.js.map +0 -1
  159. package/dist/aiEnableRequest/utils.js +0 -36
  160. package/dist/aiEnableRequest/utils.js.map +0 -1
  161. package/dist/hashTree/constants.js +0 -22
  162. package/dist/hashTree/constants.js.map +0 -1
  163. package/dist/hashTree/hashTree.js +0 -533
  164. package/dist/hashTree/hashTree.js.map +0 -1
  165. package/dist/hashTree/utils.js +0 -69
  166. package/dist/hashTree/utils.js.map +0 -1
  167. package/dist/interceptors/constant.js +0 -12
  168. package/dist/interceptors/constant.js.map +0 -1
  169. package/dist/interceptors/dataChannelAuthToken.js +0 -290
  170. package/dist/interceptors/dataChannelAuthToken.js.map +0 -1
  171. package/dist/interceptors/utils.js +0 -27
  172. package/dist/interceptors/utils.js.map +0 -1
  173. package/dist/types/aiEnableRequest/index.d.ts +0 -5
  174. package/dist/types/aiEnableRequest/utils.d.ts +0 -2
  175. package/dist/types/hashTree/constants.d.ts +0 -9
  176. package/dist/types/hashTree/hashTree.d.ts +0 -136
  177. package/dist/types/hashTree/utils.d.ts +0 -22
  178. package/dist/types/interceptors/constant.d.ts +0 -5
  179. package/dist/types/interceptors/dataChannelAuthToken.d.ts +0 -43
  180. package/dist/types/interceptors/utils.d.ts +0 -1
  181. package/dist/types/webinar/utils.d.ts +0 -6
  182. package/dist/webinar/utils.js +0 -25
  183. package/dist/webinar/utils.js.map +0 -1
  184. package/src/aiEnableRequest/README.md +0 -84
  185. package/src/aiEnableRequest/index.ts +0 -170
  186. package/src/aiEnableRequest/utils.ts +0 -25
  187. package/src/hashTree/constants.ts +0 -10
  188. package/src/hashTree/hashTree.ts +0 -480
  189. package/src/hashTree/utils.ts +0 -62
  190. package/src/interceptors/constant.ts +0 -6
  191. package/src/interceptors/dataChannelAuthToken.ts +0 -170
  192. package/src/interceptors/utils.ts +0 -16
  193. package/src/webinar/utils.ts +0 -16
  194. package/test/unit/spec/aiEnableRequest/index.ts +0 -981
  195. package/test/unit/spec/aiEnableRequest/utils.ts +0 -130
  196. package/test/unit/spec/hashTree/hashTree.ts +0 -721
  197. package/test/unit/spec/hashTree/hashTreeParser.ts +0 -3670
  198. package/test/unit/spec/hashTree/utils.ts +0 -140
  199. package/test/unit/spec/interceptors/dataChannelAuthToken.ts +0 -210
  200. package/test/unit/spec/interceptors/utils.ts +0 -75
  201. package/test/unit/spec/webinar/utils.ts +0 -39
@@ -6,18 +6,15 @@ _Object$defineProperty(exports, "__esModule", {
6
6
  value: true
7
7
  });
8
8
  exports.default = void 0;
9
- var _promise = _interopRequireDefault(require("@babel/runtime-corejs2/core-js/promise"));
10
9
  var _regenerator = _interopRequireDefault(require("@babel/runtime-corejs2/regenerator"));
11
10
  var _defineProperty2 = _interopRequireDefault(require("@babel/runtime-corejs2/helpers/defineProperty"));
12
11
  var _asyncToGenerator2 = _interopRequireDefault(require("@babel/runtime-corejs2/helpers/asyncToGenerator"));
13
12
  var _webexCore = require("@webex/webex-core");
14
13
  var _uuid = _interopRequireDefault(require("uuid"));
15
14
  var _lodash = require("lodash");
16
- var _internalPluginLlm = require("@webex/internal-plugin-llm");
17
15
  var _constants = require("../constants");
18
16
  var _collection = _interopRequireDefault(require("./collection"));
19
17
  var _loggerProxy = _interopRequireDefault(require("../common/logs/logger-proxy"));
20
- var _utils = require("./utils");
21
18
  /*!
22
19
  * Copyright (c) 2015-2023 Cisco Systems, Inc. See LICENSE file.
23
20
  */
@@ -45,13 +42,6 @@ var Webinar = _webexCore.WebexPlugin.extend({
45
42
  // practice session enabled
46
43
  meetingId: 'string'
47
44
  },
48
- /**
49
- * Calls this to clean up listeners
50
- * @returns {void}
51
- */
52
- cleanUp: function cleanUp() {
53
- this.cleanupPSDataChannel();
54
- },
55
45
  /**
56
46
  * Update the current locus url of the webinar
57
47
  * @param {string} locusUrl
@@ -115,7 +105,10 @@ var Webinar = _webexCore.WebexPlugin.extend({
115
105
  // while panelist still need subscribe native mode so trigger force update here
116
106
  meeting === null || meeting === void 0 ? void 0 : (_meeting$locusInfo = meeting.locusInfo) === null || _meeting$locusInfo === void 0 ? void 0 : _meeting$locusInfo.updateMediaShares(meeting === null || meeting === void 0 ? void 0 : (_meeting$locusInfo2 = meeting.locusInfo) === null || _meeting$locusInfo2 === void 0 ? void 0 : _meeting$locusInfo2.mediaShares, true);
117
107
  }
118
- this.updatePSDataChannel();
108
+ if (this.practiceSessionEnabled) {
109
+ // may need change data channel in practice session
110
+ meeting === null || meeting === void 0 ? void 0 : meeting.updateLLMConnection();
111
+ }
119
112
  },
120
113
  /**
121
114
  * should join practice session data channel or not
@@ -124,217 +117,6 @@ var Webinar = _webexCore.WebexPlugin.extend({
124
117
  isJoinPracticeSessionDataChannel: function isJoinPracticeSessionDataChannel() {
125
118
  return this.selfIsPanelist && this.practiceSessionEnabled;
126
119
  },
127
- /**
128
- * Disconnects the practice session data channel and removes its relay listener.
129
- * @returns {Promise<void>}
130
- */
131
- cleanupPSDataChannel: function cleanupPSDataChannel() {
132
- var _this = this;
133
- return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee() {
134
- var meeting;
135
- return _regenerator.default.wrap(function (_context) {
136
- while (1) switch (_context.prev = _context.next) {
137
- case 0:
138
- if (_this._pendingOnlineListener) {
139
- // @ts-ignore - Fix type
140
- _this.webex.internal.llm.off('online', _this._pendingOnlineListener);
141
- _this._pendingOnlineListener = null;
142
- }
143
- meeting = _this.webex.meetings.getMeetingByType(_constants._ID_, _this.meetingId); // @ts-ignore - Fix type
144
- _context.next = 1;
145
- return _this.webex.internal.llm.disconnectLLM({
146
- code: 3050,
147
- reason: 'done (permanent)'
148
- }, _constants.LLM_PRACTICE_SESSION);
149
- case 1:
150
- // @ts-ignore - Fix type
151
- _this.webex.internal.llm.off("event:relay.event:".concat(_constants.LLM_PRACTICE_SESSION), meeting === null || meeting === void 0 ? void 0 : meeting.processRelayEvent);
152
- case 2:
153
- case "end":
154
- return _context.stop();
155
- }
156
- }, _callee);
157
- }))();
158
- },
159
- /**
160
- * Ensures practice-session token exists before registering the practice LLM channel.
161
- * @param {object} meeting
162
- * @returns {Promise<string|undefined>}
163
- */
164
- ensurePracticeSessionDatachannelToken: function ensurePracticeSessionDatachannelToken(meeting) {
165
- var _this2 = this;
166
- return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee2() {
167
- var isDataChannelTokenEnabled, cachedToken, _refreshResponse$body, refreshResponse, _ref2, datachannelToken, dataChannelTokenType, _t;
168
- return _regenerator.default.wrap(function (_context2) {
169
- while (1) switch (_context2.prev = _context2.next) {
170
- case 0:
171
- _context2.next = 1;
172
- return _this2.webex.internal.llm.isDataChannelTokenEnabled();
173
- case 1:
174
- isDataChannelTokenEnabled = _context2.sent;
175
- if (isDataChannelTokenEnabled) {
176
- _context2.next = 2;
177
- break;
178
- }
179
- return _context2.abrupt("return", undefined);
180
- case 2:
181
- // @ts-ignore
182
- cachedToken = _this2.webex.internal.llm.getDatachannelToken(_internalPluginLlm.DataChannelTokenType.PracticeSession);
183
- if (!cachedToken) {
184
- _context2.next = 3;
185
- break;
186
- }
187
- return _context2.abrupt("return", cachedToken);
188
- case 3:
189
- _context2.prev = 3;
190
- _context2.next = 4;
191
- return meeting.refreshDataChannelToken();
192
- case 4:
193
- refreshResponse = _context2.sent;
194
- _ref2 = (_refreshResponse$body = refreshResponse === null || refreshResponse === void 0 ? void 0 : refreshResponse.body) !== null && _refreshResponse$body !== void 0 ? _refreshResponse$body : {}, datachannelToken = _ref2.datachannelToken, dataChannelTokenType = _ref2.dataChannelTokenType;
195
- if (datachannelToken) {
196
- _context2.next = 5;
197
- break;
198
- }
199
- return _context2.abrupt("return", undefined);
200
- case 5:
201
- // @ts-ignore
202
- _this2.webex.internal.llm.setDatachannelToken(datachannelToken, dataChannelTokenType || _internalPluginLlm.DataChannelTokenType.PracticeSession);
203
- return _context2.abrupt("return", datachannelToken);
204
- case 6:
205
- _context2.prev = 6;
206
- _t = _context2["catch"](3);
207
- _loggerProxy.default.logger.warn("Webinar:index#ensurePracticeSessionDatachannelToken --> failed to proactively refresh practice-session token: ".concat((_t === null || _t === void 0 ? void 0 : _t.message) || String(_t)));
208
- return _context2.abrupt("return", undefined);
209
- case 7:
210
- case "end":
211
- return _context2.stop();
212
- }
213
- }, _callee2, null, [[3, 6]]);
214
- }))();
215
- },
216
- /**
217
- * Connects to low latency mercury and reconnects if the address has changed
218
- * It will also disconnect if called when the meeting has ended
219
- * @returns {Promise}
220
- */
221
- updatePSDataChannel: function updatePSDataChannel() {
222
- var _this3 = this;
223
- return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee3() {
224
- var invocationSequence, meeting, isPracticeSession, _ref3, _ref3$url, url, _ref3$info, _ref3$info2, _ref3$info2$practiceS, practiceSessionDatachannelUrl, practiceSessionDatachannelToken, isCaptionBoxOn, _onDefaultSessionConnected, refreshedPracticeSessionToken, latestPracticeSessionDatachannelUrl, isStillPracticeSession;
225
- return _regenerator.default.wrap(function (_context3) {
226
- while (1) switch (_context3.prev = _context3.next) {
227
- case 0:
228
- _this3._updatePSDataChannelSequence = (_this3._updatePSDataChannelSequence || 0) + 1;
229
- invocationSequence = _this3._updatePSDataChannelSequence;
230
- meeting = _this3.webex.meetings.getMeetingByType(_constants._ID_, _this3.meetingId);
231
- isPracticeSession = (meeting === null || meeting === void 0 ? void 0 : meeting.isJoined()) && _this3.isJoinPracticeSessionDataChannel();
232
- if (isPracticeSession) {
233
- _context3.next = 2;
234
- break;
235
- }
236
- _context3.next = 1;
237
- return _this3.cleanupPSDataChannel();
238
- case 1:
239
- return _context3.abrupt("return", undefined);
240
- case 2:
241
- // @ts-ignore - Fix type
242
- _ref3 = (meeting === null || meeting === void 0 ? void 0 : meeting.locusInfo) || {}, _ref3$url = _ref3.url, url = _ref3$url === void 0 ? undefined : _ref3$url, _ref3$info = _ref3.info, _ref3$info2 = _ref3$info === void 0 ? {} : _ref3$info, _ref3$info2$practiceS = _ref3$info2.practiceSessionDatachannelUrl, practiceSessionDatachannelUrl = _ref3$info2$practiceS === void 0 ? undefined : _ref3$info2$practiceS; // @ts-ignore
243
- practiceSessionDatachannelToken = _this3.webex.internal.llm.getDatachannelToken(_internalPluginLlm.DataChannelTokenType.PracticeSession);
244
- isCaptionBoxOn = _this3.webex.internal.voicea.getIsCaptionBoxOn();
245
- if (practiceSessionDatachannelUrl) {
246
- _context3.next = 3;
247
- break;
248
- }
249
- return _context3.abrupt("return", undefined);
250
- case 3:
251
- if (!_this3.webex.internal.llm.isConnected(_constants.LLM_PRACTICE_SESSION)) {
252
- _context3.next = 5;
253
- break;
254
- }
255
- if (!(
256
- // @ts-ignore - Fix type
257
- url === _this3.webex.internal.llm.getLocusUrl(_constants.LLM_PRACTICE_SESSION) &&
258
- // @ts-ignore - Fix type
259
- practiceSessionDatachannelUrl === _this3.webex.internal.llm.getDatachannelUrl(_constants.LLM_PRACTICE_SESSION))) {
260
- _context3.next = 4;
261
- break;
262
- }
263
- return _context3.abrupt("return", undefined);
264
- case 4:
265
- _context3.next = 5;
266
- return _this3.cleanupPSDataChannel();
267
- case 5:
268
- // Ensure the default session data channel is connected before connecting the practice session.
269
- // Subscribe before checking isConnected() to avoid a race where the 'online' event fires
270
- // between the check and the subscription — Mercury does not replay missed events.
271
- if (!_this3._pendingOnlineListener) {
272
- _onDefaultSessionConnected = function onDefaultSessionConnected() {
273
- _this3._pendingOnlineListener = null;
274
- // @ts-ignore - Fix type
275
- _this3.webex.internal.llm.off('online', _onDefaultSessionConnected);
276
- _this3.updatePSDataChannel();
277
- };
278
- _this3._pendingOnlineListener = _onDefaultSessionConnected;
279
- // @ts-ignore - Fix type
280
- _this3.webex.internal.llm.on('online', _onDefaultSessionConnected);
281
- }
282
-
283
- // @ts-ignore - Fix type
284
- if (_this3.webex.internal.llm.isConnected()) {
285
- _context3.next = 6;
286
- break;
287
- }
288
- _loggerProxy.default.logger.info('Webinar:index#updatePSDataChannel --> default session not yet connected, deferring practice session connect.');
289
- return _context3.abrupt("return", undefined);
290
- case 6:
291
- // Default session is already connected — cancel the pending listener and proceed
292
- if (_this3._pendingOnlineListener) {
293
- // @ts-ignore - Fix type
294
- _this3.webex.internal.llm.off('online', _this3._pendingOnlineListener);
295
- _this3._pendingOnlineListener = null;
296
- }
297
- _context3.next = 7;
298
- return _this3.ensurePracticeSessionDatachannelToken(meeting);
299
- case 7:
300
- refreshedPracticeSessionToken = _context3.sent;
301
- latestPracticeSessionDatachannelUrl = (0, _lodash.get)(meeting, 'locusInfo.info.practiceSessionDatachannelUrl');
302
- isStillPracticeSession = (meeting === null || meeting === void 0 ? void 0 : meeting.isJoined()) && _this3.isJoinPracticeSessionDataChannel(); // Skip stale invocations after async refresh to avoid reconnecting a session
303
- // that was already updated/cleaned by a newer state transition.
304
- if (!(invocationSequence !== _this3._updatePSDataChannelSequence || !isStillPracticeSession || !latestPracticeSessionDatachannelUrl || latestPracticeSessionDatachannelUrl !== practiceSessionDatachannelUrl)) {
305
- _context3.next = 8;
306
- break;
307
- }
308
- return _context3.abrupt("return", undefined);
309
- case 8:
310
- if (refreshedPracticeSessionToken) {
311
- practiceSessionDatachannelToken = refreshedPracticeSessionToken;
312
- }
313
-
314
- // @ts-ignore - Fix type
315
- return _context3.abrupt("return", _this3.webex.internal.llm.registerAndConnect(url, practiceSessionDatachannelUrl, practiceSessionDatachannelToken, _constants.LLM_PRACTICE_SESSION).then(function (registerAndConnectResult) {
316
- var _this3$webex$internal, _this3$webex$internal2;
317
- // @ts-ignore - Fix type
318
- _this3.webex.internal.llm.off("event:relay.event:".concat(_constants.LLM_PRACTICE_SESSION), meeting === null || meeting === void 0 ? void 0 : meeting.processRelayEvent);
319
- // @ts-ignore - Fix type
320
- _this3.webex.internal.llm.on("event:relay.event:".concat(_constants.LLM_PRACTICE_SESSION), meeting === null || meeting === void 0 ? void 0 : meeting.processRelayEvent);
321
- // @ts-ignore - Fix type
322
- (_this3$webex$internal = _this3.webex.internal.voicea) === null || _this3$webex$internal === void 0 ? void 0 : (_this3$webex$internal2 = _this3$webex$internal.announce) === null || _this3$webex$internal2 === void 0 ? void 0 : _this3$webex$internal2.call(_this3$webex$internal);
323
- if (isCaptionBoxOn) {
324
- _this3.webex.internal.voicea.updateSubchannelSubscriptions({
325
- subscribe: ['transcription']
326
- });
327
- }
328
- _loggerProxy.default.logger.info("Webinar:index#updatePSDataChannel --> enabled to receive relay events for default session for ".concat(_constants.LLM_PRACTICE_SESSION, "!"));
329
- return _promise.default.resolve(registerAndConnectResult);
330
- }));
331
- case 9:
332
- case "end":
333
- return _context3.stop();
334
- }
335
- }, _callee3);
336
- }))();
337
- },
338
120
  /**
339
121
  * start or stop practice session for webinar
340
122
  * @param {boolean} enabled
@@ -361,7 +143,6 @@ var Webinar = _webexCore.WebexPlugin.extend({
361
143
  */
362
144
  updatePracticeSessionStatus: function updatePracticeSessionStatus(payload) {
363
145
  this.set('practiceSessionEnabled', !!(payload !== null && payload !== void 0 && payload.enabled));
364
- this.updatePSDataChannel().then(function () {});
365
146
  },
366
147
  /**
367
148
  * start webcast mode for webinar
@@ -370,33 +151,33 @@ var Webinar = _webexCore.WebexPlugin.extend({
370
151
  * @returns {Promise}
371
152
  */
372
153
  startWebcast: function startWebcast(meeting, layout) {
373
- var _this4 = this;
374
- return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee4() {
375
- var _t2, _t3, _t4, _t5, _t6, _t7, _t8, _t9;
376
- return _regenerator.default.wrap(function (_context4) {
377
- while (1) switch (_context4.prev = _context4.next) {
154
+ var _this = this;
155
+ return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee() {
156
+ var _t, _t2, _t3, _t4, _t5, _t6, _t7, _t8;
157
+ return _regenerator.default.wrap(function (_context) {
158
+ while (1) switch (_context.prev = _context.next) {
378
159
  case 0:
379
160
  if (meeting) {
380
- _context4.next = 1;
161
+ _context.next = 1;
381
162
  break;
382
163
  }
383
164
  _loggerProxy.default.logger.error("Meeting:webinar#startWebcast failed --> meeting parameter : ".concat(meeting));
384
165
  throw new Error('Meeting parameter does not meet expectations');
385
166
  case 1:
386
- _t2 = _this4;
387
- _t3 = _constants.HTTP_VERBS.PUT;
388
- _t4 = "".concat(_this4.webcastInstanceUrl, "/streaming");
389
- _t5 = _defineProperty2.default;
390
- _context4.next = 2;
391
- return _this4.webex.credentials.getUserToken();
167
+ _t = _this;
168
+ _t2 = _constants.HTTP_VERBS.PUT;
169
+ _t3 = "".concat(_this.webcastInstanceUrl, "/streaming");
170
+ _t4 = _defineProperty2.default;
171
+ _context.next = 2;
172
+ return _this.webex.credentials.getUserToken();
392
173
  case 2:
393
- _t6 = _context4.sent;
394
- _t7 = "".concat(_webexCore.config.trackingIdPrefix, "_").concat(_uuid.default.v4().toString());
395
- _t8 = _t5({
396
- authorization: _t6,
397
- trackingId: _t7
174
+ _t5 = _context.sent;
175
+ _t6 = "".concat(_webexCore.config.trackingIdPrefix, "_").concat(_uuid.default.v4().toString());
176
+ _t7 = _t4({
177
+ authorization: _t5,
178
+ trackingId: _t6
398
179
  }, _constants.HEADERS.CONTENT_TYPE, _constants.HEADERS.CONTENT_TYPE_VALUE.APPLICATION_JSON);
399
- _t9 = {
180
+ _t8 = {
400
181
  action: 'start',
401
182
  meetingInfo: {
402
183
  locusId: meeting.locusId,
@@ -404,20 +185,20 @@ var Webinar = _webexCore.WebexPlugin.extend({
404
185
  },
405
186
  layout: layout
406
187
  };
407
- return _context4.abrupt("return", _t2.request.call(_t2, {
408
- method: _t3,
409
- uri: _t4,
410
- headers: _t8,
411
- body: _t9
188
+ return _context.abrupt("return", _t.request.call(_t, {
189
+ method: _t2,
190
+ uri: _t3,
191
+ headers: _t7,
192
+ body: _t8
412
193
  }).catch(function (error) {
413
194
  _loggerProxy.default.logger.error('Meeting:webinar#startWebcast failed', error);
414
195
  throw error;
415
196
  }));
416
197
  case 3:
417
198
  case "end":
418
- return _context4.stop();
199
+ return _context.stop();
419
200
  }
420
- }, _callee4);
201
+ }, _callee);
421
202
  }))();
422
203
  },
423
204
  /**
@@ -425,42 +206,42 @@ var Webinar = _webexCore.WebexPlugin.extend({
425
206
  * @returns {Promise}
426
207
  */
427
208
  stopWebcast: function stopWebcast() {
428
- var _this5 = this;
429
- return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee5() {
430
- var _t0, _t1, _t10, _t11, _t12, _t13, _t14, _t15;
431
- return _regenerator.default.wrap(function (_context5) {
432
- while (1) switch (_context5.prev = _context5.next) {
209
+ var _this2 = this;
210
+ return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee2() {
211
+ var _t9, _t0, _t1, _t10, _t11, _t12, _t13, _t14;
212
+ return _regenerator.default.wrap(function (_context2) {
213
+ while (1) switch (_context2.prev = _context2.next) {
433
214
  case 0:
434
- _t0 = _this5;
435
- _t1 = _constants.HTTP_VERBS.PUT;
436
- _t10 = "".concat(_this5.webcastInstanceUrl, "/streaming");
437
- _t11 = _defineProperty2.default;
438
- _context5.next = 1;
439
- return _this5.webex.credentials.getUserToken();
215
+ _t9 = _this2;
216
+ _t0 = _constants.HTTP_VERBS.PUT;
217
+ _t1 = "".concat(_this2.webcastInstanceUrl, "/streaming");
218
+ _t10 = _defineProperty2.default;
219
+ _context2.next = 1;
220
+ return _this2.webex.credentials.getUserToken();
440
221
  case 1:
441
- _t12 = _context5.sent;
442
- _t13 = "".concat(_webexCore.config.trackingIdPrefix, "_").concat(_uuid.default.v4().toString());
443
- _t14 = _t11({
444
- authorization: _t12,
445
- trackingId: _t13
222
+ _t11 = _context2.sent;
223
+ _t12 = "".concat(_webexCore.config.trackingIdPrefix, "_").concat(_uuid.default.v4().toString());
224
+ _t13 = _t10({
225
+ authorization: _t11,
226
+ trackingId: _t12
446
227
  }, _constants.HEADERS.CONTENT_TYPE, _constants.HEADERS.CONTENT_TYPE_VALUE.APPLICATION_JSON);
447
- _t15 = {
228
+ _t14 = {
448
229
  action: 'stop'
449
230
  };
450
- return _context5.abrupt("return", _t0.request.call(_t0, {
451
- method: _t1,
452
- uri: _t10,
453
- headers: _t14,
454
- body: _t15
231
+ return _context2.abrupt("return", _t9.request.call(_t9, {
232
+ method: _t0,
233
+ uri: _t1,
234
+ headers: _t13,
235
+ body: _t14
455
236
  }).catch(function (error) {
456
237
  _loggerProxy.default.logger.error('Meeting:webinar#stopWebcast failed', error);
457
238
  throw error;
458
239
  }));
459
240
  case 2:
460
241
  case "end":
461
- return _context5.stop();
242
+ return _context2.stop();
462
243
  }
463
- }, _callee5);
244
+ }, _callee2);
464
245
  }))();
465
246
  },
466
247
  /**
@@ -468,37 +249,37 @@ var Webinar = _webexCore.WebexPlugin.extend({
468
249
  * @returns {Promise}
469
250
  */
470
251
  queryWebcastLayout: function queryWebcastLayout() {
471
- var _this6 = this;
472
- return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee6() {
473
- var _t16, _t17, _t18, _t19, _t20, _t21;
474
- return _regenerator.default.wrap(function (_context6) {
475
- while (1) switch (_context6.prev = _context6.next) {
252
+ var _this3 = this;
253
+ return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee3() {
254
+ var _t15, _t16, _t17, _t18, _t19, _t20;
255
+ return _regenerator.default.wrap(function (_context3) {
256
+ while (1) switch (_context3.prev = _context3.next) {
476
257
  case 0:
477
- _t16 = _this6;
478
- _t17 = _constants.HTTP_VERBS.GET;
479
- _t18 = "".concat(_this6.webcastInstanceUrl, "/layout");
480
- _context6.next = 1;
481
- return _this6.webex.credentials.getUserToken();
258
+ _t15 = _this3;
259
+ _t16 = _constants.HTTP_VERBS.GET;
260
+ _t17 = "".concat(_this3.webcastInstanceUrl, "/layout");
261
+ _context3.next = 1;
262
+ return _this3.webex.credentials.getUserToken();
482
263
  case 1:
483
- _t19 = _context6.sent;
484
- _t20 = "".concat(_webexCore.config.trackingIdPrefix, "_").concat(_uuid.default.v4().toString());
485
- _t21 = {
486
- authorization: _t19,
487
- trackingId: _t20
264
+ _t18 = _context3.sent;
265
+ _t19 = "".concat(_webexCore.config.trackingIdPrefix, "_").concat(_uuid.default.v4().toString());
266
+ _t20 = {
267
+ authorization: _t18,
268
+ trackingId: _t19
488
269
  };
489
- return _context6.abrupt("return", _t16.request.call(_t16, {
490
- method: _t17,
491
- uri: _t18,
492
- headers: _t21
270
+ return _context3.abrupt("return", _t15.request.call(_t15, {
271
+ method: _t16,
272
+ uri: _t17,
273
+ headers: _t20
493
274
  }).catch(function (error) {
494
275
  _loggerProxy.default.logger.error('Meeting:webinar#queryWebcastLayout failed', error);
495
276
  throw error;
496
277
  }));
497
278
  case 2:
498
279
  case "end":
499
- return _context6.stop();
280
+ return _context3.stop();
500
281
  }
501
- }, _callee6);
282
+ }, _callee3);
502
283
  }))();
503
284
  },
504
285
  /**
@@ -507,83 +288,84 @@ var Webinar = _webexCore.WebexPlugin.extend({
507
288
  * @returns {Promise}
508
289
  */
509
290
  updateWebcastLayout: function updateWebcastLayout(layout) {
510
- var _this7 = this;
511
- return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee7() {
512
- var _t22, _t23, _t24, _t25, _t26, _t27, _t28, _t29;
513
- return _regenerator.default.wrap(function (_context7) {
514
- while (1) switch (_context7.prev = _context7.next) {
291
+ var _this4 = this;
292
+ return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee4() {
293
+ var _t21, _t22, _t23, _t24, _t25, _t26, _t27, _t28;
294
+ return _regenerator.default.wrap(function (_context4) {
295
+ while (1) switch (_context4.prev = _context4.next) {
515
296
  case 0:
516
- _t22 = _this7;
517
- _t23 = _constants.HTTP_VERBS.PUT;
518
- _t24 = "".concat(_this7.webcastInstanceUrl, "/layout");
519
- _t25 = _defineProperty2.default;
520
- _context7.next = 1;
521
- return _this7.webex.credentials.getUserToken();
297
+ _t21 = _this4;
298
+ _t22 = _constants.HTTP_VERBS.PUT;
299
+ _t23 = "".concat(_this4.webcastInstanceUrl, "/layout");
300
+ _t24 = _defineProperty2.default;
301
+ _context4.next = 1;
302
+ return _this4.webex.credentials.getUserToken();
522
303
  case 1:
523
- _t26 = _context7.sent;
524
- _t27 = "".concat(_webexCore.config.trackingIdPrefix, "_").concat(_uuid.default.v4().toString());
525
- _t28 = _t25({
526
- authorization: _t26,
527
- trackingId: _t27
304
+ _t25 = _context4.sent;
305
+ _t26 = "".concat(_webexCore.config.trackingIdPrefix, "_").concat(_uuid.default.v4().toString());
306
+ _t27 = _t24({
307
+ authorization: _t25,
308
+ trackingId: _t26
528
309
  }, _constants.HEADERS.CONTENT_TYPE, _constants.HEADERS.CONTENT_TYPE_VALUE.APPLICATION_JSON);
529
- _t29 = {
310
+ _t28 = {
530
311
  videoLayout: layout.videoLayout,
531
312
  contentLayout: layout.contentLayout,
532
313
  syncStageLayout: layout.syncStageLayout,
533
314
  syncStageInMeeting: layout.syncStageInMeeting
534
315
  };
535
- return _context7.abrupt("return", _t22.request.call(_t22, {
536
- method: _t23,
537
- uri: _t24,
538
- headers: _t28,
539
- body: _t29
316
+ return _context4.abrupt("return", _t21.request.call(_t21, {
317
+ method: _t22,
318
+ uri: _t23,
319
+ headers: _t27,
320
+ body: _t28
540
321
  }).catch(function (error) {
541
322
  _loggerProxy.default.logger.error('Meeting:webinar#updateWebcastLayout failed', error);
542
323
  throw error;
543
324
  }));
544
325
  case 2:
545
326
  case "end":
546
- return _context7.stop();
327
+ return _context4.stop();
547
328
  }
548
- }, _callee7);
329
+ }, _callee4);
549
330
  }))();
550
331
  },
551
332
  /**
552
333
  * view all webcast attendees
334
+ * @param {string} queryString
553
335
  * @returns {Promise}
554
336
  */
555
337
  viewAllWebcastAttendees: function viewAllWebcastAttendees() {
556
- var _this8 = this;
557
- return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee8() {
558
- var _t30, _t31, _t32, _t33, _t34, _t35;
559
- return _regenerator.default.wrap(function (_context8) {
560
- while (1) switch (_context8.prev = _context8.next) {
338
+ var _this5 = this;
339
+ return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee5() {
340
+ var _t29, _t30, _t31, _t32, _t33, _t34;
341
+ return _regenerator.default.wrap(function (_context5) {
342
+ while (1) switch (_context5.prev = _context5.next) {
561
343
  case 0:
562
- _t30 = _this8;
563
- _t31 = _constants.HTTP_VERBS.GET;
564
- _t32 = "".concat(_this8.webcastInstanceUrl, "/attendees");
565
- _context8.next = 1;
566
- return _this8.webex.credentials.getUserToken();
344
+ _t29 = _this5;
345
+ _t30 = _constants.HTTP_VERBS.GET;
346
+ _t31 = "".concat(_this5.webcastInstanceUrl, "/attendees");
347
+ _context5.next = 1;
348
+ return _this5.webex.credentials.getUserToken();
567
349
  case 1:
568
- _t33 = _context8.sent;
569
- _t34 = "".concat(_webexCore.config.trackingIdPrefix, "_").concat(_uuid.default.v4().toString());
570
- _t35 = {
571
- authorization: _t33,
572
- trackingId: _t34
350
+ _t32 = _context5.sent;
351
+ _t33 = "".concat(_webexCore.config.trackingIdPrefix, "_").concat(_uuid.default.v4().toString());
352
+ _t34 = {
353
+ authorization: _t32,
354
+ trackingId: _t33
573
355
  };
574
- return _context8.abrupt("return", _t30.request.call(_t30, {
575
- method: _t31,
576
- uri: _t32,
577
- headers: _t35
356
+ return _context5.abrupt("return", _t29.request.call(_t29, {
357
+ method: _t30,
358
+ uri: _t31,
359
+ headers: _t34
578
360
  }).catch(function (error) {
579
361
  _loggerProxy.default.logger.error('Meeting:webinar#viewAllWebcastAttendees failed', error);
580
362
  throw error;
581
363
  }));
582
364
  case 2:
583
365
  case "end":
584
- return _context8.stop();
366
+ return _context5.stop();
585
367
  }
586
- }, _callee8);
368
+ }, _callee5);
587
369
  }))();
588
370
  },
589
371
  /**
@@ -593,38 +375,38 @@ var Webinar = _webexCore.WebexPlugin.extend({
593
375
  */
594
376
  searchWebcastAttendees: function searchWebcastAttendees() {
595
377
  var _arguments = arguments,
596
- _this9 = this;
597
- return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee9() {
598
- var queryString, _t36, _t37, _t38, _t39, _t40, _t41;
599
- return _regenerator.default.wrap(function (_context9) {
600
- while (1) switch (_context9.prev = _context9.next) {
378
+ _this6 = this;
379
+ return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee6() {
380
+ var queryString, _t35, _t36, _t37, _t38, _t39, _t40;
381
+ return _regenerator.default.wrap(function (_context6) {
382
+ while (1) switch (_context6.prev = _context6.next) {
601
383
  case 0:
602
384
  queryString = _arguments.length > 0 && _arguments[0] !== undefined ? _arguments[0] : '';
603
- _t36 = _this9;
604
- _t37 = _constants.HTTP_VERBS.GET;
605
- _t38 = "".concat(_this9.webcastInstanceUrl, "/attendees?keyword=").concat(encodeURIComponent(queryString));
606
- _context9.next = 1;
607
- return _this9.webex.credentials.getUserToken();
385
+ _t35 = _this6;
386
+ _t36 = _constants.HTTP_VERBS.GET;
387
+ _t37 = "".concat(_this6.webcastInstanceUrl, "/attendees?keyword=").concat(encodeURIComponent(queryString));
388
+ _context6.next = 1;
389
+ return _this6.webex.credentials.getUserToken();
608
390
  case 1:
609
- _t39 = _context9.sent;
610
- _t40 = "".concat(_webexCore.config.trackingIdPrefix, "_").concat(_uuid.default.v4().toString());
611
- _t41 = {
612
- authorization: _t39,
613
- trackingId: _t40
391
+ _t38 = _context6.sent;
392
+ _t39 = "".concat(_webexCore.config.trackingIdPrefix, "_").concat(_uuid.default.v4().toString());
393
+ _t40 = {
394
+ authorization: _t38,
395
+ trackingId: _t39
614
396
  };
615
- return _context9.abrupt("return", _t36.request.call(_t36, {
616
- method: _t37,
617
- uri: _t38,
618
- headers: _t41
397
+ return _context6.abrupt("return", _t35.request.call(_t35, {
398
+ method: _t36,
399
+ uri: _t37,
400
+ headers: _t40
619
401
  }).catch(function (error) {
620
402
  _loggerProxy.default.logger.error('Meeting:webinar#searchWebcastAttendees failed', error);
621
403
  throw error;
622
404
  }));
623
405
  case 2:
624
406
  case "end":
625
- return _context9.stop();
407
+ return _context6.stop();
626
408
  }
627
- }, _callee9);
409
+ }, _callee6);
628
410
  }))();
629
411
  },
630
412
  /**
@@ -633,97 +415,40 @@ var Webinar = _webexCore.WebexPlugin.extend({
633
415
  * @returns {Promise}
634
416
  */
635
417
  expelWebcastAttendee: function expelWebcastAttendee(participantId) {
636
- var _this0 = this;
637
- return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee0() {
638
- var _t42, _t43, _t44, _t45, _t46, _t47;
639
- return _regenerator.default.wrap(function (_context0) {
640
- while (1) switch (_context0.prev = _context0.next) {
418
+ var _this7 = this;
419
+ return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee7() {
420
+ var _t41, _t42, _t43, _t44, _t45, _t46;
421
+ return _regenerator.default.wrap(function (_context7) {
422
+ while (1) switch (_context7.prev = _context7.next) {
641
423
  case 0:
642
- _t42 = _this0;
643
- _t43 = _constants.HTTP_VERBS.DELETE;
644
- _t44 = "".concat(_this0.webcastInstanceUrl, "/attendees/").concat(participantId);
645
- _context0.next = 1;
646
- return _this0.webex.credentials.getUserToken();
424
+ _t41 = _this7;
425
+ _t42 = _constants.HTTP_VERBS.DELETE;
426
+ _t43 = "".concat(_this7.webcastInstanceUrl, "/attendees/").concat(participantId);
427
+ _context7.next = 1;
428
+ return _this7.webex.credentials.getUserToken();
647
429
  case 1:
648
- _t45 = _context0.sent;
649
- _t46 = "".concat(_webexCore.config.trackingIdPrefix, "_").concat(_uuid.default.v4().toString());
650
- _t47 = {
651
- authorization: _t45,
652
- trackingId: _t46
430
+ _t44 = _context7.sent;
431
+ _t45 = "".concat(_webexCore.config.trackingIdPrefix, "_").concat(_uuid.default.v4().toString());
432
+ _t46 = {
433
+ authorization: _t44,
434
+ trackingId: _t45
653
435
  };
654
- return _context0.abrupt("return", _t42.request.call(_t42, {
655
- method: _t43,
656
- uri: _t44,
657
- headers: _t47
436
+ return _context7.abrupt("return", _t41.request.call(_t41, {
437
+ method: _t42,
438
+ uri: _t43,
439
+ headers: _t46
658
440
  }).catch(function (error) {
659
441
  _loggerProxy.default.logger.error('Meeting:webinar#expelWebcastAttendee failed', error);
660
442
  throw error;
661
443
  }));
662
444
  case 2:
663
445
  case "end":
664
- return _context0.stop();
665
- }
666
- }, _callee0);
667
- }))();
668
- },
669
- /**
670
- * search large scale webinar attendees
671
- * @param {object} payload
672
- * @param {string} payload.queryString
673
- * @param {number} payload.limit
674
- * @param {string} payload.next
675
- * @returns {Promise}
676
- */
677
- searchLargeScaleWebinarAttendees: function searchLargeScaleWebinarAttendees(payload) {
678
- var _this1 = this;
679
- return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee1() {
680
- var _payload$limit, _meeting$locusInfo3, _meeting$locusInfo3$l, _meeting$locusInfo3$l2, _meeting$locusInfo3$l3;
681
- var meeting, rawParams, attendeeSearchUrl, _t48, _t49, _t50, _t51, _t52, _t53;
682
- return _regenerator.default.wrap(function (_context1) {
683
- while (1) switch (_context1.prev = _context1.next) {
684
- case 0:
685
- meeting = _this1.webex.meetings.getMeetingByType(_constants._ID_, _this1.meetingId);
686
- rawParams = {
687
- search_text: payload === null || payload === void 0 ? void 0 : payload.queryString,
688
- limit: (_payload$limit = payload === null || payload === void 0 ? void 0 : payload.limit) !== null && _payload$limit !== void 0 ? _payload$limit : _constants.DEFAULT_LARGE_SCALE_WEBINAR_ATTENDEE_SEARCH_LIMIT,
689
- next: payload === null || payload === void 0 ? void 0 : payload.next
690
- };
691
- attendeeSearchUrl = meeting === null || meeting === void 0 ? void 0 : (_meeting$locusInfo3 = meeting.locusInfo) === null || _meeting$locusInfo3 === void 0 ? void 0 : (_meeting$locusInfo3$l = _meeting$locusInfo3.links) === null || _meeting$locusInfo3$l === void 0 ? void 0 : (_meeting$locusInfo3$l2 = _meeting$locusInfo3$l.resources) === null || _meeting$locusInfo3$l2 === void 0 ? void 0 : (_meeting$locusInfo3$l3 = _meeting$locusInfo3$l2.attendeeSearch) === null || _meeting$locusInfo3$l3 === void 0 ? void 0 : _meeting$locusInfo3$l3.url;
692
- if (attendeeSearchUrl) {
693
- _context1.next = 1;
694
- break;
695
- }
696
- _loggerProxy.default.logger.error("Meeting:webinar5k#searchLargeScaleWebinarAttendees failed");
697
- throw new Error('Meeting:webinar5k#Attendee search url is not available');
698
- case 1:
699
- _t48 = _this1;
700
- _t49 = _constants.HTTP_VERBS.GET;
701
- _t50 = "".concat(attendeeSearchUrl, "?").concat(new URLSearchParams((0, _utils.sanitizeParams)(rawParams)).toString());
702
- _context1.next = 2;
703
- return _this1.webex.credentials.getUserToken();
704
- case 2:
705
- _t51 = _context1.sent;
706
- _t52 = "".concat(_webexCore.config.trackingIdPrefix, "_").concat(_uuid.default.v4().toString());
707
- _t53 = {
708
- authorization: _t51,
709
- trackingId: _t52
710
- };
711
- return _context1.abrupt("return", _t48.request.call(_t48, {
712
- method: _t49,
713
- uri: _t50,
714
- headers: _t53
715
- }).catch(function (error) {
716
- _loggerProxy.default.logger.error('Meeting:webinar5k#searchLargeScaleWebinarAttendees failed', error);
717
- throw error;
718
- }));
719
- case 3:
720
- case "end":
721
- return _context1.stop();
446
+ return _context7.stop();
722
447
  }
723
- }, _callee1);
448
+ }, _callee7);
724
449
  }))();
725
450
  },
726
- version: "3.12.0-next.8"
451
+ version: "3.12.0-task-refactor.1"
727
452
  });
728
453
  var _default = exports.default = Webinar;
729
454
  //# sourceMappingURL=index.js.map