@futdevpro/nts-dynamo 1.14.29 → 1.14.32

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 (255) hide show
  1. package/build/_modules/ai/_modules/open-ai/_services/oai-llm.service-base.d.ts +0 -3
  2. package/build/_modules/ai/_modules/open-ai/_services/oai-llm.service-base.d.ts.map +1 -1
  3. package/build/_modules/ai/_modules/open-ai/_services/oai-llm.service-base.js +20 -15
  4. package/build/_modules/ai/_modules/open-ai/_services/oai-llm.service-base.js.map +1 -1
  5. package/build/_modules/ai/_services/ai-llm.service-base.d.ts +0 -2
  6. package/build/_modules/ai/_services/ai-llm.service-base.d.ts.map +1 -1
  7. package/build/_modules/ai/_services/ai-provider.service-base.d.ts +2 -1
  8. package/build/_modules/ai/_services/ai-provider.service-base.d.ts.map +1 -1
  9. package/build/_modules/ai/_services/ai-provider.service-base.js +2 -1
  10. package/build/_modules/ai/_services/ai-provider.service-base.js.map +1 -1
  11. package/build/_modules/assistant/_collections/ass.util.d.ts +2 -2
  12. package/build/_modules/assistant/_collections/ass.util.d.ts.map +1 -1
  13. package/build/_modules/assistant/_services/ass-io.control-service.d.ts +5 -9
  14. package/build/_modules/assistant/_services/ass-io.control-service.d.ts.map +1 -1
  15. package/build/_modules/assistant/_services/ass-io.control-service.js +9 -10
  16. package/build/_modules/assistant/_services/ass-io.control-service.js.map +1 -1
  17. package/build/_modules/assistant/_services/ass-main.control-service.d.ts +26 -10
  18. package/build/_modules/assistant/_services/ass-main.control-service.d.ts.map +1 -1
  19. package/build/_modules/assistant/_services/ass-main.control-service.js +49 -4
  20. package/build/_modules/assistant/_services/ass-main.control-service.js.map +1 -1
  21. package/build/_modules/assistant/index.d.ts +1 -1
  22. package/build/_modules/assistant/index.d.ts.map +1 -1
  23. package/build/_modules/assistant/index.js +1 -1
  24. package/build/_modules/assistant/index.js.map +1 -1
  25. package/build/_modules/bot/_models/bot-channel-wrapper.interface.d.ts +17 -0
  26. package/build/_modules/bot/_models/bot-channel-wrapper.interface.d.ts.map +1 -0
  27. package/build/_modules/bot/_models/{bot-message.interface.js → bot-channel-wrapper.interface.js} +1 -1
  28. package/build/_modules/bot/_models/bot-channel-wrapper.interface.js.map +1 -0
  29. package/build/_modules/bot/_models/bot-command.interface.d.ts +2 -2
  30. package/build/_modules/bot/_models/bot-command.interface.d.ts.map +1 -1
  31. package/build/_modules/bot/_models/bot-global-settings.interface.d.ts +1 -1
  32. package/build/_modules/bot/_models/bot-global-settings.interface.d.ts.map +1 -1
  33. package/build/_modules/bot/_models/bot-message-wrapper.interface.d.ts +16 -13
  34. package/build/_modules/bot/_models/bot-message-wrapper.interface.d.ts.map +1 -1
  35. package/build/_modules/bot/_models/bot-user-wrapper.interface.d.ts +17 -0
  36. package/build/_modules/bot/_models/bot-user-wrapper.interface.d.ts.map +1 -0
  37. package/build/_modules/bot/_models/{bot-channel.interface.js → bot-user-wrapper.interface.js} +1 -1
  38. package/build/_modules/bot/_models/bot-user-wrapper.interface.js.map +1 -0
  39. package/build/_modules/bot/_modules/discord-bot/_models/dib-platform.types.d.ts +0 -7
  40. package/build/_modules/bot/_modules/discord-bot/_models/dib-platform.types.d.ts.map +1 -1
  41. package/build/_modules/bot/_modules/discord-bot/_models/dib-platform.types.js +10 -2
  42. package/build/_modules/bot/_modules/discord-bot/_models/dib-platform.types.js.map +1 -1
  43. package/build/_modules/bot/_modules/discord-bot/_services/dib-messaging-provider.control-service.d.ts +68 -0
  44. package/build/_modules/bot/_modules/discord-bot/_services/dib-messaging-provider.control-service.d.ts.map +1 -0
  45. package/build/_modules/bot/_modules/discord-bot/_services/dib-messaging-provider.control-service.js +397 -0
  46. package/build/_modules/bot/_modules/discord-bot/_services/dib-messaging-provider.control-service.js.map +1 -0
  47. package/build/_modules/bot/_modules/discord-bot/index.d.ts +1 -4
  48. package/build/_modules/bot/_modules/discord-bot/index.d.ts.map +1 -1
  49. package/build/_modules/bot/_modules/discord-bot/index.js +2 -5
  50. package/build/_modules/bot/_modules/discord-bot/index.js.map +1 -1
  51. package/build/_modules/bot/_modules/dynamo-bot/_collections/dyb-operations.util.d.ts +3 -3
  52. package/build/_modules/bot/_modules/dynamo-bot/_collections/dyb-operations.util.d.ts.map +1 -1
  53. package/build/_modules/bot/_modules/dynamo-bot/_collections/dyb-operations.util.js +2 -2
  54. package/build/_modules/bot/_modules/dynamo-bot/_collections/dyb-operations.util.js.map +1 -1
  55. package/build/_modules/bot/_modules/dynamo-bot/_models/dyb-platform.types.d.ts +6 -6
  56. package/build/_modules/bot/_modules/dynamo-bot/_models/dyb-platform.types.d.ts.map +1 -1
  57. package/build/_modules/bot/_modules/dynamo-bot/_services/dyb-messaging-provider.control-service.d.ts +60 -0
  58. package/build/_modules/bot/_modules/dynamo-bot/_services/dyb-messaging-provider.control-service.d.ts.map +1 -0
  59. package/build/_modules/bot/_modules/dynamo-bot/_services/{dyb-messaging-provider.service.js → dyb-messaging-provider.control-service.js} +134 -108
  60. package/build/_modules/bot/_modules/dynamo-bot/_services/dyb-messaging-provider.control-service.js.map +1 -0
  61. package/build/_modules/bot/_modules/dynamo-bot/index.d.ts +1 -2
  62. package/build/_modules/bot/_modules/dynamo-bot/index.d.ts.map +1 -1
  63. package/build/_modules/bot/_modules/dynamo-bot/index.js +1 -2
  64. package/build/_modules/bot/_modules/dynamo-bot/index.js.map +1 -1
  65. package/build/_modules/bot/_modules/slack-bot/_models/slb-platform.types.d.ts +6 -6
  66. package/build/_modules/bot/_modules/slack-bot/_models/slb-platform.types.d.ts.map +1 -1
  67. package/build/_modules/bot/_modules/slack-bot/_services/slb-messaging-provider.control-service.d.ts +56 -0
  68. package/build/_modules/bot/_modules/slack-bot/_services/slb-messaging-provider.control-service.d.ts.map +1 -0
  69. package/build/_modules/bot/_modules/slack-bot/_services/slb-messaging-provider.control-service.js +135 -0
  70. package/build/_modules/bot/_modules/slack-bot/_services/slb-messaging-provider.control-service.js.map +1 -0
  71. package/build/_modules/bot/_modules/slack-bot/index.d.ts +1 -2
  72. package/build/_modules/bot/_modules/slack-bot/index.d.ts.map +1 -1
  73. package/build/_modules/bot/_modules/slack-bot/index.js +1 -3
  74. package/build/_modules/bot/_modules/slack-bot/index.js.map +1 -1
  75. package/build/_modules/bot/_modules/teams-bot/_models/teb-platform.types.d.ts +6 -6
  76. package/build/_modules/bot/_modules/teams-bot/_models/teb-platform.types.d.ts.map +1 -1
  77. package/build/_modules/bot/_modules/teams-bot/_services/teb-messaging-provider.control-service.d.ts +56 -0
  78. package/build/_modules/bot/_modules/teams-bot/_services/teb-messaging-provider.control-service.d.ts.map +1 -0
  79. package/build/_modules/bot/_modules/teams-bot/_services/teb-messaging-provider.control-service.js +135 -0
  80. package/build/_modules/bot/_modules/teams-bot/_services/teb-messaging-provider.control-service.js.map +1 -0
  81. package/build/_modules/bot/_modules/teams-bot/index.d.ts +1 -2
  82. package/build/_modules/bot/_modules/teams-bot/index.d.ts.map +1 -1
  83. package/build/_modules/bot/_modules/teams-bot/index.js +1 -3
  84. package/build/_modules/bot/_modules/teams-bot/index.js.map +1 -1
  85. package/build/_modules/bot/_services/bot-commands.control-service.d.ts +8 -11
  86. package/build/_modules/bot/_services/bot-commands.control-service.d.ts.map +1 -1
  87. package/build/_modules/bot/_services/bot-commands.control-service.js +60 -15
  88. package/build/_modules/bot/_services/bot-commands.control-service.js.map +1 -1
  89. package/build/_modules/bot/_services/bot-io.control-service.d.ts +16 -17
  90. package/build/_modules/bot/_services/bot-io.control-service.d.ts.map +1 -1
  91. package/build/_modules/bot/_services/bot-io.control-service.js +60 -51
  92. package/build/_modules/bot/_services/bot-io.control-service.js.map +1 -1
  93. package/build/_modules/bot/_services/bot-main.control-service.d.ts +18 -37
  94. package/build/_modules/bot/_services/bot-main.control-service.d.ts.map +1 -1
  95. package/build/_modules/bot/_services/bot-main.control-service.js +127 -264
  96. package/build/_modules/bot/_services/bot-main.control-service.js.map +1 -1
  97. package/build/_modules/bot/_services/bot-messaging-provider.service-base.d.ts +71 -0
  98. package/build/_modules/bot/_services/bot-messaging-provider.service-base.d.ts.map +1 -0
  99. package/build/_modules/bot/_services/bot-messaging-provider.service-base.js +16 -0
  100. package/build/_modules/bot/_services/bot-messaging-provider.service-base.js.map +1 -0
  101. package/build/_modules/bot/_services/bot-routines.control-service.d.ts +6 -9
  102. package/build/_modules/bot/_services/bot-routines.control-service.d.ts.map +1 -1
  103. package/build/_modules/bot/_services/bot-routines.control-service.js +29 -9
  104. package/build/_modules/bot/_services/bot-routines.control-service.js.map +1 -1
  105. package/build/_modules/bot/index.d.ts +3 -7
  106. package/build/_modules/bot/index.d.ts.map +1 -1
  107. package/build/_modules/bot/index.js +9 -7
  108. package/build/_modules/bot/index.js.map +1 -1
  109. package/build/_modules/messaging/_collections/msg-global-settings.const.d.ts.map +1 -1
  110. package/build/_modules/messaging/_collections/msg-global-settings.const.js +0 -5
  111. package/build/_modules/messaging/_collections/msg-global-settings.const.js.map +1 -1
  112. package/build/_modules/messaging/_collections/msg.util.d.ts +2 -2
  113. package/build/_modules/messaging/_collections/msg.util.d.ts.map +1 -1
  114. package/build/_modules/messaging/_collections/msg.util.js.map +1 -1
  115. package/build/_modules/messaging/_models/msg-global-settings.interface.d.ts +0 -9
  116. package/build/_modules/messaging/_models/msg-global-settings.interface.d.ts.map +1 -1
  117. package/build/_modules/messaging/_services/msg-integration.control-service.d.ts +0 -25
  118. package/build/_modules/messaging/_services/msg-integration.control-service.d.ts.map +1 -1
  119. package/build/_modules/messaging/_services/msg-integration.control-service.js +180 -125
  120. package/build/_modules/messaging/_services/msg-integration.control-service.js.map +1 -1
  121. package/build/_modules/messaging/index.d.ts +0 -1
  122. package/build/_modules/messaging/index.d.ts.map +1 -1
  123. package/build/_modules/messaging/index.js +1 -1
  124. package/build/_modules/messaging/index.js.map +1 -1
  125. package/package.json +1 -1
  126. package/src/_modules/ai/_modules/open-ai/_services/oai-llm.service-base.ts +4 -4
  127. package/src/_modules/ai/_services/ai-llm.service-base.ts +2 -2
  128. package/src/_modules/ai/_services/ai-provider.service-base.ts +2 -1
  129. package/src/_modules/assistant/_collections/ass.util.ts +2 -2
  130. package/src/_modules/assistant/_services/ass-io.control-service.ts +17 -48
  131. package/src/_modules/assistant/_services/ass-main.control-service.ts +82 -32
  132. package/src/_modules/assistant/index.ts +1 -1
  133. package/src/_modules/bot/_models/bot-channel-wrapper.interface.ts +24 -0
  134. package/src/_modules/bot/_models/bot-command.interface.ts +2 -2
  135. package/src/_modules/bot/_models/bot-global-settings.interface.ts +1 -1
  136. package/src/_modules/bot/_models/bot-message-wrapper.interface.ts +18 -18
  137. package/src/_modules/bot/_models/bot-user-wrapper.interface.ts +35 -0
  138. package/src/_modules/bot/_modules/discord-bot/_models/dib-platform.types.ts +8 -7
  139. package/src/_modules/bot/_modules/discord-bot/_services/dib-messaging-provider.control-service.ts +529 -0
  140. package/src/_modules/bot/_modules/discord-bot/index.ts +2 -5
  141. package/src/_modules/bot/_modules/dynamo-bot/_collections/dyb-operations.util.ts +8 -5
  142. package/src/_modules/bot/_modules/dynamo-bot/_models/dyb-platform.types.ts +6 -6
  143. package/src/_modules/bot/_modules/dynamo-bot/_services/dyb-messaging-provider.control-service.ts +436 -0
  144. package/src/_modules/bot/_modules/dynamo-bot/index.ts +1 -2
  145. package/src/_modules/bot/_modules/slack-bot/_models/slb-platform.types.ts +6 -6
  146. package/src/_modules/bot/_modules/slack-bot/_services/slb-messaging-provider.control-service.ts +190 -0
  147. package/src/_modules/bot/_modules/slack-bot/index.ts +1 -3
  148. package/src/_modules/bot/_modules/teams-bot/_models/teb-platform.types.ts +6 -6
  149. package/src/_modules/bot/_modules/teams-bot/_services/teb-messaging-provider.control-service.ts +190 -0
  150. package/src/_modules/bot/_modules/teams-bot/index.ts +1 -4
  151. package/src/_modules/bot/_services/bot-commands.control-service.ts +64 -34
  152. package/src/_modules/bot/_services/bot-io.control-service.ts +86 -95
  153. package/src/_modules/bot/_services/bot-main.control-service.ts +253 -240
  154. package/src/_modules/bot/_services/bot-messaging-provider.service-base.ts +153 -0
  155. package/src/_modules/bot/_services/bot-routines.control-service.ts +39 -44
  156. package/src/_modules/bot/index.ts +9 -7
  157. package/src/_modules/messaging/README.md +2 -7
  158. package/src/_modules/messaging/_collections/msg-global-settings.const.ts +0 -6
  159. package/src/_modules/messaging/_collections/msg.util.ts +2 -2
  160. package/src/_modules/messaging/_models/msg-global-settings.interface.ts +0 -12
  161. package/src/_modules/messaging/_services/msg-integration.control-service.ts +180 -179
  162. package/src/_modules/messaging/index.ts +1 -1
  163. package/build/_modules/ai/_modules/open-ai/_services/oai-doc-chunk-data.service.d.ts +0 -22
  164. package/build/_modules/ai/_modules/open-ai/_services/oai-doc-chunk-data.service.d.ts.map +0 -1
  165. package/build/_modules/ai/_modules/open-ai/_services/oai-doc-chunk-data.service.js +0 -187
  166. package/build/_modules/ai/_modules/open-ai/_services/oai-doc-chunk-data.service.js.map +0 -1
  167. package/build/_modules/ai/_modules/open-ai/_services/oai-doc-page.data-service.d.ts +0 -27
  168. package/build/_modules/ai/_modules/open-ai/_services/oai-doc-page.data-service.d.ts.map +0 -1
  169. package/build/_modules/ai/_modules/open-ai/_services/oai-doc-page.data-service.js +0 -277
  170. package/build/_modules/ai/_modules/open-ai/_services/oai-doc-page.data-service.js.map +0 -1
  171. package/build/_modules/ai/_modules/open-ai/_services/oai-document.data-service.d.ts +0 -23
  172. package/build/_modules/ai/_modules/open-ai/_services/oai-document.data-service.d.ts.map +0 -1
  173. package/build/_modules/ai/_modules/open-ai/_services/oai-document.data-service.js +0 -319
  174. package/build/_modules/ai/_modules/open-ai/_services/oai-document.data-service.js.map +0 -1
  175. package/build/_modules/ai/_modules/open-ai/_services/oai-vector-data.service.d.ts +0 -118
  176. package/build/_modules/ai/_modules/open-ai/_services/oai-vector-data.service.d.ts.map +0 -1
  177. package/build/_modules/ai/_modules/open-ai/_services/oai-vector-data.service.js +0 -460
  178. package/build/_modules/ai/_modules/open-ai/_services/oai-vector-data.service.js.map +0 -1
  179. package/build/_modules/assistant/_services/ass.service-base.d.ts +0 -33
  180. package/build/_modules/assistant/_services/ass.service-base.d.ts.map +0 -1
  181. package/build/_modules/assistant/_services/ass.service-base.js +0 -58
  182. package/build/_modules/assistant/_services/ass.service-base.js.map +0 -1
  183. package/build/_modules/bot/_collections/bot-operations.util.d.ts +0 -21
  184. package/build/_modules/bot/_collections/bot-operations.util.d.ts.map +0 -1
  185. package/build/_modules/bot/_collections/bot-operations.util.js +0 -74
  186. package/build/_modules/bot/_collections/bot-operations.util.js.map +0 -1
  187. package/build/_modules/bot/_models/bot-channel.interface.d.ts +0 -8
  188. package/build/_modules/bot/_models/bot-channel.interface.d.ts.map +0 -1
  189. package/build/_modules/bot/_models/bot-channel.interface.js.map +0 -1
  190. package/build/_modules/bot/_models/bot-message.interface.d.ts +0 -15
  191. package/build/_modules/bot/_models/bot-message.interface.d.ts.map +0 -1
  192. package/build/_modules/bot/_models/bot-message.interface.js.map +0 -1
  193. package/build/_modules/bot/_models/bot-messaging-provider.interface.d.ts +0 -68
  194. package/build/_modules/bot/_models/bot-messaging-provider.interface.d.ts.map +0 -1
  195. package/build/_modules/bot/_models/bot-messaging-provider.interface.js +0 -3
  196. package/build/_modules/bot/_models/bot-messaging-provider.interface.js.map +0 -1
  197. package/build/_modules/bot/_models/bot-user.interface.d.ts +0 -8
  198. package/build/_modules/bot/_models/bot-user.interface.d.ts.map +0 -1
  199. package/build/_modules/bot/_models/bot-user.interface.js +0 -3
  200. package/build/_modules/bot/_models/bot-user.interface.js.map +0 -1
  201. package/build/_modules/bot/_modules/discord-bot/_collections/dib-operations.util.d.ts +0 -11
  202. package/build/_modules/bot/_modules/discord-bot/_collections/dib-operations.util.d.ts.map +0 -1
  203. package/build/_modules/bot/_modules/discord-bot/_collections/dib-operations.util.js +0 -13
  204. package/build/_modules/bot/_modules/discord-bot/_collections/dib-operations.util.js.map +0 -1
  205. package/build/_modules/bot/_modules/discord-bot/_collections/dib.util.d.ts +0 -5
  206. package/build/_modules/bot/_modules/discord-bot/_collections/dib.util.d.ts.map +0 -1
  207. package/build/_modules/bot/_modules/discord-bot/_collections/dib.util.js +0 -19
  208. package/build/_modules/bot/_modules/discord-bot/_collections/dib.util.js.map +0 -1
  209. package/build/_modules/bot/_modules/discord-bot/_services/dib-messaging-provider.service.d.ts +0 -56
  210. package/build/_modules/bot/_modules/discord-bot/_services/dib-messaging-provider.service.d.ts.map +0 -1
  211. package/build/_modules/bot/_modules/discord-bot/_services/dib-messaging-provider.service.js +0 -379
  212. package/build/_modules/bot/_modules/discord-bot/_services/dib-messaging-provider.service.js.map +0 -1
  213. package/build/_modules/bot/_modules/dynamo-bot/_collections/dyb.util.d.ts +0 -5
  214. package/build/_modules/bot/_modules/dynamo-bot/_collections/dyb.util.d.ts.map +0 -1
  215. package/build/_modules/bot/_modules/dynamo-bot/_collections/dyb.util.js +0 -26
  216. package/build/_modules/bot/_modules/dynamo-bot/_collections/dyb.util.js.map +0 -1
  217. package/build/_modules/bot/_modules/dynamo-bot/_services/dyb-messaging-provider.service.d.ts +0 -55
  218. package/build/_modules/bot/_modules/dynamo-bot/_services/dyb-messaging-provider.service.d.ts.map +0 -1
  219. package/build/_modules/bot/_modules/dynamo-bot/_services/dyb-messaging-provider.service.js.map +0 -1
  220. package/build/_modules/bot/_modules/slack-bot/_collections/slb-operations.util.d.ts +0 -11
  221. package/build/_modules/bot/_modules/slack-bot/_collections/slb-operations.util.d.ts.map +0 -1
  222. package/build/_modules/bot/_modules/slack-bot/_collections/slb-operations.util.js +0 -13
  223. package/build/_modules/bot/_modules/slack-bot/_collections/slb-operations.util.js.map +0 -1
  224. package/build/_modules/bot/_modules/slack-bot/_services/slb-messaging-provider.service.d.ts +0 -41
  225. package/build/_modules/bot/_modules/slack-bot/_services/slb-messaging-provider.service.d.ts.map +0 -1
  226. package/build/_modules/bot/_modules/slack-bot/_services/slb-messaging-provider.service.js +0 -119
  227. package/build/_modules/bot/_modules/slack-bot/_services/slb-messaging-provider.service.js.map +0 -1
  228. package/build/_modules/bot/_modules/teams-bot/_collections/teb-operations.util.d.ts +0 -11
  229. package/build/_modules/bot/_modules/teams-bot/_collections/teb-operations.util.d.ts.map +0 -1
  230. package/build/_modules/bot/_modules/teams-bot/_collections/teb-operations.util.js +0 -13
  231. package/build/_modules/bot/_modules/teams-bot/_collections/teb-operations.util.js.map +0 -1
  232. package/build/_modules/bot/_modules/teams-bot/_services/teb-messaging-provider.service.d.ts +0 -41
  233. package/build/_modules/bot/_modules/teams-bot/_services/teb-messaging-provider.service.d.ts.map +0 -1
  234. package/build/_modules/bot/_modules/teams-bot/_services/teb-messaging-provider.service.js +0 -119
  235. package/build/_modules/bot/_modules/teams-bot/_services/teb-messaging-provider.service.js.map +0 -1
  236. package/build/_modules/bot/_services/bot-messaging-provider-factory.service.d.ts +0 -6
  237. package/build/_modules/bot/_services/bot-messaging-provider-factory.service.d.ts.map +0 -1
  238. package/build/_modules/bot/_services/bot-messaging-provider-factory.service.js +0 -47
  239. package/build/_modules/bot/_services/bot-messaging-provider-factory.service.js.map +0 -1
  240. package/src/_modules/assistant/_services/ass.service-base.ts +0 -100
  241. package/src/_modules/bot/_collections/bot-operations.util.ts +0 -149
  242. package/src/_modules/bot/_models/bot-channel.interface.ts +0 -7
  243. package/src/_modules/bot/_models/bot-message.interface.ts +0 -14
  244. package/src/_modules/bot/_models/bot-messaging-provider.interface.ts +0 -88
  245. package/src/_modules/bot/_models/bot-user.interface.ts +0 -7
  246. package/src/_modules/bot/_modules/discord-bot/_collections/dib-operations.util.ts +0 -18
  247. package/src/_modules/bot/_modules/discord-bot/_collections/dib.util.ts +0 -20
  248. package/src/_modules/bot/_modules/discord-bot/_services/dib-messaging-provider.service.ts +0 -475
  249. package/src/_modules/bot/_modules/dynamo-bot/_collections/dyb.util.ts +0 -26
  250. package/src/_modules/bot/_modules/dynamo-bot/_services/dyb-messaging-provider.service.ts +0 -403
  251. package/src/_modules/bot/_modules/slack-bot/_collections/slb-operations.util.ts +0 -18
  252. package/src/_modules/bot/_modules/slack-bot/_services/slb-messaging-provider.service.ts +0 -156
  253. package/src/_modules/bot/_modules/teams-bot/_collections/teb-operations.util.ts +0 -18
  254. package/src/_modules/bot/_modules/teams-bot/_services/teb-messaging-provider.service.ts +0 -156
  255. package/src/_modules/bot/_services/bot-messaging-provider-factory.service.ts +0 -56
