@cognigy/rest-api-client 4.93.0 → 4.95.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (117) hide show
  1. package/CHANGELOG.md +5 -0
  2. package/build/authentication/AuthenticationAPI.js +1 -1
  3. package/build/shared/charts/descriptors/agentAssist/helpers/knowledgeSearch/errorHandler.helper.js +1 -1
  4. package/build/shared/charts/descriptors/agentAssist/knowledgeAssist.js +1 -1
  5. package/build/shared/charts/descriptors/agentAssist/nextActionAssist.js +1 -1
  6. package/build/shared/charts/descriptors/analytics/overwriteAnalytics.js +1 -1
  7. package/build/shared/charts/descriptors/analytics/requestRating.js +1 -1
  8. package/build/shared/charts/descriptors/knowledgeSearch/searchExtractOutput.js +6 -6
  9. package/build/shared/charts/descriptors/liveAgent/assistInfo.js +1 -1
  10. package/build/shared/charts/descriptors/logic/thinkV2.js +1 -1
  11. package/build/shared/charts/descriptors/message/checkChannelChange/checkChannelChange.js +2 -2
  12. package/build/shared/charts/descriptors/message/say.js +2 -2
  13. package/build/shared/charts/descriptors/message/sendText.js +1 -1
  14. package/build/shared/charts/descriptors/microsoft/getToken.js +1 -1
  15. package/build/shared/charts/descriptors/microsoft/invalidateToken.js +1 -1
  16. package/build/shared/charts/descriptors/service/GPTConversation.js +14 -14
  17. package/build/shared/charts/descriptors/service/GPTPrompt.js +4 -4
  18. package/build/shared/charts/descriptors/service/aiAgent/aiAgentJob.js +4 -4
  19. package/build/shared/charts/descriptors/service/handover.js +1 -1
  20. package/build/shared/charts/descriptors/service/jwtSecret.js +5 -3
  21. package/build/shared/charts/descriptors/voice/nodes/bargeIn.js +1 -1
  22. package/build/shared/charts/descriptors/voice/nodes/continuousAsr.js +1 -1
  23. package/build/shared/charts/descriptors/voice/nodes/dtmf.js +1 -1
  24. package/build/shared/charts/descriptors/voice/nodes/hangup.js +1 -1
  25. package/build/shared/charts/descriptors/voice/nodes/muteSpeechInput.js +1 -1
  26. package/build/shared/charts/descriptors/voice/nodes/noUserInput.js +1 -1
  27. package/build/shared/charts/descriptors/voice/nodes/play.js +1 -1
  28. package/build/shared/charts/descriptors/voice/nodes/sendMetadata.js +1 -1
  29. package/build/shared/charts/descriptors/voice/nodes/sessionSpeechParameters.js +1 -1
  30. package/build/shared/charts/descriptors/voice/nodes/transfer.js +2 -2
  31. package/build/shared/charts/descriptors/voicegateway/nodes/agentAssist.js +1 -1
  32. package/build/shared/charts/descriptors/voicegateway/nodes/callRecording.js +2 -2
  33. package/build/shared/charts/descriptors/voicegateway/nodes/handover.js +2 -2
  34. package/build/shared/charts/descriptors/voicegateway/nodes/hangup.js +1 -1
  35. package/build/shared/charts/descriptors/voicegateway/nodes/playURL.js +1 -1
  36. package/build/shared/charts/descriptors/voicegateway/nodes/sendMessage.js +3 -2
  37. package/build/shared/charts/descriptors/voicegateway/nodes/sendMetaData.js +1 -1
  38. package/build/shared/charts/descriptors/voicegateway/nodes/setSessionParams.js +2 -2
  39. package/build/shared/charts/descriptors/voicegateway2/nodes/dtmf.js +1 -1
  40. package/build/shared/charts/descriptors/voicegateway2/nodes/hangup.js +1 -1
  41. package/build/shared/charts/descriptors/voicegateway2/nodes/muteSpeechInput.js +1 -1
  42. package/build/shared/charts/descriptors/voicegateway2/nodes/play.js +1 -1
  43. package/build/shared/charts/descriptors/voicegateway2/nodes/record.js +3 -3
  44. package/build/shared/charts/descriptors/voicegateway2/nodes/refer.js +2 -2
  45. package/build/shared/charts/descriptors/voicegateway2/nodes/sendMetadata.js +1 -1
  46. package/build/shared/charts/descriptors/voicegateway2/nodes/setSessionConfig.js +1 -1
  47. package/build/shared/charts/descriptors/voicegateway2/nodes/transfer.js +2 -2
  48. package/build/shared/interfaces/IProfile.js +1 -0
  49. package/build/shared/interfaces/IProfileSchema.js +5 -0
  50. package/build/shared/interfaces/handover.js +2 -1
  51. package/build/shared/interfaces/messageAPI/endpoints.js +1 -0
  52. package/build/shared/interfaces/resources/IConnection.js +3 -2
  53. package/build/shared/interfaces/resources/IGlobalResource.js +3 -0
  54. package/build/shared/interfaces/resources/ILargeLanguageModel.js +10 -1
  55. package/build/shared/interfaces/resources/INodeDescriptorSet.js +2 -1
  56. package/build/shared/interfaces/resources/TRestChannelType.js +7 -2
  57. package/dist/esm/authentication/AuthenticationAPI.js +1 -1
  58. package/dist/esm/shared/charts/descriptors/agentAssist/helpers/knowledgeSearch/errorHandler.helper.js +1 -1
  59. package/dist/esm/shared/charts/descriptors/agentAssist/knowledgeAssist.js +1 -1
  60. package/dist/esm/shared/charts/descriptors/agentAssist/nextActionAssist.js +1 -1
  61. package/dist/esm/shared/charts/descriptors/analytics/overwriteAnalytics.js +1 -1
  62. package/dist/esm/shared/charts/descriptors/analytics/requestRating.js +1 -1
  63. package/dist/esm/shared/charts/descriptors/knowledgeSearch/searchExtractOutput.js +6 -6
  64. package/dist/esm/shared/charts/descriptors/liveAgent/assistInfo.js +1 -1
  65. package/dist/esm/shared/charts/descriptors/logic/thinkV2.js +1 -1
  66. package/dist/esm/shared/charts/descriptors/message/checkChannelChange/checkChannelChange.js +2 -2
  67. package/dist/esm/shared/charts/descriptors/message/say.js +2 -2
  68. package/dist/esm/shared/charts/descriptors/message/sendText.js +1 -1
  69. package/dist/esm/shared/charts/descriptors/microsoft/getToken.js +1 -1
  70. package/dist/esm/shared/charts/descriptors/microsoft/invalidateToken.js +1 -1
  71. package/dist/esm/shared/charts/descriptors/service/GPTConversation.js +15 -15
  72. package/dist/esm/shared/charts/descriptors/service/GPTPrompt.js +4 -4
  73. package/dist/esm/shared/charts/descriptors/service/aiAgent/aiAgentJob.js +4 -4
  74. package/dist/esm/shared/charts/descriptors/service/handover.js +1 -1
  75. package/dist/esm/shared/charts/descriptors/service/jwtSecret.js +5 -3
  76. package/dist/esm/shared/charts/descriptors/voice/nodes/bargeIn.js +1 -1
  77. package/dist/esm/shared/charts/descriptors/voice/nodes/continuousAsr.js +1 -1
  78. package/dist/esm/shared/charts/descriptors/voice/nodes/dtmf.js +1 -1
  79. package/dist/esm/shared/charts/descriptors/voice/nodes/hangup.js +1 -1
  80. package/dist/esm/shared/charts/descriptors/voice/nodes/muteSpeechInput.js +1 -1
  81. package/dist/esm/shared/charts/descriptors/voice/nodes/noUserInput.js +1 -1
  82. package/dist/esm/shared/charts/descriptors/voice/nodes/play.js +1 -1
  83. package/dist/esm/shared/charts/descriptors/voice/nodes/sendMetadata.js +1 -1
  84. package/dist/esm/shared/charts/descriptors/voice/nodes/sessionSpeechParameters.js +1 -1
  85. package/dist/esm/shared/charts/descriptors/voice/nodes/transfer.js +2 -2
  86. package/dist/esm/shared/charts/descriptors/voicegateway/nodes/agentAssist.js +1 -1
  87. package/dist/esm/shared/charts/descriptors/voicegateway/nodes/callRecording.js +2 -2
  88. package/dist/esm/shared/charts/descriptors/voicegateway/nodes/handover.js +2 -2
  89. package/dist/esm/shared/charts/descriptors/voicegateway/nodes/hangup.js +1 -1
  90. package/dist/esm/shared/charts/descriptors/voicegateway/nodes/playURL.js +1 -1
  91. package/dist/esm/shared/charts/descriptors/voicegateway/nodes/sendMessage.js +3 -2
  92. package/dist/esm/shared/charts/descriptors/voicegateway/nodes/sendMetaData.js +1 -1
  93. package/dist/esm/shared/charts/descriptors/voicegateway/nodes/setSessionParams.js +2 -2
  94. package/dist/esm/shared/charts/descriptors/voicegateway2/nodes/dtmf.js +1 -1
  95. package/dist/esm/shared/charts/descriptors/voicegateway2/nodes/hangup.js +1 -1
  96. package/dist/esm/shared/charts/descriptors/voicegateway2/nodes/muteSpeechInput.js +1 -1
  97. package/dist/esm/shared/charts/descriptors/voicegateway2/nodes/play.js +1 -1
  98. package/dist/esm/shared/charts/descriptors/voicegateway2/nodes/record.js +3 -3
  99. package/dist/esm/shared/charts/descriptors/voicegateway2/nodes/refer.js +2 -2
  100. package/dist/esm/shared/charts/descriptors/voicegateway2/nodes/sendMetadata.js +1 -1
  101. package/dist/esm/shared/charts/descriptors/voicegateway2/nodes/setSessionConfig.js +1 -1
  102. package/dist/esm/shared/charts/descriptors/voicegateway2/nodes/transfer.js +2 -2
  103. package/dist/esm/shared/interfaces/IProfile.js +1 -0
  104. package/dist/esm/shared/interfaces/IProfileSchema.js +5 -0
  105. package/dist/esm/shared/interfaces/handover.js +2 -1
  106. package/dist/esm/shared/interfaces/messageAPI/endpoints.js +1 -0
  107. package/dist/esm/shared/interfaces/resources/IConnection.js +3 -2
  108. package/dist/esm/shared/interfaces/resources/IGlobalResource.js +2 -0
  109. package/dist/esm/shared/interfaces/resources/ILargeLanguageModel.js +10 -1
  110. package/dist/esm/shared/interfaces/resources/INodeDescriptorSet.js +2 -1
  111. package/dist/esm/shared/interfaces/resources/TRestChannelType.js +7 -2
  112. package/package.json +3 -2
  113. package/types/index.d.ts +201 -94
  114. package/build/shared/interfaces/license.js.map +0 -1
  115. package/build/test.js +0 -1
  116. package/dist/esm/shared/interfaces/license.js.map +0 -1
  117. package/dist/esm/test.js +0 -1
