o2g-node-sdk 1.0.0

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 (103) hide show
  1. package/README.md +10 -0
  2. package/dist/ErrorInfo.d.ts +87 -0
  3. package/dist/host.d.ts +17 -0
  4. package/dist/o2g-analytics.d.ts +66 -0
  5. package/dist/o2g-cc-agent.d.ts +247 -0
  6. package/dist/o2g-cc-mngt.d.ts +32 -0
  7. package/dist/o2g-cc-pilot.d.ts +42 -0
  8. package/dist/o2g-comlog.d.ts +173 -0
  9. package/dist/o2g-directory.d.ts +88 -0
  10. package/dist/o2g-eventSummary.d.ts +33 -0
  11. package/dist/o2g-maint.d.ts +48 -0
  12. package/dist/o2g-messaging.d.ts +115 -0
  13. package/dist/o2g-node-sdk.d.ts +159 -0
  14. package/dist/o2g-node-sdk.js +2 -0
  15. package/dist/o2g-node-sdk.js.map +1 -0
  16. package/dist/o2g-pbx-mngt.d.ts +146 -0
  17. package/dist/o2g-phone-set-prog.d.ts +29 -0
  18. package/dist/o2g-routing.d.ts +267 -0
  19. package/dist/o2g-rsi.d.ts +160 -0
  20. package/dist/o2g-telephony.d.ts +795 -0
  21. package/dist/o2g-user-mngt.d.ts +42 -0
  22. package/dist/o2g-users.d.ts +85 -0
  23. package/dist/subscription.d.ts +258 -0
  24. package/dist/types/analytics/call-type.d.ts +24 -0
  25. package/dist/types/analytics/charging-file.d.ts +27 -0
  26. package/dist/types/analytics/charging-result.d.ts +43 -0
  27. package/dist/types/analytics/charging.d.ts +105 -0
  28. package/dist/types/analytics/incident.d.ts +46 -0
  29. package/dist/types/analytics/tel-facility.d.ts +44 -0
  30. package/dist/types/analytics/time-range.d.ts +22 -0
  31. package/dist/types/cc-agent/cc-agent-events.d.ts +54 -0
  32. package/dist/types/cc-agent/cc-agent-types.d.ts +71 -0
  33. package/dist/types/cc-agent/intrusion-mode.d.ts +24 -0
  34. package/dist/types/cc-agent/operator-dyn-state.d.ts +56 -0
  35. package/dist/types/cc-agent/operator-main-state.d.ts +21 -0
  36. package/dist/types/cc-agent/operator-type.d.ts +16 -0
  37. package/dist/types/cc-mngt/calendar/abstract-calendar.d.ts +7 -0
  38. package/dist/types/cc-mngt/calendar/calendar.d.ts +19 -0
  39. package/dist/types/cc-mngt/calendar/day-of-week.d.ts +33 -0
  40. package/dist/types/cc-mngt/calendar/exception-calendar.d.ts +26 -0
  41. package/dist/types/cc-mngt/calendar/normal-calendar.d.ts +27 -0
  42. package/dist/types/cc-mngt/calendar/transition.d.ts +49 -0
  43. package/dist/types/cc-mngt/cc-mngt-types.d.ts +0 -0
  44. package/dist/types/cc-mngt/pilot-rule-set.d.ts +27 -0
  45. package/dist/types/cc-mngt/pilot-rule.d.ts +14 -0
  46. package/dist/types/cc-mngt/pilot.d.ts +56 -0
  47. package/dist/types/cc-pilot/cc-pilot-events.d.ts +111 -0
  48. package/dist/types/comlog/com-record.d.ts +51 -0
  49. package/dist/types/comlog/comlog-events.d.ts +74 -0
  50. package/dist/types/comlog/comlog-types.d.ts +131 -0
  51. package/dist/types/comlog/option.d.ts +23 -0
  52. package/dist/types/comlog/page.d.ts +33 -0
  53. package/dist/types/comlog/query-filter.d.ts +44 -0
  54. package/dist/types/comlog/query-result.d.ts +27 -0
  55. package/dist/types/comlog/reason.d.ts +61 -0
  56. package/dist/types/comlog/role.d.ts +17 -0
  57. package/dist/types/common/common-types.d.ts +78 -0
  58. package/dist/types/directory/criteria.d.ts +90 -0
  59. package/dist/types/directory/directory-types.d.ts +44 -0
  60. package/dist/types/directory/filter-item.d.ts +21 -0
  61. package/dist/types/directory/operation-filter.d.ts +21 -0
  62. package/dist/types/events/events.d.ts +54 -0
  63. package/dist/types/eventsummary/event-summary-counter.d.ts +44 -0
  64. package/dist/types/eventsummary/event-summary-events.d.ts +15 -0
  65. package/dist/types/maint/maint-events.d.ts +51 -0
  66. package/dist/types/maint/maint-types.d.ts +162 -0
  67. package/dist/types/messaging/messaging-types.d.ts +120 -0
  68. package/dist/types/pbxmngt/attribute-filter.d.ts +30 -0
  69. package/dist/types/pbxmngt/attribute-type.d.ts +34 -0
  70. package/dist/types/pbxmngt/filter.d.ts +46 -0
  71. package/dist/types/pbxmngt/model.d.ts +63 -0
  72. package/dist/types/pbxmngt/pbx-attr-map.d.ts +91 -0
  73. package/dist/types/pbxmngt/pbx-attribute.d.ts +87 -0
  74. package/dist/types/pbxmngt/pbx-object.d.ts +45 -0
  75. package/dist/types/pbxmngt/pbxmngt-events.d.ts +59 -0
  76. package/dist/types/pbxmngt/pbxmngt-types.d.ts +14 -0
  77. package/dist/types/phoneset/device-key.d.ts +27 -0
  78. package/dist/types/phoneset/phoneset-types.d.ts +17 -0
  79. package/dist/types/phoneset/pin-control.d.ts +21 -0
  80. package/dist/types/phoneset/pin.d.ts +50 -0
  81. package/dist/types/phoneset/programmable-key.d.ts +23 -0
  82. package/dist/types/phoneset/softkey.d.ts +17 -0
  83. package/dist/types/routing/destination.d.ts +19 -0
  84. package/dist/types/routing/forward.d.ts +51 -0
  85. package/dist/types/routing/overflow.d.ts +42 -0
  86. package/dist/types/routing/routing-capability.d.ts +31 -0
  87. package/dist/types/routing/routing-events.d.ts +15 -0
  88. package/dist/types/routing/routing-state.d.ts +67 -0
  89. package/dist/types/routing/routing-types.d.ts +10 -0
  90. package/dist/types/rsi/add-digit-coll-criteria.d.ts +16 -0
  91. package/dist/types/rsi/collection-cause.d.ts +21 -0
  92. package/dist/types/rsi/routing-caller-type.d.ts +17 -0
  93. package/dist/types/rsi/routing-reason.d.ts +25 -0
  94. package/dist/types/rsi/rsi-events.d.ts +76 -0
  95. package/dist/types/rsi/rsi-types.d.ts +49 -0
  96. package/dist/types/rsi/tones.d.ts +25 -0
  97. package/dist/types/telephony/RecordingAction.d.ts +6 -0
  98. package/dist/types/telephony/acr-skill.d.ts +29 -0
  99. package/dist/types/telephony/telephony-events.d.ts +292 -0
  100. package/dist/types/telephony/telephony-types.d.ts +587 -0
  101. package/dist/types/users/users-events.d.ts +33 -0
  102. package/dist/types/users/users-types.d.ts +129 -0
  103. package/package.json +33 -0
