@webex/plugin-meetings 3.0.0-test.1 → 3.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (431) hide show
  1. package/.eslintrc.js +6 -0
  2. package/babel.config.js +3 -0
  3. package/dist/annotation/constants.js +12 -20
  4. package/dist/annotation/constants.js.map +1 -1
  5. package/dist/annotation/index.js +25 -10
  6. package/dist/annotation/index.js.map +1 -1
  7. package/dist/breakouts/breakout.js +2 -3
  8. package/dist/breakouts/breakout.js.map +1 -1
  9. package/dist/breakouts/collection.js +1 -2
  10. package/dist/breakouts/collection.js.map +1 -1
  11. package/dist/breakouts/edit-lock-error.js +1 -2
  12. package/dist/breakouts/edit-lock-error.js.map +1 -1
  13. package/dist/breakouts/events.js +1 -2
  14. package/dist/breakouts/events.js.map +1 -1
  15. package/dist/breakouts/index.js +13 -14
  16. package/dist/breakouts/index.js.map +1 -1
  17. package/dist/breakouts/request.js +1 -2
  18. package/dist/breakouts/request.js.map +1 -1
  19. package/dist/breakouts/utils.js +3 -6
  20. package/dist/breakouts/utils.js.map +1 -1
  21. package/dist/common/browser-detection.js +2 -3
  22. package/dist/common/browser-detection.js.map +1 -1
  23. package/dist/common/collection.js +3 -4
  24. package/dist/common/collection.js.map +1 -1
  25. package/dist/common/config.js +1 -2
  26. package/dist/common/config.js.map +1 -1
  27. package/dist/common/errors/captcha-error.js +1 -2
  28. package/dist/common/errors/captcha-error.js.map +1 -1
  29. package/dist/common/errors/intent-to-join.js +1 -2
  30. package/dist/common/errors/intent-to-join.js.map +1 -1
  31. package/dist/common/errors/join-meeting.js +1 -2
  32. package/dist/common/errors/join-meeting.js.map +1 -1
  33. package/dist/common/errors/media.js +1 -2
  34. package/dist/common/errors/media.js.map +1 -1
  35. package/dist/common/errors/no-meeting-info.js +1 -2
  36. package/dist/common/errors/no-meeting-info.js.map +1 -1
  37. package/dist/common/errors/parameter.js +3 -4
  38. package/dist/common/errors/parameter.js.map +1 -1
  39. package/dist/common/errors/password-error.js +1 -2
  40. package/dist/common/errors/password-error.js.map +1 -1
  41. package/dist/common/errors/permission.js +1 -2
  42. package/dist/common/errors/permission.js.map +1 -1
  43. package/dist/common/errors/reclaim-host-role-errors.js +6 -10
  44. package/dist/common/errors/reclaim-host-role-errors.js.map +1 -1
  45. package/dist/common/errors/reconnection-in-progress.js +1 -2
  46. package/dist/common/errors/reconnection-in-progress.js.map +1 -1
  47. package/dist/common/errors/reconnection.js +1 -2
  48. package/dist/common/errors/reconnection.js.map +1 -1
  49. package/dist/common/errors/stats.js +1 -2
  50. package/dist/common/errors/stats.js.map +1 -1
  51. package/dist/common/errors/webex-errors.js +14 -15
  52. package/dist/common/errors/webex-errors.js.map +1 -1
  53. package/dist/common/errors/webex-meetings-error.js +1 -2
  54. package/dist/common/errors/webex-meetings-error.js.map +1 -1
  55. package/dist/common/events/events-scope.js +1 -2
  56. package/dist/common/events/events-scope.js.map +1 -1
  57. package/dist/common/events/events.js +1 -2
  58. package/dist/common/events/events.js.map +1 -1
  59. package/dist/common/events/trigger-proxy.js +1 -2
  60. package/dist/common/events/trigger-proxy.js.map +1 -1
  61. package/dist/common/events/util.js +1 -2
  62. package/dist/common/events/util.js.map +1 -1
  63. package/dist/common/logs/logger-config.js +1 -2
  64. package/dist/common/logs/logger-config.js.map +1 -1
  65. package/dist/common/logs/logger-proxy.js +1 -2
  66. package/dist/common/logs/logger-proxy.js.map +1 -1
  67. package/dist/{types/common → common}/logs/request.d.ts +1 -1
  68. package/dist/common/logs/request.js +3 -4
  69. package/dist/common/logs/request.js.map +1 -1
  70. package/dist/common/queue.js +2 -4
  71. package/dist/common/queue.js.map +1 -1
  72. package/dist/{types/config.d.ts → config.d.ts} +1 -0
  73. package/dist/config.js +4 -3
  74. package/dist/config.js.map +1 -1
  75. package/dist/{types/constants.d.ts → constants.d.ts} +10 -5
  76. package/dist/constants.js +207 -380
  77. package/dist/constants.js.map +1 -1
  78. package/dist/controls-options-manager/constants.js +3 -6
  79. package/dist/controls-options-manager/constants.js.map +1 -1
  80. package/dist/controls-options-manager/enums.js +7 -10
  81. package/dist/controls-options-manager/enums.js.map +1 -1
  82. package/dist/controls-options-manager/index.js +27 -32
  83. package/dist/controls-options-manager/index.js.map +1 -1
  84. package/dist/controls-options-manager/util.js +1 -2
  85. package/dist/controls-options-manager/util.js.map +1 -1
  86. package/dist/index.js +3 -4
  87. package/dist/index.js.map +1 -1
  88. package/dist/interceptors/index.js.map +1 -1
  89. package/dist/interceptors/locusRetry.js +4 -3
  90. package/dist/interceptors/locusRetry.js.map +1 -1
  91. package/dist/interpretation/collection.js +1 -2
  92. package/dist/interpretation/collection.js.map +1 -1
  93. package/dist/interpretation/index.js +4 -5
  94. package/dist/interpretation/index.js.map +1 -1
  95. package/dist/interpretation/siLanguage.js +2 -3
  96. package/dist/interpretation/siLanguage.js.map +1 -1
  97. package/dist/locus-info/controlsUtils.js +12 -13
  98. package/dist/locus-info/controlsUtils.js.map +1 -1
  99. package/dist/locus-info/embeddedAppsUtils.js +3 -4
  100. package/dist/locus-info/embeddedAppsUtils.js.map +1 -1
  101. package/dist/locus-info/fullState.js +1 -2
  102. package/dist/locus-info/fullState.js.map +1 -1
  103. package/dist/locus-info/hostUtils.js +1 -2
  104. package/dist/locus-info/hostUtils.js.map +1 -1
  105. package/dist/locus-info/index.js +23 -27
  106. package/dist/locus-info/index.js.map +1 -1
  107. package/dist/locus-info/infoUtils.js +3 -4
  108. package/dist/locus-info/infoUtils.js.map +1 -1
  109. package/dist/locus-info/mediaSharesUtils.js +16 -3
  110. package/dist/locus-info/mediaSharesUtils.js.map +1 -1
  111. package/dist/locus-info/parser.js +6 -10
  112. package/dist/locus-info/parser.js.map +1 -1
  113. package/dist/locus-info/selfUtils.js +12 -6
  114. package/dist/locus-info/selfUtils.js.map +1 -1
  115. package/dist/media/MediaConnectionAwaiter.d.ts +61 -0
  116. package/dist/media/MediaConnectionAwaiter.js +163 -0
  117. package/dist/media/MediaConnectionAwaiter.js.map +1 -0
  118. package/dist/media/index.js +9 -5
  119. package/dist/media/index.js.map +1 -1
  120. package/dist/media/properties.js +7 -28
  121. package/dist/media/properties.js.map +1 -1
  122. package/dist/media/util.js +1 -2
  123. package/dist/media/util.js.map +1 -1
  124. package/dist/mediaQualityMetrics/config.js +9 -18
  125. package/dist/mediaQualityMetrics/config.js.map +1 -1
  126. package/dist/meeting/in-meeting-actions.js +14 -2
  127. package/dist/meeting/in-meeting-actions.js.map +1 -1
  128. package/dist/{types/meeting → meeting}/index.d.ts +71 -16
  129. package/dist/meeting/index.js +1411 -1036
  130. package/dist/meeting/index.js.map +1 -1
  131. package/dist/meeting/locusMediaRequest.js +4 -5
  132. package/dist/meeting/locusMediaRequest.js.map +1 -1
  133. package/dist/meeting/muteState.js +2 -4
  134. package/dist/meeting/muteState.js.map +1 -1
  135. package/dist/{types/meeting → meeting}/request.d.ts +3 -0
  136. package/dist/meeting/request.js +45 -36
  137. package/dist/meeting/request.js.map +1 -1
  138. package/dist/meeting/state.js +1 -2
  139. package/dist/meeting/state.js.map +1 -1
  140. package/dist/{types/meeting → meeting}/util.d.ts +1 -0
  141. package/dist/meeting/util.js +13 -10
  142. package/dist/meeting/util.js.map +1 -1
  143. package/dist/meeting/voicea-meeting.d.ts +16 -0
  144. package/dist/meeting/voicea-meeting.js +169 -0
  145. package/dist/meeting/voicea-meeting.js.map +1 -0
  146. package/dist/meeting-info/collection.js +3 -4
  147. package/dist/meeting-info/collection.js.map +1 -1
  148. package/dist/meeting-info/index.js +5 -4
  149. package/dist/meeting-info/index.js.map +1 -1
  150. package/dist/meeting-info/meeting-info-v2.js +27 -29
  151. package/dist/meeting-info/meeting-info-v2.js.map +1 -1
  152. package/dist/meeting-info/request.js +1 -2
  153. package/dist/meeting-info/request.js.map +1 -1
  154. package/dist/meeting-info/util.js +8 -8
  155. package/dist/meeting-info/util.js.map +1 -1
  156. package/dist/meeting-info/utilv2.js +15 -9
  157. package/dist/meeting-info/utilv2.js.map +1 -1
  158. package/dist/meetings/collection.js +5 -6
  159. package/dist/meetings/collection.js.map +1 -1
  160. package/dist/{types/meetings → meetings}/index.d.ts +11 -2
  161. package/dist/meetings/index.js +44 -17
  162. package/dist/meetings/index.js.map +1 -1
  163. package/dist/meetings/request.js +2 -3
  164. package/dist/meetings/request.js.map +1 -1
  165. package/dist/meetings/util.js +1 -4
  166. package/dist/meetings/util.js.map +1 -1
  167. package/dist/member/index.js +1 -3
  168. package/dist/member/index.js.map +1 -1
  169. package/dist/member/types.js +6 -8
  170. package/dist/member/types.js.map +1 -1
  171. package/dist/member/util.js +1 -2
  172. package/dist/member/util.js.map +1 -1
  173. package/dist/members/collection.js +1 -2
  174. package/dist/members/collection.js.map +1 -1
  175. package/dist/members/index.js +8 -7
  176. package/dist/members/index.js.map +1 -1
  177. package/dist/members/request.js +2 -3
  178. package/dist/members/request.js.map +1 -1
  179. package/dist/members/types.js +3 -4
  180. package/dist/members/types.js.map +1 -1
  181. package/dist/{types/members → members}/util.d.ts +1 -1
  182. package/dist/members/util.js +3 -4
  183. package/dist/members/util.js.map +1 -1
  184. package/dist/metrics/constants.js +1 -2
  185. package/dist/metrics/constants.js.map +1 -1
  186. package/dist/metrics/index.js +3 -2
  187. package/dist/metrics/index.js.map +1 -1
  188. package/dist/{types/multistream → multistream}/mediaRequestManager.d.ts +1 -2
  189. package/dist/multistream/mediaRequestManager.js +9 -11
  190. package/dist/multistream/mediaRequestManager.js.map +1 -1
  191. package/dist/multistream/receiveSlot.js +3 -5
  192. package/dist/multistream/receiveSlot.js.map +1 -1
  193. package/dist/multistream/receiveSlotManager.js +7 -9
  194. package/dist/multistream/receiveSlotManager.js.map +1 -1
  195. package/dist/multistream/remoteMedia.js +3 -5
  196. package/dist/multistream/remoteMedia.js.map +1 -1
  197. package/dist/{types/multistream → multistream}/remoteMediaGroup.d.ts +1 -1
  198. package/dist/multistream/remoteMediaGroup.js +7 -6
  199. package/dist/multistream/remoteMediaGroup.js.map +1 -1
  200. package/dist/{types/multistream → multistream}/remoteMediaManager.d.ts +1 -2
  201. package/dist/multistream/remoteMediaManager.js +32 -29
  202. package/dist/multistream/remoteMediaManager.js.map +1 -1
  203. package/dist/{types/multistream → multistream}/sendSlotManager.d.ts +1 -2
  204. package/dist/multistream/sendSlotManager.js +9 -6
  205. package/dist/multistream/sendSlotManager.js.map +1 -1
  206. package/dist/networkQualityMonitor/index.js +1 -2
  207. package/dist/networkQualityMonitor/index.js.map +1 -1
  208. package/dist/personal-meeting-room/index.js +2 -3
  209. package/dist/personal-meeting-room/index.js.map +1 -1
  210. package/dist/personal-meeting-room/request.js +2 -3
  211. package/dist/personal-meeting-room/request.js.map +1 -1
  212. package/dist/personal-meeting-room/util.js +1 -2
  213. package/dist/personal-meeting-room/util.js.map +1 -1
  214. package/dist/{types/reachability → reachability}/clusterReachability.d.ts +1 -0
  215. package/dist/reachability/clusterReachability.js +35 -20
  216. package/dist/reachability/clusterReachability.js.map +1 -1
  217. package/dist/{types/reachability → reachability}/index.d.ts +4 -0
  218. package/dist/reachability/index.js +41 -12
  219. package/dist/reachability/index.js.map +1 -1
  220. package/dist/reachability/request.js +25 -20
  221. package/dist/reachability/request.js.map +1 -1
  222. package/dist/{types/reachability → reachability}/util.d.ts +7 -0
  223. package/dist/reachability/util.js +19 -0
  224. package/dist/reachability/util.js.map +1 -1
  225. package/dist/reactions/constants.js +1 -2
  226. package/dist/reactions/constants.js.map +1 -1
  227. package/dist/reactions/reactions.js +2 -4
  228. package/dist/reactions/reactions.js.map +1 -1
  229. package/dist/reactions/reactions.type.js +6 -8
  230. package/dist/reactions/reactions.type.js.map +1 -1
  231. package/dist/reconnection-manager/index.js +18 -11
  232. package/dist/reconnection-manager/index.js.map +1 -1
  233. package/dist/recording-controller/enums.js +4 -5
  234. package/dist/recording-controller/enums.js.map +1 -1
  235. package/dist/recording-controller/index.js +43 -51
  236. package/dist/recording-controller/index.js.map +1 -1
  237. package/dist/recording-controller/util.js +1 -2
  238. package/dist/recording-controller/util.js.map +1 -1
  239. package/dist/{types/roap → roap}/index.d.ts +10 -2
  240. package/dist/roap/index.js +17 -3
  241. package/dist/roap/index.js.map +1 -1
  242. package/dist/roap/request.js +10 -10
  243. package/dist/roap/request.js.map +1 -1
  244. package/dist/{types/roap → roap}/turnDiscovery.d.ts +64 -17
  245. package/dist/roap/turnDiscovery.js +316 -134
  246. package/dist/roap/turnDiscovery.js.map +1 -1
  247. package/dist/rtcMetrics/constants.js +1 -2
  248. package/dist/rtcMetrics/constants.js.map +1 -1
  249. package/dist/rtcMetrics/index.js +4 -6
  250. package/dist/rtcMetrics/index.js.map +1 -1
  251. package/dist/statsAnalyzer/global.js +1 -2
  252. package/dist/statsAnalyzer/global.js.map +1 -1
  253. package/dist/statsAnalyzer/index.js +123 -96
  254. package/dist/statsAnalyzer/index.js.map +1 -1
  255. package/dist/statsAnalyzer/mqaUtil.js +24 -31
  256. package/dist/statsAnalyzer/mqaUtil.js.map +1 -1
  257. package/dist/transcription/index.js +1 -2
  258. package/dist/transcription/index.js.map +1 -1
  259. package/dist/webinar/collection.js +1 -2
  260. package/dist/webinar/collection.js.map +1 -1
  261. package/dist/webinar/index.js +2 -3
  262. package/dist/webinar/index.js.map +1 -1
  263. package/jest.config.js +3 -0
  264. package/package.json +44 -25
  265. package/process +1 -0
  266. package/src/config.ts +3 -4
  267. package/src/constants.ts +13 -4
  268. package/src/interpretation/index.ts +2 -2
  269. package/src/locus-info/mediaSharesUtils.ts +16 -0
  270. package/src/locus-info/selfUtils.ts +5 -0
  271. package/src/media/MediaConnectionAwaiter.ts +174 -0
  272. package/src/media/index.ts +3 -1
  273. package/src/media/properties.ts +6 -31
  274. package/src/meeting/index.ts +526 -227
  275. package/src/meeting/request.ts +18 -2
  276. package/src/meeting/util.ts +6 -1
  277. package/src/meeting/voicea-meeting.ts +122 -0
  278. package/src/meeting-info/meeting-info-v2.ts +5 -11
  279. package/src/meeting-info/util.ts +12 -9
  280. package/src/meeting-info/utilv2.ts +26 -15
  281. package/src/meetings/index.ts +18 -0
  282. package/src/member/index.ts +0 -1
  283. package/src/multistream/mediaRequestManager.ts +1 -1
  284. package/src/multistream/remoteMediaGroup.ts +1 -1
  285. package/src/multistream/remoteMediaManager.ts +1 -2
  286. package/src/multistream/sendSlotManager.ts +1 -2
  287. package/src/reachability/clusterReachability.ts +20 -5
  288. package/src/reachability/index.ts +24 -1
  289. package/src/reachability/request.ts +15 -11
  290. package/src/reachability/util.ts +21 -0
  291. package/src/reconnection-manager/index.ts +1 -1
  292. package/src/roap/index.ts +25 -3
  293. package/src/roap/request.ts +2 -2
  294. package/src/roap/turnDiscovery.ts +244 -78
  295. package/src/statsAnalyzer/index.ts +63 -27
  296. package/test/integration/spec/journey.js +2 -2
  297. package/test/unit/spec/breakouts/breakout.ts +2 -1
  298. package/test/unit/spec/breakouts/index.ts +7 -4
  299. package/test/unit/spec/interpretation/index.ts +4 -1
  300. package/test/unit/spec/locus-info/index.js +27 -18
  301. package/test/unit/spec/locus-info/mediaSharesUtils.ts +9 -0
  302. package/test/unit/spec/locus-info/selfUtils.js +41 -11
  303. package/test/unit/spec/media/MediaConnectionAwaiter.ts +344 -0
  304. package/test/unit/spec/media/index.ts +94 -78
  305. package/test/unit/spec/media/properties.ts +16 -70
  306. package/test/unit/spec/meeting/index.js +757 -141
  307. package/test/unit/spec/meeting/request.js +21 -0
  308. package/test/unit/spec/meeting/utils.js +58 -11
  309. package/test/unit/spec/meeting/voicea-meeting.ts +266 -0
  310. package/test/unit/spec/meeting-info/meetinginfov2.js +20 -15
  311. package/test/unit/spec/meeting-info/utilv2.js +6 -0
  312. package/test/unit/spec/meetings/index.js +101 -13
  313. package/test/unit/spec/metrics/index.js +1 -2
  314. package/test/unit/spec/multistream/mediaRequestManager.ts +1 -0
  315. package/test/unit/spec/multistream/remoteMediaGroup.ts +0 -1
  316. package/test/unit/spec/multistream/remoteMediaManager.ts +0 -1
  317. package/test/unit/spec/reachability/clusterReachability.ts +86 -22
  318. package/test/unit/spec/reachability/index.ts +197 -60
  319. package/test/unit/spec/reachability/request.js +15 -7
  320. package/test/unit/spec/reachability/util.ts +32 -2
  321. package/test/unit/spec/reconnection-manager/index.js +28 -0
  322. package/test/unit/spec/recording-controller/index.js +0 -1
  323. package/test/unit/spec/roap/index.ts +61 -6
  324. package/test/unit/spec/roap/turnDiscovery.ts +299 -17
  325. package/test/unit/spec/stats-analyzer/index.js +179 -0
  326. /package/dist/{types/annotation → annotation}/annotation.types.d.ts +0 -0
  327. /package/dist/{types/annotation → annotation}/constants.d.ts +0 -0
  328. /package/dist/{types/annotation → annotation}/index.d.ts +0 -0
  329. /package/dist/{types/breakouts → breakouts}/breakout.d.ts +0 -0
  330. /package/dist/{types/breakouts → breakouts}/collection.d.ts +0 -0
  331. /package/dist/{types/breakouts → breakouts}/edit-lock-error.d.ts +0 -0
  332. /package/dist/{types/breakouts → breakouts}/events.d.ts +0 -0
  333. /package/dist/{types/breakouts → breakouts}/index.d.ts +0 -0
  334. /package/dist/{types/breakouts → breakouts}/request.d.ts +0 -0
  335. /package/dist/{types/breakouts → breakouts}/utils.d.ts +0 -0
  336. /package/dist/{types/common → common}/browser-detection.d.ts +0 -0
  337. /package/dist/{types/common → common}/collection.d.ts +0 -0
  338. /package/dist/{types/common → common}/config.d.ts +0 -0
  339. /package/dist/{types/common → common}/errors/captcha-error.d.ts +0 -0
  340. /package/dist/{types/common → common}/errors/intent-to-join.d.ts +0 -0
  341. /package/dist/{types/common → common}/errors/join-meeting.d.ts +0 -0
  342. /package/dist/{types/common → common}/errors/media.d.ts +0 -0
  343. /package/dist/{types/common → common}/errors/no-meeting-info.d.ts +0 -0
  344. /package/dist/{types/common → common}/errors/parameter.d.ts +0 -0
  345. /package/dist/{types/common → common}/errors/password-error.d.ts +0 -0
  346. /package/dist/{types/common → common}/errors/permission.d.ts +0 -0
  347. /package/dist/{types/common → common}/errors/reclaim-host-role-errors.d.ts +0 -0
  348. /package/dist/{types/common → common}/errors/reconnection-in-progress.d.ts +0 -0
  349. /package/dist/{types/common → common}/errors/reconnection.d.ts +0 -0
  350. /package/dist/{types/common → common}/errors/stats.d.ts +0 -0
  351. /package/dist/{types/common → common}/errors/webex-errors.d.ts +0 -0
  352. /package/dist/{types/common → common}/errors/webex-meetings-error.d.ts +0 -0
  353. /package/dist/{types/common → common}/events/events-scope.d.ts +0 -0
  354. /package/dist/{types/common → common}/events/events.d.ts +0 -0
  355. /package/dist/{types/common → common}/events/trigger-proxy.d.ts +0 -0
  356. /package/dist/{types/common → common}/events/util.d.ts +0 -0
  357. /package/dist/{types/common → common}/logs/logger-config.d.ts +0 -0
  358. /package/dist/{types/common → common}/logs/logger-proxy.d.ts +0 -0
  359. /package/dist/{types/common → common}/queue.d.ts +0 -0
  360. /package/dist/{types/controls-options-manager → controls-options-manager}/constants.d.ts +0 -0
  361. /package/dist/{types/controls-options-manager → controls-options-manager}/enums.d.ts +0 -0
  362. /package/dist/{types/controls-options-manager → controls-options-manager}/index.d.ts +0 -0
  363. /package/dist/{types/controls-options-manager → controls-options-manager}/types.d.ts +0 -0
  364. /package/dist/{types/controls-options-manager → controls-options-manager}/util.d.ts +0 -0
  365. /package/dist/{types/index.d.ts → index.d.ts} +0 -0
  366. /package/dist/{types/interceptors → interceptors}/index.d.ts +0 -0
  367. /package/dist/{types/interceptors → interceptors}/locusRetry.d.ts +0 -0
  368. /package/dist/{types/interpretation → interpretation}/collection.d.ts +0 -0
  369. /package/dist/{types/interpretation → interpretation}/index.d.ts +0 -0
  370. /package/dist/{types/interpretation → interpretation}/siLanguage.d.ts +0 -0
  371. /package/dist/{types/locus-info → locus-info}/controlsUtils.d.ts +0 -0
  372. /package/dist/{types/locus-info → locus-info}/embeddedAppsUtils.d.ts +0 -0
  373. /package/dist/{types/locus-info → locus-info}/fullState.d.ts +0 -0
  374. /package/dist/{types/locus-info → locus-info}/hostUtils.d.ts +0 -0
  375. /package/dist/{types/locus-info → locus-info}/index.d.ts +0 -0
  376. /package/dist/{types/locus-info → locus-info}/infoUtils.d.ts +0 -0
  377. /package/dist/{types/locus-info → locus-info}/mediaSharesUtils.d.ts +0 -0
  378. /package/dist/{types/locus-info → locus-info}/parser.d.ts +0 -0
  379. /package/dist/{types/locus-info → locus-info}/selfUtils.d.ts +0 -0
  380. /package/dist/{types/media → media}/index.d.ts +0 -0
  381. /package/dist/{types/media → media}/properties.d.ts +0 -0
  382. /package/dist/{types/media → media}/util.d.ts +0 -0
  383. /package/dist/{types/mediaQualityMetrics → mediaQualityMetrics}/config.d.ts +0 -0
  384. /package/dist/{types/meeting → meeting}/in-meeting-actions.d.ts +0 -0
  385. /package/dist/{types/meeting → meeting}/locusMediaRequest.d.ts +0 -0
  386. /package/dist/{types/meeting → meeting}/muteState.d.ts +0 -0
  387. /package/dist/{types/meeting → meeting}/request.type.d.ts +0 -0
  388. /package/dist/{types/meeting → meeting}/state.d.ts +0 -0
  389. /package/dist/{types/meeting-info → meeting-info}/collection.d.ts +0 -0
  390. /package/dist/{types/meeting-info → meeting-info}/index.d.ts +0 -0
  391. /package/dist/{types/meeting-info → meeting-info}/meeting-info-v2.d.ts +0 -0
  392. /package/dist/{types/meeting-info → meeting-info}/request.d.ts +0 -0
  393. /package/dist/{types/meeting-info → meeting-info}/util.d.ts +0 -0
  394. /package/dist/{types/meeting-info → meeting-info}/utilv2.d.ts +0 -0
  395. /package/dist/{types/meetings → meetings}/collection.d.ts +0 -0
  396. /package/dist/{types/meetings → meetings}/meetings.types.d.ts +0 -0
  397. /package/dist/{types/meetings → meetings}/request.d.ts +0 -0
  398. /package/dist/{types/meetings → meetings}/util.d.ts +0 -0
  399. /package/dist/{types/member → member}/index.d.ts +0 -0
  400. /package/dist/{types/member → member}/types.d.ts +0 -0
  401. /package/dist/{types/member → member}/util.d.ts +0 -0
  402. /package/dist/{types/members → members}/collection.d.ts +0 -0
  403. /package/dist/{types/members → members}/index.d.ts +0 -0
  404. /package/dist/{types/members → members}/request.d.ts +0 -0
  405. /package/dist/{types/members → members}/types.d.ts +0 -0
  406. /package/dist/{types/metrics → metrics}/constants.d.ts +0 -0
  407. /package/dist/{types/metrics → metrics}/index.d.ts +0 -0
  408. /package/dist/{types/multistream → multistream}/receiveSlot.d.ts +0 -0
  409. /package/dist/{types/multistream → multistream}/receiveSlotManager.d.ts +0 -0
  410. /package/dist/{types/multistream → multistream}/remoteMedia.d.ts +0 -0
  411. /package/dist/{types/networkQualityMonitor → networkQualityMonitor}/index.d.ts +0 -0
  412. /package/dist/{types/personal-meeting-room → personal-meeting-room}/index.d.ts +0 -0
  413. /package/dist/{types/personal-meeting-room → personal-meeting-room}/request.d.ts +0 -0
  414. /package/dist/{types/personal-meeting-room → personal-meeting-room}/util.d.ts +0 -0
  415. /package/dist/{types/reachability → reachability}/request.d.ts +0 -0
  416. /package/dist/{types/reactions → reactions}/constants.d.ts +0 -0
  417. /package/dist/{types/reactions → reactions}/reactions.d.ts +0 -0
  418. /package/dist/{types/reactions → reactions}/reactions.type.d.ts +0 -0
  419. /package/dist/{types/reconnection-manager → reconnection-manager}/index.d.ts +0 -0
  420. /package/dist/{types/recording-controller → recording-controller}/enums.d.ts +0 -0
  421. /package/dist/{types/recording-controller → recording-controller}/index.d.ts +0 -0
  422. /package/dist/{types/recording-controller → recording-controller}/util.d.ts +0 -0
  423. /package/dist/{types/roap → roap}/request.d.ts +0 -0
  424. /package/dist/{types/rtcMetrics → rtcMetrics}/constants.d.ts +0 -0
  425. /package/dist/{types/rtcMetrics → rtcMetrics}/index.d.ts +0 -0
  426. /package/dist/{types/statsAnalyzer → statsAnalyzer}/global.d.ts +0 -0
  427. /package/dist/{types/statsAnalyzer → statsAnalyzer}/index.d.ts +0 -0
  428. /package/dist/{types/statsAnalyzer → statsAnalyzer}/mqaUtil.d.ts +0 -0
  429. /package/dist/{types/transcription → transcription}/index.d.ts +0 -0
  430. /package/dist/{types/webinar → webinar}/collection.d.ts +0 -0
  431. /package/dist/{types/webinar → webinar}/index.d.ts +0 -0