@@ -766,11 +766,11 @@ export const AI_AGENT_JOB = createNodeDescriptor({
766
766
  const generated_buffer_phrase = (_h = (_g = lastToolCall === null || lastToolCall === void 0 ? void 0 : lastToolCall.function) === null || _g === void 0 ? void 0 : _g.arguments) === null || _h === void 0 ? void 0 : _h.generated_buffer_phrase;
767
767
  if (generated_buffer_phrase) {
768
768
  // output the generated buffer phrase. Don't add it to the transcript, else the LLM will repeat it next time.
769
- (_j = api.output) === null || _j === void 0 ? void 0 : _j.call(api, generated_buffer_phrase, {
769
+ yield ((_j = api.output) === null || _j === void 0 ? void 0 : _j.call(api, generated_buffer_phrase, {
770
770
  _cognigy: {
771
771
  _preventTranscript: true
772
772
  }
773
- });
773
+ }));
774
774
  }
775
775
  }
776
776
  if (knowledgeSearchTags && knowledgeSearchTags.length > 0) {
@@ -1076,7 +1076,7 @@ export const AI_AGENT_JOB = createNodeDescriptor({
1076
1076
  }
1077
1077
  // Optionally output the result immediately
1078
1078
  if (llmResult.result && outputImmediately && !llmPromptOptions.stream) {
1079
- (_2 = api.output) === null || _2 === void 0 ? void 0 : _2.call(api, llmResult.result, {});
1079
+ yield ((_2 = api.output) === null || _2 === void 0 ? void 0 : _2.call(api, llmResult.result, {}));
1080
1080
  }
1081
1081
  // If we are streaming and we got a result, also store it into the transcript, since streamed chunks are not stored there
1082
1082
  if (llmResult.result && llmPromptOptions.stream) {
@@ -1122,7 +1122,7 @@ export const AI_AGENT_JOB = createNodeDescriptor({
1122
1122
  if (errorHandling === "continue") {
1123
1123
  // output the timeout message
1124
1124
  if (errorMessage) {
1125
- (_8 = api.output) === null || _8 === void 0 ? void 0 : _8.call(api, errorMessage, null);
1125
+ yield ((_8 = api.output) === null || _8 === void 0 ? void 0 : _8.call(api, errorMessage, null));
1126
1126
  }
1127
1127
  // Set default node as next node
1128
1128
  const defaultChild = childConfigs.find(child => child.type === "aiAgentJobDefault");
@@ -99,7 +99,7 @@ export const HANDOVER = createNodeDescriptor({
99
99
  function: ({ cognigy, config, childConfigs, nodeId }) => __awaiter(void 0, void 0, void 0, function* () {
100
100
  const { api, input } = cognigy;
101
101
  if (input.channel === "adminconsole") {
102
- api.output("You are using the deprecated Handover Node. Please find the new Handover to Agent Node in the Node Selection Menu.", null);
102
+ yield api.output("You are using the deprecated Handover Node. Please find the new Handover to Agent Node in the Node Selection Menu.", null);
103
103
  }
104
104
  yield api.handover({ cognigy, config, nodeId, childConfigs });
105
105
  })
@@ -1,7 +1,9 @@
1
1
  /* JWT Secret Connection */
2
2
  export const JWT_SECRET_CONNECTION = {
3
- type: "jwt_secret",
4
- label: "JWT Secret for authentication",
5
- fields: [{ fieldName: "jwtSecret" }],
3
+ type: "AgentCopilotAuthentication",
4
+ label: "UI__NODE_EDITOR__AGENT_COPILOT_AUTHENTICATION_SECRET__LABEL",
5
+ fields: [
6
+ { fieldName: "jwtSecret", label: "UI__CONNECTION_EDITOR__FIELD_JWT SECRET" },
7
+ ],
6
8
  };
7
9
  //# sourceMappingURL=jwtSecret.js.map
@@ -94,7 +94,7 @@ export const BARGE_IN = createNodeDescriptor({
94
94
  const payload = setSessionConfig.handleInput(endpointType, voiceConfigParamsToVoiceSettings(config, api));
95
95
  /* we need to store this for the DTMF Collect - Config node */
96
96
  api.setSystemContext("vgSettings", { bargeInOnDtmf: config.bargeInOnDtmf });
97
- api.say(null, {
97
+ yield api.say(null, {
98
98
  _cognigy: payload,
99
99
  });
100
100
  logFullConfigToDebugMode(cognigy, config);
@@ -58,7 +58,7 @@ export const CONTINUOUS_ASR = createNodeDescriptor({
58
58
  const { endpointType } = input;
59
59
  try {
60
60
  const payload = setSessionConfig.handleInput(endpointType, voiceConfigParamsToVoiceSettings(config, api));
61
- api.say(null, {
61
+ yield api.say(null, {
62
62
  _cognigy: payload,
63
63
  });
64
64
  logFullConfigToDebugMode(cognigy, config);
@@ -67,7 +67,7 @@ export const DTMF = createNodeDescriptor({
67
67
  const { endpointType } = input;
68
68
  try {
69
69
  const payload = setSessionConfig.handleInput(endpointType, voiceConfigParamsToVoiceSettings(config, api));
70
- api.say(null, {
70
+ yield api.say(null, {
71
71
  _cognigy: payload,
72
72
  });
73
73
  logFullConfigToDebugMode(cognigy, config);
@@ -33,7 +33,7 @@ export const HANG_UP = createNodeDescriptor({
33
33
  const { endpointType } = input;
34
34
  try {
35
35
  const payload = hangUp.handleInput(endpointType, hangupReason);
36
- api.say(null, {
36
+ yield api.say(null, {
37
37
  _cognigy: payload
38
38
  });
39
39
  }
@@ -38,7 +38,7 @@ export const MUTE_SPEECH_INPUT = createNodeDescriptor({
38
38
  try {
39
39
  mapper.endpointType = endpointType;
40
40
  const payload = mapper.handleInput(config, api);
41
- api.say(null, {
41
+ yield api.say(null, {
42
42
  _cognigy: payload
43
43
  });
44
44
  api.logDebugMessage(`UI__DEBUG_MODE__MUTE_SPEECH__MESSAGE ${config.muteSpeechInput}`);
@@ -93,7 +93,7 @@ export const USER_INPUT_TIMEOUT = createNodeDescriptor({
93
93
  const { endpointType } = input;
94
94
  try {
95
95
  const payload = setSessionConfig.handleInput(endpointType, voiceConfigParamsToVoiceSettings(config, api));
96
- api.say(null, {
96
+ yield api.say(null, {
97
97
  _cognigy: payload,
98
98
  });
99
99
  logFullConfigToDebugMode(cognigy, config);
@@ -100,7 +100,7 @@ export const PLAY = createNodeDescriptor({
100
100
  config,
101
101
  api,
102
102
  });
103
- api.say(null, {
103
+ yield api.say(null, {
104
104
  _cognigy: payload
105
105
  });
106
106
  }
@@ -36,7 +36,7 @@ export const SEND_METADATA = createNodeDescriptor({
36
36
  if (!config.metadata)
37
37
  return;
38
38
  try {
39
- api.say(null, {
39
+ yield api.say(null, {
40
40
  _cognigy: sendMetadata.handleInput(endpointType, config.metadata)
41
41
  });
42
42
  }
@@ -328,7 +328,7 @@ export const SESSION_SPEECH_PARAMETERS = createNodeDescriptor({
328
328
  const { endpointType } = input;
329
329
  try {
330
330
  const payload = setSessionConfig.handleInput(endpointType, voiceConfigParamsToVoiceSettings(config, api));
331
- api.say(null, {
331
+ yield api.say(null, {
332
332
  _cognigy: payload,
333
333
  });
334
334
  logFullConfigToDebugMode(cognigy, config);
@@ -95,7 +95,7 @@ export const TRANSFER_VOICE = createNodeDescriptor({
95
95
  const { endpointType } = input;
96
96
  try {
97
97
  if (input.channel === "adminconsole") {
98
- api.say("Transferring a call is not supported in the Interaction Panel.", null);
98
+ yield api.say("Transferring a call is not supported in the Interaction Panel.", null);
99
99
  return;
100
100
  }
101
101
  const transferParams = {
@@ -113,7 +113,7 @@ export const TRANSFER_VOICE = createNodeDescriptor({
113
113
  api.log("error", "Invalid JSON in Transfer SIP Headers");
114
114
  }
115
115
  const payload = transfer.handleInput(endpointType, transferParams, true);
116
- api.say(null, {
116
+ yield api.say(null, {
117
117
  _cognigy: payload,
118
118
  });
119
119
  logFullConfigToDebugMode(cognigy, config);
@@ -70,7 +70,7 @@ export const agentAssistNode = createNodeDescriptor({
70
70
  }
71
71
  });
72
72
  }
73
- api.output(null, {
73
+ yield api.output(null, {
74
74
  "_cognigy": {
75
75
  "_voiceGateway": {
76
76
  "json": {
@@ -107,11 +107,11 @@ export const callRecordingNode = createNodeDescriptor({
107
107
  }
108
108
  const { isFeatureAccmEnabled } = api.getEndpointSettings();
109
109
  if (isFeatureAccmEnabled) {
110
- return api.say(null, {
110
+ return yield api.say(null, {
111
111
  _cognigy: buildPayloadAccm("callRecording", config, nodeId)
112
112
  });
113
113
  }
114
- api.output(null, {
114
+ yield api.output(null, {
115
115
  _cognigy: {
116
116
  _voiceGateway: {
117
117
  json: {
@@ -129,12 +129,12 @@ export const handoverNode = createNodeDescriptor({
129
129
  };
130
130
  try {
131
131
  if (input.channel === "adminconsole") {
132
- api.say("Transferring a call is not supported in the Interaction Panel, please use the AudioCodes endpoint.", null);
132
+ yield api.say("Transferring a call is not supported in the Interaction Panel, please use the AudioCodes endpoint.", null);
133
133
  return;
134
134
  }
135
135
  const { isFeatureAccmEnabled } = api.getEndpointSettings();
136
136
  const payload = isFeatureAccmEnabled ? buildPayloadAccm("handover", transferParams, nodeId) : transfer.handleInput("audioCodes", transferParams);
137
- api.say(null, {
137
+ yield api.say(null, {
138
138
  _cognigy: payload
139
139
  });
140
140
  }
@@ -36,7 +36,7 @@ export const hangupNode = createNodeDescriptor({
36
36
  try {
37
37
  const { isFeatureAccmEnabled } = api.getEndpointSettings();
38
38
  const payload = isFeatureAccmEnabled ? buildPayloadAccm("hangup", config, nodeId) : hangUp.handleInput("audioCodes", hangupReason);
39
- api.say(null, {
39
+ yield api.say(null, {
40
40
  _cognigy: payload
41
41
  });
42
42
  }
@@ -117,7 +117,7 @@ export const playURLNode = createNodeDescriptor({
117
117
  try {
118
118
  const { isFeatureAccmEnabled } = api.getEndpointSettings();
119
119
  const payload = isFeatureAccmEnabled ? buildPayloadAccm("playURL", config, nodeId) : play.handleInput({ endpointType: 'audioCodes', config });
120
- api.say(null, {
120
+ yield api.say(null, {
121
121
  _cognigy: payload
122
122
  });
123
123
  }
@@ -248,16 +248,17 @@ export const sendMessageNode = createNodeDescriptor({
248
248
  const { text, activityParams, setActivityParams } = config;
249
249
  const { isFeatureAccmEnabled } = api.getEndpointSettings();
250
250
  if (isFeatureAccmEnabled && text) {
251
- return api.say(null, {
251
+ yield api.say(null, {
252
252
  _cognigy: buildPayloadAccm("sendMessage", config, nodeId)
253
253
  });
254
+ return;
254
255
  }
255
256
  let compiledParams = activityParams || {};
256
257
  if (setActivityParams) {
257
258
  compileParams(config, compiledParams);
258
259
  }
259
260
  if (text) {
260
- api.output(null, {
261
+ yield api.output(null, {
261
262
  "_cognigy": {
262
263
  "_voiceGateway": {
263
264
  "json": {
@@ -35,7 +35,7 @@ export const sendMetaDataNode = createNodeDescriptor({
35
35
  try {
36
36
  const { isFeatureAccmEnabled } = api.getEndpointSettings();
37
37
  const payload = isFeatureAccmEnabled ? buildPayloadAccm("sendMetadata", config, nodeId) : sendMetadata.handleInput("audioCodes", config.metaData);
38
- api.output(null, {
38
+ yield api.output(null, {
39
39
  _cognigy: payload
40
40
  });
41
41
  }
@@ -51,14 +51,14 @@ export const setSessionParamsNode = createNodeDescriptor({
51
51
  const { sessionParams } = config;
52
52
  const { isFeatureAccmEnabled } = api.getEndpointSettings();
53
53
  if (isFeatureAccmEnabled) {
54
- return api.say(null, {
54
+ return yield api.say(null, {
55
55
  _cognigy: buildPayloadAccm("setSessionParams", config, nodeId)
56
56
  });
57
57
  }
58
58
  let compiledParams = sessionParams || {};
59
59
  compileParams(config, compiledParams);
60
60
  // output the activity to the voice gateway
61
- api.output(null, {
61
+ yield api.output(null, {
62
62
  "_cognigy": {
63
63
  "_voiceGateway": {
64
64
  "json": {
@@ -47,7 +47,7 @@ export const dtmfNode = createNodeDescriptor({
47
47
  duration
48
48
  }
49
49
  };
50
- api.say(null, {
50
+ yield api.say(null, {
51
51
  _cognigy: {
52
52
  _voiceGateway2: {
53
53
  json: voiceGateway2Payload
@@ -32,7 +32,7 @@ export const hangupNode = createNodeDescriptor({
32
32
  const { hangupReason } = config;
33
33
  try {
34
34
  const payload = hangUp.handleInput("voiceGateway2", hangupReason);
35
- api.say(null, {
35
+ yield api.say(null, {
36
36
  _cognigy: payload
37
37
  });
38
38
  api.logDebugMessage(`UI__DEBUG_MODE__HANGUP__MESSAGE ${hangupReason}`);
@@ -48,7 +48,7 @@ export const muteSpeechInputNode = createNodeDescriptor({
48
48
  const { api } = cognigy;
49
49
  try {
50
50
  const payload = mapper.handleInput(config, api);
51
- api.say(null, {
51
+ yield api.say(null, {
52
52
  _cognigy: payload
53
53
  });
54
54
  logFullConfigToDebugMode(cognigy, config);
@@ -138,7 +138,7 @@ export const playNode = createNodeDescriptor({
138
138
  config,
139
139
  api,
140
140
  });
141
- api.say(null, {
141
+ yield api.say(null, {
142
142
  _cognigy: payload
143
143
  });
144
144
  }
@@ -52,7 +52,7 @@ export const recordNode = createNodeDescriptor({
52
52
  label: "UI__NODE_EDITOR__VOICEGATEWAY2__FIELDS__SIPREC_SERVER_URL__LABEL",
53
53
  type: "cognigyText",
54
54
  description: "UI__NODE_EDITOR__VOICEGATEWAY2__FIELDS__SIPREC_SERVER_URL__DESCRIPTION",
55
- defaultValue: false,
55
+ defaultValue: "",
56
56
  condition: {
57
57
  key: "action",
58
58
  value: "startCallRecording"
@@ -63,7 +63,7 @@ export const recordNode = createNodeDescriptor({
63
63
  label: "UI__NODE_EDITOR__VOICEGATEWAY2__FIELDS__RECORDING_ID__LABEL",
64
64
  type: "cognigyText",
65
65
  description: "UI__NODE_EDITOR__VOICEGATEWAY2__FIELDS__RECORDING_ID__DESCRIPTION",
66
- defaultValue: false,
66
+ defaultValue: "",
67
67
  condition: {
68
68
  key: "action",
69
69
  value: "startCallRecording"
@@ -95,7 +95,7 @@ export const recordNode = createNodeDescriptor({
95
95
  };
96
96
  try {
97
97
  const payload = mapper.handleInput(recordInput, api, false);
98
- api.say(null, {
98
+ yield api.say(null, {
99
99
  _cognigy: payload
100
100
  });
101
101
  }
@@ -86,10 +86,10 @@ export const referNode = createNodeDescriptor({
86
86
  try {
87
87
  const payload = transfer.handleInput("voiceGateway2", transferParams, false);
88
88
  if (input.channel === "adminconsole") {
89
- api.output('You are using the deprecated Refer Node. Please replace it with new Transfer Node in the Node Selection Menu.', null);
89
+ yield api.output('You are using the deprecated Refer Node. Please replace it with new Transfer Node in the Node Selection Menu.', null);
90
90
  }
91
91
  api.log('error', 'You are using the deprecated Refer Node. Please replace it with new Transfer Node in the Node Selection Menu.');
92
- api.say(null, {
92
+ yield api.say(null, {
93
93
  _cognigy: payload
94
94
  });
95
95
  }
@@ -35,7 +35,7 @@ export const sendMetadataNode = createNodeDescriptor({
35
35
  if (!config.metadata)
36
36
  return;
37
37
  try {
38
- api.say(null, {
38
+ yield api.say(null, {
39
39
  _cognigy: sendMetadata.handleInput("voiceGateway2", config.metadata)
40
40
  });
41
41
  }
@@ -1074,7 +1074,7 @@ export const setSessionConfigNode = createNodeDescriptor({
1074
1074
  try {
1075
1075
  const voiceSettings = voiceConfigParamsToVoiceSettings(config, api);
1076
1076
  const payload = setSessionConfig.handleVGInput(voiceSettings, sessionParams, api);
1077
- api.say(null, {
1077
+ yield api.say(null, {
1078
1078
  _cognigy: payload,
1079
1079
  });
1080
1080
  logFullConfigToDebugMode(cognigy, voiceSettings);
@@ -506,7 +506,7 @@ export const transferNode = createNodeDescriptor({
506
506
  if (agentAssistEnabled && !dialTranscriptionWebhook) {
507
507
  textWarningAdminChannel = `${textWarningAdminChannel + "\n"} Copilot is enabled but no transcription webhook is configured. Please configure a transcription webhook in the Transfer node.`;
508
508
  }
509
- api.say(textWarningAdminChannel, null);
509
+ yield api.say(textWarningAdminChannel, null);
510
510
  return;
511
511
  }
512
512
  if (agentAssistEnabled && dialTranscriptionWebhook) {
@@ -545,7 +545,7 @@ export const transferNode = createNodeDescriptor({
545
545
  api.log("error", "Invalid JSON in Transfer SIP Headers");
546
546
  }
547
547
  const payload = transfer.handleInput("voiceGateway2", transferParams, false, recognitionChannel, sttVendor, sttLanguage, googleModel, sttDeepgramModel, sttDisablePunctuation, deepgramEndpointing, deepgramEndpointingValue, deepgramSmartFormatting, anchorMedia);
548
- api.say(null, {
548
+ yield api.say(null, {
549
549
  _cognigy: payload,
550
550
  });
551
551
  api.logDebugMessage(`${transferType} UI__DEBUG_MODE__TRANSFER__MESSAGE ${transferTarget}`);
@@ -10,6 +10,7 @@ export const profileDataSchema = {
10
10
  properties: {
11
11
  active: { type: "boolean" },
12
12
  contactIds: { type: "array", items: { type: "string" }, additionalItems: false, minItems: 1 },
13
+ contactIdsHash: { type: "string" },
13
14
  expiresAt: { type: "object" },
14
15
  profile: {},
15
16
  },
@@ -21,6 +21,11 @@ export const profileSchemaSchema = {
21
21
  },
22
22
  } }),
23
23
  };
24
+ /**
25
+ * WARNING!!
26
+ * make sure to update the default values for the profile mongoose model in the models/profiles.ts file
27
+ * when changing the profile schema and the default profile object below
28
+ */
24
29
  export const defaultProfile = {
25
30
  firstname: "",
26
31
  lastname: "",
@@ -98,7 +98,8 @@ export const handoverSettingsSchema = {
98
98
  enableTranscriptTile: { type: "boolean" },
99
99
  enableTranscriptTileChatInput: { type: "boolean" },
100
100
  redactTranscriptTileMessages: { type: "boolean" },
101
- oAuth2Connection: { type: "string" }
101
+ enableAgentCopilotAuthentication: { type: "boolean" },
102
+ agentCopilotAuthentication: { type: "string" },
102
103
  }
103
104
  }
104
105
  }
@@ -32,6 +32,7 @@ export const endpointTypes = [
32
32
  "bandwidth",
33
33
  "genesysBotConnector",
34
34
  "niceCXOne",
35
+ "niceCXOneAAH",
35
36
  "agentAssistVoice",
36
37
  "webchat3"
37
38
  ];
@@ -8,7 +8,7 @@ export const connectionFieldReturnFormat = [
8
8
  ];
9
9
  export const generateConnectionsRedisKey = (data) => {
10
10
  return [
11
- `organisationId:${data.organisationReference}:projectId:${data.projectReference}:connection:${data.referenceId}`
11
+ `organisationId:${data.organisationReference}:${data.projectReference ? `projectId:${data.projectReference}:` : ''}connection:${data.referenceId}`
12
12
  ];
13
13
  };
14
14
  export const connectionFieldDataSchema = {
@@ -50,7 +50,8 @@ export const connectionDataSchema = {
50
50
  },
51
51
  extension: { type: "string", format: "package-name" },
52
52
  type: { type: "string", format: "resource-name" },
53
- isDeprecated: { type: "boolean" }
53
+ isDeprecated: { type: "boolean" },
54
+ resourceLevel: { type: "string", enum: ["organisation", "project"] }
54
55
  }
55
56
  };
56
57
  export const connectionSchema = {
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=IGlobalResource.js.map
@@ -119,7 +119,16 @@ export const largeLanguageModelDataSchema = {
119
119
  alephAlpha: alephAlphaMetaSchema,
120
120
  anthropic: anthropicMetaSchema,
121
121
  awsBedrock: awsBedrockMetaSchema,
122
- fallbacks: llmFallbackSchema
122
+ fallbacks: llmFallbackSchema,
123
+ resourceLevel: { type: "string", enum: ["organisation", "project"] },
124
+ assignedToProjects: {
125
+ type: "array",
126
+ uniqueItems: true,
127
+ items: {
128
+ type: "string",
129
+ format: "mongo-id"
130
+ }
131
+ }
123
132
  }
124
133
  };
125
134
  export const largeLanguageModelSchema = {
@@ -95,6 +95,7 @@ export const nodeFieldTypes = [
95
95
  "checkbox",
96
96
  "chipInput",
97
97
  "code",
98
+ "cognigyLLMText",
98
99
  "cognigyText",
99
100
  "cognigyTextArray",
100
101
  "condition",
@@ -137,7 +138,7 @@ export const nodeFieldTypes = [
137
138
  "toggle",
138
139
  "ttsSelect",
139
140
  "typescript",
140
- "xml",
141
+ "xml"
141
142
  ];
142
143
  export const searchableNodeFieldTypes = [
143
144
  "text",
@@ -13,7 +13,8 @@ export const restChannelTypes = [
13
13
  "nonConversational",
14
14
  "amazonLex",
15
15
  "genesysBotConnector",
16
- "niceCXOne"
16
+ "niceCXOne",
17
+ "niceCXOneAAH",
17
18
  ];
18
19
  export const restChannelDisplayNames = [
19
20
  {
@@ -75,6 +76,10 @@ export const restChannelDisplayNames = [
75
76
  {
76
77
  channel: "niceCXOne",
77
78
  displayName: "NICE CXone"
78
- }
79
+ },
80
+ {
81
+ channel: "niceCXOneAAH",
82
+ displayName: "NICE CXone AAH"
83
+ },
79
84
  ];
80
85
  //# sourceMappingURL=TRestChannelType.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cognigy/rest-api-client",
3
- "version": "4.93.0",
3
+ "version": "4.95.0",
4
4
  "description": "Cognigy REST-Client",
5
5
  "main": "build/index.js",
6
6
  "module": "dist/esm/index.js",
@@ -73,7 +73,8 @@
73
73
  "typescript": "4.7.4"
74
74
  },
75
75
  "engines": {
76
- "node": ">=18.17.1",
76
+ "node": ">=22.1.0",
77
+ "npm": ">=10.1.0",
77
78
  "vscode": "^1.22.0"
78
79
  }
79
80
  }