@webex/calling 3.11.0-next.7 → 3.11.0-next.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/CallingClient/CallingClient.js +115 -18
- package/dist/CallingClient/CallingClient.js.map +1 -1
- package/dist/CallingClient/CallingClient.test.js +121 -6
- package/dist/CallingClient/CallingClient.test.js.map +1 -1
- package/dist/CallingClient/constants.js +4 -2
- package/dist/CallingClient/constants.js.map +1 -1
- package/dist/CallingClient/registration/register.js +16 -0
- package/dist/CallingClient/registration/register.js.map +1 -1
- package/dist/CallingClient/registration/types.js.map +1 -1
- package/dist/CallingClient/types.js.map +1 -1
- package/dist/common/types.js.map +1 -1
- package/dist/module/CallHistory/CallHistory.js +8 -8
- package/dist/module/CallHistory/callHistoryFixtures.js +1 -1
- package/dist/module/CallSettings/CallSettings.js +8 -8
- package/dist/module/CallSettings/UcmBackendConnector.js +6 -6
- package/dist/module/CallSettings/WxCallBackendConnector.js +6 -6
- package/dist/module/CallingClient/CallingClient.js +56 -14
- package/dist/module/CallingClient/callRecordFixtures.js +1 -1
- package/dist/module/CallingClient/calling/CallerId/index.js +4 -4
- package/dist/module/CallingClient/calling/call.js +14 -14
- package/dist/module/CallingClient/calling/callManager.js +9 -9
- package/dist/module/CallingClient/calling/index.js +2 -2
- package/dist/module/CallingClient/callingClientFixtures.js +3 -3
- package/dist/module/CallingClient/constants.js +2 -0
- package/dist/module/CallingClient/line/index.js +13 -13
- package/dist/module/CallingClient/registration/index.js +1 -1
- package/dist/module/CallingClient/registration/register.js +19 -11
- package/dist/module/CallingClient/registration/webWorker.js +1 -1
- package/dist/module/Contacts/ContactsClient.js +7 -7
- package/dist/module/Errors/catalog/CallError.js +1 -1
- package/dist/module/Errors/catalog/CallingDeviceError.js +2 -2
- package/dist/module/Errors/catalog/ExtendedError.js +1 -1
- package/dist/module/Errors/catalog/LineError.js +2 -2
- package/dist/module/Errors/index.js +3 -3
- package/dist/module/Events/impl/index.js +2 -2
- package/dist/module/Events/types.js +1 -1
- package/dist/module/Logger/index.js +2 -2
- package/dist/module/Metrics/index.js +4 -4
- package/dist/module/SDKConnector/index.js +1 -1
- package/dist/module/Voicemail/BroadworksBackendConnector.js +7 -7
- package/dist/module/Voicemail/UcmBackendConnector.js +6 -6
- package/dist/module/Voicemail/Voicemail.js +12 -12
- package/dist/module/Voicemail/WxCallBackendConnector.js +6 -6
- package/dist/module/Voicemail/voicemailFixture.js +1 -1
- package/dist/module/api.js +5 -5
- package/dist/module/common/Utils.js +11 -11
- package/dist/module/common/index.js +1 -1
- package/dist/module/common/types.js +1 -1
- package/dist/module/index.js +15 -15
- package/dist/types/CallingClient/CallingClient.d.ts +2 -1
- package/dist/types/CallingClient/CallingClient.d.ts.map +1 -1
- package/dist/types/CallingClient/constants.d.ts +2 -0
- package/dist/types/CallingClient/constants.d.ts.map +1 -1
- package/dist/types/CallingClient/registration/register.d.ts +2 -1
- package/dist/types/CallingClient/registration/register.d.ts.map +1 -1
- package/dist/types/CallingClient/registration/types.d.ts +2 -1
- package/dist/types/CallingClient/registration/types.d.ts.map +1 -1
- package/dist/types/CallingClient/types.d.ts +2 -1
- package/dist/types/CallingClient/types.d.ts.map +1 -1
- package/dist/types/SDKConnector/types.d.ts +1 -1
- package/dist/types/common/types.d.ts +4 -0
- package/dist/types/common/types.d.ts.map +1 -1
- package/package.json +3 -4
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import SDKConnector from '../SDKConnector
|
|
2
|
-
import log from '../Logger
|
|
3
|
-
import { HTTP_METHODS, DecodeType, CALLING_BACKEND } from '../common/types
|
|
4
|
-
import { SERVICES_ENDPOINT, STATUS_CODE, SUCCESS_MESSAGE, XML_TYPE, WEBEX_CALLING_CONNECTOR_FILE, METHOD_START_MESSAGE, } from '../common/constants
|
|
5
|
-
import { CALL_WAITING_ENDPOINT, CF_ENDPOINT, DND_ENDPOINT, METHODS, ORG_ENDPOINT, PEOPLE_ENDPOINT, USER_ENDPOINT, VM_ENDPOINT, XSI_VERSION, } from './constants
|
|
6
|
-
import { getXsiActionEndpoint, inferIdFromUuid, serviceErrorCodeHandler, uploadLogs, } from '../common/Utils
|
|
1
|
+
import SDKConnector from '../SDKConnector';
|
|
2
|
+
import log from '../Logger';
|
|
3
|
+
import { HTTP_METHODS, DecodeType, CALLING_BACKEND } from '../common/types';
|
|
4
|
+
import { SERVICES_ENDPOINT, STATUS_CODE, SUCCESS_MESSAGE, XML_TYPE, WEBEX_CALLING_CONNECTOR_FILE, METHOD_START_MESSAGE, } from '../common/constants';
|
|
5
|
+
import { CALL_WAITING_ENDPOINT, CF_ENDPOINT, DND_ENDPOINT, METHODS, ORG_ENDPOINT, PEOPLE_ENDPOINT, USER_ENDPOINT, VM_ENDPOINT, XSI_VERSION, } from './constants';
|
|
6
|
+
import { getXsiActionEndpoint, inferIdFromUuid, serviceErrorCodeHandler, uploadLogs, } from '../common/Utils';
|
|
7
7
|
export class WxCallBackendConnector {
|
|
8
8
|
sdkConnector;
|
|
9
9
|
webex;
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
import * as Media from '@webex/internal-media-core';
|
|
2
2
|
import { Mutex } from 'async-mutex';
|
|
3
|
-
import { METHOD_START_MESSAGE } from '../common/constants
|
|
4
|
-
import { filterMobiusUris, handleCallingClientErrors, uploadLogs, validateServiceData, } from '../common/Utils
|
|
5
|
-
import { LOGGER } from '../Logger/types
|
|
6
|
-
import SDKConnector from '../SDKConnector
|
|
7
|
-
import { Eventing } from '../Events/impl
|
|
8
|
-
import { MOBIUS_EVENT_KEYS, SessionType, CALLING_CLIENT_EVENT_KEYS, } from '../Events/types
|
|
9
|
-
import { ServiceIndicator, ALLOWED_SERVICES, HTTP_METHODS, RegistrationStatus, } from '../common/types
|
|
10
|
-
import log from '../Logger
|
|
11
|
-
import { getCallManager } from './calling/callManager
|
|
12
|
-
import { CALLING_CLIENT_FILE, CALLS_CLEARED_HANDLER_UTIL, CALLING_USER_AGENT, CISCO_DEVICE_URL, DISCOVERY_URL, GET_MOBIUS_SERVERS_UTIL, SPARK_USER_AGENT, URL_ENDPOINT, API_V1, METHODS, NETWORK_FLAP_TIMEOUT, } from './constants
|
|
13
|
-
import Line from './line
|
|
14
|
-
import { METRIC_EVENT, REG_ACTION, METRIC_TYPE, CONNECTION_ACTION, MOBIUS_SERVER_ACTION, } from '../Metrics/types
|
|
15
|
-
import { getMetricManager } from '../Metrics
|
|
16
|
-
import windowsChromiumIceWarmup from './windowsChromiumIceWarmupUtils
|
|
3
|
+
import { METHOD_START_MESSAGE } from '../common/constants';
|
|
4
|
+
import { filterMobiusUris, handleCallingClientErrors, uploadLogs, validateServiceData, } from '../common/Utils';
|
|
5
|
+
import { LOGGER } from '../Logger/types';
|
|
6
|
+
import SDKConnector from '../SDKConnector';
|
|
7
|
+
import { Eventing } from '../Events/impl';
|
|
8
|
+
import { MOBIUS_EVENT_KEYS, SessionType, CALLING_CLIENT_EVENT_KEYS, } from '../Events/types';
|
|
9
|
+
import { ServiceIndicator, ALLOWED_SERVICES, HTTP_METHODS, RegistrationStatus, } from '../common/types';
|
|
10
|
+
import log from '../Logger';
|
|
11
|
+
import { getCallManager } from './calling/callManager';
|
|
12
|
+
import { CALLING_CLIENT_FILE, CALLS_CLEARED_HANDLER_UTIL, CALLING_USER_AGENT, CISCO_DEVICE_URL, DISCOVERY_URL, GET_MOBIUS_SERVERS_UTIL, SPARK_USER_AGENT, URL_ENDPOINT, API_V1, METHODS, NETWORK_FLAP_TIMEOUT, DEVICES_ENDPOINT_RESOURCE, } from './constants';
|
|
13
|
+
import Line from './line';
|
|
14
|
+
import { METRIC_EVENT, REG_ACTION, METRIC_TYPE, CONNECTION_ACTION, MOBIUS_SERVER_ACTION, } from '../Metrics/types';
|
|
15
|
+
import { getMetricManager } from '../Metrics';
|
|
16
|
+
import windowsChromiumIceWarmup from './windowsChromiumIceWarmupUtils';
|
|
17
17
|
export class CallingClient extends Eventing {
|
|
18
18
|
sdkConnector;
|
|
19
19
|
webex;
|
|
@@ -410,6 +410,48 @@ export class CallingClient extends Eventing {
|
|
|
410
410
|
getLines() {
|
|
411
411
|
return this.lineDict;
|
|
412
412
|
}
|
|
413
|
+
async getDevices(userId) {
|
|
414
|
+
const userid = userId || this.webex.internal.device.userId;
|
|
415
|
+
if (!userid) {
|
|
416
|
+
throw new Error('userId is required to fetch devices');
|
|
417
|
+
}
|
|
418
|
+
log.info(METHOD_START_MESSAGE, { file: CALLING_CLIENT_FILE, method: METHODS.GET_DEVICES });
|
|
419
|
+
const mobiusUrls = [...this.primaryMobiusUris, ...this.backupMobiusUris];
|
|
420
|
+
if (mobiusUrls.length === 0) {
|
|
421
|
+
throw new Error('Mobius URLs are not available');
|
|
422
|
+
}
|
|
423
|
+
let finalError;
|
|
424
|
+
for (const mobiusUrl of mobiusUrls) {
|
|
425
|
+
const normalizedMobiusUrl = mobiusUrl.replace(/\/+$/, '/');
|
|
426
|
+
const uri = `${normalizedMobiusUrl}${DEVICES_ENDPOINT_RESOURCE}?userid=${encodeURIComponent(userid)}`;
|
|
427
|
+
try {
|
|
428
|
+
const response = await this.webex.request({
|
|
429
|
+
uri,
|
|
430
|
+
method: HTTP_METHODS.GET,
|
|
431
|
+
service: ALLOWED_SERVICES.MOBIUS,
|
|
432
|
+
headers: {
|
|
433
|
+
[CISCO_DEVICE_URL]: this.webex.internal.device.url,
|
|
434
|
+
[SPARK_USER_AGENT]: CALLING_USER_AGENT,
|
|
435
|
+
},
|
|
436
|
+
});
|
|
437
|
+
if (response.statusCode !== 200) {
|
|
438
|
+
throw new Error(`API call failed with ${response.statusCode}`);
|
|
439
|
+
}
|
|
440
|
+
const body = response.body;
|
|
441
|
+
Object.values(this.lineDict)[0].registration.setDeviceInfo(body);
|
|
442
|
+
Object.values(this.lineDict)[0].registration.setActiveMobiusUrl(normalizedMobiusUrl);
|
|
443
|
+
return body.devices ?? [];
|
|
444
|
+
}
|
|
445
|
+
catch (error) {
|
|
446
|
+
finalError = error;
|
|
447
|
+
}
|
|
448
|
+
}
|
|
449
|
+
log.error(`Failed to fetch devices for userId ${userId}: ${JSON.stringify(finalError)}`, {
|
|
450
|
+
file: CALLING_CLIENT_FILE,
|
|
451
|
+
method: METHODS.GET_DEVICES,
|
|
452
|
+
});
|
|
453
|
+
throw finalError;
|
|
454
|
+
}
|
|
413
455
|
getActiveCalls() {
|
|
414
456
|
const activeCalls = {};
|
|
415
457
|
const calls = this.callManager.getActiveCalls();
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import log from '../../../Logger/index
|
|
2
|
-
import { CALLER_ID_FILE, VALID_PHONE_REGEX } from '../../constants
|
|
3
|
-
import SDKConnector from '../../../SDKConnector
|
|
4
|
-
import { resolveCallerIdDisplay } from '../../../common
|
|
1
|
+
import log from '../../../Logger/index';
|
|
2
|
+
import { CALLER_ID_FILE, VALID_PHONE_REGEX } from '../../constants';
|
|
3
|
+
import SDKConnector from '../../../SDKConnector';
|
|
4
|
+
import { resolveCallerIdDisplay } from '../../../common';
|
|
5
5
|
export class CallerId {
|
|
6
6
|
webex;
|
|
7
7
|
callerInfo;
|
|
@@ -3,20 +3,20 @@ import { createMachine, interpret } from 'xstate';
|
|
|
3
3
|
import { v4 as uuid } from 'uuid';
|
|
4
4
|
import { EffectEvent } from '@webex/media-helpers';
|
|
5
5
|
import { RtcMetrics } from '@webex/internal-plugin-metrics';
|
|
6
|
-
import { ERROR_LAYER, ERROR_TYPE } from '../../Errors/types
|
|
7
|
-
import { handleCallErrors, modifySdpForIPv4, parseMediaQualityStatistics, serviceErrorCodeHandler, uploadLogs, } from '../../common/Utils
|
|
8
|
-
import { ALLOWED_SERVICES, CallDirection, HTTP_METHODS, } from '../../common/types
|
|
9
|
-
import { createCallError } from '../../Errors/catalog/CallError
|
|
10
|
-
import { CALL_ENDPOINT_RESOURCE, CALL_FILE, CALL_HOLD_SERVICE, CALL_STATUS_RESOURCE, CALL_TRANSFER_SERVICE, CALLING_USER_AGENT, CALLS_ENDPOINT_RESOURCE, CISCO_DEVICE_URL, DEFAULT_LOCAL_CALL_ID, DEFAULT_SESSION_TIMER, DEVICES_ENDPOINT_RESOURCE, HOLD_ENDPOINT, ICE_CANDIDATES_TIMEOUT, INITIAL_SEQ_NUMBER, MAX_CALL_KEEPALIVE_RETRY_COUNT, MEDIA_ENDPOINT_RESOURCE, METHODS, NOISE_REDUCTION_EFFECT, RESUME_ENDPOINT, SPARK_USER_AGENT, SUPPLEMENTARY_SERVICES_TIMEOUT, TRANSFER_ENDPOINT, } from '../constants
|
|
11
|
-
import SDKConnector from '../../SDKConnector
|
|
12
|
-
import { Eventing } from '../../Events/impl
|
|
13
|
-
import { CALL_EVENT_KEYS, MEDIA_CONNECTION_EVENT_KEYS, MOBIUS_MIDCALL_STATE, SUPPLEMENTARY_SERVICES, } from '../../Events/types
|
|
14
|
-
import { DisconnectCause, DisconnectCode, MidCallEventType, MobiusCallState, MUTE_TYPE, RoapScenario, TransferType, } from './types
|
|
15
|
-
import log from '../../Logger
|
|
16
|
-
import { createCallerId } from './CallerId
|
|
17
|
-
import { METRIC_TYPE, METRIC_EVENT, TRANSFER_ACTION } from '../../Metrics/types
|
|
18
|
-
import { getMetricManager } from '../../Metrics
|
|
19
|
-
import { METHOD_START_MESSAGE, SERVICES_ENDPOINT } from '../../common/constants
|
|
6
|
+
import { ERROR_LAYER, ERROR_TYPE } from '../../Errors/types';
|
|
7
|
+
import { handleCallErrors, modifySdpForIPv4, parseMediaQualityStatistics, serviceErrorCodeHandler, uploadLogs, } from '../../common/Utils';
|
|
8
|
+
import { ALLOWED_SERVICES, CallDirection, HTTP_METHODS, } from '../../common/types';
|
|
9
|
+
import { createCallError } from '../../Errors/catalog/CallError';
|
|
10
|
+
import { CALL_ENDPOINT_RESOURCE, CALL_FILE, CALL_HOLD_SERVICE, CALL_STATUS_RESOURCE, CALL_TRANSFER_SERVICE, CALLING_USER_AGENT, CALLS_ENDPOINT_RESOURCE, CISCO_DEVICE_URL, DEFAULT_LOCAL_CALL_ID, DEFAULT_SESSION_TIMER, DEVICES_ENDPOINT_RESOURCE, HOLD_ENDPOINT, ICE_CANDIDATES_TIMEOUT, INITIAL_SEQ_NUMBER, MAX_CALL_KEEPALIVE_RETRY_COUNT, MEDIA_ENDPOINT_RESOURCE, METHODS, NOISE_REDUCTION_EFFECT, RESUME_ENDPOINT, SPARK_USER_AGENT, SUPPLEMENTARY_SERVICES_TIMEOUT, TRANSFER_ENDPOINT, } from '../constants';
|
|
11
|
+
import SDKConnector from '../../SDKConnector';
|
|
12
|
+
import { Eventing } from '../../Events/impl';
|
|
13
|
+
import { CALL_EVENT_KEYS, MEDIA_CONNECTION_EVENT_KEYS, MOBIUS_MIDCALL_STATE, SUPPLEMENTARY_SERVICES, } from '../../Events/types';
|
|
14
|
+
import { DisconnectCause, DisconnectCode, MidCallEventType, MobiusCallState, MUTE_TYPE, RoapScenario, TransferType, } from './types';
|
|
15
|
+
import log from '../../Logger';
|
|
16
|
+
import { createCallerId } from './CallerId';
|
|
17
|
+
import { METRIC_TYPE, METRIC_EVENT, TRANSFER_ACTION } from '../../Metrics/types';
|
|
18
|
+
import { getMetricManager } from '../../Metrics';
|
|
19
|
+
import { METHOD_START_MESSAGE, SERVICES_ENDPOINT } from '../../common/constants';
|
|
20
20
|
export class Call extends Eventing {
|
|
21
21
|
sdkConnector;
|
|
22
22
|
webex;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { METHOD_START_MESSAGE } from '../../common/constants
|
|
2
|
-
import { CALL_MANAGER_FILE, METHODS } from '../constants
|
|
3
|
-
import { CALLING_CLIENT_EVENT_KEYS, LINE_EVENT_KEYS } from '../../Events/types
|
|
4
|
-
import { Eventing } from '../../Events/impl
|
|
5
|
-
import SDKConnector from '../../SDKConnector
|
|
6
|
-
import { CallDirection } from '../../common/types
|
|
7
|
-
import { MediaState, MobiusEventType, } from './types
|
|
8
|
-
import { createCall } from './call
|
|
9
|
-
import log from '../../Logger
|
|
1
|
+
import { METHOD_START_MESSAGE } from '../../common/constants';
|
|
2
|
+
import { CALL_MANAGER_FILE, METHODS } from '../constants';
|
|
3
|
+
import { CALLING_CLIENT_EVENT_KEYS, LINE_EVENT_KEYS } from '../../Events/types';
|
|
4
|
+
import { Eventing } from '../../Events/impl';
|
|
5
|
+
import SDKConnector from '../../SDKConnector';
|
|
6
|
+
import { CallDirection } from '../../common/types';
|
|
7
|
+
import { MediaState, MobiusEventType, } from './types';
|
|
8
|
+
import { createCall } from './call';
|
|
9
|
+
import log from '../../Logger';
|
|
10
10
|
let callManager;
|
|
11
11
|
export class CallManager extends Eventing {
|
|
12
12
|
sdkConnector;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export * from './call
|
|
2
|
-
export * from './callManager
|
|
1
|
+
export * from './call';
|
|
2
|
+
export * from './callManager';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { getMobiusDiscoveryResponse, getTestUtilsWebex } from '../common/testUtil
|
|
2
|
-
import { URL_ENDPOINT } from './constants
|
|
3
|
-
import { mockPostResponse } from './registration/registerFixtures
|
|
1
|
+
import { getMobiusDiscoveryResponse, getTestUtilsWebex } from '../common/testUtil';
|
|
2
|
+
import { URL_ENDPOINT } from './constants';
|
|
3
|
+
import { mockPostResponse } from './registration/registerFixtures';
|
|
4
4
|
const webex = getTestUtilsWebex();
|
|
5
5
|
const mockIPReturnBody = {
|
|
6
6
|
ipv4: '1.1.1.1',
|
|
@@ -125,6 +125,7 @@ export const MOBIUS_EU_PROD = 'mobius-eu-central-1.prod.infra.webex.com';
|
|
|
125
125
|
export const MOBIUS_US_INT = 'mobius-us-east-1.int.infra.webex.com';
|
|
126
126
|
export const MOBIUS_EU_INT = 'mobius-eu-central-1.int.infra.webex.com';
|
|
127
127
|
export const FAILOVER_CACHE_PREFIX = 'wxc-failover-state';
|
|
128
|
+
export const ACTIVE_MOBIUS_STORAGE_KEY = 'wxc-active-mobius';
|
|
128
129
|
export const ICE_CANDIDATES_TIMEOUT = 3000;
|
|
129
130
|
export const METHODS = {
|
|
130
131
|
CONSTRUCTOR: 'constructor',
|
|
@@ -225,6 +226,7 @@ export const METHODS = {
|
|
|
225
226
|
REGISTER_SESSIONS_LISTENER: 'registerSessionsListener',
|
|
226
227
|
CREATE_LINE: 'createLine',
|
|
227
228
|
GET_LINES: 'getLines',
|
|
229
|
+
GET_DEVICES: 'getDevices',
|
|
228
230
|
UPLOAD_LOGS: 'uploadLogs',
|
|
229
231
|
GET_SDK_CONNECTOR: 'getSDKConnector',
|
|
230
232
|
GET_CONNECTED_CALL: 'getConnectedCall',
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import { v4 as uuid } from 'uuid';
|
|
2
|
-
import { METHOD_START_MESSAGE } from '../../common/constants
|
|
3
|
-
import { CallDirection, RegistrationStatus, ServiceIndicator, } from '../../common/types
|
|
4
|
-
import { LINE_EVENTS } from './types
|
|
5
|
-
import { LINE_FILE, METHODS, VALID_PHONE_REGEX } from '../constants
|
|
6
|
-
import log from '../../Logger
|
|
7
|
-
import { createRegistration } from '../registration
|
|
8
|
-
import { Eventing } from '../../Events/impl
|
|
9
|
-
import { LineError } from '../../Errors/catalog/LineError
|
|
10
|
-
import { validateServiceData } from '../../common
|
|
11
|
-
import SDKConnector from '../../SDKConnector
|
|
12
|
-
import { LINE_EVENT_KEYS } from '../../Events/types
|
|
13
|
-
import { getCallManager } from '../calling/callManager
|
|
14
|
-
import { ERROR_TYPE } from '../../Errors/types
|
|
2
|
+
import { METHOD_START_MESSAGE } from '../../common/constants';
|
|
3
|
+
import { CallDirection, RegistrationStatus, ServiceIndicator, } from '../../common/types';
|
|
4
|
+
import { LINE_EVENTS } from './types';
|
|
5
|
+
import { LINE_FILE, METHODS, VALID_PHONE_REGEX } from '../constants';
|
|
6
|
+
import log from '../../Logger';
|
|
7
|
+
import { createRegistration } from '../registration';
|
|
8
|
+
import { Eventing } from '../../Events/impl';
|
|
9
|
+
import { LineError } from '../../Errors/catalog/LineError';
|
|
10
|
+
import { validateServiceData } from '../../common';
|
|
11
|
+
import SDKConnector from '../../SDKConnector';
|
|
12
|
+
import { LINE_EVENT_KEYS } from '../../Events/types';
|
|
13
|
+
import { getCallManager } from '../calling/callManager';
|
|
14
|
+
import { ERROR_TYPE } from '../../Errors/types';
|
|
15
15
|
export default class Line extends Eventing {
|
|
16
16
|
#webex;
|
|
17
17
|
#mutex;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export * from './register
|
|
1
|
+
export * from './register';
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import { v4 as uuid } from 'uuid';
|
|
2
|
-
import { METHOD_START_MESSAGE } from '../../common/constants
|
|
3
|
-
import { emitFinalFailure, handleRegistrationErrors, uploadLogs } from '../../common
|
|
4
|
-
import webWorkerStr from './webWorkerStr
|
|
5
|
-
import { METRIC_EVENT, METRIC_TYPE, REG_ACTION, } from '../../Metrics/types
|
|
6
|
-
import { getMetricManager } from '../../Metrics
|
|
7
|
-
import { getCallManager } from '../calling
|
|
8
|
-
import log from '../../Logger
|
|
9
|
-
import SDKConnector from '../../SDKConnector
|
|
10
|
-
import { ALLOWED_SERVICES, HTTP_METHODS, RegistrationStatus, ServiceIndicator, WorkerMessageType, } from '../../common/types
|
|
11
|
-
import { CALLING_USER_AGENT, CISCO_DEVICE_URL, DEVICES_ENDPOINT_RESOURCE, SPARK_USER_AGENT, WEBEX_WEB_CLIENT, BASE_REG_RETRY_TIMER_VAL_IN_SEC, BASE_REG_TIMER_MFACTOR, SEC_TO_MSEC_MFACTOR, REG_RANDOM_T_FACTOR_UPPER_LIMIT, REG_TRY_BACKUP_TIMER_VAL_IN_SEC, MINUTES_TO_SEC_MFACTOR, REG_429_RETRY_UTIL, REG_FAILBACK_429_MAX_RETRIES, FAILBACK_UTIL, REGISTRATION_FILE, DEFAULT_REHOMING_INTERVAL_MIN, DEFAULT_REHOMING_INTERVAL_MAX, DEFAULT_KEEPALIVE_INTERVAL, FAILOVER_UTIL, REGISTER_UTIL, RETRY_TIMER_UPPER_LIMIT, KEEPALIVE_UTIL, REGISTRATION_UTIL, METHODS, URL_ENDPOINT, RECONNECT_ON_FAILURE_UTIL, FAILOVER_CACHE_PREFIX, } from '../constants
|
|
12
|
-
import { LINE_EVENTS } from '../line/types
|
|
2
|
+
import { METHOD_START_MESSAGE } from '../../common/constants';
|
|
3
|
+
import { emitFinalFailure, handleRegistrationErrors, uploadLogs } from '../../common';
|
|
4
|
+
import webWorkerStr from './webWorkerStr';
|
|
5
|
+
import { METRIC_EVENT, METRIC_TYPE, REG_ACTION, } from '../../Metrics/types';
|
|
6
|
+
import { getMetricManager } from '../../Metrics';
|
|
7
|
+
import { getCallManager } from '../calling';
|
|
8
|
+
import log from '../../Logger';
|
|
9
|
+
import SDKConnector from '../../SDKConnector';
|
|
10
|
+
import { ALLOWED_SERVICES, HTTP_METHODS, RegistrationStatus, ServiceIndicator, WorkerMessageType, } from '../../common/types';
|
|
11
|
+
import { CALLING_USER_AGENT, CISCO_DEVICE_URL, DEVICES_ENDPOINT_RESOURCE, SPARK_USER_AGENT, WEBEX_WEB_CLIENT, BASE_REG_RETRY_TIMER_VAL_IN_SEC, BASE_REG_TIMER_MFACTOR, SEC_TO_MSEC_MFACTOR, REG_RANDOM_T_FACTOR_UPPER_LIMIT, REG_TRY_BACKUP_TIMER_VAL_IN_SEC, MINUTES_TO_SEC_MFACTOR, REG_429_RETRY_UTIL, REG_FAILBACK_429_MAX_RETRIES, FAILBACK_UTIL, REGISTRATION_FILE, DEFAULT_REHOMING_INTERVAL_MIN, DEFAULT_REHOMING_INTERVAL_MAX, DEFAULT_KEEPALIVE_INTERVAL, FAILOVER_UTIL, REGISTER_UTIL, RETRY_TIMER_UPPER_LIMIT, KEEPALIVE_UTIL, REGISTRATION_UTIL, METHODS, URL_ENDPOINT, RECONNECT_ON_FAILURE_UTIL, FAILOVER_CACHE_PREFIX, } from '../constants';
|
|
12
|
+
import { LINE_EVENTS } from '../line/types';
|
|
13
13
|
export class Registration {
|
|
14
14
|
sdkConnector;
|
|
15
15
|
webex;
|
|
@@ -116,6 +116,14 @@ export class Registration {
|
|
|
116
116
|
this.activeMobiusUrl = url;
|
|
117
117
|
this.callManager.updateActiveMobius(url);
|
|
118
118
|
}
|
|
119
|
+
setDeviceInfo(devicesInfo) {
|
|
120
|
+
const [device] = devicesInfo.devices;
|
|
121
|
+
this.deviceInfo = {
|
|
122
|
+
userId: devicesInfo.userId,
|
|
123
|
+
device,
|
|
124
|
+
devices: devicesInfo.devices,
|
|
125
|
+
};
|
|
126
|
+
}
|
|
119
127
|
setMobiusServers(primaryMobiusUris, backupMobiusUris) {
|
|
120
128
|
log.log(METHOD_START_MESSAGE, { method: METHODS.SET_MOBIUS_SERVERS, file: REGISTRATION_FILE });
|
|
121
129
|
this.primaryMobiusUris = primaryMobiusUris;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { v4 as uuid } from 'uuid';
|
|
2
|
-
import { HTTP_METHODS, WorkerMessageType } from '../../common/types
|
|
2
|
+
import { HTTP_METHODS, WorkerMessageType } from '../../common/types';
|
|
3
3
|
let keepaliveTimer;
|
|
4
4
|
const messageHandler = (event) => {
|
|
5
5
|
const { type } = event.data;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { FAILURE_MESSAGE, METHOD_START_MESSAGE, SCIM_ENTERPRISE_USER, SCIM_WEBEXIDENTITY_USER, STATUS_CODE, SUCCESS_MESSAGE, } from '../common/constants
|
|
2
|
-
import { HTTP_METHODS } from '../common/types
|
|
3
|
-
import SDKConnector from '../SDKConnector
|
|
4
|
-
import log from '../Logger
|
|
5
|
-
import { CONTACTS_CLIENT, CONTACTS_SCHEMA, CONTACT_FILTER, DEFAULT_GROUP_NAME, ENCRYPT_FILTER, GROUP_FILTER, METHODS, OR, SCIM_ID_FILTER, USERS, encryptedFields, } from './constants
|
|
6
|
-
import { ContactType, GroupType, } from './types
|
|
7
|
-
import { scimQuery, serviceErrorCodeHandler, uploadLogs } from '../common/Utils
|
|
1
|
+
import { FAILURE_MESSAGE, METHOD_START_MESSAGE, SCIM_ENTERPRISE_USER, SCIM_WEBEXIDENTITY_USER, STATUS_CODE, SUCCESS_MESSAGE, } from '../common/constants';
|
|
2
|
+
import { HTTP_METHODS } from '../common/types';
|
|
3
|
+
import SDKConnector from '../SDKConnector';
|
|
4
|
+
import log from '../Logger';
|
|
5
|
+
import { CONTACTS_CLIENT, CONTACTS_SCHEMA, CONTACT_FILTER, DEFAULT_GROUP_NAME, ENCRYPT_FILTER, GROUP_FILTER, METHODS, OR, SCIM_ID_FILTER, USERS, encryptedFields, } from './constants';
|
|
6
|
+
import { ContactType, GroupType, } from './types';
|
|
7
|
+
import { scimQuery, serviceErrorCodeHandler, uploadLogs } from '../common/Utils';
|
|
8
8
|
export class ContactsClient {
|
|
9
9
|
sdkConnector;
|
|
10
10
|
encryptionKeyUrl;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { RegistrationStatus } from '../../common/types
|
|
2
|
-
import ExtendedError from './ExtendedError
|
|
1
|
+
import { RegistrationStatus } from '../../common/types';
|
|
2
|
+
import ExtendedError from './ExtendedError';
|
|
3
3
|
export class CallingClientError extends ExtendedError {
|
|
4
4
|
status = RegistrationStatus.INACTIVE;
|
|
5
5
|
constructor(msg, context, type, status) {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { RegistrationStatus } from '../../common/types
|
|
2
|
-
import ExtendedError from './ExtendedError
|
|
1
|
+
import { RegistrationStatus } from '../../common/types';
|
|
2
|
+
import ExtendedError from './ExtendedError';
|
|
3
3
|
export class LineError extends ExtendedError {
|
|
4
4
|
status = RegistrationStatus.INACTIVE;
|
|
5
5
|
constructor(msg, context, type, status) {
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export { CallingClientError } from './catalog/CallingDeviceError
|
|
2
|
-
export { CallError } from './catalog/CallError
|
|
3
|
-
export { LineError } from './catalog/LineError
|
|
1
|
+
export { CallingClientError } from './catalog/CallingDeviceError';
|
|
2
|
+
export { CallError } from './catalog/CallError';
|
|
3
|
+
export { LineError } from './catalog/LineError';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import EventEmitter from 'events';
|
|
2
|
-
import Logger from '../../Logger
|
|
3
|
-
import { LOG_PREFIX } from '../../Logger/types
|
|
2
|
+
import Logger from '../../Logger';
|
|
3
|
+
import { LOG_PREFIX } from '../../Logger/types';
|
|
4
4
|
export class Eventing extends EventEmitter {
|
|
5
5
|
emit(event, ...args) {
|
|
6
6
|
const timestamp = new Date().toUTCString();
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { LINE_EVENTS } from '../CallingClient/line/types
|
|
1
|
+
import { LINE_EVENTS } from '../CallingClient/line/types';
|
|
2
2
|
export var COMMON_EVENT_KEYS;
|
|
3
3
|
(function (COMMON_EVENT_KEYS) {
|
|
4
4
|
COMMON_EVENT_KEYS["CB_VOICEMESSAGE_CONTENT_GET"] = "call_back_voicemail_content_get";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { REPO_NAME } from '../CallingClient/constants
|
|
2
|
-
import { LOGGING_LEVEL, LOGGER, LOG_PREFIX } from './types
|
|
1
|
+
import { REPO_NAME } from '../CallingClient/constants';
|
|
2
|
+
import { LOGGING_LEVEL, LOGGER, LOG_PREFIX } from './types';
|
|
3
3
|
let currentLogLevel = LOGGING_LEVEL.error;
|
|
4
4
|
let webexLogger = console;
|
|
5
5
|
const writeToLogger = (message, level) => {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { METRIC_FILE, VERSION } from '../CallingClient/constants
|
|
2
|
-
import { ServiceIndicator } from '../common/types
|
|
3
|
-
import { METRIC_EVENT, } from './types
|
|
4
|
-
import log from '../Logger
|
|
1
|
+
import { METRIC_FILE, VERSION } from '../CallingClient/constants';
|
|
2
|
+
import { ServiceIndicator } from '../common/types';
|
|
3
|
+
import { METRIC_EVENT, } from './types';
|
|
4
|
+
import log from '../Logger';
|
|
5
5
|
let metricManager;
|
|
6
6
|
class MetricManager {
|
|
7
7
|
webex;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { ERROR_CODE } from '../Errors/types
|
|
2
|
-
import SDKConnector from '../SDKConnector
|
|
3
|
-
import { BASE64, BEARER, BINARY, SUCCESS_MESSAGE, SUCCESS_STATUS_CODE, OBJECT, TOKEN, USER, XML_TYPE, BW_XSI_ENDPOINT_VERSION, METHOD_START_MESSAGE, } from '../common/constants
|
|
4
|
-
import { serviceErrorCodeHandler, getXsiActionEndpoint, getSortedVoicemailList, storeVoicemailList, fetchVoicemailList, uploadLogs, } from '../common/Utils
|
|
5
|
-
import { CALLING_BACKEND, HTTP_METHODS, SORT, } from '../common/types
|
|
6
|
-
import log from '../Logger
|
|
7
|
-
import { BROADWORKS_VOICEMAIL_FILE, BW_TOKEN_FETCH_ENDPOINT, JSON_FORMAT, MARK_AS_READ, MARK_AS_UNREAD, MESSAGE_MEDIA_CONTENT, VOICE_MESSAGING_MESSAGES, NO_VOICEMAIL_MSG, NO_VOICEMAIL_STATUS_CODE, RADIX_RAND, PREFIX, METHODS, } from './constants
|
|
1
|
+
import { ERROR_CODE } from '../Errors/types';
|
|
2
|
+
import SDKConnector from '../SDKConnector';
|
|
3
|
+
import { BASE64, BEARER, BINARY, SUCCESS_MESSAGE, SUCCESS_STATUS_CODE, OBJECT, TOKEN, USER, XML_TYPE, BW_XSI_ENDPOINT_VERSION, METHOD_START_MESSAGE, } from '../common/constants';
|
|
4
|
+
import { serviceErrorCodeHandler, getXsiActionEndpoint, getSortedVoicemailList, storeVoicemailList, fetchVoicemailList, uploadLogs, } from '../common/Utils';
|
|
5
|
+
import { CALLING_BACKEND, HTTP_METHODS, SORT, } from '../common/types';
|
|
6
|
+
import log from '../Logger';
|
|
7
|
+
import { BROADWORKS_VOICEMAIL_FILE, BW_TOKEN_FETCH_ENDPOINT, JSON_FORMAT, MARK_AS_READ, MARK_AS_UNREAD, MESSAGE_MEDIA_CONTENT, VOICE_MESSAGING_MESSAGES, NO_VOICEMAIL_MSG, NO_VOICEMAIL_STATUS_CODE, RADIX_RAND, PREFIX, METHODS, } from './constants';
|
|
8
8
|
export class BroadworksBackendConnector {
|
|
9
9
|
bwtoken;
|
|
10
10
|
userId;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import SDKConnector from '../SDKConnector
|
|
2
|
-
import { HTTP_METHODS, CALLING_BACKEND, } from '../common/types
|
|
3
|
-
import { getVgActionEndpoint, serviceErrorCodeHandler, uploadLogs } from '../common/Utils
|
|
4
|
-
import { SUCCESS_MESSAGE, USERS, CONTENT, UCM_CONNECTOR_FILE, FAILURE_MESSAGE, METHOD_START_MESSAGE, } from '../common/constants
|
|
5
|
-
import log from '../Logger
|
|
6
|
-
import { API_V1, LIMIT, METHODS, OFFSET, SORT_ORDER, VMGATEWAY, VOICEMAILS } from './constants
|
|
1
|
+
import SDKConnector from '../SDKConnector';
|
|
2
|
+
import { HTTP_METHODS, CALLING_BACKEND, } from '../common/types';
|
|
3
|
+
import { getVgActionEndpoint, serviceErrorCodeHandler, uploadLogs } from '../common/Utils';
|
|
4
|
+
import { SUCCESS_MESSAGE, USERS, CONTENT, UCM_CONNECTOR_FILE, FAILURE_MESSAGE, METHOD_START_MESSAGE, } from '../common/constants';
|
|
5
|
+
import log from '../Logger';
|
|
6
|
+
import { API_V1, LIMIT, METHODS, OFFSET, SORT_ORDER, VMGATEWAY, VOICEMAILS } from './constants';
|
|
7
7
|
export class UcmBackendConnector {
|
|
8
8
|
vgEndpoint;
|
|
9
9
|
userId;
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { METHOD_START_MESSAGE } from '../common/constants
|
|
2
|
-
import SDKConnector from '../SDKConnector
|
|
3
|
-
import { CALLING_BACKEND } from '../common/types
|
|
4
|
-
import log from '../Logger
|
|
5
|
-
import { getCallingBackEnd, uploadLogs } from '../common/Utils
|
|
6
|
-
import { WxCallBackendConnector } from './WxCallBackendConnector
|
|
7
|
-
import { BroadworksBackendConnector } from './BroadworksBackendConnector
|
|
8
|
-
import { Eventing } from '../Events/impl
|
|
9
|
-
import { UcmBackendConnector } from './UcmBackendConnector
|
|
10
|
-
import { METRIC_EVENT, METRIC_TYPE, VOICEMAIL_ACTION } from '../Metrics/types
|
|
11
|
-
import { getMetricManager } from '../Metrics
|
|
12
|
-
import { VOICEMAIL_FILE, METHODS } from './constants
|
|
1
|
+
import { METHOD_START_MESSAGE } from '../common/constants';
|
|
2
|
+
import SDKConnector from '../SDKConnector';
|
|
3
|
+
import { CALLING_BACKEND } from '../common/types';
|
|
4
|
+
import log from '../Logger';
|
|
5
|
+
import { getCallingBackEnd, uploadLogs } from '../common/Utils';
|
|
6
|
+
import { WxCallBackendConnector } from './WxCallBackendConnector';
|
|
7
|
+
import { BroadworksBackendConnector } from './BroadworksBackendConnector';
|
|
8
|
+
import { Eventing } from '../Events/impl';
|
|
9
|
+
import { UcmBackendConnector } from './UcmBackendConnector';
|
|
10
|
+
import { METRIC_EVENT, METRIC_TYPE, VOICEMAIL_ACTION } from '../Metrics/types';
|
|
11
|
+
import { getMetricManager } from '../Metrics';
|
|
12
|
+
import { VOICEMAIL_FILE, METHODS } from './constants';
|
|
13
13
|
export class Voicemail extends Eventing {
|
|
14
14
|
logger;
|
|
15
15
|
sdkConnector;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import SDKConnector from '../SDKConnector
|
|
2
|
-
import { RAW_REQUEST, SUCCESS_MESSAGE, SUCCESS_STATUS_CODE, TRANSCRIPT, USER, XML_TYPE, BW_XSI_ENDPOINT_VERSION, WEBEX_CALLING_CONNECTOR_FILE, METHOD_START_MESSAGE, } from '../common/constants
|
|
3
|
-
import { serviceErrorCodeHandler, getXsiActionEndpoint, getSortedVoicemailList, resolveContact, storeVoicemailList, fetchVoicemailList, uploadLogs, } from '../common/Utils
|
|
4
|
-
import { CALLING_BACKEND, HTTP_METHODS, SORT, } from '../common/types
|
|
5
|
-
import log from '../Logger
|
|
6
|
-
import { JSON_FORMAT, MARK_AS_READ, MARK_AS_UNREAD, MESSAGE_MEDIA_CONTENT, TRANSCRIPT_CONTENT, VOICE_MESSAGING_MESSAGES, NO_VOICEMAIL_MSG, NO_VOICEMAIL_STATUS_CODE, RADIX_RAND, PREFIX, TRANSCRIPT_STATUS, MESSAGE_SUMMARY, CALLS, SUMMARY, NEW_MESSAGES, NEW_URGENT_MESSAGES, OLD_URGENT_MESSAGES, OLD_MESSAGES, METHODS, } from './constants
|
|
1
|
+
import SDKConnector from '../SDKConnector';
|
|
2
|
+
import { RAW_REQUEST, SUCCESS_MESSAGE, SUCCESS_STATUS_CODE, TRANSCRIPT, USER, XML_TYPE, BW_XSI_ENDPOINT_VERSION, WEBEX_CALLING_CONNECTOR_FILE, METHOD_START_MESSAGE, } from '../common/constants';
|
|
3
|
+
import { serviceErrorCodeHandler, getXsiActionEndpoint, getSortedVoicemailList, resolveContact, storeVoicemailList, fetchVoicemailList, uploadLogs, } from '../common/Utils';
|
|
4
|
+
import { CALLING_BACKEND, HTTP_METHODS, SORT, } from '../common/types';
|
|
5
|
+
import log from '../Logger';
|
|
6
|
+
import { JSON_FORMAT, MARK_AS_READ, MARK_AS_UNREAD, MESSAGE_MEDIA_CONTENT, TRANSCRIPT_CONTENT, VOICE_MESSAGING_MESSAGES, NO_VOICEMAIL_MSG, NO_VOICEMAIL_STATUS_CODE, RADIX_RAND, PREFIX, TRANSCRIPT_STATUS, MESSAGE_SUMMARY, CALLS, SUMMARY, NEW_MESSAGES, NEW_URGENT_MESSAGES, OLD_URGENT_MESSAGES, OLD_MESSAGES, METHODS, } from './constants';
|
|
7
7
|
export class WxCallBackendConnector {
|
|
8
8
|
xsiEndpoint;
|
|
9
9
|
userId;
|
package/dist/module/api.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { CallHistory, createCallHistoryClient } from './CallHistory/CallHistory
|
|
2
|
-
import { CallSettings, createCallSettingsClient } from './CallSettings/CallSettings
|
|
3
|
-
import { CallingClient, createClient } from './CallingClient/CallingClient
|
|
4
|
-
import { ContactsClient, createContactsClient } from './Contacts/ContactsClient
|
|
5
|
-
import { Voicemail, createVoicemailClient } from './Voicemail/Voicemail
|
|
1
|
+
import { CallHistory, createCallHistoryClient } from './CallHistory/CallHistory';
|
|
2
|
+
import { CallSettings, createCallSettingsClient } from './CallSettings/CallSettings';
|
|
3
|
+
import { CallingClient, createClient } from './CallingClient/CallingClient';
|
|
4
|
+
import { ContactsClient, createContactsClient } from './Contacts/ContactsClient';
|
|
5
|
+
import { Voicemail, createVoicemailClient } from './Voicemail/Voicemail';
|
|
6
6
|
export { CallHistory, CallSettings, CallingClient, ContactsClient, Voicemail };
|
|
7
7
|
export { createCallHistoryClient, createCallSettingsClient, createClient, createContactsClient, createVoicemailClient, };
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import * as platform from 'platform';
|
|
2
2
|
import { v4 as uuid } from 'uuid';
|
|
3
|
-
import { METRIC_EVENT, METRIC_TYPE, UPLOAD_LOGS_ACTION } from '../Metrics/types
|
|
4
|
-
import { getMetricManager } from '../Metrics
|
|
5
|
-
import { createCallError } from '../Errors/catalog/CallError
|
|
6
|
-
import { DEVICE_ERROR_CODE, ERROR_CODE, ERROR_TYPE, CALL_ERROR_CODE, } from '../Errors/types
|
|
7
|
-
import { CALLING_BACKEND, HTTP_METHODS, RegistrationStatus, SORT, ServiceIndicator, } from './types
|
|
8
|
-
import log from '../Logger
|
|
9
|
-
import { createClientError } from '../Errors/catalog/CallingDeviceError
|
|
10
|
-
import { BYTES_RECEIVED, BYTES_SENT, CALLING_USER_AGENT, CISCO_DEVICE_URL, CODEC_ID, DUMMY_METRICS, INBOUND_CODEC_MATCH, INBOUND_RTP, JITTER_BUFFER_DELAY, JITTER_BUFFER_EMITTED_COUNT, LOCAL_CANDIDATE_ID, MEDIA_ID, MEDIA_SOURCE, MIME_TYPE, NETWORK_TYPE, OUTBOUND_CODEC_MATCH, OUTBOUND_RTP, PACKETS_DISCARDED, PACKETS_LOST, PACKETS_RECEIVED, PACKETS_SENT, REMOTE_INBOUND_RTP, ROUND_TRIP_TIME_MEASUREMENTS, RTC_CODEC, RTC_ICE_CANDIDATE, RTC_ICE_CANDIDATE_PAIR, RTP_RX_STAT, RTP_TX_STAT, SELECTED_CANDIDATE_PAIR_ID, SPARK_USER_AGENT, TARGET_BIT_RATE, TIMESTAMP, TOTAL_ROUND_TRIP_TIME, TOTAL_SAMPLES_DURATION, TRANSPORT, TYPE, URL_ENDPOINT, UTILS_FILE, METHODS, DEFAULT_KEEPALIVE_INTERVAL, } from '../CallingClient/constants
|
|
11
|
-
import { DEVICES, ITEMS, SETTINGS, VALUES, KEY, TIME, PLACEHOLDER_KEY, XSI_ACTION_ENDPOINT_ORG_URL_PARAM, XSI_ACTION_ENDPOINT, INFER_ID_CONSTANT, BW_XSI_URL, ENTITLEMENT_BASIC, ENTITLEMENT_BROADWORKS_CONN, ENTITLEMENT_STANDARD, NATIVE_WEBEX_TEAMS_CALLING, NATIVE_SIP_CALL_TO_UCM, BW_XSI_ENDPOINT_VERSION, IDENTITY_ENDPOINT_RESOURCE, SCIM_ENDPOINT_RESOURCE, SCIM_USER_FILTER, WEBEX_API_PROD, WEBEX_API_BTS, BW_XSI_ENDPOINT_VERSION_WITH_SLASH, } from './constants
|
|
12
|
-
import SDKConnector from '../SDKConnector
|
|
13
|
-
import { createLineError } from '../Errors/catalog/LineError
|
|
3
|
+
import { METRIC_EVENT, METRIC_TYPE, UPLOAD_LOGS_ACTION } from '../Metrics/types';
|
|
4
|
+
import { getMetricManager } from '../Metrics';
|
|
5
|
+
import { createCallError } from '../Errors/catalog/CallError';
|
|
6
|
+
import { DEVICE_ERROR_CODE, ERROR_CODE, ERROR_TYPE, CALL_ERROR_CODE, } from '../Errors/types';
|
|
7
|
+
import { CALLING_BACKEND, HTTP_METHODS, RegistrationStatus, SORT, ServiceIndicator, } from './types';
|
|
8
|
+
import log from '../Logger';
|
|
9
|
+
import { createClientError } from '../Errors/catalog/CallingDeviceError';
|
|
10
|
+
import { BYTES_RECEIVED, BYTES_SENT, CALLING_USER_AGENT, CISCO_DEVICE_URL, CODEC_ID, DUMMY_METRICS, INBOUND_CODEC_MATCH, INBOUND_RTP, JITTER_BUFFER_DELAY, JITTER_BUFFER_EMITTED_COUNT, LOCAL_CANDIDATE_ID, MEDIA_ID, MEDIA_SOURCE, MIME_TYPE, NETWORK_TYPE, OUTBOUND_CODEC_MATCH, OUTBOUND_RTP, PACKETS_DISCARDED, PACKETS_LOST, PACKETS_RECEIVED, PACKETS_SENT, REMOTE_INBOUND_RTP, ROUND_TRIP_TIME_MEASUREMENTS, RTC_CODEC, RTC_ICE_CANDIDATE, RTC_ICE_CANDIDATE_PAIR, RTP_RX_STAT, RTP_TX_STAT, SELECTED_CANDIDATE_PAIR_ID, SPARK_USER_AGENT, TARGET_BIT_RATE, TIMESTAMP, TOTAL_ROUND_TRIP_TIME, TOTAL_SAMPLES_DURATION, TRANSPORT, TYPE, URL_ENDPOINT, UTILS_FILE, METHODS, DEFAULT_KEEPALIVE_INTERVAL, } from '../CallingClient/constants';
|
|
11
|
+
import { DEVICES, ITEMS, SETTINGS, VALUES, KEY, TIME, PLACEHOLDER_KEY, XSI_ACTION_ENDPOINT_ORG_URL_PARAM, XSI_ACTION_ENDPOINT, INFER_ID_CONSTANT, BW_XSI_URL, ENTITLEMENT_BASIC, ENTITLEMENT_BROADWORKS_CONN, ENTITLEMENT_STANDARD, NATIVE_WEBEX_TEAMS_CALLING, NATIVE_SIP_CALL_TO_UCM, BW_XSI_ENDPOINT_VERSION, IDENTITY_ENDPOINT_RESOURCE, SCIM_ENDPOINT_RESOURCE, SCIM_USER_FILTER, WEBEX_API_PROD, WEBEX_API_BTS, BW_XSI_ENDPOINT_VERSION_WITH_SLASH, } from './constants';
|
|
12
|
+
import SDKConnector from '../SDKConnector';
|
|
13
|
+
import { createLineError } from '../Errors/catalog/LineError';
|
|
14
14
|
export function filterMobiusUris(mobiusServers, defaultMobiusUrl) {
|
|
15
15
|
const logContext = {
|
|
16
16
|
file: UTILS_FILE,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export * from './Utils
|
|
1
|
+
export * from './Utils';
|
package/dist/module/index.js
CHANGED
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
import { NoiseReductionEffect, createMicrophoneStream } from '@webex/media-helpers';
|
|
2
|
-
import { createCallSettingsClient } from './CallSettings/CallSettings
|
|
3
|
-
import { createContactsClient } from './Contacts/ContactsClient
|
|
4
|
-
import { createClient } from './CallingClient/CallingClient
|
|
5
|
-
import { createCallHistoryClient } from './CallHistory/CallHistory
|
|
6
|
-
import { createVoicemailClient } from './Voicemail/Voicemail
|
|
7
|
-
import Logger from './Logger
|
|
2
|
+
import { createCallSettingsClient } from './CallSettings/CallSettings';
|
|
3
|
+
import { createContactsClient } from './Contacts/ContactsClient';
|
|
4
|
+
import { createClient } from './CallingClient/CallingClient';
|
|
5
|
+
import { createCallHistoryClient } from './CallHistory/CallHistory';
|
|
6
|
+
import { createVoicemailClient } from './Voicemail/Voicemail';
|
|
7
|
+
import Logger from './Logger';
|
|
8
8
|
export { createClient, createCallHistoryClient, createCallSettingsClient, createContactsClient, createMicrophoneStream, createVoicemailClient, Logger, NoiseReductionEffect, };
|
|
9
|
-
export { ERROR_LAYER, ERROR_TYPE } from './Errors/types
|
|
10
|
-
export { GroupType } from './Contacts/types
|
|
11
|
-
export { LINE_EVENTS } from './CallingClient/line/types
|
|
12
|
-
export { CALLING_CLIENT_EVENT_KEYS, CALL_EVENT_KEYS, Disposition, LINE_EVENT_KEYS, COMMON_EVENT_KEYS, } from './Events/types
|
|
13
|
-
export { CallDirection, CallType, SORT, SORT_BY, } from './common/types
|
|
14
|
-
export { CallError, LineError } from './Errors
|
|
15
|
-
export { TransferType } from './CallingClient/calling/types
|
|
16
|
-
export { LOGGER } from './Logger/types
|
|
9
|
+
export { ERROR_LAYER, ERROR_TYPE } from './Errors/types';
|
|
10
|
+
export { GroupType } from './Contacts/types';
|
|
11
|
+
export { LINE_EVENTS } from './CallingClient/line/types';
|
|
12
|
+
export { CALLING_CLIENT_EVENT_KEYS, CALL_EVENT_KEYS, Disposition, LINE_EVENT_KEYS, COMMON_EVENT_KEYS, } from './Events/types';
|
|
13
|
+
export { CallDirection, CallType, SORT, SORT_BY, } from './common/types';
|
|
14
|
+
export { CallError, LineError } from './Errors';
|
|
15
|
+
export { TransferType } from './CallingClient/calling/types';
|
|
16
|
+
export { LOGGER } from './Logger/types';
|
|
17
17
|
export { LocalMicrophoneStream } from '@webex/media-helpers';
|
|
18
|
-
export { ServiceIndicator } from './common/types
|
|
18
|
+
export { ServiceIndicator } from './common/types';
|