@@ -5,26 +5,46 @@ const fsm_dynamo_1 = require("@futdevpro/fsm-dynamo");
5
5
  const singleton_service_1 = require("../../../_services/base/singleton.service");
6
6
  const global_settings_const_1 = require("../../../_collections/global-settings.const");
7
7
  class DyNTS_Bot_Routines_ControlService extends singleton_service_1.DyNTS_SingletonService {
8
- mainBot_CS = this.getMainBotControlService();
9
- get provider() {
10
- return this.mainBot_CS?.provider;
8
+ mainBot_CS;
9
+ /* get provider(): any {
10
+ return this.mainBot_CS?.provider;
11
+ } */
12
+ get defaultProvider() {
13
+ return this.mainBot_CS.defaultProvider;
11
14
  }
12
15
  _routinesStarted;
13
16
  get routinesStarted() {
14
17
  return this._routinesStarted;
15
18
  }
16
- constructor() {
17
- super();
18
- if (!this.provider) {
19
+ /* protected constructor() {
20
+ super();
21
+ } */
22
+ async setup(issuer) {
23
+ try {
24
+ this.mainBot_CS = this.getMainBotControlService();
25
+ if (!this.mainBot_CS) {
26
+ throw new fsm_dynamo_1.DyFM_Error({
27
+ ...this.getDefaultErrorSettings('setup', new Error('Main Bot Control Service not found'), issuer),
28
+ errorCode: `${global_settings_const_1.DyNTS_global_settings.systemShortCodeName}|DyNTS-Bot-RCS-S01`,
29
+ });
30
+ }
31
+ }
32
+ catch (error) {
19
33
  throw new fsm_dynamo_1.DyFM_Error({
20
- ...this.getDefaultErrorSettings('constructor', new Error('Bot provider not yet initialized, ' +
21
- 'should only be called after DyNTS_Bot_Main_ControlService.start'), 'system-init'),
22
- errorCode: `${global_settings_const_1.DyNTS_global_settings.systemShortCodeName}|DyNTS-Bot-RCS-C000`,
34
+ ...this.getDefaultErrorSettings('setup', error, issuer),
35
+ errorCode: `${global_settings_const_1.DyNTS_global_settings.systemShortCodeName}|DyNTS-Bot-RCS-S000`,
23
36
  });
24
37
  }
25
38
  }
26
39
  async start(issuer) {
27
40
  try {
41
+ if (!this.defaultProvider) {
42
+ throw new fsm_dynamo_1.DyFM_Error({
43
+ ...this.getDefaultErrorSettings('start', new Error('Bot routines not yet started, ' +
44
+ 'should only be called after DyNTS_Bot_Main_ControlService.start'), 'system-init'),
45
+ errorCode: `${global_settings_const_1.DyNTS_global_settings.systemShortCodeName}|DyNTS-Bot-RCS-ST00`,
46
+ });
47
+ }
28
48
  await this.startRoutines(issuer);
29
49
  this._routinesStarted = true;
30
50
  }
@@ -1 +1 @@
1
- {"version":3,"file":"bot-routines.control-service.js","sourceRoot":"","sources":["../../../../src/_modules/bot/_services/bot-routines.control-service.ts"],"names":[],"mappings":";;;AAGA,sDAA+D;AAC/D,iFAAmF;AAEnF,uFAAoF;AAMpF,MAAsB,iCAapB,SAAQ,0CAAsB;IASX,UAAU,GAKzB,IAAI,CAAC,wBAAwB,EAAE,CAAC;IAEpC,IAAI,QAAQ;QACV,OAAO,IAAI,CAAC,UAAU,EAAE,QAAQ,CAAC;IACnC,CAAC;IAEO,gBAAgB,CAAU;IAClC,IAAI,eAAe;QACjB,OAAO,IAAI,CAAC,gBAAgB,CAAC;IAC/B,CAAC;IAED;QACE,KAAK,EAAE,CAAC;QAER,IAAI,CAAC,IAAI,CAAC,QAAQ,EAAE,CAAC;YACnB,MAAM,IAAI,uBAAU,CAAC;gBACnB,GAAG,IAAI,CAAC,uBAAuB,CAC7B,aAAa,EACb,IAAI,KAAK,CACP,oCAAoC;oBACpC,iEAAiE,CAClE,EACD,aAAa,CACd;gBACD,SAAS,EAAE,GAAG,6CAAqB,CAAC,mBAAmB,qBAAqB;aAC7E,CAAC,CAAA;QACJ,CAAC;IACH,CAAC;IAED,KAAK,CAAC,KAAK,CAAC,MAAc;QACxB,IAAI,CAAC;YACH,MAAM,IAAI,CAAC,aAAa,CAAC,MAAM,CAAC,CAAC;YAEjC,IAAI,CAAC,gBAAgB,GAAG,IAAI,CAAC;QAC/B,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,MAAM,IAAI,uBAAU,CAAC;gBACnB,GAAG,IAAI,CAAC,uBAAuB,CAAC,OAAO,EAAE,KAAK,EAAE,MAAM,CAAC;gBACvD,SAAS,EAAE,GAAG,6CAAqB,CAAC,mBAAmB,oBAAoB;aAC5E,CAAC,CAAA;QACJ,CAAC;IACH,CAAC;CAGF;AAtED,8EAsEC"}
1
+ {"version":3,"file":"bot-routines.control-service.js","sourceRoot":"","sources":["../../../../src/_modules/bot/_services/bot-routines.control-service.ts"],"names":[],"mappings":";;;AAGA,sDAA+D;AAC/D,iFAAmF;AAEnF,uFAAoF;AAGpF,MAAsB,iCAAkC,SAAQ,0CAAsB;IAE1E,UAAU,CAAgC;IAGpD;;QAEI;IAEJ,IAAI,eAAe;QACjB,OAAO,IAAI,CAAC,UAAU,CAAC,eAAe,CAAC;IACzC,CAAC;IAEO,gBAAgB,CAAU;IAClC,IAAI,eAAe;QACjB,OAAO,IAAI,CAAC,gBAAgB,CAAC;IAC/B,CAAC;IAED;;QAEI;IAEJ,KAAK,CAAC,KAAK,CAAC,MAAc;QACxB,IAAI,CAAC;YACH,IAAI,CAAC,UAAU,GAAG,IAAI,CAAC,wBAAwB,EAAE,CAAC;YAElD,IAAI,CAAC,IAAI,CAAC,UAAU,EAAE,CAAC;gBACrB,MAAM,IAAI,uBAAU,CAAC;oBACnB,GAAG,IAAI,CAAC,uBAAuB,CAAC,OAAO,EAAE,IAAI,KAAK,CAAC,oCAAoC,CAAC,EAAE,MAAM,CAAC;oBACjG,SAAS,EAAE,GAAG,6CAAqB,CAAC,mBAAmB,oBAAoB;iBAC5E,CAAC,CAAA;YACJ,CAAC;QACH,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,MAAM,IAAI,uBAAU,CAAC;gBACnB,GAAG,IAAI,CAAC,uBAAuB,CAAC,OAAO,EAAE,KAAK,EAAE,MAAM,CAAC;gBACvD,SAAS,EAAE,GAAG,6CAAqB,CAAC,mBAAmB,qBAAqB;aAC7E,CAAC,CAAA;QACJ,CAAC;IACH,CAAC;IAED,KAAK,CAAC,KAAK,CAAC,MAAc;QACxB,IAAI,CAAC;YACH,IAAI,CAAC,IAAI,CAAC,eAAe,EAAE,CAAC;gBAC1B,MAAM,IAAI,uBAAU,CAAC;oBACnB,GAAG,IAAI,CAAC,uBAAuB,CAC7B,OAAO,EACP,IAAI,KAAK,CACP,gCAAgC;wBAChC,iEAAiE,CAClE,EACD,aAAa,CACd;oBACD,SAAS,EAAE,GAAG,6CAAqB,CAAC,mBAAmB,qBAAqB;iBAC7E,CAAC,CAAA;YACJ,CAAC;YAED,MAAM,IAAI,CAAC,aAAa,CAAC,MAAM,CAAC,CAAC;YAEjC,IAAI,CAAC,gBAAgB,GAAG,IAAI,CAAC;QAC/B,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,MAAM,IAAI,uBAAU,CAAC;gBACnB,GAAG,IAAI,CAAC,uBAAuB,CAAC,OAAO,EAAE,KAAK,EAAE,MAAM,CAAC;gBACvD,SAAS,EAAE,GAAG,6CAAqB,CAAC,mBAAmB,oBAAoB;aAC5E,CAAC,CAAA;QACJ,CAAC;IACH,CAAC;CAGF;AApED,8EAoEC"}
@@ -1,23 +1,19 @@
1
1
  export * from './_enums/bot-message-provider.enum';
2
- export * from './_models/bot-message.interface';
3
2
  export * from './_models/bot-message-wrapper.interface';
4
- export * from './_models/bot-channel.interface';
5
- export * from './_models/bot-user.interface';
6
- export * from './_models/bot-messaging-provider.interface';
3
+ export * from './_models/bot-channel-wrapper.interface';
4
+ export * from './_models/bot-user-wrapper.interface';
5
+ export * from './_services/bot-messaging-provider.service-base';
7
6
  export * from './_models/bot-command.interface';
8
7
  export * from './_models/bot-global-settings.interface';
9
8
  export * from './_models/bot-last-message-date.interface';
10
9
  export * from './_models/bot-last-mention-date.interface';
11
- export * from './_collections/bot-operations.util';
12
10
  export * from './_collections/bot-global-settings.const';
13
11
  export * from './_collections/bot-default-commands.const';
14
12
  export * from './_services/bot-main.control-service';
15
13
  export * from './_services/bot-io.control-service';
16
14
  export * from './_services/bot-commands.control-service';
17
15
  export * from './_services/bot-routines.control-service';
18
- export * from './_services/bot-messaging-provider-factory.service';
19
16
  export * from './_modules/discord-bot';
20
17
  export * from './_modules/slack-bot';
21
18
  export * from './_modules/teams-bot';
22
- export * from './_modules/dynamo-bot';
23
19
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/_modules/bot/index.ts"],"names":[],"mappings":"AAQA,cAAc,oCAAoC,CAAC;AAGnD,cAAc,iCAAiC,CAAC;AAChD,cAAc,yCAAyC,CAAC;AACxD,cAAc,iCAAiC,CAAC;AAChD,cAAc,8BAA8B,CAAC;AAC7C,cAAc,4CAA4C,CAAC;AAC3D,cAAc,iCAAiC,CAAC;AAChD,cAAc,yCAAyC,CAAC;AACxD,cAAc,2CAA2C,CAAC;AAC1D,cAAc,2CAA2C,CAAC;AAG1D,cAAc,oCAAoC,CAAC;AACnD,cAAc,0CAA0C,CAAC;AACzD,cAAc,2CAA2C,CAAC;AAG1D,cAAc,sCAAsC,CAAC;AACrD,cAAc,oCAAoC,CAAC;AACnD,cAAc,0CAA0C,CAAC;AACzD,cAAc,0CAA0C,CAAC;AACzD,cAAc,oDAAoD,CAAC;AAGnE,cAAc,wBAAwB,CAAC;AACvC,cAAc,sBAAsB,CAAC;AACrC,cAAc,sBAAsB,CAAC;AACrC,cAAc,uBAAuB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/_modules/bot/index.ts"],"names":[],"mappings":"AAQA,cAAc,oCAAoC,CAAC;AAInD,cAAc,yCAAyC,CAAC;AAExD,cAAc,yCAAyC,CAAC;AAExD,cAAc,sCAAsC,CAAC;AACrD,cAAc,iDAAiD,CAAC;AAChE,cAAc,iCAAiC,CAAC;AAChD,cAAc,yCAAyC,CAAC;AACxD,cAAc,2CAA2C,CAAC;AAC1D,cAAc,2CAA2C,CAAC;AAI1D,cAAc,0CAA0C,CAAC;AACzD,cAAc,2CAA2C,CAAC;AAG1D,cAAc,sCAAsC,CAAC;AACrD,cAAc,oCAAoC,CAAC;AACnD,cAAc,0CAA0C,CAAC;AACzD,cAAc,0CAA0C,CAAC;AAIzD,cAAc,wBAAwB,CAAC;AACvC,cAAc,sBAAsB,CAAC;AACrC,cAAc,sBAAsB,CAAC"}
@@ -10,17 +10,19 @@ const tslib_1 = require("tslib");
10
10
  // ENUMS
11
11
  tslib_1.__exportStar(require("./_enums/bot-message-provider.enum"), exports);
12
12
  // MODELS
13
- tslib_1.__exportStar(require("./_models/bot-message.interface"), exports);
13
+ /* export * from './_models/bot-message.interface'; */
14
14
  tslib_1.__exportStar(require("./_models/bot-message-wrapper.interface"), exports);
15
- tslib_1.__exportStar(require("./_models/bot-channel.interface"), exports);
16
- tslib_1.__exportStar(require("./_models/bot-user.interface"), exports);
17
- tslib_1.__exportStar(require("./_models/bot-messaging-provider.interface"), exports);
15
+ /* export * from './_models/bot-channel.interface'; */
16
+ tslib_1.__exportStar(require("./_models/bot-channel-wrapper.interface"), exports);
17
+ /* export * from './_models/bot-user.interface'; */
18
+ tslib_1.__exportStar(require("./_models/bot-user-wrapper.interface"), exports);
19
+ tslib_1.__exportStar(require("./_services/bot-messaging-provider.service-base"), exports);
18
20
  tslib_1.__exportStar(require("./_models/bot-command.interface"), exports);
19
21
  tslib_1.__exportStar(require("./_models/bot-global-settings.interface"), exports);
20
22
  tslib_1.__exportStar(require("./_models/bot-last-message-date.interface"), exports);
21
23
  tslib_1.__exportStar(require("./_models/bot-last-mention-date.interface"), exports);
22
24
  // COLLECTIONS
23
- tslib_1.__exportStar(require("./_collections/bot-operations.util"), exports);
25
+ /* export * from './_collections/bot-operations.util'; */
24
26
  tslib_1.__exportStar(require("./_collections/bot-global-settings.const"), exports);
25
27
  tslib_1.__exportStar(require("./_collections/bot-default-commands.const"), exports);
26
28
  // SERVICES
@@ -28,10 +30,10 @@ tslib_1.__exportStar(require("./_services/bot-main.control-service"), exports);
28
30
  tslib_1.__exportStar(require("./_services/bot-io.control-service"), exports);
29
31
  tslib_1.__exportStar(require("./_services/bot-commands.control-service"), exports);
30
32
  tslib_1.__exportStar(require("./_services/bot-routines.control-service"), exports);
31
- tslib_1.__exportStar(require("./_services/bot-messaging-provider-factory.service"), exports);
33
+ /* export * from './_services/bot-messaging-provider-factory.service'; */
32
34
  // PROVIDERS
33
35
  tslib_1.__exportStar(require("./_modules/discord-bot"), exports);
34
36
  tslib_1.__exportStar(require("./_modules/slack-bot"), exports);
35
37
  tslib_1.__exportStar(require("./_modules/teams-bot"), exports);
36
- tslib_1.__exportStar(require("./_modules/dynamo-bot"), exports);
38
+ /* export * from './_modules/dynamo-bot'; */
37
39
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/_modules/bot/index.ts"],"names":[],"mappings":";AAAA,EAAE;AACF,iCAAiC;AACjC,EAAE;AACF,2DAA2D;AAC3D,+DAA+D;AAC/D,EAAE;;;AAEF,QAAQ;AACR,6EAAmD;AAEnD,SAAS;AACT,0EAAgD;AAChD,kFAAwD;AACxD,0EAAgD;AAChD,uEAA6C;AAC7C,qFAA2D;AAC3D,0EAAgD;AAChD,kFAAwD;AACxD,oFAA0D;AAC1D,oFAA0D;AAE1D,cAAc;AACd,6EAAmD;AACnD,mFAAyD;AACzD,oFAA0D;AAE1D,WAAW;AACX,+EAAqD;AACrD,6EAAmD;AACnD,mFAAyD;AACzD,mFAAyD;AACzD,6FAAmE;AAEnE,YAAY;AACZ,iEAAuC;AACvC,+DAAqC;AACrC,+DAAqC;AACrC,gEAAsC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/_modules/bot/index.ts"],"names":[],"mappings":";AAAA,EAAE;AACF,iCAAiC;AACjC,EAAE;AACF,2DAA2D;AAC3D,+DAA+D;AAC/D,EAAE;;;AAEF,QAAQ;AACR,6EAAmD;AAEnD,SAAS;AACT,sDAAsD;AACtD,kFAAwD;AACxD,sDAAsD;AACtD,kFAAwD;AACxD,mDAAmD;AACnD,+EAAqD;AACrD,0FAAgE;AAChE,0EAAgD;AAChD,kFAAwD;AACxD,oFAA0D;AAC1D,oFAA0D;AAE1D,cAAc;AACd,yDAAyD;AACzD,mFAAyD;AACzD,oFAA0D;AAE1D,WAAW;AACX,+EAAqD;AACrD,6EAAmD;AACnD,mFAAyD;AACzD,mFAAyD;AACzD,yEAAyE;AAEzE,YAAY;AACZ,iEAAuC;AACvC,+DAAqC;AACrC,+DAAqC;AACrC,4CAA4C"}
@@ -1 +1 @@
1
- {"version":3,"file":"msg-global-settings.const.d.ts","sourceRoot":"","sources":["../../../../src/_modules/messaging/_collections/msg-global-settings.const.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,yBAAyB,EAAE,MAAM,0CAA0C,CAAC;AAErF;;GAEG;AACH,eAAO,MAAM,yBAAyB,EAAE,yBAqBvC,CAAC"}
1
+ {"version":3,"file":"msg-global-settings.const.d.ts","sourceRoot":"","sources":["../../../../src/_modules/messaging/_collections/msg-global-settings.const.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,yBAAyB,EAAE,MAAM,0CAA0C,CAAC;AAErF;;GAEG;AACH,eAAO,MAAM,yBAAyB,EAAE,yBAevC,CAAC"}
@@ -14,11 +14,6 @@ exports.DyNTS_Msg_global_settings = {
14
14
  enableMentions: true,
15
15
  enableReadReceipts: true,
16
16
  enableTypingIndicators: true,
17
- integration: {
18
- syncBotMessages: true,
19
- syncAssistantMessages: true,
20
- enableAgentProcessViz: true,
21
- },
22
17
  retry: {
23
18
  maxRetries: 3,
24
19
  retryDelay: 1000, // 1 second
@@ -1 +1 @@
1
- {"version":3,"file":"msg-global-settings.const.js","sourceRoot":"","sources":["../../../../src/_modules/messaging/_collections/msg-global-settings.const.ts"],"names":[],"mappings":";;;AAEA;;GAEG;AACU,QAAA,yBAAyB,GAA8B;IAClE,oBAAoB,EAAE,IAAI;IAC1B,kBAAkB,EAAE,EAAE;IACtB,eAAe,EAAE,IAAI;IACrB,eAAe,EAAE,IAAI;IACrB,iBAAiB,EAAE,IAAI;IACvB,iBAAiB,EAAE,EAAE,GAAG,IAAI,GAAG,IAAI,EAAE,OAAO;IAC5C,cAAc,EAAE,IAAI;IACpB,kBAAkB,EAAE,IAAI;IACxB,sBAAsB,EAAE,IAAI;IAE5B,WAAW,EAAE;QACX,eAAe,EAAE,IAAI;QACrB,qBAAqB,EAAE,IAAI;QAC3B,qBAAqB,EAAE,IAAI;KAC5B;IAED,KAAK,EAAE;QACL,UAAU,EAAE,CAAC;QACb,UAAU,EAAE,IAAI,EAAE,WAAW;KAC9B;CACF,CAAC"}
1
+ {"version":3,"file":"msg-global-settings.const.js","sourceRoot":"","sources":["../../../../src/_modules/messaging/_collections/msg-global-settings.const.ts"],"names":[],"mappings":";;;AAEA;;GAEG;AACU,QAAA,yBAAyB,GAA8B;IAClE,oBAAoB,EAAE,IAAI;IAC1B,kBAAkB,EAAE,EAAE;IACtB,eAAe,EAAE,IAAI;IACrB,eAAe,EAAE,IAAI;IACrB,iBAAiB,EAAE,IAAI;IACvB,iBAAiB,EAAE,EAAE,GAAG,IAAI,GAAG,IAAI,EAAE,OAAO;IAC5C,cAAc,EAAE,IAAI;IACpB,kBAAkB,EAAE,IAAI;IACxB,sBAAsB,EAAE,IAAI;IAE5B,KAAK,EAAE;QACL,UAAU,EAAE,CAAC;QACb,UAAU,EAAE,IAAI,EAAE,WAAW;KAC9B;CACF,CAAC"}
@@ -1,5 +1,5 @@
1
1
  import { DyFM_Msg_Message, DyFM_Msg_Conversation } from '@futdevpro/fsm-dynamo/messaging';
2
- import { DyNTS_Bot_Message } from '../../bot/_models/bot-message.interface';
2
+ import { DyNTS_Bot_MessageWrapper } from '../../bot/_models/bot-message-wrapper.interface';
3
3
  /**
4
4
  * Messaging utility functions
5
5
  */
@@ -7,7 +7,7 @@ export declare class DyNTS_Msg_Util {
7
7
  /**
8
8
  * Convert bot message to messaging system message
9
9
  */
10
- static botMessageToMsgMessage<T>(botMessage: DyNTS_Bot_Message<T>, conversationId: string, issuer: string): DyFM_Msg_Message;
10
+ static botMessageToMsgMessage<T>(botMessage: DyNTS_Bot_MessageWrapper<T>, conversationId: string, issuer: string): DyFM_Msg_Message;
11
11
  /**
12
12
  * Create AI message from assistant response
13
13
  */
@@ -1 +1 @@
1
- {"version":3,"file":"msg.util.d.ts","sourceRoot":"","sources":["../../../../src/_modules/messaging/_collections/msg.util.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,gBAAgB,EAChB,qBAAqB,EAGtB,MAAM,iCAAiC,CAAC;AACzC,OAAO,EAAE,iBAAiB,EAAE,MAAM,yCAAyC,CAAC;AAE5E;;GAEG;AACH,qBAAa,cAAc;IAEzB;;OAEG;IACH,MAAM,CAAC,sBAAsB,CAAC,CAAC,EAC7B,UAAU,EAAE,iBAAiB,CAAC,CAAC,CAAC,EAChC,cAAc,EAAE,MAAM,EACtB,MAAM,EAAE,MAAM,GACb,gBAAgB;IAiBnB;;OAEG;IACH,MAAM,CAAC,eAAe,CACpB,cAAc,EAAE,MAAM,EACtB,OAAO,EAAE,MAAM,EACf,UAAU,EAAE,MAAM,EAClB,OAAO,EAAE,MAAM,EACf,QAAQ,EAAE,MAAM,EAChB,MAAM,EAAE,MAAM,GACb,gBAAgB;IAgBnB;;;OAGG;IACH,MAAM,CAAC,eAAe,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,EAAE;IAMjD;;OAEG;IACH,MAAM,CAAC,yBAAyB,CAC9B,YAAY,EAAE,qBAAqB,EACnC,MAAM,EAAE,MAAM,GACb,OAAO;CAGX"}
1
+ {"version":3,"file":"msg.util.d.ts","sourceRoot":"","sources":["../../../../src/_modules/messaging/_collections/msg.util.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,gBAAgB,EAChB,qBAAqB,EAGtB,MAAM,iCAAiC,CAAC;AACzC,OAAO,EAAE,wBAAwB,EAAE,MAAM,iDAAiD,CAAC;AAE3F;;GAEG;AACH,qBAAa,cAAc;IAEzB;;OAEG;IACH,MAAM,CAAC,sBAAsB,CAAC,CAAC,EAC7B,UAAU,EAAE,wBAAwB,CAAC,CAAC,CAAC,EACvC,cAAc,EAAE,MAAM,EACtB,MAAM,EAAE,MAAM,GACb,gBAAgB;IAiBnB;;OAEG;IACH,MAAM,CAAC,eAAe,CACpB,cAAc,EAAE,MAAM,EACtB,OAAO,EAAE,MAAM,EACf,UAAU,EAAE,MAAM,EAClB,OAAO,EAAE,MAAM,EACf,QAAQ,EAAE,MAAM,EAChB,MAAM,EAAE,MAAM,GACb,gBAAgB;IAgBnB;;;OAGG;IACH,MAAM,CAAC,eAAe,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,EAAE;IAMjD;;OAEG;IACH,MAAM,CAAC,yBAAyB,CAC9B,YAAY,EAAE,qBAAqB,EACnC,MAAM,EAAE,MAAM,GACb,OAAO;CAGX"}
@@ -1 +1 @@
1
- {"version":3,"file":"msg.util.js","sourceRoot":"","sources":["../../../../src/_modules/messaging/_collections/msg.util.ts"],"names":[],"mappings":";;;AAAA,+DAKyC;AAGzC;;GAEG;AACH,MAAa,cAAc;IAEzB;;OAEG;IACH,MAAM,CAAC,sBAAsB,CAC3B,UAAgC,EAChC,cAAsB,EACtB,MAAc;QAEd,OAAO,IAAI,4BAAgB,CAAC;YAC1B,cAAc;YACd,OAAO,EAAE,UAAU,CAAC,OAAO,IAAI,EAAE;YACjC,IAAI,EAAE,yBAAa,CAAC,UAAU;YAC9B,MAAM,EAAE,2BAAe,CAAC,IAAI;YAC5B,QAAQ,EAAE,UAAU,CAAC,QAAQ;YAC7B,UAAU,EAAE,UAAU,CAAC,UAAU;YACjC,iBAAiB,EAAE,UAAU,CAAC,iBAAiB;YAC/C,iBAAiB,EAAG,UAAU,CAAC,kBAA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AAO,CAAC,KAAK,CAAC,YAAY,CAAC,CAAC;QAC5C,OAAO,OAAO,CAAC,CAAC,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC;IACzD,CAAC;IAED;;OAEG;IACH,MAAM,CAAC,yBAAyB,CAC9B,YAAmC,EACnC,MAAc;QAEd,OAAO,YAAY,CAAC,YAAY,EAAE,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,MAAM,KAAK,MAAM,CAAC,IAAI,KAAK,CAAC;IAC5E,CAAC;CACF;AAvED,wCAuEC"}
@@ -20,15 +20,6 @@ export interface DyNTS_Msg_Global_Settings {
20
20
  enableReadReceipts?: boolean;
21
21
  /** Enable typing indicators */
22
22
  enableTypingIndicators?: boolean;
23
- /** Integration settings */
24
- integration?: {
25
- /** Auto-sync bot messages to messaging system */
26
- syncBotMessages?: boolean;
27
- /** Auto-sync assistant messages to messaging system */
28
- syncAssistantMessages?: boolean;
29
- /** Enable agent process visualization */
30
- enableAgentProcessViz?: boolean;
31
- };
32
23
  /** Retry settings for failed messages */
33
24
  retry?: {
34
25
  maxRetries?: number;
@@ -1 +1 @@
1
- {"version":3,"file":"msg-global-settings.interface.d.ts","sourceRoot":"","sources":["../../../../src/_modules/messaging/_models/msg-global-settings.interface.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,MAAM,WAAW,yBAAyB;IACxC,kDAAkD;IAClD,oBAAoB,CAAC,EAAE,OAAO,CAAC;IAE/B,gDAAgD;IAChD,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAE5B,oCAAoC;IACpC,eAAe,CAAC,EAAE,OAAO,CAAC;IAE1B,+BAA+B;IAC/B,eAAe,CAAC,EAAE,OAAO,CAAC;IAE1B,8BAA8B;IAC9B,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAE5B,uCAAuC;IACvC,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAE3B,sBAAsB;IACtB,cAAc,CAAC,EAAE,OAAO,CAAC;IAEzB,2BAA2B;IAC3B,kBAAkB,CAAC,EAAE,OAAO,CAAC;IAE7B,+BAA+B;IAC/B,sBAAsB,CAAC,EAAE,OAAO,CAAC;IAEjC,2BAA2B;IAC3B,WAAW,CAAC,EAAE;QACZ,iDAAiD;QACjD,eAAe,CAAC,EAAE,OAAO,CAAC;QAE1B,uDAAuD;QACvD,qBAAqB,CAAC,EAAE,OAAO,CAAC;QAEhC,yCAAyC;QACzC,qBAAqB,CAAC,EAAE,OAAO,CAAC;KACjC,CAAC;IAEF,yCAAyC;IACzC,KAAK,CAAC,EAAE;QACN,UAAU,CAAC,EAAE,MAAM,CAAC;QACpB,UAAU,CAAC,EAAE,MAAM,CAAC;KACrB,CAAC;CACH"}
1
+ {"version":3,"file":"msg-global-settings.interface.d.ts","sourceRoot":"","sources":["../../../../src/_modules/messaging/_models/msg-global-settings.interface.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,MAAM,WAAW,yBAAyB;IACxC,kDAAkD;IAClD,oBAAoB,CAAC,EAAE,OAAO,CAAC;IAE/B,gDAAgD;IAChD,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAE5B,oCAAoC;IACpC,eAAe,CAAC,EAAE,OAAO,CAAC;IAE1B,+BAA+B;IAC/B,eAAe,CAAC,EAAE,OAAO,CAAC;IAE1B,8BAA8B;IAC9B,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAE5B,uCAAuC;IACvC,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAE3B,sBAAsB;IACtB,cAAc,CAAC,EAAE,OAAO,CAAC;IAEzB,2BAA2B;IAC3B,kBAAkB,CAAC,EAAE,OAAO,CAAC;IAE7B,+BAA+B;IAC/B,sBAAsB,CAAC,EAAE,OAAO,CAAC;IAEjC,yCAAyC;IACzC,KAAK,CAAC,EAAE;QACN,UAAU,CAAC,EAAE,MAAM,CAAC;QACpB,UAAU,CAAC,EAAE,MAAM,CAAC;KACrB,CAAC;CACH"}
@@ -1,26 +1 @@
1
- import { DyNTS_SingletonService } from '../../../_services/base/singleton.service';
2
- import { DyFM_Msg_Message, DyFM_Msg_Conversation } from '@futdevpro/fsm-dynamo/messaging';
3
- import { DyNTS_Bot_Message } from '../../bot/_models/bot-message.interface';
4
- /**
5
- * Messaging Integration Control Service
6
- * Handles integration between messaging system and bot/assistant modules
7
- */
8
- export declare class DyNTS_Msg_Integration_ControlService extends DyNTS_SingletonService {
9
- static getInstance(): DyNTS_Msg_Integration_ControlService;
10
- private eventsService;
11
- /**
12
- * Sync bot message to messaging system
13
- * Called from bot IO when message is received
14
- */
15
- syncBotMessage<T>(botMessage: DyNTS_Bot_Message<T>, conversationId: string, issuer: string): Promise<DyFM_Msg_Message>;
16
- /**
17
- * Sync assistant response to messaging system
18
- * Called from assistant IO when AI responds
19
- */
20
- syncAssistantMessage(content: string, conversationId: string, aiProvider: string, aiModel: string, senderId: string, issuer: string): Promise<DyFM_Msg_Message>;
21
- /**
22
- * Find or create conversation for bot channel
23
- */
24
- findOrCreateBotConversation(channelId: string, platformSource: string, issuer: string): Promise<DyFM_Msg_Conversation>;
25
- }
26
1
  //# sourceMappingURL=msg-integration.control-service.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"msg-integration.control-service.d.ts","sourceRoot":"","sources":["../../../../src/_modules/messaging/_services/msg-integration.control-service.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,sBAAsB,EAAE,MAAM,2CAA2C,CAAC;AAEnF,OAAO,EAAE,gBAAgB,EAAE,qBAAqB,EAAE,MAAM,iCAAiC,CAAC;AAM1F,OAAO,EAAE,iBAAiB,EAAE,MAAM,yCAAyC,CAAC;AAE5E;;;GAGG;AACH,qBAAa,oCAAqC,SAAQ,sBAAsB;IAE9E,MAAM,CAAC,WAAW,IAAI,oCAAoC;IAI1D,OAAO,CAAC,aAAa,CAA0C;IAE/D;;;OAGG;IACG,cAAc,CAAC,CAAC,EACpB,UAAU,EAAE,iBAAiB,CAAC,CAAC,CAAC,EAChC,cAAc,EAAE,MAAM,EACtB,MAAM,EAAE,MAAM,GACb,OAAO,CAAC,gBAAgB,CAAC;IA8C5B;;;OAGG;IACG,oBAAoB,CACxB,OAAO,EAAE,MAAM,EACf,cAAc,EAAE,MAAM,EACtB,UAAU,EAAE,MAAM,EAClB,OAAO,EAAE,MAAM,EACf,QAAQ,EAAE,MAAM,EAChB,MAAM,EAAE,MAAM,GACb,OAAO,CAAC,gBAAgB,CAAC;IAiD5B;;OAEG;IACG,2BAA2B,CAC/B,SAAS,EAAE,MAAM,EACjB,cAAc,EAAE,MAAM,EACtB,MAAM,EAAE,MAAM,GACb,OAAO,CAAC,qBAAqB,CAAC;CAmClC"}
1
+ {"version":3,"file":"msg-integration.control-service.d.ts","sourceRoot":"","sources":["../../../../src/_modules/messaging/_services/msg-integration.control-service.ts"],"names":[],"mappings":""}
@@ -1,126 +1,181 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.DyNTS_Msg_Integration_ControlService = void 0;
4
- const singleton_service_1 = require("../../../_services/base/singleton.service");
5
- const fsm_dynamo_1 = require("@futdevpro/fsm-dynamo");
6
- const global_settings_const_1 = require("../../../_collections/global-settings.const");
7
- const msg_message_data_service_1 = require("./msg-message.data-service");
8
- const msg_conversation_data_service_1 = require("./msg-conversation.data-service");
9
- const msg_events_service_1 = require("./msg-events.service");
10
- const msg_util_1 = require("../_collections/msg.util");
11
- /**
12
- * Messaging Integration Control Service
13
- * Handles integration between messaging system and bot/assistant modules
14
- */
15
- class DyNTS_Msg_Integration_ControlService extends singleton_service_1.DyNTS_SingletonService {
16
- static getInstance() {
17
- return DyNTS_Msg_Integration_ControlService.getSingletonInstance();
18
- }
19
- eventsService = msg_events_service_1.DyNTS_Msg_Events_Service.getInstance();
20
- /**
21
- * Sync bot message to messaging system
22
- * Called from bot IO when message is received
23
- */
24
- async syncBotMessage(botMessage, conversationId, issuer) {
25
- try {
26
- if (!global_settings_const_1.DyNTS_global_settings.messaging_settings?.integration?.syncBotMessages) {
27
- throw new Error('Bot message sync is disabled');
28
- }
29
- // Convert bot message to messaging format
30
- const msgMessage = msg_util_1.DyNTS_Msg_Util.botMessageToMsgMessage(botMessage, conversationId, issuer);
31
- // Save to database
32
- const messageService = new msg_message_data_service_1.DyNTS_Msg_Message_DataService({
33
- message: msgMessage,
34
- issuer,
35
- });
36
- await messageService.saveData(messageService.data, false, false);
37
- // Update conversation last message
38
- const conversationService = new msg_conversation_data_service_1.DyNTS_Msg_Conversation_DataService({
39
- issuer,
40
- });
41
- await conversationService.updateLastMessage(conversationId, messageService.data._id, msgMessage.content.substring(0, 100));
42
- // Emit real-time event
43
- this.eventsService.emitMessageSent(messageService.data, conversationId);
44
- return messageService.data;
45
- }
46
- catch (error) {
47
- fsm_dynamo_1.DyFM_Log.error('Failed to sync bot message', error);
48
- throw new fsm_dynamo_1.DyFM_Error({
49
- ...this.getDefaultErrorSettings('syncBotMessage', error, issuer),
50
- errorCode: `${global_settings_const_1.DyNTS_global_settings.systemShortCodeName}|DyNTS-MSG-SBM`,
51
- userMessage: 'Failed to sync bot message to messaging system.',
52
- });
53
- }
54
- }
55
- /**
56
- * Sync assistant response to messaging system
57
- * Called from assistant IO when AI responds
58
- */
59
- async syncAssistantMessage(content, conversationId, aiProvider, aiModel, senderId, issuer) {
60
- try {
61
- if (!global_settings_const_1.DyNTS_global_settings.messaging_settings?.integration?.syncAssistantMessages) {
62
- throw new Error('Assistant message sync is disabled');
63
- }
64
- // Create AI message
65
- const msgMessage = msg_util_1.DyNTS_Msg_Util.createAIMessage(conversationId, content, aiProvider, aiModel, senderId, issuer);
66
- // Save to database
67
- const messageService = new msg_message_data_service_1.DyNTS_Msg_Message_DataService({
68
- message: msgMessage,
69
- issuer,
70
- });
71
- await messageService.saveData(messageService.data, false, false);
72
- // Update conversation last message
73
- const conversationService = new msg_conversation_data_service_1.DyNTS_Msg_Conversation_DataService({
74
- issuer,
75
- });
76
- await conversationService.updateLastMessage(conversationId, messageService.data._id, content.substring(0, 100));
77
- // Emit real-time event
78
- this.eventsService.emitMessageSent(messageService.data, conversationId);
79
- return messageService.data;
80
- }
81
- catch (error) {
82
- fsm_dynamo_1.DyFM_Log.error('Failed to sync assistant message', error);
83
- throw new fsm_dynamo_1.DyFM_Error({
84
- ...this.getDefaultErrorSettings('syncAssistantMessage', error, issuer),
85
- errorCode: `${global_settings_const_1.DyNTS_global_settings.systemShortCodeName}|DyNTS-MSG-SAM`,
86
- userMessage: 'Failed to sync assistant message to messaging system.',
87
- });
88
- }
89
- }
90
- /**
91
- * Find or create conversation for bot channel
92
- */
93
- async findOrCreateBotConversation(channelId, platformSource, issuer) {
94
- try {
95
- const conversationService = new msg_conversation_data_service_1.DyNTS_Msg_Conversation_DataService({
96
- issuer,
97
- });
98
- // Try to find existing conversation
99
- const existingConversation = await conversationService.dataDBService.findOne({
100
- platformChannelId: channelId,
101
- platformSource,
102
- __deleted: { $exists: false },
103
- });
104
- if (existingConversation) {
105
- conversationService.data = existingConversation;
106
- }
107
- // Create new if not found
108
- if (!conversationService.data._id) {
109
- conversationService.data.platformChannelId = channelId;
110
- conversationService.data.platformSource = platformSource;
111
- conversationService.data.participants = [];
112
- await conversationService.saveData(conversationService.data, false, false);
113
- }
114
- return conversationService.data;
115
- }
116
- catch (error) {
117
- throw new fsm_dynamo_1.DyFM_Error({
118
- ...this.getDefaultErrorSettings('findOrCreateBotConversation', error, issuer),
119
- errorCode: `${global_settings_const_1.DyNTS_global_settings.systemShortCodeName}|DyNTS-MSG-FCBC`,
120
- userMessage: 'Failed to find or create bot conversation.',
121
- });
122
- }
123
- }
124
- }
125
- exports.DyNTS_Msg_Integration_ControlService = DyNTS_Msg_Integration_ControlService;
1
+ //import { DyNTS_SingletonService } from '../../../_services/base/singleton.service';
2
+ //import { DyFM_Error, DyFM_Log, DyFM_DBFilter } from '@futdevpro/fsm-dynamo';
3
+ //import { DyFM_Msg_Message, DyFM_Msg_Conversation } from '@futdevpro/fsm-dynamo/messaging';
4
+ //import { DyNTS_global_settings } from '../../../_collections/global-settings.const';
5
+ //import { DyNTS_Msg_Message_DataService } from './msg-message.data-service';
6
+ //import { DyNTS_Msg_Conversation_DataService } from './msg-conversation.data-service';
7
+ //import { DyNTS_Msg_Events_Service } from './msg-events.service';
8
+ //import { DyNTS_Msg_Util } from '../_collections/msg.util';
9
+ //import { DyNTS_Bot_MessageWrapper } from '../../bot/_models/bot-message.interface';
10
+ //
11
+ ///**
12
+ // * Messaging Integration Control Service
13
+ // * Handles integration between messaging system and bot/assistant modules
14
+ // */
15
+ //export class DyNTS_Msg_Integration_ControlService extends DyNTS_SingletonService {
16
+ //
17
+ // static getInstance(): DyNTS_Msg_Integration_ControlService {
18
+ // return DyNTS_Msg_Integration_ControlService.getSingletonInstance();
19
+ // }
20
+ //
21
+ // private eventsService = DyNTS_Msg_Events_Service.getInstance();
22
+ //
23
+ // /**
24
+ // * Sync bot message to messaging system
25
+ // * Called from bot IO when message is received
26
+ // */
27
+ // async syncBotMessage<T>(
28
+ // botMessage: DyNTS_Bot_MessageWrapper<T>,
29
+ // conversationId: string,
30
+ // issuer: string
31
+ // ): Promise<DyFM_Msg_Message> {
32
+ // try {
33
+ // if (!DyNTS_global_settings.messaging_settings?.integration?.syncBotMessages) {
34
+ // throw new Error('Bot message sync is disabled');
35
+ // }
36
+ //
37
+ // // Convert bot message to messaging format
38
+ // const msgMessage = DyNTS_Msg_Util.botMessageToMsgMessage(
39
+ // botMessage,
40
+ // conversationId,
41
+ // issuer
42
+ // );
43
+ //
44
+ // // Save to database
45
+ // const messageService = new DyNTS_Msg_Message_DataService({
46
+ // message: msgMessage,
47
+ // issuer,
48
+ // });
49
+ //
50
+ // await messageService.saveData(messageService.data, false, false);
51
+ //
52
+ // // Update conversation last message
53
+ // const conversationService = new DyNTS_Msg_Conversation_DataService({
54
+ // issuer,
55
+ // });
56
+ //
57
+ // await conversationService.updateLastMessage(
58
+ // conversationId,
59
+ // messageService.data._id!,
60
+ // msgMessage.content.substring(0, 100)
61
+ // );
62
+ //
63
+ // // Emit real-time event
64
+ // this.eventsService.emitMessageSent(messageService.data, conversationId);
65
+ //
66
+ // return messageService.data;
67
+ // } catch (error) {
68
+ // DyFM_Log.error('Failed to sync bot message', error);
69
+ // throw new DyFM_Error({
70
+ // ...this.getDefaultErrorSettings('syncBotMessage', error, issuer),
71
+ // errorCode: `${DyNTS_global_settings.systemShortCodeName}|DyNTS-MSG-SBM`,
72
+ // userMessage: 'Failed to sync bot message to messaging system.',
73
+ // });
74
+ // }
75
+ // }
76
+ //
77
+ // /**
78
+ // * Sync assistant response to messaging system
79
+ // * Called from assistant IO when AI responds
80
+ // */
81
+ // async syncAssistantMessage(
82
+ // content: string,
83
+ // conversationId: string,
84
+ // aiProvider: string,
85
+ // aiModel: string,
86
+ // senderId: string,
87
+ // issuer: string
88
+ // ): Promise<DyFM_Msg_Message> {
89
+ // try {
90
+ // if (!DyNTS_global_settings.messaging_settings?.integration?.syncAssistantMessages) {
91
+ // throw new Error('Assistant message sync is disabled');
92
+ // }
93
+ //
94
+ // // Create AI message
95
+ // const msgMessage = DyNTS_Msg_Util.createAIMessage(
96
+ // conversationId,
97
+ // content,
98
+ // aiProvider,
99
+ // aiModel,
100
+ // senderId,
101
+ // issuer
102
+ // );
103
+ //
104
+ // // Save to database
105
+ // const messageService = new DyNTS_Msg_Message_DataService({
106
+ // message: msgMessage,
107
+ // issuer,
108
+ // });
109
+ //
110
+ // await messageService.saveData(messageService.data, false, false);
111
+ //
112
+ // // Update conversation last message
113
+ // const conversationService = new DyNTS_Msg_Conversation_DataService({
114
+ // issuer,
115
+ // });
116
+ //
117
+ // await conversationService.updateLastMessage(
118
+ // conversationId,
119
+ // messageService.data._id!,
120
+ // content.substring(0, 100)
121
+ // );
122
+ //
123
+ // // Emit real-time event
124
+ // this.eventsService.emitMessageSent(messageService.data, conversationId);
125
+ //
126
+ // return messageService.data;
127
+ // } catch (error) {
128
+ // DyFM_Log.error('Failed to sync assistant message', error);
129
+ // throw new DyFM_Error({
130
+ // ...this.getDefaultErrorSettings('syncAssistantMessage', error, issuer),
131
+ // errorCode: `${DyNTS_global_settings.systemShortCodeName}|DyNTS-MSG-SAM`,
132
+ // userMessage: 'Failed to sync assistant message to messaging system.',
133
+ // });
134
+ // }
135
+ // }
136
+ //
137
+ // /**
138
+ // * Find or create conversation for bot channel
139
+ // */
140
+ // async findOrCreateBotConversation(
141
+ // channelId: string,
142
+ // platformSource: string,
143
+ // issuer: string
144
+ // ): Promise<DyFM_Msg_Conversation> {
145
+ // try {
146
+ // const conversationService = new DyNTS_Msg_Conversation_DataService({
147
+ // issuer,
148
+ // });
149
+ //
150
+ // // Try to find existing conversation
151
+ // const existingConversation = await conversationService.dataDBService.findOne({
152
+ // platformChannelId: channelId,
153
+ // platformSource,
154
+ // __deleted: { $exists: false },
155
+ // } as DyFM_DBFilter<DyFM_Msg_Conversation>);
156
+ //
157
+ // if (existingConversation) {
158
+ // conversationService.data = existingConversation;
159
+ // }
160
+ //
161
+ // // Create new if not found
162
+ // if (!conversationService.data._id) {
163
+ // conversationService.data.platformChannelId = channelId;
164
+ // conversationService.data.platformSource = platformSource;
165
+ // conversationService.data.participants = [];
166
+ //
167
+ // await conversationService.saveData(conversationService.data, false, false);
168
+ // }
169
+ //
170
+ // return conversationService.data;
171
+ // } catch (error) {
172
+ // throw new DyFM_Error({
173
+ // ...this.getDefaultErrorSettings('findOrCreateBotConversation', error, issuer),
174
+ // errorCode: `${DyNTS_global_settings.systemShortCodeName}|DyNTS-MSG-FCBC`,
175
+ // userMessage: 'Failed to find or create bot conversation.',
176
+ // });
177
+ // }
178
+ // }
179
+ //}
180
+ //
126
181
  //# sourceMappingURL=msg-integration.control-service.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"msg-integration.control-service.js","sourceRoot":"","sources":["../../../../src/_modules/messaging/_services/msg-integration.control-service.ts"],"names":[],"mappings":";;;AAAA,iFAA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7E,CAAC;YAED,OAAO,mBAAmB,CAAC,IAAI,CAAC;QAClC,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,MAAM,IAAI,uBAAU,CAAC;gBACnB,GAAG,IAAI,CAAC,uBAAuB,CAAC,6BAA6B,EAAE,KAAK,EAAE,MAAM,CAAC;gBAC7E,SAAS,EAAE,GAAG,6CAAqB,CAAC,mBAAmB,iBAAiB;gBACxE,WAAW,EAAE,4CAA4C;aAC1D,CAAC,CAAC;QACL,CAAC;IACH,CAAC;CACF;AApKD,oFAoKC"}
1
+ {"version":3,"file":"msg-integration.control-service.js","sourceRoot":"","sources":["../../../../src/_modules/messaging/_services/msg-integration.control-service.ts"],"names":[],"mappings":"AAAA,qFAAqF;AACrF,8EAA8E;AAC9E,4FAA4F;AAC5F,sFAAsF;AACtF,6EAA6E;AAC7E,uFAAuF;AACvF,kEAAkE;AAClE,4DAA4D;AAC5D,qFAAqF;AACrF,EAAE;AACF,KAAK;AACL,0CAA0C;AAC1C,2EAA2E;AAC3E,KAAK;AACL,oFAAoF;AACpF,IAAI;AACJ,gEAAgE;AAChE,yEAAyE;AACzE,KAAK;AACL,IAAI;AACJ,mEAAmE;AACnE,IAAI;AACJ,OAAO;AACP,2CAA2C;AAC3C,kDAAkD;AAClD,OAAO;AACP,4BAA4B;AAC5B,8CAA8C;AAC9C,6BAA6B;AAC7B,oBAAoB;AACpB,kCAAkC;AAClC,WAAW;AACX,sFAAsF;AACtF,0DAA0D;AAC1D,SAAS;AACT,QAAQ;AACR,kDAAkD;AAClD,iEAAiE;AACjE,qBAAqB;AACrB,yBAAyB;AACzB,gBAAgB;AAChB,UAAU;AACV,QAAQ;AACR,2BAA2B;AAC3B,kEAAkE;AAClE,8BAA8B;AAC9B,iBAAiB;AACjB,WAAW;AACX,QAAQ;AACR,6EAA6E;AAC7E,QAAQ;AACR,2CAA2C;AAC3C,4EAA4E;AAC5E,iBAAiB;AACjB,WAAW;AACX,QAAQ;AACR,oDAAoD;AACpD,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