@webex/plugin-meetings 3.12.0-task-refactor.1 → 3.12.0-webex-services-ready.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.
- package/AGENTS.md +9 -0
- package/dist/aiEnableRequest/index.js +197 -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 +8 -3
- package/dist/breakouts/breakout.js.map +1 -1
- package/dist/breakouts/index.js +26 -2
- package/dist/breakouts/index.js.map +1 -1
- package/dist/common/errors/webex-errors.js +49 -5
- package/dist/common/errors/webex-errors.js.map +1 -1
- package/dist/config.js +9 -3
- package/dist/config.js.map +1 -1
- package/dist/constants.js +59 -10
- package/dist/constants.js.map +1 -1
- package/dist/controls-options-manager/constants.js +11 -1
- package/dist/controls-options-manager/constants.js.map +1 -1
- package/dist/controls-options-manager/index.js +67 -29
- package/dist/controls-options-manager/index.js.map +1 -1
- package/dist/controls-options-manager/util.js +91 -0
- package/dist/controls-options-manager/util.js.map +1 -1
- package/dist/hashTree/constants.js +34 -0
- package/dist/hashTree/constants.js.map +1 -0
- package/dist/hashTree/hashTree.js +533 -0
- package/dist/hashTree/hashTree.js.map +1 -0
- package/dist/hashTree/hashTreeParser.js +2068 -36
- package/dist/hashTree/hashTreeParser.js.map +1 -1
- package/dist/hashTree/types.js +13 -3
- package/dist/hashTree/types.js.map +1 -1
- package/dist/hashTree/utils.js +111 -0
- package/dist/hashTree/utils.js.map +1 -0
- package/dist/index.js +18 -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 +350 -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/locusRetry.js +23 -8
- package/dist/interceptors/locusRetry.js.map +1 -1
- package/dist/interceptors/locusRouteToken.js +27 -5
- package/dist/interceptors/locusRouteToken.js.map +1 -1
- package/dist/interceptors/utils.js +27 -0
- package/dist/interceptors/utils.js.map +1 -0
- package/dist/interpretation/index.js +11 -2
- package/dist/interpretation/index.js.map +1 -1
- package/dist/interpretation/interpretation.types.js +7 -0
- package/dist/interpretation/interpretation.types.js.map +1 -0
- package/dist/interpretation/siLanguage.js +1 -1
- package/dist/locus-info/controlsUtils.js +11 -4
- package/dist/locus-info/controlsUtils.js.map +1 -1
- package/dist/locus-info/index.js +896 -277
- package/dist/locus-info/index.js.map +1 -1
- package/dist/locus-info/infoUtils.js +36 -5
- package/dist/locus-info/infoUtils.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 +19 -0
- package/dist/locus-info/types.js.map +1 -1
- package/dist/media/MediaConnectionAwaiter.js +72 -3
- package/dist/media/MediaConnectionAwaiter.js.map +1 -1
- package/dist/media/index.js +8 -2
- package/dist/media/index.js.map +1 -1
- package/dist/media/properties.js +5 -2
- package/dist/media/properties.js.map +1 -1
- package/dist/meeting/in-meeting-actions.js +11 -1
- package/dist/meeting/in-meeting-actions.js.map +1 -1
- package/dist/meeting/index.js +2075 -1096
- package/dist/meeting/index.js.map +1 -1
- package/dist/meeting/locusMediaRequest.js +229 -82
- package/dist/meeting/locusMediaRequest.js.map +1 -1
- package/dist/meeting/muteState.js +10 -1
- package/dist/meeting/muteState.js.map +1 -1
- package/dist/meeting/request.js +55 -2
- package/dist/meeting/request.js.map +1 -1
- package/dist/meeting/request.type.js.map +1 -1
- package/dist/meeting/util.js +168 -5
- package/dist/meeting/util.js.map +1 -1
- package/dist/meeting-info/meeting-info-v2.js +2 -2
- package/dist/meeting-info/meeting-info-v2.js.map +1 -1
- package/dist/meetings/index.js +369 -173
- package/dist/meetings/index.js.map +1 -1
- package/dist/meetings/meetings.types.js +6 -1
- package/dist/meetings/meetings.types.js.map +1 -1
- package/dist/meetings/request.js +39 -0
- package/dist/meetings/request.js.map +1 -1
- package/dist/meetings/util.js +127 -25
- package/dist/meetings/util.js.map +1 -1
- package/dist/member/index.js +20 -0
- package/dist/member/index.js.map +1 -1
- package/dist/member/types.js.map +1 -1
- package/dist/member/util.js +40 -0
- package/dist/member/util.js.map +1 -1
- package/dist/members/index.js +101 -43
- package/dist/members/index.js.map +1 -1
- package/dist/members/util.js +8 -1
- package/dist/members/util.js.map +1 -1
- package/dist/metrics/constants.js +11 -1
- package/dist/metrics/constants.js.map +1 -1
- package/dist/multistream/codec/constants.js +63 -0
- package/dist/multistream/codec/constants.js.map +1 -0
- package/dist/multistream/mediaRequestManager.js +64 -68
- package/dist/multistream/mediaRequestManager.js.map +1 -1
- package/dist/multistream/receiveSlot.js +9 -0
- package/dist/multistream/receiveSlot.js.map +1 -1
- package/dist/multistream/remoteMediaManager.js +11 -0
- package/dist/multistream/remoteMediaManager.js.map +1 -1
- package/dist/multistream/sendSlotManager.js +116 -2
- package/dist/multistream/sendSlotManager.js.map +1 -1
- package/dist/reachability/clusterReachability.js +171 -18
- package/dist/reachability/clusterReachability.js.map +1 -1
- package/dist/reachability/index.js +142 -94
- package/dist/reachability/index.js.map +1 -1
- package/dist/reachability/reachability.types.js +2 -0
- package/dist/reachability/reachability.types.js.map +1 -1
- package/dist/reachability/reachabilityPeerConnection.js +1 -1
- package/dist/reachability/reachabilityPeerConnection.js.map +1 -1
- package/dist/reachability/util.js +45 -0
- package/dist/reachability/util.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/recording-controller/index.js +1 -3
- package/dist/recording-controller/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/common/browser-detection.d.ts +1 -0
- package/dist/types/common/errors/webex-errors.d.ts +32 -2
- package/dist/types/common/events/events-scope.d.ts +1 -0
- package/dist/types/common/events/events.d.ts +1 -0
- package/dist/types/config.d.ts +7 -2
- package/dist/types/constants.d.ts +35 -1
- package/dist/types/controls-options-manager/constants.d.ts +6 -1
- package/dist/types/controls-options-manager/index.d.ts +16 -0
- package/dist/types/hashTree/constants.d.ts +11 -0
- package/dist/types/hashTree/hashTree.d.ts +136 -0
- package/dist/types/hashTree/hashTreeParser.d.ts +392 -14
- package/dist/types/hashTree/types.d.ts +20 -0
- package/dist/types/hashTree/utils.d.ts +40 -0
- package/dist/types/index.d.ts +4 -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/locusRetry.d.ts +4 -4
- package/dist/types/interceptors/locusRouteToken.d.ts +2 -0
- package/dist/types/interceptors/utils.d.ts +1 -0
- package/dist/types/interpretation/interpretation.types.d.ts +10 -0
- package/dist/types/locus-info/index.d.ts +116 -51
- package/dist/types/locus-info/infoUtils.d.ts +8 -0
- package/dist/types/locus-info/types.d.ts +48 -12
- package/dist/types/media/MediaConnectionAwaiter.d.ts +20 -2
- package/dist/types/media/properties.d.ts +3 -1
- package/dist/types/meeting/in-meeting-actions.d.ts +10 -0
- package/dist/types/meeting/index.d.ts +196 -15
- package/dist/types/meeting/locusMediaRequest.d.ts +12 -0
- package/dist/types/meeting/request.d.ts +17 -1
- package/dist/types/meeting/request.type.d.ts +5 -0
- package/dist/types/meeting/util.d.ts +40 -0
- package/dist/types/meeting-info/util.d.ts +1 -0
- package/dist/types/meeting-info/utilv2.d.ts +1 -0
- package/dist/types/meetings/index.d.ts +34 -20
- package/dist/types/meetings/meetings.types.d.ts +15 -0
- package/dist/types/meetings/request.d.ts +14 -0
- package/dist/types/member/index.d.ts +2 -0
- package/dist/types/member/types.d.ts +5 -4
- package/dist/types/member/util.d.ts +14 -0
- package/dist/types/members/index.d.ts +15 -2
- package/dist/types/members/util.d.ts +1 -5
- package/dist/types/metrics/constants.d.ts +10 -0
- package/dist/types/multistream/codec/constants.d.ts +7 -0
- package/dist/types/multistream/mediaRequestManager.d.ts +20 -26
- package/dist/types/multistream/sendSlotManager.d.ts +23 -1
- package/dist/types/reachability/clusterReachability.d.ts +33 -6
- package/dist/types/reachability/index.d.ts +10 -3
- package/dist/types/reachability/reachability.types.d.ts +7 -0
- package/dist/types/reachability/util.d.ts +17 -0
- package/dist/types/reactions/reactions.type.d.ts +4 -0
- package/dist/types/recording-controller/util.d.ts +5 -5
- package/dist/types/roap/index.d.ts +1 -1
- package/dist/types/webinar/utils.d.ts +6 -0
- package/dist/webinar/index.js +585 -164
- 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 +26 -24
- package/src/aiEnableRequest/README.md +84 -0
- package/src/aiEnableRequest/index.ts +186 -0
- package/src/aiEnableRequest/utils.ts +25 -0
- package/src/annotation/index.ts +27 -7
- package/src/breakouts/breakout.ts +3 -1
- package/src/breakouts/index.ts +31 -0
- package/src/common/errors/webex-errors.ts +50 -3
- package/src/config.ts +7 -2
- package/src/constants.ts +49 -3
- package/src/controls-options-manager/constants.ts +14 -1
- package/src/controls-options-manager/index.ts +87 -28
- package/src/controls-options-manager/util.ts +81 -1
- package/src/hashTree/constants.ts +26 -0
- package/src/hashTree/hashTree.ts +480 -0
- package/src/hashTree/hashTreeParser.ts +1911 -29
- package/src/hashTree/types.ts +24 -1
- package/src/hashTree/utils.ts +98 -0
- package/src/index.ts +14 -1
- package/src/interceptors/constant.ts +6 -0
- package/src/interceptors/dataChannelAuthToken.ts +246 -0
- package/src/interceptors/index.ts +2 -1
- package/src/interceptors/locusRetry.ts +25 -4
- package/src/interceptors/locusRouteToken.ts +22 -5
- package/src/interceptors/utils.ts +16 -0
- package/src/interpretation/index.ts +29 -11
- package/src/interpretation/interpretation.types.ts +11 -0
- package/src/locus-info/controlsUtils.ts +20 -1
- package/src/locus-info/index.ts +958 -250
- package/src/locus-info/infoUtils.ts +41 -6
- package/src/locus-info/selfUtils.ts +1 -0
- package/src/locus-info/types.ts +51 -12
- package/src/media/MediaConnectionAwaiter.ts +62 -5
- package/src/media/index.ts +10 -1
- package/src/media/properties.ts +4 -1
- package/src/meeting/in-meeting-actions.ts +20 -0
- package/src/meeting/index.ts +1025 -146
- package/src/meeting/locusMediaRequest.ts +106 -6
- package/src/meeting/muteState.ts +10 -1
- package/src/meeting/request.ts +53 -0
- package/src/meeting/request.type.ts +6 -0
- package/src/meeting/util.ts +207 -7
- package/src/meeting-info/meeting-info-v2.ts +4 -2
- package/src/meetings/index.ts +307 -132
- package/src/meetings/meetings.types.ts +19 -0
- package/src/meetings/request.ts +43 -0
- package/src/meetings/util.ts +127 -13
- package/src/member/index.ts +20 -0
- package/src/member/types.ts +1 -0
- package/src/member/util.ts +41 -0
- package/src/members/index.ts +70 -7
- package/src/members/util.ts +12 -4
- package/src/metrics/constants.ts +11 -0
- package/src/multistream/codec/constants.ts +58 -0
- package/src/multistream/mediaRequestManager.ts +117 -76
- package/src/multistream/receiveSlot.ts +18 -0
- package/src/multistream/remoteMediaManager.ts +13 -0
- package/src/multistream/sendSlotManager.ts +97 -3
- package/src/reachability/clusterReachability.ts +156 -29
- package/src/reachability/index.ts +62 -17
- package/src/reachability/reachability.types.ts +11 -0
- package/src/reachability/reachabilityPeerConnection.ts +3 -1
- package/src/reachability/util.ts +36 -0
- package/src/reactions/reactions.type.ts +4 -0
- package/src/reconnection-manager/index.ts +0 -1
- package/src/recording-controller/index.ts +1 -2
- package/src/webinar/index.ts +448 -11
- package/src/webinar/utils.ts +16 -0
- package/test/unit/spec/aiEnableRequest/index.ts +1067 -0
- package/test/unit/spec/aiEnableRequest/utils.ts +130 -0
- package/test/unit/spec/annotation/index.ts +69 -7
- package/test/unit/spec/breakouts/breakout.ts +9 -3
- package/test/unit/spec/breakouts/index.ts +49 -0
- package/test/unit/spec/common/errors/webex-errors.ts +78 -0
- package/test/unit/spec/controls-options-manager/index.js +244 -29
- package/test/unit/spec/controls-options-manager/util.js +165 -0
- package/test/unit/spec/hashTree/hashTree.ts +721 -0
- package/test/unit/spec/hashTree/hashTreeParser.ts +5328 -0
- package/test/unit/spec/hashTree/utils.ts +264 -0
- package/test/unit/spec/interceptors/dataChannelAuthToken.ts +406 -0
- package/test/unit/spec/interceptors/locusRetry.ts +205 -4
- package/test/unit/spec/interceptors/locusRouteToken.ts +44 -0
- package/test/unit/spec/interceptors/utils.ts +75 -0
- package/test/unit/spec/interpretation/index.ts +26 -4
- package/test/unit/spec/locus-info/controlsUtils.js +222 -52
- package/test/unit/spec/locus-info/index.js +2000 -171
- package/test/unit/spec/locus-info/infoUtils.js +184 -1
- package/test/unit/spec/media/MediaConnectionAwaiter.ts +96 -1
- package/test/unit/spec/media/index.ts +92 -0
- package/test/unit/spec/media/properties.ts +12 -3
- package/test/unit/spec/meeting/in-meeting-actions.ts +12 -2
- package/test/unit/spec/meeting/index.js +2925 -209
- package/test/unit/spec/meeting/locusMediaRequest.ts +406 -4
- package/test/unit/spec/meeting/muteState.js +81 -0
- package/test/unit/spec/meeting/request.js +82 -0
- package/test/unit/spec/meeting/utils.js +595 -27
- package/test/unit/spec/meeting-info/meetinginfov2.js +19 -10
- package/test/unit/spec/meetings/index.js +1214 -75
- package/test/unit/spec/meetings/request.js +141 -0
- package/test/unit/spec/meetings/utils.js +453 -52
- package/test/unit/spec/member/index.js +35 -4
- package/test/unit/spec/member/util.js +154 -27
- package/test/unit/spec/members/index.js +216 -0
- package/test/unit/spec/members/request.js +37 -1
- package/test/unit/spec/members/utils.js +63 -0
- package/test/unit/spec/multistream/mediaRequestManager.ts +503 -122
- package/test/unit/spec/multistream/remoteMediaManager.ts +30 -0
- package/test/unit/spec/multistream/sendSlotManager.ts +135 -36
- package/test/unit/spec/reachability/clusterReachability.ts +125 -1
- package/test/unit/spec/reachability/index.ts +154 -49
- package/test/unit/spec/reachability/util.ts +31 -0
- package/test/unit/spec/reconnection-manager/index.js +4 -8
- package/test/unit/spec/recording-controller/index.js +9 -8
- package/test/unit/spec/webinar/index.ts +837 -39
- package/test/unit/spec/webinar/utils.ts +39 -0
package/dist/meeting/util.js
CHANGED
|
@@ -21,6 +21,7 @@ var _defineProperty2 = _interopRequireDefault(require("@babel/runtime-corejs2/he
|
|
|
21
21
|
var _asyncToGenerator2 = _interopRequireDefault(require("@babel/runtime-corejs2/helpers/asyncToGenerator"));
|
|
22
22
|
var _promise = _interopRequireDefault(require("@babel/runtime-corejs2/core-js/promise"));
|
|
23
23
|
var _stringify = _interopRequireDefault(require("@babel/runtime-corejs2/core-js/json/stringify"));
|
|
24
|
+
var _url = _interopRequireDefault(require("url"));
|
|
24
25
|
var _lodash = require("lodash");
|
|
25
26
|
var _webexErrors = require("../common/errors/webex-errors");
|
|
26
27
|
var _loggerProxy = _interopRequireDefault(require("../common/logs/logger-proxy"));
|
|
@@ -33,6 +34,7 @@ var _permission = _interopRequireDefault(require("../common/errors/permission"))
|
|
|
33
34
|
var _passwordError = _interopRequireDefault(require("../common/errors/password-error"));
|
|
34
35
|
var _captchaError = _interopRequireDefault(require("../common/errors/captcha-error"));
|
|
35
36
|
var _triggerProxy = _interopRequireDefault(require("../common/events/trigger-proxy"));
|
|
37
|
+
var _types = require("../member/types");
|
|
36
38
|
function _createForOfIteratorHelper(r, e) { var t = "undefined" != typeof _Symbol && r[_Symbol$iterator] || r["@@iterator"]; if (!t) { if (_Array$isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && "number" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t.return || t.return(); } finally { if (u) throw o; } } }; }
|
|
37
39
|
function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? _Array$from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }
|
|
38
40
|
function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
|
|
@@ -45,6 +47,7 @@ var MeetingUtil = {
|
|
|
45
47
|
// First todo: add check for existance
|
|
46
48
|
parsed.locus = response.body.locus;
|
|
47
49
|
parsed.dataSets = response.body.dataSets;
|
|
50
|
+
parsed.metadata = response.body.metaData;
|
|
48
51
|
parsed.mediaConnections = response.body.mediaConnections;
|
|
49
52
|
parsed.locusUrl = parsed.locus.url;
|
|
50
53
|
parsed.locusId = parsed.locus.url.split('/').pop();
|
|
@@ -58,6 +61,106 @@ var MeetingUtil = {
|
|
|
58
61
|
});
|
|
59
62
|
return parsed;
|
|
60
63
|
},
|
|
64
|
+
/**
|
|
65
|
+
* Sanitizes a WebSocket URL by extracting only protocol, host, and pathname
|
|
66
|
+
* Returns concatenated protocol + host + pathname for safe logging
|
|
67
|
+
* Note: This is used for logging only; URL matching uses partial matching via _urlsPartiallyMatch
|
|
68
|
+
* @param {string} urlString - The URL to sanitize
|
|
69
|
+
* @returns {string} Sanitized URL or empty string if parsing fails
|
|
70
|
+
*/
|
|
71
|
+
sanitizeWebSocketUrl: function sanitizeWebSocketUrl(urlString) {
|
|
72
|
+
if (!urlString || typeof urlString !== 'string') {
|
|
73
|
+
return '';
|
|
74
|
+
}
|
|
75
|
+
try {
|
|
76
|
+
var parsedUrl = _url.default.parse(urlString);
|
|
77
|
+
var protocol = parsedUrl.protocol || '';
|
|
78
|
+
var host = parsedUrl.host || '';
|
|
79
|
+
|
|
80
|
+
// If we don't have at least protocol and host, it's not a valid URL
|
|
81
|
+
if (!protocol || !host) {
|
|
82
|
+
return '';
|
|
83
|
+
}
|
|
84
|
+
var pathname = parsedUrl.pathname || '';
|
|
85
|
+
|
|
86
|
+
// Strip trailing slash if pathname is just '/'
|
|
87
|
+
var normalizedPathname = pathname === '/' ? '' : pathname;
|
|
88
|
+
return "".concat(protocol, "//").concat(host).concat(normalizedPathname);
|
|
89
|
+
} catch (error) {
|
|
90
|
+
_loggerProxy.default.logger.warn("Meeting:util#sanitizeWebSocketUrl --> unable to parse URL: ".concat(error));
|
|
91
|
+
return '';
|
|
92
|
+
}
|
|
93
|
+
},
|
|
94
|
+
/**
|
|
95
|
+
* Checks if two URLs partially match using an endsWith approach
|
|
96
|
+
* Combines host and pathname, then checks if one ends with the other
|
|
97
|
+
* This handles cases where one URL goes through a proxy (e.g., /webproxy/) while the other is direct
|
|
98
|
+
* @param {string} url1 - First URL to compare
|
|
99
|
+
* @param {string} url2 - Second URL to compare
|
|
100
|
+
* @returns {boolean} True if one URL path ends with the other (partial match), false otherwise
|
|
101
|
+
*/
|
|
102
|
+
_urlsPartiallyMatch: function _urlsPartiallyMatch(url1, url2) {
|
|
103
|
+
if (!url1 || !url2) {
|
|
104
|
+
return false;
|
|
105
|
+
}
|
|
106
|
+
try {
|
|
107
|
+
var parsedUrl1 = _url.default.parse(url1);
|
|
108
|
+
var parsedUrl2 = _url.default.parse(url2);
|
|
109
|
+
var host1 = parsedUrl1.host || '';
|
|
110
|
+
var host2 = parsedUrl2.host || '';
|
|
111
|
+
var pathname1 = parsedUrl1.pathname || '';
|
|
112
|
+
var pathname2 = parsedUrl2.pathname || '';
|
|
113
|
+
|
|
114
|
+
// If either failed to parse, they don't match
|
|
115
|
+
if (!host1 || !host2 || !pathname1 || !pathname2) {
|
|
116
|
+
return false;
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
// Combine host and pathname for comparison
|
|
120
|
+
var combined1 = host1 + pathname1;
|
|
121
|
+
var combined2 = host2 + pathname2;
|
|
122
|
+
|
|
123
|
+
// Check if one combined path ends with the other (handles proxy URLs)
|
|
124
|
+
return combined1.endsWith(combined2) || combined2.endsWith(combined1);
|
|
125
|
+
} catch (e) {
|
|
126
|
+
_loggerProxy.default.logger.warn('Meeting:util#_urlsPartiallyMatch --> error comparing URLs', e);
|
|
127
|
+
return false;
|
|
128
|
+
}
|
|
129
|
+
},
|
|
130
|
+
/**
|
|
131
|
+
* Gets socket URL information for metrics, including whether the socket URLs match
|
|
132
|
+
* Uses partial matching to handle proxy URLs (e.g., URLs with /webproxy/ prefix)
|
|
133
|
+
* @param {Object} webex - The webex instance
|
|
134
|
+
* @returns {Object} Object with hasMismatchedSocket, mercurySocketUrl, and deviceSocketUrl properties
|
|
135
|
+
*/
|
|
136
|
+
getSocketUrlInfo: function getSocketUrlInfo(webex) {
|
|
137
|
+
try {
|
|
138
|
+
var _webex$internal, _webex$internal$mercu, _webex$internal$mercu2, _webex$internal2, _webex$internal2$devi;
|
|
139
|
+
var mercuryUrl = webex === null || webex === void 0 ? void 0 : (_webex$internal = webex.internal) === null || _webex$internal === void 0 ? void 0 : (_webex$internal$mercu = _webex$internal.mercury) === null || _webex$internal$mercu === void 0 ? void 0 : (_webex$internal$mercu2 = _webex$internal$mercu.socket) === null || _webex$internal$mercu2 === void 0 ? void 0 : _webex$internal$mercu2.url;
|
|
140
|
+
var deviceUrl = webex === null || webex === void 0 ? void 0 : (_webex$internal2 = webex.internal) === null || _webex$internal2 === void 0 ? void 0 : (_webex$internal2$devi = _webex$internal2.device) === null || _webex$internal2$devi === void 0 ? void 0 : _webex$internal2$devi.webSocketUrl;
|
|
141
|
+
var sanitizedMercuryUrl = MeetingUtil.sanitizeWebSocketUrl(mercuryUrl);
|
|
142
|
+
var sanitizedDeviceUrl = MeetingUtil.sanitizeWebSocketUrl(deviceUrl);
|
|
143
|
+
|
|
144
|
+
// Only report a mismatch if both URLs are present and they don't match
|
|
145
|
+
// If either URL is missing, we can't determine if there's a mismatch, so return false
|
|
146
|
+
var hasMismatchedSocket = false;
|
|
147
|
+
if (sanitizedMercuryUrl && sanitizedDeviceUrl) {
|
|
148
|
+
hasMismatchedSocket = !MeetingUtil._urlsPartiallyMatch(mercuryUrl, deviceUrl);
|
|
149
|
+
}
|
|
150
|
+
return {
|
|
151
|
+
hasMismatchedSocket: hasMismatchedSocket,
|
|
152
|
+
mercurySocketUrl: sanitizedMercuryUrl,
|
|
153
|
+
deviceSocketUrl: sanitizedDeviceUrl
|
|
154
|
+
};
|
|
155
|
+
} catch (error) {
|
|
156
|
+
_loggerProxy.default.logger.warn("Meeting:util#getSocketUrlInfo --> error getting socket URL info: ".concat(error));
|
|
157
|
+
return {
|
|
158
|
+
hasMismatchedSocket: false,
|
|
159
|
+
mercurySocketUrl: '',
|
|
160
|
+
deviceSocketUrl: ''
|
|
161
|
+
};
|
|
162
|
+
}
|
|
163
|
+
},
|
|
61
164
|
remoteUpdateAudioVideo: function remoteUpdateAudioVideo(meeting, audioMuted, videoMuted) {
|
|
62
165
|
if (!meeting) {
|
|
63
166
|
return _promise.default.reject(new _parameter.default('You need a meeting object.'));
|
|
@@ -201,6 +304,7 @@ var MeetingUtil = {
|
|
|
201
304
|
locale: options.locale,
|
|
202
305
|
deviceCapabilities: options.deviceCapabilities,
|
|
203
306
|
liveAnnotationSupported: options.liveAnnotationSupported,
|
|
307
|
+
enableSimultaneousInterpretation: options.enableSimultaneousInterpretation,
|
|
204
308
|
clientMediaPreferences: clientMediaPreferences,
|
|
205
309
|
alias: options.alias
|
|
206
310
|
}).then(function (res) {
|
|
@@ -208,13 +312,15 @@ var MeetingUtil = {
|
|
|
208
312
|
var parsed = MeetingUtil.parseLocusJoin(res);
|
|
209
313
|
meeting.setLocus(parsed);
|
|
210
314
|
meeting.isoLocalClientMeetingJoinTime = res === null || res === void 0 ? void 0 : (_res$headers = res.headers) === null || _res$headers === void 0 ? void 0 : _res$headers.date; // read from header if exist, else fall back to system clock : https://jira-eng-gpk2.cisco.com/jira/browse/SPARK-555657
|
|
315
|
+
var socketUrlInfo = MeetingUtil.getSocketUrlInfo(webex);
|
|
211
316
|
webex.internal.newMetrics.submitClientEvent({
|
|
212
317
|
name: 'client.locus.join.response',
|
|
213
318
|
payload: {
|
|
214
319
|
trigger: 'loci-update',
|
|
215
320
|
identifiers: {
|
|
216
321
|
trackingId: res.headers.trackingid
|
|
217
|
-
}
|
|
322
|
+
},
|
|
323
|
+
eventData: _objectSpread({}, socketUrlInfo)
|
|
218
324
|
},
|
|
219
325
|
options: {
|
|
220
326
|
meetingId: meeting.id,
|
|
@@ -224,12 +330,14 @@ var MeetingUtil = {
|
|
|
224
330
|
return parsed;
|
|
225
331
|
}).catch(function (err) {
|
|
226
332
|
var _meeting$meetingInfo2;
|
|
333
|
+
var socketUrlInfo = MeetingUtil.getSocketUrlInfo(webex);
|
|
227
334
|
webex.internal.newMetrics.submitClientEvent({
|
|
228
335
|
name: 'client.locus.join.response',
|
|
229
336
|
payload: {
|
|
230
337
|
identifiers: {
|
|
231
338
|
meetingLookupUrl: (_meeting$meetingInfo2 = meeting.meetingInfo) === null || _meeting$meetingInfo2 === void 0 ? void 0 : _meeting$meetingInfo2.meetingLookupUrl
|
|
232
|
-
}
|
|
339
|
+
},
|
|
340
|
+
eventData: _objectSpread({}, socketUrlInfo)
|
|
233
341
|
},
|
|
234
342
|
options: {
|
|
235
343
|
meetingId: meeting.id,
|
|
@@ -254,7 +362,9 @@ var MeetingUtil = {
|
|
|
254
362
|
meeting.getWebexObject().internal.device.meetingEnded();
|
|
255
363
|
meeting.stopPeriodicLogUpload();
|
|
256
364
|
meeting.breakouts.cleanUp();
|
|
365
|
+
meeting.webinar.cleanUp();
|
|
257
366
|
meeting.simultaneousInterpretation.cleanUp();
|
|
367
|
+
meeting.locusInfo.cleanUp();
|
|
258
368
|
meeting.locusMediaRequest = undefined;
|
|
259
369
|
(_meeting$webex = meeting.webex) === null || _meeting$webex === void 0 ? void 0 : (_meeting$webex$intern = _meeting$webex.internal) === null || _meeting$webex$intern === void 0 ? void 0 : (_meeting$webex$intern2 = _meeting$webex$intern.newMetrics) === null || _meeting$webex$intern2 === void 0 ? void 0 : (_meeting$webex$intern3 = _meeting$webex$intern2.callDiagnosticMetrics) === null || _meeting$webex$intern3 === void 0 ? void 0 : _meeting$webex$intern3.clearEventLimitsForCorrelationId(meeting.correlationId);
|
|
260
370
|
|
|
@@ -274,8 +384,11 @@ var MeetingUtil = {
|
|
|
274
384
|
}).then(function () {
|
|
275
385
|
var _meeting$config;
|
|
276
386
|
if ((_meeting$config = meeting.config) !== null && _meeting$config !== void 0 && _meeting$config.enableAutomaticLLM) {
|
|
277
|
-
meeting.
|
|
387
|
+
return meeting.cleanupLLMConneciton({
|
|
388
|
+
throwOnError: false
|
|
389
|
+
});
|
|
278
390
|
}
|
|
391
|
+
return undefined;
|
|
279
392
|
});
|
|
280
393
|
},
|
|
281
394
|
disconnectPhoneAudio: function disconnectPhoneAudio(meeting, phoneUrl) {
|
|
@@ -515,6 +628,9 @@ var MeetingUtil = {
|
|
|
515
628
|
bothLeaveAndEndMeetingAvailable: function bothLeaveAndEndMeetingAvailable(displayHints) {
|
|
516
629
|
return displayHints.includes(_constants.DISPLAY_HINTS.LEAVE_TRANSFER_HOST_END_MEETING) || displayHints.includes(_constants.DISPLAY_HINTS.LEAVE_END_MEETING);
|
|
517
630
|
},
|
|
631
|
+
requireHostEndMeetingBeforeLeave: function requireHostEndMeetingBeforeLeave(displayHints) {
|
|
632
|
+
return displayHints.includes(_constants.DISPLAY_HINTS.REQUIRE_HOST_END_MEETING_BEFORE_LEAVE) || !displayHints.includes(_constants.DISPLAY_HINTS.LEAVE_TRANSFER_HOST_END_MEETING) && displayHints.includes(_constants.DISPLAY_HINTS.END_MEETING);
|
|
633
|
+
},
|
|
518
634
|
canManageBreakout: function canManageBreakout(displayHints) {
|
|
519
635
|
return displayHints.includes(_constants.DISPLAY_HINTS.BREAKOUT_MANAGEMENT);
|
|
520
636
|
},
|
|
@@ -687,6 +803,18 @@ var MeetingUtil = {
|
|
|
687
803
|
}
|
|
688
804
|
requestBody.sequence = sequence;
|
|
689
805
|
},
|
|
806
|
+
/**
|
|
807
|
+
* Checks if Locus API response contains a Locus DTO
|
|
808
|
+
*
|
|
809
|
+
* @param {any} response http response from Locus API call
|
|
810
|
+
* @returns {boolean} true if response contains a Locus DTO
|
|
811
|
+
*/
|
|
812
|
+
isLocusDtoInAPIResponse: function isLocusDtoInAPIResponse(response) {
|
|
813
|
+
var _response$body, _response$body2;
|
|
814
|
+
return (response === null || response === void 0 ? void 0 : (_response$body = response.body) === null || _response$body === void 0 ? void 0 : _response$body.locus) || (// for APIs called on our participant - locus is one of props in the response body
|
|
815
|
+
response === null || response === void 0 ? void 0 : (_response$body2 = response.body) === null || _response$body2 === void 0 ? void 0 : _response$body2.url) // for APIs that act on locus itself (like mute all), the body is the locus
|
|
816
|
+
;
|
|
817
|
+
},
|
|
690
818
|
/**
|
|
691
819
|
* Updates the locus info for the meeting with the locus
|
|
692
820
|
* information returned from API requests made to Locus
|
|
@@ -696,11 +824,12 @@ var MeetingUtil = {
|
|
|
696
824
|
* @returns {Object}
|
|
697
825
|
*/
|
|
698
826
|
updateLocusFromApiResponse: function updateLocusFromApiResponse(meeting, response) {
|
|
699
|
-
var _response$body;
|
|
700
827
|
if (!meeting) {
|
|
701
828
|
return response;
|
|
702
829
|
}
|
|
703
|
-
|
|
830
|
+
|
|
831
|
+
// locus API responses can come in different shapes:
|
|
832
|
+
if (MeetingUtil.isLocusDtoInAPIResponse(response)) {
|
|
704
833
|
meeting.locusInfo.handleLocusAPIResponse(meeting, response.body);
|
|
705
834
|
}
|
|
706
835
|
return response;
|
|
@@ -731,11 +860,45 @@ var MeetingUtil = {
|
|
|
731
860
|
}
|
|
732
861
|
var options = buildLocusDeltaRequestOptions(originalOptions);
|
|
733
862
|
return meeting.request(options).then(function (response) {
|
|
863
|
+
var requestUri = options === null || options === void 0 ? void 0 : options.uri;
|
|
864
|
+
var meetingLocusUrl = meeting.locusUrl;
|
|
865
|
+
if (!requestUri || !meetingLocusUrl || !requestUri.startsWith(meetingLocusUrl)) {
|
|
866
|
+
_loggerProxy.default.logger.info("Meeting:util#generateLocusDeltaRequest --> skipping updateLocusFromApiResponse, request uri \"".concat(requestUri, "\" does not match meeting locusUrl \"").concat(meetingLocusUrl, "\""));
|
|
867
|
+
return response;
|
|
868
|
+
}
|
|
734
869
|
return MeetingUtil.updateLocusFromApiResponse(meeting, response);
|
|
735
870
|
});
|
|
736
871
|
};
|
|
737
872
|
return locusDeltaRequest;
|
|
738
873
|
},
|
|
874
|
+
canAttendeeRequestAiAssistantEnabled: function canAttendeeRequestAiAssistantEnabled() {
|
|
875
|
+
var displayHints = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];
|
|
876
|
+
var roles = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [];
|
|
877
|
+
var isHostOrCoHost = roles.includes(_types.ServerRoles.Cohost) || roles.includes(_types.ServerRoles.Moderator);
|
|
878
|
+
if (isHostOrCoHost) {
|
|
879
|
+
return false;
|
|
880
|
+
}
|
|
881
|
+
if (displayHints.includes(_constants.DISPLAY_HINTS.ATTENDEE_REQUEST_AI_ASSISTANT_ENABLED)) {
|
|
882
|
+
return true;
|
|
883
|
+
}
|
|
884
|
+
return false;
|
|
885
|
+
},
|
|
886
|
+
attendeeRequestAiAssistantDeclinedAll: function attendeeRequestAiAssistantDeclinedAll() {
|
|
887
|
+
var displayHints = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];
|
|
888
|
+
return displayHints.includes(_constants.DISPLAY_HINTS.ATTENDEE_REQUEST_AI_ASSISTANT_DECLINED_ALL);
|
|
889
|
+
},
|
|
890
|
+
isAnonymizeDisplayNamesEnabled: function isAnonymizeDisplayNamesEnabled(displayHints) {
|
|
891
|
+
return displayHints.includes(_constants.DISPLAY_HINTS.ANONYMOUS_DISPLAY_NAMES_ENABLED);
|
|
892
|
+
},
|
|
893
|
+
canViewTheParticipantList: function canViewTheParticipantList(displayHints, canNotViewTheParticipantList) {
|
|
894
|
+
if (!displayHints.includes(_constants.DISPLAY_HINTS.VIEW_THE_PARTICIPANT_LIST)) {
|
|
895
|
+
return false;
|
|
896
|
+
}
|
|
897
|
+
if (canNotViewTheParticipantList) {
|
|
898
|
+
return false;
|
|
899
|
+
}
|
|
900
|
+
return displayHints.includes(_constants.DISPLAY_HINTS.CAN_VIEW_THE_PARTICIPANT_LIST);
|
|
901
|
+
},
|
|
739
902
|
selfSupportsFeature: function selfSupportsFeature(feature, userPolicies) {
|
|
740
903
|
if (!userPolicies) {
|
|
741
904
|
return true;
|