@cleardu/types 1.0.77 → 1.0.79
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/constants/brokerMessages/index.d.ts +2 -0
- package/constants/brokerMessages/index.js +2 -0
- package/constants/brokerMessages/index.ts +2 -0
- package/constants/index.d.ts +177 -4
- package/constants/index.js +178 -5
- package/constants/index.ts +179 -6
- package/interfaces/index.d.ts +2 -0
- package/interfaces/index.js +2 -0
- package/interfaces/index.ts +2 -0
- package/interfaces/userStatus/index.d.ts +29 -0
- package/interfaces/userStatus/index.js +2 -0
- package/interfaces/userStatus/index.ts +31 -0
- package/interfaces/userTasks/index.d.ts +5 -0
- package/interfaces/userTasks/index.ts +6 -0
- package/interfaces/webhook/index.d.ts +70 -0
- package/interfaces/webhook/index.js +2 -0
- package/interfaces/webhook/index.ts +77 -0
- package/package.json +1 -1
- package/tsconfig.build.tsbuildinfo +1 -1
package/constants/index.ts
CHANGED
|
@@ -100,7 +100,8 @@ export const userModules = {
|
|
|
100
100
|
Centers: 29,
|
|
101
101
|
Breaks: 30,
|
|
102
102
|
PaymentAccounts: 31,
|
|
103
|
-
PaymentLinks: 32
|
|
103
|
+
PaymentLinks: 32,
|
|
104
|
+
ClientDispositions: 33
|
|
104
105
|
};
|
|
105
106
|
|
|
106
107
|
export const dispoSubDispo = {
|
|
@@ -231,17 +232,133 @@ export const Constants = {
|
|
|
231
232
|
SEEDER: {
|
|
232
233
|
ROLE: {
|
|
233
234
|
PERMISSION: {
|
|
235
|
+
CENTER: {
|
|
236
|
+
ADD: {
|
|
237
|
+
TITLE: 'Add Centers',
|
|
238
|
+
SLUG: 'create_centers',
|
|
239
|
+
DESCRIPTION: 'Create centers',
|
|
240
|
+
MODULE_ID: userModules.Centers,
|
|
241
|
+
},
|
|
242
|
+
EDIT: {
|
|
243
|
+
TITLE: 'Edit Centers',
|
|
244
|
+
SLUG: 'edit_centers',
|
|
245
|
+
DESCRIPTION: 'Edit centers',
|
|
246
|
+
MODULE_ID: userModules.Centers,
|
|
247
|
+
},
|
|
248
|
+
UPDATE: {
|
|
249
|
+
TITLE: 'Update Centers',
|
|
250
|
+
SLUG: 'update_centers',
|
|
251
|
+
DESCRIPTION: 'Update centers',
|
|
252
|
+
MODULE_ID: userModules.Centers,
|
|
253
|
+
},
|
|
254
|
+
LIST: {
|
|
255
|
+
TITLE: 'List Centers',
|
|
256
|
+
SLUG: 'list_centers',
|
|
257
|
+
DESCRIPTION: 'List centers',
|
|
258
|
+
MODULE_ID: userModules.Centers,
|
|
259
|
+
}
|
|
260
|
+
},
|
|
261
|
+
DISPOSITIONS: {
|
|
262
|
+
ADD: {
|
|
263
|
+
TITLE: 'Add Dispositions',
|
|
264
|
+
SLUG: 'create_dispositions',
|
|
265
|
+
DESCRIPTION: 'Create Dispositions',
|
|
266
|
+
MODULE_ID: userModules.Dispositions,
|
|
267
|
+
},
|
|
268
|
+
EDIT: {
|
|
269
|
+
TITLE: 'Edit Dispositions',
|
|
270
|
+
SLUG: 'edit_dispositions',
|
|
271
|
+
DESCRIPTION: 'Edit Dispositions',
|
|
272
|
+
MODULE_ID: userModules.Dispositions,
|
|
273
|
+
},
|
|
274
|
+
UPDATE: {
|
|
275
|
+
TITLE: 'Update Dispositions',
|
|
276
|
+
SLUG: 'update_dispositions',
|
|
277
|
+
DESCRIPTION: 'Update Dispositions',
|
|
278
|
+
MODULE_ID: userModules.Dispositions,
|
|
279
|
+
},
|
|
280
|
+
LIST: {
|
|
281
|
+
TITLE: 'List Dispositions',
|
|
282
|
+
SLUG: 'list_dispositions',
|
|
283
|
+
DESCRIPTION: 'List Dispositions',
|
|
284
|
+
MODULE_ID: userModules.Dispositions,
|
|
285
|
+
},
|
|
286
|
+
DELETE: {
|
|
287
|
+
TITLE: 'Delete Dispositions',
|
|
288
|
+
SLUG: 'delete_dispositions',
|
|
289
|
+
DESCRIPTION: 'Delete Dispositions',
|
|
290
|
+
MODULE_ID: userModules.Dispositions,
|
|
291
|
+
}
|
|
292
|
+
},
|
|
293
|
+
BREACK: {
|
|
294
|
+
ADD: {
|
|
295
|
+
TITLE: 'Add break',
|
|
296
|
+
SLUG: 'create_break',
|
|
297
|
+
DESCRIPTION: 'Create break',
|
|
298
|
+
MODULE_ID: userModules.Breaks,
|
|
299
|
+
},
|
|
300
|
+
EDIT: {
|
|
301
|
+
TITLE: 'Edit/Get break',
|
|
302
|
+
SLUG: 'edit_break',
|
|
303
|
+
DESCRIPTION: 'Edit/Get break',
|
|
304
|
+
MODULE_ID: userModules.Breaks,
|
|
305
|
+
},
|
|
306
|
+
UPDATE: {
|
|
307
|
+
TITLE: 'Update break',
|
|
308
|
+
SLUG: 'update_break',
|
|
309
|
+
DESCRIPTION: 'Update break',
|
|
310
|
+
MODULE_ID: userModules.Breaks,
|
|
311
|
+
},
|
|
312
|
+
LIST: {
|
|
313
|
+
TITLE: 'List break',
|
|
314
|
+
SLUG: 'list_break',
|
|
315
|
+
DESCRIPTION: 'List break',
|
|
316
|
+
MODULE_ID: userModules.Breaks,
|
|
317
|
+
},
|
|
318
|
+
DELETE: {
|
|
319
|
+
TITLE: 'Delete break',
|
|
320
|
+
SLUG: 'delete_break',
|
|
321
|
+
DESCRIPTION: 'Delete break',
|
|
322
|
+
MODULE_ID: userModules.Breaks,
|
|
323
|
+
}
|
|
324
|
+
},
|
|
234
325
|
SETUP_MASTER: {
|
|
235
326
|
TITLE: 'Setup/Master',
|
|
236
327
|
SLUG: 'setup_master',
|
|
237
328
|
DESCRIPTION: 'Setup/Master',
|
|
238
329
|
MODULE_ID: userModules.SetupMaster,
|
|
239
330
|
},
|
|
240
|
-
PERMISSIONS: {
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
331
|
+
PERMISSIONS: {
|
|
332
|
+
ADD: {
|
|
333
|
+
TITLE: 'Add Permissions',
|
|
334
|
+
SLUG: 'create_permissions',
|
|
335
|
+
DESCRIPTION: 'Create Permissions',
|
|
336
|
+
MODULE_ID: userModules.Permissions,
|
|
337
|
+
},
|
|
338
|
+
EDIT: {
|
|
339
|
+
TITLE: 'Edit/Get Permissions',
|
|
340
|
+
SLUG: 'edit_permissions',
|
|
341
|
+
DESCRIPTION: 'Edit/Get Permissions',
|
|
342
|
+
MODULE_ID: userModules.Permissions,
|
|
343
|
+
},
|
|
344
|
+
UPDATE: {
|
|
345
|
+
TITLE: 'Update Permissions',
|
|
346
|
+
SLUG: 'update_permissions',
|
|
347
|
+
DESCRIPTION: 'Update Permissions',
|
|
348
|
+
MODULE_ID: userModules.Permissions,
|
|
349
|
+
},
|
|
350
|
+
LIST: {
|
|
351
|
+
TITLE: 'List Permissions',
|
|
352
|
+
SLUG: 'list_permissions',
|
|
353
|
+
DESCRIPTION: 'List Permissions',
|
|
354
|
+
MODULE_ID: userModules.Permissions,
|
|
355
|
+
},
|
|
356
|
+
DELETE: {
|
|
357
|
+
TITLE: 'Delete Permissions',
|
|
358
|
+
SLUG: 'delete_permissions',
|
|
359
|
+
DESCRIPTION: 'Delete Permissions',
|
|
360
|
+
MODULE_ID: userModules.Permissions,
|
|
361
|
+
}
|
|
245
362
|
},
|
|
246
363
|
DASHBOARD: {
|
|
247
364
|
ADMIN_DASHBOARD: {
|
|
@@ -406,6 +523,38 @@ export const Constants = {
|
|
|
406
523
|
DESCRIPTION: 'Export Client Data',
|
|
407
524
|
MODULE_ID: userModules.Clients,
|
|
408
525
|
},
|
|
526
|
+
DISPOSITIONS: {
|
|
527
|
+
ADD: {
|
|
528
|
+
TITLE: 'Add Client Dispositions',
|
|
529
|
+
SLUG: 'create_client_dispositions',
|
|
530
|
+
DESCRIPTION: 'Create Client Dispositions',
|
|
531
|
+
MODULE_ID: userModules.ClientDispositions,
|
|
532
|
+
},
|
|
533
|
+
EDIT: {
|
|
534
|
+
TITLE: 'Edit Client Dispositions',
|
|
535
|
+
SLUG: 'edit_client_dispositions',
|
|
536
|
+
DESCRIPTION: 'Edit Client Dispositions',
|
|
537
|
+
MODULE_ID: userModules.ClientDispositions,
|
|
538
|
+
},
|
|
539
|
+
UPDATE: {
|
|
540
|
+
TITLE: 'Update Client Dispositions',
|
|
541
|
+
SLUG: 'update_client_dispositions',
|
|
542
|
+
DESCRIPTION: 'Update Client Dispositions',
|
|
543
|
+
MODULE_ID: userModules.ClientDispositions,
|
|
544
|
+
},
|
|
545
|
+
LIST: {
|
|
546
|
+
TITLE: 'List Client Dispositions',
|
|
547
|
+
SLUG: 'list_client_dispositions',
|
|
548
|
+
DESCRIPTION: 'List Client Dispositions',
|
|
549
|
+
MODULE_ID: userModules.ClientDispositions,
|
|
550
|
+
},
|
|
551
|
+
DELETE: {
|
|
552
|
+
TITLE: 'Delete Client Dispositions',
|
|
553
|
+
SLUG: 'delete_client_dispositions',
|
|
554
|
+
DESCRIPTION: 'Delete Client Dispositions',
|
|
555
|
+
MODULE_ID: userModules.ClientDispositions,
|
|
556
|
+
}
|
|
557
|
+
}
|
|
409
558
|
},
|
|
410
559
|
CAMPAIGN: {
|
|
411
560
|
LIST: {
|
|
@@ -482,6 +631,12 @@ export const Constants = {
|
|
|
482
631
|
DESCRIPTION: 'Export Portfolio Data',
|
|
483
632
|
MODULE_ID: userModules.Portfolio,
|
|
484
633
|
},
|
|
634
|
+
UPDATE: {
|
|
635
|
+
TITLE: 'Update Portfolio',
|
|
636
|
+
SLUG: 'update_portfolio',
|
|
637
|
+
DESCRIPTION: 'Update Portfolio',
|
|
638
|
+
MODULE_ID: userModules.Portfolio,
|
|
639
|
+
},
|
|
485
640
|
},
|
|
486
641
|
TEMPLATE: {
|
|
487
642
|
LIST: {
|
|
@@ -658,12 +813,30 @@ export const Constants = {
|
|
|
658
813
|
}
|
|
659
814
|
},
|
|
660
815
|
SETTLEMENTS: {
|
|
816
|
+
ADD: {
|
|
817
|
+
TITLE: 'Add Settlements',
|
|
818
|
+
SLUG: 'add_settlements',
|
|
819
|
+
DESCRIPTION: 'Add Settlements',
|
|
820
|
+
MODULE_ID: userModules.AgentActivity,
|
|
821
|
+
},
|
|
822
|
+
EDIT: {
|
|
823
|
+
TITLE: 'Edit/Get Settlements',
|
|
824
|
+
SLUG: 'edit_settlements',
|
|
825
|
+
DESCRIPTION: 'Edit/Get Settlements',
|
|
826
|
+
MODULE_ID: userModules.AgentActivity,
|
|
827
|
+
},
|
|
661
828
|
LIST: {
|
|
662
829
|
TITLE: 'List Settlements',
|
|
663
830
|
SLUG: 'list_settlements',
|
|
664
831
|
DESCRIPTION: 'List Settlements',
|
|
665
832
|
MODULE_ID: userModules.AgentActivity,
|
|
666
833
|
},
|
|
834
|
+
UPDATE: {
|
|
835
|
+
TITLE: 'Update Settlements',
|
|
836
|
+
SLUG: 'update_settlements',
|
|
837
|
+
DESCRIPTION: 'Update Settlements',
|
|
838
|
+
MODULE_ID: userModules.AgentActivity,
|
|
839
|
+
},
|
|
667
840
|
EXPORT: {
|
|
668
841
|
TITLE: 'Export Settlements',
|
|
669
842
|
SLUG: 'export_settlements',
|
package/interfaces/index.d.ts
CHANGED
|
@@ -52,6 +52,8 @@ export * from './cdr';
|
|
|
52
52
|
export * from './paymentLinks';
|
|
53
53
|
export * from './clientDispositions';
|
|
54
54
|
export * from './common';
|
|
55
|
+
export * from './webhook';
|
|
56
|
+
export * from './userStatus';
|
|
55
57
|
import { ConnectionOptions, Dialect, ReplicationOptions } from 'sequelize/types';
|
|
56
58
|
export interface DBConnection extends ConnectionOptions {
|
|
57
59
|
host: string;
|
package/interfaces/index.js
CHANGED
|
@@ -55,3 +55,5 @@ tslib_1.__exportStar(require("./cdr"), exports);
|
|
|
55
55
|
tslib_1.__exportStar(require("./paymentLinks"), exports);
|
|
56
56
|
tslib_1.__exportStar(require("./clientDispositions"), exports);
|
|
57
57
|
tslib_1.__exportStar(require("./common"), exports);
|
|
58
|
+
tslib_1.__exportStar(require("./webhook"), exports);
|
|
59
|
+
tslib_1.__exportStar(require("./userStatus"), exports);
|
package/interfaces/index.ts
CHANGED
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
export interface IUserStatus {
|
|
2
|
+
id?: number;
|
|
3
|
+
userId: string;
|
|
4
|
+
status: string;
|
|
5
|
+
}
|
|
6
|
+
export interface IUserActivities {
|
|
7
|
+
userId: string;
|
|
8
|
+
userName: string;
|
|
9
|
+
loginHrs: string;
|
|
10
|
+
logoutHrs: string;
|
|
11
|
+
activeHrs: string;
|
|
12
|
+
avgLogin: string;
|
|
13
|
+
avgLogout: string;
|
|
14
|
+
}
|
|
15
|
+
export interface IUserActivitiesSearchData {
|
|
16
|
+
page?: number;
|
|
17
|
+
pageSize?: number;
|
|
18
|
+
searchStr?: string;
|
|
19
|
+
export?: boolean;
|
|
20
|
+
filter?: {
|
|
21
|
+
userId?: string;
|
|
22
|
+
fromDate?: string;
|
|
23
|
+
toDate?: string;
|
|
24
|
+
};
|
|
25
|
+
}
|
|
26
|
+
export interface IUserActivitiesRowsCount {
|
|
27
|
+
count: number;
|
|
28
|
+
rows: IUserActivities[];
|
|
29
|
+
}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
export interface IUserStatus {
|
|
2
|
+
id?: number;
|
|
3
|
+
userId: string;
|
|
4
|
+
status: string;
|
|
5
|
+
}
|
|
6
|
+
export interface IUserActivities {
|
|
7
|
+
userId: string;
|
|
8
|
+
userName: string;
|
|
9
|
+
loginHrs: string;
|
|
10
|
+
logoutHrs: string;
|
|
11
|
+
activeHrs: string;
|
|
12
|
+
avgLogin: string;
|
|
13
|
+
avgLogout: string;
|
|
14
|
+
}
|
|
15
|
+
export interface IUserActivitiesSearchData {
|
|
16
|
+
page?: number;
|
|
17
|
+
pageSize?: number;
|
|
18
|
+
searchStr?: string;
|
|
19
|
+
export?: boolean;
|
|
20
|
+
filter?: {
|
|
21
|
+
userId?: string;
|
|
22
|
+
fromDate?: string;
|
|
23
|
+
toDate?: string;
|
|
24
|
+
};
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
export interface IUserActivitiesRowsCount {
|
|
28
|
+
count: number;
|
|
29
|
+
rows: IUserActivities[];
|
|
30
|
+
}
|
|
31
|
+
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
export type EventType = 'agent' | 'call' | 'Campaign' | 'ivr';
|
|
2
|
+
export type AgentEventSubType = 'status-change';
|
|
3
|
+
export type AgentStatus = 'logged-in' | 'logged-out' | 'on-break' | 'on-call' | 'waiting' | 'wrap-up' | 'idle' | 'ringing';
|
|
4
|
+
export type CallEventSubType = 'call-initiate' | 'call-summary' | 'ivr-summary';
|
|
5
|
+
export interface IWebhookEvent {
|
|
6
|
+
type: EventType;
|
|
7
|
+
}
|
|
8
|
+
export interface IAgentWebhook extends IWebhookEvent {
|
|
9
|
+
subType: AgentEventSubType;
|
|
10
|
+
status: AgentStatus;
|
|
11
|
+
agentId: string;
|
|
12
|
+
campaignId?: string;
|
|
13
|
+
extension?: string;
|
|
14
|
+
}
|
|
15
|
+
export interface ICallWebhook extends IWebhookEvent {
|
|
16
|
+
subType: CallEventSubType;
|
|
17
|
+
}
|
|
18
|
+
export interface ICallInitiateWebhook extends ICallWebhook {
|
|
19
|
+
leadId: string;
|
|
20
|
+
campaignId: string;
|
|
21
|
+
agentId: string;
|
|
22
|
+
extension: string;
|
|
23
|
+
number: string;
|
|
24
|
+
callUid: string;
|
|
25
|
+
uId: string;
|
|
26
|
+
callDirection: string;
|
|
27
|
+
mode: string;
|
|
28
|
+
}
|
|
29
|
+
export interface ICallSummaryWebhook extends ICallInitiateWebhook {
|
|
30
|
+
recordingId: string;
|
|
31
|
+
status: string;
|
|
32
|
+
duration: number;
|
|
33
|
+
talkSec: number;
|
|
34
|
+
waitingSec: number;
|
|
35
|
+
startTime: string;
|
|
36
|
+
endTime: string;
|
|
37
|
+
mode: string;
|
|
38
|
+
}
|
|
39
|
+
export interface IHypertelCampaignStartStop {
|
|
40
|
+
id: string;
|
|
41
|
+
status: boolean;
|
|
42
|
+
}
|
|
43
|
+
export interface IHypertelCampaignResponse {
|
|
44
|
+
data: IHypertelCampaignList[];
|
|
45
|
+
}
|
|
46
|
+
export interface IHypertelCampaignList {
|
|
47
|
+
id: string;
|
|
48
|
+
name: string;
|
|
49
|
+
type: string;
|
|
50
|
+
status: string;
|
|
51
|
+
createdAt: string;
|
|
52
|
+
callCenter: {
|
|
53
|
+
callCenterQueueUuid: string;
|
|
54
|
+
queueExtension: string;
|
|
55
|
+
queueStrategy: string;
|
|
56
|
+
queueMaxWaitTime: string;
|
|
57
|
+
dialplanUuid: string;
|
|
58
|
+
};
|
|
59
|
+
agents: {
|
|
60
|
+
agentUuid: string;
|
|
61
|
+
agent: {
|
|
62
|
+
agentName: string;
|
|
63
|
+
agentId: string;
|
|
64
|
+
agentContact: string;
|
|
65
|
+
};
|
|
66
|
+
}[];
|
|
67
|
+
}
|
|
68
|
+
export interface IHypertelSwitchProcess {
|
|
69
|
+
processId: number;
|
|
70
|
+
}
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
export type EventType = 'agent' | 'call' | 'Campaign' | 'ivr';
|
|
2
|
+
export type AgentEventSubType = 'status-change';
|
|
3
|
+
export type AgentStatus = 'logged-in' | 'logged-out' | 'on-break' | 'on-call' | 'waiting' | 'wrap-up' | 'idle' | 'ringing';
|
|
4
|
+
|
|
5
|
+
export type CallEventSubType = 'call-initiate' | 'call-summary' | 'ivr-summary';
|
|
6
|
+
|
|
7
|
+
export interface IWebhookEvent {
|
|
8
|
+
type: EventType;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
export interface IAgentWebhook extends IWebhookEvent {
|
|
12
|
+
subType: AgentEventSubType;
|
|
13
|
+
status: AgentStatus;
|
|
14
|
+
agentId: string;
|
|
15
|
+
campaignId?: string; // * Not being used on cleardu / crm
|
|
16
|
+
extension?: string; // * Not being used on cleardu / crm
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
export interface ICallWebhook extends IWebhookEvent {
|
|
20
|
+
subType: CallEventSubType;
|
|
21
|
+
}
|
|
22
|
+
export interface ICallInitiateWebhook extends ICallWebhook {
|
|
23
|
+
leadId: string;
|
|
24
|
+
campaignId: string;
|
|
25
|
+
agentId: string;
|
|
26
|
+
extension: string;
|
|
27
|
+
number: string;
|
|
28
|
+
callUid: string;
|
|
29
|
+
uId: string;
|
|
30
|
+
callDirection: string;
|
|
31
|
+
mode: string
|
|
32
|
+
}
|
|
33
|
+
export interface ICallSummaryWebhook extends ICallInitiateWebhook {
|
|
34
|
+
recordingId: string;
|
|
35
|
+
status: string;
|
|
36
|
+
duration: number;
|
|
37
|
+
talkSec: number;
|
|
38
|
+
waitingSec: number;
|
|
39
|
+
startTime: string;
|
|
40
|
+
endTime: string;
|
|
41
|
+
mode: string;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
export interface IHypertelCampaignStartStop {
|
|
45
|
+
id: string;
|
|
46
|
+
status: boolean;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
export interface IHypertelCampaignResponse {
|
|
50
|
+
data: IHypertelCampaignList[];
|
|
51
|
+
}
|
|
52
|
+
export interface IHypertelCampaignList {
|
|
53
|
+
id: string;
|
|
54
|
+
name: string;
|
|
55
|
+
type: string;
|
|
56
|
+
status: string;
|
|
57
|
+
createdAt: string;
|
|
58
|
+
callCenter: {
|
|
59
|
+
callCenterQueueUuid: string;
|
|
60
|
+
queueExtension: string;
|
|
61
|
+
queueStrategy: string;
|
|
62
|
+
queueMaxWaitTime: string;
|
|
63
|
+
dialplanUuid: string;
|
|
64
|
+
};
|
|
65
|
+
agents: {
|
|
66
|
+
agentUuid: string;
|
|
67
|
+
agent: {
|
|
68
|
+
agentName: string;
|
|
69
|
+
agentId: string;
|
|
70
|
+
agentContact: string;
|
|
71
|
+
};
|
|
72
|
+
}[];
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
export interface IHypertelSwitchProcess {
|
|
76
|
+
processId: number;
|
|
77
|
+
}
|