@telnyx/ai-chat-widget 3.2.1 → 4.0.2

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/dist/index.d.ts CHANGED
@@ -5,17 +5,27 @@ import * as TooltipPrimitive from '@radix-ui/react-tooltip';
5
5
 
6
6
  declare type BaseProps = {
7
7
  /**
8
- * The endpoint to use for the chat widget
9
- * @default `flow`
8
+ * The default endpoint to use for the chat widget (user can toggle between modes)
9
+ * @default `aida`
10
+ * @deprecated
10
11
  */
11
- endpoint: 'flow' | 'aida';
12
+ endpoint?: 'flow' | 'aida';
12
13
  /**
13
- * The base URL of the flow to execute, Defaults to `https://api.telnyx.com/v2/flow`
14
+ * The base URL for AIDA (Heavy thinking mode)
14
15
  * @required
15
16
  */
16
17
  chatAPIUrl: string;
17
18
  /**
18
- * The base URL of the feedback to send, Defaults to `https://api.telnyx.com/v2/ai/chatbot/feedback`
19
+ * The base URL for Flow (Instant mode). If not provided, uses chatAPIUrl.
20
+ */
21
+ flowAPIUrl?: string;
22
+ /**
23
+ * API key for Flow (Instant mode). If not provided, uses user.api_v2_token.
24
+ * This allows using a separate API key for the Flow chatbot.
25
+ */
26
+ flowApiKey?: string;
27
+ /**
28
+ * The base URL of the feedback to send
19
29
  * @required
20
30
  */
21
31
  feedbackAPIUrl: string;
@@ -48,7 +58,7 @@ declare type BaseProps = {
48
58
  onHelpAction?: () => void;
49
59
  };
50
60
 
51
- export declare const ChatWidget: ({ endpoint, chatAPIUrl, feedbackAPIUrl, user, onHelpAction, open, setOpen, placeholders, mountPosition, mountDirection, offsetX, offsetY, icon, }: ChatWidgetProps) => JSX.Element;
61
+ export declare const ChatWidget: ({ chatAPIUrl, flowAPIUrl, flowApiKey, feedbackAPIUrl, user, onHelpAction, open, setOpen, placeholders, mountPosition, mountDirection, offsetX, offsetY, icon, }: ChatWidgetProps) => JSX.Element;
52
62
 
53
63
  declare interface ChatWidgetNoMounting extends BaseProps {
54
64
  open?: never;