@botonic/core 0.41.1-alpha.0 → 0.42.0-alpha.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.
@@ -28,7 +28,6 @@ interface CarouselElement {
28
28
  export interface CarouselMessage extends BaseMessage {
29
29
  type: 'carousel';
30
30
  content: {
31
- text?: string;
32
31
  elements: CarouselElement[];
33
32
  };
34
33
  }
@@ -1,5 +1,5 @@
1
1
  import { ToolExecution } from './ai-agents';
2
- export declare const EVENT_FORMAT_VERSION = 4;
2
+ export declare const EVENT_FORMAT_VERSION = 5;
3
3
  export declare enum EventAction {
4
4
  AiAgent = "ai_agent",
5
5
  FeedbackCase = "feedback_case",
@@ -8,6 +8,12 @@ export declare enum EventAction {
8
8
  FeedbackKnowledgebase = "feedback_knowledgebase",
9
9
  FeedbackWebview = "feedback_webview",
10
10
  FlowNode = "flow_node",
11
+ ConditionalCountry = "conditional_country",
12
+ ConditionalQueueStatus = "conditional_queue_status",
13
+ ConditionalCustom = "conditional_custom",
14
+ ConditionalChannel = "conditional_channel",
15
+ BotAction = "bot_action",
16
+ WebviewActionTriggered = "webview_action_triggered",
11
17
  HandoffOption = "handoff_option",
12
18
  HandoffSuccess = "handoff_success",
13
19
  HandoffFail = "handoff_fail",
@@ -17,11 +23,19 @@ export declare enum EventAction {
17
23
  Fallback = "fallback",
18
24
  WebviewStep = "webview_step",
19
25
  WebviewEnd = "webview_end",
20
- Custom = "custom"
26
+ Custom = "custom",
27
+ RedirectFlow = "redirect_flow"
21
28
  }
22
29
  export interface HtBaseEventProps {
23
30
  action: EventAction;
24
31
  }
32
+ export interface HtBaseEventAllFlowProps extends HtBaseEventProps {
33
+ flowThreadId: string;
34
+ flowId: string;
35
+ flowName: string;
36
+ flowNodeId: string;
37
+ flowNodeContentId: string;
38
+ }
25
39
  export interface EventFeedback extends HtBaseEventProps {
26
40
  action: EventAction.FeedbackCase | EventAction.FeedbackConversation | EventAction.FeedbackMessage | EventAction.FeedbackWebview;
27
41
  feedbackTargetId: string;
@@ -53,6 +67,30 @@ export interface EventFlow extends HtBaseEventProps {
53
67
  flowNodeContentId: string;
54
68
  flowNodeIsMeaningful?: boolean;
55
69
  }
70
+ export interface EventBotAction extends HtBaseEventAllFlowProps {
71
+ action: EventAction.BotAction;
72
+ payload: string;
73
+ }
74
+ export interface EventConditionalCountry extends HtBaseEventAllFlowProps {
75
+ action: EventAction.ConditionalCountry;
76
+ country: string;
77
+ }
78
+ export interface EventConditionalQueueStatus extends HtBaseEventAllFlowProps {
79
+ action: EventAction.ConditionalQueueStatus;
80
+ queueId: string;
81
+ queueName: string;
82
+ isQueueOpen: boolean;
83
+ isAvailableAgent: boolean;
84
+ }
85
+ export interface EventConditionalCustom extends HtBaseEventAllFlowProps {
86
+ action: EventAction.ConditionalCustom;
87
+ conditionalVariable: string;
88
+ variableFormat: string;
89
+ }
90
+ export interface EventConditionalChannel extends HtBaseEventAllFlowProps {
91
+ action: EventAction.ConditionalChannel;
92
+ channel: string;
93
+ }
56
94
  export interface EventHandoff extends HtBaseEventProps {
57
95
  action: EventAction.HandoffSuccess | EventAction.HandoffFail;
58
96
  flowThreadId?: string;
@@ -115,13 +153,13 @@ export interface EventKnowledgeBase extends HtBaseEventProps {
115
153
  knowledgebaseMessageId: string;
116
154
  userInput: string;
117
155
  }
118
- export interface EventAiAgent extends HtBaseEventProps {
156
+ export interface EventWebviewActionTriggered extends HtBaseEventAllFlowProps {
157
+ action: EventAction.WebviewActionTriggered;
158
+ webviewTargetId: string;
159
+ webviewName: string;
160
+ }
161
+ export interface EventAiAgent extends HtBaseEventAllFlowProps {
119
162
  action: EventAction.AiAgent;
120
- flowThreadId: string;
121
- flowId: string;
122
- flowName: string;
123
- flowNodeId: string;
124
- flowNodeContentId: string;
125
163
  flowNodeIsMeaningful: boolean;
126
164
  toolsExecuted: ToolExecution[];
127
165
  inputMessageId: string;
@@ -131,6 +169,11 @@ export interface EventAiAgent extends HtBaseEventProps {
131
169
  exit: boolean;
132
170
  error: boolean;
133
171
  }
172
+ export interface EventRedirectFlow extends HtBaseEventAllFlowProps {
173
+ action: EventAction.RedirectFlow;
174
+ flowTargetId: string;
175
+ flowTargetName: string;
176
+ }
134
177
  export declare enum KnowledgebaseFailReason {
135
178
  NoKnowledge = "no_knowledge",
136
179
  Hallucination = "hallucination"
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.WebviewEndFailType = exports.KnowledgebaseFailReason = exports.EventAction = exports.EVENT_FORMAT_VERSION = void 0;
4
- exports.EVENT_FORMAT_VERSION = 4;
4
+ exports.EVENT_FORMAT_VERSION = 5;
5
5
  var EventAction;
6
6
  (function (EventAction) {
7
7
  EventAction["AiAgent"] = "ai_agent";
@@ -11,6 +11,12 @@ var EventAction;
11
11
  EventAction["FeedbackKnowledgebase"] = "feedback_knowledgebase";
12
12
  EventAction["FeedbackWebview"] = "feedback_webview";
13
13
  EventAction["FlowNode"] = "flow_node";
14
+ EventAction["ConditionalCountry"] = "conditional_country";
15
+ EventAction["ConditionalQueueStatus"] = "conditional_queue_status";
16
+ EventAction["ConditionalCustom"] = "conditional_custom";
17
+ EventAction["ConditionalChannel"] = "conditional_channel";
18
+ EventAction["BotAction"] = "bot_action";
19
+ EventAction["WebviewActionTriggered"] = "webview_action_triggered";
14
20
  EventAction["HandoffOption"] = "handoff_option";
15
21
  EventAction["HandoffSuccess"] = "handoff_success";
16
22
  EventAction["HandoffFail"] = "handoff_fail";
@@ -21,6 +27,7 @@ var EventAction;
21
27
  EventAction["WebviewStep"] = "webview_step";
22
28
  EventAction["WebviewEnd"] = "webview_end";
23
29
  EventAction["Custom"] = "custom";
30
+ EventAction["RedirectFlow"] = "redirect_flow";
24
31
  })(EventAction = exports.EventAction || (exports.EventAction = {}));
25
32
  var KnowledgebaseFailReason;
26
33
  (function (KnowledgebaseFailReason) {
@@ -1 +1 @@
1
- {"version":3,"file":"hubtype-analytics.js","sourceRoot":"","sources":["../../../src/models/hubtype-analytics.ts"],"names":[],"mappings":";;;AAEa,QAAA,oBAAoB,GAAG,CAAC,CAAA;AAErC,IAAY,WAkBX;AAlBD,WAAY,WAAW;IACrB,mCAAoB,CAAA;IACpB,6CAA8B,CAAA;IAC9B,mDAAoC,CAAA;IACpC,6DAA8C,CAAA;IAC9C,+DAAgD,CAAA;IAChD,mDAAoC,CAAA;IACpC,qCAAsB,CAAA;IACtB,+CAAgC,CAAA;IAChC,iDAAkC,CAAA;IAClC,2CAA4B,CAAA;IAC5B,sCAAuB,CAAA;IACvB,+CAAgC,CAAA;IAChC,8CAA+B,CAAA;IAC/B,oCAAqB,CAAA;IACrB,2CAA4B,CAAA;IAC5B,yCAA0B,CAAA;IAC1B,gCAAiB,CAAA;AACnB,CAAC,EAlBW,WAAW,GAAX,mBAAW,KAAX,mBAAW,QAkBtB;AAgID,IAAY,uBAGX;AAHD,WAAY,uBAAuB;IACjC,uDAA4B,CAAA;IAC5B,0DAA+B,CAAA;AACjC,CAAC,EAHW,uBAAuB,GAAvB,+BAAuB,KAAvB,+BAAuB,QAGlC;AAiCD,IAAY,kBAIX;AAJD,WAAY,kBAAkB;IAC5B,yDAAmC,CAAA;IACnC,4CAAsB,CAAA;IACtB,0DAAoC,CAAA;AACtC,CAAC,EAJW,kBAAkB,GAAlB,0BAAkB,KAAlB,0BAAkB,QAI7B"}
1
+ {"version":3,"file":"hubtype-analytics.js","sourceRoot":"","sources":["../../../src/models/hubtype-analytics.ts"],"names":[],"mappings":";;;AAEa,QAAA,oBAAoB,GAAG,CAAC,CAAA;AAErC,IAAY,WAyBX;AAzBD,WAAY,WAAW;IACrB,mCAAoB,CAAA;IACpB,6CAA8B,CAAA;IAC9B,mDAAoC,CAAA;IACpC,6DAA8C,CAAA;IAC9C,+DAAgD,CAAA;IAChD,mDAAoC,CAAA;IACpC,qCAAsB,CAAA;IACtB,yDAA0C,CAAA;IAC1C,kEAAmD,CAAA;IACnD,uDAAwC,CAAA;IACxC,yDAA0C,CAAA;IAC1C,uCAAwB,CAAA;IACxB,kEAAmD,CAAA;IACnD,+CAAgC,CAAA;IAChC,iDAAkC,CAAA;IAClC,2CAA4B,CAAA;IAC5B,sCAAuB,CAAA;IACvB,+CAAgC,CAAA;IAChC,8CAA+B,CAAA;IAC/B,oCAAqB,CAAA;IACrB,2CAA4B,CAAA;IAC5B,yCAA0B,CAAA;IAC1B,gCAAiB,CAAA;IACjB,6CAA8B,CAAA;AAChC,CAAC,EAzBW,WAAW,GAAX,mBAAW,KAAX,mBAAW,QAyBtB;AA4KD,IAAY,uBAGX;AAHD,WAAY,uBAAuB;IACjC,uDAA4B,CAAA;IAC5B,0DAA+B,CAAA;AACjC,CAAC,EAHW,uBAAuB,GAAvB,+BAAuB,KAAvB,+BAAuB,QAGlC;AAiCD,IAAY,kBAIX;AAJD,WAAY,kBAAkB;IAC5B,yDAAmC,CAAA;IACnC,4CAAsB,CAAA;IACtB,0DAAoC,CAAA;AACtC,CAAC,EAJW,kBAAkB,GAAlB,0BAAkB,KAAlB,0BAAkB,QAI7B"}
@@ -28,7 +28,6 @@ interface CarouselElement {
28
28
  export interface CarouselMessage extends BaseMessage {
29
29
  type: 'carousel';
30
30
  content: {
31
- text?: string;
32
31
  elements: CarouselElement[];
33
32
  };
34
33
  }
@@ -1,5 +1,5 @@
1
1
  import { ToolExecution } from './ai-agents';
2
- export declare const EVENT_FORMAT_VERSION = 4;
2
+ export declare const EVENT_FORMAT_VERSION = 5;
3
3
  export declare enum EventAction {
4
4
  AiAgent = "ai_agent",
5
5
  FeedbackCase = "feedback_case",
@@ -8,6 +8,12 @@ export declare enum EventAction {
8
8
  FeedbackKnowledgebase = "feedback_knowledgebase",
9
9
  FeedbackWebview = "feedback_webview",
10
10
  FlowNode = "flow_node",
11
+ ConditionalCountry = "conditional_country",
12
+ ConditionalQueueStatus = "conditional_queue_status",
13
+ ConditionalCustom = "conditional_custom",
14
+ ConditionalChannel = "conditional_channel",
15
+ BotAction = "bot_action",
16
+ WebviewActionTriggered = "webview_action_triggered",
11
17
  HandoffOption = "handoff_option",
12
18
  HandoffSuccess = "handoff_success",
13
19
  HandoffFail = "handoff_fail",
@@ -17,11 +23,19 @@ export declare enum EventAction {
17
23
  Fallback = "fallback",
18
24
  WebviewStep = "webview_step",
19
25
  WebviewEnd = "webview_end",
20
- Custom = "custom"
26
+ Custom = "custom",
27
+ RedirectFlow = "redirect_flow"
21
28
  }
22
29
  export interface HtBaseEventProps {
23
30
  action: EventAction;
24
31
  }
32
+ export interface HtBaseEventAllFlowProps extends HtBaseEventProps {
33
+ flowThreadId: string;
34
+ flowId: string;
35
+ flowName: string;
36
+ flowNodeId: string;
37
+ flowNodeContentId: string;
38
+ }
25
39
  export interface EventFeedback extends HtBaseEventProps {
26
40
  action: EventAction.FeedbackCase | EventAction.FeedbackConversation | EventAction.FeedbackMessage | EventAction.FeedbackWebview;
27
41
  feedbackTargetId: string;
@@ -53,6 +67,30 @@ export interface EventFlow extends HtBaseEventProps {
53
67
  flowNodeContentId: string;
54
68
  flowNodeIsMeaningful?: boolean;
55
69
  }
70
+ export interface EventBotAction extends HtBaseEventAllFlowProps {
71
+ action: EventAction.BotAction;
72
+ payload: string;
73
+ }
74
+ export interface EventConditionalCountry extends HtBaseEventAllFlowProps {
75
+ action: EventAction.ConditionalCountry;
76
+ country: string;
77
+ }
78
+ export interface EventConditionalQueueStatus extends HtBaseEventAllFlowProps {
79
+ action: EventAction.ConditionalQueueStatus;
80
+ queueId: string;
81
+ queueName: string;
82
+ isQueueOpen: boolean;
83
+ isAvailableAgent: boolean;
84
+ }
85
+ export interface EventConditionalCustom extends HtBaseEventAllFlowProps {
86
+ action: EventAction.ConditionalCustom;
87
+ conditionalVariable: string;
88
+ variableFormat: string;
89
+ }
90
+ export interface EventConditionalChannel extends HtBaseEventAllFlowProps {
91
+ action: EventAction.ConditionalChannel;
92
+ channel: string;
93
+ }
56
94
  export interface EventHandoff extends HtBaseEventProps {
57
95
  action: EventAction.HandoffSuccess | EventAction.HandoffFail;
58
96
  flowThreadId?: string;
@@ -115,13 +153,13 @@ export interface EventKnowledgeBase extends HtBaseEventProps {
115
153
  knowledgebaseMessageId: string;
116
154
  userInput: string;
117
155
  }
118
- export interface EventAiAgent extends HtBaseEventProps {
156
+ export interface EventWebviewActionTriggered extends HtBaseEventAllFlowProps {
157
+ action: EventAction.WebviewActionTriggered;
158
+ webviewTargetId: string;
159
+ webviewName: string;
160
+ }
161
+ export interface EventAiAgent extends HtBaseEventAllFlowProps {
119
162
  action: EventAction.AiAgent;
120
- flowThreadId: string;
121
- flowId: string;
122
- flowName: string;
123
- flowNodeId: string;
124
- flowNodeContentId: string;
125
163
  flowNodeIsMeaningful: boolean;
126
164
  toolsExecuted: ToolExecution[];
127
165
  inputMessageId: string;
@@ -131,6 +169,11 @@ export interface EventAiAgent extends HtBaseEventProps {
131
169
  exit: boolean;
132
170
  error: boolean;
133
171
  }
172
+ export interface EventRedirectFlow extends HtBaseEventAllFlowProps {
173
+ action: EventAction.RedirectFlow;
174
+ flowTargetId: string;
175
+ flowTargetName: string;
176
+ }
134
177
  export declare enum KnowledgebaseFailReason {
135
178
  NoKnowledge = "no_knowledge",
136
179
  Hallucination = "hallucination"
@@ -1,4 +1,4 @@
1
- export const EVENT_FORMAT_VERSION = 4;
1
+ export const EVENT_FORMAT_VERSION = 5;
2
2
  export var EventAction;
3
3
  (function (EventAction) {
4
4
  EventAction["AiAgent"] = "ai_agent";
@@ -8,6 +8,12 @@ export var EventAction;
8
8
  EventAction["FeedbackKnowledgebase"] = "feedback_knowledgebase";
9
9
  EventAction["FeedbackWebview"] = "feedback_webview";
10
10
  EventAction["FlowNode"] = "flow_node";
11
+ EventAction["ConditionalCountry"] = "conditional_country";
12
+ EventAction["ConditionalQueueStatus"] = "conditional_queue_status";
13
+ EventAction["ConditionalCustom"] = "conditional_custom";
14
+ EventAction["ConditionalChannel"] = "conditional_channel";
15
+ EventAction["BotAction"] = "bot_action";
16
+ EventAction["WebviewActionTriggered"] = "webview_action_triggered";
11
17
  EventAction["HandoffOption"] = "handoff_option";
12
18
  EventAction["HandoffSuccess"] = "handoff_success";
13
19
  EventAction["HandoffFail"] = "handoff_fail";
@@ -18,6 +24,7 @@ export var EventAction;
18
24
  EventAction["WebviewStep"] = "webview_step";
19
25
  EventAction["WebviewEnd"] = "webview_end";
20
26
  EventAction["Custom"] = "custom";
27
+ EventAction["RedirectFlow"] = "redirect_flow";
21
28
  })(EventAction || (EventAction = {}));
22
29
  export var KnowledgebaseFailReason;
23
30
  (function (KnowledgebaseFailReason) {
@@ -1 +1 @@
1
- {"version":3,"file":"hubtype-analytics.js","sourceRoot":"","sources":["../../../src/models/hubtype-analytics.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,MAAM,oBAAoB,GAAG,CAAC,CAAA;AAErC,MAAM,CAAN,IAAY,WAkBX;AAlBD,WAAY,WAAW;IACrB,mCAAoB,CAAA;IACpB,6CAA8B,CAAA;IAC9B,mDAAoC,CAAA;IACpC,6DAA8C,CAAA;IAC9C,+DAAgD,CAAA;IAChD,mDAAoC,CAAA;IACpC,qCAAsB,CAAA;IACtB,+CAAgC,CAAA;IAChC,iDAAkC,CAAA;IAClC,2CAA4B,CAAA;IAC5B,sCAAuB,CAAA;IACvB,+CAAgC,CAAA;IAChC,8CAA+B,CAAA;IAC/B,oCAAqB,CAAA;IACrB,2CAA4B,CAAA;IAC5B,yCAA0B,CAAA;IAC1B,gCAAiB,CAAA;AACnB,CAAC,EAlBW,WAAW,KAAX,WAAW,QAkBtB;AAgID,MAAM,CAAN,IAAY,uBAGX;AAHD,WAAY,uBAAuB;IACjC,uDAA4B,CAAA;IAC5B,0DAA+B,CAAA;AACjC,CAAC,EAHW,uBAAuB,KAAvB,uBAAuB,QAGlC;AAiCD,MAAM,CAAN,IAAY,kBAIX;AAJD,WAAY,kBAAkB;IAC5B,yDAAmC,CAAA;IACnC,4CAAsB,CAAA;IACtB,0DAAoC,CAAA;AACtC,CAAC,EAJW,kBAAkB,KAAlB,kBAAkB,QAI7B"}
1
+ {"version":3,"file":"hubtype-analytics.js","sourceRoot":"","sources":["../../../src/models/hubtype-analytics.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,MAAM,oBAAoB,GAAG,CAAC,CAAA;AAErC,MAAM,CAAN,IAAY,WAyBX;AAzBD,WAAY,WAAW;IACrB,mCAAoB,CAAA;IACpB,6CAA8B,CAAA;IAC9B,mDAAoC,CAAA;IACpC,6DAA8C,CAAA;IAC9C,+DAAgD,CAAA;IAChD,mDAAoC,CAAA;IACpC,qCAAsB,CAAA;IACtB,yDAA0C,CAAA;IAC1C,kEAAmD,CAAA;IACnD,uDAAwC,CAAA;IACxC,yDAA0C,CAAA;IAC1C,uCAAwB,CAAA;IACxB,kEAAmD,CAAA;IACnD,+CAAgC,CAAA;IAChC,iDAAkC,CAAA;IAClC,2CAA4B,CAAA;IAC5B,sCAAuB,CAAA;IACvB,+CAAgC,CAAA;IAChC,8CAA+B,CAAA;IAC/B,oCAAqB,CAAA;IACrB,2CAA4B,CAAA;IAC5B,yCAA0B,CAAA;IAC1B,gCAAiB,CAAA;IACjB,6CAA8B,CAAA;AAChC,CAAC,EAzBW,WAAW,KAAX,WAAW,QAyBtB;AA4KD,MAAM,CAAN,IAAY,uBAGX;AAHD,WAAY,uBAAuB;IACjC,uDAA4B,CAAA;IAC5B,0DAA+B,CAAA;AACjC,CAAC,EAHW,uBAAuB,KAAvB,uBAAuB,QAGlC;AAiCD,MAAM,CAAN,IAAY,kBAIX;AAJD,WAAY,kBAAkB;IAC5B,yDAAmC,CAAA;IACnC,4CAAsB,CAAA;IACtB,0DAAoC,CAAA;AACtC,CAAC,EAJW,kBAAkB,KAAlB,kBAAkB,QAI7B"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@botonic/core",
3
- "version": "0.41.1-alpha.0",
3
+ "version": "0.42.0-alpha.0",
4
4
  "license": "MIT",
5
5
  "description": "Build Chatbots using React",
6
6
  "main": "./lib/cjs/index.js",
@@ -33,7 +33,6 @@ interface CarouselElement {
33
33
  export interface CarouselMessage extends BaseMessage {
34
34
  type: 'carousel'
35
35
  content: {
36
- text?: string
37
36
  elements: CarouselElement[]
38
37
  }
39
38
  }
@@ -1,6 +1,6 @@
1
1
  import { ToolExecution } from './ai-agents'
2
2
 
3
- export const EVENT_FORMAT_VERSION = 4
3
+ export const EVENT_FORMAT_VERSION = 5
4
4
 
5
5
  export enum EventAction {
6
6
  AiAgent = 'ai_agent',
@@ -10,6 +10,12 @@ export enum EventAction {
10
10
  FeedbackKnowledgebase = 'feedback_knowledgebase',
11
11
  FeedbackWebview = 'feedback_webview',
12
12
  FlowNode = 'flow_node',
13
+ ConditionalCountry = 'conditional_country',
14
+ ConditionalQueueStatus = 'conditional_queue_status',
15
+ ConditionalCustom = 'conditional_custom',
16
+ ConditionalChannel = 'conditional_channel',
17
+ BotAction = 'bot_action',
18
+ WebviewActionTriggered = 'webview_action_triggered',
13
19
  HandoffOption = 'handoff_option',
14
20
  HandoffSuccess = 'handoff_success',
15
21
  HandoffFail = 'handoff_fail',
@@ -20,12 +26,21 @@ export enum EventAction {
20
26
  WebviewStep = 'webview_step',
21
27
  WebviewEnd = 'webview_end',
22
28
  Custom = 'custom',
29
+ RedirectFlow = 'redirect_flow',
23
30
  }
24
31
 
25
32
  export interface HtBaseEventProps {
26
33
  action: EventAction
27
34
  }
28
35
 
36
+ export interface HtBaseEventAllFlowProps extends HtBaseEventProps {
37
+ flowThreadId: string
38
+ flowId: string
39
+ flowName: string
40
+ flowNodeId: string
41
+ flowNodeContentId: string
42
+ }
43
+
29
44
  export interface EventFeedback extends HtBaseEventProps {
30
45
  action:
31
46
  | EventAction.FeedbackCase
@@ -64,6 +79,35 @@ export interface EventFlow extends HtBaseEventProps {
64
79
  flowNodeIsMeaningful?: boolean
65
80
  }
66
81
 
82
+ export interface EventBotAction extends HtBaseEventAllFlowProps {
83
+ action: EventAction.BotAction
84
+ payload: string
85
+ }
86
+
87
+ export interface EventConditionalCountry extends HtBaseEventAllFlowProps {
88
+ action: EventAction.ConditionalCountry
89
+ country: string
90
+ }
91
+
92
+ export interface EventConditionalQueueStatus extends HtBaseEventAllFlowProps {
93
+ action: EventAction.ConditionalQueueStatus
94
+ queueId: string
95
+ queueName: string
96
+ isQueueOpen: boolean
97
+ isAvailableAgent: boolean
98
+ }
99
+
100
+ export interface EventConditionalCustom extends HtBaseEventAllFlowProps {
101
+ action: EventAction.ConditionalCustom
102
+ conditionalVariable: string
103
+ variableFormat: string
104
+ }
105
+
106
+ export interface EventConditionalChannel extends HtBaseEventAllFlowProps {
107
+ action: EventAction.ConditionalChannel
108
+ channel: string
109
+ }
110
+
67
111
  export interface EventHandoff extends HtBaseEventProps {
68
112
  action: EventAction.HandoffSuccess | EventAction.HandoffFail
69
113
  flowThreadId?: string
@@ -131,13 +175,14 @@ export interface EventKnowledgeBase extends HtBaseEventProps {
131
175
  userInput: string
132
176
  }
133
177
 
134
- export interface EventAiAgent extends HtBaseEventProps {
178
+ export interface EventWebviewActionTriggered extends HtBaseEventAllFlowProps {
179
+ action: EventAction.WebviewActionTriggered
180
+ webviewTargetId: string
181
+ webviewName: string
182
+ }
183
+
184
+ export interface EventAiAgent extends HtBaseEventAllFlowProps {
135
185
  action: EventAction.AiAgent
136
- flowThreadId: string
137
- flowId: string
138
- flowName: string
139
- flowNodeId: string
140
- flowNodeContentId: string
141
186
  flowNodeIsMeaningful: boolean
142
187
  toolsExecuted: ToolExecution[]
143
188
  inputMessageId: string
@@ -148,6 +193,12 @@ export interface EventAiAgent extends HtBaseEventProps {
148
193
  error: boolean
149
194
  }
150
195
 
196
+ export interface EventRedirectFlow extends HtBaseEventAllFlowProps {
197
+ action: EventAction.RedirectFlow
198
+ flowTargetId: string
199
+ flowTargetName: string
200
+ }
201
+
151
202
  export enum KnowledgebaseFailReason {
152
203
  NoKnowledge = 'no_knowledge',
153
204
  Hallucination = 'hallucination',