@webex/plugin-meetings 3.8.1 → 3.9.0-multiple-llm.2

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 (319) hide show
  1. package/README.md +26 -13
  2. package/dist/breakouts/breakout.js +1 -1
  3. package/dist/breakouts/index.js +1 -1
  4. package/dist/constants.js +34 -3
  5. package/dist/constants.js.map +1 -1
  6. package/dist/controls-options-manager/enums.js +1 -0
  7. package/dist/controls-options-manager/enums.js.map +1 -1
  8. package/dist/controls-options-manager/types.js.map +1 -1
  9. package/dist/controls-options-manager/util.js +26 -0
  10. package/dist/controls-options-manager/util.js.map +1 -1
  11. package/dist/interpretation/index.js +1 -1
  12. package/dist/interpretation/siLanguage.js +1 -1
  13. package/dist/locus-info/controlsUtils.js +11 -3
  14. package/dist/locus-info/controlsUtils.js.map +1 -1
  15. package/dist/locus-info/index.js +107 -95
  16. package/dist/locus-info/index.js.map +1 -1
  17. package/dist/locus-info/parser.js +4 -1
  18. package/dist/locus-info/parser.js.map +1 -1
  19. package/dist/media/index.js +2 -2
  20. package/dist/media/index.js.map +1 -1
  21. package/dist/media/properties.js +53 -5
  22. package/dist/media/properties.js.map +1 -1
  23. package/dist/meeting/brbState.js +17 -14
  24. package/dist/meeting/brbState.js.map +1 -1
  25. package/dist/meeting/in-meeting-actions.js +13 -1
  26. package/dist/meeting/in-meeting-actions.js.map +1 -1
  27. package/dist/meeting/index.js +555 -296
  28. package/dist/meeting/index.js.map +1 -1
  29. package/dist/meeting/muteState.js +2 -5
  30. package/dist/meeting/muteState.js.map +1 -1
  31. package/dist/meeting/request.js +44 -0
  32. package/dist/meeting/request.js.map +1 -1
  33. package/dist/meeting/request.type.js.map +1 -1
  34. package/dist/{rtcMetrics/constants.js → meeting/type.js} +1 -5
  35. package/dist/meeting/type.js.map +1 -0
  36. package/dist/meeting/util.js +98 -13
  37. package/dist/meeting/util.js.map +1 -1
  38. package/dist/meeting-info/meeting-info-v2.js +29 -21
  39. package/dist/meeting-info/meeting-info-v2.js.map +1 -1
  40. package/dist/meetings/index.js +18 -10
  41. package/dist/meetings/index.js.map +1 -1
  42. package/dist/member/types.js.map +1 -1
  43. package/dist/members/collection.js +13 -0
  44. package/dist/members/collection.js.map +1 -1
  45. package/dist/members/index.js +53 -29
  46. package/dist/members/index.js.map +1 -1
  47. package/dist/members/request.js +3 -3
  48. package/dist/members/request.js.map +1 -1
  49. package/dist/members/util.js +25 -8
  50. package/dist/members/util.js.map +1 -1
  51. package/dist/metrics/constants.js +3 -1
  52. package/dist/metrics/constants.js.map +1 -1
  53. package/dist/multistream/mediaRequestManager.js +1 -1
  54. package/dist/multistream/mediaRequestManager.js.map +1 -1
  55. package/dist/multistream/remoteMedia.js +34 -5
  56. package/dist/multistream/remoteMedia.js.map +1 -1
  57. package/dist/multistream/remoteMediaGroup.js +42 -2
  58. package/dist/multistream/remoteMediaGroup.js.map +1 -1
  59. package/dist/multistream/sendSlotManager.js +32 -2
  60. package/dist/multistream/sendSlotManager.js.map +1 -1
  61. package/dist/reachability/index.js +8 -13
  62. package/dist/reachability/index.js.map +1 -1
  63. package/dist/types/constants.d.ts +30 -0
  64. package/dist/types/controls-options-manager/enums.d.ts +2 -1
  65. package/dist/types/controls-options-manager/types.d.ts +4 -1
  66. package/dist/types/locus-info/index.d.ts +54 -10
  67. package/dist/types/media/properties.d.ts +21 -0
  68. package/dist/types/meeting/brbState.d.ts +0 -1
  69. package/dist/types/meeting/in-meeting-actions.d.ts +12 -0
  70. package/dist/types/meeting/index.d.ts +58 -20
  71. package/dist/types/meeting/request.d.ts +18 -1
  72. package/dist/types/meeting/request.type.d.ts +74 -0
  73. package/dist/types/meeting/type.d.ts +9 -0
  74. package/dist/types/meeting/util.d.ts +13 -3
  75. package/dist/types/meeting-info/meeting-info-v2.d.ts +6 -3
  76. package/dist/types/meetings/index.d.ts +3 -1
  77. package/dist/types/member/types.d.ts +1 -0
  78. package/dist/types/members/collection.d.ts +6 -0
  79. package/dist/types/members/index.d.ts +22 -9
  80. package/dist/types/members/request.d.ts +1 -1
  81. package/dist/types/members/util.d.ts +13 -6
  82. package/dist/types/metrics/constants.d.ts +2 -0
  83. package/dist/types/multistream/remoteMedia.d.ts +20 -1
  84. package/dist/types/multistream/remoteMediaGroup.d.ts +11 -0
  85. package/dist/types/multistream/sendSlotManager.d.ts +16 -0
  86. package/dist/types/reachability/index.d.ts +2 -2
  87. package/dist/webinar/index.js +1 -1
  88. package/package.json +25 -26
  89. package/src/constants.ts +34 -2
  90. package/src/controls-options-manager/enums.ts +1 -0
  91. package/src/controls-options-manager/types.ts +6 -1
  92. package/src/controls-options-manager/util.ts +31 -0
  93. package/src/locus-info/controlsUtils.ts +15 -0
  94. package/src/locus-info/index.ts +174 -96
  95. package/src/locus-info/parser.ts +5 -1
  96. package/src/media/index.ts +2 -2
  97. package/src/media/properties.ts +43 -0
  98. package/src/meeting/brbState.ts +13 -9
  99. package/src/meeting/in-meeting-actions.ts +25 -0
  100. package/src/meeting/index.ts +362 -75
  101. package/src/meeting/muteState.ts +2 -6
  102. package/src/meeting/request.ts +39 -0
  103. package/src/meeting/request.type.ts +64 -0
  104. package/src/meeting/type.ts +9 -0
  105. package/src/meeting/util.ts +114 -22
  106. package/src/meeting-info/meeting-info-v2.ts +24 -5
  107. package/src/meetings/index.ts +12 -5
  108. package/src/member/types.ts +1 -0
  109. package/src/members/collection.ts +11 -0
  110. package/src/members/index.ts +51 -15
  111. package/src/members/request.ts +2 -2
  112. package/src/members/util.ts +34 -6
  113. package/src/metrics/constants.ts +2 -0
  114. package/src/multistream/mediaRequestManager.ts +7 -7
  115. package/src/multistream/remoteMedia.ts +34 -4
  116. package/src/multistream/remoteMediaGroup.ts +37 -2
  117. package/src/multistream/sendSlotManager.ts +34 -2
  118. package/src/reachability/index.ts +8 -16
  119. package/test/unit/spec/common/browser-detection.js +0 -24
  120. package/test/unit/spec/controls-options-manager/util.js +58 -0
  121. package/test/unit/spec/locus-info/controlsUtils.js +52 -0
  122. package/test/unit/spec/locus-info/index.js +270 -97
  123. package/test/unit/spec/locus-info/parser.js +3 -2
  124. package/test/unit/spec/media/index.ts +107 -0
  125. package/test/unit/spec/media/properties.ts +137 -0
  126. package/test/unit/spec/meeting/brbState.ts +23 -4
  127. package/test/unit/spec/meeting/in-meeting-actions.ts +12 -0
  128. package/test/unit/spec/meeting/index.js +1194 -97
  129. package/test/unit/spec/meeting/muteState.js +32 -6
  130. package/test/unit/spec/meeting/request.js +92 -0
  131. package/test/unit/spec/meeting/utils.js +167 -17
  132. package/test/unit/spec/meeting-info/meetinginfov2.js +8 -3
  133. package/test/unit/spec/meetings/index.js +12 -5
  134. package/test/unit/spec/members/collection.js +120 -0
  135. package/test/unit/spec/members/index.js +140 -12
  136. package/test/unit/spec/members/request.js +57 -2
  137. package/test/unit/spec/members/utils.js +139 -17
  138. package/test/unit/spec/multistream/mediaRequestManager.ts +19 -6
  139. package/test/unit/spec/multistream/remoteMedia.ts +66 -2
  140. package/test/unit/spec/multistream/sendSlotManager.ts +59 -0
  141. package/test/unit/spec/reachability/index.ts +160 -9
  142. package/test/unit/spec/roap/turnDiscovery.ts +3 -3
  143. package/dist/annotation/annotation.types.d.ts +0 -42
  144. package/dist/annotation/constants.d.ts +0 -31
  145. package/dist/annotation/index.d.ts +0 -117
  146. package/dist/breakouts/breakout.d.ts +0 -8
  147. package/dist/breakouts/collection.d.ts +0 -5
  148. package/dist/breakouts/edit-lock-error.d.ts +0 -15
  149. package/dist/breakouts/events.d.ts +0 -8
  150. package/dist/breakouts/index.d.ts +0 -5
  151. package/dist/breakouts/request.d.ts +0 -22
  152. package/dist/breakouts/utils.d.ts +0 -15
  153. package/dist/common/browser-detection.d.ts +0 -9
  154. package/dist/common/collection.d.ts +0 -48
  155. package/dist/common/config.d.ts +0 -2
  156. package/dist/common/errors/captcha-error.d.ts +0 -15
  157. package/dist/common/errors/intent-to-join.d.ts +0 -16
  158. package/dist/common/errors/join-meeting.d.ts +0 -17
  159. package/dist/common/errors/media.d.ts +0 -15
  160. package/dist/common/errors/no-meeting-info.d.ts +0 -14
  161. package/dist/common/errors/parameter.d.ts +0 -15
  162. package/dist/common/errors/password-error.d.ts +0 -15
  163. package/dist/common/errors/permission.d.ts +0 -14
  164. package/dist/common/errors/reclaim-host-role-error.d.ts +0 -60
  165. package/dist/common/errors/reclaim-host-role-error.js +0 -158
  166. package/dist/common/errors/reclaim-host-role-error.js.map +0 -1
  167. package/dist/common/errors/reclaim-host-role-errors.d.ts +0 -60
  168. package/dist/common/errors/reconnection-in-progress.d.ts +0 -9
  169. package/dist/common/errors/reconnection-in-progress.js +0 -35
  170. package/dist/common/errors/reconnection-in-progress.js.map +0 -1
  171. package/dist/common/errors/reconnection.d.ts +0 -15
  172. package/dist/common/errors/stats.d.ts +0 -15
  173. package/dist/common/errors/webex-errors.d.ts +0 -81
  174. package/dist/common/errors/webex-meetings-error.d.ts +0 -20
  175. package/dist/common/events/events-scope.d.ts +0 -17
  176. package/dist/common/events/events.d.ts +0 -12
  177. package/dist/common/events/trigger-proxy.d.ts +0 -2
  178. package/dist/common/events/util.d.ts +0 -2
  179. package/dist/common/logs/logger-config.d.ts +0 -2
  180. package/dist/common/logs/logger-proxy.d.ts +0 -2
  181. package/dist/common/logs/request.d.ts +0 -34
  182. package/dist/common/queue.d.ts +0 -32
  183. package/dist/config.d.ts +0 -73
  184. package/dist/constants.d.ts +0 -952
  185. package/dist/controls-options-manager/constants.d.ts +0 -4
  186. package/dist/controls-options-manager/enums.d.ts +0 -5
  187. package/dist/controls-options-manager/index.d.ts +0 -120
  188. package/dist/controls-options-manager/types.d.ts +0 -43
  189. package/dist/controls-options-manager/util.d.ts +0 -7
  190. package/dist/index.d.ts +0 -4
  191. package/dist/interceptors/index.d.ts +0 -2
  192. package/dist/interceptors/locusRetry.d.ts +0 -27
  193. package/dist/interpretation/collection.d.ts +0 -5
  194. package/dist/interpretation/index.d.ts +0 -5
  195. package/dist/interpretation/siLanguage.d.ts +0 -5
  196. package/dist/locus-info/controlsUtils.d.ts +0 -2
  197. package/dist/locus-info/embeddedAppsUtils.d.ts +0 -2
  198. package/dist/locus-info/fullState.d.ts +0 -2
  199. package/dist/locus-info/hostUtils.d.ts +0 -2
  200. package/dist/locus-info/index.d.ts +0 -269
  201. package/dist/locus-info/infoUtils.d.ts +0 -2
  202. package/dist/locus-info/mediaSharesUtils.d.ts +0 -2
  203. package/dist/locus-info/parser.d.ts +0 -212
  204. package/dist/locus-info/selfUtils.d.ts +0 -2
  205. package/dist/media/index.d.ts +0 -32
  206. package/dist/media/properties.d.ts +0 -108
  207. package/dist/media/util.d.ts +0 -2
  208. package/dist/mediaQualityMetrics/config.d.ts +0 -233
  209. package/dist/mediaQualityMetrics/config.js +0 -513
  210. package/dist/mediaQualityMetrics/config.js.map +0 -1
  211. package/dist/meeting/effectsState.d.ts +0 -42
  212. package/dist/meeting/effectsState.js +0 -260
  213. package/dist/meeting/effectsState.js.map +0 -1
  214. package/dist/meeting/in-meeting-actions.d.ts +0 -79
  215. package/dist/meeting/index.d.ts +0 -1622
  216. package/dist/meeting/locusMediaRequest.d.ts +0 -74
  217. package/dist/meeting/muteState.d.ts +0 -116
  218. package/dist/meeting/request.d.ts +0 -257
  219. package/dist/meeting/request.type.d.ts +0 -11
  220. package/dist/meeting/state.d.ts +0 -9
  221. package/dist/meeting/util.d.ts +0 -2
  222. package/dist/meeting/voicea-meeting.d.ts +0 -16
  223. package/dist/meeting-info/collection.d.ts +0 -20
  224. package/dist/meeting-info/index.d.ts +0 -57
  225. package/dist/meeting-info/meeting-info-v2.d.ts +0 -93
  226. package/dist/meeting-info/request.d.ts +0 -22
  227. package/dist/meeting-info/util.d.ts +0 -2
  228. package/dist/meeting-info/utilv2.d.ts +0 -2
  229. package/dist/meetings/collection.d.ts +0 -23
  230. package/dist/meetings/index.d.ts +0 -296
  231. package/dist/meetings/meetings.types.d.ts +0 -4
  232. package/dist/meetings/request.d.ts +0 -27
  233. package/dist/meetings/util.d.ts +0 -18
  234. package/dist/member/index.d.ts +0 -148
  235. package/dist/member/member.types.d.ts +0 -11
  236. package/dist/member/member.types.js +0 -18
  237. package/dist/member/member.types.js.map +0 -1
  238. package/dist/member/types.d.ts +0 -32
  239. package/dist/member/util.d.ts +0 -2
  240. package/dist/members/collection.d.ts +0 -24
  241. package/dist/members/index.d.ts +0 -308
  242. package/dist/members/request.d.ts +0 -58
  243. package/dist/members/types.d.ts +0 -25
  244. package/dist/members/util.d.ts +0 -2
  245. package/dist/metrics/config.d.ts +0 -169
  246. package/dist/metrics/config.js +0 -289
  247. package/dist/metrics/config.js.map +0 -1
  248. package/dist/metrics/constants.d.ts +0 -59
  249. package/dist/metrics/index.d.ts +0 -152
  250. package/dist/multistream/mediaRequestManager.d.ts +0 -119
  251. package/dist/multistream/receiveSlot.d.ts +0 -68
  252. package/dist/multistream/receiveSlotManager.d.ts +0 -56
  253. package/dist/multistream/remoteMedia.d.ts +0 -72
  254. package/dist/multistream/remoteMediaGroup.d.ts +0 -49
  255. package/dist/multistream/remoteMediaManager.d.ts +0 -300
  256. package/dist/multistream/sendSlotManager.d.ts +0 -69
  257. package/dist/networkQualityMonitor/index.d.ts +0 -70
  258. package/dist/networkQualityMonitor/index.js +0 -226
  259. package/dist/networkQualityMonitor/index.js.map +0 -1
  260. package/dist/peer-connection-manager/index.d.ts +0 -6
  261. package/dist/peer-connection-manager/index.js +0 -671
  262. package/dist/peer-connection-manager/index.js.map +0 -1
  263. package/dist/peer-connection-manager/util.d.ts +0 -6
  264. package/dist/peer-connection-manager/util.js +0 -110
  265. package/dist/peer-connection-manager/util.js.map +0 -1
  266. package/dist/personal-meeting-room/index.d.ts +0 -47
  267. package/dist/personal-meeting-room/request.d.ts +0 -14
  268. package/dist/personal-meeting-room/util.d.ts +0 -2
  269. package/dist/reachability/clusterReachability.d.ts +0 -109
  270. package/dist/reachability/index.d.ts +0 -139
  271. package/dist/reachability/request.d.ts +0 -35
  272. package/dist/reachability/util.d.ts +0 -8
  273. package/dist/reactions/constants.d.ts +0 -3
  274. package/dist/reactions/reactions.d.ts +0 -4
  275. package/dist/reactions/reactions.type.d.ts +0 -32
  276. package/dist/reconnection-manager/index.d.ts +0 -112
  277. package/dist/recording-controller/enums.d.ts +0 -7
  278. package/dist/recording-controller/index.d.ts +0 -193
  279. package/dist/recording-controller/util.d.ts +0 -13
  280. package/dist/roap/collection.d.ts +0 -10
  281. package/dist/roap/collection.js +0 -63
  282. package/dist/roap/collection.js.map +0 -1
  283. package/dist/roap/handler.d.ts +0 -47
  284. package/dist/roap/handler.js +0 -279
  285. package/dist/roap/handler.js.map +0 -1
  286. package/dist/roap/index.d.ts +0 -116
  287. package/dist/roap/request.d.ts +0 -35
  288. package/dist/roap/state.d.ts +0 -9
  289. package/dist/roap/state.js +0 -127
  290. package/dist/roap/state.js.map +0 -1
  291. package/dist/roap/turnDiscovery.d.ts +0 -81
  292. package/dist/roap/util.d.ts +0 -2
  293. package/dist/roap/util.js +0 -76
  294. package/dist/roap/util.js.map +0 -1
  295. package/dist/rtcMetrics/constants.d.ts +0 -4
  296. package/dist/rtcMetrics/constants.js.map +0 -1
  297. package/dist/rtcMetrics/index.d.ts +0 -61
  298. package/dist/rtcMetrics/index.js +0 -197
  299. package/dist/rtcMetrics/index.js.map +0 -1
  300. package/dist/statsAnalyzer/global.d.ts +0 -118
  301. package/dist/statsAnalyzer/global.js +0 -127
  302. package/dist/statsAnalyzer/global.js.map +0 -1
  303. package/dist/statsAnalyzer/index.d.ts +0 -193
  304. package/dist/statsAnalyzer/index.js +0 -1019
  305. package/dist/statsAnalyzer/index.js.map +0 -1
  306. package/dist/statsAnalyzer/mqaUtil.d.ts +0 -22
  307. package/dist/statsAnalyzer/mqaUtil.js +0 -181
  308. package/dist/statsAnalyzer/mqaUtil.js.map +0 -1
  309. package/dist/transcription/index.d.ts +0 -64
  310. package/dist/types/common/errors/reconnection-in-progress.d.ts +0 -9
  311. package/dist/types/mediaQualityMetrics/config.d.ts +0 -241
  312. package/dist/types/networkQualityMonitor/index.d.ts +0 -70
  313. package/dist/types/rtcMetrics/constants.d.ts +0 -4
  314. package/dist/types/rtcMetrics/index.d.ts +0 -71
  315. package/dist/types/statsAnalyzer/global.d.ts +0 -36
  316. package/dist/types/statsAnalyzer/index.d.ts +0 -217
  317. package/dist/types/statsAnalyzer/mqaUtil.d.ts +0 -48
  318. package/dist/webinar/collection.d.ts +0 -16
  319. package/dist/webinar/index.d.ts +0 -5
