@webex/plugin-meetings 2.60.0-next.4 → 2.60.0-next.6

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 (126) hide show
  1. package/dist/annotation/annotation.types.d.ts +42 -0
  2. package/dist/annotation/constants.d.ts +31 -0
  3. package/dist/annotation/index.d.ts +117 -0
  4. package/dist/breakouts/breakout.d.ts +8 -0
  5. package/dist/breakouts/breakout.js +1 -1
  6. package/dist/breakouts/collection.d.ts +5 -0
  7. package/dist/breakouts/edit-lock-error.d.ts +15 -0
  8. package/dist/breakouts/events.d.ts +8 -0
  9. package/dist/breakouts/index.d.ts +5 -0
  10. package/dist/breakouts/index.js +1 -1
  11. package/dist/breakouts/request.d.ts +22 -0
  12. package/dist/breakouts/utils.d.ts +15 -0
  13. package/dist/common/browser-detection.d.ts +9 -0
  14. package/dist/common/collection.d.ts +48 -0
  15. package/dist/common/config.d.ts +2 -0
  16. package/dist/common/errors/captcha-error.d.ts +15 -0
  17. package/dist/common/errors/intent-to-join.d.ts +16 -0
  18. package/dist/common/errors/join-meeting.d.ts +17 -0
  19. package/dist/common/errors/media.d.ts +15 -0
  20. package/dist/common/errors/no-meeting-info.d.ts +14 -0
  21. package/dist/common/errors/parameter.d.ts +15 -0
  22. package/dist/common/errors/password-error.d.ts +15 -0
  23. package/dist/common/errors/permission.d.ts +14 -0
  24. package/dist/common/errors/reclaim-host-role-errors.d.ts +60 -0
  25. package/dist/common/errors/reconnection-in-progress.d.ts +9 -0
  26. package/dist/common/errors/reconnection.d.ts +15 -0
  27. package/dist/common/errors/stats.d.ts +15 -0
  28. package/dist/common/errors/webex-errors.d.ts +93 -0
  29. package/dist/common/errors/webex-meetings-error.d.ts +20 -0
  30. package/dist/common/events/events-scope.d.ts +17 -0
  31. package/dist/common/events/events.d.ts +12 -0
  32. package/dist/common/events/trigger-proxy.d.ts +2 -0
  33. package/dist/common/events/util.d.ts +2 -0
  34. package/dist/common/logs/logger-config.d.ts +2 -0
  35. package/dist/common/logs/logger-proxy.d.ts +2 -0
  36. package/dist/common/logs/request.d.ts +36 -0
  37. package/dist/common/queue.d.ts +34 -0
  38. package/dist/config.d.ts +71 -0
  39. package/dist/constants.d.ts +1072 -0
  40. package/dist/controls-options-manager/constants.d.ts +4 -0
  41. package/dist/controls-options-manager/enums.d.ts +15 -0
  42. package/dist/controls-options-manager/index.d.ts +136 -0
  43. package/dist/controls-options-manager/types.d.ts +43 -0
  44. package/dist/controls-options-manager/util.d.ts +1 -0
  45. package/dist/index.d.ts +7 -0
  46. package/dist/interpretation/collection.d.ts +5 -0
  47. package/dist/interpretation/index.d.ts +5 -0
  48. package/dist/interpretation/index.js +1 -1
  49. package/dist/interpretation/siLanguage.d.ts +5 -0
  50. package/dist/interpretation/siLanguage.js +1 -1
  51. package/dist/locus-info/controlsUtils.d.ts +2 -0
  52. package/dist/locus-info/embeddedAppsUtils.d.ts +2 -0
  53. package/dist/locus-info/fullState.d.ts +2 -0
  54. package/dist/locus-info/hostUtils.d.ts +2 -0
  55. package/dist/locus-info/index.d.ts +322 -0
  56. package/dist/locus-info/infoUtils.d.ts +2 -0
  57. package/dist/locus-info/mediaSharesUtils.d.ts +2 -0
  58. package/dist/locus-info/parser.d.ts +272 -0
  59. package/dist/locus-info/selfUtils.d.ts +2 -0
  60. package/dist/media/index.d.ts +34 -0
  61. package/dist/media/properties.d.ts +93 -0
  62. package/dist/media/util.d.ts +2 -0
  63. package/dist/mediaQualityMetrics/config.d.ts +365 -0
  64. package/dist/meeting/in-meeting-actions.d.ts +167 -0
  65. package/dist/meeting/index.d.ts +1715 -0
  66. package/dist/meeting/locusMediaRequest.d.ts +74 -0
  67. package/dist/meeting/muteState.d.ts +184 -0
  68. package/dist/meeting/request.d.ts +290 -0
  69. package/dist/meeting/request.type.d.ts +11 -0
  70. package/dist/meeting/state.d.ts +9 -0
  71. package/dist/meeting/util.d.ts +103 -0
  72. package/dist/meeting-info/collection.d.ts +20 -0
  73. package/dist/meeting-info/index.d.ts +69 -0
  74. package/dist/meeting-info/meeting-info-v2.d.ts +123 -0
  75. package/dist/meeting-info/request.d.ts +22 -0
  76. package/dist/meeting-info/util.d.ts +2 -0
  77. package/dist/meeting-info/utilv2.d.ts +2 -0
  78. package/dist/meetings/collection.d.ts +40 -0
  79. package/dist/meetings/index.d.ts +378 -0
  80. package/dist/meetings/meetings.types.d.ts +4 -0
  81. package/dist/meetings/request.d.ts +27 -0
  82. package/dist/meetings/util.d.ts +18 -0
  83. package/dist/member/index.d.ts +160 -0
  84. package/dist/member/member.types.d.ts +11 -0
  85. package/dist/member/types.d.ts +32 -0
  86. package/dist/member/util.d.ts +2 -0
  87. package/dist/members/collection.d.ts +29 -0
  88. package/dist/members/index.d.ts +353 -0
  89. package/dist/members/request.d.ts +114 -0
  90. package/dist/members/types.d.ts +25 -0
  91. package/dist/members/util.d.ts +215 -0
  92. package/dist/metrics/constants.d.ts +68 -0
  93. package/dist/metrics/index.d.ts +45 -0
  94. package/dist/multistream/mediaRequestManager.d.ts +118 -0
  95. package/dist/multistream/receiveSlot.d.ts +68 -0
  96. package/dist/multistream/receiveSlotManager.d.ts +56 -0
  97. package/dist/multistream/remoteMedia.d.ts +72 -0
  98. package/dist/multistream/remoteMediaGroup.d.ts +47 -0
  99. package/dist/multistream/remoteMediaManager.d.ts +285 -0
  100. package/dist/multistream/sendSlotManager.d.ts +61 -0
  101. package/dist/networkQualityMonitor/index.d.ts +70 -0
  102. package/dist/personal-meeting-room/index.d.ts +47 -0
  103. package/dist/personal-meeting-room/request.d.ts +14 -0
  104. package/dist/personal-meeting-room/util.d.ts +2 -0
  105. package/dist/reachability/index.d.ts +194 -0
  106. package/dist/reachability/request.d.ts +39 -0
  107. package/dist/reactions/constants.d.ts +3 -0
  108. package/dist/reactions/reactions.d.ts +4 -0
  109. package/dist/reactions/reactions.type.d.ts +52 -0
  110. package/dist/reconnection-manager/index.d.ts +136 -0
  111. package/dist/recording-controller/enums.d.ts +7 -0
  112. package/dist/recording-controller/index.d.ts +207 -0
  113. package/dist/recording-controller/util.d.ts +14 -0
  114. package/dist/roap/index.d.ts +78 -0
  115. package/dist/roap/request.d.ts +41 -0
  116. package/dist/roap/turnDiscovery.d.ts +92 -0
  117. package/dist/rtcMetrics/constants.d.ts +4 -0
  118. package/dist/rtcMetrics/index.d.ts +54 -0
  119. package/dist/statsAnalyzer/global.d.ts +36 -0
  120. package/dist/statsAnalyzer/index.d.ts +201 -0
  121. package/dist/statsAnalyzer/mqaUtil.d.ts +24 -0
  122. package/dist/transcription/index.d.ts +64 -0
  123. package/dist/webinar/collection.d.ts +16 -0
  124. package/dist/webinar/index.d.ts +5 -0
  125. package/dist/webinar/index.js +1 -1
  126. package/package.json +21 -21
