@cognigy/rest-api-client 0.18.0 → 0.19.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.
- package/CHANGELOG.md +6 -0
- package/build/apigroups/AdministrationAPIGroup_2_0.js +3 -1
- package/build/apigroups/MetricsAPIGroup_2_0.js +5 -0
- package/build/apigroups/ResourcesAPIGroup_2_0.js +9 -6
- package/build/shared/charts/descriptors/agentAssist/helpers/determineMetadata.js +15 -0
- package/build/shared/charts/descriptors/agentAssist/helpers/knowledgeSearch/answerExtraction.helper.js +1 -1
- package/build/shared/charts/descriptors/agentAssist/helpers/knowledgeSearch/followUpDetection.helper.js +2 -2
- package/build/shared/charts/descriptors/agentAssist/identityAssist.js +1 -1
- package/build/shared/charts/descriptors/agentAssist/knowledgeAssist.js +1 -1
- package/build/shared/charts/descriptors/agentAssist/nextActionAssist.js +4 -5
- package/build/shared/charts/descriptors/agentAssist/sentimentAssist.js +1 -1
- package/build/shared/charts/descriptors/agentAssist/setAdaptiveCardTile.js +2 -0
- package/build/shared/charts/descriptors/agentAssist/setAgentAssistGrid.js +2 -1
- package/build/shared/charts/descriptors/agentAssist/setHtmlTile.js +5 -3
- package/build/shared/charts/descriptors/agentAssist/setIframeTile.js +5 -3
- package/build/shared/charts/descriptors/agentAssist/setSecureFormsTile.js +2 -2
- package/build/shared/charts/descriptors/agentAssist/transcriptAssist.js +2 -1
- package/build/shared/charts/descriptors/analytics/activateProfile.js +1 -0
- package/build/shared/charts/descriptors/analytics/blindMode.js +2 -0
- package/build/shared/charts/descriptors/analytics/completeGoal.js +1 -0
- package/build/shared/charts/descriptors/analytics/deactivateProfile.js +1 -0
- package/build/shared/charts/descriptors/analytics/deleteProfile.js +1 -0
- package/build/shared/charts/descriptors/analytics/index.js +3 -1
- package/build/shared/charts/descriptors/analytics/mergeProfile.js +1 -0
- package/build/shared/charts/descriptors/analytics/overwriteAnalytics.js +9 -0
- package/build/shared/charts/descriptors/analytics/setRating.js +4 -2
- package/build/shared/charts/descriptors/analytics/trackMilestone.js +95 -0
- package/build/shared/charts/descriptors/analytics/updateProfile.js +1 -0
- package/build/shared/charts/descriptors/apps/initAppSession.js +1 -0
- package/build/shared/charts/descriptors/apps/setAdaptiveCardAppState.js +35 -10
- package/build/shared/charts/descriptors/apps/setHtmlAppState.js +25 -2
- package/build/shared/charts/descriptors/apps/utils/getXAppsOverlaySettings.js +54 -0
- package/build/shared/charts/descriptors/connectionNodes/documentParserProviders/azureAIDocumentIntelligenceConnection.js +12 -0
- package/build/shared/charts/descriptors/connectionNodes/documentParserProviders/index.js +13 -0
- package/build/shared/charts/descriptors/connectionNodes/generativeAIProviders/awsBedrockProviderConnection.js +12 -0
- package/build/shared/charts/descriptors/connectionNodes/generativeAIProviders/azureOpenAIProviderConnection.js +4 -3
- package/build/shared/charts/descriptors/connectionNodes/generativeAIProviders/azureOpenAIProviderConnectionV2.js +3 -3
- package/build/shared/charts/descriptors/connectionNodes/generativeAIProviders/azureOpenAIProviderOauth2Connection.js +14 -0
- package/build/shared/charts/descriptors/connectionNodes/generativeAIProviders/index.js +16 -8
- package/build/shared/charts/descriptors/connectionNodes/generativeAIProviders/openAIProviderConnection.js +3 -3
- package/build/shared/charts/descriptors/data/addToContext.js +7 -0
- package/build/shared/charts/descriptors/data/copyDataToContext.js +3 -0
- package/build/shared/charts/descriptors/data/copySlotsToContext.js +3 -0
- package/build/shared/charts/descriptors/data/debugMessage.js +73 -0
- package/build/shared/charts/descriptors/data/index.js +3 -1
- package/build/shared/charts/descriptors/data/removeFromContext.js +9 -1
- package/build/shared/charts/descriptors/data/resetContext.js +1 -0
- package/build/shared/charts/descriptors/index.js +7 -1
- package/build/shared/charts/descriptors/knowledgeSearch/searchExtractOutput.js +35 -10
- package/build/shared/charts/descriptors/logic/resetState.js +1 -0
- package/build/shared/charts/descriptors/logic/setState.js +2 -1
- package/build/shared/charts/descriptors/logic/setTranslation.js +3 -1
- package/build/shared/charts/descriptors/logic/switchLocale.js +1 -0
- package/build/shared/charts/descriptors/logic/think.js +3 -1
- package/build/shared/charts/descriptors/logic/thinkV2.js +2 -0
- package/build/shared/charts/descriptors/message/question/question.js +50 -5
- package/build/shared/charts/descriptors/message/question/utils/validateQuestionAnswer.js +4 -2
- package/build/shared/charts/descriptors/nlu/cleanText.js +1 -0
- package/build/shared/charts/descriptors/nlu/fuzzySearch.js +23 -1
- package/build/shared/charts/descriptors/nlu/generativeSlotFiller/prompt.js +19 -9
- package/build/shared/charts/descriptors/service/GPTPrompt.js +59 -24
- package/build/shared/charts/descriptors/service/LLMEntityExtract.js +11 -2
- package/build/shared/charts/descriptors/service/handoverV2.js +84 -1
- package/build/shared/charts/descriptors/service/httpRequest.js +35 -2
- package/build/shared/charts/descriptors/voice/mappers/setSessionConfig.mapper.js +96 -17
- package/build/shared/charts/descriptors/voice/nodes/bargeIn.js +2 -0
- package/build/shared/charts/descriptors/voice/nodes/continuousAsr.js +2 -0
- package/build/shared/charts/descriptors/voice/nodes/dtmf.js +2 -0
- package/build/shared/charts/descriptors/voice/nodes/muteSpeechInput.js +1 -0
- package/build/shared/charts/descriptors/voice/nodes/noUserInput.js +2 -0
- package/build/shared/charts/descriptors/voice/nodes/sessionSpeechParameters.js +2 -0
- package/build/shared/charts/descriptors/voice/nodes/transfer.js +2 -0
- package/build/shared/charts/descriptors/voicegateway2/nodes/dtmf.js +2 -0
- package/build/shared/charts/descriptors/voicegateway2/nodes/hangup.js +2 -0
- package/build/shared/charts/descriptors/voicegateway2/nodes/muteSpeechInput.js +3 -0
- package/build/shared/charts/descriptors/voicegateway2/nodes/play.js +1 -0
- package/build/shared/charts/descriptors/voicegateway2/nodes/record.js +1 -0
- package/build/shared/charts/descriptors/voicegateway2/nodes/refer.js +1 -0
- package/build/shared/charts/descriptors/voicegateway2/nodes/sendMetadata.js +1 -0
- package/build/shared/charts/descriptors/voicegateway2/nodes/setSessionConfig.js +298 -8
- package/build/shared/charts/descriptors/voicegateway2/nodes/transfer.js +10 -6
- package/build/shared/charts/descriptors/voicegateway2/utils/helper.js +2 -2
- package/build/shared/charts/helpers/generativeAI/rephraseSentenceWithAi.js +4 -2
- package/build/shared/constants.js +10 -1
- package/build/shared/handoverClients/interfaces/THandoverEventType.js +1 -0
- package/build/shared/helper/logFullConfigToDebugMode.js +30 -0
- package/build/shared/helper/nlu/textCleaner.js +3 -1
- package/build/shared/interfaces/IOrganisation.js +1 -0
- package/build/shared/interfaces/IProfile.js +1 -0
- package/build/shared/interfaces/IProfileSchema.js +3 -0
- package/build/shared/interfaces/analytics/IAnalyticsSourceData.js +20 -20
- package/build/shared/interfaces/{restAPI/resources/journey/v2.0/IJourneyStep_2_0.js → analytics/IMilestoneAnalytics.js} +1 -1
- package/build/shared/interfaces/{restAPI/resources/journey/v2.0/IJourneyProgress_2_0.js → appsession/ISetAppStateOptions.js} +1 -1
- package/build/shared/interfaces/{restAPI/resources/journey/v2.0/IJourneyIndexItem_2_0.js → appsession/ISetAppStateOverlaySettings.js} +1 -1
- package/build/shared/interfaces/appsession/ISetAppStateOverlaySettingsMetaData.js +3 -0
- package/build/shared/interfaces/{restAPI/resources/journey/v2.0/IIndexJourneysRest_2_0.js → debugEvents/TDebugEventMessagePayload.js} +1 -1
- package/build/shared/interfaces/debugEvents/TDebugEventType.js +2 -0
- package/build/shared/interfaces/generativeAI/IGenerativeAIModels.js +33 -69
- package/build/shared/interfaces/handover.js +42 -1
- package/build/shared/interfaces/license.js +3 -2
- package/build/shared/interfaces/license.js.map +1 -1
- package/build/shared/interfaces/messageAPI/endpoints.js +2 -0
- package/build/shared/interfaces/messageAPI/handover.js +20 -1
- package/build/shared/interfaces/resources/IConnection.js +1 -0
- package/build/shared/interfaces/resources/IEndpoint.js +1 -2
- package/build/shared/interfaces/resources/ILargeLanguageModel.js +25 -4
- package/build/shared/interfaces/resources/IMilestone.js +1 -1
- package/build/shared/interfaces/resources/INodeDescriptorSet.js +12 -0
- package/build/shared/interfaces/resources/knowledgeStore/IKnowledgeSource.js +1 -1
- package/build/shared/interfaces/resources/settings/IAgentSettings.js +12 -7
- package/build/shared/interfaces/resources/settings/IGenerativeAISettings.js +4 -0
- package/build/shared/interfaces/resources/settings/IKnowledgeAISettings.js +18 -0
- package/build/shared/interfaces/resources/settings/index.js +4 -1
- package/build/shared/interfaces/restAPI/administration/organisations/v2.0/IReadCollectionsToBeDeletedRest_2_0.js +0 -1
- package/build/shared/interfaces/restAPI/administration/organisations/v2.0/IReadOrganisationKnowledgeChunksCountRest_2_0.js +3 -0
- package/build/shared/interfaces/restAPI/operations/nlu/v2.0/IGenerateNluScoresRest_2_0.js +57 -0
- package/build/shared/interfaces/restAPI/{resources/journey/v2.0/IJourney_2_0.js → operations/nlu/v2.0/index.js} +1 -1
- package/build/shared/interfaces/restAPI/resources/largeLanguageModel/v2.0/IAvailableModelsForLLMProvider_2_0 .js +18 -0
- package/build/shared/interfaces/restAPI/resources/largeLanguageModel/v2.0/IGetAvailableModelsForLLMRest_2_0 .js +3 -0
- package/build/shared/interfaces/security/IRole.js +2 -0
- package/build/shared/interfaces/security/ISystemCapabilities.js +3 -0
- package/build/shared/interfaces/security/index.js +1 -1
- package/build/shared/interfaces/trainer/ITrainerRecord.js +2 -2
- package/build/shared/interfaces/user.js +1 -1
- package/package.json +2 -2
- package/types/index.d.ts +1254 -670
- package/build/shared/interfaces/journeys/IJourney.js +0 -83
- package/build/shared/interfaces/journeys/IJourneyProgress.js +0 -40
- package/build/shared/interfaces/journeys/IJourneyTrackEvent.js +0 -35
- package/build/shared/interfaces/journeys/index.js +0 -14
- package/build/shared/interfaces/restAPI/resources/journey/v2.0/IJourneyTrackEvents_2_0.js +0 -3
- package/build/shared/interfaces/restAPI/resources/journey/v2.0/IReadJourneyProgressRest_2_0.js +0 -3
- package/build/shared/interfaces/restAPI/resources/journey/v2.0/IReadJourneyRest_2_0.js +0 -3
- package/build/shared/interfaces/restAPI/resources/journey/v2.0/ITrackJourneyEventRest_2_0.js +0 -3
- package/build/shared/interfaces/restAPI/resources/journey/v2.0/IUpdateSelectedJourneyRest_2_0.js +0 -3
- /package/build/shared/interfaces/restAPI/{resources/journey/v2.0 → operations}/index.js +0 -0
|
@@ -7,6 +7,7 @@ const createNodeDescriptor_1 = require("../../../createNodeDescriptor");
|
|
|
7
7
|
const design_1 = require("../utils/design");
|
|
8
8
|
const transfer_mapper_1 = require("../mappers/transfer.mapper");
|
|
9
9
|
const helper_1 = require("../../voicegateway2/utils/helper");
|
|
10
|
+
const logFullConfigToDebugMode_1 = require("../../../../helper/logFullConfigToDebugMode");
|
|
10
11
|
exports.TRANSFER_VOICE = (0, createNodeDescriptor_1.createNodeDescriptor)({
|
|
11
12
|
type: "transfer",
|
|
12
13
|
defaultLabel: "Transfer",
|
|
@@ -117,6 +118,7 @@ exports.TRANSFER_VOICE = (0, createNodeDescriptor_1.createNodeDescriptor)({
|
|
|
117
118
|
api.say(null, {
|
|
118
119
|
_cognigy: payload,
|
|
119
120
|
});
|
|
121
|
+
(0, logFullConfigToDebugMode_1.logFullConfigToDebugMode)(cognigy, config);
|
|
120
122
|
}
|
|
121
123
|
catch (error) {
|
|
122
124
|
throw new Error(`Error on Transfer Node type: refer. Error message: ${error.message}`);
|
|
@@ -16,6 +16,7 @@ exports.dtmfNode = (0, createNodeDescriptor_1.createNodeDescriptor)({
|
|
|
16
16
|
appearance: {
|
|
17
17
|
color: design_1.nodeColor
|
|
18
18
|
},
|
|
19
|
+
tags: ["vg"],
|
|
19
20
|
fields: [
|
|
20
21
|
{
|
|
21
22
|
key: "dtmf",
|
|
@@ -55,6 +56,7 @@ exports.dtmfNode = (0, createNodeDescriptor_1.createNodeDescriptor)({
|
|
|
55
56
|
}
|
|
56
57
|
}
|
|
57
58
|
});
|
|
59
|
+
api.logDebugMessage(`UI__DEBUG_MODE__DTMF__MESSAGE '${dtmf}' UI__DEBUG_MODE__DTMF__MESSAGE_2 ${duration}ms`);
|
|
58
60
|
}
|
|
59
61
|
});
|
|
60
62
|
//# sourceMappingURL=dtmf.js.map
|
|
@@ -13,6 +13,7 @@ exports.hangupNode = (0, createNodeDescriptor_1.createNodeDescriptor)({
|
|
|
13
13
|
key: "hangupReason",
|
|
14
14
|
type: "text"
|
|
15
15
|
},
|
|
16
|
+
tags: ["vg"],
|
|
16
17
|
appearance: {
|
|
17
18
|
color: design_1.nodeColor
|
|
18
19
|
},
|
|
@@ -36,6 +37,7 @@ exports.hangupNode = (0, createNodeDescriptor_1.createNodeDescriptor)({
|
|
|
36
37
|
api.say(null, {
|
|
37
38
|
_cognigy: payload
|
|
38
39
|
});
|
|
40
|
+
api.logDebugMessage(`UI__DEBUG_MODE__HANGUP__MESSAGE ${hangupReason}`);
|
|
39
41
|
}
|
|
40
42
|
catch (error) {
|
|
41
43
|
throw new Error(`Error on hangup node. Error message: ${error.message}`);
|
|
@@ -6,6 +6,7 @@ const createNodeDescriptor_1 = require("../../../createNodeDescriptor");
|
|
|
6
6
|
/** Helper Modules */
|
|
7
7
|
const design_1 = require("../utils/design");
|
|
8
8
|
const muteSpeechInput_mapper_1 = require("../../voice/mappers/muteSpeechInput.mapper");
|
|
9
|
+
const logFullConfigToDebugMode_1 = require("../../../../helper/logFullConfigToDebugMode");
|
|
9
10
|
const mapper = new muteSpeechInput_mapper_1.MuteSpeechInputMapper("voiceGateway2");
|
|
10
11
|
exports.muteSpeechInputNode = (0, createNodeDescriptor_1.createNodeDescriptor)({
|
|
11
12
|
type: "muteSpeechInput",
|
|
@@ -18,6 +19,7 @@ exports.muteSpeechInputNode = (0, createNodeDescriptor_1.createNodeDescriptor)({
|
|
|
18
19
|
appearance: {
|
|
19
20
|
color: design_1.nodeColor
|
|
20
21
|
},
|
|
22
|
+
tags: ["vg"],
|
|
21
23
|
fields: [
|
|
22
24
|
{
|
|
23
25
|
key: "muteSpeechInput",
|
|
@@ -51,6 +53,7 @@ exports.muteSpeechInputNode = (0, createNodeDescriptor_1.createNodeDescriptor)({
|
|
|
51
53
|
api.say(null, {
|
|
52
54
|
_cognigy: payload
|
|
53
55
|
});
|
|
56
|
+
(0, logFullConfigToDebugMode_1.logFullConfigToDebugMode)(cognigy, config);
|
|
54
57
|
}
|
|
55
58
|
catch (error) {
|
|
56
59
|
throw new Error(`Error on mute speech input node. Error message: ${error.message}`);
|
|
@@ -8,6 +8,7 @@ const design_1 = require("../utils/design");
|
|
|
8
8
|
const setSessionConfig_mapper_1 = require("../../voice/mappers/setSessionConfig.mapper");
|
|
9
9
|
const setSessionConfig_mapper_2 = require("../../voice/mappers/setSessionConfig.mapper");
|
|
10
10
|
const vgConstants_1 = require("../../voice/utils/vgConstants");
|
|
11
|
+
const logFullConfigToDebugMode_1 = require("../../../../helper/logFullConfigToDebugMode");
|
|
11
12
|
exports.voiceConfigFields = [
|
|
12
13
|
{
|
|
13
14
|
key: "bargeInMinWordCount",
|
|
@@ -310,6 +311,13 @@ exports.voiceConfigFields = [
|
|
|
310
311
|
value: "", // We show the field for all vendors as soon as it is defined
|
|
311
312
|
}
|
|
312
313
|
},
|
|
314
|
+
{
|
|
315
|
+
key: "userNoInputTimeoutEnable",
|
|
316
|
+
type: "toggle",
|
|
317
|
+
label: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__USER_NO_INPUT_TIMEOUT_ENABLE__LABEL",
|
|
318
|
+
description: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__USER_NO_INPUT_TIMEOUT_ENABLE__DESCRIPTION",
|
|
319
|
+
defaultValue: true,
|
|
320
|
+
},
|
|
313
321
|
{
|
|
314
322
|
key: "userNoInputMode",
|
|
315
323
|
type: "select",
|
|
@@ -331,6 +339,10 @@ exports.voiceConfigFields = [
|
|
|
331
339
|
value: "event"
|
|
332
340
|
}
|
|
333
341
|
]
|
|
342
|
+
},
|
|
343
|
+
condition: {
|
|
344
|
+
key: "userNoInputTimeoutEnable",
|
|
345
|
+
value: true
|
|
334
346
|
}
|
|
335
347
|
},
|
|
336
348
|
{
|
|
@@ -340,7 +352,11 @@ exports.voiceConfigFields = [
|
|
|
340
352
|
description: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__USER_NO_INPUT_TIMEOUT__DESCRIPTION",
|
|
341
353
|
defaultValue: 10000,
|
|
342
354
|
params: {
|
|
343
|
-
min:
|
|
355
|
+
min: 1
|
|
356
|
+
},
|
|
357
|
+
condition: {
|
|
358
|
+
key: "userNoInputTimeoutEnable",
|
|
359
|
+
value: true
|
|
344
360
|
}
|
|
345
361
|
},
|
|
346
362
|
{
|
|
@@ -352,6 +368,10 @@ exports.voiceConfigFields = [
|
|
|
352
368
|
params: {
|
|
353
369
|
min: 0,
|
|
354
370
|
max: 999
|
|
371
|
+
},
|
|
372
|
+
condition: {
|
|
373
|
+
key: "userNoInputTimeoutEnable",
|
|
374
|
+
value: true
|
|
355
375
|
}
|
|
356
376
|
},
|
|
357
377
|
{
|
|
@@ -361,12 +381,20 @@ exports.voiceConfigFields = [
|
|
|
361
381
|
description: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__USER_NO_INPUT_SPEECH__DESCRIPTION",
|
|
362
382
|
defaultValue: "",
|
|
363
383
|
condition: {
|
|
364
|
-
|
|
365
|
-
|
|
384
|
+
and: [
|
|
385
|
+
{
|
|
386
|
+
key: "userNoInputTimeoutEnable",
|
|
387
|
+
value: true
|
|
388
|
+
},
|
|
389
|
+
{
|
|
390
|
+
key: "userNoInputMode",
|
|
391
|
+
value: "speech"
|
|
392
|
+
}
|
|
393
|
+
]
|
|
366
394
|
},
|
|
367
395
|
params: {
|
|
368
396
|
required: true
|
|
369
|
-
}
|
|
397
|
+
},
|
|
370
398
|
},
|
|
371
399
|
{
|
|
372
400
|
key: "userNoInputUrl",
|
|
@@ -375,8 +403,119 @@ exports.voiceConfigFields = [
|
|
|
375
403
|
description: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__USER_NO_INPUT_URL__DESCRIPTION",
|
|
376
404
|
defaultValue: "",
|
|
377
405
|
condition: {
|
|
378
|
-
|
|
379
|
-
|
|
406
|
+
and: [
|
|
407
|
+
{
|
|
408
|
+
key: "userNoInputTimeoutEnable",
|
|
409
|
+
value: true
|
|
410
|
+
},
|
|
411
|
+
{
|
|
412
|
+
key: "userNoInputMode",
|
|
413
|
+
value: "play"
|
|
414
|
+
}
|
|
415
|
+
]
|
|
416
|
+
},
|
|
417
|
+
params: {
|
|
418
|
+
required: true
|
|
419
|
+
}
|
|
420
|
+
},
|
|
421
|
+
{
|
|
422
|
+
key: "flowNoInputTimeoutEnable",
|
|
423
|
+
type: "toggle",
|
|
424
|
+
label: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__FLOW_NO_INPUT_TIMEOUT_ENABLE__LABEL",
|
|
425
|
+
description: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__FLOW_NO_INPUT_TIMEOUT_ENABLE__DESCRIPTION",
|
|
426
|
+
defaultValue: false,
|
|
427
|
+
},
|
|
428
|
+
{
|
|
429
|
+
key: "flowNoInputMode",
|
|
430
|
+
type: "select",
|
|
431
|
+
label: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__FLOW_NO_INPUT_MODE__LABEL",
|
|
432
|
+
description: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__FLOW_NO_INPUT_MODE__DESCRIPTION",
|
|
433
|
+
defaultValue: "play",
|
|
434
|
+
params: {
|
|
435
|
+
options: [
|
|
436
|
+
{
|
|
437
|
+
label: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__FLOW_NO_INPUT_MODE__OPTIONS__PLAY__LABEL",
|
|
438
|
+
value: "play"
|
|
439
|
+
},
|
|
440
|
+
{
|
|
441
|
+
label: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__FLOW_NO_INPUT_MODE__OPTIONS__SPEECH__LABEL",
|
|
442
|
+
value: "speech"
|
|
443
|
+
}
|
|
444
|
+
]
|
|
445
|
+
},
|
|
446
|
+
condition: {
|
|
447
|
+
key: "flowNoInputTimeoutEnable",
|
|
448
|
+
value: true
|
|
449
|
+
}
|
|
450
|
+
},
|
|
451
|
+
{
|
|
452
|
+
key: "flowNoInputTimeout",
|
|
453
|
+
type: "number",
|
|
454
|
+
label: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__FLOW_NO_INPUT_TIMEOUT__LABEL",
|
|
455
|
+
description: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__FLOW_NO_INPUT_TIMEOUT__DESCRIPTION",
|
|
456
|
+
defaultValue: 10000,
|
|
457
|
+
params: {
|
|
458
|
+
min: 1
|
|
459
|
+
},
|
|
460
|
+
condition: {
|
|
461
|
+
key: "flowNoInputTimeoutEnable",
|
|
462
|
+
value: true
|
|
463
|
+
}
|
|
464
|
+
},
|
|
465
|
+
{
|
|
466
|
+
key: "flowNoInputRetries",
|
|
467
|
+
type: "number",
|
|
468
|
+
label: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__FLOW_NO_INPUT_RETRIES__LABEL",
|
|
469
|
+
description: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__FLOW_NO_INPUT_RETRIES__DESCRIPTION",
|
|
470
|
+
defaultValue: 1,
|
|
471
|
+
params: {
|
|
472
|
+
min: 0,
|
|
473
|
+
max: 999
|
|
474
|
+
},
|
|
475
|
+
condition: {
|
|
476
|
+
key: "flowNoInputTimeoutEnable",
|
|
477
|
+
value: true
|
|
478
|
+
}
|
|
479
|
+
},
|
|
480
|
+
{
|
|
481
|
+
key: "flowNoInputSpeech",
|
|
482
|
+
type: "cognigyText",
|
|
483
|
+
label: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__FLOW_NO_INPUT_SPEECH__LABEL",
|
|
484
|
+
description: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__FLOW_NO_INPUT_SPEECH__DESCRIPTION",
|
|
485
|
+
defaultValue: "",
|
|
486
|
+
condition: {
|
|
487
|
+
and: [
|
|
488
|
+
{
|
|
489
|
+
key: "flowNoInputTimeoutEnable",
|
|
490
|
+
value: true
|
|
491
|
+
},
|
|
492
|
+
{
|
|
493
|
+
key: "flowNoInputMode",
|
|
494
|
+
value: "speech"
|
|
495
|
+
}
|
|
496
|
+
]
|
|
497
|
+
},
|
|
498
|
+
params: {
|
|
499
|
+
required: true
|
|
500
|
+
},
|
|
501
|
+
},
|
|
502
|
+
{
|
|
503
|
+
key: "flowNoInputUrl",
|
|
504
|
+
type: "cognigyText",
|
|
505
|
+
label: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__FLOW_NO_INPUT_URL__LABEL",
|
|
506
|
+
description: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__FLOW_NO_INPUT_URL__DESCRIPTION",
|
|
507
|
+
defaultValue: "",
|
|
508
|
+
condition: {
|
|
509
|
+
and: [
|
|
510
|
+
{
|
|
511
|
+
key: "flowNoInputTimeoutEnable",
|
|
512
|
+
value: true
|
|
513
|
+
},
|
|
514
|
+
{
|
|
515
|
+
key: "flowNoInputMode",
|
|
516
|
+
value: "play"
|
|
517
|
+
}
|
|
518
|
+
]
|
|
380
519
|
},
|
|
381
520
|
params: {
|
|
382
521
|
required: true
|
|
@@ -616,6 +755,119 @@ exports.voiceConfigFields = [
|
|
|
616
755
|
]
|
|
617
756
|
}
|
|
618
757
|
},
|
|
758
|
+
{
|
|
759
|
+
key: "atmosphereAction",
|
|
760
|
+
type: "select",
|
|
761
|
+
label: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__ATMOSPHERE_ACTION__LABEL",
|
|
762
|
+
description: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__ATMOSPHERE_ACTION__DESCRIPTION",
|
|
763
|
+
defaultValue: "",
|
|
764
|
+
params: {
|
|
765
|
+
options: [
|
|
766
|
+
{
|
|
767
|
+
label: "",
|
|
768
|
+
value: ""
|
|
769
|
+
},
|
|
770
|
+
{
|
|
771
|
+
label: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__ATMOSPHERE_ACTION__OPTIONS__PLAY__LABEL",
|
|
772
|
+
value: "addTrack"
|
|
773
|
+
},
|
|
774
|
+
{
|
|
775
|
+
label: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__ATMOSPHERE_ACTION__OPTIONS__SILENCE__LABEL",
|
|
776
|
+
value: "silenceTrack"
|
|
777
|
+
},
|
|
778
|
+
{
|
|
779
|
+
label: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__ATMOSPHERE_ACTION__OPTIONS__REMOVE__LABEL",
|
|
780
|
+
value: "removeTrack"
|
|
781
|
+
}
|
|
782
|
+
]
|
|
783
|
+
}
|
|
784
|
+
},
|
|
785
|
+
{
|
|
786
|
+
key: "atmosphereLoop",
|
|
787
|
+
type: "toggle",
|
|
788
|
+
label: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__ATMOSPHERE_LOOP__LABEL",
|
|
789
|
+
description: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__ATMOSPHERE_LOOP__DESCRIPTION",
|
|
790
|
+
defaultValue: true,
|
|
791
|
+
condition: {
|
|
792
|
+
key: "atmosphereAction",
|
|
793
|
+
value: "addTrack"
|
|
794
|
+
}
|
|
795
|
+
},
|
|
796
|
+
{
|
|
797
|
+
key: "atmosphereVolume",
|
|
798
|
+
type: "number",
|
|
799
|
+
label: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__ATMOSPHERE_VOLUME__LABEL",
|
|
800
|
+
description: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__ATMOSPHERE_VOLUME__DESCRIPTION",
|
|
801
|
+
defaultValue: 0,
|
|
802
|
+
params: {
|
|
803
|
+
min: -50,
|
|
804
|
+
max: 50
|
|
805
|
+
},
|
|
806
|
+
condition: {
|
|
807
|
+
key: "atmosphereAction",
|
|
808
|
+
value: "addTrack"
|
|
809
|
+
}
|
|
810
|
+
},
|
|
811
|
+
{
|
|
812
|
+
key: "atmosphereUrl",
|
|
813
|
+
type: "cognigyText",
|
|
814
|
+
label: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__ATMOSPHERE_URL__LABEL",
|
|
815
|
+
description: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__ATMOSPHERE_URL__DESCRIPTION",
|
|
816
|
+
defaultValue: "",
|
|
817
|
+
condition: {
|
|
818
|
+
key: "atmosphereAction",
|
|
819
|
+
value: "addTrack"
|
|
820
|
+
}
|
|
821
|
+
},
|
|
822
|
+
{
|
|
823
|
+
key: "silenceOverlayAction",
|
|
824
|
+
type: "select",
|
|
825
|
+
label: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__SILENCE_OVERLAY_ACTION__LABEL",
|
|
826
|
+
description: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__SILENCE_OVERLAY_ACTION__DESCRIPTION",
|
|
827
|
+
defaultValue: "",
|
|
828
|
+
params: {
|
|
829
|
+
options: [
|
|
830
|
+
{
|
|
831
|
+
label: "",
|
|
832
|
+
value: ""
|
|
833
|
+
},
|
|
834
|
+
{
|
|
835
|
+
label: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__SILENCE_OVERLAY_ACTION__OPTIONS__PLAY__LABEL",
|
|
836
|
+
value: true
|
|
837
|
+
},
|
|
838
|
+
{
|
|
839
|
+
label: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__SILENCE_OVERLAY_ACTION__OPTIONS__REMOVE__LABEL",
|
|
840
|
+
value: false
|
|
841
|
+
},
|
|
842
|
+
]
|
|
843
|
+
}
|
|
844
|
+
},
|
|
845
|
+
{
|
|
846
|
+
key: "silenceOverlayURL",
|
|
847
|
+
type: "cognigyText",
|
|
848
|
+
label: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__SILENCE_OVERLAY_URL__LABEL",
|
|
849
|
+
description: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__SILENCE_OVERLAY_URL__DESCRIPTION",
|
|
850
|
+
defaultValue: "",
|
|
851
|
+
condition: {
|
|
852
|
+
key: "silenceOverlayAction",
|
|
853
|
+
value: true
|
|
854
|
+
}
|
|
855
|
+
},
|
|
856
|
+
{
|
|
857
|
+
key: "silenceOverlayDelay",
|
|
858
|
+
type: "number",
|
|
859
|
+
label: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__SILENCE_OVERLAY_DELAY__LABEL",
|
|
860
|
+
description: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__SILENCE_OVERLAY_DELAY__DESCRIPTION",
|
|
861
|
+
defaultValue: 0,
|
|
862
|
+
params: {
|
|
863
|
+
min: 0,
|
|
864
|
+
max: 60
|
|
865
|
+
},
|
|
866
|
+
condition: {
|
|
867
|
+
key: "silenceOverlayAction",
|
|
868
|
+
value: true
|
|
869
|
+
}
|
|
870
|
+
},
|
|
619
871
|
{
|
|
620
872
|
key: "googleModel",
|
|
621
873
|
type: "select",
|
|
@@ -729,6 +981,7 @@ exports.setSessionConfigNode = (0, createNodeDescriptor_1.createNodeDescriptor)(
|
|
|
729
981
|
label: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__SESSIONS_PARAMS_USER_TIMEOUTS__LABEL",
|
|
730
982
|
defaultCollapsed: true,
|
|
731
983
|
fields: [
|
|
984
|
+
"userNoInputTimeoutEnable",
|
|
732
985
|
"userNoInputMode",
|
|
733
986
|
"userNoInputSpeech",
|
|
734
987
|
"userNoInputUrl",
|
|
@@ -736,6 +989,19 @@ exports.setSessionConfigNode = (0, createNodeDescriptor_1.createNodeDescriptor)(
|
|
|
736
989
|
"userNoInputRetries",
|
|
737
990
|
],
|
|
738
991
|
},
|
|
992
|
+
{
|
|
993
|
+
key: "params_flow_timeouts",
|
|
994
|
+
label: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__SESSIONS_PARAMS_FLOW_TIMEOUTS__LABEL",
|
|
995
|
+
defaultCollapsed: true,
|
|
996
|
+
fields: [
|
|
997
|
+
"flowNoInputTimeoutEnable",
|
|
998
|
+
"flowNoInputMode",
|
|
999
|
+
"flowNoInputSpeech",
|
|
1000
|
+
"flowNoInputUrl",
|
|
1001
|
+
"flowNoInputTimeout",
|
|
1002
|
+
"flowNoInputRetries",
|
|
1003
|
+
],
|
|
1004
|
+
},
|
|
739
1005
|
{
|
|
740
1006
|
key: "params_dtmf",
|
|
741
1007
|
label: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__SESSIONS_PARAMS_DTMF__LABEL",
|
|
@@ -754,6 +1020,18 @@ exports.setSessionConfigNode = (0, createNodeDescriptor_1.createNodeDescriptor)(
|
|
|
754
1020
|
defaultCollapsed: true,
|
|
755
1021
|
fields: ["asrEnabled", "asrDigit", "asrTimeout"],
|
|
756
1022
|
},
|
|
1023
|
+
{
|
|
1024
|
+
key: "params_atmosphere_sound",
|
|
1025
|
+
label: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__SESSIONS_PARAMS_ATMOSPHERE__LABEL",
|
|
1026
|
+
defaultCollapsed: true,
|
|
1027
|
+
fields: ["atmosphereAction", "atmosphereUrl", "atmosphereLoop", "atmosphereVolume"],
|
|
1028
|
+
},
|
|
1029
|
+
{
|
|
1030
|
+
key: "params_silence_overlay",
|
|
1031
|
+
label: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__SESSIONS_PARAMS_SILENCE_OVERLAY__LABEL",
|
|
1032
|
+
defaultCollapsed: true,
|
|
1033
|
+
fields: ["silenceOverlayAction", "silenceOverlayURL", "silenceOverlayDelay"],
|
|
1034
|
+
},
|
|
757
1035
|
{
|
|
758
1036
|
key: "advanced",
|
|
759
1037
|
label: "UI__NODE_EDITOR__VOICEGATEWAY2__SET_SESSION_CONFIG__SESSIONS_PARAMS_ADVANCED__LABEL",
|
|
@@ -761,24 +1039,36 @@ exports.setSessionConfigNode = (0, createNodeDescriptor_1.createNodeDescriptor)(
|
|
|
761
1039
|
fields: ["sessionParams"],
|
|
762
1040
|
},
|
|
763
1041
|
],
|
|
1042
|
+
tags: ["vg"],
|
|
764
1043
|
form: [
|
|
765
1044
|
{ type: "section", key: "params_tts" },
|
|
766
1045
|
{ type: "section", key: "params_stt" },
|
|
767
1046
|
{ type: "section", key: "params_bargein" },
|
|
768
1047
|
{ type: "section", key: "params_user_timeouts" },
|
|
1048
|
+
// hidding the flow timeout until we release timeout event
|
|
1049
|
+
// { type: "section", key: "params_flow_timeouts" },
|
|
769
1050
|
{ type: "section", key: "params_dtmf" },
|
|
770
1051
|
{ type: "section", key: "params_continuous_asr" },
|
|
771
1052
|
{ type: "section", key: "params_azure_config" },
|
|
1053
|
+
process.env.DISABLE_VG_SILENCE_OVERLAY !== "true" && { type: "section", key: "params_atmosphere_sound" },
|
|
1054
|
+
process.env.DISABLE_VG_ATMOSPHERE_NOISE !== "true" && { type: "section", key: "params_silence_overlay" },
|
|
772
1055
|
{ type: "section", key: "advanced" },
|
|
773
|
-
]
|
|
1056
|
+
]
|
|
1057
|
+
.filter(element => !!element),
|
|
774
1058
|
function: async ({ cognigy, config }) => {
|
|
775
1059
|
const { api } = cognigy;
|
|
776
1060
|
const { sessionParams } = config;
|
|
1061
|
+
// code for applying as default false for flowNoInputTimeout to apply to old nodes.
|
|
1062
|
+
if (config.flowNoInputTimeoutEnable === undefined) {
|
|
1063
|
+
config.flowNoInputTimeoutEnable = false;
|
|
1064
|
+
}
|
|
777
1065
|
try {
|
|
778
|
-
const
|
|
1066
|
+
const voiceSettings = (0, setSessionConfig_mapper_2.voiceConfigParamsToVoiceSettings)(config, api);
|
|
1067
|
+
const payload = setSessionConfig_mapper_1.setSessionConfig.handleVGInput(voiceSettings, sessionParams, api);
|
|
779
1068
|
api.say(null, {
|
|
780
1069
|
_cognigy: payload,
|
|
781
1070
|
});
|
|
1071
|
+
(0, logFullConfigToDebugMode_1.logFullConfigToDebugMode)(cognigy, voiceSettings);
|
|
782
1072
|
}
|
|
783
1073
|
catch (error) {
|
|
784
1074
|
throw new Error(`[VG2] Error on set session config node. Error message: ${error.message}`);
|
|
@@ -18,6 +18,7 @@ exports.transferNode = (0, createNodeDescriptor_1.createNodeDescriptor)({
|
|
|
18
18
|
appearance: {
|
|
19
19
|
color: design_1.nodeColor,
|
|
20
20
|
},
|
|
21
|
+
tags: ["vg"],
|
|
21
22
|
fields: [
|
|
22
23
|
{
|
|
23
24
|
key: "transferType",
|
|
@@ -470,7 +471,7 @@ exports.transferNode = (0, createNodeDescriptor_1.createNodeDescriptor)({
|
|
|
470
471
|
}
|
|
471
472
|
],
|
|
472
473
|
summary: "UI__NODE_EDITOR__VOICEGATEWAY2__TRANSFER__SUMMARY",
|
|
473
|
-
function: async ({ cognigy, config,
|
|
474
|
+
function: async ({ cognigy, config, }) => {
|
|
474
475
|
const { api, input } = cognigy;
|
|
475
476
|
const { transferType, transferTarget, referredBy, useTransferSipHeaders, transferSipHeaders = {}, transferReason, dialMusic, dialTranscriptionWebhook, dialCallerId, recognitionChannel, sttVendor, sttLanguage, sttDisablePunctuation, dialTimeout, amdEnabled, amdRedirectOnMachineDetected, amdRedirectText, sttLabel, googleModel, sttDeepgramModel, deepgramEndpointing, deepgramEndpointingValue, deepgramSmartFormatting, agentAssistEnabled, agentAssistHeadersKey = customHeaderDefaultValue } = config;
|
|
476
477
|
const transferParams = {
|
|
@@ -501,14 +502,16 @@ exports.transferNode = (0, createNodeDescriptor_1.createNodeDescriptor)({
|
|
|
501
502
|
if (agentAssistEnabled && dialTranscriptionWebhook) {
|
|
502
503
|
try {
|
|
503
504
|
const agentAssistConfigId = api.getAgentAssistConfigId();
|
|
504
|
-
const
|
|
505
|
+
const params = {
|
|
505
506
|
sessionId: input.sessionId,
|
|
506
507
|
userId: input.userId,
|
|
507
508
|
webhookUrl: dialTranscriptionWebhook,
|
|
508
|
-
agentAssistConfigId,
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
509
|
+
agentAssistConfigId: agentAssistConfigId,
|
|
510
|
+
};
|
|
511
|
+
if ((!params.agentAssistConfigId || params.agentAssistConfigId === 'none')) {
|
|
512
|
+
delete params.agentAssistConfigId;
|
|
513
|
+
}
|
|
514
|
+
const uui = (0, helper_1.buildUUIValue)(params);
|
|
512
515
|
if (!(~dialTranscriptionWebhook.indexOf("userId") && ~dialTranscriptionWebhook.indexOf("sessionId"))) {
|
|
513
516
|
transferParams.dialTranscriptionWebhook = `${dialTranscriptionWebhook}?userId=${input.userId}&sessionId=${input.sessionId}`;
|
|
514
517
|
}
|
|
@@ -535,6 +538,7 @@ exports.transferNode = (0, createNodeDescriptor_1.createNodeDescriptor)({
|
|
|
535
538
|
api.say(null, {
|
|
536
539
|
_cognigy: payload,
|
|
537
540
|
});
|
|
541
|
+
api.logDebugMessage(`${transferType} UI__DEBUG_MODE__TRANSFER__MESSAGE ${transferTarget}`);
|
|
538
542
|
}
|
|
539
543
|
catch (error) {
|
|
540
544
|
throw new Error(`Error on Transfer node type: ${transferType}. Error message: ${error.message}`);
|
|
@@ -60,12 +60,12 @@ const createFullUUIValue = (uui) => {
|
|
|
60
60
|
return `00${encodeHex(uui)};encoding=hex`;
|
|
61
61
|
};
|
|
62
62
|
const buildUUIValue = (params) => {
|
|
63
|
-
const { webhookUrl, userId, sessionId, agentAssistConfigId,
|
|
63
|
+
const { webhookUrl, userId, sessionId, agentAssistConfigId, } = params;
|
|
64
64
|
const { AGENT_ASSIST_WORKSPACE_FRONTEND_URL_WITH_PROTOCOL } = process.env;
|
|
65
65
|
const URLToken = extractURLToken(webhookUrl);
|
|
66
66
|
const assistUserId = `assist-${userId}`;
|
|
67
67
|
const assistSessionId = `assist-${sessionId}`;
|
|
68
|
-
const uui = `${AGENT_ASSIST_WORKSPACE_FRONTEND_URL_WITH_PROTOCOL}/?userId=${assistUserId}&sessionId=${assistSessionId}&URLToken=${URLToken}
|
|
68
|
+
const uui = `${AGENT_ASSIST_WORKSPACE_FRONTEND_URL_WITH_PROTOCOL}/?userId=${assistUserId}&sessionId=${assistSessionId}&URLToken=${URLToken}${agentAssistConfigId ? `&configId=${agentAssistConfigId}` : ''}`;
|
|
69
69
|
return createFullUUIValue(uui);
|
|
70
70
|
};
|
|
71
71
|
exports.buildUUIValue = buildUUIValue;
|
|
@@ -3,10 +3,12 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.rephraseMultipleSentencesWithAI = exports.rephraseSentenceWithAI = void 0;
|
|
4
4
|
const rephraseSentenceWithAI = async (sentence, config, api, organisationId) => {
|
|
5
5
|
const { generativeAI_rephraseOutputMode } = config;
|
|
6
|
+
let newSentence = sentence;
|
|
6
7
|
if (generativeAI_rephraseOutputMode === "userInputs" || generativeAI_rephraseOutputMode === "customInputs") {
|
|
7
|
-
|
|
8
|
+
newSentence = await api.rephraseSentenceWithAI(sentence, createRephraseSentenceWithAIOptions(config));
|
|
8
9
|
}
|
|
9
|
-
|
|
10
|
+
newSentence !== sentence && api.logDebugMessage(`Rephrased sentence via AI<br>From: '${sentence}'<br>To: '${newSentence}'`, "Rephrased Sentence via AI");
|
|
11
|
+
return newSentence;
|
|
10
12
|
};
|
|
11
13
|
exports.rephraseSentenceWithAI = rephraseSentenceWithAI;
|
|
12
14
|
const rephraseMultipleSentencesWithAI = async (sentences, config, api, organisationId) => {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.IP_NOT_AVAILABLE = exports.COGNIGY_LIVE_AGENT_DESCRIPTOR_FIELDS = exports.TRANSLATION_PROVIDER_EXTENSION = exports.AUDIO_PREVIEW_PROVIDER_EXTENSION = exports.GENERATIVE_AI_PROVIDER_EXTENSION = exports.ADMIN_CONSOLE_URL_TOKEN = exports.X_COGNIGY_ORIGIN = exports.EMBEDDED_EXTENSION = exports.INTERNAL_STORAGE_PROVIDER_EXTENSION = exports.VOICE_GATEWAY_2_EXTENSION = exports.MICROSOFT_EXTENSION = exports.VOICE_GATEWAY_EXTENSION = exports.SMTP_EXTENSION = exports.SQL_EXTENSION = exports.MONGO_DB_EXTENSION = exports.BASIC_EXTENSION = exports.MAX_INT32 = exports.PASSWORD_RESET_TOKEN_TTL_IN_SECONDS = exports.SCOPED_USER = exports.SYSTEM_EMAIL = exports.SYSTEM = exports.CREATED_BY_SSO = void 0;
|
|
3
|
+
exports.IP_NOT_AVAILABLE = exports.COGNIGY_LIVE_AGENT_DESCRIPTOR_FIELDS = exports.DOCUMENT_PARSER_PROVIDER_EXTENSION = exports.TRANSLATION_PROVIDER_EXTENSION = exports.AUDIO_PREVIEW_PROVIDER_EXTENSION = exports.GENERATIVE_AI_PROVIDER_EXTENSION = exports.ADMIN_CONSOLE_URL_TOKEN = exports.X_COGNIGY_ORIGIN = exports.EMBEDDED_EXTENSION = exports.INTERNAL_STORAGE_PROVIDER_EXTENSION = exports.VOICE_GATEWAY_2_EXTENSION = exports.MICROSOFT_EXTENSION = exports.VOICE_GATEWAY_EXTENSION = exports.SMTP_EXTENSION = exports.SQL_EXTENSION = exports.MONGO_DB_EXTENSION = exports.BASIC_EXTENSION = exports.MAX_INT32 = exports.PASSWORD_RESET_TOKEN_TTL_IN_SECONDS = exports.SCOPED_USER = exports.SYSTEM_EMAIL = exports.SYSTEM = exports.CREATED_BY_SSO = void 0;
|
|
4
4
|
exports.CREATED_BY_SSO = "000000000000000000000550";
|
|
5
5
|
exports.SYSTEM = "000000000000000000000000";
|
|
6
6
|
exports.SYSTEM_EMAIL = "system@mail.com";
|
|
@@ -23,6 +23,7 @@ exports.ADMIN_CONSOLE_URL_TOKEN = "ffffffffffffffffffff55555555555555555eeeeeeee
|
|
|
23
23
|
exports.GENERATIVE_AI_PROVIDER_EXTENSION = "@cognigy/generative-ai-provider";
|
|
24
24
|
exports.AUDIO_PREVIEW_PROVIDER_EXTENSION = "@cognigy/audio-preview-provider";
|
|
25
25
|
exports.TRANSLATION_PROVIDER_EXTENSION = "@cognigy/translation-provider";
|
|
26
|
+
exports.DOCUMENT_PARSER_PROVIDER_EXTENSION = "@cognigy/document-parser-provider";
|
|
26
27
|
exports.COGNIGY_LIVE_AGENT_DESCRIPTOR_FIELDS = {
|
|
27
28
|
ESCALATE_INTENTS_HANDOVER_LIVE_AGENT_INBOX_ID: "escalateIntentsHandoverLiveAgentInboxId",
|
|
28
29
|
ESCALATE_INTENTS_AGENT_ASSIST_INIT_MESSAGE: "escalateIntentsAgentAssistInitMessage",
|
|
@@ -36,6 +37,14 @@ exports.COGNIGY_LIVE_AGENT_DESCRIPTOR_FIELDS = {
|
|
|
36
37
|
LIVE_AGENT_PRIORITY: "liveAgentPriority",
|
|
37
38
|
AGENT_ASSIST_INIT_MESSAGE: "agentAssistInitMessage",
|
|
38
39
|
ALLOW_AGENT_INJECT: "allowAgentInject",
|
|
40
|
+
GET_QUEUE_POSITION: "getQueuePosition",
|
|
41
|
+
GET_ESTIMATED_WAIT_TIME: "getEstimatedWaitTime",
|
|
42
|
+
UPDATE_INTERVAL_QUEUE_POSITION: "updateIntervalQueuePosition",
|
|
43
|
+
UPDATE_INTERVAL_ESTIMATED_WAIT_TIME: "updateIntervalEstimatedWaitTime",
|
|
44
|
+
ALTERNATIVE_UPDATE: "alternativeUpdate",
|
|
45
|
+
MAXIMUM_QUEUE_POSITION: "maximumQueuePosition",
|
|
46
|
+
MAXIMUM_ESTIMATED_WAIT_TIME: "maximumEstimatedWaitTime",
|
|
47
|
+
ALTERNATIVE_TEXT: "alternativeText",
|
|
39
48
|
};
|
|
40
49
|
exports.IP_NOT_AVAILABLE = "not available";
|
|
41
50
|
//# sourceMappingURL=constants.js.map
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.logFullConfigToDebugMode = void 0;
|
|
4
|
+
function logFullConfigToDebugMode(cognigy, config, header) {
|
|
5
|
+
var _a;
|
|
6
|
+
const { input, api } = cognigy;
|
|
7
|
+
// sort the object "config" by keys in alphabetic order
|
|
8
|
+
const sortedConfig = Object.keys(config).sort().reduce((acc, key) => {
|
|
9
|
+
acc[key] = config[key];
|
|
10
|
+
return acc;
|
|
11
|
+
}, {});
|
|
12
|
+
if (input.endpointType === "adminconsole" || api.getMetadata().isFollowSessionActive) {
|
|
13
|
+
let totalSettingsString = "";
|
|
14
|
+
Object.keys(sortedConfig).forEach((key) => {
|
|
15
|
+
if (typeof config[key] === "object") {
|
|
16
|
+
totalSettingsString += `${key}:<br>`;
|
|
17
|
+
Object.keys(config[key]).forEach((subkey) => {
|
|
18
|
+
totalSettingsString += `- ${subkey}: ${config[key][subkey]}<br>`;
|
|
19
|
+
});
|
|
20
|
+
totalSettingsString += `<br>`;
|
|
21
|
+
}
|
|
22
|
+
else {
|
|
23
|
+
totalSettingsString += `${key}: ${config[key]}<br>`;
|
|
24
|
+
}
|
|
25
|
+
});
|
|
26
|
+
(_a = api === null || api === void 0 ? void 0 : api.logDebugMessage) === null || _a === void 0 ? void 0 : _a.call(api, `${totalSettingsString}`, header);
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
exports.logFullConfigToDebugMode = logFullConfigToDebugMode;
|
|
30
|
+
//# sourceMappingURL=logFullConfigToDebugMode.js.map
|