@webex/contact-center 3.11.0 → 3.12.0-auth-prejoin-fetch.1

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 (325) hide show
  1. package/.sdd/manifest.json +883 -0
  2. package/AGENTS.md +94 -0
  3. package/ai-docs/ARCHITECTURE.md +168 -0
  4. package/ai-docs/CONTRACTS.md +50 -0
  5. package/ai-docs/GETTING_STARTED.md +168 -0
  6. package/ai-docs/GLOSSARY.md +43 -0
  7. package/ai-docs/README.md +138 -0
  8. package/ai-docs/REVIEW_CHECKLIST.md +41 -0
  9. package/ai-docs/RULES.md +444 -0
  10. package/ai-docs/SECURITY.md +52 -0
  11. package/ai-docs/SERVICE_STATE.md +48 -0
  12. package/ai-docs/SPEC_INDEX.md +65 -0
  13. package/ai-docs/adr/0001-spec-source-policy.md +55 -0
  14. package/ai-docs/adr/README.md +8 -0
  15. package/ai-docs/adr/_adr-template.md +31 -0
  16. package/ai-docs/contact-center-spec.md +359 -0
  17. package/ai-docs/features/consult-transfer-list-policy/spec/feature-spec.md +362 -0
  18. package/ai-docs/features/generated-spec-conformance-fidelity-remediation/spec/feature-spec.md +117 -0
  19. package/ai-docs/features/residual-warning-coverage-completion/spec/feature-spec.md +203 -0
  20. package/ai-docs/features/validator-code-fidelity-drift-fix/spec/feature-spec.md +315 -0
  21. package/ai-docs/patterns/event-driven-patterns.md +485 -0
  22. package/ai-docs/patterns/testing-patterns.md +480 -0
  23. package/ai-docs/patterns/typescript-patterns.md +365 -0
  24. package/ai-docs/templates/README.md +102 -0
  25. package/ai-docs/templates/documentation/create-agents-md.md +240 -0
  26. package/ai-docs/templates/documentation/create-architecture-md.md +295 -0
  27. package/ai-docs/templates/existing-service/bug-fix.md +254 -0
  28. package/ai-docs/templates/existing-service/feature-enhancement.md +450 -0
  29. package/ai-docs/templates/new-method/00-master.md +80 -0
  30. package/ai-docs/templates/new-method/01-requirements.md +232 -0
  31. package/ai-docs/templates/new-method/02-implementation.md +295 -0
  32. package/ai-docs/templates/new-method/03-tests.md +201 -0
  33. package/ai-docs/templates/new-method/04-validation.md +141 -0
  34. package/ai-docs/templates/new-service/00-master.md +109 -0
  35. package/ai-docs/templates/new-service/01-pre-questions.md +159 -0
  36. package/ai-docs/templates/new-service/02-code-generation.md +346 -0
  37. package/ai-docs/templates/new-service/03-integration.md +178 -0
  38. package/ai-docs/templates/new-service/04-test-generation.md +205 -0
  39. package/ai-docs/templates/new-service/05-validation.md +145 -0
  40. package/dist/cc.js +818 -59
  41. package/dist/cc.js.map +1 -1
  42. package/dist/config.js +13 -0
  43. package/dist/config.js.map +1 -1
  44. package/dist/constants.js +31 -3
  45. package/dist/constants.js.map +1 -1
  46. package/dist/index.js +27 -5
  47. package/dist/index.js.map +1 -1
  48. package/dist/metrics/behavioral-events.js +127 -0
  49. package/dist/metrics/behavioral-events.js.map +1 -1
  50. package/dist/metrics/constants.js +34 -3
  51. package/dist/metrics/constants.js.map +1 -1
  52. package/dist/services/AddressBook.js +18 -15
  53. package/dist/services/AddressBook.js.map +1 -1
  54. package/dist/services/AnswerCallOnWebexService.js +174 -0
  55. package/dist/services/AnswerCallOnWebexService.js.map +1 -0
  56. package/dist/services/ApiAiAssistant.js +318 -0
  57. package/dist/services/ApiAiAssistant.js.map +1 -0
  58. package/dist/services/EntryPoint.js +46 -68
  59. package/dist/services/EntryPoint.js.map +1 -1
  60. package/dist/services/Queue.js +27 -22
  61. package/dist/services/Queue.js.map +1 -1
  62. package/dist/services/UserPreference.js +427 -0
  63. package/dist/services/UserPreference.js.map +1 -0
  64. package/dist/services/WebexCrossClientService.js +171 -0
  65. package/dist/services/WebexCrossClientService.js.map +1 -0
  66. package/dist/services/WxAppTelephonyMercurySync.js +93 -0
  67. package/dist/services/WxAppTelephonyMercurySync.js.map +1 -0
  68. package/dist/services/agent/types.js.map +1 -1
  69. package/dist/services/config/Util.js +11 -4
  70. package/dist/services/config/Util.js.map +1 -1
  71. package/dist/services/config/constants.js +45 -8
  72. package/dist/services/config/constants.js.map +1 -1
  73. package/dist/services/config/index.js +41 -2
  74. package/dist/services/config/index.js.map +1 -1
  75. package/dist/services/config/types.js +70 -8
  76. package/dist/services/config/types.js.map +1 -1
  77. package/dist/services/constants.js +27 -1
  78. package/dist/services/constants.js.map +1 -1
  79. package/dist/services/core/Err.js.map +1 -1
  80. package/dist/services/core/Utils.js +122 -25
  81. package/dist/services/core/Utils.js.map +1 -1
  82. package/dist/services/core/WebexRequest.js +6 -2
  83. package/dist/services/core/WebexRequest.js.map +1 -1
  84. package/dist/services/core/aqm-reqs.js +119 -30
  85. package/dist/services/core/aqm-reqs.js.map +1 -1
  86. package/dist/services/core/types.js.map +1 -1
  87. package/dist/services/core/websocket/WebSocketManager.js +22 -6
  88. package/dist/services/core/websocket/WebSocketManager.js.map +1 -1
  89. package/dist/services/core/websocket/connection-service.js +3 -1
  90. package/dist/services/core/websocket/connection-service.js.map +1 -1
  91. package/dist/services/core/websocket/types.js.map +1 -1
  92. package/dist/services/index.js +6 -0
  93. package/dist/services/index.js.map +1 -1
  94. package/dist/services/task/Task.js +754 -0
  95. package/dist/services/task/Task.js.map +1 -0
  96. package/dist/services/task/TaskFactory.js +49 -0
  97. package/dist/services/task/TaskFactory.js.map +1 -0
  98. package/dist/services/task/TaskManager.js +1073 -447
  99. package/dist/services/task/TaskManager.js.map +1 -1
  100. package/dist/services/task/TaskUtils.js +220 -23
  101. package/dist/services/task/TaskUtils.js.map +1 -1
  102. package/dist/services/task/WebexCallingUtils.js +70 -0
  103. package/dist/services/task/WebexCallingUtils.js.map +1 -0
  104. package/dist/services/task/constants.js +26 -2
  105. package/dist/services/task/constants.js.map +1 -1
  106. package/dist/services/task/contact.js +29 -0
  107. package/dist/services/task/contact.js.map +1 -1
  108. package/dist/services/task/dialer.js +129 -0
  109. package/dist/services/task/dialer.js.map +1 -1
  110. package/dist/services/task/digital/Digital.js +78 -0
  111. package/dist/services/task/digital/Digital.js.map +1 -0
  112. package/dist/services/task/state-machine/TaskStateMachine.js +971 -0
  113. package/dist/services/task/state-machine/TaskStateMachine.js.map +1 -0
  114. package/dist/services/task/state-machine/actions.js +572 -0
  115. package/dist/services/task/state-machine/actions.js.map +1 -0
  116. package/dist/services/task/state-machine/constants.js +161 -0
  117. package/dist/services/task/state-machine/constants.js.map +1 -0
  118. package/dist/services/task/state-machine/guards.js +409 -0
  119. package/dist/services/task/state-machine/guards.js.map +1 -0
  120. package/dist/services/task/state-machine/index.js +53 -0
  121. package/dist/services/task/state-machine/index.js.map +1 -0
  122. package/dist/services/task/state-machine/types.js +54 -0
  123. package/dist/services/task/state-machine/types.js.map +1 -0
  124. package/dist/services/task/state-machine/uiControlsComputer.js +703 -0
  125. package/dist/services/task/state-machine/uiControlsComputer.js.map +1 -0
  126. package/dist/services/task/taskDataNormalizer.js +99 -0
  127. package/dist/services/task/taskDataNormalizer.js.map +1 -0
  128. package/dist/services/task/types.js +243 -5
  129. package/dist/services/task/types.js.map +1 -1
  130. package/dist/services/task/voice/Voice.js +1380 -0
  131. package/dist/services/task/voice/Voice.js.map +1 -0
  132. package/dist/services/task/voice/WebRTC.js +152 -0
  133. package/dist/services/task/voice/WebRTC.js.map +1 -0
  134. package/dist/services/task/voice/wxAppVoiceMethods.js +201 -0
  135. package/dist/services/task/voice/wxAppVoiceMethods.js.map +1 -0
  136. package/dist/services/wxAppTelephonyUtils.js +19 -0
  137. package/dist/services/wxAppTelephonyUtils.js.map +1 -0
  138. package/dist/types/cc.d.ts +967 -0
  139. package/dist/types/config.d.ts +79 -0
  140. package/dist/types/constants.d.ts +74 -0
  141. package/dist/types/index.d.ts +201 -0
  142. package/dist/types/logger-proxy.d.ts +71 -0
  143. package/dist/types/metrics/MetricsManager.d.ts +223 -0
  144. package/dist/types/metrics/behavioral-events.d.ts +29 -0
  145. package/dist/types/metrics/constants.d.ts +183 -0
  146. package/dist/types/services/AddressBook.d.ts +75 -0
  147. package/dist/types/services/AnswerCallOnWebexService.d.ts +37 -0
  148. package/dist/types/services/ApiAiAssistant.d.ts +49 -0
  149. package/dist/types/services/EntryPoint.d.ts +69 -0
  150. package/dist/types/services/Queue.d.ts +78 -0
  151. package/dist/types/services/UserPreference.d.ts +118 -0
  152. package/dist/types/services/WebCallingService.d.ts +1 -0
  153. package/dist/types/services/WebexCrossClientService.d.ts +28 -0
  154. package/dist/types/services/WxAppTelephonyMercurySync.d.ts +28 -0
  155. package/dist/types/services/agent/index.d.ts +46 -0
  156. package/dist/types/services/agent/types.d.ts +413 -0
  157. package/dist/types/services/config/Util.d.ts +20 -0
  158. package/dist/types/services/config/constants.d.ts +273 -0
  159. package/dist/types/services/config/index.d.ts +177 -0
  160. package/dist/types/services/config/types.d.ts +1381 -0
  161. package/dist/types/services/constants.d.ts +110 -0
  162. package/dist/types/services/core/Err.d.ts +127 -0
  163. package/dist/types/services/core/GlobalTypes.d.ts +58 -0
  164. package/dist/types/services/core/Utils.d.ts +121 -0
  165. package/dist/types/services/core/WebexRequest.d.ts +23 -0
  166. package/dist/types/services/core/aqm-reqs.d.ts +65 -0
  167. package/dist/types/services/core/constants.d.ts +99 -0
  168. package/dist/types/services/core/types.d.ts +49 -0
  169. package/dist/types/services/core/websocket/WebSocketManager.d.ts +36 -0
  170. package/dist/types/services/core/websocket/connection-service.d.ts +27 -0
  171. package/dist/types/services/core/websocket/keepalive.worker.d.ts +2 -0
  172. package/dist/types/services/core/websocket/types.d.ts +37 -0
  173. package/dist/types/services/index.d.ts +54 -0
  174. package/dist/types/services/task/AutoWrapup.d.ts +40 -0
  175. package/dist/types/services/task/Task.d.ts +175 -0
  176. package/dist/types/services/task/TaskFactory.d.ts +13 -0
  177. package/dist/types/services/task/TaskManager.d.ts +1 -0
  178. package/dist/types/services/task/TaskUtils.d.ts +138 -0
  179. package/dist/types/services/task/WebexCallingUtils.d.ts +11 -0
  180. package/dist/types/services/task/constants.d.ts +94 -0
  181. package/dist/types/services/task/contact.d.ts +73 -0
  182. package/dist/types/services/task/dialer.d.ts +73 -0
  183. package/dist/types/services/task/digital/Digital.d.ts +22 -0
  184. package/dist/types/services/task/state-machine/TaskStateMachine.d.ts +1398 -0
  185. package/dist/types/services/task/state-machine/actions.d.ts +10 -0
  186. package/dist/types/services/task/state-machine/constants.d.ts +107 -0
  187. package/dist/types/services/task/state-machine/guards.d.ts +103 -0
  188. package/dist/types/services/task/state-machine/index.d.ts +13 -0
  189. package/dist/types/services/task/state-machine/types.d.ts +277 -0
  190. package/dist/types/services/task/state-machine/uiControlsComputer.d.ts +9 -0
  191. package/dist/types/services/task/taskDataNormalizer.d.ts +10 -0
  192. package/dist/types/services/task/types.d.ts +1933 -0
  193. package/dist/types/services/task/voice/Voice.d.ts +223 -0
  194. package/dist/types/services/task/voice/WebRTC.d.ts +53 -0
  195. package/dist/types/services/task/voice/wxAppVoiceMethods.d.ts +52 -0
  196. package/dist/types/services/wxAppTelephonyUtils.d.ts +5 -0
  197. package/dist/types/types.d.ts +784 -0
  198. package/dist/types/utils/PageCache.d.ts +190 -0
  199. package/dist/types/webex-config.d.ts +53 -0
  200. package/dist/types/webex.d.ts +8 -0
  201. package/dist/types.js +137 -3
  202. package/dist/types.js.map +1 -1
  203. package/dist/utils/PageCache.js +19 -5
  204. package/dist/utils/PageCache.js.map +1 -1
  205. package/dist/webex.js +14 -2
  206. package/dist/webex.js.map +1 -1
  207. package/package.json +16 -12
  208. package/src/cc.ts +983 -60
  209. package/src/config.ts +13 -0
  210. package/src/constants.ts +29 -1
  211. package/src/index.ts +26 -5
  212. package/src/metrics/ai-docs/AGENTS.md +350 -0
  213. package/src/metrics/ai-docs/ARCHITECTURE.md +338 -0
  214. package/src/metrics/ai-docs/metrics-spec.md +860 -0
  215. package/src/metrics/behavioral-events.ts +134 -0
  216. package/src/metrics/constants.ts +39 -3
  217. package/src/services/AddressBook.ts +17 -6
  218. package/src/services/AnswerCallOnWebexService.ts +206 -0
  219. package/src/services/ApiAiAssistant.ts +412 -0
  220. package/src/services/EntryPoint.ts +59 -60
  221. package/src/services/Queue.ts +29 -12
  222. package/src/services/UserPreference.ts +509 -0
  223. package/src/services/WebexCrossClientService.ts +212 -0
  224. package/src/services/WxAppTelephonyMercurySync.ts +115 -0
  225. package/src/services/agent/ai-docs/AGENTS.md +240 -0
  226. package/src/services/agent/ai-docs/ARCHITECTURE.md +304 -0
  227. package/src/services/agent/ai-docs/agent-spec.md +504 -0
  228. package/src/services/agent/types.ts +1 -1
  229. package/src/services/ai-docs/AGENTS.md +386 -0
  230. package/src/services/ai-docs/services-spec.md +497 -0
  231. package/src/services/config/Util.ts +13 -2
  232. package/src/services/config/ai-docs/AGENTS.md +255 -0
  233. package/src/services/config/ai-docs/ARCHITECTURE.md +426 -0
  234. package/src/services/config/ai-docs/config-spec.md +675 -0
  235. package/src/services/config/constants.ts +47 -7
  236. package/src/services/config/index.ts +45 -1
  237. package/src/services/config/types.ts +253 -11
  238. package/src/services/constants.ts +29 -0
  239. package/src/services/core/Err.ts +4 -0
  240. package/src/services/core/Utils.ts +143 -30
  241. package/src/services/core/WebexRequest.ts +3 -1
  242. package/src/services/core/ai-docs/AGENTS.md +381 -0
  243. package/src/services/core/ai-docs/ARCHITECTURE.md +698 -0
  244. package/src/services/core/ai-docs/core-spec.md +787 -0
  245. package/src/services/core/aqm-reqs.ts +125 -32
  246. package/src/services/core/types.ts +2 -0
  247. package/src/services/core/websocket/WebSocketManager.ts +23 -6
  248. package/src/services/core/websocket/connection-service.ts +5 -1
  249. package/src/services/core/websocket/types.ts +1 -1
  250. package/src/services/index.ts +4 -0
  251. package/src/services/task/Task.ts +908 -0
  252. package/src/services/task/TaskFactory.ts +60 -0
  253. package/src/services/task/TaskManager.ts +1291 -513
  254. package/src/services/task/TaskUtils.ts +314 -24
  255. package/src/services/task/WebexCallingUtils.ts +136 -0
  256. package/src/services/task/ai-docs/AGENTS.md +457 -0
  257. package/src/services/task/ai-docs/ARCHITECTURE.md +595 -0
  258. package/src/services/task/ai-docs/task-spec.md +1469 -0
  259. package/src/services/task/constants.ts +26 -0
  260. package/src/services/task/contact.ts +30 -0
  261. package/src/services/task/dialer.ts +136 -1
  262. package/src/services/task/digital/Digital.ts +97 -0
  263. package/src/services/task/state-machine/TaskStateMachine.ts +1313 -0
  264. package/src/services/task/state-machine/actions.ts +741 -0
  265. package/src/services/task/state-machine/ai-docs/AGENTS.md +462 -0
  266. package/src/services/task/state-machine/ai-docs/ARCHITECTURE.md +1146 -0
  267. package/src/services/task/state-machine/ai-docs/task-state-machine-spec.md +2209 -0
  268. package/src/services/task/state-machine/constants.ts +172 -0
  269. package/src/services/task/state-machine/guards.ts +498 -0
  270. package/src/services/task/state-machine/index.ts +28 -0
  271. package/src/services/task/state-machine/types.ts +258 -0
  272. package/src/services/task/state-machine/uiControlsComputer.ts +1135 -0
  273. package/src/services/task/taskDataNormalizer.ts +137 -0
  274. package/src/services/task/types.ts +843 -70
  275. package/src/services/task/voice/Voice.ts +1720 -0
  276. package/src/services/task/voice/WebRTC.ts +191 -0
  277. package/src/services/task/voice/wxAppVoiceMethods.ts +307 -0
  278. package/src/services/wxAppTelephonyUtils.ts +14 -0
  279. package/src/types.ts +238 -11
  280. package/src/utils/AGENTS.md +289 -0
  281. package/src/utils/PageCache.ts +38 -5
  282. package/src/utils/ai-docs/utils-spec.md +391 -0
  283. package/src/webex.js +2 -0
  284. package/test/unit/spec/cc.ts +1856 -122
  285. package/test/unit/spec/logger-proxy.ts +70 -0
  286. package/test/unit/spec/metrics/behavioral-events.ts +18 -0
  287. package/test/unit/spec/services/AddressBook.ts +37 -6
  288. package/test/unit/spec/services/AnswerCallOnWebexService.ts +223 -0
  289. package/test/unit/spec/services/ApiAiAssistant.ts +273 -0
  290. package/test/unit/spec/services/EntryPoint.ts +87 -40
  291. package/test/unit/spec/services/Queue.ts +123 -12
  292. package/test/unit/spec/services/UserPreference.ts +401 -0
  293. package/test/unit/spec/services/WebCallingService.ts +7 -1
  294. package/test/unit/spec/services/WebexCrossClientService.ts +261 -0
  295. package/test/unit/spec/services/WxAppTelephonyMercurySync.ts +113 -0
  296. package/test/unit/spec/services/config/Util.ts +85 -0
  297. package/test/unit/spec/services/config/index.ts +85 -29
  298. package/test/unit/spec/services/core/Utils.ts +481 -2
  299. package/test/unit/spec/services/core/WebexRequest.ts +3 -1
  300. package/test/unit/spec/services/core/aqm-reqs.ts +113 -1
  301. package/test/unit/spec/services/core/websocket/WebSocketManager.ts +137 -41
  302. package/test/unit/spec/services/core/websocket/connection-service.ts +3 -1
  303. package/test/unit/spec/services/task/AutoWrapup.ts +63 -0
  304. package/test/unit/spec/services/task/Task.ts +677 -0
  305. package/test/unit/spec/services/task/TaskFactory.ts +99 -0
  306. package/test/unit/spec/services/task/TaskManager.ts +2209 -918
  307. package/test/unit/spec/services/task/TaskUtils.ts +235 -0
  308. package/test/unit/spec/services/task/WebexCallingUtils.ts +153 -0
  309. package/test/unit/spec/services/task/contact.ts +33 -0
  310. package/test/unit/spec/services/task/dialer.ts +372 -96
  311. package/test/unit/spec/services/task/digital/Digital.ts +105 -0
  312. package/test/unit/spec/services/task/state-machine/TaskStateMachine.ts +3433 -0
  313. package/test/unit/spec/services/task/state-machine/guards.ts +839 -0
  314. package/test/unit/spec/services/task/state-machine/types.ts +18 -0
  315. package/test/unit/spec/services/task/state-machine/uiControlsComputer.ts +3101 -0
  316. package/test/unit/spec/services/task/taskTestUtils.ts +87 -0
  317. package/test/unit/spec/services/task/voice/Voice.ts +1523 -0
  318. package/test/unit/spec/services/task/voice/WebRTC.ts +235 -0
  319. package/test/unit/spec/services/task/voice/wxAppVoiceMethods.ts +459 -0
  320. package/umd/contact-center.min.js +2 -2
  321. package/umd/contact-center.min.js.map +1 -1
  322. package/dist/services/task/index.js +0 -1525
  323. package/dist/services/task/index.js.map +0 -1
  324. package/src/services/task/index.ts +0 -1801
  325. package/test/unit/spec/services/task/index.ts +0 -2184