@@ -0,0 +1,1715 @@
1
+ /// <reference types="node" />
2
+ import { StatelessWebexPlugin } from '@webex/webex-core';
3
+ import { ClientEvent, ClientEventLeaveReason } from '@webex/internal-plugin-metrics';
4
+ import { LocalStream, LocalCameraStream, LocalDisplayStream, LocalSystemAudioStream, LocalMicrophoneStream } from '@webex/media-helpers';
5
+ import { StatsAnalyzer } from '../statsAnalyzer';
6
+ import NetworkQualityMonitor from '../networkQualityMonitor';
7
+ import Roap from '../roap/index';
8
+ import { type BundlePolicy } from '../media';
9
+ import MediaProperties from '../media/properties';
10
+ import ReconnectionManager from '../reconnection-manager';
11
+ import MeetingRequest from './request';
12
+ import Members from '../members/index';
13
+ import Transcription from '../transcription';
14
+ import { NETWORK_STATUS } from '../constants';
15
+ import { ReceiveSlotManager } from '../multistream/receiveSlotManager';
16
+ import { MediaRequestManager } from '../multistream/mediaRequestManager';
17
+ import { Configuration as RemoteMediaManagerConfiguration, RemoteMediaManager } from '../multistream/remoteMediaManager';
18
+ import { ReactionServerType, SkinToneType } from '../reactions/reactions.type';
19
+ import InMeetingActions from './in-meeting-actions';
20
+ import RecordingController from '../recording-controller';
21
+ import ControlsOptionsManager from '../controls-options-manager';
22
+ import { LocusMediaRequest } from './locusMediaRequest';
23
+ export type LocalStreams = {
24
+ microphone?: LocalMicrophoneStream;
25
+ camera?: LocalCameraStream;
26
+ screenShare?: {
27
+ audio?: LocalSystemAudioStream;
28
+ video?: LocalDisplayStream;
29
+ };
30
+ };
31
+ export type AddMediaOptions = {
32
+ localStreams?: LocalStreams;
33
+ audioEnabled?: boolean;
34
+ videoEnabled?: boolean;
35
+ shareAudioEnabled?: boolean;
36
+ shareVideoEnabled?: boolean;
37
+ remoteMediaManagerConfig?: RemoteMediaManagerConfiguration;
38
+ bundlePolicy?: BundlePolicy;
39
+ allowMediaInLobby?: boolean;
40
+ };
41
+ export type CallStateForMetrics = {
42
+ correlationId?: string;
43
+ joinTrigger?: string;
44
+ loginType?: string;
45
+ };
46
+ export declare const MEDIA_UPDATE_TYPE: {
47
+ TRANSCODED_MEDIA_CONNECTION: string;
48
+ SHARE_FLOOR_REQUEST: string;
49
+ UPDATE_MEDIA: string;
50
+ };
51
+ export declare enum ScreenShareFloorStatus {
52
+ PENDING = "floor_request_pending",
53
+ GRANTED = "floor_request_granted",
54
+ RELEASED = "floor_released"
55
+ }
56
+ /**
57
+ * MediaDirection
58
+ * @typedef {Object} MediaDirection
59
+ * @property {boolean} sendAudio
60
+ * @property {boolean} receiveAudio
61
+ * @property {boolean} sendVideo
62
+ * @property {boolean} receiveVideo
63
+ * @property {boolean} sendShare
64
+ * @property {boolean} receiveShare
65
+ * @property {boolean} isSharing
66
+ */
67
+ /**
68
+ * SharePreferences
69
+ * @typedef {Object} SharePreferences
70
+ * @property {Object} [shareConstraints]
71
+ * @property {Boolean} [highFrameRate]
72
+ */
73
+ /**
74
+ * JoinOptions
75
+ * @typedef {Object} JoinOptions
76
+ * @property {String} [resourceId]
77
+ * @property {String} [pin]
78
+ * @property {Boolean} [moderator]
79
+ * @property {String|Object} [meetingQuality]
80
+ * @property {String} [meetingQuality.remote]
81
+ * @property {Boolean} [rejoin]
82
+ * @property {Boolean} [enableMultistream]
83
+ */
84
+ /**
85
+ * Recording
86
+ * @typedef {Object} Recording
87
+ * @property {Object} state
88
+ * @property {String} modifiedBy
89
+ */
90
+ /**
91
+ * Meeting State Change Event
92
+ * Emitted when ever there is a meeting state change
93
+ * @event meeting:stateChange
94
+ * @instance
95
+ * @type {Object}
96
+ * @property {String} currentState current state of the meeting
97
+ * @property {String} previousState previous state of the meeting
98
+ * @memberof Meeting
99
+ */
100
+ /**
101
+ * Media Ready Event
102
+ * Emitted when a stream is ready to be rendered
103
+ * @event media:ready
104
+ * @instance
105
+ * @type {Object}
106
+ * @property {MediaStream} stream the media stream
107
+ * @property {String} type what type of stream, remote, local
108
+ * @memberof Meeting
109
+ */
110
+ /**
111
+ * Media Stopped Event
112
+ * Emitted when a stream has stopped sending
113
+ * @event media:stopped
114
+ * @instance
115
+ * @type {Object}
116
+ * @property {String} type what type of stream, remote, local
117
+ * @memberof Meeting
118
+ */
119
+ /**
120
+ * Meeting Ringing Event
121
+ * Emitted when this client should play a ringing sound, because this member is getting an incoming meeting
122
+ * or sending out an incoming meeting
123
+ * @event meeting:ringing
124
+ * @instance
125
+ * @type {Object}
126
+ * @property {String} type // INCOMING or JOIN
127
+ * @property {String} id
128
+ * @memberof Meeting
129
+ */
130
+ /**
131
+ * Meeting Ringing Stop Event
132
+ * Emitted when this client should stop playing a ringing sound
133
+ * @event meeting:ringingStop
134
+ * @instance
135
+ * @type {Object}
136
+ * @property {Object} type
137
+ * @property {Boolean} type.remoteAnswered
138
+ * @property {Boolean} type.remoteDeclined
139
+ * @property {String} id
140
+ * @memberof Meeting
141
+ */
142
+ /**
143
+ * Meeting Started Sharing Local Event
144
+ * Emitted when this member starts sharing
145
+ * @event meeting:startedSharingLocal
146
+ * @instance
147
+ * @type {Object}
148
+ * @memberof Meeting
149
+ */
150
+ /**
151
+ * Meeting Stopped Sharing Local Event
152
+ * Emitted when this member stops sharing
153
+ * @event meeting:stoppedSharingLocal
154
+ * @instance
155
+ * @type {Object}
156
+ * @memberof Meeting
157
+ */
158
+ /**
159
+ * Meeting Started Sharing Remote Event
160
+ * Emitted when remote sharing starts
161
+ * @event meeting:startedSharingRemote
162
+ * @instance
163
+ * @type {Object}
164
+ * @property {Boolean} memberId id of the meeting member that started screen share
165
+ * @property {String} url of this content share
166
+ * @property {String} shareInstanceId of this content share
167
+ * @property {Object} annotation Info of this content share
168
+ * @memberof Meeting
169
+ *
170
+ */
171
+ /**
172
+ * Meeting Stopped Sharing Remote Event
173
+ * Emitted when remote screen sharing ends
174
+ * @event meeting:stoppedSharingRemote
175
+ * @instance
176
+ * @type {Object}
177
+ * @memberof Meeting
178
+ */
179
+ /**
180
+ * Meeting Locked Event
181
+ * Emitted when a meeting is locked
182
+ * @event meeting:locked
183
+ * @instance
184
+ * @type {Object}
185
+ * @property {Object} info
186
+ * @memberof Meeting
187
+ */
188
+ /**
189
+ * Meeting Unlocked Event
190
+ * Emitted when a meeting is unlocked
191
+ * @event meeting:unlocked
192
+ * @instance
193
+ * @type {Object}
194
+ * @property {Object} info
195
+ * @memberof Meeting
196
+ */
197
+ /**
198
+ * Meeting Actions Update Event
199
+ * Emitted when a user can take actions on a meeting such as lock, unlock, assign host
200
+ * @event meeting:actionsUpdate
201
+ * @instance
202
+ * @type {Object}
203
+ * @property {Boolean} canLock
204
+ * @property {Boolean} canUnlock
205
+ * @property {Boolean} canAssignHost
206
+ * @memberof Meeting
207
+ */
208
+ /**
209
+ * Meeting Unmuted By Others Event
210
+ * Emitted when a member is unmuted by another member
211
+ * @event meeting:self:unmutedByOthers
212
+ * @instance
213
+ * @type {Object}
214
+ * @property {Object} payload
215
+ * @memberof Meeting
216
+ */
217
+ /**
218
+ * Meeting Muted By Others Event
219
+ * Emitted when a member is muted by another member
220
+ * @event meeting:self:mutedByOthers
221
+ * @instance
222
+ * @type {Object}
223
+ * @property {Object} payload
224
+ * @property {Boolean} payload.unmuteAllowed - whether the user is allowed to unmute self
225
+ * @memberof Meeting
226
+ */
227
+ /**
228
+ * Meeting Muted By Others Event
229
+ * Emitted when the host(moderator)/co-host requests a user to unmute
230
+ * @event meeting:self:requestedToUnmute
231
+ * @instance
232
+ * @type {Object}
233
+ * @property {Object} payload
234
+ * @memberof Meeting
235
+ */
236
+ /**
237
+ * Meeting Self Guest Admitted Event
238
+ * Emitted when a joined user get admitted to the meeting by another member or host
239
+ * @event meeting:self:guestAdmitted
240
+ * @instance
241
+ * @type {Object}
242
+ * @property {Object} payload
243
+ * @memberof Meeting
244
+ */
245
+ /**
246
+ * Meeting Self Lobby Waiting Event
247
+ * Emitted when joined user enters the lobby and is waiting for the webex meeting to begin
248
+ * @event meeting:self:lobbyWaiting
249
+ * @instance
250
+ * @type {Object}
251
+ * @property {Object} reason Reason why user left the meeting
252
+ * @memberof Meeting
253
+ */
254
+ /**
255
+ * Meeting Self Left State
256
+ * Emitted when user is inactive for more then 40 seconds, User can rejoin the meeting again
257
+ * @event meeting:self:left
258
+ * @instance
259
+ * @type {Object}
260
+ * @property {Object} payload
261
+ * @memberof Meeting
262
+ */
263
+ /**
264
+ * Reconnection Starting Event
265
+ * Emitted when reconnection of media to the active meeting was successful
266
+ * @event meeting:reconnectionStarting
267
+ * @instance
268
+ * @memberof Meeting
269
+ */
270
+ /**
271
+ * Reconnection Success Event
272
+ * Emitted when reconnection of media to the active meeting was successful
273
+ * @event meeting:reconnectionSuccess
274
+ * @instance
275
+ * @type {Object}
276
+ * @property {Object} reconnect
277
+ * @memberof Meeting
278
+ */
279
+ /**
280
+ * Reconnection Failure Event
281
+ * Emitted when reconnection of media to the active meeting was successful
282
+ * @event meeting:reconnectionFailure
283
+ * @instance
284
+ * @type {Object}
285
+ * @property {Error} error
286
+ * @memberof Meeting
287
+ */
288
+ /**
289
+ * Meeting network quality event
290
+ * Emitted on each interval of retrieving stats Analyzer data
291
+ * @event network:quality
292
+ * @type {Object}
293
+ * @property {string} mediaType {video|audio}
294
+ * @property {number} networkQualityScore - {1|0} 1 indicates acceptable uplink 0 indicates unacceptable uplink based on threshold
295
+ * @memberof Meeting
296
+ */
297
+ /**
298
+ * @description Meeting is the crux of the plugin
299
+ * @export
300
+ * @class Meeting
301
+ */
302
+ export default class Meeting extends StatelessWebexPlugin {
303
+ attrs: any;
304
+ audio: any;
305
+ breakouts: any;
306
+ simultaneousInterpretation: any;
307
+ annotation: any;
308
+ webinar: any;
309
+ conversationUrl: string;
310
+ callStateForMetrics: CallStateForMetrics;
311
+ destination: string;
312
+ destinationType: string;
313
+ deviceUrl: string;
314
+ hostId: string;
315
+ id: string;
316
+ isMultistream: boolean;
317
+ locusUrl: string;
318
+ mediaConnections: any[];
319
+ mediaId?: string;
320
+ meetingFiniteStateMachine: any;
321
+ meetingInfo: any;
322
+ meetingRequest: MeetingRequest;
323
+ members: Members;
324
+ options: object;
325
+ orgId: string;
326
+ owner: string;
327
+ partner: any;
328
+ policy: string;
329
+ reconnectionManager: ReconnectionManager;
330
+ resource: string;
331
+ roap: Roap;
332
+ roapSeq: number;
333
+ selfUrl?: string;
334
+ sipUri: string;
335
+ type: string;
336
+ userId: string;
337
+ video: any;
338
+ callEvents: any[];
339
+ datachannelUrl: string;
340
+ deferJoin: Promise<any>;
341
+ dialInDeviceStatus: string;
342
+ dialInUrl: string;
343
+ dialOutDeviceStatus: string;
344
+ dialOutUrl: string;
345
+ fetchMeetingInfoTimeoutId: NodeJS.Timeout;
346
+ floorGrantPending: boolean;
347
+ hasJoinedOnce: boolean;
348
+ hasWebsocketConnected: boolean;
349
+ inMeetingActions: InMeetingActions;
350
+ isLocalShareLive: boolean;
351
+ isRoapInProgress: boolean;
352
+ keepAliveTimerId: NodeJS.Timeout;
353
+ lastVideoLayoutInfo: any;
354
+ locusInfo: any;
355
+ locusMediaRequest?: LocusMediaRequest;
356
+ mediaProperties: MediaProperties;
357
+ mediaRequestManagers: {
358
+ audio: MediaRequestManager;
359
+ video: MediaRequestManager;
360
+ screenShareAudio: MediaRequestManager;
361
+ screenShareVideo: MediaRequestManager;
362
+ };
363
+ meetingInfoFailureReason: string;
364
+ meetingInfoFailureCode?: number;
365
+ meetingInfoExtraParams?: Record<string, any>;
366
+ networkQualityMonitor: NetworkQualityMonitor;
367
+ networkStatus?: NETWORK_STATUS;
368
+ passwordStatus: string;
369
+ queuedMediaUpdates: any[];
370
+ recording: any;
371
+ remoteMediaManager: RemoteMediaManager | null;
372
+ recordingController: RecordingController;
373
+ controlsOptionsManager: ControlsOptionsManager;
374
+ requiredCaptcha: any;
375
+ receiveSlotManager: ReceiveSlotManager;
376
+ selfUserPolicies: any;
377
+ enforceVBGImagesURL: string;
378
+ shareStatus: string;
379
+ screenShareFloorState: ScreenShareFloorStatus;
380
+ statsAnalyzer: StatsAnalyzer;
381
+ transcription: Transcription;
382
+ receiveTranscription: boolean;
383
+ updateMediaConnections: (mediaConnections: any[]) => void;
384
+ userDisplayHints: any;
385
+ endCallInitJoinReq: any;
386
+ endJoinReqResp: any;
387
+ endLocalSDPGenRemoteSDPRecvDelay: any;
388
+ joinedWith: any;
389
+ locusId: any;
390
+ startCallInitJoinReq: any;
391
+ startJoinReqResp: any;
392
+ startLocalSDPGenRemoteSDPRecvDelay: any;
393
+ wirelessShare: any;
394
+ guest: any;
395
+ meetingJoinUrl: any;
396
+ meetingNumber: any;
397
+ meetingState: any;
398
+ permissionToken: string;
399
+ permissionTokenPayload: any;
400
+ resourceId: any;
401
+ resourceUrl: string;
402
+ selfId: string;
403
+ state: any;
404
+ localAudioStreamMuteStateHandler: (muted: boolean) => void;
405
+ localVideoStreamMuteStateHandler: (muted: boolean) => void;
406
+ localOutputTrackChangeHandler: () => void;
407
+ roles: any[];
408
+ environment: string;
409
+ namespace: string;
410
+ allowMediaInLobby: boolean;
411
+ turnDiscoverySkippedReason: string;
412
+ turnServerUsed: boolean;
413
+ private retriedWithTurnServer;
414
+ private sendSlotManager;
415
+ private deferSDPAnswer?;
416
+ private sdpResponseTimer?;
417
+ private hasMediaConnectionConnectedAtLeastOnce;
418
+ /**
419
+ * @param {Object} attrs
420
+ * @param {Object} options
421
+ * @constructor
422
+ * @memberof Meeting
423
+ */
424
+ constructor(attrs: any, options: object);
425
+ /**
426
+ * returns meeting is joined
427
+ * @private
428
+ * @memberof Meeting
429
+ * @returns {Boolean}
430
+ */
431
+ private isJoined;
432
+ /**
433
+ * Returns whether this meeting is a Locus CALL
434
+ * @returns {Boolean}
435
+ */
436
+ isLocusCall(): boolean;
437
+ /**
438
+ * Getter - Returns callStateForMetrics.correlationId
439
+ * @returns {string}
440
+ */
441
+ get correlationId(): string;
442
+ /**
443
+ * Setter - sets callStateForMetrics.correlationId
444
+ * @param {string} correlationId
445
+ */
446
+ set correlationId(correlationId: string);
447
+ /**
448
+ * Internal method for fetching meeting info
449
+ *
450
+ * @returns {Promise}
451
+ */
452
+ private fetchMeetingInfoInternal;
453
+ /**
454
+ * Refreshes the meeting info permission token (it's required for joining meetings)
455
+ *
456
+ * @param {string} [reason] used for metrics and logging purposes (optional)
457
+ * @returns {Promise}
458
+ */
459
+ refreshPermissionToken(reason?: string): Promise<void>;
460
+ /**
461
+ * Fetches meeting information.
462
+ * @param {Object} options
463
+ * @param {String} [options.password] optional
464
+ * @param {String} [options.captchaCode] optional
465
+ * @param {Boolean} [options.sendCAevents] optional - Whether to submit Call Analyzer events or not. Default: false.
466
+ * @public
467
+ * @memberof Meeting
468
+ * @returns {Promise}
469
+ */
470
+ fetchMeetingInfo({ password, captchaCode, extraParams, sendCAevents, }: {
471
+ password?: string;
472
+ captchaCode?: string;
473
+ extraParams?: Record<string, any>;
474
+ sendCAevents?: boolean;
475
+ }): Promise<void>;
476
+ /**
477
+ * Checks if the supplied password/host key is correct. It returns a promise with information whether the
478
+ * password and captcha code were correct or not.
479
+ * @param {String} password - this can be either a password or a host key, can be undefined if only captcha was required
480
+ * @param {String} captchaCode - can be undefined if captcha was not required by the server
481
+ * @param {Boolean} sendCAevents - whether Call Analyzer events should be sent when fetching meeting information
482
+ * @public
483
+ * @memberof Meeting
484
+ * @returns {Promise<{isPasswordValid: boolean, requiredCaptcha: boolean, failureReason: MEETING_INFO_FAILURE_REASON}>}
485
+ */
486
+ verifyPassword(password: string, captchaCode: string, sendCAevents?: boolean): Promise<{
487
+ isPasswordValid: boolean;
488
+ requiredCaptcha: any;
489
+ failureReason: string;
490
+ } | {
491
+ isPasswordValid: boolean;
492
+ requiredCaptcha: any;
493
+ failureReason: string;
494
+ }>;
495
+ /**
496
+ * Refreshes the captcha. As a result the meeting will have new captcha id, image and audio.
497
+ * If the refresh operation fails, meeting remains with the old captcha properties.
498
+ * @public
499
+ * @memberof Meeting
500
+ * @returns {Promise}
501
+ */
502
+ refreshCaptcha(): any;
503
+ /**
504
+ * Posts metrics event for this meeting. Allows the app to send Call Analyzer events.
505
+ * @param {String} eventName - Call Analyzer event
506
+ * @public
507
+ * @memberof Meeting
508
+ * @returns {Promise}
509
+ */
510
+ postMetrics(eventName: ClientEvent['name']): void;
511
+ /**
512
+ * Proxy function for all the listener set ups
513
+ * @returns {undefined}
514
+ * @private
515
+ * @memberof Meeting
516
+ */
517
+ private setUpLocusInfoListeners;
518
+ /**
519
+ * Set up the listeners for breakouts
520
+ * @returns {undefined}
521
+ * @private
522
+ * @memberof Meeting
523
+ */
524
+ setUpBreakoutsListener(): void;
525
+ /**
526
+ * Set up the listeners for interpretation
527
+ * @returns {undefined}
528
+ * @private
529
+ * @memberof Meeting
530
+ */
531
+ private setUpInterpretationListener;
532
+ /**
533
+ * Set up the locus info listener for meetings disconnected due to inactivity
534
+ * @returns {undefined}
535
+ * @private
536
+ * @memberof Meeting
537
+ */
538
+ private setUpLocusInfoMediaInactiveListener;
539
+ /**
540
+ * Set up the locus info listener for assign host permissions on a meeting
541
+ * @returns {undefined}
542
+ * @private
543
+ * @memberof Meeting
544
+ */
545
+ private setUpLocusInfoAssignHostListener;
546
+ /**
547
+ * Set up the internal locus info full state object listener
548
+ * @returns {undefined}
549
+ * @private
550
+ * @memberof Meeting
551
+ */
552
+ private setUpLocusFullStateListener;
553
+ /**
554
+ * sets the network status on meeting object
555
+ * @param {NETWORK_STATUS} networkStatus
556
+ * @private
557
+ * @returns {undefined}
558
+ * @memberof Meeting
559
+ */
560
+ private setNetworkStatus;
561
+ /**
562
+ * Set up the locus info self listener
563
+ * update self value for members and updates the member
564
+ * notifies consumer with members:self:update {activeSelfId endedSelfId}
565
+ * @returns {undefined}
566
+ * @private
567
+ * @memberof Meeting
568
+ */
569
+ private setUpLocusSelfListener;
570
+ /**
571
+ * Notify any changes on the pstn devices
572
+ * @param {Object} payload
573
+ * @returns {undefined}
574
+ * @private
575
+ * @memberof Meeting
576
+ */
577
+ private pstnUpdate;
578
+ /**
579
+ * Set up the locus info host listener
580
+ * update host value for members and updates the member
581
+ * notifies consumer with members:host:update: {activeHostId, endedHostId}
582
+ * @returns {undefined}
583
+ * @private
584
+ * @memberof Meeting
585
+ */
586
+ private setUpLocusHostListener;
587
+ /**
588
+ * Set up the locus info participants update listener
589
+ * update members collection value for members
590
+ * notifies consumer with members:update
591
+ * @returns {undefined}
592
+ * @private
593
+ * @memberof Meeting
594
+ */
595
+ private setUpLocusParticipantsListener;
596
+ /**
597
+ * Set up the locus info recording update listener
598
+ * update recording value for the meeting
599
+ * notifies consumer with:
600
+ * meeting:recording:started
601
+ * meeting:recording:stopped
602
+ * meeting:recording:paused
603
+ * meeting:recording:resumed
604
+ *
605
+ * Set up the locus info meeeting container listener
606
+ * update meetingContainerUrl value for the meeting
607
+ * notifies consumer with:
608
+ * meeting:meetingContainer:update
609
+ *
610
+ * @returns {undefined}
611
+ * @private
612
+ * @memberof Meeting
613
+ */
614
+ private setupLocusControlsListener;
615
+ /**
616
+ * Trigger annotation info update event
617
+ @returns {undefined}
618
+ @param {object} contentShare
619
+ @param {object} previousContentShare
620
+ */
621
+ private triggerAnnotationInfoEvent;
622
+ /**
623
+ * Set up the locus info media shares listener
624
+ * update content and whiteboard sharing id value for members, and updates the member
625
+ * notifies consumer with members:content:update {activeContentSharingId, endedContentSharingId}
626
+ * @returns {undefined}
627
+ * @private
628
+ * @memberof Meeting
629
+ */
630
+ private setUpLocusMediaSharesListener;
631
+ /**
632
+ * Set up the locus info url listener
633
+ * update locus_url value for members
634
+ * @returns {undefined}
635
+ * @private
636
+ * @memberof Meeting
637
+ */
638
+ private setUpLocusUrlListener;
639
+ /**
640
+ * Set up the locus info service link listener
641
+ * update the locusInfo for recording controller
642
+ * does not currently re-emit the event as it's internal only
643
+ * payload is unused
644
+ * @returns {undefined}
645
+ * @private
646
+ * @memberof Meeting
647
+ */
648
+ private setUpLocusServicesListener;
649
+ /**
650
+ * Set up the locus info meeting info listener
651
+ * @returns {undefined}
652
+ * @private
653
+ * @memberof meeting
654
+ */
655
+ private setUpLocusInfoMeetingInfoListener;
656
+ /**
657
+ * Handles a data channel URL change
658
+ * @param {String} datachannelUrl
659
+ * @returns {void}
660
+ */
661
+ handleDataChannelUrlChange(datachannelUrl: any): void;
662
+ /**
663
+ * Set up the locus info embedded apps listener
664
+ * @returns {undefined}
665
+ * @private
666
+ * @memberof meeting
667
+ */
668
+ private setUpLocusEmbeddedAppsListener;
669
+ /**
670
+ * Internal function to listen to the self object changes
671
+ * @returns {undefined}
672
+ * @private
673
+ * @memberof Meeting
674
+ */
675
+ private setUpLocusInfoSelfListener;
676
+ /**
677
+ * Add LocusInfo nested object listeners (from child to parent)
678
+ * @returns {undefined}
679
+ * @private
680
+ * @memberof Meeting
681
+ */
682
+ private setUpLocusInfoMeetingListener;
683
+ /**
684
+ * Set meeting values rather than events
685
+ * @param {Object} object
686
+ * @returns {undefined}
687
+ * @private
688
+ * @memberof Meeting
689
+ * // TODO: is this function necessary?
690
+ */
691
+ private updateMeetingObject;
692
+ /**
693
+ * Invite a guest to the call that isn't normally part of this call
694
+ * @param {Object} invitee
695
+ * @param {String} invitee.emailAddress
696
+ * @param {String} invitee.email
697
+ * @param {String} invitee.phoneNumber
698
+ * @param {Boolean} [alertIfActive]
699
+ * @returns {Promise} see #members.addMember
700
+ * @public
701
+ * @memberof Meeting
702
+ */
703
+ invite(invitee: {
704
+ emailAddress: string;
705
+ email: string;
706
+ phoneNumber: string;
707
+ }, alertIfActive?: boolean): any;
708
+ /**
709
+ * Cancel an outgoing phone call invitation made during a meeting
710
+ * @param {Object} invitee
711
+ * @param {String} invitee.phoneNumber
712
+ * @returns {Promise} see #members.cancelPhoneInvite
713
+ * @public
714
+ * @memberof Meeting
715
+ */
716
+ cancelPhoneInvite(invitee: {
717
+ phoneNumber: string;
718
+ }): any;
719
+ /**
720
+ * Admit the guest(s) to the call once they are waiting.
721
+ * If the host/cohost is in a breakout session, the locus url
722
+ * of the session must be provided as the authorizingLocusUrl.
723
+ * Regardless of host/cohost location, the locus Id (lid) in
724
+ * the path should be the locus Id of the main, which means the
725
+ * locus url of the api call must be from the main session.
726
+ * If these loucs urls are not provided, the function will do the check.
727
+ * @param {Array} memberIds
728
+ * @param {Object} sessionLocusUrls: {authorizingLocusUrl, mainLocusUrl}
729
+ * @returns {Promise} see #members.admitMembers
730
+ * @public
731
+ * @memberof Meeting
732
+ */
733
+ admit(memberIds: Array<any>, sessionLocusUrls?: {
734
+ authorizingLocusUrl: string;
735
+ mainLocusUrl: string;
736
+ }): any;
737
+ /**
738
+ * Remove the member from the meeting, boot them
739
+ * @param {String} memberId
740
+ * @returns {Promise} see #members.removeMember
741
+ * @public
742
+ * @memberof Meeting
743
+ */
744
+ remove(memberId: string): any;
745
+ /**
746
+ * Mute another member from the meeting
747
+ * @param {String} memberId
748
+ * @param {Boolean} mute
749
+ * @returns {Promise} see #members.muteMember
750
+ * @public
751
+ * @memberof Meeting
752
+ */
753
+ mute(memberId: string, mute?: boolean): any;
754
+ /**
755
+ * Transfer the moderator role to another eligible member
756
+ * @param {String} memberId
757
+ * @param {Boolean} moderator
758
+ * @returns {Promise} see #members.transferHostToMember
759
+ * @public
760
+ * @memberof Meeting
761
+ */
762
+ transfer(memberId: string, moderator?: boolean): any;
763
+ /**
764
+ * Reference to the Members object
765
+ * @returns {Members}
766
+ * @public
767
+ * @memberof Meeting
768
+ */
769
+ getMembers(): Members;
770
+ /**
771
+ * Sets the meeting info on the class instance
772
+ * @param {Object} meetingInfo
773
+ * @param {Object} meetingInfo.body
774
+ * @param {String} meetingInfo.body.conversationUrl
775
+ * @param {String} meetingInfo.body.locusUrl
776
+ * @param {String} meetingInfo.body.sipUri
777
+ * @param {Object} meetingInfo.body.owner
778
+ * @param {Object | String} destination locus object with meeting data or destination string (sip url, meeting link, etc)
779
+ * @returns {undefined}
780
+ * @private
781
+ * @memberof Meeting
782
+ */
783
+ parseMeetingInfo(meetingInfo: {
784
+ body: {
785
+ conversationUrl: string;
786
+ locusUrl: string;
787
+ sipUri: string;
788
+ owner: object;
789
+ };
790
+ } | any, destination?: object | string | null): void;
791
+ /**
792
+ * Indicates whether policy can be applied
793
+ * @returns {boolean}
794
+ */
795
+ private arePolicyRestrictionsSupported;
796
+ /**
797
+ * Updates the meeting actions (display hints), depends on locus display hints, user policy and app api info
798
+ * @returns {undefined}
799
+ * @private
800
+ * @memberof Meeting
801
+ */
802
+ private updateMeetingActions;
803
+ /**
804
+ * Sets the self user policies based on the contents of the permission token
805
+ * @returns {void}
806
+ */
807
+ setSelfUserPolicies(): void;
808
+ /**
809
+ * Sets the permission token payload on the class instance
810
+ *
811
+ * @param {String} permissionToken
812
+ * @returns {void}
813
+ */
814
+ setPermissionTokenPayload(permissionToken: string): void;
815
+ /**
816
+ * Sets the sip uri on the class instance
817
+ * uses meeting info as precedence
818
+ * @param {String} sipUri
819
+ * @returns {undefined}
820
+ * @private
821
+ * @memberof Meeting
822
+ */
823
+ setSipUri(sipUri: string): void;
824
+ /**
825
+ * Set the locus info the class instance
826
+ * @param {Object} locus
827
+ * @param {Array} locus.mediaConnections
828
+ * @param {String} locus.locusUrl
829
+ * @param {String} locus.locusId
830
+ * @param {String} locus.mediaId
831
+ * @param {Object} locus.host
832
+ * @todo change name to genertic parser
833
+ * @returns {undefined}
834
+ * @private
835
+ * @memberof Meeting
836
+ */
837
+ setLocus(locus: {
838
+ mediaConnections: Array<any>;
839
+ locusUrl: string;
840
+ locusId: string;
841
+ mediaId: string;
842
+ host: object;
843
+ } | any): void;
844
+ /**
845
+ * Upload logs for the current meeting
846
+ * @param {object} options file name and function name
847
+ * @returns {undefined}
848
+ * @public
849
+ * @memberof Meeting
850
+ */
851
+ uploadLogs(options?: object): void;
852
+ /**
853
+ * Removes remote audio, video and share streams from class instance's mediaProperties
854
+ * @returns {undefined}
855
+ */
856
+ unsetRemoteStreams(): void;
857
+ /**
858
+ * Removes the remote stream on the class instance and triggers an event
859
+ * to developers
860
+ * @returns {undefined}
861
+ * @public
862
+ * @memberof Meeting
863
+ * @deprecated after v1.89.3
864
+ */
865
+ closeRemoteStream(): void;
866
+ /**
867
+ * Removes the remote streams on the class instance and triggers an event
868
+ * to developers
869
+ * @returns {undefined}
870
+ * @memberof Meeting
871
+ */
872
+ closeRemoteStreams(): Promise<[any, any, any]>;
873
+ /**
874
+ * Stores the reference to a new microphone stream, sets up the required event listeners
875
+ * on it, cleans up previous stream, etc.
876
+ *
877
+ * @param {LocalMicrophoneStream | null} localStream local microphone stream
878
+ * @returns {Promise<void>}
879
+ */
880
+ private setLocalAudioStream;
881
+ /**
882
+ * Stores the reference to a new camera stream, sets up the required event listeners
883
+ * on it, cleans up previous stream, etc.
884
+ *
885
+ * @param {LocalCameraStream | null} localStream local camera stream
886
+ * @returns {Promise<void>}
887
+ */
888
+ private setLocalVideoStream;
889
+ /**
890
+ * Stores the reference to a new screen share stream, sets up the required event listeners
891
+ * on it, cleans up previous stream, etc.
892
+ * It also sends the floor grant/release request.
893
+ *
894
+ * @param {LocalDisplayStream | undefined} localDisplayStream local display stream
895
+ * @returns {Promise<void>}
896
+ */
897
+ private setLocalShareVideoStream;
898
+ /**
899
+ * Stores the reference to a new screen share audio stream, sets up the required event listeners
900
+ * on it, cleans up previous stream, etc.
901
+ *
902
+ * @param {LocalSystemAudioStream | undefined} localSystemAudioStream local system audio stream
903
+ * @returns {Promise<void>}
904
+ */
905
+ private setLocalShareAudioStream;
906
+ /**
907
+ * sets up listner for mercury event
908
+ * @returns {undefined}
909
+ * @public
910
+ * @memberof Meeting
911
+ */
912
+ setMercuryListener(): void;
913
+ /**
914
+ * Close the peer connections and remove them from the class.
915
+ * Cleanup any media connection related things.
916
+ *
917
+ * @returns {Promise}
918
+ * @public
919
+ * @memberof Meeting
920
+ */
921
+ closePeerConnections(): Promise<void>;
922
+ /**
923
+ * Unsets the peer connections on the class
924
+ * warning DO NOT CALL WITHOUT CLOSING PEER CONNECTIONS FIRST
925
+ * @returns {undefined}
926
+ * @public
927
+ * @memberof Meeting
928
+ */
929
+ unsetPeerConnections(): void;
930
+ /**
931
+ * Convenience method to set the correlation id for the callStateForMetrics
932
+ * @param {String} id correlation id to set on the callStateForMetrics
933
+ * @returns {undefined}
934
+ * @public
935
+ * @memberof Meeting
936
+ */
937
+ setCorrelationId(id: string): void;
938
+ /**
939
+ * Update the callStateForMetrics
940
+ * @param {CallStateForMetrics} callStateForMetrics updated values for callStateForMetrics
941
+ * @returns {undefined}
942
+ * @public
943
+ * @memberof Meeting
944
+ */
945
+ updateCallStateForMetrics(callStateForMetrics: CallStateForMetrics): void;
946
+ /**
947
+ * Enqueue request for screenshare floor and set the status to pending
948
+ * @returns {Promise}
949
+ * @private
950
+ * @memberof Meeting
951
+ */
952
+ private enqueueScreenShareFloorRequest;
953
+ /**
954
+ * Mute the audio for a meeting
955
+ * @returns {Promise} resolves the data from muting audio {mute, self} or rejects if there is no audio set
956
+ * @public
957
+ * @memberof Meeting
958
+ */
959
+ muteAudio(): any;
960
+ /**
961
+ * Unmute meeting audio
962
+ * @returns {Promise} resolves data from muting audio {mute, self} or rejects if there is no audio set
963
+ * @public
964
+ * @memberof Meeting
965
+ */
966
+ unmuteAudio(): any;
967
+ /**
968
+ * Mute the video for a meeting
969
+ * @returns {Promise} resolves data from muting video {mute, self} or rejects if there is no video set
970
+ * @public
971
+ * @memberof Meeting
972
+ */
973
+ muteVideo(): any;
974
+ /**
975
+ * Unmute meeting video
976
+ * @returns {Promise} resolves data from muting video {mute, self} or rejects if there is no video set
977
+ * @public
978
+ * @memberof Meeting
979
+ */
980
+ unmuteVideo(): any;
981
+ /**
982
+ * Shorthand function to join AND set up media
983
+ * @param {Object} options - options to join with media
984
+ * @param {JoinOptions} [options.joinOptions] - see #join()
985
+ * @param {AddMediaOptions} [options.mediaOptions] - see #addMedia()
986
+ * @returns {Promise} -- {join: see join(), media: see addMedia()}
987
+ * @public
988
+ * @memberof Meeting
989
+ * @example
990
+ * joinWithMedia({
991
+ * joinOptions: {resourceId: 'resourceId' },
992
+ * mediaOptions: {
993
+ * localStreams: { microphone: microphoneStream, camera: cameraStream }
994
+ * }
995
+ * })
996
+ */
997
+ joinWithMedia(options?: {
998
+ joinOptions?: any;
999
+ mediaOptions?: AddMediaOptions;
1000
+ }): Promise<{
1001
+ join: any;
1002
+ media: void;
1003
+ }>;
1004
+ /**
1005
+ * Initiates the reconnection of the media in the meeting
1006
+ *
1007
+ * @param {object} options
1008
+ * @returns {Promise} resolves with {reconnect} or errors with {error}
1009
+ * @public
1010
+ * @memberof Meeting
1011
+ */
1012
+ reconnect(options?: object): any;
1013
+ /**
1014
+ * Check if the meeting supports the Webex Assistant feature
1015
+ * @returns {boolean}
1016
+ * @throws TranscriptionNotSupportedError
1017
+ */
1018
+ isTranscriptionSupported(): boolean;
1019
+ /**
1020
+ * Check if the meeting supports the Reactions
1021
+ * @returns {boolean}
1022
+ */
1023
+ isReactionsSupported(): boolean;
1024
+ /**
1025
+ * Monitor the Low-Latency Mercury (LLM) web socket connection on `onError` and `onClose` states
1026
+ * @private
1027
+ * @returns {void}
1028
+ */
1029
+ private monitorTranscriptionSocketConnection;
1030
+ /**
1031
+ * Request for a WebSocket Url, open and monitor the WebSocket connection
1032
+ * @private
1033
+ * @returns {Promise<void>} a promise to open the WebSocket connection
1034
+ */
1035
+ private startTranscription;
1036
+ /**
1037
+ * Callback called when a relay event is received from meeting LLM Connection
1038
+ * @param {RelayEvent} e Event object coming from LLM Connection
1039
+ * @private
1040
+ * @returns {void}
1041
+ */
1042
+ private processRelayEvent;
1043
+ /**
1044
+ * stop recieving Transcription by closing
1045
+ * the web socket connection properly
1046
+ * @returns {void}
1047
+ */
1048
+ stopReceivingTranscription(): void;
1049
+ /**
1050
+ * triggers an event to notify that the user
1051
+ * will not receive any more transcription
1052
+ * @private
1053
+ * @returns{void}
1054
+ */
1055
+ private triggerStopReceivingTranscriptionEvent;
1056
+ /**
1057
+ * Specify joining via audio (option: pstn), video, screenshare
1058
+ * @param {JoinOptions} options A configurable options object for joining a meeting
1059
+ * @returns {Promise} the join response
1060
+ * @public
1061
+ * @memberof Meeting
1062
+ * Scenario A: Joining own claimed personal meeting room
1063
+ * Scenario B: Joining other's claimed personal meeting room, do pass pin (if desired to join as host, or nullify), do pass moderator
1064
+ * Scenario C: Joining an unclaimed personal meeting room, -do not- pass pin or moderator on first try, -do- pass pin and moderator
1065
+ * if joining as host on second loop, pass pin and pass moderator if joining as guest on second loop
1066
+ * Scenario D: Joining any other way (sip, pstn, conversationUrl, link just need to specify resourceId)
1067
+ */
1068
+ join(options?: any): Promise<any>;
1069
+ /**
1070
+ * Connects to low latency mercury and reconnects if the address has changed
1071
+ * It will also disconnect if called when the meeting has ended
1072
+ * @param {String} datachannelUrl
1073
+ * @returns {Promise}
1074
+ */
1075
+ updateLLMConnection(): Promise<any>;
1076
+ /**
1077
+ * Use phone for meeting audio
1078
+ * @param {String} phoneNumber If provided, it will dial-out using this number. If not provided, dial-in will be used
1079
+ * @returns {Promise} Resolves once the dial-in or dial-out request has completed, or rejects if it failed
1080
+ * @public
1081
+ * @memberof Meeting
1082
+ */
1083
+ usePhoneAudio(phoneNumber: string): Promise<any>;
1084
+ /**
1085
+ * Determines if the given pstnStatus is in a state which implies the phone is provisioned
1086
+ * @param {String} pstnStatus
1087
+ * @returns {Boolean}
1088
+ * @private
1089
+ * @memberof Meeting
1090
+ */
1091
+ private isPhoneProvisioned;
1092
+ /**
1093
+ * Enable dial-in for audio
1094
+ * @returns {Promise} Resolves once the dial-in request has completed, or rejects if it failed
1095
+ * @private
1096
+ * @memberof Meeting
1097
+ */
1098
+ private dialInPstn;
1099
+ /**
1100
+ * Enable dial-out for audio
1101
+ * @param {String} phoneNumber Phone number to dial out to
1102
+ * @returns {Promise} Resolves once the dial-out request has completed (it doesn't wait for the user to answer the phone), or rejects if it failed
1103
+ * @private
1104
+ * @memberof Meeting
1105
+ */
1106
+ private dialOutPstn;
1107
+ /**
1108
+ * Disconnect meeting audio via phone.
1109
+ * @returns {Promise} Resolves once the phone audio disconnection has completed
1110
+ * @public
1111
+ * @memberof Meeting
1112
+ * @returns {Promise}
1113
+ */
1114
+ disconnectPhoneAudio(): Promise<[any, any]>;
1115
+ /**
1116
+ * Moves the call to the specified resourceId
1117
+ * @param {String} resourceId
1118
+ * @returns {Promise} once the move has been completed
1119
+ * @public
1120
+ * @memberof Meeting
1121
+ */
1122
+ moveTo(resourceId: string): any;
1123
+ /**
1124
+ * Moves the call from the specified resourceId, back to computer
1125
+ * @param {String} resourceId
1126
+ * @returns {Promise} once the move has been completed
1127
+ * @public
1128
+ * @memberof Meeting
1129
+ */
1130
+ moveFrom(resourceId: string): any;
1131
+ /**
1132
+ * Handles ROAP_FAILURE event from the webrtc media connection
1133
+ *
1134
+ * @param {Error} error
1135
+ * @returns {void}
1136
+ */
1137
+ handleRoapFailure: (error: any) => void;
1138
+ /**
1139
+ * This function makes sure we send the right metrics when local and remote SDPs are processed/generated
1140
+ *
1141
+ * @returns {undefined}
1142
+ */
1143
+ setupSdpListeners: () => void;
1144
+ setupMediaConnectionListeners: () => void;
1145
+ /**
1146
+ * Registers for all required StatsAnalyzer events
1147
+ * @private
1148
+ * @returns {void}
1149
+ * @memberof Meetings
1150
+ */
1151
+ setupStatsAnalyzerEventHandlers: () => void;
1152
+ getMediaConnectionDebugId(): string;
1153
+ /**
1154
+ * Creates a webrtc media connection and publishes streams to it
1155
+ *
1156
+ * @param {Object} turnServerInfo TURN server information
1157
+ * @param {BundlePolicy} [bundlePolicy] Bundle policy settings
1158
+ * @param {AddMediaOptions} [options] Options for enabling/disabling audio/video
1159
+ * @returns {RoapMediaConnection | MultistreamRoapMediaConnection}
1160
+ */
1161
+ private createMediaConnection;
1162
+ /**
1163
+ * Listens for an event emitted by eventEmitter and emits it from the meeting object
1164
+ *
1165
+ * @private
1166
+ * @param {*} eventEmitter object from which to forward the event
1167
+ * @param {*} eventTypeToForward which event type to listen on and to forward
1168
+ * @param {string} meetingEventType event type to be used in the event emitted from the meeting object
1169
+ * @returns {void}
1170
+ */
1171
+ forwardEvent(eventEmitter: any, eventTypeToForward: any, meetingEventType: any): void;
1172
+ /**
1173
+ * Sets up all the references to local streams in this.mediaProperties before creating media connection
1174
+ * and before TURN discovery, so that the correct mute state is sent with TURN discovery roap messages.
1175
+ *
1176
+ * @private
1177
+ * @param {LocalStreams} localStreams
1178
+ * @returns {Promise<void>}
1179
+ */
1180
+ private setUpLocalStreamReferences;
1181
+ /**
1182
+ * Calls mediaProperties.waitForMediaConnectionConnected() and sends CA client.ice.end metric on failure
1183
+ *
1184
+ * @private
1185
+ * @returns {Promise<void>}
1186
+ */
1187
+ private waitForMediaConnectionConnected;
1188
+ /**
1189
+ * Enables statsAnalyser if config allows it
1190
+ *
1191
+ * @private
1192
+ * @returns {void}
1193
+ */
1194
+ private createStatsAnalyzer;
1195
+ /**
1196
+ * Handles device logging
1197
+ *
1198
+ * @private
1199
+ * @static
1200
+ * @returns {Promise<void>}
1201
+ */
1202
+ private static handleDeviceLogging;
1203
+ /**
1204
+ * Returns a promise. This promise is created once the local sdp offer has been successfully created and is resolved
1205
+ * once the remote sdp answer has been received.
1206
+ *
1207
+ * @private
1208
+ * @returns {Promise<void>}
1209
+ */
1210
+ private waitForRemoteSDPAnswer;
1211
+ /**
1212
+ * Calls establishMediaConnection with isForced = true to force turn discovery to happen
1213
+ *
1214
+ * @private
1215
+ * @param {RemoteMediaManagerConfiguration} [remoteMediaManagerConfig]
1216
+ * @param {BundlePolicy} [bundlePolicy]
1217
+ * @returns {Promise<void>}
1218
+ */
1219
+ private retryEstablishMediaConnectionWithForcedTurnDiscovery;
1220
+ /**
1221
+ * Does relevant clean up before retrying to establish media connection
1222
+ * and performs the retry with forced turn discovery
1223
+ *
1224
+ * @private
1225
+ * @param {RemoteMediaManagerConfiguration} [remoteMediaManagerConfig]
1226
+ * @param {BundlePolicy} [bundlePolicy]
1227
+ * @returns {Promise<void>}
1228
+ */
1229
+ private retryWithForcedTurnDiscovery;
1230
+ /**
1231
+ * If waitForMediaConnectionConnected() fails when we haven't done turn discovery then we
1232
+ * attempt to establish a media connection again, but this time using turn discovery. If we
1233
+ * used turn discovery on the first pass we do not attempt connection again.
1234
+ *
1235
+ * @private
1236
+ * @param {Error} error
1237
+ * @param {RemoteMediaManagerConfiguration} [remoteMediaManagerConfig]
1238
+ * @param {BundlePolicy} [bundlePolicy]
1239
+ * @returns {Promise<void>}
1240
+ */
1241
+ private handleWaitForMediaConnectionConnectedError;
1242
+ /**
1243
+ * Does TURN discovery, SDP offer/answer exhange, establishes ICE connection and DTLS handshake.
1244
+ *
1245
+ * @private
1246
+ * @param {RemoteMediaManagerConfiguration} [remoteMediaManagerConfig]
1247
+ * @param {BundlePolicy} [bundlePolicy]
1248
+ * @param {boolean} [isForced] - let isForced be true to do turn discovery regardless of reachability results
1249
+ * @returns {Promise<void>}
1250
+ */
1251
+ private establishMediaConnection;
1252
+ /**
1253
+ * Cleans up stats analyzer, peer connection, and turns off listeners
1254
+ *
1255
+ * @private
1256
+ * @returns {Promise<void>}
1257
+ */
1258
+ private cleanUpOnAddMediaFailure;
1259
+ /**
1260
+ * Sends stats report, closes peer connection and cleans up any media connection
1261
+ * related things before trying to establish media connection again with turn server
1262
+ *
1263
+ * @private
1264
+ * @returns {Promise<void>}
1265
+ */
1266
+ private cleanUpBeforeRetryWithTurnServer;
1267
+ /**
1268
+ * Creates a media connection to the server. Media connection is required for sending or receiving any audio/video.
1269
+ *
1270
+ * @param {AddMediaOptions} options
1271
+ * @returns {Promise<void>}
1272
+ * @public
1273
+ * @memberof Meeting
1274
+ */
1275
+ addMedia(options?: AddMediaOptions): Promise<void>;
1276
+ /**
1277
+ * Informs if the peer connection is in a state that can be updated with updateMedia (audio/video/share)
1278
+ * @returns {Boolean}
1279
+ */
1280
+ canUpdateMedia(): boolean;
1281
+ /**
1282
+ * media failed, so collect a stats report from webrtc using the wcme connection to grab the rtc stats report
1283
+ * send a webrtc telemetry dump to the configured server using the internal media core check metrics configured callback
1284
+ * @param {String} callFrom - the function calling this function, optional.
1285
+ * @returns {Promise<void>}
1286
+ */
1287
+ private forceSendStatsReport;
1288
+ /**
1289
+ * Enqueues a media update operation.
1290
+ * @param {String} mediaUpdateType one of MEDIA_UPDATE_TYPE values
1291
+ * @param {Object} options
1292
+ * @returns {Promise}
1293
+ * @private
1294
+ * @memberof Meeting
1295
+ */
1296
+ private enqueueMediaUpdate;
1297
+ /**
1298
+ * emits event when the negotation is completed
1299
+ * @returns {void}
1300
+ * @private
1301
+ * @memberof Meeting
1302
+ */
1303
+ mediaNegotiatedEvent: () => void;
1304
+ /**
1305
+ * Checks if there are any queued media updates and runs the first one from
1306
+ * the queue if we are in a state that allows doing that.
1307
+ * @returns {undefined}
1308
+ * @public
1309
+ * @memberof Meeting
1310
+ */
1311
+ processNextQueuedMediaUpdate: () => void;
1312
+ /**
1313
+ * Updates the media connection - it allows to enable/disable all audio/video/share in the meeting.
1314
+ * This does not affect the published tracks, so for example if a microphone track is published and
1315
+ * updateMedia({audioEnabled: false}) is called, the audio will not be sent or received anymore,
1316
+ * but the track's "published" state is not changed and when updateMedia({audioEnabled: true}) is called,
1317
+ * the sending of the audio from the same track will resume.
1318
+ *
1319
+ * @param {Object} options
1320
+ * @param {boolean} options.audioEnabled [optional] enables/disables receiving and sending of main audio in the meeting
1321
+ * @param {boolean} options.videoEnabled [optional] enables/disables receiving and sending of main video in the meeting
1322
+ * @param {boolean} options.shareEnabled [optional] enables/disables receiving and sending of screen share in the meeting
1323
+ * @returns {Promise}
1324
+ * @public
1325
+ * @memberof Meeting
1326
+ */
1327
+ updateMedia(options: {
1328
+ audioEnabled?: boolean;
1329
+ videoEnabled?: boolean;
1330
+ shareAudioEnabled?: boolean;
1331
+ shareVideoEnabled?: boolean;
1332
+ }): Promise<void>;
1333
+ /**
1334
+ * Acknowledge the meeting, outgoing or incoming
1335
+ * @param {String} type
1336
+ * @returns {Promise} resolve {message, ringing, response}
1337
+ * @public
1338
+ * @memberof Meeting
1339
+ */
1340
+ acknowledge(type: string): Promise<{
1341
+ response: any;
1342
+ }> | Promise<{
1343
+ message: string;
1344
+ }>;
1345
+ /**
1346
+ * Decline this meeting
1347
+ * @param {String} reason
1348
+ * @returns {undefined}
1349
+ * @public
1350
+ * @memberof Meeting
1351
+ */
1352
+ decline(reason: string): any;
1353
+ /**
1354
+ * Returns a promise that will resolve to fetch options for leaving a meeting.
1355
+ *
1356
+ * This is to support quickly submitting a leave request when the browser/tab is closing.
1357
+ * Calling meeting.leave will not work because there are some async steps that will
1358
+ * not complete before the browser is closed. Instead, we pre-gather all the
1359
+ * information/options needed for the request(s), and then simply and quickly
1360
+ * fire the fetch(es) when pagehide is triggered.
1361
+ *
1362
+ * We must use fetch instead of request because fetch has a keepalive option that
1363
+ * allows the request it to outlive the page.
1364
+ *
1365
+ * Note: the $timings values will be wrong, but setRequestTimingsAndFetch() will
1366
+ * properly adjust them before submitting.
1367
+ *
1368
+ * @public
1369
+ * @param {Object} options leave options
1370
+ * @param {String} options.resourceId the device with which to leave from, empty if just the computer
1371
+ * @param {any} options.reason the reason for leaving
1372
+ * @returns {Promise} resolves to options to be used with fetch
1373
+ */
1374
+ buildLeaveFetchRequestOptions(options?: {
1375
+ resourceId?: string;
1376
+ reason?: any;
1377
+ }): any;
1378
+ /**
1379
+ * Leave the current meeting
1380
+ * @param {Object} options - leave options
1381
+ * @param {String} [options.resourceId] - the device with which to leave from, empty if just the computer
1382
+ * @param {String} [options.clientEventLeaveReason] - the leaveReason to include in the Call Analyzer event.
1383
+ * Must be one of: 'paired-leave' | 'one-to-one' | 'ended-by-locus' (defaults to no reason)
1384
+ * https://sqbu-github.cisco.com/WebExSquared/event-dictionary/blob/main/diagnostic-events.raml#L796
1385
+ * @param {String} [options.reason] - only used for logging
1386
+ * @returns {Promise}
1387
+ * @public
1388
+ * @memberof Meeting
1389
+ */
1390
+ leave(options?: {
1391
+ resourceId?: string;
1392
+ clientEventLeaveReason?: ClientEventLeaveReason;
1393
+ reason?: any;
1394
+ }): any;
1395
+ /**
1396
+ * Start sharing whiteboard given channelUrl
1397
+ * @param {string} channelUrl whiteboard url
1398
+ * @param {String} resourceToken token created by authorize media injector
1399
+ * @returns {Promise}
1400
+ * @public
1401
+ * @memberof Meeting
1402
+ */
1403
+ startWhiteboardShare(channelUrl: string, resourceToken: string): any;
1404
+ /**
1405
+ * Stop sharing whiteboard given channelUrl
1406
+ * @param {string} channelUrl whiteboard url
1407
+ * @returns {Promise}
1408
+ * @public
1409
+ * @memberof Meeting
1410
+ */
1411
+ stopWhiteboardShare(channelUrl: string): any;
1412
+ /**
1413
+ * Sends a request to Locus to obtain the screen share floor
1414
+ * @returns {Promise} see #meetingRequest.changeMeetingFloor
1415
+ * @private
1416
+ * @memberof Meeting
1417
+ */
1418
+ private requestScreenShareFloor;
1419
+ /**
1420
+ * Requests screen share floor if such request is pending.
1421
+ * It should be called whenever meeting state changes to JOINED
1422
+ *
1423
+ * @returns {void}
1424
+ */
1425
+ private requestScreenShareFloorIfPending;
1426
+ /**
1427
+ * Sends a request to Locus to release the screen share floor.
1428
+ * @returns {Promise} see #meetingRequest.changeMeetingFloor
1429
+ * @private
1430
+ * @memberof Meeting
1431
+ */
1432
+ private releaseScreenShareFloor;
1433
+ /**
1434
+ * Intiate a recording of this meeting
1435
+ * @returns {Promise}
1436
+ * @public
1437
+ * @memberof Meeting
1438
+ */
1439
+ startRecording(): Promise<any>;
1440
+ /**
1441
+ * set the mute on entry flag for participants if you're the host
1442
+ * @returns {Promise}
1443
+ * @param {boolean} enabled
1444
+ * @public
1445
+ * @memberof Meeting
1446
+ */
1447
+ setMuteOnEntry(enabled: boolean): Promise<any>;
1448
+ /**
1449
+ * set the disallow unmute flag for participants if you're the host
1450
+ * @returns {Promise}
1451
+ * @param {boolean} enabled
1452
+ * @public
1453
+ * @memberof Meeting
1454
+ */
1455
+ setDisallowUnmute(enabled: boolean): Promise<any>;
1456
+ /**
1457
+ * set the mute all flag for participants if you're the host
1458
+ * @returns {Promise}
1459
+ * @param {boolean} mutedEnabled
1460
+ * @param {boolean} disallowUnmuteEnabled
1461
+ * @param {boolean} muteOnEntryEnabled
1462
+ * @public
1463
+ * @memberof Meeting
1464
+ */
1465
+ setMuteAll(mutedEnabled: boolean, disallowUnmuteEnabled: boolean, muteOnEntryEnabled: boolean): Promise<any>;
1466
+ /**
1467
+ * End the recording of this meeting
1468
+ * @returns {Promise}
1469
+ * @public
1470
+ * @memberof Meeting
1471
+ */
1472
+ stopRecording(): Promise<any>;
1473
+ /**
1474
+ * Pauses the recording of this meeting
1475
+ * @returns {Promise}
1476
+ * @public
1477
+ * @memberof Meeting
1478
+ */
1479
+ pauseRecording(): Promise<any>;
1480
+ /**
1481
+ * Resumes the recording of this meeting
1482
+ * @returns {Promise}
1483
+ * @public
1484
+ * @memberof Meeting
1485
+ */
1486
+ resumeRecording(): Promise<any>;
1487
+ /**
1488
+ * Locks the current meeting if possible
1489
+ * @returns {Promise}
1490
+ * @public
1491
+ * @memberof Meeting
1492
+ */
1493
+ lockMeeting(): any;
1494
+ /**
1495
+ * Unlocks the current meeting if possible
1496
+ * @returns {Promise}
1497
+ * @public
1498
+ * @memberof Meeting
1499
+ */
1500
+ unlockMeeting(): any;
1501
+ /**
1502
+ * Logs an error message and returns a rejected promise with same message
1503
+ * @param {String} message
1504
+ * @returns {Promise}
1505
+ * @private
1506
+ * @memberof Meeting
1507
+ */
1508
+ private rejectWithErrorLog;
1509
+ /**
1510
+ * Sends DTMF tones to the current meeting
1511
+ * @param {String} tones a string of one or more DTMF tones to send
1512
+ * @returns {Promise}
1513
+ * @public
1514
+ * @memberof Meeting
1515
+ */
1516
+ sendDTMF(tones: string): Promise<any>;
1517
+ /**
1518
+ * Sends request to change layout type for the current meeting for the specific participant/device only
1519
+ * @param {String} [layoutType] a layout type that should be available in meeting constants {@link #layout_types}
1520
+ * @param {Object} renderInfo preferred dimensions for the remote main and content streams (server can ignore it)
1521
+ * @param {Object} renderInfo.main preferred dimensions for the remote main video stream
1522
+ * @param {Number} renderInfo.main.width preferred width of main video stream
1523
+ * @param {Number} renderInfo.main.height preferred height of main video stream
1524
+ * @param {Object} renderInfo.content preferred dimensions for the remote content share stream
1525
+ * @param {Number} renderInfo.content.width preferred width of content share stream
1526
+ * @param {Number} renderInfo.content.height preferred height of content share stream
1527
+ * @returns {Promise}
1528
+ * @public
1529
+ * @memberof Meeting
1530
+ */
1531
+ changeVideoLayout(layoutType?: string, renderInfo?: {
1532
+ main: {
1533
+ width: number;
1534
+ height: number;
1535
+ };
1536
+ content: {
1537
+ width: number;
1538
+ height: number;
1539
+ };
1540
+ }): any;
1541
+ /**
1542
+ * Sets the quality level of the remote incoming media
1543
+ * @param {String} level {LOW|MEDIUM|HIGH}
1544
+ * @returns {Promise}
1545
+ */
1546
+ setRemoteQualityLevel(level: string): Promise<void>;
1547
+ /**
1548
+ * Functionality for when a share audio is ended.
1549
+ * @private
1550
+ * @memberof Meeting
1551
+ * @returns {undefined}
1552
+ */
1553
+ private handleShareAudioStreamEnded;
1554
+ /**
1555
+ * Functionality for when a share video is muted or unmuted.
1556
+ * @private
1557
+ * @memberof Meeting
1558
+ * @param {boolean} muted
1559
+ * @returns {undefined}
1560
+ */
1561
+ private handleShareVideoStreamMuteStateChange;
1562
+ /**
1563
+ * Functionality for when a share video is ended.
1564
+ * @private
1565
+ * @memberof Meeting
1566
+ * @returns {undefined}
1567
+ */
1568
+ private handleShareVideoStreamEnded;
1569
+ /**
1570
+ * Emits meeting:stoppedSharingLocal
1571
+ * @private
1572
+ * @returns {undefined}
1573
+ * @memberof Meeting
1574
+ */
1575
+ private triggerStoppedSharing;
1576
+ /**
1577
+ * Emits the 'network:quality' event
1578
+ * 1 indicates an acceptable uplink network.
1579
+ * 0 indicates an unacceptable uplink network based on a predefined threshold
1580
+ * @returns {undefined}
1581
+ * @param {Object} res - payload of emitNetworkQuality
1582
+ * @property {string} mediaType {video|audio}
1583
+ * @property {number} networkQualityScore - {1|0}
1584
+ * @private
1585
+ * @memberof Meeting
1586
+ */
1587
+ private sendNetworkQualityEvent;
1588
+ /**
1589
+ * Handle logging the media
1590
+ * @param {Object} mediaProperties
1591
+ * @private
1592
+ * @returns {undefined}
1593
+ */
1594
+ private handleMediaLogging;
1595
+ /**
1596
+ *
1597
+ * @returns {string} one of 'attendee','host','cohost', returns the user type of the current user
1598
+ */
1599
+ getCurUserType(): "host" | "cohost" | "attendee";
1600
+ /**
1601
+ * End the current meeting for all
1602
+ * @returns {Promise}
1603
+ * @public
1604
+ * @memberof Meeting
1605
+ */
1606
+ endMeetingForAll(): any;
1607
+ /**
1608
+ * clear the meeting data
1609
+ * @returns {undefined}
1610
+ * @public
1611
+ * @memberof Meeting
1612
+ */
1613
+ clearMeetingData: () => void;
1614
+ /**
1615
+ * starts keepAlives being sent
1616
+ * @returns {void}
1617
+ * @private
1618
+ * @memberof Meeting
1619
+ */
1620
+ startKeepAlive: () => void;
1621
+ /**
1622
+ * stops keepAlives being sent
1623
+ * @returns {void}
1624
+ * @private
1625
+ * @memberof Meeting
1626
+ */
1627
+ stopKeepAlive: () => void;
1628
+ /**
1629
+ * Send a reaction inside the meeting.
1630
+ *
1631
+ * @param {ReactionServerType} reactionType - type of reaction to be sent. Example: "thumbs_up"
1632
+ * @param {SkinToneType} skinToneType - skin tone for the reaction. Example: "medium_dark"
1633
+ * @returns {Promise}
1634
+ * @public
1635
+ * @memberof Meeting
1636
+ */
1637
+ sendReaction(reactionType: ReactionServerType, skinToneType?: SkinToneType): any;
1638
+ /**
1639
+ * Method to enable or disable reactions inside the meeting.
1640
+ *
1641
+ * @param {boolean} enable - enable or disable reactions
1642
+ * @returns {Promise}
1643
+ * @public
1644
+ * @memberof Meeting
1645
+ */
1646
+ toggleReactions(enable: boolean): Promise<any>;
1647
+ /**
1648
+ * Throws if we don't have a media connection created
1649
+ *
1650
+ * @returns {void}
1651
+ */
1652
+ private checkMediaConnection;
1653
+ /**
1654
+ * Method to enable or disable the 'Music mode' effect on audio stream
1655
+ *
1656
+ * @param {boolean} shouldEnableMusicMode
1657
+ * @returns {Promise}
1658
+ */
1659
+ enableMusicMode(shouldEnableMusicMode: boolean): Promise<void>;
1660
+ /** Updates the tracks being sent on the transcoded media connection
1661
+ *
1662
+ * @returns {Promise<void>}
1663
+ */
1664
+ private updateTranscodedMediaConnection;
1665
+ /**
1666
+ * Publishes a stream.
1667
+ *
1668
+ * @param {MediaType} mediaType of the stream
1669
+ * @param {LocalStream} stream to publish
1670
+ * @returns {Promise}
1671
+ */
1672
+ private publishStream;
1673
+ /**
1674
+ * Un-publishes a stream.
1675
+ *
1676
+ * @param {MediaType} mediaType of the stream
1677
+ * @param {LocalStream} stream to unpublish
1678
+ * @returns {Promise}
1679
+ */
1680
+ private unpublishStream;
1681
+ /**
1682
+ * Publishes specified local streams in the meeting
1683
+ *
1684
+ * @param {Object} streams
1685
+ * @returns {Promise}
1686
+ */
1687
+ publishStreams(streams: LocalStreams): Promise<void>;
1688
+ /**
1689
+ * Un-publishes specified local streams in the meeting
1690
+ *
1691
+ * @param {Array<LocalStream>} streams
1692
+ * @returns {Promise}
1693
+ */
1694
+ unpublishStreams(streams: LocalStream[]): Promise<void>;
1695
+ /**
1696
+ * Gets permission token expiry information including timeLeft, expiryTime, currentTime
1697
+ * (from the time the function has been fired)
1698
+ *
1699
+ * @returns {object} containing timeLeft, expiryTime, currentTime
1700
+ */
1701
+ getPermissionTokenExpiryInfo(): {
1702
+ timeLeft: number;
1703
+ expiryTime: number;
1704
+ currentTime: number;
1705
+ };
1706
+ /**
1707
+ * Check if there is enough time left till the permission token expires
1708
+ * If not - refresh the permission token
1709
+ *
1710
+ * @param {number} threshold - time in seconds
1711
+ * @param {string} reason - reason for refreshing the permission token
1712
+ * @returns {Promise<void>}
1713
+ */
1714
+ checkAndRefreshPermissionToken(threshold: number, reason: string): Promise<void>;
1715
+ }