@@ -382,10 +382,11 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
382
382
  /**
383
383
  * @param {Object} attrs
384
384
  * @param {Object} options
385
+ * @param {Function} callback - if provided, it will be called with the newly created meeting object as soon as the meeting.id is set
385
386
  * @constructor
386
387
  * @memberof Meeting
387
388
  */
388
- function Meeting(attrs, _options) {
389
+ function Meeting(attrs, _options, callback) {
389
390
  var _attrs$callStateForMe, _attrs$callStateForMe2, _this$locusInfo, _this$locusInfo$links, _this$locusInfo$links2, _this$locusInfo$links3, _this$locusInfo2, _this$locusInfo2$full, _this$locusInfo3, _this$locusInfo4;
390
391
  var _this;
391
392
  (0, _classCallCheck2.default)(this, Meeting);
@@ -475,6 +476,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
475
476
  (0, _defineProperty3.default)((0, _assertThisInitialized2.default)(_this), "shareStatus", void 0);
476
477
  (0, _defineProperty3.default)((0, _assertThisInitialized2.default)(_this), "screenShareFloorState", void 0);
477
478
  (0, _defineProperty3.default)((0, _assertThisInitialized2.default)(_this), "statsAnalyzer", void 0);
479
+ (0, _defineProperty3.default)((0, _assertThisInitialized2.default)(_this), "statsMonitor", void 0);
478
480
  (0, _defineProperty3.default)((0, _assertThisInitialized2.default)(_this), "transcription", void 0);
479
481
  (0, _defineProperty3.default)((0, _assertThisInitialized2.default)(_this), "updateMediaConnections", void 0);
480
482
  (0, _defineProperty3.default)((0, _assertThisInitialized2.default)(_this), "userDisplayHints", void 0);
@@ -947,6 +949,10 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
947
949
  // @ts-ignore
948
950
  _this.webex.internal.newMetrics.submitClientEvent({
949
951
  name: 'client.ice.start',
952
+ payload: {
953
+ // @ts-ignore
954
+ labels: _util2.default.getCaEventLabelsForIpVersion(_this.webex)
955
+ },
950
956
  options: {
951
957
  meetingId: _this.id
952
958
  }
@@ -1071,10 +1077,10 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
1071
1077
  }
1072
1078
  }
1073
1079
 
1074
- // Count members that are in the meeting.
1080
+ // Count members that are in the meeting or in the lobby.
1075
1081
  var members = _this.getMembers().membersCollection.members;
1076
1082
  event.data.intervalMetadata.meetingUserCount = (0, _values.default)(members).filter(function (member) {
1077
- return member.isInMeeting;
1083
+ return member.isInMeeting || member.isInLobby;
1078
1084
  }).length;
1079
1085
 
1080
1086
  // @ts-ignore
@@ -1489,6 +1495,10 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
1489
1495
  * @memberof Meeting
1490
1496
  */
1491
1497
  _this.id = _uuid.default.v4();
1498
+ if (callback) {
1499
+ callback((0, _assertThisInitialized2.default)(_this));
1500
+ }
1501
+
1492
1502
  /**
1493
1503
  * Call state used for metrics
1494
1504
  * @instance
@@ -1961,6 +1971,13 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
1961
1971
  * @memberof Meeting
1962
1972
  */
1963
1973
  _this.networkQualityMonitor = null;
1974
+ /**
1975
+ * @instance
1976
+ * @type {StatsMonitor}
1977
+ * @private
1978
+ * @memberof Meeting
1979
+ */
1980
+ _this.statsMonitor = null;
1964
1981
  /**
1965
1982
  * Indicates network status of the webrtc media connection
1966
1983
  * @instance
@@ -2042,7 +2059,9 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
2042
2059
  captions: [],
2043
2060
  isListening: false,
2044
2061
  commandText: '',
2045
- languageOptions: {},
2062
+ languageOptions: {
2063
+ currentSpokenLanguage: 'en'
2064
+ },
2046
2065
  showCaptionBox: false,
2047
2066
  transcribingRequestStatus: 'INACTIVE',
2048
2067
  isCaptioning: false,
@@ -2375,6 +2394,24 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
2375
2394
  this.callStateForMetrics.correlationId = correlationId;
2376
2395
  }
2377
2396
 
2397
+ /**
2398
+ * Getter - Returns callStateForMetrics.pstnCorrelationId
2399
+ * @returns {string | undefined}
2400
+ */
2401
+ }, {
2402
+ key: "pstnCorrelationId",
2403
+ get: function get() {
2404
+ return this.callStateForMetrics.pstnCorrelationId;
2405
+ }
2406
+
2407
+ /**
2408
+ * Setter - sets callStateForMetrics.pstnCorrelationId
2409
+ * @param {string | undefined} correlationId
2410
+ */,
2411
+ set: function set(correlationId) {
2412
+ this.callStateForMetrics.pstnCorrelationId = correlationId;
2413
+ }
2414
+
2378
2415
  /**
2379
2416
  * Getter - Returns callStateForMetrics.userNameInput
2380
2417
  * @returns {string}
@@ -2576,11 +2613,11 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
2576
2613
  key: "fetchMeetingInfoInternal",
2577
2614
  value: (function () {
2578
2615
  var _fetchMeetingInfoInternal = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee5(_ref8) {
2579
- var destination, destinationType, _ref8$password, password, _ref8$captchaCode, captchaCode, _ref8$extraParams, extraParams, _ref8$sendCAevents, sendCAevents, _ref8$registrationId, registrationId, captchaInfo, info, _err$body, _err$body2;
2616
+ var destination, destinationType, _ref8$password, password, _ref8$captchaCode, captchaCode, _ref8$extraParams, extraParams, _ref8$sendCAevents, sendCAevents, _ref8$registrationId, registrationId, _ref8$classificationI, classificationId, captchaInfo, info, _err$body, _err$body2;
2580
2617
  return _regenerator.default.wrap(function _callee5$(_context5) {
2581
2618
  while (1) switch (_context5.prev = _context5.next) {
2582
2619
  case 0:
2583
- destination = _ref8.destination, destinationType = _ref8.destinationType, _ref8$password = _ref8.password, password = _ref8$password === void 0 ? null : _ref8$password, _ref8$captchaCode = _ref8.captchaCode, captchaCode = _ref8$captchaCode === void 0 ? null : _ref8$captchaCode, _ref8$extraParams = _ref8.extraParams, extraParams = _ref8$extraParams === void 0 ? {} : _ref8$extraParams, _ref8$sendCAevents = _ref8.sendCAevents, sendCAevents = _ref8$sendCAevents === void 0 ? false : _ref8$sendCAevents, _ref8$registrationId = _ref8.registrationId, registrationId = _ref8$registrationId === void 0 ? null : _ref8$registrationId;
2620
+ destination = _ref8.destination, destinationType = _ref8.destinationType, _ref8$password = _ref8.password, password = _ref8$password === void 0 ? null : _ref8$password, _ref8$captchaCode = _ref8.captchaCode, captchaCode = _ref8$captchaCode === void 0 ? null : _ref8$captchaCode, _ref8$extraParams = _ref8.extraParams, extraParams = _ref8$extraParams === void 0 ? {} : _ref8$extraParams, _ref8$sendCAevents = _ref8.sendCAevents, sendCAevents = _ref8$sendCAevents === void 0 ? false : _ref8$sendCAevents, _ref8$registrationId = _ref8.registrationId, registrationId = _ref8$registrationId === void 0 ? null : _ref8$registrationId, _ref8$classificationI = _ref8.classificationId, classificationId = _ref8$classificationI === void 0 ? null : _ref8$classificationI;
2584
2621
  _context5.prev = 1;
2585
2622
  captchaInfo = captchaCode ? {
2586
2623
  code: captchaCode,
@@ -2592,7 +2629,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
2592
2629
  this.config.installedOrgID, this.locusId, extraParams, {
2593
2630
  meetingId: this.id,
2594
2631
  sendCAevents: sendCAevents
2595
- }, registrationId);
2632
+ }, registrationId, null, classificationId);
2596
2633
  case 5:
2597
2634
  info = _context5.sent;
2598
2635
  this.parseMeetingInfo(info === null || info === void 0 ? void 0 : info.body, this.destination, info === null || info === void 0 ? void 0 : info.errors);
@@ -3400,8 +3437,26 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
3400
3437
  }
3401
3438
  }
3402
3439
  });
3403
- this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_MEETING_MANUAL_CAPTION_UPDATED, function (_ref12) {
3404
- var enable = _ref12.enable;
3440
+ this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_MEETING_TRANSCRIPTION_SPOKEN_LANGUAGE_UPDATED, function (_ref12) {
3441
+ var spokenLanguage = _ref12.spokenLanguage;
3442
+ if (spokenLanguage) {
3443
+ var _this14$transcription;
3444
+ if ((_this14$transcription = _this14.transcription) !== null && _this14$transcription !== void 0 && _this14$transcription.languageOptions) {
3445
+ _this14.transcription.languageOptions.currentSpokenLanguage = spokenLanguage;
3446
+ }
3447
+ // @ts-ignore
3448
+ _this14.webex.internal.voicea.onSpokenLanguageUpdate(spokenLanguage, _this14.id);
3449
+ _triggerProxy.default.trigger(_this14, {
3450
+ file: 'meeting/index',
3451
+ function: 'setupLocusControlsListener'
3452
+ }, _constants.EVENT_TRIGGERS.MEETING_TRANSCRIPTION_SPOKEN_LANGUAGE_UPDATED, {
3453
+ spokenLanguage: spokenLanguage,
3454
+ meetingId: _this14.id
3455
+ });
3456
+ }
3457
+ });
3458
+ this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_MEETING_MANUAL_CAPTION_UPDATED, function (_ref13) {
3459
+ var enable = _ref13.enable;
3405
3460
  _triggerProxy.default.trigger(_this14, {
3406
3461
  file: 'meeting/index',
3407
3462
  function: 'setupLocusControlsListener'
@@ -3409,24 +3464,24 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
3409
3464
  enable: enable
3410
3465
  });
3411
3466
  });
3412
- this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_MEETING_BREAKOUT_UPDATED, function (_ref13) {
3413
- var breakout = _ref13.breakout;
3467
+ this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_MEETING_BREAKOUT_UPDATED, function (_ref14) {
3468
+ var breakout = _ref14.breakout;
3414
3469
  _this14.breakouts.updateBreakout(breakout);
3415
3470
  _triggerProxy.default.trigger(_this14, {
3416
3471
  file: 'meeting/index',
3417
3472
  function: 'setupLocusControlsListener'
3418
3473
  }, _constants.EVENT_TRIGGERS.MEETING_BREAKOUTS_UPDATE);
3419
3474
  });
3420
- this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_MEETING_INTERPRETATION_UPDATED, function (_ref14) {
3421
- var interpretation = _ref14.interpretation;
3475
+ this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_MEETING_INTERPRETATION_UPDATED, function (_ref15) {
3476
+ var interpretation = _ref15.interpretation;
3422
3477
  _this14.simultaneousInterpretation.updateInterpretation(interpretation);
3423
3478
  _triggerProxy.default.trigger(_this14, {
3424
3479
  file: 'meeting/index',
3425
3480
  function: 'setupLocusControlsListener'
3426
3481
  }, _constants.EVENT_TRIGGERS.MEETING_INTERPRETATION_UPDATE);
3427
3482
  });
3428
- this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_ENTRY_EXIT_TONE_UPDATED, function (_ref15) {
3429
- var entryExitTone = _ref15.entryExitTone;
3483
+ this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_ENTRY_EXIT_TONE_UPDATED, function (_ref16) {
3484
+ var entryExitTone = _ref16.entryExitTone;
3430
3485
  _triggerProxy.default.trigger(_this14, {
3431
3486
  file: 'meeting/index',
3432
3487
  function: 'setupLocusControlsListener'
@@ -3434,8 +3489,8 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
3434
3489
  entryExitTone: entryExitTone
3435
3490
  });
3436
3491
  });
3437
- this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_MUTE_ON_ENTRY_CHANGED, function (_ref16) {
3438
- var state = _ref16.state;
3492
+ this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_MUTE_ON_ENTRY_CHANGED, function (_ref17) {
3493
+ var state = _ref17.state;
3439
3494
  _triggerProxy.default.trigger(_this14, {
3440
3495
  file: 'meeting/index',
3441
3496
  function: 'setupLocusControlsListener'
@@ -3443,8 +3498,8 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
3443
3498
  state: state
3444
3499
  });
3445
3500
  });
3446
- this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_SHARE_CONTROL_CHANGED, function (_ref17) {
3447
- var state = _ref17.state;
3501
+ this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_SHARE_CONTROL_CHANGED, function (_ref18) {
3502
+ var state = _ref18.state;
3448
3503
  _triggerProxy.default.trigger(_this14, {
3449
3504
  file: 'meeting/index',
3450
3505
  function: 'setupLocusControlsListener'
@@ -3452,8 +3507,8 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
3452
3507
  state: state
3453
3508
  });
3454
3509
  });
3455
- this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_DISALLOW_UNMUTE_CHANGED, function (_ref18) {
3456
- var state = _ref18.state;
3510
+ this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_DISALLOW_UNMUTE_CHANGED, function (_ref19) {
3511
+ var state = _ref19.state;
3457
3512
  _triggerProxy.default.trigger(_this14, {
3458
3513
  file: 'meeting/index',
3459
3514
  function: 'setupLocusControlsListener'
@@ -3461,8 +3516,8 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
3461
3516
  state: state
3462
3517
  });
3463
3518
  });
3464
- this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_REACTIONS_CHANGED, function (_ref19) {
3465
- var state = _ref19.state;
3519
+ this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_REACTIONS_CHANGED, function (_ref20) {
3520
+ var state = _ref20.state;
3466
3521
  _triggerProxy.default.trigger(_this14, {
3467
3522
  file: 'meeting/index',
3468
3523
  function: 'setupLocusControlsListener'
@@ -3470,8 +3525,8 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
3470
3525
  state: state
3471
3526
  });
3472
3527
  });
3473
- this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_VIEW_THE_PARTICIPANTS_LIST_CHANGED, function (_ref20) {
3474
- var state = _ref20.state;
3528
+ this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_VIEW_THE_PARTICIPANTS_LIST_CHANGED, function (_ref21) {
3529
+ var state = _ref21.state;
3475
3530
  _triggerProxy.default.trigger(_this14, {
3476
3531
  file: 'meeting/index',
3477
3532
  function: 'setupLocusControlsListener'
@@ -3479,8 +3534,8 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
3479
3534
  state: state
3480
3535
  });
3481
3536
  });
3482
- this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_RAISE_HAND_CHANGED, function (_ref21) {
3483
- var state = _ref21.state;
3537
+ this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_RAISE_HAND_CHANGED, function (_ref22) {
3538
+ var state = _ref22.state;
3484
3539
  _triggerProxy.default.trigger(_this14, {
3485
3540
  file: 'meeting/index',
3486
3541
  function: 'setupLocusControlsListener'
@@ -3488,8 +3543,8 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
3488
3543
  state: state
3489
3544
  });
3490
3545
  });
3491
- this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_WEBCAST_CHANGED, function (_ref22) {
3492
- var state = _ref22.state;
3546
+ this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_WEBCAST_CHANGED, function (_ref23) {
3547
+ var state = _ref23.state;
3493
3548
  _triggerProxy.default.trigger(_this14, {
3494
3549
  file: 'meeting/index',
3495
3550
  function: 'setupLocusControlsListener'
@@ -3497,8 +3552,8 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
3497
3552
  state: state
3498
3553
  });
3499
3554
  });
3500
- this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_MEETING_FULL_CHANGED, function (_ref23) {
3501
- var state = _ref23.state;
3555
+ this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_MEETING_FULL_CHANGED, function (_ref24) {
3556
+ var state = _ref24.state;
3502
3557
  _triggerProxy.default.trigger(_this14, {
3503
3558
  file: 'meeting/index',
3504
3559
  function: 'setupLocusControlsListener'
@@ -3506,8 +3561,8 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
3506
3561
  state: state
3507
3562
  });
3508
3563
  });
3509
- this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_PRACTICE_SESSION_STATUS_UPDATED, function (_ref24) {
3510
- var state = _ref24.state;
3564
+ this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_PRACTICE_SESSION_STATUS_UPDATED, function (_ref25) {
3565
+ var state = _ref25.state;
3511
3566
  _this14.webinar.updatePracticeSessionStatus(state);
3512
3567
  _triggerProxy.default.trigger(_this14, {
3513
3568
  file: 'meeting/index',
@@ -3516,8 +3571,8 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
3516
3571
  state: state
3517
3572
  });
3518
3573
  });
3519
- this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_STAGE_VIEW_UPDATED, function (_ref25) {
3520
- var state = _ref25.state;
3574
+ this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_STAGE_VIEW_UPDATED, function (_ref26) {
3575
+ var state = _ref26.state;
3521
3576
  _triggerProxy.default.trigger(_this14, {
3522
3577
  file: 'meeting/index',
3523
3578
  function: 'setupLocusControlsListener'
@@ -3525,8 +3580,8 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
3525
3580
  state: state
3526
3581
  });
3527
3582
  });
3528
- this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_VIDEO_CHANGED, function (_ref26) {
3529
- var state = _ref26.state;
3583
+ this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_VIDEO_CHANGED, function (_ref27) {
3584
+ var state = _ref27.state;
3530
3585
  _triggerProxy.default.trigger(_this14, {
3531
3586
  file: 'meeting/index',
3532
3587
  function: 'setupLocusControlsListener'
@@ -3534,8 +3589,8 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
3534
3589
  state: state
3535
3590
  });
3536
3591
  });
3537
- this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_ANNOTATION_CHANGED, function (_ref27) {
3538
- var state = _ref27.state;
3592
+ this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_ANNOTATION_CHANGED, function (_ref28) {
3593
+ var state = _ref28.state;
3539
3594
  _triggerProxy.default.trigger(_this14, {
3540
3595
  file: 'meeting/index',
3541
3596
  function: 'setupLocusControlsListener'
@@ -3543,8 +3598,8 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
3543
3598
  state: state
3544
3599
  });
3545
3600
  });
3546
- this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_REMOTE_DESKTOP_CONTROL_CHANGED, function (_ref28) {
3547
- var state = _ref28.state;
3601
+ this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_REMOTE_DESKTOP_CONTROL_CHANGED, function (_ref29) {
3602
+ var state = _ref29.state;
3548
3603
  _triggerProxy.default.trigger(_this14, {
3549
3604
  file: 'meeting/index',
3550
3605
  function: 'setupLocusControlsListener'
@@ -3552,6 +3607,15 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
3552
3607
  state: state
3553
3608
  });
3554
3609
  });
3610
+ this.locusInfo.on(_constants.LOCUSINFO.EVENTS.CONTROLS_POLLING_QA_CHANGED, function (_ref30) {
3611
+ var state = _ref30.state;
3612
+ _triggerProxy.default.trigger(_this14, {
3613
+ file: 'meeting/index',
3614
+ function: 'setupLocusControlsListener'
3615
+ }, _constants.EVENT_TRIGGERS.MEETING_CONTROLS_POLLING_QA_UPDATED, {
3616
+ state: state
3617
+ });
3618
+ });
3555
3619
  }
3556
3620
 
3557
3621
  /**
@@ -3591,7 +3655,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
3591
3655
  var _this15 = this;
3592
3656
  // Will get triggered on local and remote share
3593
3657
  this.locusInfo.on(_constants.EVENTS.LOCUS_INFO_UPDATE_MEDIA_SHARES, /*#__PURE__*/function () {
3594
- var _ref29 = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee8(payload) {
3658
+ var _ref31 = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee8(payload) {
3595
3659
  var _payload$previous, _payload$previous2;
3596
3660
  var _payload$current, contentShare, whiteboardShare, previousContentShare, previousWhiteboardShare, newShareStatus, _this15$locusInfo, _this15$locusInfo$inf, _this15$webinar, oldShareStatus, sendStartedSharingRemote, _this15$mediaProperti;
3597
3661
  return _regenerator.default.wrap(function _callee8$(_context8) {
@@ -3626,9 +3690,16 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
3626
3690
  // There is no concept of local/remote share for whiteboard
3627
3691
  // It does not matter who requested to share the whiteboard, everyone gets the same view
3628
3692
  else if (whiteboardShare.disposition === _constants.FLOOR_ACTION.GRANTED) {
3629
- // WHITEBOARD - sharing whiteboard
3630
- // Webinar attendee should receive whiteboard as remote share
3631
- newShareStatus = (_this15$locusInfo = _this15.locusInfo) !== null && _this15$locusInfo !== void 0 && (_this15$locusInfo$inf = _this15$locusInfo.info) !== null && _this15$locusInfo$inf !== void 0 && _this15$locusInfo$inf.isWebinar && (_this15$webinar = _this15.webinar) !== null && _this15$webinar !== void 0 && _this15$webinar.selfIsAttendee ? _constants.SHARE_STATUS.REMOTE_SHARE_ACTIVE : _constants.SHARE_STATUS.WHITEBOARD_SHARE_ACTIVE;
3693
+ if ((_this15$locusInfo = _this15.locusInfo) !== null && _this15$locusInfo !== void 0 && (_this15$locusInfo$inf = _this15$locusInfo.info) !== null && _this15$locusInfo$inf !== void 0 && _this15$locusInfo$inf.isWebinar && (_this15$webinar = _this15.webinar) !== null && _this15$webinar !== void 0 && _this15$webinar.selfIsAttendee) {
3694
+ // WHITEBOARD - sharing whiteboard
3695
+ // Webinar attendee should receive whiteboard as remote share
3696
+ newShareStatus = _constants.SHARE_STATUS.REMOTE_SHARE_ACTIVE;
3697
+ } else if (_this15.guest) {
3698
+ // If user is a guest to a meeting, they should receive whiteboard as remote share
3699
+ newShareStatus = _constants.SHARE_STATUS.REMOTE_SHARE_ACTIVE;
3700
+ } else {
3701
+ newShareStatus = _constants.SHARE_STATUS.WHITEBOARD_SHARE_ACTIVE;
3702
+ }
3632
3703
  }
3633
3704
  // or if content share is either released or null and whiteboard share is either released or null, no one is sharing
3634
3705
  else if ((previousContentShare && contentShare.disposition === _constants.FLOOR_ACTION.RELEASED || contentShare.disposition === null) && (previousWhiteboardShare && whiteboardShare.disposition === _constants.FLOOR_ACTION.RELEASED || whiteboardShare.disposition === null)) {
@@ -3636,7 +3707,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
3636
3707
  }
3637
3708
  _loggerProxy.default.logger.info("Meeting:index#setUpLocusInfoMediaInactiveListener --> this.shareStatus=".concat(_this15.shareStatus, " newShareStatus=").concat(newShareStatus));
3638
3709
  if (!(newShareStatus !== _this15.shareStatus)) {
3639
- _context8.next = 46;
3710
+ _context8.next = 48;
3640
3711
  break;
3641
3712
  }
3642
3713
  oldShareStatus = _this15.shareStatus; // update our state before we send out any notifications
@@ -3644,14 +3715,14 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
3644
3715
 
3645
3716
  // send out "stop" notifications for the old state
3646
3717
  _context8.t0 = oldShareStatus;
3647
- _context8.next = _context8.t0 === _constants.SHARE_STATUS.REMOTE_SHARE_ACTIVE ? 15 : _context8.t0 === _constants.SHARE_STATUS.LOCAL_SHARE_ACTIVE ? 17 : _context8.t0 === _constants.SHARE_STATUS.WHITEBOARD_SHARE_ACTIVE ? 19 : _context8.t0 === _constants.SHARE_STATUS.NO_SHARE ? 21 : 22;
3718
+ _context8.next = _context8.t0 === _constants.SHARE_STATUS.REMOTE_SHARE_ACTIVE ? 15 : _context8.t0 === _constants.SHARE_STATUS.LOCAL_SHARE_ACTIVE ? 17 : _context8.t0 === _constants.SHARE_STATUS.WHITEBOARD_SHARE_ACTIVE ? 19 : _context8.t0 === _constants.SHARE_STATUS.NO_SHARE ? 23 : 24;
3648
3719
  break;
3649
3720
  case 15:
3650
3721
  _triggerProxy.default.trigger(_this15, {
3651
3722
  file: 'meetings/index',
3652
3723
  function: 'remoteShare'
3653
3724
  }, _constants.EVENT_TRIGGERS.MEETING_STOPPED_SHARING_REMOTE);
3654
- return _context8.abrupt("break", 23);
3725
+ return _context8.abrupt("break", 25);
3655
3726
  case 17:
3656
3727
  _triggerProxy.default.trigger(_this15, {
3657
3728
  file: 'meeting/index',
@@ -3659,51 +3730,76 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
3659
3730
  }, _constants.EVENT_TRIGGERS.MEETING_STOPPED_SHARING_LOCAL, {
3660
3731
  reason: _constants.SHARE_STOPPED_REASON.SELF_STOPPED
3661
3732
  });
3662
- return _context8.abrupt("break", 23);
3733
+ return _context8.abrupt("break", 25);
3663
3734
  case 19:
3664
3735
  _triggerProxy.default.trigger(_this15, {
3665
3736
  file: 'meeting/index',
3666
3737
  function: 'stopWhiteboardShare'
3667
3738
  }, _constants.EVENT_TRIGGERS.MEETING_STOPPED_SHARING_WHITEBOARD);
3668
- return _context8.abrupt("break", 23);
3669
- case 21:
3670
- return _context8.abrupt("break", 23);
3671
- case 22:
3672
- return _context8.abrupt("break", 23);
3739
+ // @ts-ignore
3740
+ _this15.webex.internal.newMetrics.callDiagnosticLatencies.saveTimestamp({
3741
+ key: 'internal.client.share.stopped'
3742
+ });
3743
+ // @ts-ignore
3744
+ _this15.webex.internal.newMetrics.submitClientEvent({
3745
+ name: 'client.share.stopped',
3746
+ payload: {
3747
+ mediaType: 'whiteboard',
3748
+ shareDuration:
3749
+ // @ts-ignore
3750
+ _this15.webex.internal.newMetrics.callDiagnosticLatencies.getShareDuration()
3751
+ },
3752
+ options: {
3753
+ meetingId: _this15.id
3754
+ }
3755
+ });
3756
+ return _context8.abrupt("break", 25);
3673
3757
  case 23:
3758
+ return _context8.abrupt("break", 25);
3759
+ case 24:
3760
+ return _context8.abrupt("break", 25);
3761
+ case 25:
3674
3762
  _context8.t1 = newShareStatus;
3675
- _context8.next = _context8.t1 === _constants.SHARE_STATUS.REMOTE_SHARE_ACTIVE ? 26 : _context8.t1 === _constants.SHARE_STATUS.LOCAL_SHARE_ACTIVE ? 35 : _context8.t1 === _constants.SHARE_STATUS.WHITEBOARD_SHARE_ACTIVE ? 38 : _context8.t1 === _constants.SHARE_STATUS.NO_SHARE ? 41 : 42;
3763
+ _context8.next = _context8.t1 === _constants.SHARE_STATUS.REMOTE_SHARE_ACTIVE ? 28 : _context8.t1 === _constants.SHARE_STATUS.LOCAL_SHARE_ACTIVE ? 37 : _context8.t1 === _constants.SHARE_STATUS.WHITEBOARD_SHARE_ACTIVE ? 40 : _context8.t1 === _constants.SHARE_STATUS.NO_SHARE ? 43 : 44;
3676
3764
  break;
3677
- case 26:
3765
+ case 28:
3678
3766
  sendStartedSharingRemote = function sendStartedSharingRemote() {
3767
+ var _this15$locusInfo2, _this15$locusInfo2$in, _this15$webinar2;
3679
3768
  _this15.remoteShareInstanceId = contentShare.shareInstanceId;
3680
3769
  _this15.shareCAEventSentStatus.receiveStart = false;
3681
3770
  _this15.shareCAEventSentStatus.receiveStop = false;
3771
+ var finalBeneficiaryId = contentShare.beneficiaryId;
3772
+ // In case of attendee in webinar, the whiteboard is shared by other participants
3773
+ if ((_this15$locusInfo2 = _this15.locusInfo) !== null && _this15$locusInfo2 !== void 0 && (_this15$locusInfo2$in = _this15$locusInfo2.info) !== null && _this15$locusInfo2$in !== void 0 && _this15$locusInfo2$in.isWebinar && (_this15$webinar2 = _this15.webinar) !== null && _this15$webinar2 !== void 0 && _this15$webinar2.selfIsAttendee) {
3774
+ if (!finalBeneficiaryId && whiteboardShare.beneficiaryId) {
3775
+ finalBeneficiaryId = whiteboardShare.beneficiaryId;
3776
+ }
3777
+ }
3682
3778
  _triggerProxy.default.trigger(_this15, {
3683
3779
  file: 'meetings/index',
3684
3780
  function: 'remoteShare'
3685
3781
  }, _constants.EVENT_TRIGGERS.MEETING_STARTED_SHARING_REMOTE, {
3686
- memberId: contentShare.beneficiaryId,
3782
+ memberId: finalBeneficiaryId,
3687
3783
  url: contentShare.url,
3688
3784
  shareInstanceId: _this15.remoteShareInstanceId,
3689
3785
  annotationInfo: contentShare.annotation,
3690
3786
  resourceType: contentShare.resourceType
3691
3787
  });
3692
3788
  };
3693
- _context8.prev = 27;
3789
+ _context8.prev = 29;
3694
3790
  if (!((_this15$mediaProperti = _this15.mediaProperties.mediaDirection) !== null && _this15$mediaProperti !== void 0 && _this15$mediaProperti.sendShare && oldShareStatus === _constants.SHARE_STATUS.LOCAL_SHARE_ACTIVE)) {
3695
- _context8.next = 31;
3791
+ _context8.next = 33;
3696
3792
  break;
3697
3793
  }
3698
- _context8.next = 31;
3794
+ _context8.next = 33;
3699
3795
  return _this15.unpublishStreams([_this15.mediaProperties.shareVideoStream, _this15.mediaProperties.shareAudioStream]);
3700
- case 31:
3701
- _context8.prev = 31;
3796
+ case 33:
3797
+ _context8.prev = 33;
3702
3798
  sendStartedSharingRemote();
3703
- return _context8.finish(31);
3704
- case 34:
3705
- return _context8.abrupt("break", 43);
3706
- case 35:
3799
+ return _context8.finish(33);
3800
+ case 36:
3801
+ return _context8.abrupt("break", 45);
3802
+ case 37:
3707
3803
  _triggerProxy.default.trigger(_this15, {
3708
3804
  file: 'meeting/index',
3709
3805
  function: 'share'
@@ -3719,8 +3815,8 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
3719
3815
  meetingId: _this15.id
3720
3816
  }
3721
3817
  });
3722
- return _context8.abrupt("break", 43);
3723
- case 38:
3818
+ return _context8.abrupt("break", 45);
3819
+ case 40:
3724
3820
  _triggerProxy.default.trigger(_this15, {
3725
3821
  file: 'meeting/index',
3726
3822
  function: 'startWhiteboardShare'
@@ -3738,16 +3834,16 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
3738
3834
  meetingId: _this15.id
3739
3835
  }
3740
3836
  });
3741
- return _context8.abrupt("break", 43);
3742
- case 41:
3743
- return _context8.abrupt("break", 43);
3744
- case 42:
3745
- return _context8.abrupt("break", 43);
3837
+ return _context8.abrupt("break", 45);
3746
3838
  case 43:
3839
+ return _context8.abrupt("break", 45);
3840
+ case 44:
3841
+ return _context8.abrupt("break", 45);
3842
+ case 45:
3747
3843
  _this15.members.locusMediaSharesUpdate(payload);
3748
- _context8.next = 47;
3844
+ _context8.next = 49;
3749
3845
  break;
3750
- case 46:
3846
+ case 48:
3751
3847
  if (newShareStatus === _constants.SHARE_STATUS.REMOTE_SHARE_ACTIVE) {
3752
3848
  // if we got here, then some remote participant has stolen
3753
3849
  // the presentation from another remote participant
@@ -3787,14 +3883,14 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
3787
3883
  });
3788
3884
  _this15.members.locusMediaSharesUpdate(payload);
3789
3885
  }
3790
- case 47:
3886
+ case 49:
3791
3887
  case "end":
3792
3888
  return _context8.stop();
3793
3889
  }
3794
- }, _callee8, null, [[27,, 31, 34]]);
3890
+ }, _callee8, null, [[29,, 33, 36]]);
3795
3891
  }));
