@webex/internal-plugin-metrics 3.0.0-beta.28 → 3.0.0-beta.280

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 (60) hide show
  1. package/dist/call-diagnostic/call-diagnostic-metrics-batcher.js +65 -0
  2. package/dist/call-diagnostic/call-diagnostic-metrics-batcher.js.map +1 -0
  3. package/dist/call-diagnostic/call-diagnostic-metrics-latencies.js +456 -0
  4. package/dist/call-diagnostic/call-diagnostic-metrics-latencies.js.map +1 -0
  5. package/dist/call-diagnostic/call-diagnostic-metrics.js +775 -0
  6. package/dist/call-diagnostic/call-diagnostic-metrics.js.map +1 -0
  7. package/dist/call-diagnostic/call-diagnostic-metrics.util.js +337 -0
  8. package/dist/call-diagnostic/call-diagnostic-metrics.util.js.map +1 -0
  9. package/dist/call-diagnostic/config.js +604 -0
  10. package/dist/call-diagnostic/config.js.map +1 -0
  11. package/dist/config.js +20 -1
  12. package/dist/config.js.map +1 -1
  13. package/dist/index.js +30 -1
  14. package/dist/index.js.map +1 -1
  15. package/dist/metrics.js +30 -30
  16. package/dist/metrics.js.map +1 -1
  17. package/dist/metrics.types.js +7 -0
  18. package/dist/metrics.types.js.map +1 -0
  19. package/dist/new-metrics.js +333 -0
  20. package/dist/new-metrics.js.map +1 -0
  21. package/dist/types/batcher.d.ts +2 -0
  22. package/dist/types/call-diagnostic/call-diagnostic-metrics-batcher.d.ts +2 -0
  23. package/dist/types/call-diagnostic/call-diagnostic-metrics-latencies.d.ts +194 -0
  24. package/dist/types/call-diagnostic/call-diagnostic-metrics.d.ts +395 -0
  25. package/dist/types/call-diagnostic/call-diagnostic-metrics.util.d.ts +96 -0
  26. package/dist/types/call-diagnostic/config.d.ts +171 -0
  27. package/dist/types/client-metrics-batcher.d.ts +2 -0
  28. package/dist/types/config.d.ts +35 -0
  29. package/dist/types/index.d.ts +13 -0
  30. package/dist/types/metrics.d.ts +3 -0
  31. package/dist/types/metrics.types.d.ts +103 -0
  32. package/dist/types/new-metrics.d.ts +139 -0
  33. package/dist/types/utils.d.ts +6 -0
  34. package/dist/utils.js +27 -0
  35. package/dist/utils.js.map +1 -0
  36. package/package.json +13 -8
  37. package/src/call-diagnostic/call-diagnostic-metrics-batcher.ts +82 -0
  38. package/src/call-diagnostic/call-diagnostic-metrics-latencies.ts +414 -0
  39. package/src/call-diagnostic/call-diagnostic-metrics.ts +843 -0
  40. package/src/call-diagnostic/call-diagnostic-metrics.util.ts +362 -0
  41. package/src/call-diagnostic/config.ts +660 -0
  42. package/src/config.js +19 -0
  43. package/src/index.ts +43 -0
  44. package/src/metrics.js +25 -27
  45. package/src/metrics.types.ts +159 -0
  46. package/src/new-metrics.ts +317 -0
  47. package/src/utils.ts +17 -0
  48. package/test/unit/spec/call-diagnostic/call-diagnostic-metrics-batcher.ts +394 -0
  49. package/test/unit/spec/call-diagnostic/call-diagnostic-metrics-latencies.ts +477 -0
  50. package/test/unit/spec/call-diagnostic/call-diagnostic-metrics.ts +1787 -0
  51. package/test/unit/spec/call-diagnostic/call-diagnostic-metrics.util.ts +565 -0
  52. package/test/unit/spec/metrics.js +65 -97
  53. package/test/unit/spec/new-metrics.ts +269 -0
  54. package/test/unit/spec/utils.ts +22 -0
  55. package/tsconfig.json +6 -0
  56. package/dist/call-diagnostic-events-batcher.js +0 -60
  57. package/dist/call-diagnostic-events-batcher.js.map +0 -1
  58. package/src/call-diagnostic-events-batcher.js +0 -62
  59. package/src/index.js +0 -17
  60. package/test/unit/spec/call-diagnostic-events-batcher.js +0 -195
