@wxcc-desktop/sdk 2.0.1 → 2.0.3
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/README.md +595 -579
- package/dist/index.js +3 -3
- package/dist/types/index.d.ts +33 -31
- package/dist/types/jsapi/actions-jsapi.d.ts +39 -39
- package/dist/types/jsapi/agent-config-jsapi.d.ts +19 -19
- package/dist/types/jsapi/agent-contact-jsapi.d.ts +186 -186
- package/dist/types/jsapi/agent-state-info-jsapi.d.ts +83 -83
- package/dist/types/jsapi/agent-station-logout-jsapi.d.ts +34 -34
- package/dist/types/jsapi/call-monitoring-jsapi.d.ts +56 -56
- package/dist/types/jsapi/common/_logger.d.ts +4 -4
- package/dist/types/jsapi/common/_service-checker.d.ts +12 -12
- package/dist/types/jsapi/common/_service-events.d.ts +31 -31
- package/dist/types/jsapi/config-jsapi.d.ts +66 -66
- package/dist/types/jsapi/dialer-jsapi.d.ts +40 -40
- package/dist/types/jsapi/i18n-jsapi.d.ts +23 -23
- package/dist/types/jsapi/logger-jsapi.d.ts +19 -19
- package/dist/types/jsapi/post-interaction-jsapi.d.ts +26 -26
- package/dist/types/jsapi/rtdwc-jsapi.d.ts +24 -24
- package/dist/types/jsapi/screenpop-jsapi.d.ts +29 -29
- package/dist/types/jsapi/shortcut-key-jsapi.d.ts +70 -70
- package/dist/types/jsapi/webex-metrics-internal-jsapi.d.ts +19 -0
- package/dist/types/sdk.d.ts +1 -1
- package/package.json +2 -2
package/dist/types/index.d.ts
CHANGED
@@ -1,31 +1,33 @@
|
|
1
|
-
import { createActionsJsApi } from "./jsapi/actions-jsapi";
|
2
|
-
import { createAgentContactJsApi } from "./jsapi/agent-contact-jsapi";
|
3
|
-
import { createAgentStateInfoJsApi } from "./jsapi/agent-state-info-jsapi";
|
4
|
-
import { createConfigJsApi } from "./jsapi/config-jsapi";
|
5
|
-
import { createDialerJsApi } from "./jsapi/dialer-jsapi";
|
6
|
-
import { createI18NJsApi } from "./jsapi/i18n-jsapi";
|
7
|
-
import { createLoggerJsApi } from "./jsapi/logger-jsapi";
|
8
|
-
import { createScreenPopJsApi } from "./jsapi/screenpop-jsapi";
|
9
|
-
import { createShortcutKeyJsApi } from "./jsapi/shortcut-key-jsapi";
|
10
|
-
import { createRTDWCJsApi } from "./jsapi/rtdwc-jsapi";
|
11
|
-
import { createMonitoringJsApi } from "./jsapi/call-monitoring-jsapi";
|
12
|
-
import {
|
13
|
-
import {
|
14
|
-
import {
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
1
|
+
import { createActionsJsApi } from "./jsapi/actions-jsapi";
|
2
|
+
import { createAgentContactJsApi } from "./jsapi/agent-contact-jsapi";
|
3
|
+
import { createAgentStateInfoJsApi } from "./jsapi/agent-state-info-jsapi";
|
4
|
+
import { createConfigJsApi } from "./jsapi/config-jsapi";
|
5
|
+
import { createDialerJsApi } from "./jsapi/dialer-jsapi";
|
6
|
+
import { createI18NJsApi } from "./jsapi/i18n-jsapi";
|
7
|
+
import { createLoggerJsApi } from "./jsapi/logger-jsapi";
|
8
|
+
import { createScreenPopJsApi } from "./jsapi/screenpop-jsapi";
|
9
|
+
import { createShortcutKeyJsApi } from "./jsapi/shortcut-key-jsapi";
|
10
|
+
import { createRTDWCJsApi } from "./jsapi/rtdwc-jsapi";
|
11
|
+
import { createMonitoringJsApi } from "./jsapi/call-monitoring-jsapi";
|
12
|
+
import { createWebexMetricsInternalJsApi } from "./jsapi/webex-metrics-internal-jsapi";
|
13
|
+
import { stationLogoutJsApi } from "./jsapi/agent-station-logout-jsapi";
|
14
|
+
import { createPostInteractionJsApi } from "./jsapi/post-interaction-jsapi";
|
15
|
+
import { createAgentConfigJsApi } from "./jsapi/agent-config-jsapi";
|
16
|
+
export type AgentXJsApi = {
|
17
|
+
config: ReturnType<typeof createConfigJsApi>;
|
18
|
+
logger: ReturnType<typeof createLoggerJsApi>;
|
19
|
+
monitoring: ReturnType<typeof createMonitoringJsApi>;
|
20
|
+
shortcutKey: ReturnType<typeof createShortcutKeyJsApi>;
|
21
|
+
agentContact: ReturnType<typeof createAgentContactJsApi>;
|
22
|
+
agentStateInfo: ReturnType<typeof createAgentStateInfoJsApi>;
|
23
|
+
dialer: ReturnType<typeof createDialerJsApi>;
|
24
|
+
screenpop: ReturnType<typeof createScreenPopJsApi>;
|
25
|
+
logout: ReturnType<typeof stationLogoutJsApi>;
|
26
|
+
i18n: ReturnType<typeof createI18NJsApi>;
|
27
|
+
actions: ReturnType<typeof createActionsJsApi>;
|
28
|
+
rtdwc: ReturnType<typeof createRTDWCJsApi>;
|
29
|
+
postInteractions: ReturnType<typeof createPostInteractionJsApi>;
|
30
|
+
agentConfigJsApi: ReturnType<typeof createAgentConfigJsApi>;
|
31
|
+
webexMetricsInternal: ReturnType<typeof createWebexMetricsInternalJsApi>;
|
32
|
+
};
|
33
|
+
export declare const Desktop: AgentXJsApi;
|
@@ -1,39 +1,39 @@
|
|
1
|
-
import type { AgentContactSharedActions, GeneralNotificationsSharedActions } from "@wxcc-desktop/sdk-types";
|
2
|
-
import { AgentxService } from "@wxcc-desktop/sdk-types";
|
3
|
-
import { createJsApiLogger } from "./common/_logger";
|
4
|
-
import { createServiceChecker } from './common/_service-checker';
|
5
|
-
type Config = {
|
6
|
-
logger: ReturnType<typeof createJsApiLogger>;
|
7
|
-
serviceChecker: ReturnType<typeof createServiceChecker>;
|
8
|
-
};
|
9
|
-
export declare class ActionsJsApi {
|
10
|
-
private readonly logger;
|
11
|
-
private readonly serviceChecker;
|
12
|
-
private SERVICE?;
|
13
|
-
private sourceActionsChannels;
|
14
|
-
private destinationActionsChannels;
|
15
|
-
private checkService;
|
16
|
-
private lastReqTs;
|
17
|
-
private lastReqN;
|
18
|
-
private getNextReqId;
|
19
|
-
constructor(config: Config);
|
20
|
-
init(SERVICE?: AgentxService): void;
|
21
|
-
cleanup(): void;
|
22
|
-
fireGeneralSilentNotification(...args: GeneralNotificationsSharedActions.FireSilent.ReqPayloadParameters): void;
|
23
|
-
fireGeneralAutoDismissNotification(...args: GeneralNotificationsSharedActions.FireAutoDismiss.ReqPayloadParameters): Promise<GeneralNotificationsSharedActions.FireAutoDismiss.ResPayloadParameters | undefined>;
|
24
|
-
fireGeneralAcknowledgeNotification(...args: GeneralNotificationsSharedActions.FireAcknowledge.ReqPayloadParameters): Promise<GeneralNotificationsSharedActions.FireAcknowledge.ResPayloadParameters | undefined>;
|
25
|
-
addCustomTask(...args: AgentContactSharedActions.AddCustomContact.ReqPayloadParameters): void;
|
26
|
-
getTaskMap(): Promise<import("@wxcc-desktop/sdk-types/agentx/store/store-agent-contact").TaskMap | undefined>;
|
27
|
-
getMediaTypeQueue(mediaType: string): Promise<import("@wxcc-desktop/sdk-types/agentx/store/store-agent-contact").TaskMap | undefined>;
|
28
|
-
getToken(): Promise<string | undefined>;
|
29
|
-
getIdleCodes(): Promise<import("@agentx/agentx-services").Service.Aqm.Configs.Entity[] | undefined>;
|
30
|
-
getWrapUpCodes(): Promise<import("@agentx/agentx-services").Service.Aqm.Configs.WrapUpReason[] | undefined>;
|
31
|
-
getClosestElement(el: any, selector: string): HTMLElement | null;
|
32
|
-
toggleMiximizeRestore: (e: MouseEvent | KeyboardEvent) => void;
|
33
|
-
toggleVoiceInteractionPanel: () => void;
|
34
|
-
toggleMuteUnmuteWebRtcCall: () => void;
|
35
|
-
declineWebRtcCall: () => void;
|
36
|
-
acceptWebRtcCall: () => void;
|
37
|
-
}
|
38
|
-
export declare const createActionsJsApi: () => ActionsJsApi;
|
39
|
-
export {};
|
1
|
+
import type { AgentContactSharedActions, GeneralNotificationsSharedActions } from "@wxcc-desktop/sdk-types";
|
2
|
+
import { AgentxService } from "@wxcc-desktop/sdk-types";
|
3
|
+
import { createJsApiLogger } from "./common/_logger";
|
4
|
+
import { createServiceChecker } from './common/_service-checker';
|
5
|
+
type Config = {
|
6
|
+
logger: ReturnType<typeof createJsApiLogger>;
|
7
|
+
serviceChecker: ReturnType<typeof createServiceChecker>;
|
8
|
+
};
|
9
|
+
export declare class ActionsJsApi {
|
10
|
+
private readonly logger;
|
11
|
+
private readonly serviceChecker;
|
12
|
+
private SERVICE?;
|
13
|
+
private sourceActionsChannels;
|
14
|
+
private destinationActionsChannels;
|
15
|
+
private checkService;
|
16
|
+
private lastReqTs;
|
17
|
+
private lastReqN;
|
18
|
+
private getNextReqId;
|
19
|
+
constructor(config: Config);
|
20
|
+
init(SERVICE?: AgentxService): void;
|
21
|
+
cleanup(): void;
|
22
|
+
fireGeneralSilentNotification(...args: GeneralNotificationsSharedActions.FireSilent.ReqPayloadParameters): void;
|
23
|
+
fireGeneralAutoDismissNotification(...args: GeneralNotificationsSharedActions.FireAutoDismiss.ReqPayloadParameters): Promise<GeneralNotificationsSharedActions.FireAutoDismiss.ResPayloadParameters | undefined>;
|
24
|
+
fireGeneralAcknowledgeNotification(...args: GeneralNotificationsSharedActions.FireAcknowledge.ReqPayloadParameters): Promise<GeneralNotificationsSharedActions.FireAcknowledge.ResPayloadParameters | undefined>;
|
25
|
+
addCustomTask(...args: AgentContactSharedActions.AddCustomContact.ReqPayloadParameters): void;
|
26
|
+
getTaskMap(): Promise<import("@wxcc-desktop/sdk-types/agentx/store/store-agent-contact").TaskMap | undefined>;
|
27
|
+
getMediaTypeQueue(mediaType: string): Promise<import("@wxcc-desktop/sdk-types/agentx/store/store-agent-contact").TaskMap | undefined>;
|
28
|
+
getToken(): Promise<string | undefined>;
|
29
|
+
getIdleCodes(): Promise<import("@agentx/agentx-services").Service.Aqm.Configs.Entity[] | undefined>;
|
30
|
+
getWrapUpCodes(): Promise<import("@agentx/agentx-services").Service.Aqm.Configs.WrapUpReason[] | undefined>;
|
31
|
+
getClosestElement(el: any, selector: string): HTMLElement | null;
|
32
|
+
toggleMiximizeRestore: (e: MouseEvent | KeyboardEvent) => void;
|
33
|
+
toggleVoiceInteractionPanel: () => void;
|
34
|
+
toggleMuteUnmuteWebRtcCall: () => void;
|
35
|
+
declineWebRtcCall: () => void;
|
36
|
+
acceptWebRtcCall: () => void;
|
37
|
+
}
|
38
|
+
export declare const createActionsJsApi: () => ActionsJsApi;
|
39
|
+
export {};
|
@@ -1,19 +1,19 @@
|
|
1
|
-
import { AgentxService, Service } from "@wxcc-desktop/sdk-types";
|
2
|
-
import { createJsApiLogger } from "./common/_logger";
|
3
|
-
import { createServiceChecker } from "./common/_service-checker";
|
4
|
-
type Config = {
|
5
|
-
logger: ReturnType<typeof createJsApiLogger>;
|
6
|
-
serviceChecker: ReturnType<typeof createServiceChecker>;
|
7
|
-
};
|
8
|
-
export declare class AgentConfigJsApi {
|
9
|
-
private readonly logger;
|
10
|
-
private readonly serviceChecker;
|
11
|
-
private SERVICE?;
|
12
|
-
private checkService;
|
13
|
-
constructor(config: Config);
|
14
|
-
init(SERVICE?: AgentxService): void;
|
15
|
-
cleanup(): void;
|
16
|
-
fetchPaginatedAuxCodes(data: Service.Aqm.Configs.AuxCodePayload): Promise<Service.Aqm.Configs.PaginatedAuxCode | undefined>;
|
17
|
-
}
|
18
|
-
export declare const createAgentConfigJsApi: () => AgentConfigJsApi;
|
19
|
-
export {};
|
1
|
+
import { AgentxService, Service } from "@wxcc-desktop/sdk-types";
|
2
|
+
import { createJsApiLogger } from "./common/_logger";
|
3
|
+
import { createServiceChecker } from "./common/_service-checker";
|
4
|
+
type Config = {
|
5
|
+
logger: ReturnType<typeof createJsApiLogger>;
|
6
|
+
serviceChecker: ReturnType<typeof createServiceChecker>;
|
7
|
+
};
|
8
|
+
export declare class AgentConfigJsApi {
|
9
|
+
private readonly logger;
|
10
|
+
private readonly serviceChecker;
|
11
|
+
private SERVICE?;
|
12
|
+
private checkService;
|
13
|
+
constructor(config: Config);
|
14
|
+
init(SERVICE?: AgentxService): void;
|
15
|
+
cleanup(): void;
|
16
|
+
fetchPaginatedAuxCodes(data: Service.Aqm.Configs.AuxCodePayload): Promise<Service.Aqm.Configs.PaginatedAuxCode | undefined>;
|
17
|
+
}
|
18
|
+
export declare const createAgentConfigJsApi: () => AgentConfigJsApi;
|
19
|
+
export {};
|
@@ -1,186 +1,186 @@
|
|
1
|
-
import { AgentxService, Service } from "@wxcc-desktop/sdk-types";
|
2
|
-
import { createJsApiLogger } from "./common/_logger";
|
3
|
-
import { createServiceChecker } from "./common/_service-checker";
|
4
|
-
import { AqmServiceEntityEvents } from "./common/_service-events";
|
5
|
-
type Listeners = {
|
6
|
-
eAgentContact: Parameters<AgentxService["aqm"]["contact"]["eAgentContact"]["listen"]>[0];
|
7
|
-
eAgentContactAssigned: Parameters<AgentxService["aqm"]["contact"]["eAgentContactAssigned"]["listen"]>[0];
|
8
|
-
eAgentContactEnded: Parameters<AgentxService["aqm"]["contact"]["eAgentContactEnded"]["listen"]>[0];
|
9
|
-
eAgentContactWrappedUp: Parameters<AgentxService["aqm"]["contact"]["eAgentContactWrappedUp"]["listen"]>[0];
|
10
|
-
eAgentOfferContact: Parameters<AgentxService["aqm"]["contact"]["eAgentOfferContact"]["listen"]>[0];
|
11
|
-
eAgentOfferContactRona: Parameters<AgentxService["aqm"]["contact"]["eAgentOfferContactRona"]["listen"]>[0];
|
12
|
-
eAgentOfferConsult: Parameters<AgentxService["aqm"]["contact"]["eAgentOfferConsult"]["listen"]>[0];
|
13
|
-
eAgentWrapup: Parameters<AgentxService["aqm"]["contact"]["eAgentWrapup"]["listen"]>[0];
|
14
|
-
eAgentContactHeld: Parameters<AgentxService["aqm"]["contact"]["eAgentContactHeld"]["listen"]>[0];
|
15
|
-
eAgentContactUnHeld: Parameters<AgentxService["aqm"]["contact"]["eAgentContactUnHeld"]["listen"]>[0];
|
16
|
-
eCallRecordingStarted: Parameters<AgentxService["aqm"]["contact"]["eCallRecordingStarted"]["listen"]>[0];
|
17
|
-
eAgentConsultCreated: Parameters<AgentxService["aqm"]["contact"]["eAgentConsultCreated"]["listen"]>[0];
|
18
|
-
eAgentConsultConferenced: Parameters<AgentxService["aqm"]["contact"]["eAgentConsultConferenced"]["listen"]>[0];
|
19
|
-
eAgentConsultEnded: Parameters<AgentxService["aqm"]["contact"]["eAgentConsultEnded"]["listen"]>[0];
|
20
|
-
eAgentCtqCancelled: Parameters<AgentxService["aqm"]["contact"]["eAgentCtqCancelled"]["listen"]>[0];
|
21
|
-
eAgentConsulting: Parameters<AgentxService["aqm"]["contact"]["eAgentConsulting"]["listen"]>[0];
|
22
|
-
eAgentConsultFailed: Parameters<AgentxService["aqm"]["contact"]["eAgentConsultFailed"]["listen"]>[0];
|
23
|
-
eAgentConsultEndFailed: Parameters<AgentxService["aqm"]["contact"]["eAgentConsultEndFailed"]["listen"]>[0];
|
24
|
-
eAgentCtqFailed: Parameters<AgentxService["aqm"]["contact"]["eAgentCtqFailed"]["listen"]>[0];
|
25
|
-
eAgentCtqCancelFailed: Parameters<AgentxService["aqm"]["contact"]["eAgentCtqCancelFailed"]["listen"]>[0];
|
26
|
-
eAgentConsultConferenceEndFailed: Parameters<AgentxService["aqm"]["contact"]["eAgentConsultConferenceEndFailed"]["listen"]>[0];
|
27
|
-
eAgentMonitorStateChanged: Parameters<AgentxService["aqm"]["supervisor"]["eAgentMonitorStateChanged"]["listen"]>[0];
|
28
|
-
eAgentMonitoringEnded: Parameters<AgentxService["aqm"]["supervisor"]["eAgentMonitoringEnded"]["listen"]>[0];
|
29
|
-
eAgentOfferCampaignReserved: Parameters<AgentxService["aqm"]["contact"]["eAgentOfferCampaignReserved"]["listen"]>[0];
|
30
|
-
eAgentAddCampaignReserved: Parameters<AgentxService["aqm"]["contact"]["eAgentAddCampaignReserved"]["listen"]>[0];
|
31
|
-
};
|
32
|
-
type AqmContactEvents = AqmServiceEntityEvents<Listeners>;
|
33
|
-
type Config = {
|
34
|
-
logger: ReturnType<typeof createJsApiLogger>;
|
35
|
-
serviceChecker: ReturnType<typeof createServiceChecker>;
|
36
|
-
aqmEvents: AqmContactEvents;
|
37
|
-
};
|
38
|
-
export declare class AgentContactJsApi {
|
39
|
-
private readonly logger;
|
40
|
-
private readonly serviceChecker;
|
41
|
-
private readonly aqmEvents;
|
42
|
-
private SERVICE?;
|
43
|
-
private checkService;
|
44
|
-
constructor(config: Config);
|
45
|
-
init(SERVICE?: AgentxService): void;
|
46
|
-
cleanup(): void;
|
47
|
-
sendDtmf(digit: any): void;
|
48
|
-
accept(p: {
|
49
|
-
interactionId: string;
|
50
|
-
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
51
|
-
consultAccept(p: {
|
52
|
-
interactionId: string;
|
53
|
-
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
54
|
-
buddyAgents(p: {
|
55
|
-
data: Service.Aqm.Contact.BuddyAgents;
|
56
|
-
}): Promise<Service.Aqm.Contact.BuddyAgentsSuccess | undefined>;
|
57
|
-
end(p: {
|
58
|
-
interactionId: string;
|
59
|
-
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
60
|
-
consultEnd(p: {
|
61
|
-
interactionId: string;
|
62
|
-
isConsult: boolean;
|
63
|
-
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
64
|
-
cancelCtq(p: {
|
65
|
-
interactionId: string;
|
66
|
-
data: Service.Aqm.Contact.cancelCtq;
|
67
|
-
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
68
|
-
wrapup(p: {
|
69
|
-
interactionId: string;
|
70
|
-
data: Service.Aqm.Contact.WrapupPayLoad;
|
71
|
-
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
72
|
-
vteamTransfer(p: {
|
73
|
-
interactionId: string;
|
74
|
-
data: Service.Aqm.Contact.vteamTransferPayLoad;
|
75
|
-
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
76
|
-
blindTransfer(p: {
|
77
|
-
interactionId: string;
|
78
|
-
data: Service.Aqm.Contact.blindTransferPayLoad;
|
79
|
-
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
80
|
-
hold(p: {
|
81
|
-
interactionId: string;
|
82
|
-
data: {
|
83
|
-
mediaResourceId: string;
|
84
|
-
};
|
85
|
-
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
86
|
-
unHold(p: {
|
87
|
-
interactionId: string;
|
88
|
-
data: {
|
89
|
-
mediaResourceId: string;
|
90
|
-
};
|
91
|
-
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
92
|
-
consult(p: {
|
93
|
-
interactionId: string;
|
94
|
-
data: Service.Aqm.Contact.ConsultPayload | Service.Aqm.Contact.ConsultDN | Service.Aqm.Contact.ConsultAgent | Service.Aqm.Contact.ConsultQueue;
|
95
|
-
url: string;
|
96
|
-
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
97
|
-
consultConference(p: {
|
98
|
-
interactionId: string;
|
99
|
-
data: Service.Aqm.Contact.ConsultPayload;
|
100
|
-
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
101
|
-
decline(p: {
|
102
|
-
interactionId: string;
|
103
|
-
data: {
|
104
|
-
mediaResourceId: string;
|
105
|
-
};
|
106
|
-
isConsult: boolean;
|
107
|
-
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
108
|
-
consultTransfer(p: {
|
109
|
-
interactionId: string;
|
110
|
-
data: Service.Aqm.Contact.consultTransferPayLoad;
|
111
|
-
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
112
|
-
vteamList(p: {
|
113
|
-
data: Service.Aqm.Contact.VTeam;
|
114
|
-
}): Promise<Service.Aqm.Contact.VTeamSuccess | undefined>;
|
115
|
-
pauseRecording(p: {
|
116
|
-
interactionId: string;
|
117
|
-
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
118
|
-
resumeRecording(p: {
|
119
|
-
interactionId: string;
|
120
|
-
data: {
|
121
|
-
autoResumed: boolean;
|
122
|
-
};
|
123
|
-
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
124
|
-
acceptV2(p: {
|
125
|
-
interactionId: string;
|
126
|
-
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
127
|
-
endV2(p: {
|
128
|
-
interactionId: string;
|
129
|
-
isEndingFromNonPrimary?: boolean;
|
130
|
-
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
131
|
-
cancelTaskV2(p: {
|
132
|
-
interactionId: string;
|
133
|
-
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
134
|
-
pauseRecordingV2(p: {
|
135
|
-
interactionId: string;
|
136
|
-
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
137
|
-
resumeRecordingV2(p: {
|
138
|
-
interactionId: string;
|
139
|
-
data: {
|
140
|
-
autoResumed: boolean;
|
141
|
-
};
|
142
|
-
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
143
|
-
wrapupV2(p: {
|
144
|
-
interactionId: string;
|
145
|
-
data: Service.Aqm.Contact.WrapupV2PayLoad;
|
146
|
-
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
147
|
-
consultV2(p: {
|
148
|
-
interactionId: string;
|
149
|
-
data: Service.Aqm.Contact.consultDataV2;
|
150
|
-
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
151
|
-
consultEndV2(p: {
|
152
|
-
interactionId: string;
|
153
|
-
isConsult: boolean;
|
154
|
-
isSecondaryEpDnAgent?: boolean;
|
155
|
-
queueId?: string;
|
156
|
-
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
157
|
-
consultConferenceV2(p: {
|
158
|
-
interactionId: string;
|
159
|
-
data: Service.Aqm.Contact.consultConferenceDataV2;
|
160
|
-
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
161
|
-
exitConference(p: {
|
162
|
-
interactionId: string;
|
163
|
-
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
164
|
-
consultTransferV2(p: {
|
165
|
-
interactionId: string;
|
166
|
-
data: Service.Aqm.Contact.transferV2Payload;
|
167
|
-
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
168
|
-
blindTransferV2(p: {
|
169
|
-
interactionId: string;
|
170
|
-
data: Service.Aqm.Contact.transferV2Payload;
|
171
|
-
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
172
|
-
vteamTransferV2(p: {
|
173
|
-
interactionId: string;
|
174
|
-
data: Service.Aqm.Contact.transferV2Payload;
|
175
|
-
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
176
|
-
buddyAgentsV2(p: {
|
177
|
-
data: Service.Aqm.Contact.BuddyAgentsV2;
|
178
|
-
}): Promise<Service.Aqm.Contact.BuddyAgentsSuccess | undefined>;
|
179
|
-
addEventListener<T extends keyof Listeners>(eventName: T, listener: Listeners[T]): void;
|
180
|
-
addOnceEventListener<T extends keyof Listeners>(eventName: T, listener: Listeners[T]): void;
|
181
|
-
removeEventListener<T extends keyof Listeners>(eventName: T, listener: Listeners[T]): void;
|
182
|
-
removeOnceEventListener<T extends keyof Listeners>(eventName: T, listener: Listeners[T]): void;
|
183
|
-
removeAllEventListeners(): void;
|
184
|
-
}
|
185
|
-
export declare const createAgentContactJsApi: () => AgentContactJsApi;
|
186
|
-
export {};
|
1
|
+
import { AgentxService, Service } from "@wxcc-desktop/sdk-types";
|
2
|
+
import { createJsApiLogger } from "./common/_logger";
|
3
|
+
import { createServiceChecker } from "./common/_service-checker";
|
4
|
+
import { AqmServiceEntityEvents } from "./common/_service-events";
|
5
|
+
type Listeners = {
|
6
|
+
eAgentContact: Parameters<AgentxService["aqm"]["contact"]["eAgentContact"]["listen"]>[0];
|
7
|
+
eAgentContactAssigned: Parameters<AgentxService["aqm"]["contact"]["eAgentContactAssigned"]["listen"]>[0];
|
8
|
+
eAgentContactEnded: Parameters<AgentxService["aqm"]["contact"]["eAgentContactEnded"]["listen"]>[0];
|
9
|
+
eAgentContactWrappedUp: Parameters<AgentxService["aqm"]["contact"]["eAgentContactWrappedUp"]["listen"]>[0];
|
10
|
+
eAgentOfferContact: Parameters<AgentxService["aqm"]["contact"]["eAgentOfferContact"]["listen"]>[0];
|
11
|
+
eAgentOfferContactRona: Parameters<AgentxService["aqm"]["contact"]["eAgentOfferContactRona"]["listen"]>[0];
|
12
|
+
eAgentOfferConsult: Parameters<AgentxService["aqm"]["contact"]["eAgentOfferConsult"]["listen"]>[0];
|
13
|
+
eAgentWrapup: Parameters<AgentxService["aqm"]["contact"]["eAgentWrapup"]["listen"]>[0];
|
14
|
+
eAgentContactHeld: Parameters<AgentxService["aqm"]["contact"]["eAgentContactHeld"]["listen"]>[0];
|
15
|
+
eAgentContactUnHeld: Parameters<AgentxService["aqm"]["contact"]["eAgentContactUnHeld"]["listen"]>[0];
|
16
|
+
eCallRecordingStarted: Parameters<AgentxService["aqm"]["contact"]["eCallRecordingStarted"]["listen"]>[0];
|
17
|
+
eAgentConsultCreated: Parameters<AgentxService["aqm"]["contact"]["eAgentConsultCreated"]["listen"]>[0];
|
18
|
+
eAgentConsultConferenced: Parameters<AgentxService["aqm"]["contact"]["eAgentConsultConferenced"]["listen"]>[0];
|
19
|
+
eAgentConsultEnded: Parameters<AgentxService["aqm"]["contact"]["eAgentConsultEnded"]["listen"]>[0];
|
20
|
+
eAgentCtqCancelled: Parameters<AgentxService["aqm"]["contact"]["eAgentCtqCancelled"]["listen"]>[0];
|
21
|
+
eAgentConsulting: Parameters<AgentxService["aqm"]["contact"]["eAgentConsulting"]["listen"]>[0];
|
22
|
+
eAgentConsultFailed: Parameters<AgentxService["aqm"]["contact"]["eAgentConsultFailed"]["listen"]>[0];
|
23
|
+
eAgentConsultEndFailed: Parameters<AgentxService["aqm"]["contact"]["eAgentConsultEndFailed"]["listen"]>[0];
|
24
|
+
eAgentCtqFailed: Parameters<AgentxService["aqm"]["contact"]["eAgentCtqFailed"]["listen"]>[0];
|
25
|
+
eAgentCtqCancelFailed: Parameters<AgentxService["aqm"]["contact"]["eAgentCtqCancelFailed"]["listen"]>[0];
|
26
|
+
eAgentConsultConferenceEndFailed: Parameters<AgentxService["aqm"]["contact"]["eAgentConsultConferenceEndFailed"]["listen"]>[0];
|
27
|
+
eAgentMonitorStateChanged: Parameters<AgentxService["aqm"]["supervisor"]["eAgentMonitorStateChanged"]["listen"]>[0];
|
28
|
+
eAgentMonitoringEnded: Parameters<AgentxService["aqm"]["supervisor"]["eAgentMonitoringEnded"]["listen"]>[0];
|
29
|
+
eAgentOfferCampaignReserved: Parameters<AgentxService["aqm"]["contact"]["eAgentOfferCampaignReserved"]["listen"]>[0];
|
30
|
+
eAgentAddCampaignReserved: Parameters<AgentxService["aqm"]["contact"]["eAgentAddCampaignReserved"]["listen"]>[0];
|
31
|
+
};
|
32
|
+
type AqmContactEvents = AqmServiceEntityEvents<Listeners>;
|
33
|
+
type Config = {
|
34
|
+
logger: ReturnType<typeof createJsApiLogger>;
|
35
|
+
serviceChecker: ReturnType<typeof createServiceChecker>;
|
36
|
+
aqmEvents: AqmContactEvents;
|
37
|
+
};
|
38
|
+
export declare class AgentContactJsApi {
|
39
|
+
private readonly logger;
|
40
|
+
private readonly serviceChecker;
|
41
|
+
private readonly aqmEvents;
|
42
|
+
private SERVICE?;
|
43
|
+
private checkService;
|
44
|
+
constructor(config: Config);
|
45
|
+
init(SERVICE?: AgentxService): void;
|
46
|
+
cleanup(): void;
|
47
|
+
sendDtmf(digit: any): void;
|
48
|
+
accept(p: {
|
49
|
+
interactionId: string;
|
50
|
+
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
51
|
+
consultAccept(p: {
|
52
|
+
interactionId: string;
|
53
|
+
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
54
|
+
buddyAgents(p: {
|
55
|
+
data: Service.Aqm.Contact.BuddyAgents;
|
56
|
+
}): Promise<Service.Aqm.Contact.BuddyAgentsSuccess | undefined>;
|
57
|
+
end(p: {
|
58
|
+
interactionId: string;
|
59
|
+
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
60
|
+
consultEnd(p: {
|
61
|
+
interactionId: string;
|
62
|
+
isConsult: boolean;
|
63
|
+
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
64
|
+
cancelCtq(p: {
|
65
|
+
interactionId: string;
|
66
|
+
data: Service.Aqm.Contact.cancelCtq;
|
67
|
+
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
68
|
+
wrapup(p: {
|
69
|
+
interactionId: string;
|
70
|
+
data: Service.Aqm.Contact.WrapupPayLoad;
|
71
|
+
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
72
|
+
vteamTransfer(p: {
|
73
|
+
interactionId: string;
|
74
|
+
data: Service.Aqm.Contact.vteamTransferPayLoad;
|
75
|
+
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
76
|
+
blindTransfer(p: {
|
77
|
+
interactionId: string;
|
78
|
+
data: Service.Aqm.Contact.blindTransferPayLoad;
|
79
|
+
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
80
|
+
hold(p: {
|
81
|
+
interactionId: string;
|
82
|
+
data: {
|
83
|
+
mediaResourceId: string;
|
84
|
+
};
|
85
|
+
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
86
|
+
unHold(p: {
|
87
|
+
interactionId: string;
|
88
|
+
data: {
|
89
|
+
mediaResourceId: string;
|
90
|
+
};
|
91
|
+
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
92
|
+
consult(p: {
|
93
|
+
interactionId: string;
|
94
|
+
data: Service.Aqm.Contact.ConsultPayload | Service.Aqm.Contact.ConsultDN | Service.Aqm.Contact.ConsultAgent | Service.Aqm.Contact.ConsultQueue;
|
95
|
+
url: string;
|
96
|
+
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
97
|
+
consultConference(p: {
|
98
|
+
interactionId: string;
|
99
|
+
data: Service.Aqm.Contact.ConsultPayload;
|
100
|
+
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
101
|
+
decline(p: {
|
102
|
+
interactionId: string;
|
103
|
+
data: {
|
104
|
+
mediaResourceId: string;
|
105
|
+
};
|
106
|
+
isConsult: boolean;
|
107
|
+
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
108
|
+
consultTransfer(p: {
|
109
|
+
interactionId: string;
|
110
|
+
data: Service.Aqm.Contact.consultTransferPayLoad;
|
111
|
+
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
112
|
+
vteamList(p: {
|
113
|
+
data: Service.Aqm.Contact.VTeam;
|
114
|
+
}): Promise<Service.Aqm.Contact.VTeamSuccess | undefined>;
|
115
|
+
pauseRecording(p: {
|
116
|
+
interactionId: string;
|
117
|
+
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
118
|
+
resumeRecording(p: {
|
119
|
+
interactionId: string;
|
120
|
+
data: {
|
121
|
+
autoResumed: boolean;
|
122
|
+
};
|
123
|
+
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
124
|
+
acceptV2(p: {
|
125
|
+
interactionId: string;
|
126
|
+
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
127
|
+
endV2(p: {
|
128
|
+
interactionId: string;
|
129
|
+
isEndingFromNonPrimary?: boolean;
|
130
|
+
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
131
|
+
cancelTaskV2(p: {
|
132
|
+
interactionId: string;
|
133
|
+
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
134
|
+
pauseRecordingV2(p: {
|
135
|
+
interactionId: string;
|
136
|
+
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
137
|
+
resumeRecordingV2(p: {
|
138
|
+
interactionId: string;
|
139
|
+
data: {
|
140
|
+
autoResumed: boolean;
|
141
|
+
};
|
142
|
+
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
143
|
+
wrapupV2(p: {
|
144
|
+
interactionId: string;
|
145
|
+
data: Service.Aqm.Contact.WrapupV2PayLoad;
|
146
|
+
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
147
|
+
consultV2(p: {
|
148
|
+
interactionId: string;
|
149
|
+
data: Service.Aqm.Contact.consultDataV2;
|
150
|
+
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
151
|
+
consultEndV2(p: {
|
152
|
+
interactionId: string;
|
153
|
+
isConsult: boolean;
|
154
|
+
isSecondaryEpDnAgent?: boolean;
|
155
|
+
queueId?: string;
|
156
|
+
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
157
|
+
consultConferenceV2(p: {
|
158
|
+
interactionId: string;
|
159
|
+
data: Service.Aqm.Contact.consultConferenceDataV2;
|
160
|
+
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
161
|
+
exitConference(p: {
|
162
|
+
interactionId: string;
|
163
|
+
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
164
|
+
consultTransferV2(p: {
|
165
|
+
interactionId: string;
|
166
|
+
data: Service.Aqm.Contact.transferV2Payload;
|
167
|
+
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
168
|
+
blindTransferV2(p: {
|
169
|
+
interactionId: string;
|
170
|
+
data: Service.Aqm.Contact.transferV2Payload;
|
171
|
+
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
172
|
+
vteamTransferV2(p: {
|
173
|
+
interactionId: string;
|
174
|
+
data: Service.Aqm.Contact.transferV2Payload;
|
175
|
+
}): Promise<Service.Aqm.Contact.AgentContact | undefined>;
|
176
|
+
buddyAgentsV2(p: {
|
177
|
+
data: Service.Aqm.Contact.BuddyAgentsV2;
|
178
|
+
}): Promise<Service.Aqm.Contact.BuddyAgentsSuccess | undefined>;
|
179
|
+
addEventListener<T extends keyof Listeners>(eventName: T, listener: Listeners[T]): void;
|
180
|
+
addOnceEventListener<T extends keyof Listeners>(eventName: T, listener: Listeners[T]): void;
|
181
|
+
removeEventListener<T extends keyof Listeners>(eventName: T, listener: Listeners[T]): void;
|
182
|
+
removeOnceEventListener<T extends keyof Listeners>(eventName: T, listener: Listeners[T]): void;
|
183
|
+
removeAllEventListeners(): void;
|
184
|
+
}
|
185
|
+
export declare const createAgentContactJsApi: () => AgentContactJsApi;
|
186
|
+
export {};
|