@@ -0,0 +1,42 @@
1
+ import UserManagementRest from "./internal/rest/user-mngt-rest";
2
+ import { User } from "./types/users/users-types";
3
+ /**
4
+ * The User Management service allows an administrator to create/delete/get the O2G users.
5
+ */
6
+ export declare class UserManagement {
7
+ private readonly _userManagementRest;
8
+ /**
9
+ *
10
+ * @internal
11
+ */
12
+ constructor(userManagementRest: UserManagementRest);
13
+ /**
14
+ * Retrieves a list of users login from the connected OXEs.
15
+ * <p>
16
+ * if 'nodeIds' is 'null', retrieves the login of users from all the
17
+ * connected OmniPCX Enterprise nodes.
18
+ *
19
+ * @param nodeIds Specify a list of OXE nodes Id in which the query is done.
20
+ * This parameter is only valid for an administrator session.
21
+ */
22
+ getLogins(nodeIds?: number[] | null): Promise<string[] | null>;
23
+ /**
24
+ * Retrieves the information on a user from one of its device.
25
+ *
26
+ * @param deviceNumber the user device
27
+ */
28
+ getByDeviceNumber(deviceNumber: string): Promise<string | null>;
29
+ /**
30
+ * Create O2G users on demand.
31
+ * @param nodeId the OXE node number
32
+ * @param deviceNumbers collection of device phone numbers corresponding to the users to be created. If deviceNumbers is null or empty, all the users of the specified node are created.
33
+ */
34
+ createUsers(nodeId: number, deviceNumbers: string[] | null): Promise<boolean>;
35
+ /**
36
+ * Retrieves the information on a user from its login.
37
+ *
38
+ * @param loginName the user login name
39
+ */
40
+ getByLoginName(loginName: string): Promise<User | null>;
41
+ deleteUser(loginName: string): Promise<boolean>;
42
+ }
@@ -0,0 +1,85 @@
1
+ import EventEmitter from "events";
2
+ import UsersRest from "./internal/rest/users-rest";
3
+ import { Preferences, SupportedLanguages, User } from "./types/users/users-types";
4
+ import { EventRegistry } from "./internal/events/event-dispatcher";
5
+ /**
6
+ * The User service allows:
7
+ * <ul>
8
+ * <li>an administrator to retrieve the list of O2G users.
9
+ * <li>a user to get information on another user account.
10
+ * <li>a user to change its password or some parameter like supported language.
11
+ * </ul>
12
+ */
13
+ export declare class Users extends EventEmitter {
14
+ private readonly _usersRest;
15
+ /**
16
+ * Raised on creation of an user.
17
+ * @event
18
+ */
19
+ static readonly ON_USER_CREATED = "OnUserCreated";
20
+ /**
21
+ * Raised when user is deleted.
22
+ * @event
23
+ */
24
+ static readonly ON_USER_DELETED = "OnUserDeleted";
25
+ /**
26
+ * Raised on any change on the user's data.
27
+ * @event
28
+ */
29
+ static readonly ON_USER_INFO_CHANGED = "OnUserInfoChanged";
30
+ /**
31
+ *
32
+ * @internal
33
+ */
34
+ constructor(_usersRest: UsersRest, eventRegistry: EventRegistry);
35
+ /**
36
+ * Retrieves a list of users login from the connected OXEs.
37
+ * <p>
38
+ * if 'nodeIds' is 'null', retrieves the login of users from all the
39
+ * connected OmniPCX Enterprise nodes. This method is generally used by an
40
+ * administrator. if it is used by a user, 'nodeIds' must be set to
41
+ * 'null' and 'onlyACD' to 'false'. In this case only the user login
42
+ * is retrieved.
43
+ *
44
+ * @param nodeIds Specify a list of OXE nodes Id in which the query is done.
45
+ * This parameter is only valid for an administrator session.
46
+ * @param onlyACD Allows to select only the ACD operators (agents or
47
+ * supervisors) during the query. This parameter is only valid
48
+ * for an administrator session.
49
+ * @param onlyWithExtLogin Allow to select only the user with an external login during the query. This parameter is only valid
50
+ * for an administrator session.
51
+ */
52
+ getLogins(nodeIds?: number[] | null, onlyACD?: boolean, onlyWithExtLogin?: boolean): Promise<string[] | null>;
53
+ /**
54
+ * Retrieves the information on a user from its login.
55
+ *
56
+ * @param loginName the user login name
57
+ */
58
+ getByLoginName(loginName: string): Promise<User | null>;
59
+ /**
60
+ * Retrieves the information on a user from its company extension umber.
61
+ *
62
+ * @param companyPhone the user extension number
63
+ */
64
+ getByCompanyPhone(companyPhone: string): Promise<User | null>;
65
+ /**
66
+ * Returns the specified user supported languages.
67
+ *
68
+ * @param loginName the user login name
69
+ */
70
+ getSupportedLanguages(loginName: string): Promise<SupportedLanguages | null>;
71
+ /**
72
+ * Returns the preference of the specified user.
73
+ *
74
+ * @param loginName the user login name
75
+ */
76
+ getPreferences(loginName: string): Promise<Preferences | null>;
77
+ /**
78
+ * Changes the specified user password.
79
+ *
80
+ * @param loginName the user login name
81
+ * @param oldPassword the old password
82
+ * @param newPassword the new password
83
+ */
84
+ changePassword(loginName: string, oldPassword: string, newPassword: string): Promise<boolean>;
85
+ }
@@ -0,0 +1,258 @@
1
+ import { EventDispatcher } from "./internal/events/event-dispatcher";
2
+ import { EventPackage } from "./internal/events/event-packages";
3
+ declare class EventFilter {
4
+ private selectors;
5
+ constructor();
6
+ add(ids: string[], name: string[]): void;
7
+ addPackage(ids: string[], eventPackage: EventPackage): void;
8
+ }
9
+ /**
10
+ * interface webhook is used when eventing is received via webhook
11
+ * This object is passed to the O2G SDK, the connectDispatcher is called by the O2G SDK.
12
+ */
13
+ export interface WebHook {
14
+ /**
15
+ * The url for the web hook
16
+ */
17
+ url: string;
18
+ /**
19
+ * The connect callback
20
+ * @param dispatcher
21
+ */
22
+ connectDispatcher: (dispatcher: EventDispatcher) => void;
23
+ }
24
+ /**
25
+ * A builder of {@link Subscription}.
26
+ *
27
+ * <p>
28
+ * An instance of Builder can be gotten with {@link Subscription.Builder}.
29
+ * <p>
30
+ * The builder can be used to configure an event subscription for the O2G
31
+ * server. Each methods modifies the state of the builder and returns the same
32
+ * instance. The {@link build} method returns a new Subscription each time it is invoked.
33
+ * @example
34
+ * ```typescript
35
+ * let subscription = Subscription.Builder
36
+ * .addRoutingEvents()
37
+ * .addTelephonyEvents()
38
+ * .addEventSummaryEvents()
39
+ * .setTimeout(10)
40
+ * .build();
41
+ *
42
+ * ```
43
+ */
44
+ export interface Builder {
45
+ /**
46
+ * Adds routing events to the subscription.
47
+ * <p>The following event associated to the {@link Routing} service is added to the subscription:
48
+ * <ul>
49
+ * <li>{@link Routing.ON_ROUTING_STATE_CHANGED}</li>
50
+ * </ul>
51
+ * <p>If the session has been opened for a user, the 'ids' parameter is
52
+ * ignored, but it is mandatory if the session has been opened by an
53
+ * administrator.
54
+ * <p>Subscribing to the routing events requires having a <b>TELEPHONY_ADVANCED</b> license.
55
+ * @param ids the ids to filter events on.
56
+ */
57
+ addRoutingEvents: (ids: string[]) => Builder;
58
+ /**
59
+ * Adds telephony events to the subscription.
60
+ * <p>The following event associated to the {@link Telephony} service is added to the subscription:
61
+ * <ul>
62
+ * <li>{@link Telephony.ON_TELEPHONY_STATE}</li>
63
+ * <li>{@link Telephony.ON_CALL_CREATED}</li>
64
+ * <li>{@link Telephony.ON_CALL_MODIFIED}</li>
65
+ * <li>{@link Telephony.ON_CALL_REMOVED}</li>
66
+ * <li>{@link Telephony.ON_USER_STATE_MODIFIED}</li>
67
+ * <li>{@link Telephony.ON_DEVICE_STATE_MODIFIED}</li>
68
+ * </ul>
69
+ * <p>If the session has been opened for a user, the 'ids' parameter is
70
+ * ignored, but it is mandatory if the session has been opened by an
71
+ * administrator.
72
+ * <p>Subscribing to the telephony events requires having a <b>TELEPHONY_ADVANCED</b> license.
73
+ * @param ids the ids to filter events on.
74
+ */
75
+ addTelephonyEvents: (ids: string[]) => Builder;
76
+ /**
77
+ * Adds user management events to the subscription.
78
+ * <p>The following event associated to the {@link Users} service is added to the subscription:
79
+ * <ul>
80
+ * <li>{@link Users.ON_USER_CREATED}</li>
81
+ * <li>{@link Users.ON_USER_DELETED}</li>
82
+ * </ul>
83
+ * <p>The session must has been opened by an administrator.
84
+ * <p>Subscribing to the user management events does not require any license.
85
+ */
86
+ addUsersManagementEvents: () => Builder;
87
+ /**
88
+ * Adds event summary events to the subscription.
89
+ * <p>The following event associated to the {@link EventSummary} service is added to the subscription:
90
+ * <ul>
91
+ * <li>{@link EventSummary.ON_EVENT_SUMMARY_UPDATED}</li>
92
+ * </ul>
93
+ * <p>If the session has been opened for a user, the 'ids' parameter is
94
+ * ignored, but it is mandatory if the session has been opened by an
95
+ * administrator.
96
+ * <p>Subscribing to the event summary events requires having a <b>TELEPHONY_ADVANCED</b> license.
97
+ * @param ids the ids to filter events on.
98
+ */
99
+ addEventSummaryEvents: (ids: string[]) => Builder;
100
+ /**
101
+ * Adds rsi events to the subscription.
102
+ * <p>The following event associated to the {@link Rsi} service is added to the subscription:
103
+ * <ul>
104
+ * <li>{@link Rsi.ON_DIGIT_COLLECTED}</li>
105
+ * <li>{@link Rsi.ON_TONE_GENERATED_START}</li>
106
+ * <li>{@link Rsi.ON_TONE_GENERATED_STOP}</li>
107
+ * <li>{@link Rsi.ON_ROUTE_END}</li>
108
+ * <li>{@link Rsi.ON_ROUTE_REQUEST}</li>
109
+ * </ul>
110
+ * <p>The session must has been opened by an administrator.
111
+ * <p>Subscribing to the rsi events requires having a <b>CONTACTCENTER_RSI</b> license.
112
+ */
113
+ /**
114
+ * Adds pbx management events to the subscription.
115
+ * <p>The following event associated to the {@link PbxManagement} service is added to the subscription:
116
+ * <ul>
117
+ * <li>{@link PbxManagement.ON_PBX_OBJECT_INSTANCE_CREATED}</li>
118
+ * <li>{@link PbxManagement.ON_PBX_OBJECT_INSTANCE_DELETED}</li>
119
+ * <li>{@link PbxManagement.ON_PBX_OBJECT_INSTANCE_MODIFIED}</li>
120
+ * </ul>
121
+ * <p>The session must has been opened by an administrator.
122
+ * <p>Subscribing to the pbx management events requires having a <b>MANAGEMENT</b> license.
123
+ */
124
+ addPbxManagementEvents: () => Builder;
125
+ /**
126
+ * Adds communication log events to the subscription.
127
+ * <p>The following event associated to the {@link CommunicationLog} service is added to the subscription:
128
+ * <ul>
129
+ * <li>{@link CommunicationLog.ON_COM_RECORD_CREATED}</li>
130
+ * <li>{@link CommunicationLog.ON_COM_RECORD_MODIFIED}</li>
131
+ * <li>{@link CommunicationLog.ON_COM_RECORDS_DELETED}</li>
132
+ * <li>{@link CommunicationLog.ON_COM_RECORDS_ACK}</li>
133
+ * <li>{@link CommunicationLog.ON_COM_RECORDS_UNACK}</li>
134
+ * </ul>
135
+ * <p>If the session has been opened for a user, the 'ids' parameter is
136
+ * ignored, but it is mandatory if the session has been opened by an
137
+ * administrator.
138
+ * <p>Subscribing to the communication log events requires having a <b>TELEPHONY_ADVANCED</b> license.
139
+ * @param ids the ids to filter events on.
140
+ */
141
+ addCommunicationLogEvents: (ids: string[]) => Builder;
142
+ /**
143
+ * Adds call center agent events to the subscription.
144
+ * <p>The following event associated to the {@link CallCenterAgent} service is added to the subscription:
145
+ * <ul>
146
+ * <li>{@link CallCenterAgent.ON_AGENT_STATE_CHANGED}</li>
147
+ * <li>{@link CallCenterAgent.ON_AGENT_SKILL_CHANGED}</li>
148
+ * <li>{@link CallCenterAgent.ON_SUPERVISOR_HELP_REQUESTED}</li>
149
+ * <li>{@link CallCenterAgent.ON_SUPERVISOR_HELP_CANCELLED}</li>
150
+ * </ul>
151
+ * <p>If the session has been opened for a user, the 'ids' parameter is
152
+ * ignored, but it is mandatory if the session has been opened by an
153
+ * administrator.
154
+ * <p>Subscribing to the call center agent events requires having a <b>CONTACTCENTER_AGENT</b> license.
155
+ * @param ids the ids to filter events on.
156
+ */
157
+ addCallCenterAgentEvents: (ids: string[]) => Builder;
158
+ /**
159
+ * Adds call center pilot events to the subscription.
160
+ * <p>The following event associated to the {@link CallCenterPilot} service is added to the subscription:
161
+ * <ul>
162
+ * <li>{@link CallCenterPilot.ON_PILOT_CALL_CREATED}</li>
163
+ * <li>{@link CallCenterPilot.ON_PILOT_CALL_QUEUED}</li>
164
+ * <li>{@link CallCenterPilot.ON_PILOT_CALL_REMOVED}</li>
165
+ * </ul>
166
+ * <p>If the session has been opened for a user, the 'ids' parameter is
167
+ * ignored, but it is mandatory if the session has been opened by an
168
+ * administrator.
169
+ * <p>Subscribing to the call center pilot events requires having a <b>CONTACTCENTER_SVCS</b> license.
170
+ * @param ids the ids to filter events on.
171
+ */
172
+ addCallCenterPilotEvents: (ids: string[]) => Builder;
173
+ /**
174
+ * Adds maintenance events to the subscription.
175
+ * <p>The following event associated to the {@link Maintenance} service is added to the subscription:
176
+ * <ul>
177
+ * <li>{@link Maintenance.ON_CTI_LINK_DOWN}</li>
178
+ * <li>{@link Maintenance.ON_CTI_LINK_UP}</li>
179
+ * <li>{@link Maintenance.ON_PBX_LOADED}</li>
180
+ * </ul>
181
+ * <p>The session must has been opened by an administrator.
182
+ * <p>Subscribing to the maintenance events does not require any license.
183
+ */
184
+ addMaintenanceEvents: () => Builder;
185
+ /**
186
+ * Adds user events to the subscription.
187
+ * <p>The following event associated to the {@link Users} service is added to the subscription:
188
+ * <ul>
189
+ * <li>{@link Users.ON_USER_INFO_CHANGED}</li>
190
+ * </ul>
191
+ * <p>If the session has been opened for a user, the 'ids' parameter is
192
+ * ignored, but it is mandatory if the session has been opened by an
193
+ * administrator.
194
+ * <p>Subscribing to the user events does not require any license.
195
+ * @param ids the ids to filter events on.
196
+ */
197
+ addUserEvents: (ids: string[]) => Builder;
198
+ /**
199
+ * Set lifetime of the event channel.
200
+ * @param value The lifetime of the event channel in minutes
201
+ */
202
+ setTimeout: (value: number) => Builder;
203
+ /**
204
+ * Set the required event version. By default, the version "1.0" is used.
205
+ * @param value The event version
206
+ */
207
+ setVersion: (value: string) => Builder;
208
+ /**
209
+ *
210
+ * @param value Set the webhook URL to use for notification.
211
+ */
212
+ setWebHook: (webHook: WebHook) => Builder;
213
+ /**
214
+ * Build the subscription.
215
+ */
216
+ build: () => Subscription;
217
+ }
218
+ /**
219
+ * Subscription represents a subscription request used to subscribe events from the O2G Server.
220
+ * An application receives event on a http chunk connection established with the O2G server.
221
+ * <p>
222
+ * The application builds a subscription using the {@link Builder} object. This object provides a builder pattern that eases
223
+ * the creation of a subscription.
224
+ * @example
225
+ * To create a subscription, uses the methods provided by the Builder object.
226
+ * ```typescript
227
+ * let subscription = Subscription.Builder
228
+ * .addRoutingEvents()
229
+ * .addTelephonyEvents()
230
+ * .addEventSummaryEvents()
231
+ * .setTimeout(10)
232
+ * .build();
233
+ *
234
+ * ```
235
+ * @see {@link subscribe}
236
+ *
237
+ */
238
+ export declare abstract class Subscription {
239
+ private _timeout;
240
+ private _filter;
241
+ private _version;
242
+ private _webHook;
243
+ /**
244
+ * @internal
245
+ */
246
+ protected constructor(version: string, timeout: number, filter: EventFilter, webHook: WebHook | null);
247
+ get timeout(): number;
248
+ get version(): string;
249
+ get filter(): EventFilter;
250
+ get webHook(): WebHook | null;
251
+ /**
252
+ * The subscription builder to use to build a new Subscription.
253
+ * @example
254
+ * To create a subscription, uses the methods provided by the Builder object.
255
+ */
256
+ static Builder: Builder;
257
+ }
258
+ export {};
@@ -0,0 +1,24 @@
1
+ /**
2
+ * CallType represents the possible call types in a charging ticket.
3
+ */
4
+ export declare enum CallType {
5
+ PublicNetworkCall = "PublicNetworkCall",
6
+ PublicNetworkCallThroughPrivateNetwork = "PublicNetworkCallThroughPrivateNetwork",
7
+ PrivateNetworkCall = "PrivateNetworkCall",
8
+ LocalNetworkCall = "Local etworkCall",
9
+ PublicNetworkIncomingCall = "PublicNetwork IncomingCall",
10
+ PublicNetworkIncomingCallThroughPrivateNetwork = "PublicNetworkIncomingCallThroughPrivateNetwork",
11
+ Unspecified = "Unspecified",
12
+ PrivateNetworkOutgoingCallToPublicNetwork = "PrivateNetworkOutgoingCallToPublicNetwork",
13
+ PrivateNetworkOutgoingCallToPrivateNetwork = "PrivateNetworkOutgoingCallToPrivateNetwork",
14
+ PublicNetworkIncomingCallToPrivateNetwork = "PublicNetworkIncomingCallToPrivateNetwork",
15
+ PrivateNetworkIncomingCallToPrivateNetwork = "PrivateNetworkIncomingCallToPrivateNetwork",
16
+ PublicOrPrivateNetworkOutgoingCallThroughPrivateNetwork = "PublicOrPrivateNetworkOutgoingCallThroughPrivateNetwork",
17
+ PublicOrPrivateNetworkIncomingCallThroughPrivateNetwork = "PublicOrPrivateNetworkIncomingCallThroughPrivateNetwork",
18
+ PrivateNetworkIncomingCall = "PrivateNetworkIncomingCall",
19
+ LocalNode = "LocalNode",
20
+ LocalTransit = "LocalTransit"
21
+ }
22
+ export declare namespace CallType {
23
+ function isCallType(value: string): value is CallType;
24
+ }
@@ -0,0 +1,27 @@
1
+ import { O2GChargingFile } from "../../internal/types/analytics/o2ganalytics-types";
2
+ /**
3
+ * ChargingFile class represent a charging file on OmniPCX Enterprise.
4
+ * @see {@link Analytics.getChargingFiles}
5
+ */
6
+ export declare class ChargingFile {
7
+ private _name;
8
+ private _date;
9
+ /**
10
+ * @internal
11
+ */
12
+ constructor();
13
+ /**
14
+ * Returns the file name.
15
+ */
16
+ get name(): string;
17
+ /**
18
+ * Returns this file timestamp.
19
+ */
20
+ get timestamp(): Date;
21
+ /**
22
+ * @ignore
23
+ */
24
+ static build(o2gChargingFile: O2GChargingFile): ChargingFile;
25
+ private static _makeIsoDate;
26
+ private static _makeDate;
27
+ }
@@ -0,0 +1,43 @@
1
+ import { O2GChargingResult } from "../../internal/types/analytics/o2ganalytics-types";
2
+ import { Charging } from "./charging";
3
+ import { TimeRange } from "./time-range";
4
+ /**
5
+ * ChargingResult class represents the result of a charging query to the OmniPCX Enterprise.
6
+ * The query can be done from a list of {@link ChargingFile}, or using a {@link TimeRange} to specified the time interval.
7
+ * @see {@link Analytics.getChargingsFromFiles} and {@link Analytics.getChargingsFromFilter}
8
+ */
9
+ export declare class ChargingResult {
10
+ private _chargings;
11
+ private _chargingFileCount;
12
+ private _totalTicketCount;
13
+ private _valuableTicketCount;
14
+ private _range;
15
+ /**
16
+ * @internal
17
+ */
18
+ constructor();
19
+ /**
20
+ * Returns the list of charging elements.
21
+ */
22
+ get chargings(): Charging[];
23
+ /**
24
+ * Returns the range that has been specified to query this result.
25
+ */
26
+ get range(): TimeRange;
27
+ /**
28
+ * Returns the number of analysed charging files in the OmniPCX Enterprise.
29
+ */
30
+ get count(): number;
31
+ /**
32
+ * Returns the total number of analysed tickets.
33
+ */
34
+ get totalTicketCount(): number;
35
+ /**
36
+ * Returns the total number of valuable tickets; tickets with a non zero cost.
37
+ */
38
+ get valuableTicketCount(): number;
39
+ /**
40
+ * @ignore
41
+ */
42
+ static build(o2gChargingResult: O2GChargingResult, range?: TimeRange | null): ChargingResult;
43
+ }
@@ -0,0 +1,105 @@
1
+ import { O2GCharging } from "../../internal/types/analytics/o2ganalytics-types";
2
+ import { CallType } from "./call-type";
3
+ import { TelFacility } from "./tel-facility";
4
+ /**
5
+ * Charging represents a charging information.
6
+ */
7
+ export declare class Charging {
8
+ private _caller;
9
+ private _name;
10
+ private _called;
11
+ private _initialDialedNumber;
12
+ private _callNumber;
13
+ private _chargingUnits;
14
+ private _cost;
15
+ private _startDate;
16
+ private _duration;
17
+ private _callType;
18
+ private _effectiveCallDuration;
19
+ private _actingExtensionNumberNode;
20
+ private _internalFacilities;
21
+ private _externalFacilities;
22
+ /**
23
+ * @internal
24
+ */
25
+ constructor();
26
+ /**
27
+ * Returns the caller phone number.
28
+ */
29
+ get caller(): string;
30
+ /**
31
+ * Returns the caller name.
32
+ */
33
+ get name(): string;
34
+ /**
35
+ * Returns the called phone number.
36
+ */
37
+ get called(): string;
38
+ /**
39
+ * Returns the initial dialed number.
40
+ * <p>
41
+ * This information is provided only if the query has been done with the 'all' option.
42
+ * @see {@link Analytics.getChargings}.
43
+ */
44
+ get initialDialedNumber(): string;
45
+ /**
46
+ * Returns the number of charged calls.
47
+ * <p>
48
+ * This information is provided only if the query has been done with the 'all' option.
49
+ * @see {@link Analytics.getChargings}.
50
+ */
51
+ get callNumber(): number;
52
+ /**
53
+ * Returns the number of charged units.
54
+ * <p>
55
+ * This information is provided only if the query has been done with the 'all' option.
56
+ * @see {@link Analytics.getChargings}.
57
+ */
58
+ get chargingUnits(): number;
59
+ /**
60
+ * Returns the call charging cost.
61
+ * <p>
62
+ * This information is provided only if the query has been done with the 'all' option.
63
+ * @see {@link Analytics.getChargings}.
64
+ */
65
+ get cost(): number;
66
+ /**
67
+ * Returns the call start date.
68
+ * <p>
69
+ * This information is provided only if the query has been done with the 'all' option.
70
+ * @see {@link Analytics.getChargings}.
71
+ */
72
+ get startDate(): Date;
73
+ /**
74
+ * Returns the call duration.
75
+ */
76
+ get duration(): number;
77
+ /**
78
+ * Returns the call type.
79
+ * <p>
80
+ * This information is provided only if the query has been done with the 'all' option.
81
+ * @see {@link Analytics.getChargings}.
82
+ */
83
+ get callType(): CallType;
84
+ /**
85
+ * Returns the effective call duration.
86
+ */
87
+ get effectiveCallDuration(): number;
88
+ /**
89
+ * Returns the acting extension node number.
90
+ */
91
+ get actingExtensionNumberNode(): number;
92
+ /**
93
+ * Return the internal facilities.
94
+ */
95
+ get internalFacilities(): TelFacility[];
96
+ /**
97
+ * Return the external facilities.
98
+ */
99
+ get externalFacilities(): TelFacility[];
100
+ /**
101
+ * @ignore
102
+ */
103
+ static build(o2gCharging: O2GCharging): Charging;
104
+ private static _makeDate;
105
+ }
@@ -0,0 +1,46 @@
1
+ import { O2GIncident } from "../../internal/types/analytics/o2ganalytics-types";
2
+ export declare class Incident {
3
+ private _id;
4
+ private _severity;
5
+ private _description;
6
+ private _nbOccurs;
7
+ private _node;
8
+ private _main;
9
+ private _rack;
10
+ private _board;
11
+ private _equipment;
12
+ private _termination;
13
+ private _date;
14
+ /**
15
+ * @internal
16
+ */
17
+ private constructor();
18
+ /** Returns the incident identifier. */
19
+ get id(): number;
20
+ /** Returns the date the incident has been raised. */
21
+ get date(): Date;
22
+ /** Returns the incident severity. */
23
+ get severity(): number;
24
+ /** Returns the textual description of this incident. */
25
+ get description(): string;
26
+ /** Returns the number of occurrences of this incident. */
27
+ get nbOccurs(): number;
28
+ /** Returns the OmniPCX Enterprise node on which this incident has been raised. */
29
+ get node(): number;
30
+ /** Returns whether this incident has been raised on the main call server. */
31
+ get main(): boolean;
32
+ /** Returns the rack related to this incident. */
33
+ get rack(): string;
34
+ /** Returns the board related to this incident. */
35
+ get board(): string;
36
+ /** Returns the equipment related to this incident. */
37
+ get equipment(): string;
38
+ /** Returns the termination related to this incident. */
39
+ get termination(): string;
40
+ /**
41
+ * @ignore
42
+ */
43
+ static build(o2gIncident: O2GIncident): Incident;
44
+ private static _makeIsoDate;
45
+ private static _makeDate;
46
+ }
@@ -0,0 +1,44 @@
1
+ /**
2
+ * TelFacility represents the telephonic facilities.
3
+ */
4
+ export declare enum TelFacility {
5
+ CallingLineIdentificationPresentation = "CallingLineIdentificationPresentation",
6
+ ConnectedLineIdentificationPresentation = "ConnectedLineIdentificationPresentation",
7
+ CallingLineIdentificationRestriction = "CallingLineIdentificationRestriction",
8
+ ConnectedLineIdentificationRestriction = "ConnectedLineIdentificationRestriction",
9
+ MaliciousCallIdentification = "MaliciousCallIdentification",
10
+ CallForwardingUnconditional = "CallForwardingUnconditional",
11
+ CallForwardingOnBusy = "CallForwardingOnBusy",
12
+ CallForwardingOnNoReply = "CallForwardingOnNoReply",
13
+ Transfer = "Transfer",
14
+ AdviceOfChargeAtSetup = "AdviceOfChargeAtSetup",
15
+ AdviceOfChargeDuringCall = "AdviceOfChargeDuringCall",
16
+ AdviceOfChargeAtEnd = "AdviceOfChargeAtEnd",
17
+ ClosedUserGroup = "ClosedUserGroup",
18
+ CallWaiting = "CallWaiting",
19
+ UserToUserSignalling = "UserToUserSignalling",
20
+ UserToUserFacility = "UserToUserFacility",
21
+ TerminalPortability = "TerminalPortability",
22
+ Interception = "Interception",
23
+ Booking = "Booking",
24
+ CampOn = "CampOn",
25
+ Conference = "Conference",
26
+ MiniMessaging = "MiniMessaging",
27
+ Subaddressing = "Subaddressing",
28
+ BasicCall = "BasicCall",
29
+ OperatorFacility = "OperatorFacility",
30
+ Substitution = "Substitution",
31
+ PriorityIncomingCall = "PriorityIncomingCall",
32
+ Transit = "Transit",
33
+ PrivateOverflowToPublic = "PrivateOverflowToPublic",
34
+ ReroutingPublicToPrivate = "ReroutingPublicToPrivate",
35
+ FaxServer = "FaxServer",
36
+ VoiceMail = "VoiceMail",
37
+ CentralAbbreviatedNumbering = "CentralAbbreviatedNumbering",
38
+ IndividualAbbreviatedNumbering = "IndividualAbbreviatedNumbering",
39
+ IntegratedServiceVirtualPrivateNetwork = "IntegratedServiceVirtualPrivateNetwork",
40
+ OverflowVirtualPrivateNetwork = "OverflowVirtualPrivateNetwork",
41
+ ARSService = "ARSService",
42
+ DISA = "DISA",
43
+ None = "None"
44
+ }