@@ -103,6 +103,7 @@ export default class MeetingRequest extends StatelessWebexPlugin {
103
103
  * @param {String} options.locale,
104
104
  * @param {Array} options.deviceCapabilities
105
105
  * @param {boolean} options.liveAnnotationSupported
106
+ * @param {String} options.alias
106
107
  * @returns {Promise}
107
108
  */
108
109
  async joinMeeting(options: {
@@ -122,11 +123,13 @@ export default class MeetingRequest extends StatelessWebexPlugin {
122
123
  meetingNumber: any;
123
124
  permissionToken: any;
124
125
  preferTranscoding: any;
126
+ reachability: any;
125
127
  breakoutsSupported: boolean;
126
128
  locale?: string;
127
129
  deviceCapabilities?: Array<string>;
128
130
  liveAnnotationSupported: boolean;
129
131
  ipVersion?: IP_VERSION;
132
+ alias?: string;
130
133
  }) {
131
134
  const {
132
135
  asResourceOccupant,
@@ -143,12 +146,14 @@ export default class MeetingRequest extends StatelessWebexPlugin {
143
146
  pin,
144
147
  moveToResource,
145
148
  roapMessage,
149
+ reachability,
146
150
  preferTranscoding,
147
151
  breakoutsSupported,
148
152
  locale,
149
153
  deviceCapabilities = [],
150
154
  liveAnnotationSupported,
151
155
  ipVersion,
156
+ alias,
152
157
  } = options;
153
158
 
154
159
  LoggerProxy.logger.info('Meeting:request#joinMeeting --> Joining a meeting', correlationId);
@@ -178,6 +183,10 @@ export default class MeetingRequest extends StatelessWebexPlugin {
178
183
  },
179
184
  };
180
185
 
186
+ if (alias) {
187
+ body.alias = alias;
188
+ }
189
+
181
190
  if (breakoutsSupported) {
182
191
  deviceCapabilities.push(BREAKOUTS.BREAKOUTS_SUPPORTED);
183
192
  }
@@ -260,8 +269,15 @@ export default class MeetingRequest extends StatelessWebexPlugin {
260
269
  };
261
270
  }
262
271
 
263
- if (roapMessage) {
264
- body.localMedias = roapMessage.localMedias;
272
+ if (roapMessage || reachability) {
273
+ body.localMedias = [
274
+ {
275
+ localSdp: JSON.stringify({
276
+ roapMessage,
277
+ reachability,
278
+ }),
279
+ },
280
+ ];
265
281
  }
266
282
 
267
283
  /// @ts-ignore
@@ -149,6 +149,7 @@ const MeetingUtil = {
149
149
  locusUrl: meeting.locusUrl,
150
150
  locusClusterUrl: meeting.meetingInfo?.locusClusterUrl,
151
151
  correlationId: meeting.correlationId,
152
+ reachability: options.reachability,
152
153
  roapMessage: options.roapMessage,
153
154
  permissionToken: meeting.permissionToken,
154
155
  resourceId: options.resourceId || null,
@@ -202,7 +203,11 @@ const MeetingUtil = {
202
203
  meeting.reconnectionManager.cleanUp();
203
204
  })
204
205
  .then(() => meeting.stopKeepAlive())
205
- .then(() => meeting.updateLLMConnection());
206
+ .then(() => {
207
+ if (meeting.config?.enableAutomaticLLM) {
208
+ meeting.updateLLMConnection();
209
+ }
210
+ });
206
211
  },
207
212
 
208
213
  disconnectPhoneAudio: (meeting, phoneUrl) => {
@@ -0,0 +1,122 @@
1
+ export const getSpeaker = (members, csis = []) =>
2
+ Object.values(members).find((member: any) => {
3
+ const memberCSIs = member.participant.status.csis ?? [];
4
+
5
+ return csis.some((csi) => memberCSIs.includes(csi));
6
+ });
7
+
8
+ export const getSpeakerFromProxyOrStore = ({csisKey, meetingMembers, transcriptData}) => {
9
+ let speaker = {
10
+ speakerId: '',
11
+ name: '',
12
+ };
13
+
14
+ let needsCaching = false;
15
+
16
+ if (csisKey && transcriptData.speakerProxy[csisKey]) {
17
+ speaker = transcriptData.speakerProxy[csisKey];
18
+
19
+ return {speaker, needsCaching};
20
+ }
21
+
22
+ const meetingMember: any = getSpeaker(meetingMembers, [csisKey]);
23
+
24
+ speaker = {
25
+ speakerId: meetingMember?.participant.person.id ?? '',
26
+ name: meetingMember?.participant.person.name ?? '',
27
+ };
28
+
29
+ needsCaching = true;
30
+
31
+ return {speaker, needsCaching};
32
+ };
33
+
34
+ export const processNewCaptions = ({data, meeting}) => {
35
+ const {transcriptId} = data;
36
+ const transcriptData = meeting.transcription;
37
+
38
+ if (data.isFinal) {
39
+ transcriptData.interimCaptions[transcriptId].forEach((interimId) => {
40
+ const interimTranscriptIndex = transcriptData.captions.findIndex(
41
+ (transcript) => transcript.id === interimId
42
+ );
43
+
44
+ if (interimTranscriptIndex !== -1) {
45
+ transcriptData.captions.splice(interimTranscriptIndex, 1);
46
+ }
47
+ });
48
+ delete transcriptData.interimCaptions[transcriptId];
49
+ const csisKey = data.transcript?.csis[0];
50
+
51
+ const {needsCaching, speaker} = getSpeakerFromProxyOrStore({
52
+ meetingMembers: meeting.members.membersCollection.members,
53
+ transcriptData,
54
+ csisKey,
55
+ });
56
+
57
+ if (needsCaching) {
58
+ transcriptData.speakerProxy[csisKey] = speaker;
59
+ }
60
+ const captionData = {
61
+ id: transcriptId,
62
+ isFinal: data.isFinal,
63
+ translations: data.translations,
64
+ text: data.transcript?.text,
65
+ currentSpokenLanguage: data.transcript?.transcript_language_code,
66
+ timestamp: data.timestamp,
67
+ speaker,
68
+ };
69
+ transcriptData.captions.push(captionData);
70
+ }
71
+ const {transcripts = []} = data;
72
+ const transcriptsPerCsis = new Map();
73
+
74
+ for (const transcript of transcripts) {
75
+ const {
76
+ text,
77
+ transcript_language_code: currentSpokenLanguage,
78
+ csis: [csisMember],
79
+ } = transcript;
80
+
81
+ const newCaption = `${transcriptsPerCsis.get(csisMember)?.text ?? ''} ${text}`.trim();
82
+
83
+ // eslint-disable-next-line camelcase
84
+ transcriptsPerCsis.set(csisMember, {text: newCaption, currentSpokenLanguage});
85
+ }
86
+ const interimTranscriptionIds = [];
87
+
88
+ for (const [key, value] of transcriptsPerCsis) {
89
+ const {needsCaching, speaker} = getSpeakerFromProxyOrStore({
90
+ meetingMembers: meeting.members.membersCollection.members,
91
+ transcriptData,
92
+ csisKey: key,
93
+ });
94
+
95
+ if (needsCaching) {
96
+ transcriptData.speakerProxy[key] = speaker;
97
+ }
98
+ const {speakerId} = speaker;
99
+ const interimId = `${transcriptId}_${speakerId}`;
100
+ const captionData = {
101
+ id: interimId,
102
+ isFinal: data.isFinal,
103
+ translations: value.translations,
104
+ text: value.text,
105
+ currentCaptionLanguage: value.currentSpokenLanguage,
106
+ timestamp: value?.timestamp,
107
+ speaker,
108
+ };
109
+
110
+ const interimTranscriptIndex = transcriptData.captions.findIndex(
111
+ (transcript) => transcript.id === interimId
112
+ );
113
+
114
+ if (interimTranscriptIndex !== -1) {
115
+ transcriptData.captions.splice(interimTranscriptIndex, 1);
116
+ }
117
+
118
+ interimTranscriptionIds.push(interimId);
119
+ transcriptData.captions.push(captionData);
120
+ }
121
+ transcriptData.interimCaptions[transcriptId] = interimTranscriptionIds;
122
+ };
@@ -204,22 +204,16 @@ export default class MeetingInfoV2 {
204
204
  return invitees;
205
205
  };
206
206
 
207
- return this.webex.internal.conversation
208
- .get({url: conversationUrl}, {includeParticipants: true, disableTransform: true})
209
- .then((conversation) => {
210
- const body: {
211
- title: string;
212
- spaceUrl: string;
213
- keyUrl: string;
214
- kroUrl: string;
215
- invitees: any[];
216
- installedOrgID?: string;
217
- } = {
207
+ return this.webex
208
+ .request({uri: conversationUrl, qs: {includeParticipants: true}, disableTransform: true})
209
+ .then(({body: conversation}) => {
210
+ const body = {
218
211
  title: conversation.displayName,
219
212
  spaceUrl: conversation.url,
220
213
  keyUrl: conversation.encryptionKeyUrl,
221
214
  kroUrl: conversation.kmsResourceObjectUrl,
222
215
  invitees: getInvitees(conversation.participants?.items),
216
+ installedOrgID,
223
217
  };
224
218
 
225
219
  if (installedOrgID) {
@@ -1,13 +1,12 @@
1
1
  import url from 'url';
2
2
 
3
3
  import btoa from 'btoa';
4
- import {
5
- // @ts-ignore
6
- deconstructHydraId,
7
- } from '@webex/common';
4
+ // @ts-ignore
5
+ import {deconstructHydraId} from '@webex/common';
8
6
 
9
7
  import ParameterError from '../common/errors/parameter';
10
8
  import LoggerProxy from '../common/logs/logger-proxy';
9
+
11
10
  import {
12
11
  _SIP_URI_,
13
12
  _PERSONAL_ROOM_,
@@ -221,12 +220,16 @@ MeetingInfoUtil.generateOptions = async (from) => {
221
220
  try {
222
221
  await webex.internal.services.waitForCatalog('postauth');
223
222
 
224
- const conversationUrl = webex.internal.conversation.getUrlFromClusterId({
225
- cluster: hydraId.cluster,
226
- id: hydraId.destination,
227
- });
223
+ const serviceUrl = webex.internal.services.getServiceUrlFromClusterId(
224
+ {
225
+ cluster: hydraId.cluster,
226
+ },
227
+ webex
228
+ );
228
229
 
229
- options.destination = conversationUrl;
230
+ options.destination = hydraId.destination
231
+ ? `${serviceUrl}/conversations/${hydraId.destination}`
232
+ : serviceUrl;
230
233
  } catch (e) {
231
234
  LoggerProxy.logger.error(`Meeting-info:util#generateOptions --> ${e}`);
232
235
  throw e;
@@ -1,9 +1,7 @@
1
1
  import url from 'url';
2
2
 
3
- import {
4
- // @ts-ignore
5
- deconstructHydraId,
6
- } from '@webex/common';
3
+ // @ts-ignore
4
+ import {deconstructHydraId} from '@webex/common';
7
5
 
8
6
  import {
9
7
  _SIP_URI_,
@@ -21,6 +19,8 @@ import {
21
19
  JOIN,
22
20
  MEET,
23
21
  MEET_M,
22
+ MEET_CISCO,
23
+ MEET_CO,
24
24
  HTTPS_PROTOCOL,
25
25
  UUID_REG,
26
26
  VALID_EMAIL_ADDRESS,
@@ -68,6 +68,8 @@ MeetingInfoUtil.isMeetingLink = (value: string) => {
68
68
  parsedUrl.pathname &&
69
69
  (parsedUrl.pathname.includes(`/${MEET}`) ||
70
70
  parsedUrl.pathname.includes(`/${MEET_M}`) ||
71
+ parsedUrl.pathname.includes(`/${MEET_CISCO}`) ||
72
+ parsedUrl.pathname.includes(`/${MEET_CO}`) ||
71
73
  parsedUrl.pathname.includes(`/${JOIN}`));
72
74
 
73
75
  return hostNameBool && pathNameBool;
@@ -162,7 +164,13 @@ MeetingInfoUtil.getDestinationType = async (from) => {
162
164
  };
163
165
  }
164
166
  const options: any = {};
165
- const hydraId = MeetingInfoUtil.getHydraId(destination);
167
+ let hydraId;
168
+
169
+ if (webex && webex.config && webex.config.meetings && webex.config.meetings.disableHydraId) {
170
+ hydraId = null;
171
+ } else {
172
+ hydraId = MeetingInfoUtil.getHydraId(destination);
173
+ }
166
174
 
167
175
  if (MeetingInfoUtil.isMeetingLink(destination)) {
168
176
  LoggerProxy.logger.warn(
@@ -180,19 +188,21 @@ MeetingInfoUtil.getDestinationType = async (from) => {
180
188
  } else if (MeetingInfoUtil.isConversationUrl(destination, webex)) {
181
189
  options.type = _CONVERSATION_URL_;
182
190
  options.destination = destination;
183
- } else if (hydraId.people) {
191
+ } else if (hydraId && hydraId.people) {
184
192
  options.type = _SIP_URI_;
185
193
 
186
- return MeetingInfoUtil.getSipUriFromHydraPersonId(hydraId.destination, webex).then((res) => {
187
- options.destination = res;
194
+ return MeetingInfoUtil.getSipUriFromHydraPersonId(hydraId && hydraId.destination, webex).then(
195
+ (res) => {
196
+ options.destination = res;
188
197
 
189
- // Since hydra person ids require a unique case in which they are
190
- // entirely converted to a SIP URI, we need to set a flag for detecting
191
- // this type of destination.
192
- options.wasHydraPerson = true;
198
+ // Since hydra person ids require a unique case in which they are
199
+ // entirely converted to a SIP URI, we need to set a flag for detecting
200
+ // this type of destination.
201
+ options.wasHydraPerson = true;
193
202
 
194
- return Promise.resolve(options);
195
- });
203
+ return Promise.resolve(options);
204
+ }
205
+ );
196
206
  } else if (hydraId.room) {
197
207
  LoggerProxy.logger.error(
198
208
  `Meeting-info:util#getDestinationType --> Using the space ID as a destination is no longer supported. Please refer to the [migration guide](https://github.com/webex/webex-js-sdk/wiki/Migration-to-Unified-Space-Meetings) to migrate to use the meeting ID or SIP address.`
@@ -282,8 +292,9 @@ MeetingInfoUtil.getRequestBody = (options: {type: string; destination: object} |
282
292
  MeetingInfoUtil.getWebexSite = (uri: string) => {
283
293
  const exceptedDomains = ['meet.webex.com', 'meetup.webex.com', 'ciscospark.com'];
284
294
  const site = uri?.match(/.+@([^.]+\.[^.]+\.[^.]+)$/)?.[1];
295
+ const isExceptedDomain = !!site && exceptedDomains.some((domain) => site.includes(domain));
285
296
 
286
- return exceptedDomains.includes(site) ? null : site;
297
+ return isExceptedDomain ? null : site;
287
298
  };
288
299
 
289
300
  /**
@@ -717,6 +717,24 @@ export default class Meetings extends WebexPlugin {
717
717
  }
718
718
  }
719
719
 
720
+ /**
721
+ * API to toggle TLS reachability, needs to be called before webex.meetings.register()
722
+ * @param {Boolean} newValue
723
+ * @private
724
+ * @memberof Meetings
725
+ * @returns {undefined}
726
+ */
727
+ private _toggleTlsReachability(newValue: boolean) {
728
+ if (typeof newValue !== 'boolean') {
729
+ return;
730
+ }
731
+ // @ts-ignore
732
+ if (this.config.experimental.enableTlsReachability !== newValue) {
733
+ // @ts-ignore
734
+ this.config.experimental.enableTlsReachability = newValue;
735
+ }
736
+ }
737
+
720
738
  /**
721
739
  * Explicitly sets up the meetings plugin by registering
722
740
  * the device, connecting to mercury, and listening for locus events.
@@ -268,7 +268,6 @@ export default class Member {
268
268
  audio: null,
269
269
  video: null,
270
270
  };
271
-
272
271
  // TODO: more participant types
273
272
  // such as native client, web client, is a device, what type of phone, etc
274
273
  this.processParticipant(participant);
@@ -8,10 +8,10 @@ import {
8
8
  H264Codec,
9
9
  getRecommendedMaxBitrateForFrameSize,
10
10
  RecommendedOpusBitrates,
11
+ NamedMediaGroup,
11
12
  } from '@webex/internal-media-core';
12
13
  import {cloneDeepWith, debounce, isEmpty} from 'lodash';
13
14
 
14
- import {NamedMediaGroup} from '@webex/json-multistream';
15
15
  import LoggerProxy from '../common/logs/logger-proxy';
16
16
 
17
17
  import {ReceiveSlot, ReceiveSlotEvents} from './receiveSlot';
@@ -2,7 +2,7 @@
2
2
  /* eslint-disable require-jsdoc */
3
3
  /* eslint-disable import/prefer-default-export */
4
4
  import {forEach} from 'lodash';
5
- import {NamedMediaGroup} from '@webex/json-multistream';
5
+ import {NamedMediaGroup} from '@webex/internal-media-core';
6
6
  import LoggerProxy from '../common/logs/logger-proxy';
7
7
 
8
8
  import {getMaxFs, RemoteMedia, RemoteVideoResolution} from './remoteMedia';
@@ -1,8 +1,7 @@
1
1
  /* eslint-disable valid-jsdoc */
2
2
  import {cloneDeep, forEach, remove} from 'lodash';
3
3
  import {EventMap} from 'typed-emitter';
4
- import {MediaType} from '@webex/internal-media-core';
5
- import {NamedMediaGroup} from '@webex/json-multistream';
4
+ import {MediaType, NamedMediaGroup} from '@webex/internal-media-core';
6
5
 
7
6
  import LoggerProxy from '../common/logs/logger-proxy';
8
7
  import EventsScope from '../common/events/events-scope';
@@ -3,10 +3,9 @@ import {
3
3
  MediaType,
4
4
  LocalStream,
5
5
  MultistreamRoapMediaConnection,
6
+ NamedMediaGroup,
6
7
  } from '@webex/internal-media-core';
7
8
 
8
- import {NamedMediaGroup} from '@webex/json-multistream';
9
-
10
9
  export default class SendSlotManager {
11
10
  private readonly slots: Map<MediaType, SendSlot> = new Map();
12
11
  private readonly LoggerProxy: any;
@@ -2,7 +2,7 @@ import {Defer} from '@webex/common';
2
2
 
3
3
  import LoggerProxy from '../common/logs/logger-proxy';
4
4
  import {ClusterNode} from './request';
5
- import {convertStunUrlToTurn} from './util';
5
+ import {convertStunUrlToTurn, convertStunUrlToTurnTls} from './util';
6
6
 
7
7
  import {ICE_GATHERING_STATE, CONNECTION_STATE} from '../constants';
8
8
 
@@ -29,6 +29,7 @@ export type ClusterReachabilityResult = {
29
29
  export class ClusterReachability {
30
30
  private numUdpUrls: number;
31
31
  private numTcpUrls: number;
32
+ private numXTlsUrls: number;
32
33
  private result: ClusterReachabilityResult;
33
34
  private pc?: RTCPeerConnection;
34
35
  private defer: Defer; // this defer is resolved once reachability checks for this cluster are completed
@@ -46,6 +47,7 @@ export class ClusterReachability {
46
47
  this.isVideoMesh = clusterInfo.isVideoMesh;
47
48
  this.numUdpUrls = clusterInfo.udp.length;
48
49
  this.numTcpUrls = clusterInfo.tcp.length;
50
+ this.numXTlsUrls = clusterInfo.xtls.length;
49
51
 
50
52
  this.pc = this.createPeerConnection(clusterInfo);
51
53
 
@@ -94,8 +96,16 @@ export class ClusterReachability {
94
96
  };
95
97
  });
96
98
 
99
+ const turnTlsIceServers = cluster.xtls.map((urlString: string) => {
100
+ return {
101
+ username: 'webexturnreachuser',
102
+ credential: 'webexturnreachpwd',
103
+ urls: [convertStunUrlToTurnTls(urlString)],
104
+ };
105
+ });
106
+
97
107
  return {
98
- iceServers: [...udpIceServers, ...tcpIceServers],
108
+ iceServers: [...udpIceServers, ...tcpIceServers, ...turnTlsIceServers],
99
109
  iceCandidatePoolSize: 0,
100
110
  iceTransportPolicy: 'all',
101
111
  };
@@ -194,7 +204,7 @@ export class ClusterReachability {
194
204
  * @returns {boolean} true if we have all results, false otherwise
195
205
  */
196
206
  private haveWeGotAllResults(): boolean {
197
- return ['udp', 'tcp'].every(
207
+ return ['udp', 'tcp', 'xtls'].every(
198
208
  (protocol) =>
199
209
  this.result[protocol].result === 'reachable' || this.result[protocol].result === 'untested'
200
210
  );
@@ -207,7 +217,7 @@ export class ClusterReachability {
207
217
  * @param {number} latency
208
218
  * @returns {void}
209
219
  */
210
- private storeLatencyResult(protocol: 'udp' | 'tcp', latency: number) {
220
+ private storeLatencyResult(protocol: 'udp' | 'tcp' | 'xtls', latency: number) {
211
221
  const result = this.result[protocol];
212
222
 
213
223
  if (result.latencyInMilliseconds === undefined) {
@@ -227,6 +237,7 @@ export class ClusterReachability {
227
237
  */
228
238
  private registerIceCandidateListener() {
229
239
  this.pc.onicecandidate = (e) => {
240
+ const TURN_TLS_PORT = 443;
230
241
  const CANDIDATE_TYPES = {
231
242
  SERVER_REFLEXIVE: 'srflx',
232
243
  RELAY: 'relay',
@@ -239,7 +250,8 @@ export class ClusterReachability {
239
250
  }
240
251
 
241
252
  if (e.candidate.type === CANDIDATE_TYPES.RELAY) {
242
- this.storeLatencyResult('tcp', this.getElapsedTime());
253
+ const protocol = e.candidate.port === TURN_TLS_PORT ? 'xtls' : 'tcp';
254
+ this.storeLatencyResult(protocol, this.getElapsedTime());
243
255
  // we don't add public IP for TCP, because in the case of relay candidates
244
256
  // e.candidate.address is the TURN server address, not the client's public IP
245
257
  }
@@ -275,6 +287,9 @@ export class ClusterReachability {
275
287
  this.result.tcp = {
276
288
  result: this.numTcpUrls > 0 ? 'unreachable' : 'untested',
277
289
  };
290
+ this.result.xtls = {
291
+ result: this.numXTlsUrls > 0 ? 'unreachable' : 'untested',
292
+ };
278
293
 
279
294
  try {
280
295
  const offer = await this.pc.createOffer({offerToReceiveAudio: true});
@@ -22,10 +22,14 @@ export type ReachabilityMetrics = {
22
22
  reachability_public_udp_failed: number;
23
23
  reachability_public_tcp_success: number;
24
24
  reachability_public_tcp_failed: number;
25
+ reachability_public_xtls_success: number;
26
+ reachability_public_xtls_failed: number;
25
27
  reachability_vmn_udp_success: number;
26
28
  reachability_vmn_udp_failed: number;
27
29
  reachability_vmn_tcp_success: number;
28
30
  reachability_vmn_tcp_failed: number;
31
+ reachability_vmn_xtls_success: number;
32
+ reachability_vmn_xtls_failed: number;
29
33
  };
30
34
 
31
35
  /**
@@ -141,10 +145,14 @@ export default class Reachability {
141
145
  reachability_public_udp_failed: 0,
142
146
  reachability_public_tcp_success: 0,
143
147
  reachability_public_tcp_failed: 0,
148
+ reachability_public_xtls_success: 0,
149
+ reachability_public_xtls_failed: 0,
144
150
  reachability_vmn_udp_success: 0,
145
151
  reachability_vmn_udp_failed: 0,
146
152
  reachability_vmn_tcp_success: 0,
147
153
  reachability_vmn_tcp_failed: 0,
154
+ reachability_vmn_xtls_success: 0,
155
+ reachability_vmn_xtls_failed: 0,
148
156
  };
149
157
 
150
158
  const updateStats = (clusterType: 'public' | 'vmn', result: ClusterReachabilityResult) => {
@@ -156,6 +164,10 @@ export default class Reachability {
156
164
  const outcome = result.tcp.result === 'reachable' ? 'success' : 'failed';
157
165
  stats[`reachability_${clusterType}_tcp_${outcome}`] += 1;
158
166
  }
167
+ if (result.xtls && result.xtls.result !== 'untested') {
168
+ const outcome = result.xtls.result === 'reachable' ? 'success' : 'failed';
169
+ stats[`reachability_${clusterType}_xtls_${outcome}`] += 1;
170
+ }
159
171
  };
160
172
 
161
173
  try {
@@ -338,7 +350,10 @@ export default class Reachability {
338
350
  LoggerProxy.logger.log(
339
351
  `Reachability:index#performReachabilityChecks --> doing UDP${
340
352
  // @ts-ignore
341
- this.webex.config.meetings.experimental.enableTcpReachability ? ' and TCP' : ''
353
+ this.webex.config.meetings.experimental.enableTcpReachability ? ',TCP' : ''
354
+ }${
355
+ // @ts-ignore
356
+ this.webex.config.meetings.experimental.enableTlsReachability ? ',TLS' : ''
342
357
  } reachability checks`
343
358
  );
344
359
 
@@ -354,6 +369,14 @@ export default class Reachability {
354
369
  cluster.tcp = [];
355
370
  }
356
371
 
372
+ const includeTlsReachability =
373
+ // @ts-ignore
374
+ this.webex.config.meetings.experimental.enableTlsReachability && !cluster.isVideoMesh;
375
+
376
+ if (!includeTlsReachability) {
377
+ cluster.xtls = [];
378
+ }
379
+
357
380
  this.clusterReachability[key] = new ClusterReachability(key, cluster);
358
381
 
359
382
  return this.clusterReachability[key].start().then((result) => {
@@ -34,17 +34,21 @@ class ReachabilityRequest {
34
34
  * @returns {Promise}
35
35
  */
36
36
  getClusters = (ipVersion?: IP_VERSION): Promise<{clusters: ClusterList; joinCookie: any}> =>
37
- this.webex
38
- .request({
39
- method: HTTP_VERBS.GET,
40
- shouldRefreshAccessToken: false,
41
- api: API.CALLIOPEDISCOVERY,
42
- resource: RESOURCE.CLUSTERS,
43
- qs: {
44
- JCSupport: 1,
45
- ipver: ipVersion,
46
- },
47
- })
37
+ this.webex.internal.newMetrics.callDiagnosticLatencies
38
+ .measureLatency(
39
+ () =>
40
+ this.webex.request({
41
+ method: HTTP_VERBS.GET,
42
+ shouldRefreshAccessToken: false,
43
+ api: API.CALLIOPEDISCOVERY,
44
+ resource: RESOURCE.CLUSTERS,
45
+ qs: {
46
+ JCSupport: 1,
47
+ ipver: ipVersion,
48
+ },
49
+ }),
50
+ 'internal.get.cluster.time'
51
+ )
48
52
  .then((res) => {
49
53
  const {clusters, joinCookie} = res.body;
50
54
 
@@ -22,3 +22,24 @@ export function convertStunUrlToTurn(stunUrl: string, protocol: 'udp' | 'tcp') {
22
22
 
23
23
  return url.toString();
24
24
  }
25
+
26
+ /**
27
+ * Converts a stun url to a turns url
28
+ *
29
+ * @param {string} stunUrl url of a stun server
30
+ * @returns {string} url of a turns server
31
+ */
32
+ export function convertStunUrlToTurnTls(stunUrl: string) {
33
+ // stunUrl looks like this: "stun:external-media1.public.wjfkm-a-15.prod.infra.webex.com:443"
34
+ // and we need it to be like this: "turns:external-media1.public.wjfkm-a-15.prod.infra.webex.com:443?transport=tcp"
35
+ const url = new URL(stunUrl);
36
+
37
+ if (url.protocol !== 'stun:') {
38
+ throw new Error(`Not a STUN URL: ${stunUrl}`);
39
+ }
40
+
41
+ url.protocol = 'turns:';
42
+ url.searchParams.append('transport', 'tcp');
43
+
44
+ return url.toString();
45
+ }
@@ -568,7 +568,7 @@ export default class ReconnectionManager {
568
568
 
569
569
  const iceServers = [];
570
570
 
571
- if (turnServerResult.turnServerInfo) {
571
+ if (turnServerResult.turnServerInfo?.url) {
572
572
  iceServers.push({
573
573
  urls: turnServerResult.turnServerInfo.url,
574
574
  username: turnServerResult.turnServerInfo.username || '',