3796
3892
  return function (_x8) {
3797
- return _ref29.apply(this, arguments);
3893
+ return _ref31.apply(this, arguments);
3798
3894
  };
3799
3895
  }());
3800
3896
  }
@@ -3908,8 +4004,8 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
3908
4004
  });
3909
4005
  }
3910
4006
  });
3911
- this.locusInfo.on(_constants.LOCUSINFO.EVENTS.MEETING_INFO_UPDATED, function (_ref30) {
3912
- var isInitializing = _ref30.isInitializing;
4007
+ this.locusInfo.on(_constants.LOCUSINFO.EVENTS.MEETING_INFO_UPDATED, function (_ref32) {
4008
+ var isInitializing = _ref32.isInitializing;
3913
4009
  _this19.updateMeetingActions();
3914
4010
  _this19.recordingController.setDisplayHints(_this19.userDisplayHints);
3915
4011
  _this19.recordingController.setUserPolicy(_this19.selfUserPolicies);
@@ -4047,7 +4143,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
4047
4143
  _this21.updateLLMConnection();
4048
4144
  });
4049
4145
  this.locusInfo.on(_constants.LOCUSINFO.EVENTS.SELF_ADMITTED_GUEST, /*#__PURE__*/function () {
4050
- var _ref31 = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee9(payload) {
4146
+ var _ref33 = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee9(payload) {
4051
4147
  var _this21$rtcMetrics;
4052
4148
  return _regenerator.default.wrap(function _callee9$(_context9) {
4053
4149
  while (1) switch (_context9.prev = _context9.next) {
@@ -4081,7 +4177,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
4081
4177
  }, _callee9);
4082
4178
  }));
4083
4179
  return function (_x9) {
4084
- return _ref31.apply(this, arguments);
4180
+ return _ref33.apply(this, arguments);
4085
4181
  };
4086
4182
  }());
4087
4183
 
@@ -4200,7 +4296,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
4200
4296
  }
4201
4297
  });
