@webex/plugin-meetings 3.11.0 → 3.12.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/aiEnableRequest/index.js +184 -0
- package/dist/aiEnableRequest/index.js.map +1 -0
- package/dist/aiEnableRequest/utils.js +36 -0
- package/dist/aiEnableRequest/utils.js.map +1 -0
- package/dist/annotation/index.js +14 -5
- package/dist/annotation/index.js.map +1 -1
- package/dist/breakouts/breakout.js +1 -1
- package/dist/breakouts/index.js +1 -1
- package/dist/config.js +5 -1
- package/dist/config.js.map +1 -1
- package/dist/constants.js +28 -6
- package/dist/constants.js.map +1 -1
- package/dist/hashTree/constants.js +3 -1
- package/dist/hashTree/constants.js.map +1 -1
- package/dist/hashTree/hashTree.js +18 -0
- package/dist/hashTree/hashTree.js.map +1 -1
- package/dist/hashTree/hashTreeParser.js +709 -380
- package/dist/hashTree/hashTreeParser.js.map +1 -1
- package/dist/hashTree/types.js +4 -2
- package/dist/hashTree/types.js.map +1 -1
- package/dist/hashTree/utils.js +10 -0
- package/dist/hashTree/utils.js.map +1 -1
- package/dist/index.js +11 -2
- package/dist/index.js.map +1 -1
- package/dist/interceptors/constant.js +12 -0
- package/dist/interceptors/constant.js.map +1 -0
- package/dist/interceptors/dataChannelAuthToken.js +290 -0
- package/dist/interceptors/dataChannelAuthToken.js.map +1 -0
- package/dist/interceptors/index.js +7 -0
- package/dist/interceptors/index.js.map +1 -1
- package/dist/interceptors/utils.js +27 -0
- package/dist/interceptors/utils.js.map +1 -0
- package/dist/interpretation/index.js +2 -2
- package/dist/interpretation/index.js.map +1 -1
- package/dist/interpretation/siLanguage.js +1 -1
- package/dist/locus-info/controlsUtils.js +5 -3
- package/dist/locus-info/controlsUtils.js.map +1 -1
- package/dist/locus-info/index.js +217 -79
- package/dist/locus-info/index.js.map +1 -1
- package/dist/locus-info/selfUtils.js +1 -0
- package/dist/locus-info/selfUtils.js.map +1 -1
- package/dist/locus-info/types.js.map +1 -1
- package/dist/media/MediaConnectionAwaiter.js +57 -1
- package/dist/media/MediaConnectionAwaiter.js.map +1 -1
- package/dist/media/properties.js +4 -2
- package/dist/media/properties.js.map +1 -1
- package/dist/meeting/in-meeting-actions.js +7 -1
- package/dist/meeting/in-meeting-actions.js.map +1 -1
- package/dist/meeting/index.js +1082 -861
- package/dist/meeting/index.js.map +1 -1
- package/dist/meeting/request.js +50 -0
- package/dist/meeting/request.js.map +1 -1
- package/dist/meeting/request.type.js.map +1 -1
- package/dist/meeting/util.js +133 -3
- package/dist/meeting/util.js.map +1 -1
- package/dist/meetings/index.js +100 -45
- package/dist/meetings/index.js.map +1 -1
- package/dist/member/index.js +10 -0
- package/dist/member/index.js.map +1 -1
- package/dist/member/util.js +10 -0
- package/dist/member/util.js.map +1 -1
- package/dist/metrics/constants.js +2 -1
- package/dist/metrics/constants.js.map +1 -1
- package/dist/multistream/mediaRequestManager.js +9 -60
- package/dist/multistream/mediaRequestManager.js.map +1 -1
- package/dist/multistream/remoteMediaManager.js +11 -0
- package/dist/multistream/remoteMediaManager.js.map +1 -1
- package/dist/reachability/index.js +18 -10
- package/dist/reachability/index.js.map +1 -1
- package/dist/reactions/reactions.type.js.map +1 -1
- package/dist/reconnection-manager/index.js +0 -1
- package/dist/reconnection-manager/index.js.map +1 -1
- package/dist/types/aiEnableRequest/index.d.ts +5 -0
- package/dist/types/aiEnableRequest/utils.d.ts +2 -0
- package/dist/types/config.d.ts +3 -0
- package/dist/types/constants.d.ts +23 -1
- package/dist/types/hashTree/constants.d.ts +1 -0
- package/dist/types/hashTree/hashTree.d.ts +7 -0
- package/dist/types/hashTree/hashTreeParser.d.ts +99 -14
- package/dist/types/hashTree/types.d.ts +3 -0
- package/dist/types/hashTree/utils.d.ts +6 -0
- package/dist/types/index.d.ts +1 -0
- package/dist/types/interceptors/constant.d.ts +5 -0
- package/dist/types/interceptors/dataChannelAuthToken.d.ts +43 -0
- package/dist/types/interceptors/index.d.ts +2 -1
- package/dist/types/interceptors/utils.d.ts +1 -0
- package/dist/types/locus-info/index.d.ts +21 -2
- package/dist/types/locus-info/types.d.ts +1 -0
- package/dist/types/media/MediaConnectionAwaiter.d.ts +10 -1
- package/dist/types/media/properties.d.ts +2 -1
- package/dist/types/meeting/in-meeting-actions.d.ts +6 -0
- package/dist/types/meeting/index.d.ts +38 -6
- package/dist/types/meeting/request.d.ts +16 -1
- package/dist/types/meeting/request.type.d.ts +5 -0
- package/dist/types/meeting/util.d.ts +31 -0
- package/dist/types/meetings/index.d.ts +4 -2
- package/dist/types/member/index.d.ts +1 -0
- package/dist/types/member/util.d.ts +5 -0
- package/dist/types/metrics/constants.d.ts +1 -0
- package/dist/types/multistream/mediaRequestManager.d.ts +0 -23
- package/dist/types/reactions/reactions.type.d.ts +1 -0
- package/dist/types/webinar/utils.d.ts +6 -0
- package/dist/webinar/index.js +260 -90
- package/dist/webinar/index.js.map +1 -1
- package/dist/webinar/utils.js +25 -0
- package/dist/webinar/utils.js.map +1 -0
- package/package.json +24 -23
- package/src/aiEnableRequest/README.md +84 -0
- package/src/aiEnableRequest/index.ts +170 -0
- package/src/aiEnableRequest/utils.ts +25 -0
- package/src/annotation/index.ts +27 -7
- package/src/config.ts +3 -0
- package/src/constants.ts +29 -1
- package/src/hashTree/constants.ts +1 -0
- package/src/hashTree/hashTree.ts +17 -0
- package/src/hashTree/hashTreeParser.ts +627 -249
- package/src/hashTree/types.ts +4 -0
- package/src/hashTree/utils.ts +9 -0
- package/src/index.ts +8 -1
- package/src/interceptors/constant.ts +6 -0
- package/src/interceptors/dataChannelAuthToken.ts +170 -0
- package/src/interceptors/index.ts +2 -1
- package/src/interceptors/utils.ts +16 -0
- package/src/interpretation/index.ts +2 -2
- package/src/locus-info/controlsUtils.ts +11 -0
- package/src/locus-info/index.ts +231 -61
- package/src/locus-info/selfUtils.ts +1 -0
- package/src/locus-info/types.ts +1 -0
- package/src/media/MediaConnectionAwaiter.ts +41 -1
- package/src/media/properties.ts +3 -1
- package/src/meeting/in-meeting-actions.ts +12 -0
- package/src/meeting/index.ts +205 -44
- package/src/meeting/request.ts +42 -0
- package/src/meeting/request.type.ts +6 -0
- package/src/meeting/util.ts +160 -2
- package/src/meetings/index.ts +135 -41
- package/src/member/index.ts +10 -0
- package/src/member/util.ts +12 -0
- package/src/metrics/constants.ts +1 -0
- package/src/multistream/mediaRequestManager.ts +4 -54
- package/src/multistream/remoteMediaManager.ts +13 -0
- package/src/reachability/index.ts +9 -0
- package/src/reactions/reactions.type.ts +1 -0
- package/src/reconnection-manager/index.ts +0 -1
- package/src/webinar/index.ts +162 -5
- package/src/webinar/utils.ts +16 -0
- package/test/unit/spec/aiEnableRequest/index.ts +981 -0
- package/test/unit/spec/aiEnableRequest/utils.ts +130 -0
- package/test/unit/spec/annotation/index.ts +69 -7
- package/test/unit/spec/hashTree/hashTree.ts +66 -0
- package/test/unit/spec/hashTree/hashTreeParser.ts +1869 -189
- package/test/unit/spec/interceptors/dataChannelAuthToken.ts +210 -0
- package/test/unit/spec/interceptors/utils.ts +75 -0
- package/test/unit/spec/locus-info/controlsUtils.js +29 -0
- package/test/unit/spec/locus-info/index.js +383 -46
- package/test/unit/spec/media/MediaConnectionAwaiter.ts +41 -1
- package/test/unit/spec/media/properties.ts +12 -3
- package/test/unit/spec/meeting/in-meeting-actions.ts +8 -2
- package/test/unit/spec/meeting/index.js +716 -115
- package/test/unit/spec/meeting/request.js +70 -0
- package/test/unit/spec/meeting/utils.js +438 -26
- package/test/unit/spec/meetings/index.js +652 -31
- package/test/unit/spec/member/index.js +28 -4
- package/test/unit/spec/member/util.js +65 -27
- package/test/unit/spec/multistream/mediaRequestManager.ts +2 -85
- package/test/unit/spec/multistream/remoteMediaManager.ts +30 -0
- package/test/unit/spec/reachability/index.ts +23 -0
- package/test/unit/spec/reconnection-manager/index.js +4 -8
- package/test/unit/spec/webinar/index.ts +348 -36
- package/test/unit/spec/webinar/utils.ts +39 -0
package/dist/webinar/index.js
CHANGED
|
@@ -6,15 +6,18 @@ _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"));
|
|
9
10
|
var _regenerator = _interopRequireDefault(require("@babel/runtime-corejs2/regenerator"));
|
|
10
11
|
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime-corejs2/helpers/defineProperty"));
|
|
11
12
|
var _asyncToGenerator2 = _interopRequireDefault(require("@babel/runtime-corejs2/helpers/asyncToGenerator"));
|
|
12
13
|
var _webexCore = require("@webex/webex-core");
|
|
13
14
|
var _uuid = _interopRequireDefault(require("uuid"));
|
|
14
15
|
var _lodash = require("lodash");
|
|
16
|
+
var _internalPluginLlm = require("@webex/internal-plugin-llm");
|
|
15
17
|
var _constants = require("../constants");
|
|
16
18
|
var _collection = _interopRequireDefault(require("./collection"));
|
|
17
19
|
var _loggerProxy = _interopRequireDefault(require("../common/logs/logger-proxy"));
|
|
20
|
+
var _utils = require("./utils");
|
|
18
21
|
/*!
|
|
19
22
|
* Copyright (c) 2015-2023 Cisco Systems, Inc. See LICENSE file.
|
|
20
23
|
*/
|
|
@@ -42,6 +45,13 @@ var Webinar = _webexCore.WebexPlugin.extend({
|
|
|
42
45
|
// practice session enabled
|
|
43
46
|
meetingId: 'string'
|
|
44
47
|
},
|
|
48
|
+
/**
|
|
49
|
+
* Calls this to clean up listeners
|
|
50
|
+
* @returns {void}
|
|
51
|
+
*/
|
|
52
|
+
cleanUp: function cleanUp() {
|
|
53
|
+
this.cleanupPSDataChannel();
|
|
54
|
+
},
|
|
45
55
|
/**
|
|
46
56
|
* Update the current locus url of the webinar
|
|
47
57
|
* @param {string} locusUrl
|
|
@@ -105,10 +115,7 @@ var Webinar = _webexCore.WebexPlugin.extend({
|
|
|
105
115
|
// while panelist still need subscribe native mode so trigger force update here
|
|
106
116
|
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);
|
|
107
117
|
}
|
|
108
|
-
|
|
109
|
-
// may need change data channel in practice session
|
|
110
|
-
meeting === null || meeting === void 0 ? void 0 : meeting.updateLLMConnection();
|
|
111
|
-
}
|
|
118
|
+
this.updatePSDataChannel();
|
|
112
119
|
},
|
|
113
120
|
/**
|
|
114
121
|
* should join practice session data channel or not
|
|
@@ -117,6 +124,111 @@ var Webinar = _webexCore.WebexPlugin.extend({
|
|
|
117
124
|
isJoinPracticeSessionDataChannel: function isJoinPracticeSessionDataChannel() {
|
|
118
125
|
return this.selfIsPanelist && this.practiceSessionEnabled;
|
|
119
126
|
},
|
|
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
|
+
meeting = _this.webex.meetings.getMeetingByType(_constants._ID_, _this.meetingId); // @ts-ignore - Fix type
|
|
139
|
+
_context.next = 1;
|
|
140
|
+
return _this.webex.internal.llm.disconnectLLM({
|
|
141
|
+
code: 3050,
|
|
142
|
+
reason: 'done (permanent)'
|
|
143
|
+
}, _constants.LLM_PRACTICE_SESSION);
|
|
144
|
+
case 1:
|
|
145
|
+
// @ts-ignore - Fix type
|
|
146
|
+
_this.webex.internal.llm.off("event:relay.event:".concat(_constants.LLM_PRACTICE_SESSION), meeting === null || meeting === void 0 ? void 0 : meeting.processRelayEvent);
|
|
147
|
+
case 2:
|
|
148
|
+
case "end":
|
|
149
|
+
return _context.stop();
|
|
150
|
+
}
|
|
151
|
+
}, _callee);
|
|
152
|
+
}))();
|
|
153
|
+
},
|
|
154
|
+
/**
|
|
155
|
+
* Connects to low latency mercury and reconnects if the address has changed
|
|
156
|
+
* It will also disconnect if called when the meeting has ended
|
|
157
|
+
* @returns {Promise}
|
|
158
|
+
*/
|
|
159
|
+
updatePSDataChannel: function updatePSDataChannel() {
|
|
160
|
+
var _this2 = this;
|
|
161
|
+
return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee2() {
|
|
162
|
+
var meeting, isPracticeSession, _ref2, _ref2$url, url, _ref2$info, _ref2$info2, _ref2$info2$practiceS, practiceSessionDatachannelUrl, _ref2$self, _ref2$self2, _ref2$self2$practiceS, practiceSessionDatachannelToken, currentToken, finalToken, isCaptionBoxOn;
|
|
163
|
+
return _regenerator.default.wrap(function (_context2) {
|
|
164
|
+
while (1) switch (_context2.prev = _context2.next) {
|
|
165
|
+
case 0:
|
|
166
|
+
meeting = _this2.webex.meetings.getMeetingByType(_constants._ID_, _this2.meetingId);
|
|
167
|
+
isPracticeSession = (meeting === null || meeting === void 0 ? void 0 : meeting.isJoined()) && _this2.isJoinPracticeSessionDataChannel();
|
|
168
|
+
if (isPracticeSession) {
|
|
169
|
+
_context2.next = 2;
|
|
170
|
+
break;
|
|
171
|
+
}
|
|
172
|
+
_context2.next = 1;
|
|
173
|
+
return _this2.cleanupPSDataChannel();
|
|
174
|
+
case 1:
|
|
175
|
+
return _context2.abrupt("return", undefined);
|
|
176
|
+
case 2:
|
|
177
|
+
// @ts-ignore - Fix type
|
|
178
|
+
_ref2 = (meeting === null || meeting === void 0 ? void 0 : meeting.locusInfo) || {}, _ref2$url = _ref2.url, url = _ref2$url === void 0 ? undefined : _ref2$url, _ref2$info = _ref2.info, _ref2$info2 = _ref2$info === void 0 ? {} : _ref2$info, _ref2$info2$practiceS = _ref2$info2.practiceSessionDatachannelUrl, practiceSessionDatachannelUrl = _ref2$info2$practiceS === void 0 ? undefined : _ref2$info2$practiceS, _ref2$self = _ref2.self, _ref2$self2 = _ref2$self === void 0 ? {} : _ref2$self, _ref2$self2$practiceS = _ref2$self2.practiceSessionDatachannelToken, practiceSessionDatachannelToken = _ref2$self2$practiceS === void 0 ? undefined : _ref2$self2$practiceS; // @ts-ignore
|
|
179
|
+
currentToken = _this2.webex.internal.llm.getDatachannelToken(_internalPluginLlm.DataChannelTokenType.PracticeSession);
|
|
180
|
+
finalToken = currentToken !== null && currentToken !== void 0 ? currentToken : practiceSessionDatachannelToken;
|
|
181
|
+
isCaptionBoxOn = _this2.webex.internal.voicea.getIsCaptionBoxOn();
|
|
182
|
+
if (!currentToken && practiceSessionDatachannelToken) {
|
|
183
|
+
// @ts-ignore
|
|
184
|
+
_this2.webex.internal.llm.setDatachannelToken(practiceSessionDatachannelToken, _internalPluginLlm.DataChannelTokenType.PracticeSession);
|
|
185
|
+
}
|
|
186
|
+
if (practiceSessionDatachannelUrl) {
|
|
187
|
+
_context2.next = 3;
|
|
188
|
+
break;
|
|
189
|
+
}
|
|
190
|
+
return _context2.abrupt("return", undefined);
|
|
191
|
+
case 3:
|
|
192
|
+
if (!_this2.webex.internal.llm.isConnected(_constants.LLM_PRACTICE_SESSION)) {
|
|
193
|
+
_context2.next = 5;
|
|
194
|
+
break;
|
|
195
|
+
}
|
|
196
|
+
if (!(
|
|
197
|
+
// @ts-ignore - Fix type
|
|
198
|
+
url === _this2.webex.internal.llm.getLocusUrl(_constants.LLM_PRACTICE_SESSION) &&
|
|
199
|
+
// @ts-ignore - Fix type
|
|
200
|
+
practiceSessionDatachannelUrl === _this2.webex.internal.llm.getDatachannelUrl(_constants.LLM_PRACTICE_SESSION))) {
|
|
201
|
+
_context2.next = 4;
|
|
202
|
+
break;
|
|
203
|
+
}
|
|
204
|
+
return _context2.abrupt("return", undefined);
|
|
205
|
+
case 4:
|
|
206
|
+
_context2.next = 5;
|
|
207
|
+
return _this2.cleanupPSDataChannel();
|
|
208
|
+
case 5:
|
|
209
|
+
return _context2.abrupt("return", _this2.webex.internal.llm.registerAndConnect(url, practiceSessionDatachannelUrl, finalToken, _constants.LLM_PRACTICE_SESSION).then(function (registerAndConnectResult) {
|
|
210
|
+
var _this2$webex$internal, _this2$webex$internal2;
|
|
211
|
+
// @ts-ignore - Fix type
|
|
212
|
+
_this2.webex.internal.llm.off("event:relay.event:".concat(_constants.LLM_PRACTICE_SESSION), meeting === null || meeting === void 0 ? void 0 : meeting.processRelayEvent);
|
|
213
|
+
// @ts-ignore - Fix type
|
|
214
|
+
_this2.webex.internal.llm.on("event:relay.event:".concat(_constants.LLM_PRACTICE_SESSION), meeting === null || meeting === void 0 ? void 0 : meeting.processRelayEvent);
|
|
215
|
+
// @ts-ignore - Fix type
|
|
216
|
+
(_this2$webex$internal = _this2.webex.internal.voicea) === null || _this2$webex$internal === void 0 ? void 0 : (_this2$webex$internal2 = _this2$webex$internal.announce) === null || _this2$webex$internal2 === void 0 ? void 0 : _this2$webex$internal2.call(_this2$webex$internal);
|
|
217
|
+
if (isCaptionBoxOn) {
|
|
218
|
+
_this2.webex.internal.voicea.updateSubchannelSubscriptions({
|
|
219
|
+
subscribe: ['transcription']
|
|
220
|
+
});
|
|
221
|
+
}
|
|
222
|
+
_loggerProxy.default.logger.info("Webinar:index#updatePSDataChannel --> enabled to receive relay events for default session for ".concat(_constants.LLM_PRACTICE_SESSION, "!"));
|
|
223
|
+
return _promise.default.resolve(registerAndConnectResult);
|
|
224
|
+
}));
|
|
225
|
+
case 6:
|
|
226
|
+
case "end":
|
|
227
|
+
return _context2.stop();
|
|
228
|
+
}
|
|
229
|
+
}, _callee2);
|
|
230
|
+
}))();
|
|
231
|
+
},
|
|
120
232
|
/**
|
|
121
233
|
* start or stop practice session for webinar
|
|
122
234
|
* @param {boolean} enabled
|
|
@@ -143,6 +255,7 @@ var Webinar = _webexCore.WebexPlugin.extend({
|
|
|
143
255
|
*/
|
|
144
256
|
updatePracticeSessionStatus: function updatePracticeSessionStatus(payload) {
|
|
145
257
|
this.set('practiceSessionEnabled', !!(payload !== null && payload !== void 0 && payload.enabled));
|
|
258
|
+
this.updatePSDataChannel().then(function () {});
|
|
146
259
|
},
|
|
147
260
|
/**
|
|
148
261
|
* start webcast mode for webinar
|
|
@@ -151,27 +264,27 @@ var Webinar = _webexCore.WebexPlugin.extend({
|
|
|
151
264
|
* @returns {Promise}
|
|
152
265
|
*/
|
|
153
266
|
startWebcast: function startWebcast(meeting, layout) {
|
|
154
|
-
var
|
|
155
|
-
return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function
|
|
267
|
+
var _this3 = this;
|
|
268
|
+
return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee3() {
|
|
156
269
|
var _t, _t2, _t3, _t4, _t5, _t6, _t7, _t8;
|
|
157
|
-
return _regenerator.default.wrap(function (
|
|
158
|
-
while (1) switch (
|
|
270
|
+
return _regenerator.default.wrap(function (_context3) {
|
|
271
|
+
while (1) switch (_context3.prev = _context3.next) {
|
|
159
272
|
case 0:
|
|
160
273
|
if (meeting) {
|
|
161
|
-
|
|
274
|
+
_context3.next = 1;
|
|
162
275
|
break;
|
|
163
276
|
}
|
|
164
277
|
_loggerProxy.default.logger.error("Meeting:webinar#startWebcast failed --> meeting parameter : ".concat(meeting));
|
|
165
278
|
throw new Error('Meeting parameter does not meet expectations');
|
|
166
279
|
case 1:
|
|
167
|
-
_t =
|
|
280
|
+
_t = _this3;
|
|
168
281
|
_t2 = _constants.HTTP_VERBS.PUT;
|
|
169
|
-
_t3 = "".concat(
|
|
282
|
+
_t3 = "".concat(_this3.webcastInstanceUrl, "/streaming");
|
|
170
283
|
_t4 = _defineProperty2.default;
|
|
171
|
-
|
|
172
|
-
return
|
|
284
|
+
_context3.next = 2;
|
|
285
|
+
return _this3.webex.credentials.getUserToken();
|
|
173
286
|
case 2:
|
|
174
|
-
_t5 =
|
|
287
|
+
_t5 = _context3.sent;
|
|
175
288
|
_t6 = "".concat(_webexCore.config.trackingIdPrefix, "_").concat(_uuid.default.v4().toString());
|
|
176
289
|
_t7 = _t4({
|
|
177
290
|
authorization: _t5,
|
|
@@ -185,7 +298,7 @@ var Webinar = _webexCore.WebexPlugin.extend({
|
|
|
185
298
|
},
|
|
186
299
|
layout: layout
|
|
187
300
|
};
|
|
188
|
-
return
|
|
301
|
+
return _context3.abrupt("return", _t.request.call(_t, {
|
|
189
302
|
method: _t2,
|
|
190
303
|
uri: _t3,
|
|
191
304
|
headers: _t7,
|
|
@@ -196,9 +309,9 @@ var Webinar = _webexCore.WebexPlugin.extend({
|
|
|
196
309
|
}));
|
|
197
310
|
case 3:
|
|
198
311
|
case "end":
|
|
199
|
-
return
|
|
312
|
+
return _context3.stop();
|
|
200
313
|
}
|
|
201
|
-
},
|
|
314
|
+
}, _callee3);
|
|
202
315
|
}))();
|
|
203
316
|
},
|
|
204
317
|
/**
|
|
@@ -206,20 +319,20 @@ var Webinar = _webexCore.WebexPlugin.extend({
|
|
|
206
319
|
* @returns {Promise}
|
|
207
320
|
*/
|
|
208
321
|
stopWebcast: function stopWebcast() {
|
|
209
|
-
var
|
|
210
|
-
return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function
|
|
322
|
+
var _this4 = this;
|
|
323
|
+
return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee4() {
|
|
211
324
|
var _t9, _t0, _t1, _t10, _t11, _t12, _t13, _t14;
|
|
212
|
-
return _regenerator.default.wrap(function (
|
|
213
|
-
while (1) switch (
|
|
325
|
+
return _regenerator.default.wrap(function (_context4) {
|
|
326
|
+
while (1) switch (_context4.prev = _context4.next) {
|
|
214
327
|
case 0:
|
|
215
|
-
_t9 =
|
|
328
|
+
_t9 = _this4;
|
|
216
329
|
_t0 = _constants.HTTP_VERBS.PUT;
|
|
217
|
-
_t1 = "".concat(
|
|
330
|
+
_t1 = "".concat(_this4.webcastInstanceUrl, "/streaming");
|
|
218
331
|
_t10 = _defineProperty2.default;
|
|
219
|
-
|
|
220
|
-
return
|
|
332
|
+
_context4.next = 1;
|
|
333
|
+
return _this4.webex.credentials.getUserToken();
|
|
221
334
|
case 1:
|
|
222
|
-
_t11 =
|
|
335
|
+
_t11 = _context4.sent;
|
|
223
336
|
_t12 = "".concat(_webexCore.config.trackingIdPrefix, "_").concat(_uuid.default.v4().toString());
|
|
224
337
|
_t13 = _t10({
|
|
225
338
|
authorization: _t11,
|
|
@@ -228,7 +341,7 @@ var Webinar = _webexCore.WebexPlugin.extend({
|
|
|
228
341
|
_t14 = {
|
|
229
342
|
action: 'stop'
|
|
230
343
|
};
|
|
231
|
-
return
|
|
344
|
+
return _context4.abrupt("return", _t9.request.call(_t9, {
|
|
232
345
|
method: _t0,
|
|
233
346
|
uri: _t1,
|
|
234
347
|
headers: _t13,
|
|
@@ -239,9 +352,9 @@ var Webinar = _webexCore.WebexPlugin.extend({
|
|
|
239
352
|
}));
|
|
240
353
|
case 2:
|
|
241
354
|
case "end":
|
|
242
|
-
return
|
|
355
|
+
return _context4.stop();
|
|
243
356
|
}
|
|
244
|
-
},
|
|
357
|
+
}, _callee4);
|
|
245
358
|
}))();
|
|
246
359
|
},
|
|
247
360
|
/**
|
|
@@ -249,25 +362,25 @@ var Webinar = _webexCore.WebexPlugin.extend({
|
|
|
249
362
|
* @returns {Promise}
|
|
250
363
|
*/
|
|
251
364
|
queryWebcastLayout: function queryWebcastLayout() {
|
|
252
|
-
var
|
|
253
|
-
return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function
|
|
365
|
+
var _this5 = this;
|
|
366
|
+
return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee5() {
|
|
254
367
|
var _t15, _t16, _t17, _t18, _t19, _t20;
|
|
255
|
-
return _regenerator.default.wrap(function (
|
|
256
|
-
while (1) switch (
|
|
368
|
+
return _regenerator.default.wrap(function (_context5) {
|
|
369
|
+
while (1) switch (_context5.prev = _context5.next) {
|
|
257
370
|
case 0:
|
|
258
|
-
_t15 =
|
|
371
|
+
_t15 = _this5;
|
|
259
372
|
_t16 = _constants.HTTP_VERBS.GET;
|
|
260
|
-
_t17 = "".concat(
|
|
261
|
-
|
|
262
|
-
return
|
|
373
|
+
_t17 = "".concat(_this5.webcastInstanceUrl, "/layout");
|
|
374
|
+
_context5.next = 1;
|
|
375
|
+
return _this5.webex.credentials.getUserToken();
|
|
263
376
|
case 1:
|
|
264
|
-
_t18 =
|
|
377
|
+
_t18 = _context5.sent;
|
|
265
378
|
_t19 = "".concat(_webexCore.config.trackingIdPrefix, "_").concat(_uuid.default.v4().toString());
|
|
266
379
|
_t20 = {
|
|
267
380
|
authorization: _t18,
|
|
268
381
|
trackingId: _t19
|
|
269
382
|
};
|
|
270
|
-
return
|
|
383
|
+
return _context5.abrupt("return", _t15.request.call(_t15, {
|
|
271
384
|
method: _t16,
|
|
272
385
|
uri: _t17,
|
|
273
386
|
headers: _t20
|
|
@@ -277,9 +390,9 @@ var Webinar = _webexCore.WebexPlugin.extend({
|
|
|
277
390
|
}));
|
|
278
391
|
case 2:
|
|
279
392
|
case "end":
|
|
280
|
-
return
|
|
393
|
+
return _context5.stop();
|
|
281
394
|
}
|
|
282
|
-
},
|
|
395
|
+
}, _callee5);
|
|
283
396
|
}))();
|
|
284
397
|
},
|
|
285
398
|
/**
|
|
@@ -288,20 +401,20 @@ var Webinar = _webexCore.WebexPlugin.extend({
|
|
|
288
401
|
* @returns {Promise}
|
|
289
402
|
*/
|
|
290
403
|
updateWebcastLayout: function updateWebcastLayout(layout) {
|
|
291
|
-
var
|
|
292
|
-
return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function
|
|
404
|
+
var _this6 = this;
|
|
405
|
+
return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee6() {
|
|
293
406
|
var _t21, _t22, _t23, _t24, _t25, _t26, _t27, _t28;
|
|
294
|
-
return _regenerator.default.wrap(function (
|
|
295
|
-
while (1) switch (
|
|
407
|
+
return _regenerator.default.wrap(function (_context6) {
|
|
408
|
+
while (1) switch (_context6.prev = _context6.next) {
|
|
296
409
|
case 0:
|
|
297
|
-
_t21 =
|
|
410
|
+
_t21 = _this6;
|
|
298
411
|
_t22 = _constants.HTTP_VERBS.PUT;
|
|
299
|
-
_t23 = "".concat(
|
|
412
|
+
_t23 = "".concat(_this6.webcastInstanceUrl, "/layout");
|
|
300
413
|
_t24 = _defineProperty2.default;
|
|
301
|
-
|
|
302
|
-
return
|
|
414
|
+
_context6.next = 1;
|
|
415
|
+
return _this6.webex.credentials.getUserToken();
|
|
303
416
|
case 1:
|
|
304
|
-
_t25 =
|
|
417
|
+
_t25 = _context6.sent;
|
|
305
418
|
_t26 = "".concat(_webexCore.config.trackingIdPrefix, "_").concat(_uuid.default.v4().toString());
|
|
306
419
|
_t27 = _t24({
|
|
307
420
|
authorization: _t25,
|
|
@@ -313,7 +426,7 @@ var Webinar = _webexCore.WebexPlugin.extend({
|
|
|
313
426
|
syncStageLayout: layout.syncStageLayout,
|
|
314
427
|
syncStageInMeeting: layout.syncStageInMeeting
|
|
315
428
|
};
|
|
316
|
-
return
|
|
429
|
+
return _context6.abrupt("return", _t21.request.call(_t21, {
|
|
317
430
|
method: _t22,
|
|
318
431
|
uri: _t23,
|
|
319
432
|
headers: _t27,
|
|
@@ -324,9 +437,9 @@ var Webinar = _webexCore.WebexPlugin.extend({
|
|
|
324
437
|
}));
|
|
325
438
|
case 2:
|
|
326
439
|
case "end":
|
|
327
|
-
return
|
|
440
|
+
return _context6.stop();
|
|
328
441
|
}
|
|
329
|
-
},
|
|
442
|
+
}, _callee6);
|
|
330
443
|
}))();
|
|
331
444
|
},
|
|
332
445
|
/**
|
|
@@ -335,25 +448,25 @@ var Webinar = _webexCore.WebexPlugin.extend({
|
|
|
335
448
|
* @returns {Promise}
|
|
336
449
|
*/
|
|
337
450
|
viewAllWebcastAttendees: function viewAllWebcastAttendees() {
|
|
338
|
-
var
|
|
339
|
-
return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function
|
|
451
|
+
var _this7 = this;
|
|
452
|
+
return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee7() {
|
|
340
453
|
var _t29, _t30, _t31, _t32, _t33, _t34;
|
|
341
|
-
return _regenerator.default.wrap(function (
|
|
342
|
-
while (1) switch (
|
|
454
|
+
return _regenerator.default.wrap(function (_context7) {
|
|
455
|
+
while (1) switch (_context7.prev = _context7.next) {
|
|
343
456
|
case 0:
|
|
344
|
-
_t29 =
|
|
457
|
+
_t29 = _this7;
|
|
345
458
|
_t30 = _constants.HTTP_VERBS.GET;
|
|
346
|
-
_t31 = "".concat(
|
|
347
|
-
|
|
348
|
-
return
|
|
459
|
+
_t31 = "".concat(_this7.webcastInstanceUrl, "/attendees");
|
|
460
|
+
_context7.next = 1;
|
|
461
|
+
return _this7.webex.credentials.getUserToken();
|
|
349
462
|
case 1:
|
|
350
|
-
_t32 =
|
|
463
|
+
_t32 = _context7.sent;
|
|
351
464
|
_t33 = "".concat(_webexCore.config.trackingIdPrefix, "_").concat(_uuid.default.v4().toString());
|
|
352
465
|
_t34 = {
|
|
353
466
|
authorization: _t32,
|
|
354
467
|
trackingId: _t33
|
|
355
468
|
};
|
|
356
|
-
return
|
|
469
|
+
return _context7.abrupt("return", _t29.request.call(_t29, {
|
|
357
470
|
method: _t30,
|
|
358
471
|
uri: _t31,
|
|
359
472
|
headers: _t34
|
|
@@ -363,9 +476,9 @@ var Webinar = _webexCore.WebexPlugin.extend({
|
|
|
363
476
|
}));
|
|
364
477
|
case 2:
|
|
365
478
|
case "end":
|
|
366
|
-
return
|
|
479
|
+
return _context7.stop();
|
|
367
480
|
}
|
|
368
|
-
},
|
|
481
|
+
}, _callee7);
|
|
369
482
|
}))();
|
|
370
483
|
},
|
|
371
484
|
/**
|
|
@@ -375,26 +488,26 @@ var Webinar = _webexCore.WebexPlugin.extend({
|
|
|
375
488
|
*/
|
|
376
489
|
searchWebcastAttendees: function searchWebcastAttendees() {
|
|
377
490
|
var _arguments = arguments,
|
|
378
|
-
|
|
379
|
-
return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function
|
|
491
|
+
_this8 = this;
|
|
492
|
+
return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee8() {
|
|
380
493
|
var queryString, _t35, _t36, _t37, _t38, _t39, _t40;
|
|
381
|
-
return _regenerator.default.wrap(function (
|
|
382
|
-
while (1) switch (
|
|
494
|
+
return _regenerator.default.wrap(function (_context8) {
|
|
495
|
+
while (1) switch (_context8.prev = _context8.next) {
|
|
383
496
|
case 0:
|
|
384
497
|
queryString = _arguments.length > 0 && _arguments[0] !== undefined ? _arguments[0] : '';
|
|
385
|
-
_t35 =
|
|
498
|
+
_t35 = _this8;
|
|
386
499
|
_t36 = _constants.HTTP_VERBS.GET;
|
|
387
|
-
_t37 = "".concat(
|
|
388
|
-
|
|
389
|
-
return
|
|
500
|
+
_t37 = "".concat(_this8.webcastInstanceUrl, "/attendees?keyword=").concat(encodeURIComponent(queryString));
|
|
501
|
+
_context8.next = 1;
|
|
502
|
+
return _this8.webex.credentials.getUserToken();
|
|
390
503
|
case 1:
|
|
391
|
-
_t38 =
|
|
504
|
+
_t38 = _context8.sent;
|
|
392
505
|
_t39 = "".concat(_webexCore.config.trackingIdPrefix, "_").concat(_uuid.default.v4().toString());
|
|
393
506
|
_t40 = {
|
|
394
507
|
authorization: _t38,
|
|
395
508
|
trackingId: _t39
|
|
396
509
|
};
|
|
397
|
-
return
|
|
510
|
+
return _context8.abrupt("return", _t35.request.call(_t35, {
|
|
398
511
|
method: _t36,
|
|
399
512
|
uri: _t37,
|
|
400
513
|
headers: _t40
|
|
@@ -404,9 +517,9 @@ var Webinar = _webexCore.WebexPlugin.extend({
|
|
|
404
517
|
}));
|
|
405
518
|
case 2:
|
|
406
519
|
case "end":
|
|
407
|
-
return
|
|
520
|
+
return _context8.stop();
|
|
408
521
|
}
|
|
409
|
-
},
|
|
522
|
+
}, _callee8);
|
|
410
523
|
}))();
|
|
411
524
|
},
|
|
412
525
|
/**
|
|
@@ -415,25 +528,25 @@ var Webinar = _webexCore.WebexPlugin.extend({
|
|
|
415
528
|
* @returns {Promise}
|
|
416
529
|
*/
|
|
417
530
|
expelWebcastAttendee: function expelWebcastAttendee(participantId) {
|
|
418
|
-
var
|
|
419
|
-
return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function
|
|
531
|
+
var _this9 = this;
|
|
532
|
+
return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee9() {
|
|
420
533
|
var _t41, _t42, _t43, _t44, _t45, _t46;
|
|
421
|
-
return _regenerator.default.wrap(function (
|
|
422
|
-
while (1) switch (
|
|
534
|
+
return _regenerator.default.wrap(function (_context9) {
|
|
535
|
+
while (1) switch (_context9.prev = _context9.next) {
|
|
423
536
|
case 0:
|
|
424
|
-
_t41 =
|
|
537
|
+
_t41 = _this9;
|
|
425
538
|
_t42 = _constants.HTTP_VERBS.DELETE;
|
|
426
|
-
_t43 = "".concat(
|
|
427
|
-
|
|
428
|
-
return
|
|
539
|
+
_t43 = "".concat(_this9.webcastInstanceUrl, "/attendees/").concat(participantId);
|
|
540
|
+
_context9.next = 1;
|
|
541
|
+
return _this9.webex.credentials.getUserToken();
|
|
429
542
|
case 1:
|
|
430
|
-
_t44 =
|
|
543
|
+
_t44 = _context9.sent;
|
|
431
544
|
_t45 = "".concat(_webexCore.config.trackingIdPrefix, "_").concat(_uuid.default.v4().toString());
|
|
432
545
|
_t46 = {
|
|
433
546
|
authorization: _t44,
|
|
434
547
|
trackingId: _t45
|
|
435
548
|
};
|
|
436
|
-
return
|
|
549
|
+
return _context9.abrupt("return", _t41.request.call(_t41, {
|
|
437
550
|
method: _t42,
|
|
438
551
|
uri: _t43,
|
|
439
552
|
headers: _t46
|
|
@@ -443,12 +556,69 @@ var Webinar = _webexCore.WebexPlugin.extend({
|
|
|
443
556
|
}));
|
|
444
557
|
case 2:
|
|
445
558
|
case "end":
|
|
446
|
-
return
|
|
559
|
+
return _context9.stop();
|
|
447
560
|
}
|
|
448
|
-
},
|
|
561
|
+
}, _callee9);
|
|
562
|
+
}))();
|
|
563
|
+
},
|
|
564
|
+
/**
|
|
565
|
+
* search large scale webinar attendees
|
|
566
|
+
* @param {object} payload
|
|
567
|
+
* @param {string} payload.queryString
|
|
568
|
+
* @param {number} payload.limit
|
|
569
|
+
* @param {string} payload.next
|
|
570
|
+
* @returns {Promise}
|
|
571
|
+
*/
|
|
572
|
+
searchLargeScaleWebinarAttendees: function searchLargeScaleWebinarAttendees(payload) {
|
|
573
|
+
var _this0 = this;
|
|
574
|
+
return (0, _asyncToGenerator2.default)(/*#__PURE__*/_regenerator.default.mark(function _callee0() {
|
|
575
|
+
var _payload$limit, _meeting$locusInfo3, _meeting$locusInfo3$l, _meeting$locusInfo3$l2, _meeting$locusInfo3$l3;
|
|
576
|
+
var meeting, rawParams, attendeeSearchUrl, _t47, _t48, _t49, _t50, _t51, _t52;
|
|
577
|
+
return _regenerator.default.wrap(function (_context0) {
|
|
578
|
+
while (1) switch (_context0.prev = _context0.next) {
|
|
579
|
+
case 0:
|
|
580
|
+
meeting = _this0.webex.meetings.getMeetingByType(_constants._ID_, _this0.meetingId);
|
|
581
|
+
rawParams = {
|
|
582
|
+
search_text: payload === null || payload === void 0 ? void 0 : payload.queryString,
|
|
583
|
+
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,
|
|
584
|
+
next: payload === null || payload === void 0 ? void 0 : payload.next
|
|
585
|
+
};
|
|
586
|
+
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;
|
|
587
|
+
if (attendeeSearchUrl) {
|
|
588
|
+
_context0.next = 1;
|
|
589
|
+
break;
|
|
590
|
+
}
|
|
591
|
+
_loggerProxy.default.logger.error("Meeting:webinar5k#searchLargeScaleWebinarAttendees failed");
|
|
592
|
+
throw new Error('Meeting:webinar5k#Attendee search url is not available');
|
|
593
|
+
case 1:
|
|
594
|
+
_t47 = _this0;
|
|
595
|
+
_t48 = _constants.HTTP_VERBS.GET;
|
|
596
|
+
_t49 = "".concat(attendeeSearchUrl, "?").concat(new URLSearchParams((0, _utils.sanitizeParams)(rawParams)).toString());
|
|
597
|
+
_context0.next = 2;
|
|
598
|
+
return _this0.webex.credentials.getUserToken();
|
|
599
|
+
case 2:
|
|
600
|
+
_t50 = _context0.sent;
|
|
601
|
+
_t51 = "".concat(_webexCore.config.trackingIdPrefix, "_").concat(_uuid.default.v4().toString());
|
|
602
|
+
_t52 = {
|
|
603
|
+
authorization: _t50,
|
|
604
|
+
trackingId: _t51
|
|
605
|
+
};
|
|
606
|
+
return _context0.abrupt("return", _t47.request.call(_t47, {
|
|
607
|
+
method: _t48,
|
|
608
|
+
uri: _t49,
|
|
609
|
+
headers: _t52
|
|
610
|
+
}).catch(function (error) {
|
|
611
|
+
_loggerProxy.default.logger.error('Meeting:webinar5k#searchLargeScaleWebinarAttendees failed', error);
|
|
612
|
+
throw error;
|
|
613
|
+
}));
|
|
614
|
+
case 3:
|
|
615
|
+
case "end":
|
|
616
|
+
return _context0.stop();
|
|
617
|
+
}
|
|
618
|
+
}, _callee0);
|
|
449
619
|
}))();
|
|
450
620
|
},
|
|
451
|
-
version: "
|
|
621
|
+
version: "3.12.0"
|
|
452
622
|
});
|
|
453
623
|
var _default = exports.default = Webinar;
|
|
454
624
|
//# sourceMappingURL=index.js.map
|