@@ -0,0 +1,395 @@
1
+ import { StatelessWebexPlugin } from '@webex/webex-core';
2
+ import { Event, ClientType, SubClientType, NetworkType, EnvironmentType, NewEnvironmentType, ClientEvent, SubmitClientEventOptions, MediaQualityEvent, SubmitMQEOptions, SubmitMQEPayload, ClientLaunchMethodType, ClientEventError, ClientEventPayload } from '../metrics.types';
3
+ type GetOriginOptions = {
4
+ clientType: ClientType;
5
+ subClientType: SubClientType;
6
+ networkType?: NetworkType;
7
+ clientLaunchMethod?: ClientLaunchMethodType;
8
+ environment?: EnvironmentType;
9
+ newEnvironment?: NewEnvironmentType;
10
+ };
11
+ type GetIdentifiersOptions = {
12
+ meeting?: any;
13
+ mediaConnections?: any[];
14
+ correlationId?: string;
15
+ preLoginId?: string;
16
+ globalMeetingId?: string;
17
+ webexConferenceIdStr?: string;
18
+ };
19
+ /**
20
+ * @description Util class to handle Call Analyzer Metrics
21
+ * @export
22
+ * @class CallDiagnosticMetrics
23
+ */
24
+ export default class CallDiagnosticMetrics extends StatelessWebexPlugin {
25
+ private callDiagnosticEventsBatcher;
26
+ private logger;
27
+ /**
28
+ * Constructor
29
+ * @param args
30
+ */
31
+ constructor(...args: any[]);
32
+ /**
33
+ * Returns the login type of the current user
34
+ * @returns one of 'login-ci','unverified-guest', null
35
+ */
36
+ getCurLoginType(): "unverified-guest" | "login-ci";
37
+ /**
38
+ * Returns if the meeting has converged architecture enabled
39
+ * @param options.meetingId
40
+ */
41
+ getIsConvergedArchitectureEnabled({ meetingId }: {
42
+ meetingId?: string;
43
+ }): boolean;
44
+ /**
45
+ * Get origin object for Call Diagnostic Event payload.
46
+ * @param options
47
+ * @param meetingId
48
+ * @returns
49
+ */
50
+ getOrigin(options: GetOriginOptions, meetingId?: string): {
51
+ name: "endpoint" | "antares" | "beech" | "breakout" | "cb" | "cloudproxy" | "edonus" | "givr" | "hecate" | "hedge" | "hesiod" | "homer" | "superhomer" | "l2sip" | "linus" | "locus" | "mcc" | "mcs" | "mercury" | "mes" | "mjs" | "mmp" | "mygdon" | "orpheus" | "page" | "poros" | "rhesos" | "terminus" | "tpgw" | "ucc" | "wdm" | "webexivr";
52
+ userAgent: string;
53
+ buildType?: "debug" | "test" | "prod" | "tap" | "analyzer-test";
54
+ upgradeChannel?: string;
55
+ instanceId?: string;
56
+ networkType: "wifi" | "ethernet" | "cellular" | "unknown";
57
+ localIP?: string;
58
+ usingProxy?: boolean;
59
+ mediaEngineSoftwareVersion?: string;
60
+ environment?: string;
61
+ newEnvironment?: string;
62
+ clientInfo?: {
63
+ os?: "windows" | "mac" | "ios" | "android" | "chrome" | "linux" | "other" | "android-x64" | "uwp-arm64";
64
+ osVersion?: string;
65
+ localIP?: string;
66
+ gatewayIP?: string;
67
+ macAddress?: string;
68
+ localNetworkPrefix?: string;
69
+ publicNetworkPrefix?: string;
70
+ browserLaunchMethod?: "url-handler" | "activex" | "npapi" | "extension" | "cwsapi" | "java" | "tfs" | "webacd" | "thinclient";
71
+ clientLaunchMethod?: "url-handler" | "universal-link" | "voice-command" | "notification" | "manual" | "teams-cross-launch" | "mc-cross-launch";
72
+ browser?: string;
73
+ browserVersion?: string;
74
+ clientType?: "MEETING_CENTER" | "EVENT_CENTER" | "TRAINING_CENTER" | "TEAMS_CLIENT" | "TEAMS_DEVICE" | "TEAMS_SHARE" | "SIP" | "RECORDING" | "CLOUD_AWARE_SIP" | "TEAMS_WXC_CLIENT" | "WXC_CLIENT" | "WXC_DEVICE" | "WEBEX_JS_SDK" | "VOICEA_CLIENT" | "CISCO_SIP_GW" | "WEBEX_SDK" | "CPAAS_THIRD_PARTY_SDK" | "WXC_THIRD_PARTY" | "WXCC";
75
+ subClientType?: "TEAMS_DEVICE" | "DESKTOP_APP" | "DESKTOP_APP_VDI" | "DEVICE_CURRENT" | "DEVICE_LEGACY_2020" | "HOLOGRAM_HEADSET_APP" | "HVDI_APP" | "MOBILE_APP" | "MOBILE_NETWORK" | "VDI_APP" | "WEB_APP";
76
+ clientVersion?: string;
77
+ localClientVersion?: string;
78
+ modelNumber?: string;
79
+ joinFirstUpdateLater?: "ep-enabled" | "sp-enabled" | "not-enabled";
80
+ standbyUsed?: boolean;
81
+ prefetchDocShowUsed?: boolean;
82
+ fastJoinUsed?: boolean;
83
+ clientDownloadSize?: number;
84
+ clientDownloadFileCount?: number;
85
+ nodeId?: number;
86
+ machineInfo?: string;
87
+ parentAppName?: string;
88
+ parentAppInPermitList?: boolean;
89
+ meetingSiteType?: "train" | "webex-11" | "orion";
90
+ CDNEnabled?: boolean;
91
+ clientMajorVersion?: string;
92
+ majorVersion?: number;
93
+ minorVersion?: number;
94
+ revision?: number;
95
+ isValidClientVersion?: boolean;
96
+ cpuInfo?: {
97
+ description: string;
98
+ clockSpeedGigaHertz: number;
99
+ numberOfCores: number;
100
+ architecture: "unknown" | "intel32" | "intel64" | "amd32" | "amd64" | "arm32" | "arm64";
101
+ staticPerformance?: string;
102
+ additionalProperties?: false;
103
+ };
104
+ shareType?: "cb-normal-share" | "ce-airplay-share" | "ce-direct-share" | "ce-gui-loopback-share" | "ce-input-source-share" | "ce-input-source-share-hdmi" | "ce-input-source-share-usbc" | "ce-jpg-share" | "ce-miracast-share" | "mcs-normal-share" | "mcs-normal-audio-share" | "mcs-hfps-share" | "mcs-hfps-audio-share";
105
+ videoDisplayMode?: "grid-view" | "active-speaker-view";
106
+ videoLayoutType?: "stack" | "stackWithShare" | "sideBySide" | "sideBySideWithShare" | "grid" | "floatingActive" | "floatingThumbnail" | "floatingGrid" | "overlay" | "focus" | "prominent" | "focusWithShare" | "prominentWithShare" | "equal" | "equalWithShare";
107
+ videoRenderType?: "wme" | "client_d3d" | "client_gdi";
108
+ vdiInfo?: {};
109
+ is64BitsClient?: boolean;
110
+ webexAppVersion?: string;
111
+ launch32BitsReason?: "forcewin32" | "disablewin64" | "platform_win32" | "platform_arm" | "platform_unknown" | "version_below_41.11";
112
+ inMeetingUpdate?: boolean;
113
+ mtaVersion?: string;
114
+ isWarholOpening?: boolean;
115
+ additionalProperties?: false;
116
+ };
117
+ emmVendorId?: string;
118
+ isHybridMedia?: boolean;
119
+ originData?: {};
120
+ additionalProperties?: false;
121
+ };
122
+ /**
123
+ * Gather identifier details for call diagnostic payload.
124
+ * @throws Error if initialization fails.
125
+ * @param options
126
+ */
127
+ getIdentifiers(options: GetIdentifiersOptions): {
128
+ attendeeId?: string;
129
+ breakoutGroupId?: string;
130
+ breakoutMoveId?: string;
131
+ breakoutSessionId?: string;
132
+ confluenceId?: string;
133
+ cpaasIdentifiers?: {
134
+ imiTenantId: string;
135
+ devClientId: string;
136
+ imiServiceId: string;
137
+ imiAppId: string;
138
+ sessionId: string;
139
+ sessionInstanceId: string;
140
+ additionalProperties?: false;
141
+ };
142
+ csdmDeviceUrl?: string;
143
+ destinationBreakoutSessionId?: string;
144
+ destinationLocusSessionId?: string;
145
+ destinationLocusUrl?: string;
146
+ destinationVenueId?: string;
147
+ deviceId?: string;
148
+ globalMeetingId?: string;
149
+ ivrCallId?: string;
150
+ ivrDialogId?: string;
151
+ ivrId?: string;
152
+ callId?: string;
153
+ locusId?: string;
154
+ locusSessionId?: string;
155
+ locusStartTime?: string;
156
+ locusUrl?: string;
157
+ machineId?: string;
158
+ mediaAgentAlias?: string;
159
+ mediaAgentGroupId?: string;
160
+ meetClusterName?: string;
161
+ meetingLookupUrl?: string;
162
+ meetingOrgId?: string;
163
+ msteamsTenantGuid?: string;
164
+ msteamsConferenceId?: string;
165
+ oauth2ClientId?: string;
166
+ orgId?: string;
167
+ provisionalCorrelationId?: string;
168
+ roomId?: string;
169
+ sipCallId?: string;
170
+ sipSessionId?: {
171
+ local?: string;
172
+ remote?: string;
173
+ additionalProperties?: false;
174
+ };
175
+ sipUri?: string;
176
+ subConfId?: string;
177
+ tenantId?: string;
178
+ trackingId?: string;
179
+ userId?: string;
180
+ venueId?: string;
181
+ venueUrl?: string;
182
+ whiteboardUrl?: string;
183
+ webexConferenceId?: number;
184
+ webexClusterName?: string;
185
+ webexConferenceIdStr?: string;
186
+ webexDataCenter?: string;
187
+ webexGuestId?: number;
188
+ webexMeetingId?: number;
189
+ webexNodeId?: number;
190
+ webexSiteId?: number;
191
+ webexSiteName?: string;
192
+ webexUserId?: number;
193
+ webexWebDomain?: string;
194
+ correlationId: string;
195
+ additionalProperties?: false;
196
+ } | {
197
+ attendeeId?: string;
198
+ breakoutGroupId?: string;
199
+ breakoutMoveId?: string;
200
+ breakoutSessionId?: string;
201
+ confluenceId?: string;
202
+ cpaasIdentifiers?: {
203
+ imiTenantId: string;
204
+ devClientId: string;
205
+ imiServiceId: string;
206
+ imiAppId: string;
207
+ sessionId: string;
208
+ sessionInstanceId: string;
209
+ additionalProperties?: false;
210
+ };
211
+ csdmDeviceUrl?: string;
212
+ destinationBreakoutSessionId?: string;
213
+ destinationLocusSessionId?: string;
214
+ destinationLocusUrl?: string;
215
+ destinationVenueId?: string;
216
+ deviceId?: string;
217
+ globalMeetingId?: string;
218
+ ivrCallId?: string;
219
+ ivrDialogId?: string;
220
+ ivrId?: string;
221
+ callId?: string;
222
+ locusId?: string;
223
+ locusSessionId?: string;
224
+ locusStartTime?: string;
225
+ locusUrl?: string;
226
+ machineId?: string;
227
+ mediaAgentAlias?: string;
228
+ mediaAgentGroupId?: string;
229
+ meetClusterName?: string;
230
+ meetingLookupUrl?: string;
231
+ meetingOrgId?: string;
232
+ msteamsTenantGuid?: string;
233
+ msteamsConferenceId?: string;
234
+ oauth2ClientId?: string;
235
+ orgId?: string;
236
+ provisionalCorrelationId?: string;
237
+ roomId?: string;
238
+ sipCallId?: string;
239
+ sipSessionId?: {
240
+ local?: string;
241
+ remote?: string;
242
+ additionalProperties?: false;
243
+ };
244
+ sipUri?: string;
245
+ subConfId?: string;
246
+ tenantId?: string;
247
+ trackingId?: string;
248
+ userId?: string;
249
+ venueId?: string;
250
+ venueUrl?: string;
251
+ whiteboardUrl?: string;
252
+ webexConferenceId?: number;
253
+ webexClusterName?: string;
254
+ webexConferenceIdStr?: string;
255
+ webexDataCenter?: string;
256
+ webexGuestId?: number;
257
+ webexMeetingId?: number;
258
+ webexNodeId?: number;
259
+ webexSiteId?: number;
260
+ webexSiteName?: string;
261
+ webexUserId?: number;
262
+ webexWebDomain?: string;
263
+ correlationId: string;
264
+ additionalProperties?: false;
265
+ };
266
+ /**
267
+ * Create diagnostic event, which can hold client event, feature event or MQE event data.
268
+ * This just initiates the shared properties that are required for all the 3 event categories.
269
+ * @param eventData
270
+ * @param options
271
+ * @returns
272
+ */
273
+ prepareDiagnosticEvent(eventData: Event['event'], options: any): Event;
274
+ /**
275
+ * TODO: NOT IMPLEMENTED
276
+ * Submit Feature Event
277
+ * @returns
278
+ */
279
+ submitFeatureEvent(): void;
280
+ /**
281
+ * Submit Media Quality Event
282
+ * @param args - submit params
283
+ * @param arg.name - event key
284
+ * @param arg.payload - additional payload to be merge with the default payload
285
+ * @param arg.options - options
286
+ */
287
+ submitMQE({ name, payload, options, }: {
288
+ name: MediaQualityEvent['name'];
289
+ payload: SubmitMQEPayload;
290
+ options: SubmitMQEOptions;
291
+ }): void;
292
+ /**
293
+ * Return Client Event payload by client error code
294
+ * @param arg - get error arg
295
+ * @param arg.clientErrorCode
296
+ * @param arg.serviceErrorCode
297
+ * @returns
298
+ */
299
+ getErrorPayloadForClientErrorCode({ clientErrorCode, serviceErrorCode, serviceErrorName, }: {
300
+ clientErrorCode: number;
301
+ serviceErrorCode: any;
302
+ serviceErrorName?: any;
303
+ }): ClientEventError;
304
+ /**
305
+ * Generate error payload for Client Event
306
+ * @param rawError
307
+ */
308
+ generateClientEventErrorPayload(rawError: any): {
309
+ fatal: boolean;
310
+ category: "other" | "signaling" | "media" | "network" | "expected";
311
+ errorDescription?: string;
312
+ errorCode?: number;
313
+ errorCodeStr?: string;
314
+ httpCode?: number;
315
+ errorCodeExt1?: number;
316
+ errorData?: {};
317
+ shownToUser: boolean;
318
+ serviceErrorCode?: number;
319
+ name: "other" | "locus.response" | "media-engine" | "ice.failed" | "locus.leave" | "client.leave" | "media-device" | "media-sca" | "wxc";
320
+ additionalProperties?: false;
321
+ };
322
+ /**
323
+ * Create client event object for in meeting events
324
+ * @param arg - create args
325
+ * @param arg.event - event key
326
+ * @param arg.options - options
327
+ * @returns object
328
+ */
329
+ private createClientEventObjectInMeeting;
330
+ /**
331
+ * Create client event object for pre meeting events
332
+ * @param arg - create args
333
+ * @param arg.event - event key
334
+ * @param arg.options - payload
335
+ * @returns object
336
+ */
337
+ private createClientEventObjectPreMeeting;
338
+ /**
339
+ * Prepare Client Event CA event.
340
+ * @param arg - submit params
341
+ * @param arg.event - event key
342
+ * @param arg.payload - additional payload to be merged with default payload
343
+ * @param arg.options - payload
344
+ * @returns {any} options to be with fetch
345
+ * @throws
346
+ */
347
+ private prepareClientEvent;
348
+ /**
349
+ * Submit Client Event CA event.
350
+ * @param arg - submit params
351
+ * @param arg.event - event key
352
+ * @param arg.payload - additional payload to be merged with default payload
353
+ * @param arg.options - payload
354
+ * @throws
355
+ */
356
+ submitClientEvent({ name, payload, options, }: {
357
+ name: ClientEvent['name'];
358
+ payload?: ClientEventPayload;
359
+ options?: SubmitClientEventOptions;
360
+ }): Promise<any>;
361
+ /**
362
+ * Prepare the event and send the request to metrics-a service.
363
+ * @param event
364
+ * @returns promise
365
+ */
366
+ submitToCallDiagnostics(event: Event): Promise<any>;
367
+ /**
368
+ * Pre login events are not batched. We make the request directly.
369
+ * @param event
370
+ * @param preLoginId
371
+ * @returns
372
+ */
373
+ submitToCallDiagnosticsPreLogin: (event: Event, preLoginId?: string) => Promise<any>;
374
+ /**
375
+ * Builds a request options object to later be passed to fetch().
376
+ * @param arg - submit params
377
+ * @param arg.event - event key
378
+ * @param arg.payload - additional payload to be merged with default payload
379
+ * @param arg.options - client event options
380
+ * @returns {Promise<any>}
381
+ * @throws
382
+ */
383
+ buildClientEventFetchRequestOptions({ name, payload, options, }: {
384
+ name: ClientEvent['name'];
385
+ payload?: ClientEventPayload;
386
+ options?: SubmitClientEventOptions;
387
+ }): Promise<any>;
388
+ /**
389
+ * Returns true if the specified serviceErrorCode maps to an expected error.
390
+ * @param {number} serviceErrorCode the service error code
391
+ * @returns {boolean}
392
+ */
393
+ isServiceErrorExpected(serviceErrorCode: number): boolean;
394
+ }
395
+ export {};
@@ -0,0 +1,96 @@
1
+ import { Event } from '../metrics.types';
2
+ export declare const anonymizeIPAddress: (localIp: any) => string;
3
+ /**
4
+ * Returns a formated string of the user agent.
5
+ *
6
+ * @returns {string} formatted user agent information
7
+ */
8
+ export declare const userAgentToString: ({ clientName, webexVersion }: {
9
+ clientName: any;
10
+ webexVersion: any;
11
+ }) => string;
12
+ /**
13
+ * Iterates object recursively and removes any
14
+ * property that returns isEmpty for it's associated value
15
+ * isEmpty = implementation from Lodash.
16
+ *
17
+ * It modifies the object in place (mutable)
18
+ *
19
+ * @param obj - input
20
+ * @returns
21
+ */
22
+ export declare const clearEmptyKeysRecursively: (obj: any) => void;
23
+ /**
24
+ * Locus error codes start with 2. The next three digits are the
25
+ * HTTP status code related to the error code (like 400, 403, 502, etc.)
26
+ * The remaining three digits are just an increasing integer.
27
+ * If it is 7 digits and starts with a 2, it is locus.
28
+ *
29
+ * @param errorCode
30
+ * @returns {boolean}
31
+ */
32
+ export declare const isLocusServiceErrorCode: (errorCode: string | number) => boolean;
33
+ /**
34
+ * MeetingInfo errors sometimes has body.data.meetingInfo object
35
+ * MeetingInfo errors come with a wbxappapi url
36
+ *
37
+ * @param {Object} rawError
38
+ * @returns {boolean}
39
+ */
40
+ export declare const isMeetingInfoServiceError: (rawError: any) => boolean;
41
+ /**
42
+ * Returns true if the raw error is a network related error
43
+ *
44
+ * @param {Object} rawError
45
+ * @returns {boolean}
46
+ */
47
+ export declare const isNetworkError: (rawError: any) => boolean;
48
+ /**
49
+ * Returns true if the error is an unauthorized error
50
+ *
51
+ * @param {Object} rawError
52
+ * @returns {boolean}
53
+ */
54
+ export declare const isUnauthorizedError: (rawError: any) => boolean;
55
+ /**
56
+ * MDN Media Devices getUserMedia() method returns a name if it errs
57
+ * Documentation can be found here: https://developer.mozilla.org/en-US/docs/Web/API/MediaDevices/getUserMedia
58
+ *
59
+ * @param errorCode
60
+ * @returns
61
+ */
62
+ export declare const isBrowserMediaErrorName: (errorName: any) => boolean;
63
+ /**
64
+ * @param webClientDomain
65
+ * @returns
66
+ */
67
+ export declare const getBuildType: (webClientDomain: any, markAsTestEvent?: boolean) => Event['origin']['buildType'];
68
+ /**
69
+ * Prepare metric item for submission.
70
+ * @param {Object} webex sdk instance
71
+ * @param {Object} item
72
+ * @returns {Object} prepared item
73
+ */
74
+ export declare const prepareDiagnosticMetricItem: (webex: any, item: any) => any;
75
+ /**
76
+ * Sets the originTime value(s) before the request/fetch.
77
+ * This function is only useful if you are about to submit a metrics
78
+ * request using pre-built fetch options;
79
+ *
80
+ * @param {any} options
81
+ * @returns {any} the updated options object
82
+ */
83
+ export declare const setMetricTimings: (options: any) => any;
84
+ export declare const extractVersionMetadata: (version: string) => {
85
+ majorVersion: number;
86
+ minorVersion: number;
87
+ };
88
+ /**
89
+ * Generates client error codes for specific ice failures
90
+ * that happen when trying to add media in a meeting.
91
+ */
92
+ export declare const generateClientErrorCodeForIceFailure: ({ signalingState, iceConnectionState, turnServerUsed, }: {
93
+ signalingState: RTCPeerConnection['signalingState'];
94
+ iceConnectionState: RTCPeerConnection['iceConnectionState'];
95
+ turnServerUsed: boolean;
96
+ }) => number;
@@ -0,0 +1,171 @@
1
+ import { ClientEventError } from '../metrics.types';
2
+ export declare const CALL_DIAGNOSTIC_LOG_IDENTIFIER = "call-diagnostic-events -> ";
3
+ export declare const AUTHENTICATION_FAILED_CODE = 1010;
4
+ export declare const NETWORK_ERROR = 1026;
5
+ export declare const NEW_LOCUS_ERROR_CLIENT_CODE = 4008;
6
+ export declare const MEETING_INFO_LOOKUP_ERROR_CLIENT_CODE = 4100;
7
+ export declare const UNKNOWN_ERROR = 9999;
8
+ export declare const ICE_FAILURE_CLIENT_CODE = 2004;
9
+ export declare const MISSING_ROAP_ANSWER_CLIENT_CODE = 2007;
10
+ export declare const DTLS_HANDSHAKE_FAILED_CLIENT_CODE = 2008;
11
+ export declare const ICE_FAILED_WITH_TURN_TLS_CLIENT_CODE = 2010;
12
+ export declare const ICE_FAILED_WITHOUT_TURN_TLS_CLIENT_CODE = 2009;
13
+ export declare const WBX_APP_API_URL = "wbxappapi";
14
+ export declare const BROWSER_MEDIA_ERROR_NAME_TO_CLIENT_ERROR_CODES_MAP: {
15
+ [x: string]: number;
16
+ };
17
+ export declare const ERROR_DESCRIPTIONS: {
18
+ UNKNOWN_CALL_FAILURE: string;
19
+ LOCUS_RATE_LIMITED_INCOMING: string;
20
+ LOCUS_RATE_LIMITED_OUTGOING: string;
21
+ LOCUS_UNAVAILABLE: string;
22
+ LOCUS_CONFLICT: string;
23
+ TIMEOUT: string;
24
+ LOCUS_INVALID_SEQUENCE_HASH: string;
25
+ AUTHENTICATION_FAILED: string;
26
+ NETWORK_ERROR: string;
27
+ UPDATE_MEDIA_FAILED: string;
28
+ FAILED_TO_CONNECT_MEDIA: string;
29
+ MEDIA_ENGINE_LOST: string;
30
+ MEDIA_CONNECTION_LOST: string;
31
+ ICE_FAILURE: string;
32
+ MEDIA_ENGINE_HANG: string;
33
+ ICE_SERVER_REJECTED: string;
34
+ CALL_FULL: string;
35
+ ROOM_TOO_LARGE: string;
36
+ GUEST_ALREADY_ADDED: string;
37
+ LOCUS_USER_NOT_AUTHORISED: string;
38
+ CLOUDBERRY_UNAVAILABLE: string;
39
+ ROOM_TOO_LARGE_FREE_ACCOUNT: string;
40
+ MEETING_INACTIVE: string;
41
+ MEETING_LOCKED: string;
42
+ MEETING_TERMINATING: string;
43
+ MODERATOR_PIN_OR_GUEST_REQUIRED: string;
44
+ MODERATOR_PIN_OR_GUEST_PIN_REQUIRED: string;
45
+ MODERATOR_REQUIRED: string;
46
+ USER_NOT_MEMBER_OF_ROOM: string;
47
+ NEW_LOCUS_ERROR: string;
48
+ NETWORK_UNAVAILABLE: string;
49
+ MEETING_UNAVAILABLE: string;
50
+ MEETING_ID_INVALID: string;
51
+ MEETING_SITE_INVALID: string;
52
+ LOCUS_INVALID_JOINTIME: string;
53
+ LOBBY_EXPIRED: string;
54
+ MEDIA_CONNECTION_LOST_PAIRED: string;
55
+ PHONE_NUMBER_NOT_A_NUMBER: string;
56
+ PHONE_NUMBER_TOO_LONG: string;
57
+ INVALID_DIALABLE_KEY: string;
58
+ ONE_ON_ONE_TO_SELF_NOT_ALLOWED: string;
59
+ REMOVED_PARTICIPANT: string;
60
+ MEETING_LINK_NOT_FOUND: string;
61
+ PHONE_NUMBER_TOO_SHORT_AFTER_IDD: string;
62
+ INVALID_INVITEE_ADDRESS: string;
63
+ PMR_USER_ACCOUNT_LOCKED_OUT: string;
64
+ GUEST_FORBIDDEN: string;
65
+ PMR_ACCOUNT_SUSPENDED: string;
66
+ EMPTY_PHONE_NUMBER_OR_COUNTRY_CODE: string;
67
+ CONVERSATION_NOT_FOUND: string;
68
+ SIP_CALLEE_BUSY: string;
69
+ SIP_CALLEE_NOT_FOUND: string;
70
+ START_RECORDING_FAILED: string;
71
+ RECORDING_IN_PROGRESS_FAILED: string;
72
+ MEETING_INFO_LOOKUP_ERROR: string;
73
+ CALL_FULL_ADD_GUEST: string;
74
+ REQUIRE_WEBEX_LOGIN: string;
75
+ USER_NOT_ALLOWED_ACCESS_MEETING: string;
76
+ USER_NEEDS_ACTIVATION: string;
77
+ SIGN_UP_INVALID_EMAIL: string;
78
+ UNKNOWN_ERROR: string;
79
+ NO_MEDIA_FOUND: string;
80
+ STREAM_ERROR_NO_MEDIA: string;
81
+ CAMERA_PERMISSION_DENIED: string;
82
+ FRAUD_DETECTION: string;
83
+ E2EE_NOT_SUPPORTED: string;
84
+ LOCUS_LOBBY_FULL_CMR: string;
85
+ USER_NOT_INVITED_TO_JOIN: string;
86
+ MISSING_ROAP_ANSWER: string;
87
+ DTLS_HANDSHAKE_FAILED: string;
88
+ ICE_FAILED_WITHOUT_TURN_TLS: string;
89
+ ICE_FAILED_WITH_TURN_TLS: string;
90
+ };
91
+ export declare const SERVICE_ERROR_CODES_TO_CLIENT_ERROR_CODES_MAP: {
92
+ 58400: number;
93
+ 99002: number;
94
+ 99009: number;
95
+ 58500: number;
96
+ 400001: number;
97
+ 403004: number;
98
+ 403028: number;
99
+ 403032: number;
100
+ 403034: number;
101
+ 403036: number;
102
+ 403038: number;
103
+ 403040: number;
104
+ 403041: number;
105
+ 403047: number;
106
+ 403408: number;
107
+ 403043: number;
108
+ 403048: number;
109
+ 403049: number;
110
+ 403100: number;
111
+ 403101: number;
112
+ 403102: number;
113
+ 403103: number;
114
+ 403104: number;
115
+ 404001: number;
116
+ 404006: number;
117
+ 423001: number;
118
+ 423005: number;
119
+ 423006: number;
120
+ 423010: number;
121
+ 423012: number;
122
+ 423013: number;
123
+ 429005: number;
124
+ 2403001: number;
125
+ 2403002: number;
126
+ 2403003: number;
127
+ 2403004: number;
128
+ 2403018: number;
129
+ 2403019: number;
130
+ 2423003: number;
131
+ 2423004: number;
132
+ 2423005: number;
133
+ 2423006: number;
134
+ 2423016: number;
135
+ 2423017: number;
136
+ 2423018: number;
137
+ 2423012: number;
138
+ 2423021: number;
139
+ 2423007: number;
140
+ 2403010: number;
141
+ 2403014: number;
142
+ 2403015: number;
143
+ 2423010: number;
144
+ 2400008: number;
145
+ 2400011: number;
146
+ 2400012: number;
147
+ 2403007: number;
148
+ 2401002: number;
149
+ 2404002: number;
150
+ 2400009: number;
151
+ 2400025: number;
152
+ 2423009: number;
153
+ 2403022: number;
154
+ 2423008: number;
155
+ 2400006: number;
156
+ 2400014: number;
157
+ 2404001: number;
158
+ 2403025: number;
159
+ 2405001: number;
160
+ 2409005: number;
161
+ 2409062: number;
162
+ 2423025: number;
163
+ 100002: number;
164
+ 100007: number;
165
+ 100001: number;
166
+ 100006: number;
167
+ 100005: number;
168
+ 100004: number;
169
+ };
170
+ export declare const CLIENT_ERROR_CODE_TO_ERROR_PAYLOAD: Record<number, Partial<ClientEventError>>;
171
+ export declare const CALL_DIAGNOSTIC_EVENT_FAILED_TO_SEND = "js_sdk_call_diagnostic_event_failed_to_send";
@@ -0,0 +1,2 @@
1
+ export default ClientMetricsBatcher;
2
+ declare const ClientMetricsBatcher: any;
@@ -0,0 +1,35 @@
1
+ export const CLIENT_NAME: "webex-js-sdk";
2
+ declare namespace _default {
3
+ export namespace device {
4
+ namespace preDiscoveryServices {
5
+ const metricsServiceUrl: string;
6
+ const metrics: string;
7
+ }
8
+ }
9
+ export namespace metrics_1 {
10
+ const appType: string;
11
+ const batcherWait: number;
12
+ const batcherMaxCalls: number;
13
+ const batcherMaxWait: number;
14
+ const batcherRetryPlateau: number;
15
+ }
16
+ export { metrics_1 as metrics };
17
+ }
18
+ export default _default;
19
+ export namespace OS_NAME {
20
+ const WINDOWS: string;
21
+ const MAC: string;
22
+ const IOS: string;
23
+ const ANDROID: string;
24
+ const CHROME: string;
25
+ const LINUX: string;
26
+ const OTHERS: string;
27
+ }
28
+ export const OSMap: {
29
+ 'Chrome OS': string;
30
+ macOS: string;
31
+ Windows: string;
32
+ iOS: string;
33
+ Android: string;
34
+ Linux: string;
35
+ };