4202
4298
  this.locusInfo.on(_constants.EVENTS.DESTROY_MEETING, /*#__PURE__*/function () {
4203
- var _ref32 = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee10(payload) {
4299
+ var _ref34 = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee10(payload) {
4204
4300
  return _regenerator.default.wrap(function _callee10$(_context10) {
4205
4301
  while (1) switch (_context10.prev = _context10.next) {
4206
4302
  case 0:
@@ -4260,7 +4356,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
4260
4356
  }, _callee10, null, [[8, 14]]);
4261
4357
  }));
4262
4358
  return function (_x10) {
4263
- return _ref32.apply(this, arguments);
4359
+ return _ref34.apply(this, arguments);
4264
4360
  };
4265
4361
  }());
4266
4362
  }
@@ -4289,11 +4385,13 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
4289
4385
 
4290
4386
  /**
4291
4387
  * Invite a guest to the call that isn't normally part of this call
4292
- * @param {Object} invitee
4388
+ * @param {Invitee} invitee
4293
4389
  * @param {String} invitee.emailAddress
4294
4390
  * @param {String} invitee.email
4295
4391
  * @param {String} invitee.phoneNumber
4296
4392
  * @param {Boolean} [alertIfActive]
4393
+ * @param {Boolean} [invitee.skipEmailValidation]
4394
+ * @param {Boolean} [invitee.isInternalNumber]
4297
4395
  * @returns {Promise} see #members.addMember
4298
4396
  * @public
4299
4397
  * @memberof Meeting
@@ -4307,7 +4405,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
4307
4405
 
4308
4406
  /**
4309
4407
  * Cancel an outgoing phone call invitation made during a meeting
4310
- * @param {Object} invitee
4408
+ * @param {Invitee} invitee
4311
4409
  * @param {String} invitee.phoneNumber
4312
4410
  * @returns {Promise} see #members.cancelPhoneInvite
4313
4411
  * @public
@@ -4320,17 +4418,18 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
4320
4418
  }
4321
4419
 
4322
4420
  /**
4323
- * Cancel an SIP call invitation made during a meeting
4324
- * @param {Object} invitee
4421
+ * Cancel an SIP/phone call invitation made during a meeting
4422
+ * @param {Invitee} invitee
4325
4423
  * @param {String} invitee.memberId
4326
- * @returns {Promise} see #members.cancelSIPInvite
4424
+ * @param {Boolean} [invitee.isInternalNumber] - When cancel phone invitation, if the number is internal
4425
+ * @returns {Promise} see #members.cancelInviteByMemberId
4327
4426
  * @public
4328
4427
  * @memberof Meeting
4329
4428
  */