@@ -0,0 +1,784 @@
1
+ import { CallingClientConfig } from '@webex/calling';
2
+ import * as Agent from './services/agent/types';
3
+ import { Profile } from './services/config/types';
4
+ import { PaginatedResponse, BaseSearchParams } from './utils/PageCache';
5
+ /**
6
+ * HTTP methods supported by WebexRequest.
7
+ * @enum {string}
8
+ * @public
9
+ * @example
10
+ * const method: HTTP_METHODS = HTTP_METHODS.GET;
11
+ * @ignore
12
+ */
13
+ export declare const HTTP_METHODS: {
14
+ /** HTTP GET method for retrieving data */
15
+ readonly GET: "GET";
16
+ /** HTTP POST method for creating resources */
17
+ readonly POST: "POST";
18
+ /** HTTP PATCH method for partial updates */
19
+ readonly PATCH: "PATCH";
20
+ /** HTTP PUT method for complete updates */
21
+ readonly PUT: "PUT";
22
+ /** HTTP DELETE method for removing resources */
23
+ readonly DELETE: "DELETE";
24
+ };
25
+ /**
26
+ * Union type of HTTP methods.
27
+ * @public
28
+ * @example
29
+ * function makeRequest(method: HTTP_METHODS) { ... }
30
+ * @ignore
31
+ */
32
+ export type HTTP_METHODS = Enum<typeof HTTP_METHODS>;
33
+ /**
34
+ * Payload for making requests to Webex APIs.
35
+ * @public
36
+ * @example
37
+ * const payload: WebexRequestPayload = {
38
+ * service: 'identity',
39
+ * resource: '/users',
40
+ * method: HTTP_METHODS.GET
41
+ * };
42
+ * @ignore
43
+ */
44
+ export type WebexRequestPayload = {
45
+ /** Service name to target */
46
+ service?: string;
47
+ /** Resource path within the service */
48
+ resource?: string;
49
+ /** HTTP method to use */
50
+ method?: HTTP_METHODS;
51
+ /** Full URI if not using service/resource pattern */
52
+ uri?: string;
53
+ /** Whether to add authorization header */
54
+ addAuthHeader?: boolean;
55
+ /** Custom headers to include in request */
56
+ headers?: {
57
+ [key: string]: string | null;
58
+ };
59
+ /** Request body data */
60
+ body?: object;
61
+ /** Expected response status code */
62
+ statusCode?: number;
63
+ /** Whether to parse response as JSON */
64
+ json?: boolean;
65
+ };
66
+ /**
67
+ * Configuration options for the Contact Center Plugin.
68
+ * @interface CCPluginConfig
69
+ * @public
70
+ * @example
71
+ * const config: CCPluginConfig = {
72
+ * allowMultiLogin: true,
73
+ * allowAutomatedRelogin: false,
74
+ * clientType: 'browser',
75
+ * isKeepAliveEnabled: true,
76
+ * force: false,
77
+ * metrics: { clientName: 'myClient', clientType: 'browser' },
78
+ * logging: { enable: true, verboseEvents: false },
79
+ * callingClientConfig: { ... }
80
+ * };
81
+ */
82
+ export interface CCPluginConfig {
83
+ /** Whether to allow multiple logins from different devices */
84
+ allowMultiLogin: boolean;
85
+ /** Whether to automatically attempt relogin on connection loss */
86
+ allowAutomatedRelogin: boolean;
87
+ /** The type of client making the connection */
88
+ clientType: string;
89
+ /** Whether to enable keep-alive messages */
90
+ isKeepAliveEnabled: boolean;
91
+ /** Whether to force registration */
92
+ force: boolean;
93
+ /** Metrics configuration */
94
+ metrics: {
95
+ /** Name of the client for metrics */
96
+ clientName: string;
97
+ /** Type of client for metrics */
98
+ clientType: string;
99
+ };
100
+ /** Logging configuration */
101
+ logging: {
102
+ /** Whether to enable logging */
103
+ enable: boolean;
104
+ /** Whether to log verbose events */
105
+ verboseEvents: boolean;
106
+ };
107
+ /** Configuration for the calling client */
108
+ callingClientConfig: CallingClientConfig;
109
+ /** Whether to skip Mobius/WebRTC registration for browser login flows */
110
+ disableWebRTCRegistration?: boolean;
111
+ /** Whether wxApp Better Together (telephony REST + usersub) is enabled at init (WXCC-6026) */
112
+ enableWxBetterTogether?: boolean;
113
+ }
114
+ /**
115
+ * Logger interface for standardized logging throughout the plugin.
116
+ * @public
117
+ * @example
118
+ * logger.log('This is a log message');
119
+ * logger.error('This is an error message');
120
+ * @ignore
121
+ */
122
+ export type Logger = {
123
+ /** Log general messages */
124
+ log: (payload: string) => void;
125
+ /** Log error messages */
126
+ error: (payload: string) => void;
127
+ /** Log warning messages */
128
+ warn: (payload: string) => void;
129
+ /** Log informational messages */
130
+ info: (payload: string) => void;
131
+ /** Log detailed trace messages */
132
+ trace: (payload: string) => void;
133
+ /** Log debug messages */
134
+ debug: (payload: string) => void;
135
+ };
136
+ /**
137
+ * Contextual information for log entries.
138
+ * @public
139
+ * @ignore
140
+ */
141
+ export interface LogContext {
142
+ /** Module name where the log originated */
143
+ module?: string;
144
+ /** Method name where the log originated */
145
+ method?: string;
146
+ interactionId?: string;
147
+ trackingId?: string;
148
+ /** Additional structured data to include in logs */
149
+ data?: Record<string, any>;
150
+ /** Error object to include in logs */
151
+ error?: Error | unknown;
152
+ }
153
+ /**
154
+ * Available logging severity levels.
155
+ * @enum {string}
156
+ * @public
157
+ * @example
158
+ * const level: LOGGING_LEVEL = LOGGING_LEVEL.error;
159
+ * @ignore
160
+ */
161
+ export declare enum LOGGING_LEVEL {
162
+ /** Critical failures that require immediate attention */
163
+ error = "ERROR",
164
+ /** Important issues that don't prevent the system from working */
165
+ warn = "WARN",
166
+ /** General informational logs */
167
+ log = "LOG",
168
+ /** Detailed information about system operation */
169
+ info = "INFO",
170
+ /** Highly detailed diagnostic information */
171
+ trace = "TRACE"
172
+ }
173
+ /**
174
+ * Metadata for log uploads.
175
+ * @public
176
+ * @example
177
+ * const meta: LogsMetaData = { feedbackId: 'fb123', correlationId: 'corr456' };
178
+ * @ignore
179
+ */
180
+ export type LogsMetaData = {
181
+ /** Optional feedback ID to associate with logs */
182
+ feedbackId?: string;
183
+ /** Optional correlation ID to track related operations */
184
+ correlationId?: string;
185
+ };
186
+ /**
187
+ * Response from uploading logs to the server.
188
+ * @public
189
+ * @example
190
+ * const response: UploadLogsResponse = { trackingid: 'track123', url: 'https://...', userId: 'user1' };
191
+ */
192
+ export type UploadLogsResponse = {
193
+ /** Tracking ID for the upload request */
194
+ trackingid?: string;
195
+ /** URL where the logs can be accessed */
196
+ url?: string;
197
+ /** ID of the user who uploaded logs */
198
+ userId?: string;
199
+ /** Feedback ID associated with the logs */
200
+ feedbackId?: string;
201
+ /** Correlation ID for tracking related operations */
202
+ correlationId?: string;
203
+ };
204
+ /**
205
+ * Interface representing the WebexSDK core functionality.
206
+ * @interface WebexSDK
207
+ * @public
208
+ * @example
209
+ * const sdk: WebexSDK = ...;
210
+ * sdk.request({ service: 'identity', resource: '/users', method: HTTP_METHODS.GET });
211
+ * @ignore
212
+ */
213
+ export interface WebexSDK {
214
+ /** Version of the WebexSDK */
215
+ version: string;
216
+ /** Whether the SDK can authorize requests */
217
+ canAuthorize: boolean;
218
+ /** Credentials management */
219
+ credentials: {
220
+ /** Get the user token for authentication */
221
+ getUserToken: () => Promise<string>;
222
+ /** Get the organization ID */
223
+ getOrgId: () => string;
224
+ };
225
+ /** Whether the SDK is ready for use */
226
+ ready: boolean;
227
+ /** Make a request to the Webex APIs */
228
+ request: <T>(payload: WebexRequestPayload) => Promise<T>;
229
+ /** Register a one-time event handler */
230
+ once: (event: string, callBack: () => void) => void;
231
+ /** Internal plugins and services */
232
+ internal: IWebexInternal;
233
+ /** Logger instance */
234
+ logger: Logger;
235
+ }
236
+ /**
237
+ * An interface for the `ContactCenter` class.
238
+ * The `ContactCenter` package is designed to provide a set of APIs to perform various operations for the Agent flow within Webex Contact Center.
239
+ * @public
240
+ * @example
241
+ * const cc: IContactCenter = ...;
242
+ * cc.register().then(profile => { ... });
243
+ * @ignore
244
+ */
245
+ export interface IContactCenter {
246
+ /**
247
+ * Initialize the CC SDK by setting up the contact center mercury connection.
248
+ * This establishes WebSocket connectivity for real-time communication.
249
+ *
250
+ * @returns A Promise that resolves to the agent's profile upon successful registration
251
+ * @public
252
+ * @example
253
+ * cc.register().then(profile => { ... });
254
+ */
255
+ register(): Promise<Profile>;
256
+ }
257
+ /**
258
+ * Generic HTTP response structure.
259
+ * @public
260
+ * @example
261
+ * const response: IHttpResponse = { body: {}, statusCode: 200, method: 'GET', headers: {}, url: '...' };
262
+ * @ignore
263
+ */
264
+ export interface IHttpResponse {
265
+ /** Response body content */
266
+ body: any;
267
+ /** HTTP status code */
268
+ statusCode: number;
269
+ /** HTTP method used for the request */
270
+ method: string;
271
+ /** Response headers */
272
+ headers: Headers;
273
+ /** Request URL */
274
+ url: string;
275
+ }
276
+ /**
277
+ * Supported login options for agent authentication.
278
+ * @public
279
+ * @example
280
+ * const option: LoginOption = LoginOption.AGENT_DN;
281
+ * @ignore
282
+ */
283
+ export declare const LoginOption: {
284
+ /** Login using agent's direct number */
285
+ readonly AGENT_DN: "AGENT_DN";
286
+ /** Login using an extension number */
287
+ readonly EXTENSION: "EXTENSION";
288
+ /** Login using browser WebRTC capabilities */
289
+ readonly BROWSER: "BROWSER";
290
+ };
291
+ /**
292
+ * Union type of login options.
293
+ * @public
294
+ * @example
295
+ * function login(option: LoginOption) { ... }
296
+ * @ignore
297
+ */
298
+ export type LoginOption = Enum<typeof LoginOption>;
299
+ /**
300
+ * Request payload for subscribing to the contact center websocket.
301
+ * @public
302
+ * @example
303
+ * const req: SubscribeRequest = { force: true, isKeepAliveEnabled: true, clientType: 'browser', allowMultiLogin: false };
304
+ * @ignore
305
+ */
306
+ export type SubscribeRequest = {
307
+ /** Whether to force connection even if another exists */
308
+ force: boolean;
309
+ /** Whether to send keepalive messages */
310
+ isKeepAliveEnabled: boolean;
311
+ /** Type of client connecting */
312
+ clientType: string;
313
+ /** Whether to allow login from multiple devices */
314
+ allowMultiLogin: boolean;
315
+ };
316
+ /**
317
+ * Represents the response from getListOfTeams method.
318
+ * Teams are groups of agents that can be managed together.
319
+ * @public
320
+ * @example
321
+ * const team: Team = { id: 'team1', name: 'Support', desktopLayoutId: 'layout1' };
322
+ * @ignore
323
+ */
324
+ export type Team = {
325
+ /**
326
+ * Unique identifier of the team.
327
+ */
328
+ id: string;
329
+ /**
330
+ * Display name of the team.
331
+ */
332
+ name: string;
333
+ /**
334
+ * Associated desktop layout ID for the team.
335
+ * Controls how the agent desktop is displayed for team members.
336
+ */
337
+ desktopLayoutId?: string;
338
+ };
339
+ /**
340
+ * Represents the request to perform agent login.
341
+ * @public
342
+ * @example
343
+ * const login: AgentLogin = { dialNumber: '1234', teamId: 'team1', loginOption: LoginOption.AGENT_DN };
344
+ */
345
+ export type AgentLogin = {
346
+ /**
347
+ * A dialNumber field contains the number to dial such as a route point or extension.
348
+ * Required for AGENT_DN and EXTENSION login options.
349
+ */
350
+ dialNumber?: string;
351
+ /**
352
+ * The unique ID representing a team of users.
353
+ * The agent must belong to this team.
354
+ */
355
+ teamId: string;
356
+ /**
357
+ * The loginOption field specifies the type of login method.
358
+ * Controls how calls are delivered to the agent.
359
+ */
360
+ loginOption: LoginOption;
361
+ };
362
+ /**
363
+ * Represents the request to update agent profile settings.
364
+ * @public
365
+ * @example
366
+ * const update: AgentProfileUpdate = { loginOption: LoginOption.BROWSER, dialNumber: '5678' };
367
+ */
368
+ export type AgentProfileUpdate = Pick<AgentLogin, 'loginOption' | 'dialNumber' | 'teamId'>;
369
+ /**
370
+ * Represents the options to fetch buddy agents for the logged in agent.
371
+ * Buddy agents are other agents who can be consulted or transferred to.
372
+ * @public
373
+ * @example
374
+ * const opts: BuddyAgents = { mediaType: 'telephony', state: 'Available' };
375
+ */
376
+ export type BuddyAgents = {
377
+ /**
378
+ * The media type channel to filter buddy agents. Defaults to telephony when omitted.
379
+ */
380
+ mediaType?: 'telephony' | 'chat' | 'social' | 'email';
381
+ /**
382
+ * Optional filter for agent state.
383
+ * If specified, returns only agents in that state.
384
+ * If omitted, returns both available and idle agents.
385
+ */
386
+ state?: 'Available' | 'Idle';
387
+ /**
388
+ * Applies the default state policy for the operation. An explicit state takes precedence.
389
+ */
390
+ action?: 'Consult' | 'Transfer';
391
+ };
392
+ /**
393
+
394
+ * Generic error structure for Contact Center SDK errors.
395
+ * Contains detailed information about the error context.
396
+ * @public
397
+ * @example
398
+ * const err: GenericError = new Error('Failed');
399
+ * err.details = { type: 'ERR', orgId: 'org1', trackingId: 'track1', data: {} };
400
+ * @ignore
401
+ */
402
+ export interface GenericError extends Error {
403
+ /** Structured details about the error */
404
+ details: {
405
+ /** Error type identifier */
406
+ type: string;
407
+ /** Organization ID where the error occurred */
408
+ orgId: string;
409
+ /** Unique tracking ID for the error */
410
+ trackingId: string;
411
+ /** Additional error context data */
412
+ data: Record<string, any>;
413
+ };
414
+ }
415
+ /**
416
+ * Response type for station login operations.
417
+ * Either a success response with agent details or an error.
418
+ * @public
419
+ * @example
420
+ * function handleLogin(resp: StationLoginResponse) { ... }
421
+ */
422
+ export type StationLoginResponse = Agent.StationLoginSuccessResponse | Error;
423
+ /**
424
+ * Response type for station logout operations.
425
+ * Either a success response with logout details or an error.
426
+ * @public
427
+ * @example
428
+ * function handleLogout(resp: StationLogoutResponse) { ... }
429
+ */
430
+ export type StationLogoutResponse = Agent.LogoutSuccess | Error;
431
+ /**
432
+ * Response type for station relogin operations.
433
+ * Either a success response with relogin details or an error.
434
+ * @public
435
+ * @example
436
+ * function handleReLogin(resp: StationReLoginResponse) { ... }
437
+ * @ignore
438
+ */
439
+ export type StationReLoginResponse = Agent.ReloginSuccess | Error;
440
+ /**
441
+ * Response type for agent state change operations.
442
+ * Either a success response with state change details or an error.
443
+ * @public
444
+ * @example
445
+ * function handleStateChange(resp: SetStateResponse) { ... }
446
+ * @ignore
447
+ */
448
+ export type SetStateResponse = Agent.StateChangeSuccess | Error;
449
+ /**
450
+ * AddressBook types
451
+ */
452
+ export interface AddressBookEntry {
453
+ id: string;
454
+ organizationId?: string;
455
+ version?: number;
456
+ name: string;
457
+ number: string;
458
+ createdTime?: number;
459
+ lastUpdatedTime?: number;
460
+ }
461
+ export type AddressBookEntriesResponse = PaginatedResponse<AddressBookEntry>;
462
+ export interface AddressBookEntrySearchParams extends BaseSearchParams {
463
+ addressBookId?: string;
464
+ }
465
+ /**
466
+ * EntryPointRecord types
467
+ */
468
+ export interface EntryPointRecord {
469
+ id: string;
470
+ name: string;
471
+ /** Dialled number mapped to this entry point when included in the list response. */
472
+ number?: string;
473
+ description?: string;
474
+ type?: string;
475
+ isActive?: boolean;
476
+ orgId?: string;
477
+ createdAt?: string;
478
+ updatedAt?: string;
479
+ settings?: Record<string, any>;
480
+ }
481
+ export type EntryPointListResponse = PaginatedResponse<EntryPointRecord>;
482
+ export type EntryPointSearchParams = BaseSearchParams;
483
+ /**
484
+ * Queue types
485
+ */
486
+ export interface QueueSkillRequirement {
487
+ organizationId?: string;
488
+ id?: string;
489
+ version?: number;
490
+ skillId: string;
491
+ skillName?: string;
492
+ skillType?: string;
493
+ condition: string;
494
+ skillValue: string;
495
+ createdTime?: number;
496
+ lastUpdatedTime?: number;
497
+ }
498
+ export interface QueueAgent {
499
+ id: string;
500
+ ciUserId?: string;
501
+ }
502
+ export interface AgentGroup {
503
+ teamId: string;
504
+ }
505
+ export interface CallDistributionGroup {
506
+ agentGroups: AgentGroup[];
507
+ order: number;
508
+ duration?: number;
509
+ }
510
+ export interface AssistantSkillMapping {
511
+ assistantSkillId?: string;
512
+ assistantSkillUpdatedTime?: number;
513
+ }
514
+ /**
515
+ * Configuration for a contact service queue
516
+ * @public
517
+ */
518
+ export interface ContactServiceQueue {
519
+ /** Organization ID */
520
+ organizationId?: string;
521
+ /** Unique identifier for the queue */
522
+ id?: string;
523
+ /** Version of the queue */
524
+ version?: number;
525
+ /** Name of the Contact Service Queue */
526
+ name: string;
527
+ /** Description of the queue */
528
+ description?: string;
529
+ /** Queue type (INBOUND, OUTBOUND) */
530
+ queueType: 'INBOUND' | 'OUTBOUND';
531
+ /** Whether to check agent availability */
532
+ checkAgentAvailability: boolean;
533
+ /** Channel type (TELEPHONY, EMAIL, SOCIAL_CHANNEL, CHAT, etc.) */
534
+ channelType: 'TELEPHONY' | 'EMAIL' | 'FAX' | 'CHAT' | 'VIDEO' | 'OTHERS' | 'SOCIAL_CHANNEL';
535
+ /** Social channel type for SOCIAL_CHANNEL channelType */
536
+ socialChannelType?: 'MESSAGEBIRD' | 'MESSENGER' | 'WHATSAPP' | 'APPLE_BUSINESS_CHAT' | 'GOOGLE_BUSINESS_MESSAGES';
537
+ /** Service level threshold in seconds */
538
+ serviceLevelThreshold: number;
539
+ /** Maximum number of simultaneous contacts */
540
+ maxActiveContacts: number;
541
+ /** Maximum time in queue in seconds */
542
+ maxTimeInQueue: number;
543
+ /** Default music in queue media file ID */
544
+ defaultMusicInQueueMediaFileId: string;
545
+ /** Timezone for routing strategies */
546
+ timezone?: string;
547
+ /** Whether the queue is active */
548
+ active: boolean;
549
+ /** Whether outdial campaign is enabled */
550
+ outdialCampaignEnabled?: boolean;
551
+ /** Whether monitoring is permitted */
552
+ monitoringPermitted: boolean;
553
+ /** Whether parking is permitted */
554
+ parkingPermitted: boolean;
555
+ /** Whether recording is permitted */
556
+ recordingPermitted: boolean;
557
+ /** Whether recording all calls is permitted */
558
+ recordingAllCallsPermitted: boolean;
559
+ /** Whether pausing recording is permitted */
560
+ pauseRecordingPermitted: boolean;
561
+ /** Recording pause duration in seconds */
562
+ recordingPauseDuration?: number;
563
+ /** Control flow script URL */
564
+ controlFlowScriptUrl: string;
565
+ /** IVR requeue URL */
566
+ ivrRequeueUrl: string;
567
+ /** Overflow number for telephony */
568
+ overflowNumber?: string;
569
+ /** Vendor ID */
570
+ vendorId?: string;
571
+ /** Routing type */
572
+ routingType: 'LONGEST_AVAILABLE_AGENT' | 'SKILLS_BASED' | 'CIRCULAR' | 'LINEAR';
573
+ /** Skills-based routing type */
574
+ skillBasedRoutingType?: 'LONGEST_AVAILABLE_AGENT' | 'BEST_AVAILABLE_AGENT';
575
+ /** Queue routing type */
576
+ queueRoutingType: 'TEAM_BASED' | 'SKILL_BASED' | 'AGENT_BASED';
577
+ /** Queue skill requirements */
578
+ queueSkillRequirements?: QueueSkillRequirement[];
579
+ /** List of agents for agent-based queue */
580
+ agents?: QueueAgent[];
581
+ /** Call distribution groups */
582
+ callDistributionGroups: CallDistributionGroup[];
583
+ /** XSP version */
584
+ xspVersion?: string;
585
+ /** Subscription ID */
586
+ subscriptionId?: string;
587
+ /** Assistant skill mapping */
588
+ assistantSkill?: AssistantSkillMapping;
589
+ /** Whether this is a system default queue */
590
+ systemDefault?: boolean;
591
+ /** User who last updated agents list */
592
+ agentsLastUpdatedByUserName?: string;
593
+ /** Email of user who last updated agents list */
594
+ agentsLastUpdatedByUserEmailPrefix?: string;
595
+ /** When agents list was last updated */
596
+ agentsLastUpdatedTime?: number;
597
+ /** Creation timestamp in epoch millis */
598
+ createdTime?: number;
599
+ /** Last updated timestamp in epoch millis */
600
+ lastUpdatedTime?: number;
601
+ }
602
+ export type ContactServiceQueuesResponse = PaginatedResponse<ContactServiceQueue>;
603
+ export interface ContactServiceQueueSearchParams extends BaseSearchParams {
604
+ desktopProfileFilter?: boolean;
605
+ provisioningView?: boolean;
606
+ singleObjectResponse?: boolean;
607
+ }
608
+ /**
609
+ * Response type for buddy agents query operations.
610
+ * Either a success response with list of buddy agents or an error.
611
+ * @public
612
+ * @example
613
+ * function handleBuddyAgents(resp: BuddyAgentsResponse) { ... }
614
+ */
615
+ export type BuddyAgentsResponse = Agent.BuddyAgentsSuccess | Error;
616
+ /**
617
+ * Response type for device type update operations.
618
+ * Either a success response with update confirmation or an error.
619
+ * @public
620
+ * @example
621
+ * function handleUpdateDeviceType(resp: UpdateDeviceTypeResponse) { ... }
622
+ */
623
+ export type UpdateDeviceTypeResponse = Agent.DeviceTypeUpdateSuccess | Error;
624
+ /**
625
+ * Supported transcript control actions for AI Assistant events.
626
+ * @public
627
+ * @example
628
+ * const action: TranscriptAction = 'START';
629
+ * @ignore
630
+ */
631
+ export type TranscriptAction = 'START' | 'STOP';
632
+ /**
633
+ * Parameters used to request AI Assistant real-time assistance.
634
+ * @public
635
+ * @example
636
+ * const params: RealTimeAssistanceParams = {
637
+ * interactionId: 'interaction-123',
638
+ * context: 'Need help with credit card payment due date',
639
+ * };
640
+ */
641
+ export type RealTimeAssistanceParams = {
642
+ /** Agent identifier */
643
+ agentId: string;
644
+ /** Interaction identifier for which assistance should be generated */
645
+ interactionId: string;
646
+ /** Optional additional context that should refine the assistance */
647
+ context?: string;
648
+ /** Optional language code for assistance (for example, 'en'). Defaults to 'en'. */
649
+ languageCode?: string;
650
+ };
651
+ /**
652
+ * Supported user actions on an AI Assistant real-time assistance adaptive card.
653
+ * @public
654
+ */
655
+ export declare const RealTimeAssistanceUserActionId: {
656
+ /** User liked the real-time assistance response */
657
+ readonly LIKE: "likeButton";
658
+ /** User disliked the real-time assistance response */
659
+ readonly DISLIKE: "dislikeButton";
660
+ /** User copied the real-time assistance response */
661
+ readonly COPY: "copyButton";
662
+ };
663
+ /**
664
+ * Union type of supported real-time assistance user actions.
665
+ * @public
666
+ */
667
+ export type RealTimeAssistanceUserActionId = Enum<typeof RealTimeAssistanceUserActionId>;
668
+ /**
669
+ * Parameters used to send user action feedback for a real-time assistance adaptive card.
670
+ * @public
671
+ * @example
672
+ * const params: RealTimeAssistanceUserActionParams = {
673
+ * agentId: 'agent-123',
674
+ * interactionId: 'interaction-123',
675
+ * adaptiveCardId: 'adaptive-card-123',
676
+ * actionId: RealTimeAssistanceUserActionId.LIKE,
677
+ * };
678
+ */
679
+ export type RealTimeAssistanceUserActionParams = {
680
+ /** Agent identifier */
681
+ agentId: string;
682
+ /** Interaction identifier associated with the real-time assistance response */
683
+ interactionId: string;
684
+ /** Adaptive card identifier from the real-time assistance payload */
685
+ adaptiveCardId: string;
686
+ /** User action performed on the adaptive card */
687
+ actionId: RealTimeAssistanceUserActionId;
688
+ /** Optional language code. Defaults to 'en'. */
689
+ languageCode?: string;
690
+ };
691
+ /**
692
+ * Supported AI Assistant event categories.
693
+ * @public
694
+ * @example
695
+ * const eventType: AIAssistantEventType = AIAssistantEventType.CUSTOM_EVENT;
696
+ * @ignore
697
+ */
698
+ export declare const AIAssistantEventType: {
699
+ /** Custom AI Assistant event */
700
+ readonly CUSTOM_EVENT: "CUSTOM_EVENT";
701
+ /** CTI-backed AI Assistant event */
702
+ readonly CTI_EVENT: "CTI_EVENT";
703
+ };
704
+ /**
705
+ * Union type of AI Assistant event categories.
706
+ * @public
707
+ * @example
708
+ * function send(type: AIAssistantEventType) { ... }
709
+ * @ignore
710
+ */
711
+ export type AIAssistantEventType = Enum<typeof AIAssistantEventType>;
712
+ /**
713
+ * Supported AI Assistant event names.
714
+ * @public
715
+ * @example
716
+ * const name: AIAssistantEventName = AIAssistantEventName.GET_TRANSCRIPTS;
717
+ * @ignore
718
+ */
719
+ export declare const AIAssistantEventName: {
720
+ /** Request transcript streaming for an interaction */
721
+ readonly GET_TRANSCRIPTS: "GET_TRANSCRIPTS";
722
+ /** Request a suggested response for an interaction */
723
+ readonly GET_SUGGESTIONS: "GET_SUGGESTIONS";
724
+ /** Add extra context to refine a suggested response */
725
+ readonly ADD_SUGGESTIONS_EXTRA_CONTEXT: "ADD_SUGGESTIONS_EXTRA_CONTEXT";
726
+ /** Request mid-call summary generation */
727
+ readonly GET_MID_CALL_SUMMARY: "GET_MID_CALL_SUMMARY";
728
+ /** Request post-call summary generation */
729
+ readonly GET_POST_CALL_SUMMARY: "GET_POST_CALL_SUMMARY";
730
+ /** Mid-call summary response event */
731
+ readonly MID_CALL_SUMMARY_RESPONSE: "MID_CALL_SUMMARY_RESPONSE";
732
+ /** Post-call summary response event */
733
+ readonly POST_CALL_SUMMARY_RESPONSE: "POST_CALL_SUMMARY_RESPONSE";
734
+ /** Suggested digital response event */
735
+ readonly SUGGESTED_RESPONSES_DIGITAL: "SUGGESTED_RESPONSES_DIGITAL";
736
+ /** User action on a suggested response adaptive card */
737
+ readonly SUGGESTED_RESPONSES_USER_ACTION: "SUGGESTED_RESPONSES_USER_ACTION";
738
+ };
739
+ /**
740
+ * Union type of AI Assistant event names.
741
+ * @public
742
+ * @example
743
+ * function handle(name: AIAssistantEventName) { ... }
744
+ * @ignore
745
+ */
746
+ export type AIAssistantEventName = Enum<typeof AIAssistantEventName>;
747
+ /**
748
+ * A single transcript message entry returned by AI Assistant APIs.
749
+ * @public
750
+ * @example
751
+ * const message: TranscriptMessage = { role: 'AGENT', content: 'Hello', messageId: '1', publishTimestamp: Date.now() };
752
+ *
753
+ */
754
+ export type TranscriptMessage = {
755
+ /** Speaker role for this message */
756
+ role: string;
757
+ /** Transcript chunk content */
758
+ content: string;
759
+ /** Unique message identifier */
760
+ messageId: string;
761
+ /** Message publish timestamp (epoch milliseconds) */
762
+ publishTimestamp: number;
763
+ };
764
+ /**
765
+ * Response payload for historic transcripts API.
766
+ * @public
767
+ * @example
768
+ * const resp: HistoricTranscriptsResponse = { orgId: 'org', agentId: 'agent', conversationId: null, interactionId: 'int', source: 'AI', data: [] };
769
+ *
770
+ */
771
+ export type HistoricTranscriptsResponse = {
772
+ /** Organization identifier */
773
+ orgId: string;
774
+ /** Agent identifier */
775
+ agentId: string;
776
+ /** Conversation identifier when available */
777
+ conversationId: string | null;
778
+ /** Interaction identifier */
779
+ interactionId: string;
780
+ /** Data source identifier */
781
+ source: string;
782
+ /** Transcript messages */
783
+ data: TranscriptMessage[];
784
+ };