4330
4429
  }, {
4331
- key: "cancelSIPInvite",
4332
- value: function cancelSIPInvite(invitee) {
4333
- return this.members.cancelSIPInvite(invitee);
4430
+ key: "cancelInviteByMemberId",
4431
+ value: function cancelInviteByMemberId(invitee) {
4432
+ return this.members.cancelInviteByMemberId(invitee);
4334
4433
  }
4335
4434
 
4336
4435
  /**
@@ -4405,6 +4504,8 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
4405
4504
  // so we need to explicitly update remote mute for correct logic flow
4406
4505
  _this24.audio.handleServerRemoteMuteUpdate(_this24, enabled);
4407
4506
  }
4507
+ }).catch(function (error) {
4508
+ return _promise.default.reject(error);
4408
4509
  }));
4409
4510
  case 11:
4410
4511
  case "end":
@@ -4613,8 +4714,12 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
4613
4714
  isClosedCaptionActive: _util2.default.isClosedCaptionActive(this.userDisplayHints),
4614
4715
  canStartManualCaption: _util2.default.canStartManualCaption(this.userDisplayHints),
4615
4716
  canStopManualCaption: _util2.default.canStopManualCaption(this.userDisplayHints),
4717
+ isLocalRecordingStarted: _util2.default.isLocalRecordingStarted(this.userDisplayHints),
4718
+ isLocalRecordingStopped: _util2.default.isLocalRecordingStopped(this.userDisplayHints),
4719
+ isLocalRecordingPaused: _util2.default.isLocalRecordingPaused(this.userDisplayHints),
4616
4720
  isManualCaptionActive: _util2.default.isManualCaptionActive(this.userDisplayHints),
4617
4721
  isSaveTranscriptsEnabled: _util2.default.isSaveTranscriptsEnabled(this.userDisplayHints),
4722
+ isSpokenLanguageAutoDetectionEnabled: _util2.default.isSpokenLanguageAutoDetectionEnabled(this.userDisplayHints),
4618
4723
  isWebexAssistantActive: _util2.default.isWebexAssistantActive(this.userDisplayHints),
4619
4724
  canViewCaptionPanel: _util2.default.canViewCaptionPanel(this.userDisplayHints),
4620
4725
  isRealTimeTranslationEnabled: _util2.default.isRealTimeTranslationEnabled(this.userDisplayHints),
@@ -4822,6 +4927,14 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
4822
4927
  canDisableRemoteDesktopControl: _util5.default.hasHints({
4823
4928
  requiredHints: [_constants.DISPLAY_HINTS.DISABLE_RDC_MEETING_OPTION],
4824
4929
  displayHints: this.userDisplayHints
4930
+ }),
4931
+ canEnablePollingQA: _util5.default.hasHints({
4932
+ requiredHints: [_constants.DISPLAY_HINTS.ENABLE_ATTENDEE_START_POLLING_QA],
4933
+ displayHints: this.userDisplayHints
4934
+ }),
4935
+ canDisablePollingQA: _util5.default.hasHints({
4936
+ requiredHints: [_constants.DISPLAY_HINTS.DISABLE_ATTENDEE_START_POLLING_QA],
4937
+ displayHints: this.userDisplayHints
4825
4938
  })
4826
4939
  }) || changed;
4827
4940
  }
@@ -5343,13 +5456,6 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
5343
5456
 
5344
5457
  // Only send restore event when it was disconnected before and for connected later
5345
5458
  if (!_this27.hasWebsocketConnected) {
5346
- // @ts-ignore
5347
- _this27.webex.internal.newMetrics.submitClientEvent({
5348
- name: 'client.mercury.connection.restored',
5349
- options: {
5350
- meetingId: _this27.id
5351
- }
5352
- });
5353
5459
  _metrics.default.sendBehavioralMetric(_constants2.default.MERCURY_CONNECTION_RESTORED, {
5354
5460
  correlation_id: _this27.correlationId
5355
5461
  });
@@ -5360,13 +5466,6 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
5360
5466
  // @ts-ignore
5361
5467
  this.webex.internal.mercury.on(_constants.OFFLINE, function () {
5362
5468
  _loggerProxy.default.logger.error('Meeting:index#setMercuryListener --> Web socket offline');
5363
- // @ts-ignore
5364
- _this27.webex.internal.newMetrics.submitClientEvent({
5365
- name: 'client.mercury.connection.lost',
5366
- options: {
5367
- meetingId: _this27.id
5368
- }
5369
- });
5370
5469
  _metrics.default.sendBehavioralMetric(_constants2.default.MERCURY_CONNECTION_FAILURE, {
5371
5470
  correlation_id: _this27.correlationId
5372
5471
  });
@@ -6293,24 +6392,10 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
6293
6392
  _this36.deferJoin = undefined;
6294
6393
  return join;
6295
6394
  }).catch(function (error) {
6296
- var _this36$meetingInfo, _error$error;
6395
+ var _error$error;
6297
6396
  _this36.meetingFiniteStateMachine.fail(error);
6298
6397
  _loggerProxy.default.logger.error('Meeting:index#join --> Failed', error);
6299
6398
 
6300
- // @ts-ignore
6301
- _this36.webex.internal.newMetrics.submitClientEvent({
6302
- name: 'client.locus.join.response',
6303
- payload: {
6304
- identifiers: {
6305
- meetingLookupUrl: (_this36$meetingInfo = _this36.meetingInfo) === null || _this36$meetingInfo === void 0 ? void 0 : _this36$meetingInfo.meetingLookupUrl
6306
- }
6307
- },
6308
- options: {
6309
- meetingId: _this36.id,
6310
- rawError: error
6311
- }
6312
- });
6313
-
6314
6399
  // TODO: change this to error codes and pre defined dictionary
6315
6400
  _metrics.default.sendBehavioralMetric(_constants2.default.JOIN_FAILURE, {
6316
6401
  correlation_id: _this36.correlationId,
@@ -6464,14 +6549,14 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
6464
6549
  value: function dialInPstn() {
6465
6550
  var _this38 = this;
6466
6551
  if (this.isPhoneProvisioned(this.dialInDeviceStatus)) return _promise.default.resolve(); // prevent multiple dial in devices from being provisioned
6467
-
6468
- var correlationId = this.correlationId,
6552
+ this.pstnCorrelationId = _uuid.default.v4();
6553
+ var pstnCorrelationId = this.pstnCorrelationId,
6469
6554
  locusUrl = this.locusUrl;
6470
6555
  if (!this.dialInUrl) this.dialInUrl = "dialin:///".concat(_uuid.default.v4());
6471
6556
  return this.meetingRequest
6472
6557
  // @ts-ignore
6473
6558
  .dialIn({
6474
- correlationId: correlationId,
6559
+ correlationId: pstnCorrelationId,
6475
6560
  dialInUrl: this.dialInUrl,
6476
6561
  locusUrl: locusUrl,
6477
6562
  clientUrl: this.deviceUrl
@@ -6480,11 +6565,15 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
6480
6565
  _metrics.default.sendBehavioralMetric(_constants2.default.ADD_DIAL_IN_FAILURE, {
6481
6566
  correlation_id: _this38.correlationId,
6482
6567
  dial_in_url: _this38.dialInUrl,
6568
+ dial_in_correlation_id: pstnCorrelationId,
6483
6569
  locus_id: locusUrl.split('/').pop(),
6484
6570
  client_url: _this38.deviceUrl,
6485
6571
  reason: (_error$error2 = error.error) === null || _error$error2 === void 0 ? void 0 : _error$error2.message,
6486
6572
  stack: error.stack
6487
6573
  });
6574
+ if (_this38.pstnCorrelationId === pstnCorrelationId) {
6575
+ _this38.pstnCorrelationId = undefined;
6576
+ }
6488
6577
  return _promise.default.reject(error);
6489
6578
  });
6490
6579
  }
@@ -6501,14 +6590,14 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
6501
6590
  value: function dialOutPstn(phoneNumber) {
6502
6591
  var _this39 = this;
6503
6592
  if (this.isPhoneProvisioned(this.dialOutDeviceStatus)) return _promise.default.resolve(); // prevent multiple dial out devices from being provisioned
6504
-
6505
- var correlationId = this.correlationId,
6506
- locusUrl = this.locusUrl;
6593
+ this.pstnCorrelationId = _uuid.default.v4();
6594
+ var locusUrl = this.locusUrl,
6595
+ pstnCorrelationId = this.pstnCorrelationId;
6507
6596
  if (!this.dialOutUrl) this.dialOutUrl = "dialout:///".concat(_uuid.default.v4());
6508
6597
  return this.meetingRequest
6509
6598
  // @ts-ignore
6510
6599
  .dialOut({
6511
- correlationId: correlationId,
6600
+ correlationId: pstnCorrelationId,
6512
6601
  dialOutUrl: this.dialOutUrl,
6513
6602
  phoneNumber: phoneNumber,
6514
6603
  locusUrl: locusUrl,
@@ -6518,11 +6607,15 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
6518
6607
  _metrics.default.sendBehavioralMetric(_constants2.default.ADD_DIAL_OUT_FAILURE, {
6519
6608
  correlation_id: _this39.correlationId,
6520
6609
  dial_out_url: _this39.dialOutUrl,
6610
+ dial_out_correlation_id: pstnCorrelationId,
6521
6611
  locus_id: locusUrl.split('/').pop(),
6522
6612
  client_url: _this39.deviceUrl,
6523
6613
  reason: (_error$error3 = error.error) === null || _error$error3 === void 0 ? void 0 : _error$error3.message,
6524
6614
  stack: error.stack
6525
6615
  });
6616
+ if (_this39.pstnCorrelationId === pstnCorrelationId) {
6617
+ _this39.pstnCorrelationId = undefined;
6618
+ }
6526
6619
  return _promise.default.reject(error);
6527
6620
  });
6528
6621
  }
@@ -6537,7 +6630,13 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
6537
6630
  }, {
6538
6631
  key: "disconnectPhoneAudio",
6539
6632
  value: function disconnectPhoneAudio() {
6540
- return _promise.default.all([this.isPhoneProvisioned(this.dialInDeviceStatus) ? _util2.default.disconnectPhoneAudio(this, this.dialInUrl) : _promise.default.resolve(), this.isPhoneProvisioned(this.dialOutDeviceStatus) ? _util2.default.disconnectPhoneAudio(this, this.dialOutUrl) : _promise.default.resolve()]);
6633
+ var _this40 = this;
6634
+ var correlationToClear = this.pstnCorrelationId;
6635
+ return _promise.default.all([this.isPhoneProvisioned(this.dialInDeviceStatus) ? _util2.default.disconnectPhoneAudio(this, this.dialInUrl) : _promise.default.resolve(), this.isPhoneProvisioned(this.dialOutDeviceStatus) ? _util2.default.disconnectPhoneAudio(this, this.dialOutUrl) : _promise.default.resolve()]).then(function () {
6636
+ if (_this40.pstnCorrelationId === correlationToClear) {
6637
+ _this40.pstnCorrelationId = undefined;
6638
+ }
6639
+ });
6541
6640
  }
6542
6641
 
6543
6642
  /**
@@ -6550,7 +6649,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
6550
6649
  }, {
6551
6650
  key: "moveTo",
6552
6651
  value: function moveTo(resourceId) {
6553
- var _this40 = this;
6652
+ var _this41 = this;
6554
6653
  if (!resourceId) {
6555
6654
  throw new _parameter.default('Cannot move call without a resourceId.');
6556
6655
  }
@@ -6594,12 +6693,12 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
6594
6693
  while (1) switch (_context21.prev = _context21.next) {
6595
6694
  case 0:
6596
6695
  _context21.prev = 0;
6597
- if (!(_this40.screenShareFloorState === ScreenShareFloorStatus.GRANTED)) {
6696
+ if (!(_this41.screenShareFloorState === ScreenShareFloorStatus.GRANTED)) {
6598
6697
  _context21.next = 4;
6599
6698
  break;
6600
6699
  }
6601
6700
  _context21.next = 4;
6602
- return _this40.releaseScreenShareFloor();
6701
+ return _this41.releaseScreenShareFloor();
6603
6702
  case 4:
6604
6703
  mediaSettings = {
6605
6704
  mediaDirection: {
@@ -6611,37 +6710,37 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
6611
6710
  receiveShare: true
6612
6711
  }
6613
6712
  };
6614
- _this40.mediaProperties.setMediaDirection(mediaSettings.mediaDirection);
6615
- _this40.mediaProperties.unsetRemoteMedia();
6713
+ _this41.mediaProperties.setMediaDirection(mediaSettings.mediaDirection);
6714
+ _this41.mediaProperties.unsetRemoteMedia();
6616
6715
 
6617
6716
  // when a move to is intiated by the client , Locus delets the existing media node from the server as soon the device answers the meeting
6618
6717
  // once the device answers we close the old connection and create new media server connection with only share enabled
6619
- if (!_this40.statsAnalyzer) {
6718
+ if (!_this41.statsAnalyzer) {
6620
6719
  _context21.next = 10;
6621
6720
  break;
6622
6721
  }
6623
6722
  _context21.next = 10;
6624
- return _this40.statsAnalyzer.stopAnalyzer();
6723
+ return _this41.statsAnalyzer.stopAnalyzer();
6625
6724
  case 10:
6626
6725
  _context21.next = 12;
6627
- return _this40.closeRemoteStreams();
6726
+ return _this41.closeRemoteStreams();
6628
6727
  case 12:
6629
6728
  _context21.next = 14;
6630
- return _this40.closePeerConnections();
6729
+ return _this41.closePeerConnections();
6631
6730
  case 14:
6632
- _this40.cleanupLocalStreams();
6633
- _this40.unsetRemoteStreams();
6634
- _this40.unsetPeerConnections();
6635
- _this40.reconnectionManager.cleanUp();
6731
+ _this41.cleanupLocalStreams();
6732
+ _this41.unsetRemoteStreams();
6733
+ _this41.unsetPeerConnections();
6734
+ _this41.reconnectionManager.cleanUp();
6636
6735
  _context21.next = 20;
6637
- return _this40.addMedia({
6736
+ return _this41.addMedia({
6638
6737
  audioEnabled: false,
6639
6738
  videoEnabled: false,
6640
6739
  shareVideoEnabled: true
6641
6740
  });
6642
6741
  case 20:
6643
6742
  _metrics.default.sendBehavioralMetric(_constants2.default.MOVE_TO_SUCCESS);
6644
- _this40.isMoveToInProgress = false;
6743
+ _this41.isMoveToInProgress = false;
6645
6744
  _context21.next = 29;
6646
6745
  break;
6647
6746
  case 24:
@@ -6649,12 +6748,12 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
6649
6748
  _context21.t0 = _context21["catch"](0);
6650
6749
  _loggerProxy.default.logger.error('Meeting:index#moveTo --> Failed to moveTo resourceId', _context21.t0);
6651
6750
  _metrics.default.sendBehavioralMetric(_constants2.default.MOVE_TO_FAILURE, {
6652
- correlation_id: _this40.correlationId,
6653
- locus_id: _this40.locusUrl.split('/').pop(),
6751
+ correlation_id: _this41.correlationId,
6752
+ locus_id: _this41.locusUrl.split('/').pop(),
6654
6753
  reason: _context21.t0.message,
6655
6754
  stack: _context21.t0.stack
6656
6755
  });
6657
- _this40.isMoveToInProgress = false;
6756
+ _this41.isMoveToInProgress = false;
6658
6757
  case 29:
6659
6758
  case "end":
6660
6759
  return _context21.stop();
@@ -6670,17 +6769,17 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
6670
6769
  resourceId: resourceId,
6671
6770
  moveToResource: true
6672
6771
  }).then(function () {
6673
- _this40.meetingFiniteStateMachine.join();
6772
+ _this41.meetingFiniteStateMachine.join();
6674
6773
  }).catch(function (error) {
6675
- _this40.meetingFiniteStateMachine.fail(error);
6774
+ _this41.meetingFiniteStateMachine.fail(error);
6676
6775
  _metrics.default.sendBehavioralMetric(_constants2.default.MOVE_TO_FAILURE, {
6677
- correlation_id: _this40.correlationId,
6678
- locus_id: _this40.locusUrl.split('/').pop(),
6776
+ correlation_id: _this41.correlationId,
6777
+ locus_id: _this41.locusUrl.split('/').pop(),
6679
6778
  reason: error.message,
6680
6779
  stack: error.stack
6681
6780
  });
6682
6781
  _loggerProxy.default.logger.error('Meeting:index#moveTo --> Failed to moveTo resourceId', error);
6683
- _this40.isMoveToInProgress = false;
6782
+ _this41.isMoveToInProgress = false;
6684
6783
  return _promise.default.reject(error);
6685
6784
  });
6686
6785
  }
@@ -6695,7 +6794,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
6695
6794
  }, {
6696
6795
  key: "moveFrom",
6697
6796
  value: function moveFrom(resourceId) {
6698
- var _this41 = this;
6797
+ var _this42 = this;
6699
6798
  // On moveFrom ask the developer to re capture it moveFrom then updateMedia
6700
6799
  if (!resourceId) {
6701
6800
  throw new _parameter.default('Cannot move call without a resourceId.');
@@ -6710,19 +6809,19 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
6710
6809
  }
6711
6810
  });
6712
6811
  return _util2.default.joinMeetingOptions(this).then(function () {
6713
- return _util2.default.leaveMeeting(_this41, {
6812
+ return _util2.default.leaveMeeting(_this42, {
6714
6813
  resourceId: resourceId,
6715
6814
  correlationId: oldCorrelationId,
6716
6815
  moveMeeting: true
6717
6816
  }).then(function () {
6718
- _this41.resourceId = '';
6817
+ _this42.resourceId = '';
6719
6818
  _metrics.default.sendBehavioralMetric(_constants2.default.MOVE_FROM_SUCCESS);
6720
6819
  });
6721
6820
  }).catch(function (error) {
6722
- _this41.meetingFiniteStateMachine.fail(error);
6821
+ _this42.meetingFiniteStateMachine.fail(error);
6723
6822
  _metrics.default.sendBehavioralMetric(_constants2.default.MOVE_FROM_FAILURE, {
6724
- correlation_id: _this41.correlationId,
6725
- locus_id: _this41.locusUrl.split('/').pop(),
6823
+ correlation_id: _this42.correlationId,
6824
+ locus_id: _this42.locusUrl.split('/').pop(),
6726
6825
  reason: error.message,
6727
6826
  stack: error.stack
6728
6827
  });
@@ -6845,9 +6944,9 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
6845
6944
  }, {
6846
6945
  key: "forwardEvent",
6847
6946
  value: function forwardEvent(eventEmitter, eventTypeToForward, meetingEventType) {
6848
- var _this42 = this;
6947
+ var _this43 = this;
6849
6948
  eventEmitter.on(eventTypeToForward, function (data) {
6850
- return _triggerProxy.default.trigger(_this42, {
6949
+ return _triggerProxy.default.trigger(_this43, {
6851
6950
  file: 'meetings',
6852
6951
  function: 'addMedia'
6853
6952
  }, meetingEventType, data);
@@ -7001,14 +7100,17 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7001
7100
  }, {
7002
7101
  key: "createStatsAnalyzer",
7003
7102
  value: function createStatsAnalyzer() {
7103
+ var _this44 = this;
7004
7104
  // @ts-ignore - config coming from registerPlugin
7005
7105
  if (this.config.stats.enableStatsAnalyzer) {
7006
7106
  // @ts-ignore - config coming from registerPlugin
7007
7107
  this.networkQualityMonitor = new _internalMediaCore.NetworkQualityMonitor(this.config.stats);
7108
+ this.statsMonitor = new _internalMediaCore.StatsMonitor();
7008
7109
  this.statsAnalyzer = new _internalMediaCore.StatsAnalyzer({
7009
7110
  // @ts-ignore - config coming from registerPlugin
7010
7111
  config: this.config.stats,
7011
7112
  networkQualityMonitor: this.networkQualityMonitor,
7113
+ statsMonitor: this.statsMonitor,
7012
7114
  isMultistream: this.isMultistream
7013
7115
  });
7014
7116
  this.shareCAEventSentStatus = {
@@ -7019,6 +7121,22 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7019
7121
  };
7020
7122
  this.setupStatsAnalyzerEventHandlers();
7021
7123
  this.networkQualityMonitor.on(_internalMediaCore.NetworkQualityEventNames.NETWORK_QUALITY, this.sendNetworkQualityEvent.bind(this));
7124
+ this.statsMonitor.on(_internalMediaCore.StatsMonitorEventNames.INBOUND_AUDIO_ISSUE, function (data) {
7125
+ // Before forwarding any inbound audio issues to the app, make sure that we have at least one other
7126
+ // participant in the meeting with unmuted audio.
7127
+ // We don't check this.mediaProperties.mediaDirection here, because that's already handled in statsAnalyzer,
7128
+ // so we won't get this event if we are not setup to receive any audio
7129
+ var atLeastOneUnmutedOtherMember = (0, _values.default)(_this44.members.membersCollection.getAll()).find(function (member) {
7130
+ return !member.isSelf && !member.isPairedWithSelf && !member.isAudioMuted;
7131
+ });
7132
+ if (atLeastOneUnmutedOtherMember) {
7133
+ _this44.mediaProperties.sendMediaIssueMetric('inbound_audio', data.issueSubType, _this44.correlationId);
7134
+ _triggerProxy.default.trigger(_this44, {
7135
+ file: 'meeting/index',
7136
+ function: 'createStatsAnalyzer'
7137
+ }, _constants.EVENT_TRIGGERS.MEDIA_INBOUND_AUDIO_ISSUE_DETECTED, data);
7138
+ }
7139
+ });
7022
7140
  }
7023
7141
  }
7024
7142
 
@@ -7033,7 +7151,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7033
7151
  key: "waitForRemoteSDPAnswer",
7034
7152
  value: (function () {
7035
7153
  var _waitForRemoteSDPAnswer = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee25() {
7036
- var _this43 = this;
7154
+ var _this45 = this;
7037
7155
  var LOG_HEADER, deferSDPAnswer;
7038
7156
  return _regenerator.default.wrap(function _callee25$(_context25) {
7039
7157
  while (1) switch (_context25.prev = _context25.next) {
@@ -7052,18 +7170,18 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7052
7170
  var error = new Error('Timed out waiting for REMOTE SDP ANSWER');
7053
7171
 
7054
7172
  // @ts-ignore
7055
- _this43.webex.internal.newMetrics.submitClientEvent({
7173
+ _this45.webex.internal.newMetrics.submitClientEvent({
7056
7174
  name: 'client.media-engine.remote-sdp-received',
7057
7175
  payload: {
7058
7176
  canProceed: false,
7059
7177
  errors: [
7060
7178
  // @ts-ignore
7061
- _this43.webex.internal.newMetrics.callDiagnosticMetrics.getErrorPayloadForClientErrorCode({
7179
+ _this45.webex.internal.newMetrics.callDiagnosticMetrics.getErrorPayloadForClientErrorCode({
7062
7180
  clientErrorCode: _internalPluginMetrics.CALL_DIAGNOSTIC_CONFIG.MISSING_ROAP_ANSWER_CLIENT_CODE
7063
7181
  })]
7064
7182
  },
7065
7183
  options: {
7066
- meetingId: _this43.id,
7184
+ meetingId: _this45.id,
7067
7185
  rawError: error
7068
7186
  }
7069
7187
  });
@@ -7372,6 +7490,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7372
7490
  key: "cleanUpOnAddMediaFailure",
7373
7491
  value: (function () {
7374
7492
  var _cleanUpOnAddMediaFailure = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee31() {
7493
+ var _this$networkQualityM, _this$statsMonitor;
7375
7494
  return _regenerator.default.wrap(function _callee31$(_context31) {
7376
7495
  while (1) switch (_context31.prev = _context31.next) {
7377
7496
  case 0:
@@ -7383,19 +7502,23 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7383
7502
  return this.statsAnalyzer.stopAnalyzer();
7384
7503
  case 3:
7385
7504
  this.statsAnalyzer = null;
7505
+ (_this$networkQualityM = this.networkQualityMonitor) === null || _this$networkQualityM === void 0 ? void 0 : _this$networkQualityM.removeAllListeners();
7506
+ this.networkQualityMonitor = null;
7507
+ (_this$statsMonitor = this.statsMonitor) === null || _this$statsMonitor === void 0 ? void 0 : _this$statsMonitor.removeAllListeners();
7508
+ this.statsMonitor = null;
7386
7509
 
7387
7510
  // when media fails, we want to upload a webrtc dump to see whats going on
7388
7511
  // this function is async, but returns once the stats have been gathered
7389
- _context31.next = 6;
7512
+ _context31.next = 10;
7390
7513
  return this.forceSendStatsReport({
7391
7514
  callFrom: 'addMedia'
7392
7515
  });
7393
- case 6:
7516
+ case 10:
7394
7517
  if (this.mediaProperties.webrtcMediaConnection) {
7395
7518
  this.closePeerConnections();
7396
7519
  this.unsetPeerConnections();
7397
7520
  }
7398
- case 7:
7521
+ case 11:
7399
7522
  case "end":
7400
7523
  return _context31.stop();
7401
7524
  }
@@ -7418,7 +7541,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7418
7541
  key: "downgradeFromMultistreamToTranscoded",
7419
7542
  value: (function () {
7420
7543
  var _downgradeFromMultistreamToTranscoded = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee32() {
7421
- var _this$locusMediaReque2;
7544
+ var _this$networkQualityM2, _this$statsMonitor2, _this$locusMediaReque2;
7422
7545
  return _regenerator.default.wrap(function _callee32$(_context32) {
7423
7546
  while (1) switch (_context32.prev = _context32.next) {
7424
7547
  case 0:
@@ -7430,6 +7553,10 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7430
7553
  return this.statsAnalyzer.stopAnalyzer();
7431
7554
  case 3:
7432
7555
  this.statsAnalyzer = null;
7556
+ (_this$networkQualityM2 = this.networkQualityMonitor) === null || _this$networkQualityM2 === void 0 ? void 0 : _this$networkQualityM2.removeAllListeners();
7557
+ this.networkQualityMonitor = null;
7558
+ (_this$statsMonitor2 = this.statsMonitor) === null || _this$statsMonitor2 === void 0 ? void 0 : _this$statsMonitor2.removeAllListeners();
7559
+ this.statsMonitor = null;
7433
7560
  this.isMultistream = false;
7434
7561
  if (this.mediaProperties.webrtcMediaConnection) {
7435
7562
  // close peer connection, but don't reset mute state information, because we will want to use it on the retry
@@ -7438,7 +7565,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7438
7565
  }
7439
7566
  (_this$locusMediaReque2 = this.locusMediaRequest) === null || _this$locusMediaReque2 === void 0 ? void 0 : _this$locusMediaReque2.downgradeFromMultistreamToTranscoded();
7440
7567
  this.createStatsAnalyzer();
7441
- case 8:
7568
+ case 12:
7442
7569
  case "end":
7443
7570
  return _context32.stop();
7444
7571
  }
@@ -7570,10 +7697,10 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7570
7697
  }, {
7571
7698
  key: "addMedia",
7572
7699
  value: function addMedia() {
7573
- var _this44 = this;
7700
+ var _this46 = this;
7574
7701
  var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
7575
7702
  return this.addMediaInternal(function () {
7576
- return _this44.turnServerUsed ? 'JOIN_MEETING_FINAL' : 'JOIN_MEETING_RETRY';
7703
+ return _this46.turnServerUsed ? 'JOIN_MEETING_FINAL' : 'JOIN_MEETING_RETRY';
7577
7704
  }, undefined, false, options);
7578
7705
  }
7579
7706
 
@@ -7606,6 +7733,17 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7606
7733
  remoteMediaManagerConfig,
7607
7734
  _options$bundlePolicy,
7608
7735
  bundlePolicy,
7736
+ _options$additionalMe,
7737
+ additionalMediaOptions,
7738
+ rawSendVideo,
7739
+ rawReceiveVideo,
7740
+ rawSendAudio,
7741
+ rawReceiveAudio,
7742
+ sendVideo,
7743
+ receiveVideo,
7744
+ sendAudio,
7745
+ receiveAudio,
7746
+ ipver,
7609
7747
  _this$remoteMediaMana,
7610
7748
  _yield$this$mediaProp,
7611
7749
  connectionType,
@@ -7662,17 +7800,24 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7662
7800
  }
7663
7801
  throw new _webexErrors.UserNotJoinedError();
7664
7802
  case 10:
7665
- localStreams = options.localStreams, _options$audioEnabled = options.audioEnabled, audioEnabled = _options$audioEnabled === void 0 ? true : _options$audioEnabled, _options$videoEnabled = options.videoEnabled, videoEnabled = _options$videoEnabled === void 0 ? true : _options$videoEnabled, _options$shareAudioEn = options.shareAudioEnabled, shareAudioEnabled = _options$shareAudioEn === void 0 ? true : _options$shareAudioEn, _options$shareVideoEn = options.shareVideoEnabled, shareVideoEnabled = _options$shareVideoEn === void 0 ? true : _options$shareVideoEn, remoteMediaManagerConfig = options.remoteMediaManagerConfig, _options$bundlePolicy = options.bundlePolicy, bundlePolicy = _options$bundlePolicy === void 0 ? 'max-bundle' : _options$bundlePolicy;
7803
+ localStreams = options.localStreams, _options$audioEnabled = options.audioEnabled, audioEnabled = _options$audioEnabled === void 0 ? true : _options$audioEnabled, _options$videoEnabled = options.videoEnabled, videoEnabled = _options$videoEnabled === void 0 ? true : _options$videoEnabled, _options$shareAudioEn = options.shareAudioEnabled, shareAudioEnabled = _options$shareAudioEn === void 0 ? true : _options$shareAudioEn, _options$shareVideoEn = options.shareVideoEnabled, shareVideoEnabled = _options$shareVideoEn === void 0 ? true : _options$shareVideoEn, remoteMediaManagerConfig = options.remoteMediaManagerConfig, _options$bundlePolicy = options.bundlePolicy, bundlePolicy = _options$bundlePolicy === void 0 ? 'max-bundle' : _options$bundlePolicy, _options$additionalMe = options.additionalMediaOptions, additionalMediaOptions = _options$additionalMe === void 0 ? {} : _options$additionalMe;
7804
+ rawSendVideo = additionalMediaOptions.sendVideo, rawReceiveVideo = additionalMediaOptions.receiveVideo, rawSendAudio = additionalMediaOptions.sendAudio, rawReceiveAudio = additionalMediaOptions.receiveAudio;
7805
+ sendVideo = videoEnabled && (rawSendVideo !== null && rawSendVideo !== void 0 ? rawSendVideo : true);
7806
+ receiveVideo = videoEnabled && (rawReceiveVideo !== null && rawReceiveVideo !== void 0 ? rawReceiveVideo : true);
7807
+ sendAudio = audioEnabled && (rawSendAudio !== null && rawSendAudio !== void 0 ? rawSendAudio : true);
7808
+ receiveAudio = audioEnabled && (rawReceiveAudio !== null && rawReceiveAudio !== void 0 ? rawReceiveAudio : true);
7666
7809
  this.allowMediaInLobby = options === null || options === void 0 ? void 0 : options.allowMediaInLobby;
7667
7810
 
7811
+ // @ts-ignore
7812
+ ipver = _util2.default.getIpVersion(this.webex); // used just for metrics
7668
7813
  // If the user is unjoined or guest waiting in lobby dont allow the user to addMedia
7669
7814
  // @ts-ignore - isUserUnadmitted coming from SelfUtil
7670
7815
  if (!(this.isUserUnadmitted && !this.wirelessShare && !this.allowMediaInLobby)) {
7671
- _context35.next = 14;
7816
+ _context35.next = 20;
7672
7817
  break;
7673
7818
  }
7674
7819
  throw new _webexErrors.UserInLobbyError();
7675
- case 14:
7820
+ case 20:
7676
7821
  // @ts-ignore
7677
7822
  this.webex.internal.newMetrics.submitClientEvent({
7678
7823
  name: 'client.media.capabilities',
@@ -7702,73 +7847,74 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7702
7847
  // when audioEnabled/videoEnabled is true, we set sendAudio/sendVideo to true even before any streams are published
7703
7848
  // to avoid doing an extra SDP exchange when they are published for the first time
7704
7849
  this.mediaProperties.setMediaDirection({
7705
- sendAudio: audioEnabled,
7706
- sendVideo: videoEnabled,
7850
+ sendAudio: sendAudio,
7851
+ sendVideo: sendVideo,
7707
7852
  sendShare: false,
7708
- receiveAudio: audioEnabled,
7709
- receiveVideo: videoEnabled,
7853
+ receiveAudio: receiveAudio,
7854
+ receiveVideo: receiveVideo,
7710
7855
  receiveShare: shareAudioEnabled || shareVideoEnabled
7711
7856
  });
7712
7857
  this.audio = (0, _muteState.createMuteState)(_constants.AUDIO, this, audioEnabled);
7713
7858
  this.video = (0, _muteState.createMuteState)(_constants.VIDEO, this, videoEnabled);
7714
7859
  this.brbState = (0, _brbState.createBrbState)(this, false);
7715
- _context35.prev = 19;
7716
- _context35.next = 22;
7860
+ _context35.prev = 25;
7861
+ _context35.next = 28;
7717
7862
  return this.setUpLocalStreamReferences(localStreams);
7718
- case 22:
7863
+ case 28:
7719
7864
  this.setMercuryListener();
7720
7865
  this.createStatsAnalyzer();
7721
- _context35.prev = 24;
7722
- _context35.next = 27;
7866
+ _context35.prev = 30;
7867
+ _context35.next = 33;
7723
7868
  return this.establishMediaConnection(remoteMediaManagerConfig, bundlePolicy, forceTurnDiscovery, turnServerInfo);
7724
- case 27:
7725
- _context35.next = 40;
7869
+ case 33:
7870
+ _context35.next = 46;
7726
7871
  break;
7727
- case 29:
7728
- _context35.prev = 29;
7729
- _context35.t0 = _context35["catch"](24);
7872
+ case 35:
7873
+ _context35.prev = 35;
7874
+ _context35.t0 = _context35["catch"](30);
7730
7875
  if (!(_context35.t0 instanceof _multistreamNotSupportedError.default)) {
7731
- _context35.next = 39;
7876
+ _context35.next = 45;
7732
7877
  break;
7733
7878
  }
7734
7879
  _loggerProxy.default.logger.warn("".concat(LOG_HEADER, " we asked for multistream backend (Homer), but got transcoded backend, recreating media connection..."));
7735
- _context35.next = 35;
7880
+ _context35.next = 41;
7736
7881
  return this.downgradeFromMultistreamToTranscoded();
7737
- case 35:
7738
- _context35.next = 37;
7882
+ case 41:
7883
+ _context35.next = 43;
7739
7884
  return this.establishMediaConnection(remoteMediaManagerConfig, bundlePolicy, true, undefined);
7740
- case 37:
7741
- _context35.next = 40;
7885
+ case 43:
7886
+ _context35.next = 46;
7742
7887
  break;
7743
- case 39:
7888
+ case 45:
7744
7889
  throw _context35.t0;
7745
- case 40:
7890
+ case 46:
7746
7891
  _loggerProxy.default.logger.info("".concat(LOG_HEADER, " media connected, finalizing..."));
7747
7892
  if (!this.mediaProperties.hasLocalShareStream()) {
7748
- _context35.next = 44;
7893
+ _context35.next = 50;
7749
7894
  break;
7750
7895
  }
7751
- _context35.next = 44;
7896
+ _context35.next = 50;
7752
7897
  return this.enqueueScreenShareFloorRequest();
7753
- case 44:
7754
- _context35.next = 46;
7898
+ case 50:
7899
+ _context35.next = 52;
7755
7900
  return this.mediaProperties.getCurrentConnectionInfo();
7756
- case 46:
7901
+ case 52:
7757
7902
  _yield$this$mediaProp = _context35.sent;
7758
7903
  connectionType = _yield$this$mediaProp.connectionType;
7759
7904
  ipVersion = _yield$this$mediaProp.ipVersion;
7760
7905
  selectedCandidatePairChanges = _yield$this$mediaProp.selectedCandidatePairChanges;
7761
7906
  numTransports = _yield$this$mediaProp.numTransports;
7762
7907
  iceCandidateErrors = Object.fromEntries(this.iceCandidateErrors);
7763
- _context35.next = 54;
7908
+ _context35.next = 60;
7764
7909
  return this.getMediaReachabilityMetricFields();
7765
- case 54:
7910
+ case 60:
7766
7911
  reachabilityMetrics = _context35.sent;
7767
7912
  _metrics.default.sendBehavioralMetric(_constants2.default.ADD_MEDIA_SUCCESS, _objectSpread(_objectSpread(_objectSpread({
7768
7913
  correlation_id: this.correlationId,
7769
7914
  locus_id: this.locusUrl.split('/').pop(),
7770
7915
  connectionType: connectionType,
7771
7916
  ipVersion: ipVersion,
7917
+ ipver: ipver,
7772
7918
  selectedCandidatePairChanges: selectedCandidatePairChanges,
7773
7919
  numTransports: numTransports,
7774
7920
  isMultistream: this.isMultistream,
@@ -7792,21 +7938,21 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7792
7938
  // We can log ReceiveSlot SSRCs only after the SDP exchange, so doing it here:
7793
7939
  (_this$remoteMediaMana = this.remoteMediaManager) === null || _this$remoteMediaMana === void 0 ? void 0 : _this$remoteMediaMana.logAllReceiveSlots();
7794
7940
  this.startPeriodicLogUpload();
7795
- _context35.next = 80;
7941
+ _context35.next = 86;
7796
7942
  break;
7797
- case 62:
7798
- _context35.prev = 62;
7799
- _context35.t1 = _context35["catch"](19);
7943
+ case 68:
7944
+ _context35.prev = 68;
7945
+ _context35.t1 = _context35["catch"](25);
7800
7946
  _loggerProxy.default.logger.error("".concat(LOG_HEADER, " failed to establish media connection: "), _context35.t1);
7801
7947
 
7802
7948
  // @ts-ignore
7803
- _context35.next = 67;
7949
+ _context35.next = 73;
7804
7950
  return this.getMediaReachabilityMetricFields();
7805
- case 67:
7951
+ case 73:
7806
7952
  _reachabilityMetrics = _context35.sent;
7807
- _context35.next = 70;
7953
+ _context35.next = 76;
7808
7954
  return this.mediaProperties.getCurrentConnectionInfo();
7809
- case 70:
7955
+ case 76:
7810
7956
  _yield$this$mediaProp2 = _context35.sent;
7811
7957
  _selectedCandidatePairChanges = _yield$this$mediaProp2.selectedCandidatePairChanges;
7812
7958
  _numTransports = _yield$this$mediaProp2.numTransports;
@@ -7828,11 +7974,12 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7828
7974
  connectionState: ((_this$mediaProperties22 = this.mediaProperties.webrtcMediaConnection) === null || _this$mediaProperties22 === void 0 ? void 0 : (_this$mediaProperties23 = _this$mediaProperties22.multistreamConnection) === null || _this$mediaProperties23 === void 0 ? void 0 : (_this$mediaProperties24 = _this$mediaProperties23.pc) === null || _this$mediaProperties24 === void 0 ? void 0 : (_this$mediaProperties25 = _this$mediaProperties24.pc) === null || _this$mediaProperties25 === void 0 ? void 0 : _this$mediaProperties25.connectionState) || ((_this$mediaProperties26 = this.mediaProperties.webrtcMediaConnection) === null || _this$mediaProperties26 === void 0 ? void 0 : (_this$mediaProperties27 = _this$mediaProperties26.mediaConnection) === null || _this$mediaProperties27 === void 0 ? void 0 : (_this$mediaProperties28 = _this$mediaProperties27.pc) === null || _this$mediaProperties28 === void 0 ? void 0 : _this$mediaProperties28.connectionState) || 'unknown',
7829
7975
  iceConnectionState: ((_this$mediaProperties29 = this.mediaProperties.webrtcMediaConnection) === null || _this$mediaProperties29 === void 0 ? void 0 : (_this$mediaProperties30 = _this$mediaProperties29.multistreamConnection) === null || _this$mediaProperties30 === void 0 ? void 0 : (_this$mediaProperties31 = _this$mediaProperties30.pc) === null || _this$mediaProperties31 === void 0 ? void 0 : (_this$mediaProperties32 = _this$mediaProperties31.pc) === null || _this$mediaProperties32 === void 0 ? void 0 : _this$mediaProperties32.iceConnectionState) || ((_this$mediaProperties33 = this.mediaProperties.webrtcMediaConnection) === null || _this$mediaProperties33 === void 0 ? void 0 : (_this$mediaProperties34 = _this$mediaProperties33.mediaConnection) === null || _this$mediaProperties34 === void 0 ? void 0 : (_this$mediaProperties35 = _this$mediaProperties34.pc) === null || _this$mediaProperties35 === void 0 ? void 0 : _this$mediaProperties35.iceConnectionState) || 'unknown'
7830
7976
  }, _reachabilityMetrics), _iceCandidateErrors), {}, {
7831
- iceCandidatesCount: this.iceCandidatesCount
7977
+ iceCandidatesCount: this.iceCandidatesCount,
7978
+ ipver: ipver
7832
7979
  }));
7833
- _context35.next = 77;
7980
+ _context35.next = 83;
7834
7981
  return this.cleanUpOnAddMediaFailure();
7835
- case 77:
7982
+ case 83:
7836
7983
  // Upload logs on error while adding media
7837
7984
  _triggerProxy.default.trigger(this, {
7838
7985
  file: 'meeting/index',
@@ -7844,15 +7991,15 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7844
7991
  });
7845
7992
  }
7846
7993
  throw _context35.t1;
7847
- case 80:
7848
- _context35.prev = 80;
7994
+ case 86:
7995
+ _context35.prev = 86;
7849
7996
  this.addMediaData.icePhaseCallback = DEFAULT_ICE_PHASE_CALLBACK;
7850
- return _context35.finish(80);
7851
- case 83:
7997
+ return _context35.finish(86);
7998
+ case 89:
7852
7999
  case "end":
7853
8000
  return _context35.stop();
7854
8001
  }
7855
- }, _callee35, this, [[19, 62, 80, 83], [24, 29]]);
8002
+ }, _callee35, this, [[25, 68, 86, 89], [30, 35]]);
7856
8003
  }));
7857
8004
  function addMediaInternal(_x33, _x34, _x35) {
7858
8005
  return _addMediaInternal.apply(this, arguments);
@@ -7884,7 +8031,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7884
8031
  * @memberof Meeting
7885
8032
  */
7886
8033
  function enqueueMediaUpdate(mediaUpdateType) {
7887
- var _this45 = this;
8034
+ var _this47 = this;
7888
8035
  var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
7889
8036
  var canUpdateMediaNow = this.canUpdateMedia();
7890
8037
  return new _promise.default(function (resolve, reject) {
@@ -7895,9 +8042,9 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
7895
8042
  options: options
7896
8043
  };
7897
8044
  _loggerProxy.default.logger.log("Meeting:index#enqueueMediaUpdate --> enqueuing media update type=".concat(mediaUpdateType));
7898
- _this45.queuedMediaUpdates.push(queueItem);
8045
+ _this47.queuedMediaUpdates.push(queueItem);
7899
8046
  if (canUpdateMediaNow) {
7900
- _this45.processNextQueuedMediaUpdate();
8047
+ _this47.processNextQueuedMediaUpdate();
7901
8048
  }
7902
8049
  });
7903
8050
  }
@@ -8002,7 +8149,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8002
8149
  }, {
8003
8150
  key: "acknowledge",
8004
8151
  value: function acknowledge(type) {
8005
- var _this46 = this;
8152
+ var _this48 = this;
8006
8153
  if (!type) {
8007
8154
  return _promise.default.reject(new _parameter.default('Type must be set to acknowledge the meeting.'));
8008
8155
  }
@@ -8014,12 +8161,12 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8014
8161
  }).then(function (response) {
8015
8162
  return _promise.default.resolve(response);
8016
8163
  }).then(function (response) {
8017
- _this46.meetingFiniteStateMachine.ring(type);
8164
+ _this48.meetingFiniteStateMachine.ring(type);
8018
8165
  // @ts-ignore
8019
- _this46.webex.internal.newMetrics.submitClientEvent({
8166
+ _this48.webex.internal.newMetrics.submitClientEvent({
8020
8167
  name: 'client.alert.displayed',
8021
8168
  options: {
8022
- meetingId: _this46.id
8169
+ meetingId: _this48.id
8023
8170
  }
8024
8171
  });
8025
8172
  return _promise.default.resolve({
@@ -8044,12 +8191,12 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8044
8191
  }, {
8045
8192
  key: "decline",
8046
8193
  value: function decline(reason) {
8047
- var _this47 = this;
8194
+ var _this49 = this;
8048
8195
  return _util2.default.declineMeeting(this, reason).then(function (decline) {
8049
- _this47.meetingFiniteStateMachine.decline();
8196
+ _this49.meetingFiniteStateMachine.decline();
8050
8197
  return _promise.default.resolve(decline);
8051
8198
  }).catch(function (error) {
8052
- _this47.meetingFiniteStateMachine.fail(error);
8199
+ _this49.meetingFiniteStateMachine.fail(error);
8053
8200
  return _promise.default.reject(error);
8054
8201
  });
8055
8202
  }
@@ -8100,7 +8247,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8100
8247
  }, {
8101
8248
  key: "leave",
8102
8249
  value: function leave() {
8103
- var _this48 = this;
8250
+ var _this50 = this;
8104
8251
  var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
8105
8252
  var leaveReason = options.reason || _constants.MEETING_REMOVED_REASON.CLIENT_LEAVE_REQUEST;
8106
8253
 
@@ -8112,7 +8259,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8112
8259
  var payload = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
8113
8260
  return (
8114
8261
  // @ts-ignore
8115
- _this48.webex.internal.newMetrics.submitClientEvent({
8262
+ _this50.webex.internal.newMetrics.submitClientEvent({
8116
8263
  name: 'client.call.leave',
8117
8264
  payload: _objectSpread({
8118
8265
  trigger: 'user-interaction',
@@ -8120,7 +8267,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8120
8267
  leaveReason: options.clientEventLeaveReason
8121
8268
  }, payload),
8122
8269
  options: {
8123
- meetingId: _this48.id
8270
+ meetingId: _this50.id
8124
8271
  }
8125
8272
  })
8126
8273
  );
@@ -8129,24 +8276,24 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8129
8276
  return _util2.default.leaveMeeting(this, options).then(function (leave) {
8130
8277
  // CA team recommends submitting this *after* locus /leave
8131
8278
  submitLeaveMetric();
8132
- _this48.meetingFiniteStateMachine.leave();
8133
- _this48.clearMeetingData();
8279
+ _this50.meetingFiniteStateMachine.leave();
8280
+ _this50.clearMeetingData();
8134
8281
 
8135
8282
  // upload logs on leave irrespective of meeting delete
8136
- _triggerProxy.default.trigger(_this48, {
8283
+ _triggerProxy.default.trigger(_this50, {
8137
8284
  file: 'meeting/index',
8138
8285
  function: 'leave'
8139
- }, _constants.EVENTS.REQUEST_UPLOAD_LOGS, _this48);
8286
+ }, _constants.EVENTS.REQUEST_UPLOAD_LOGS, _this50);
8140
8287
 
8141
8288
  // TODO: more testing before we remove this code, we are not sure the scenarios for destroy here
8142
- if (_this48.wirelessShare || _this48.guest) {
8289
+ if (_this50.wirelessShare || _this50.guest) {
8143
8290
  // If screen sharing clean the meeting object
8144
- _triggerProxy.default.trigger(_this48, {
8291
+ _triggerProxy.default.trigger(_this50, {
8145
8292
  file: 'meeting/index',
8146
8293
  function: 'leave'
8147
8294
  }, _constants.EVENTS.DESTROY_MEETING, {
8148
8295
  reason: options.reason,
8149
- meetingId: _this48.id
8296
+ meetingId: _this50.id
8150
8297
  });
8151
8298
  }
8152
8299
  _loggerProxy.default.logger.log('Meeting:index#leave --> LEAVE REASON ', leaveReason);
@@ -8163,16 +8310,16 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8163
8310
  shownToUser: false
8164
8311
  }]
8165
8312
  });
8166
- _this48.meetingFiniteStateMachine.fail(error);
8313
+ _this50.meetingFiniteStateMachine.fail(error);
8167
8314
  _loggerProxy.default.logger.error('Meeting:index#leave --> Failed to leave ', error);
8168
8315
  // upload logs on leave irrespective of meeting delete
8169
- _triggerProxy.default.trigger(_this48, {
8316
+ _triggerProxy.default.trigger(_this50, {
8170
8317
  file: 'meeting/index',
8171
8318
  function: 'leave'
8172
- }, _constants.EVENTS.REQUEST_UPLOAD_LOGS, _this48);
8319
+ }, _constants.EVENTS.REQUEST_UPLOAD_LOGS, _this50);
8173
8320
  _metrics.default.sendBehavioralMetric(_constants2.default.MEETING_LEAVE_FAILURE, {
8174
- correlation_id: _this48.correlationId,
8175
- locus_id: _this48.locusUrl.split('/').pop(),
8321
+ correlation_id: _this50.correlationId,
8322
+ locus_id: _this50.locusUrl.split('/').pop(),
8176
8323
  reason: error.message,
8177
8324
  stack: error.stack,
8178
8325
  code: error.code
@@ -8192,7 +8339,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8192
8339
  }, {
8193
8340
  key: "startWhiteboardShare",
8194
8341
  value: function startWhiteboardShare(channelUrl, resourceToken) {
8195
- var _this49 = this;
8342
+ var _this51 = this;
8196
8343
  var whiteboard = this.locusInfo.mediaShares.find(function (element) {
8197
8344
  return element.name === 'whiteboard';
8198
8345
  });
@@ -8200,6 +8347,10 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8200
8347
  return _promise.default.reject(new _parameter.default('Cannot share without channelUrl.'));
8201
8348
  }
8202
8349
  if (whiteboard) {
8350
+ // @ts-ignore
8351
+ this.webex.internal.newMetrics.callDiagnosticLatencies.saveTimestamp({
8352
+ key: 'internal.client.share.initiated'
8353
+ });
8203
8354
  // @ts-ignore
8204
8355
  this.webex.internal.newMetrics.submitClientEvent({
8205
8356
  name: 'client.share.initiated',
@@ -8221,13 +8372,13 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8221
8372
  body.resourceToken = resourceToken;
8222
8373
  }
8223
8374
  return this.meetingRequest.changeMeetingFloor(body).then(function () {
8224
- _this49.screenShareFloorState = ScreenShareFloorStatus.RELEASED;
8375
+ _this51.screenShareFloorState = ScreenShareFloorStatus.RELEASED;
8225
8376
  return _promise.default.resolve();
8226
8377
  }).catch(function (error) {
8227
8378
  _loggerProxy.default.logger.error('Meeting:index#startWhiteboardShare --> Error ', error);
8228
8379
  _metrics.default.sendBehavioralMetric(_constants2.default.MEETING_START_WHITEBOARD_SHARE_FAILURE, {
8229
- correlation_id: _this49.correlationId,
8230
- locus_id: _this49.locusUrl.split('/').pop(),
8380
+ correlation_id: _this51.correlationId,
8381
+ locus_id: _this51.locusUrl.split('/').pop(),
8231
8382
  reason: error.message,
8232
8383
  stack: error.stack,
8233
8384
  board: {
@@ -8250,16 +8401,22 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8250
8401
  }, {
8251
8402
  key: "stopWhiteboardShare",
8252
8403
  value: function stopWhiteboardShare(channelUrl) {
8253
- var _this50 = this;
8404
+ var _this52 = this;
8254
8405
  var whiteboard = this.locusInfo.mediaShares.find(function (element) {
8255
8406
  return element.name === 'whiteboard';
8256
8407
  });
8257
8408
  if (whiteboard) {
8409
+ // @ts-ignore
8410
+ this.webex.internal.newMetrics.callDiagnosticLatencies.saveTimestamp({
8411
+ key: 'internal.client.share.stopped'
8412
+ });
8258
8413
  // @ts-ignore
8259
8414
  this.webex.internal.newMetrics.submitClientEvent({
8260
8415
  name: 'client.share.stopped',
8261
8416
  payload: {
8262
- mediaType: 'whiteboard'
8417
+ mediaType: 'whiteboard',
8418
+ // @ts-ignore
8419
+ shareDuration: this.webex.internal.newMetrics.callDiagnosticLatencies.getShareDuration()
8263
8420
  },
8264
8421
  options: {
8265
8422
  meetingId: this.id
@@ -8273,8 +8430,8 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8273
8430
  }).catch(function (error) {
8274
8431
  _loggerProxy.default.logger.error('Meeting:index#stopWhiteboardShare --> Error ', error);
8275
8432
  _metrics.default.sendBehavioralMetric(_constants2.default.MEETING_STOP_WHITEBOARD_SHARE_FAILURE, {
8276
- correlation_id: _this50.correlationId,
8277
- locus_id: _this50.locusUrl.split('/').pop(),
8433
+ correlation_id: _this52.correlationId,
8434
+ locus_id: _this52.locusUrl.split('/').pop(),
8278
8435
  reason: error.message,
8279
8436
  stack: error.stack,
8280
8437
  board: {
@@ -8296,7 +8453,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8296
8453
  }, {
8297
8454
  key: "requestScreenShareFloor",
8298
8455
  value: function requestScreenShareFloor() {
8299
- var _this51 = this;
8456
+ var _this53 = this;
8300
8457
  if (!this.mediaProperties.hasLocalShareStream() || !this.mediaProperties.mediaDirection.sendShare) {
8301
8458
  _loggerProxy.default.logger.log("Meeting:index#requestScreenShareFloor --> NOT requesting floor, because we don't have the share stream anymore (shareStream=".concat(this.mediaProperties.shareVideoStream ? 'yes' : 'no', ", sendShare=").concat(this.mediaProperties.mediaDirection.sendShare, ")"));
8302
8459
  this.screenShareFloorState = ScreenShareFloorStatus.RELEASED;
@@ -8327,34 +8484,34 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8327
8484
  resourceUrl: this.resourceUrl,
8328
8485
  shareInstanceId: this.localShareInstanceId
8329
8486
  }).then(function () {
8330
- _this51.screenShareFloorState = ScreenShareFloorStatus.GRANTED;
8487
+ _this53.screenShareFloorState = ScreenShareFloorStatus.GRANTED;
8331
8488
  _metrics.default.sendBehavioralMetric(_constants2.default.MEETING_SHARE_SUCCESS, {
8332
- correlation_id: _this51.correlationId,
8333
- locus_id: _this51.locusUrl.split('/').pop()
8489
+ correlation_id: _this53.correlationId,
8490
+ locus_id: _this53.locusUrl.split('/').pop()
8334
8491
  });
8335
8492
  return _promise.default.resolve();
8336
8493
  }).catch(function (error) {
8337
8494
  _loggerProxy.default.logger.error('Meeting:index#share --> Error ', error);
8338
8495
  _metrics.default.sendBehavioralMetric(_constants2.default.MEETING_SHARE_FAILURE, {
8339
- correlation_id: _this51.correlationId,
8340
- locus_id: _this51.locusUrl.split('/').pop(),
8496
+ correlation_id: _this53.correlationId,
8497
+ locus_id: _this53.locusUrl.split('/').pop(),
8341
8498
  reason: error.message,
8342
8499
  stack: error.stack
8343
8500
  });
8344
8501
 
8345
8502
  // @ts-ignore
8346
- _this51.webex.internal.newMetrics.submitClientEvent({
8503
+ _this53.webex.internal.newMetrics.submitClientEvent({
8347
8504
  name: 'client.share.floor-granted.local',
8348
8505
  payload: {
8349
8506
  mediaType: 'share',
8350
8507
  errors: _util2.default.getChangeMeetingFloorErrorPayload(error.message),
8351
- shareInstanceId: _this51.localShareInstanceId
8508
+ shareInstanceId: _this53.localShareInstanceId
8352
8509
  },
8353
8510
  options: {
8354
- meetingId: _this51.id
8511
+ meetingId: _this53.id
8355
8512
  }
8356
8513
  });
8357
- _this51.screenShareFloorState = ScreenShareFloorStatus.RELEASED;
8514
+ _this53.screenShareFloorState = ScreenShareFloorStatus.RELEASED;
8358
8515
  return _promise.default.reject(error);
8359
8516
  });
8360
8517
  }
@@ -8377,10 +8534,10 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8377
8534
  }, {
8378
8535
  key: "requestScreenShareFloorIfPending",
8379
8536
  value: function requestScreenShareFloorIfPending() {
8380
- var _this52 = this;
8537
+ var _this54 = this;
8381
8538
  if (this.floorGrantPending && this.state === _constants.MEETING_STATE.STATES.JOINED) {
8382
8539
  this.requestScreenShareFloor().then(function () {
8383
- _this52.floorGrantPending = false;
8540
+ _this54.floorGrantPending = false;
8384
8541
  });
8385
8542
  }
8386
8543
  }
@@ -8394,7 +8551,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8394
8551
  }, {
8395
8552
  key: "releaseScreenShareFloor",
8396
8553
  value: function releaseScreenShareFloor() {
8397
- var _this53 = this;
8554
+ var _this55 = this;
8398
8555
  var content = this.locusInfo.mediaShares.find(function (element) {
8399
8556
  return element.name === _constants.CONTENT;
8400
8557
  });
@@ -8405,11 +8562,17 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8405
8562
  if (content) {
8406
8563
  var _content$floor;
8407
8564
  // @ts-ignore
8565
+ this.webex.internal.newMetrics.callDiagnosticLatencies.saveTimestamp({
8566
+ key: 'internal.client.share.stopped'
8567
+ });
8568
+ // @ts-ignore
8408
8569
  this.webex.internal.newMetrics.submitClientEvent({
8409
8570
  name: 'client.share.stopped',
8410
8571
  payload: {
8411
8572
  mediaType: 'share',
8412
- shareInstanceId: this.localShareInstanceId
8573
+ shareInstanceId: this.localShareInstanceId,
8574
+ // @ts-ignore
8575
+ shareDuration: this.webex.internal.newMetrics.callDiagnosticLatencies.getShareDuration()
8413
8576
  },
8414
8577
  options: {
8415
8578
  meetingId: this.id
@@ -8429,8 +8592,8 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8429
8592
  }).catch(function (error) {
8430
8593
  _loggerProxy.default.logger.error('Meeting:index#releaseScreenShareFloor --> Error ', error);
8431
8594
  _metrics.default.sendBehavioralMetric(_constants2.default.STOP_FLOOR_REQUEST_FAILURE, {
8432
- correlation_id: _this53.correlationId,
8433
- locus_id: _this53.locusUrl.split('/').pop(),
8595
+ correlation_id: _this55.correlationId,
8596
+ locus_id: _this55.locusUrl.split('/').pop(),
8434
8597
  reason: error.message,
8435
8598
  stack: error.stack
8436
8599
  });
@@ -8610,7 +8773,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8610
8773
  }, {
8611
8774
  key: "changeVideoLayout",
8612
8775
  value: function changeVideoLayout(layoutType) {
8613
- var _this54 = this;
8776
+ var _this56 = this;
8614
8777
  var renderInfo = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
8615
8778
  var main = renderInfo.main,
8616
8779
  content = renderInfo.content;
@@ -8664,7 +8827,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8664
8827
  }
8665
8828
  this.lastVideoLayoutInfo = (0, _lodash.cloneDeep)(layoutInfo);
8666
8829
  this.locusInfo.once(_constants.LOCUSINFO.EVENTS.CONTROLS_MEETING_LAYOUT_UPDATED, function (envelope) {
8667
- _triggerProxy.default.trigger(_this54, {
8830
+ _triggerProxy.default.trigger(_this56, {
8668
8831
  file: 'meeting/index',
8669
8832
  function: 'changeVideoLayout'
8670
8833
  }, _constants.EVENT_TRIGGERS.MEETING_CONTROLS_LAYOUT_UPDATE, {
@@ -8780,7 +8943,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8780
8943
  }, {
8781
8944
  key: "endMeetingForAll",
8782
8945
  value: function endMeetingForAll() {
8783
- var _this55 = this;
8946
+ var _this57 = this;
8784
8947
  // @ts-ignore
8785
8948
  this.webex.internal.newMetrics.submitClientEvent({
8786
8949
  name: 'client.call.leave',
@@ -8798,25 +8961,25 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8798
8961
  locus_id: this.locusId
8799
8962
  });
8800
8963
  return _util2.default.endMeetingForAll(this).then(function (end) {
8801
- _this55.meetingFiniteStateMachine.end();
8802
- _this55.clearMeetingData();
8964
+ _this57.meetingFiniteStateMachine.end();
8965
+ _this57.clearMeetingData();
8803
8966
  // upload logs on leave irrespective of meeting delete
8804
- _triggerProxy.default.trigger(_this55, {
8967
+ _triggerProxy.default.trigger(_this57, {
8805
8968
  file: 'meeting/index',
8806
8969
  function: 'endMeetingForAll'
8807
- }, _constants.EVENTS.REQUEST_UPLOAD_LOGS, _this55);
8970
+ }, _constants.EVENTS.REQUEST_UPLOAD_LOGS, _this57);
8808
8971
  return end;
8809
8972
  }).catch(function (error) {
8810
- _this55.meetingFiniteStateMachine.fail(error);
8973
+ _this57.meetingFiniteStateMachine.fail(error);
8811
8974
  _loggerProxy.default.logger.error('Meeting:index#endMeetingForAll --> Failed to end meeting ', error);
8812
8975
  // upload logs on leave irrespective of meeting delete
8813
- _triggerProxy.default.trigger(_this55, {
8976
+ _triggerProxy.default.trigger(_this57, {
8814
8977
  file: 'meeting/index',
8815
8978
  function: 'endMeetingForAll'
8816
- }, _constants.EVENTS.REQUEST_UPLOAD_LOGS, _this55);
8979
+ }, _constants.EVENTS.REQUEST_UPLOAD_LOGS, _this57);
8817
8980
  _metrics.default.sendBehavioralMetric(_constants2.default.MEETING_END_ALL_FAILURE, {
8818
- correlation_id: _this55.correlationId,
8819
- locus_id: _this55.locusUrl.split('/').pop(),
8981
+ correlation_id: _this57.correlationId,
8982
+ locus_id: _this57.locusUrl.split('/').pop(),
8820
8983
  reason: error.message,
8821
8984
  stack: error.stack,
8822
8985
  code: error.code
@@ -8977,7 +9140,7 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
8977
9140
  _this$mediaProperties43,
8978
9141
  _this$mediaProperties44,
8979
9142
  _this$mediaProperties45,
8980
- _this56 = this;
9143
+ _this58 = this;
8981
9144
  var LOG_HEADER = 'Meeting:index#updateTranscodedMediaConnection -->';
8982
9145
  _loggerProxy.default.logger.info("".concat(LOG_HEADER, " starting"));
8983
9146
  if (!this.canUpdateMedia()) {
@@ -9002,8 +9165,8 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
9002
9165
  }).catch(function (error) {
9003
9166
  _loggerProxy.default.logger.error("".concat(LOG_HEADER, " Error: "), error);
9004
9167
  _metrics.default.sendBehavioralMetric(_constants2.default.UPDATE_MEDIA_FAILURE, {
9005
- correlation_id: _this56.correlationId,
9006
- locus_id: _this56.locusUrl.split('/').pop(),
9168
+ correlation_id: _this58.correlationId,
9169
+ locus_id: _this58.locusUrl.split('/').pop(),
9007
9170
  reason: error.message,
9008
9171
  stack: error.stack
9009
9172
  });
@@ -9225,13 +9388,18 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
9225
9388
  return this.updateTranscodedMediaConnection();
9226
9389
  case 31:
9227
9390
  if (!floorRequestNeeded) {
9228
- _context40.next = 39;
9391
+ _context40.next = 40;
9229
9392
  break;
9230
9393
  }
9231
9394
  this.localShareInstanceId = _uuid.default.v4();
9232
9395
  this.shareCAEventSentStatus.transmitStart = false;
9233
9396
  this.shareCAEventSentStatus.transmitStop = false;
9234
9397
 
9398
+ // @ts-ignore
9399
+ this.webex.internal.newMetrics.callDiagnosticLatencies.saveTimestamp({
9400
+ key: 'internal.client.share.initiated'
9401
+ });
9402
+
9235
9403
  // @ts-ignore
9236
9404
  this.webex.internal.newMetrics.submitClientEvent({
9237
9405
  name: 'client.share.initiated',
@@ -9251,9 +9419,9 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
9251
9419
  // we're sending the http request to Locus to request the screen share floor
9252
9420
  // only after the SDP update, because that's how it's always been done for transcoded meetings
9253
9421
  // and also if sharing from the start, we need confluence to have been created
9254
- _context40.next = 39;
9422
+ _context40.next = 40;
9255
9423
  return this.enqueueScreenShareFloorRequest();
9256
- case 39:
9424
+ case 40:
9257
9425
  case "end":
9258
9426
  return _context40.stop();
9259
9427
  }
@@ -9401,7 +9569,8 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
9401
9569
  key: "getMediaReachabilityMetricFields",
9402
9570
  value: (function () {
9403
9571
  var _getMediaReachabilityMetricFields = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee42() {
9404
- var reachabilityMetrics, successKeys, totalSuccessCases, isSubnetReachable, selectedCluster;
9572
+ var _this$mediaServerIp, _this$mediaConnection, _this$mediaConnection2, _this$mediaConnection3;
9573
+ var reachabilityMetrics, successKeys, totalSuccessCases, selectedSubnetFirstOctet, isSubnetReachable, selectedCluster;
9405
9574
  return _regenerator.default.wrap(function _callee42$(_context42) {
9406
9575
  while (1) switch (_context42.prev = _context42.next) {
9407
9576
  case 0:
@@ -9417,18 +9586,18 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
9417
9586
  }
9418
9587
  return total;
9419
9588
  }, 0);
9589
+ selectedSubnetFirstOctet = (_this$mediaServerIp = this.mediaServerIp) === null || _this$mediaServerIp === void 0 ? void 0 : _this$mediaServerIp.split('.')[0];
9420
9590
  isSubnetReachable = null;
9421
- if (totalSuccessCases > 0) {
9591
+ if (totalSuccessCases > 0 && selectedSubnetFirstOctet) {
9592
+ isSubnetReachable =
9422
9593
  // @ts-ignore
9423
- isSubnetReachable = this.webex.meetings.reachability.isSubnetReachable(this.mediaServerIp);
9424
- }
9425
- selectedCluster = null;
9426
- if (this.mediaConnections && this.mediaConnections.length > 0) {
9427
- selectedCluster = this.mediaConnections[0].mediaAgentCluster;
9594
+ this.webex.meetings.reachability.isSubnetReachable(selectedSubnetFirstOctet);
9428
9595
  }
9596
+ selectedCluster = (_this$mediaConnection = (_this$mediaConnection2 = this.mediaConnections) === null || _this$mediaConnection2 === void 0 ? void 0 : (_this$mediaConnection3 = _this$mediaConnection2[0]) === null || _this$mediaConnection3 === void 0 ? void 0 : _this$mediaConnection3.mediaAgentCluster) !== null && _this$mediaConnection !== void 0 ? _this$mediaConnection : null;
9429
9597
  return _context42.abrupt("return", _objectSpread(_objectSpread({}, reachabilityMetrics), {}, {
9430
- isSubnetReachable: isSubnetReachable,
9431
- selectedCluster: selectedCluster
9598
+ subnet_reachable: isSubnetReachable,
9599
+ selected_cluster: selectedCluster,
9600
+ selected_subnet: selectedSubnetFirstOctet ? "".concat(selectedSubnetFirstOctet, ".X.X.X") : null
9432
9601
  }));
9433
9602
  case 10:
9434
9603
  case "end":
@@ -9440,7 +9609,97 @@ var Meeting = exports.default = /*#__PURE__*/function (_StatelessWebexPlugin) {
9440
9609
  return _getMediaReachabilityMetricFields.apply(this, arguments);
9441
9610
  }
9442
9611
  return getMediaReachabilityMetricFields;
9443
- }())
9612
+ }()
9613
+ /**
9614
+ * Set the stage for the meeting
9615
+ *
9616
+ * @param {SetStageOptions} options Options to use when setting the stage
9617
+ * @returns {Promise} The locus request
9618
+ */
9619
+ )
9620
+ }, {
9621
+ key: "setStage",
9622
+ value: function setStage() {
9623
+ var _ref37 = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {},
9624
+ _ref37$activeSpeakerP = _ref37.activeSpeakerProportion,
9625
+ activeSpeakerProportion = _ref37$activeSpeakerP === void 0 ? 0.5 : _ref37$activeSpeakerP,
9626
+ customBackground = _ref37.customBackground,
9627
+ customLogo = _ref37.customLogo,
9628
+ customNameLabel = _ref37.customNameLabel,
9629
+ importantParticipants = _ref37.importantParticipants,
9630
+ _ref37$lockAttendeeVi = _ref37.lockAttendeeViewOnStage,
9631
+ lockAttendeeViewOnStage = _ref37$lockAttendeeVi === void 0 ? false : _ref37$lockAttendeeVi,
9632
+ _ref37$showActiveSpea = _ref37.showActiveSpeaker,
9633
+ showActiveSpeaker = _ref37$showActiveSpea === void 0 ? false : _ref37$showActiveSpea;
9634
+ var videoLayout = {
9635
+ overrideDefault: true,
9636
+ lockAttendeeViewOnStageOnly: lockAttendeeViewOnStage,
9637
+ stageParameters: {
9638
+ activeSpeakerProportion: activeSpeakerProportion,
9639
+ showActiveSpeaker: {
9640
+ show: showActiveSpeaker,
9641
+ order: 0
9642
+ },
9643
+ stageManagerType: 0
9644
+ }
9645
+ };
9646
+ if (importantParticipants !== null && importantParticipants !== void 0 && importantParticipants.length) {
9647
+ videoLayout.stageParameters.importantParticipants = importantParticipants.map(function (importantParticipant, index) {
9648
+ return _objectSpread(_objectSpread({}, importantParticipant), {}, {
9649
+ order: index + 1
9650
+ });
9651
+ });
9652
+ }
9653
+ if (customLogo) {
9654
+ if (!videoLayout.customLayouts) {
9655
+ videoLayout.customLayouts = {};
9656
+ }
9657
+ videoLayout.customLayouts.logo = customLogo;
9658
+ // eslint-disable-next-line no-bitwise
9659
+ videoLayout.stageParameters.stageManagerType |= _constants.STAGE_MANAGER_TYPE.LOGO;
9660
+ }
9661
+ if (customBackground) {
9662
+ if (!videoLayout.customLayouts) {
9663
+ videoLayout.customLayouts = {};
9664
+ }
9665
+ videoLayout.customLayouts.background = customBackground;
9666
+ // eslint-disable-next-line no-bitwise
9667
+ videoLayout.stageParameters.stageManagerType |= _constants.STAGE_MANAGER_TYPE.BACKGROUND;
9668
+ }
9669
+ if (customNameLabel) {
9670
+ videoLayout.nameLabelStyle = customNameLabel;
9671
+ // eslint-disable-next-line no-bitwise
9672
+ videoLayout.stageParameters.stageManagerType |= _constants.STAGE_MANAGER_TYPE.NAME_LABEL;
9673
+ }
9674
+ return this.meetingRequest.synchronizeStage(this.locusUrl, videoLayout);
9675
+ }
9676
+
9677
+ /**
9678
+ * Unset the stage for the meeting
9679
+ *
9680
+ * @returns {Promise} The locus request
9681
+ */
9682
+ }, {
9683
+ key: "unsetStage",
9684
+ value: function unsetStage() {
9685
+ var videoLayout = {
9686
+ overrideDefault: false
9687
+ };
9688
+ return this.meetingRequest.synchronizeStage(this.locusUrl, videoLayout);
9689
+ }
9690
+
9691
+ /**
9692
+ * Notifies the host with the given meeting UUID and display names.
9693
+ *
9694
+ * @param {string} meetingUuid - The UUID of the meeting.
9695
+ * @param {string[]} displayName - An array of display names to notify the host with.
9696
+ * @returns {Promise<any>} The result of the notifyHost request.
9697
+ */
9698
+ }, {
9699
+ key: "notifyHost",
9700
+ value: function notifyHost(meetingUuid, displayName) {
9701
+ return this.meetingRequest.notifyHost(this.meetingInfo.siteFullUrl, this.locusId, meetingUuid, displayName);
9702
+ }
9444
9703
  }]);
9445
9704
  return Meeting;
9446
9705
  }(_webexCore.StatelessWebexPlugin);