@invergent/agent-chat-react 2.5.4 → 2.5.6

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.cts CHANGED
@@ -556,6 +556,30 @@ interface AgentChatAdapter {
556
556
  reason?: string;
557
557
  cascadeToWorkers?: boolean;
558
558
  }): Promise<void>;
559
+ listComposioConnections?(input: {
560
+ agentId?: string;
561
+ }): Promise<{
562
+ toolkits: {
563
+ toolkit: string;
564
+ connected: boolean;
565
+ name?: string;
566
+ logo?: string;
567
+ category?: string;
568
+ description?: string;
569
+ auth_mode?: string;
570
+ }[];
571
+ }>;
572
+ authorizeComposioToolkit?(input: {
573
+ agentId?: string;
574
+ toolkit: string;
575
+ }): Promise<{
576
+ redirectUrl: string;
577
+ status: string;
578
+ }>;
579
+ disconnectComposioToolkit?(input: {
580
+ agentId?: string;
581
+ toolkit: string;
582
+ }): Promise<void>;
559
583
  listInbox?(input?: AgentChatInboxListInput): Promise<AgentChatInboxList>;
560
584
  getInboxItem?(input: {
561
585
  itemId: number;
@@ -754,8 +778,14 @@ interface AgentChatProps {
754
778
  * that domain.
755
779
  */
756
780
  deepResearchEnabled?: boolean;
781
+ /**
782
+ * Called when the user clicks the integrations band under the composer.
783
+ * Hosts navigate to their Integrations route. When omitted, the band is
784
+ * not rendered.
785
+ */
786
+ onOpenIntegrations?: () => void;
757
787
  }
758
- declare function AgentChat({ adapter, agentId, sessionId, onSessionChange, onFileSelect, onMessagesChange, disabled, onComposerError, deepResearchEnabled, }: AgentChatProps): react_jsx_runtime.JSX.Element;
788
+ declare function AgentChat({ adapter, agentId, sessionId, onSessionChange, onFileSelect, onMessagesChange, disabled, onComposerError, deepResearchEnabled, onOpenIntegrations, }: AgentChatProps): react_jsx_runtime.JSX.Element;
759
789
 
760
790
  interface AgentChatAdapterContextValue {
761
791
  adapter: AgentChatAdapter;
@@ -777,6 +807,44 @@ declare function useAgentChatRuntime({ adapter, agentId, sessionId, onSessionCha
777
807
  type MessageResponseProps = ComponentProps<typeof Streamdown>;
778
808
  declare const MessageResponse: React.MemoExoticComponent<({ className, ...props }: MessageResponseProps) => react_jsx_runtime.JSX.Element>;
779
809
 
810
+ interface ComposioConnectCardProps {
811
+ /** The Composio hosted connect URL (connect.composio.dev/link/…). */
812
+ url: string;
813
+ /** The original link text, e.g. "Connect Jira". */
814
+ label?: string;
815
+ }
816
+ /**
817
+ * Rendered in place of a raw ``connect.composio.dev`` markdown link in an
818
+ * assistant message: a tidy card with the toolkit name and a Connect button
819
+ * that opens the hosted auth flow in a popup. Works for any Composio toolkit.
820
+ */
821
+ declare function ComposioConnectCard({ url, label }: ComposioConnectCardProps): react_jsx_runtime.JSX.Element;
822
+
823
+ interface IntegrationsBandProps {
824
+ agentId?: string;
825
+ adapter: AgentChatAdapter;
826
+ onOpenIntegrations: () => void;
827
+ }
828
+ /**
829
+ * Thin strip under the composer. Shows up to ten connected toolkit logos and
830
+ * a "Connect your accounts" prompt; the whole band opens the Integrations
831
+ * page. Renders nothing when the adapter lacks the Composio methods or the
832
+ * agent has no assigned toolkits.
833
+ */
834
+ declare function IntegrationsBand({ agentId, adapter, onOpenIntegrations, }: IntegrationsBandProps): react_jsx_runtime.JSX.Element | null;
835
+
836
+ interface IntegrationsPageProps {
837
+ agentId?: string;
838
+ adapter: AgentChatAdapter;
839
+ onBack: () => void;
840
+ }
841
+ /**
842
+ * Full-screen Integrations view: search + category groups + per-toolkit
843
+ * Connect/Disconnect. Lists the agent's assigned toolkits (from the adapter),
844
+ * rendering whatever metadata the backend enriched the rows with.
845
+ */
846
+ declare function IntegrationsPage({ agentId, adapter, onBack }: IntegrationsPageProps): react_jsx_runtime.JSX.Element;
847
+
780
848
  interface InboxPanelProps {
781
849
  adapter: AgentChatAdapter;
782
850
  title?: string;
@@ -907,4 +975,4 @@ interface SessionTreePanelProps {
907
975
  }
908
976
  declare function SessionTreePanel({ adapter, sessionId, activeSessionId, agentId, title, sessionListLimit, hideRoot, hideHeader, loadList, onSessionSelect, onSessionDelete, }: SessionTreePanelProps): react_jsx_runtime.JSX.Element | null;
909
977
 
910
- export { ACTIVE_MISSION_STATUSES, AgentChat, type AgentChatAdapter, type AgentChatAdapterContextValue, AgentChatAdapterProvider, type AgentChatArtifactKind, type AgentChatArtifactMeta, type AgentChatArtifactPayload, type AgentChatAskUserQuestionAnswer, type AgentChatAskUserQuestionArgs, type AgentChatAskUserQuestionChoice, type AgentChatAskUserQuestionQuestion, type AgentChatAttachment, type AgentChatChartArtifactSpec, type AgentChatDisplayAttachment, type AgentChatErrorCategory, type AgentChatErrorInfo, type AgentChatEventStream, type AgentChatEventType, type AgentChatExpertFeedbackRating, type AgentChatHtmlArtifactSpec, type AgentChatImageAttachment, type AgentChatInboxEventStream, type AgentChatInboxItem, type AgentChatInboxKind, type AgentChatInboxList, type AgentChatInboxListInput, type AgentChatInboxStatus, type AgentChatInboxStreamEvent, type AgentChatMarkdownArtifactSpec, type AgentChatMessage, type AgentChatMessageStatus, type AgentChatMissionList, type AgentChatMissionStatus, type AgentChatMissionSummary, type AgentChatMissionTask, type AgentChatMissionWorker, type AgentChatPendingAttachment, type AgentChatProps, type AgentChatResearchSource, type AgentChatRole, type AgentChatRuntimeApi, type AgentChatRuntimeEvent, type AgentChatScheduledWorkItem, type AgentChatScheduledWorkKind, type AgentChatScheduledWorkList, type AgentChatSession, type AgentChatSessionList, type AgentChatSessionTree, type AgentChatSessionTreeNode, type AgentChatSlashCommand, type AgentChatSseMessageEvent, type AgentChatState, type AgentChatSvgArtifactSpec, type AgentChatSystemKind, type AgentChatTableArtifactSpec, type AgentChatTokenUsage, type AgentChatToolCallInfo, type AgentChatWorkspaceEntry, type AgentChatWorkspaceFile, type AgentChatWorkspaceTree, type AgentChatWorkspaceUpload, type ArtifactKind, type ArtifactPayload, type AskUserQuestionAnswer, type AskUserQuestionArgs, type AskUserQuestionChoice, type AskUserQuestionQuestion, type ChartArtifactSpec, type ChatComposerError, type ChatMessage, type CitationSegment, CitationText, type ErrorInfo, type HtmlArtifactSpec, type InboxItem, type InboxList, InboxPanel, type InboxPanelProps, type InboxUnreadCountState, type MarkdownArtifactSpec, MessageResponse, type MessageResponseProps, MissionDashboard, type MissionDashboardProps, type MissionTaskBucket, MissionsPanel, type MissionsPanelProps, ResearchSourcesPanel, type RetryIndicator, type ScheduledWorkItem, type ScheduledWorkList, ScheduledWorkPanel, type ScheduledWorkPanelProps, type SessionTree, type SessionTreeNode, SessionTreePanel, type SessionTreePanelProps, type SvgArtifactSpec, type TableArtifactSpec, type TokenUsage, type ToolCallInfo, type WorkspaceEntry, type WorkspaceFile, type WorkspaceTree, type WorkspaceUpload, deriveMissionWorkerActivityLabel, groupMissionTasksByBucket, isTerminalMissionStatus, missionTaskBucket, splitCitations, useAgentChatAdapterContext, useAgentChatRuntime, useChatViewMode, useInboxUnreadCount };
978
+ export { ACTIVE_MISSION_STATUSES, AgentChat, type AgentChatAdapter, type AgentChatAdapterContextValue, AgentChatAdapterProvider, type AgentChatArtifactKind, type AgentChatArtifactMeta, type AgentChatArtifactPayload, type AgentChatAskUserQuestionAnswer, type AgentChatAskUserQuestionArgs, type AgentChatAskUserQuestionChoice, type AgentChatAskUserQuestionQuestion, type AgentChatAttachment, type AgentChatChartArtifactSpec, type AgentChatDisplayAttachment, type AgentChatErrorCategory, type AgentChatErrorInfo, type AgentChatEventStream, type AgentChatEventType, type AgentChatExpertFeedbackRating, type AgentChatHtmlArtifactSpec, type AgentChatImageAttachment, type AgentChatInboxEventStream, type AgentChatInboxItem, type AgentChatInboxKind, type AgentChatInboxList, type AgentChatInboxListInput, type AgentChatInboxStatus, type AgentChatInboxStreamEvent, type AgentChatMarkdownArtifactSpec, type AgentChatMessage, type AgentChatMessageStatus, type AgentChatMissionList, type AgentChatMissionStatus, type AgentChatMissionSummary, type AgentChatMissionTask, type AgentChatMissionWorker, type AgentChatPendingAttachment, type AgentChatProps, type AgentChatResearchSource, type AgentChatRole, type AgentChatRuntimeApi, type AgentChatRuntimeEvent, type AgentChatScheduledWorkItem, type AgentChatScheduledWorkKind, type AgentChatScheduledWorkList, type AgentChatSession, type AgentChatSessionList, type AgentChatSessionTree, type AgentChatSessionTreeNode, type AgentChatSlashCommand, type AgentChatSseMessageEvent, type AgentChatState, type AgentChatSvgArtifactSpec, type AgentChatSystemKind, type AgentChatTableArtifactSpec, type AgentChatTokenUsage, type AgentChatToolCallInfo, type AgentChatWorkspaceEntry, type AgentChatWorkspaceFile, type AgentChatWorkspaceTree, type AgentChatWorkspaceUpload, type ArtifactKind, type ArtifactPayload, type AskUserQuestionAnswer, type AskUserQuestionArgs, type AskUserQuestionChoice, type AskUserQuestionQuestion, type ChartArtifactSpec, type ChatComposerError, type ChatMessage, type CitationSegment, CitationText, ComposioConnectCard, type ComposioConnectCardProps, type ErrorInfo, type HtmlArtifactSpec, type InboxItem, type InboxList, InboxPanel, type InboxPanelProps, type InboxUnreadCountState, IntegrationsBand, type IntegrationsBandProps, IntegrationsPage, type IntegrationsPageProps, type MarkdownArtifactSpec, MessageResponse, type MessageResponseProps, MissionDashboard, type MissionDashboardProps, type MissionTaskBucket, MissionsPanel, type MissionsPanelProps, ResearchSourcesPanel, type RetryIndicator, type ScheduledWorkItem, type ScheduledWorkList, ScheduledWorkPanel, type ScheduledWorkPanelProps, type SessionTree, type SessionTreeNode, SessionTreePanel, type SessionTreePanelProps, type SvgArtifactSpec, type TableArtifactSpec, type TokenUsage, type ToolCallInfo, type WorkspaceEntry, type WorkspaceFile, type WorkspaceTree, type WorkspaceUpload, deriveMissionWorkerActivityLabel, groupMissionTasksByBucket, isTerminalMissionStatus, missionTaskBucket, splitCitations, useAgentChatAdapterContext, useAgentChatRuntime, useChatViewMode, useInboxUnreadCount };
package/dist/index.d.ts CHANGED
@@ -556,6 +556,30 @@ interface AgentChatAdapter {
556
556
  reason?: string;
557
557
  cascadeToWorkers?: boolean;
558
558
  }): Promise<void>;
559
+ listComposioConnections?(input: {
560
+ agentId?: string;
561
+ }): Promise<{
562
+ toolkits: {
563
+ toolkit: string;
564
+ connected: boolean;
565
+ name?: string;
566
+ logo?: string;
567
+ category?: string;
568
+ description?: string;
569
+ auth_mode?: string;
570
+ }[];
571
+ }>;
572
+ authorizeComposioToolkit?(input: {
573
+ agentId?: string;
574
+ toolkit: string;
575
+ }): Promise<{
576
+ redirectUrl: string;
577
+ status: string;
578
+ }>;
579
+ disconnectComposioToolkit?(input: {
580
+ agentId?: string;
581
+ toolkit: string;
582
+ }): Promise<void>;
559
583
  listInbox?(input?: AgentChatInboxListInput): Promise<AgentChatInboxList>;
560
584
  getInboxItem?(input: {
561
585
  itemId: number;
@@ -754,8 +778,14 @@ interface AgentChatProps {
754
778
  * that domain.
755
779
  */
756
780
  deepResearchEnabled?: boolean;
781
+ /**
782
+ * Called when the user clicks the integrations band under the composer.
783
+ * Hosts navigate to their Integrations route. When omitted, the band is
784
+ * not rendered.
785
+ */
786
+ onOpenIntegrations?: () => void;
757
787
  }
758
- declare function AgentChat({ adapter, agentId, sessionId, onSessionChange, onFileSelect, onMessagesChange, disabled, onComposerError, deepResearchEnabled, }: AgentChatProps): react_jsx_runtime.JSX.Element;
788
+ declare function AgentChat({ adapter, agentId, sessionId, onSessionChange, onFileSelect, onMessagesChange, disabled, onComposerError, deepResearchEnabled, onOpenIntegrations, }: AgentChatProps): react_jsx_runtime.JSX.Element;
759
789
 
760
790
  interface AgentChatAdapterContextValue {
761
791
  adapter: AgentChatAdapter;
@@ -777,6 +807,44 @@ declare function useAgentChatRuntime({ adapter, agentId, sessionId, onSessionCha
777
807
  type MessageResponseProps = ComponentProps<typeof Streamdown>;
778
808
  declare const MessageResponse: React.MemoExoticComponent<({ className, ...props }: MessageResponseProps) => react_jsx_runtime.JSX.Element>;
779
809
 
810
+ interface ComposioConnectCardProps {
811
+ /** The Composio hosted connect URL (connect.composio.dev/link/…). */
812
+ url: string;
813
+ /** The original link text, e.g. "Connect Jira". */
814
+ label?: string;
815
+ }
816
+ /**
817
+ * Rendered in place of a raw ``connect.composio.dev`` markdown link in an
818
+ * assistant message: a tidy card with the toolkit name and a Connect button
819
+ * that opens the hosted auth flow in a popup. Works for any Composio toolkit.
820
+ */
821
+ declare function ComposioConnectCard({ url, label }: ComposioConnectCardProps): react_jsx_runtime.JSX.Element;
822
+
823
+ interface IntegrationsBandProps {
824
+ agentId?: string;
825
+ adapter: AgentChatAdapter;
826
+ onOpenIntegrations: () => void;
827
+ }
828
+ /**
829
+ * Thin strip under the composer. Shows up to ten connected toolkit logos and
830
+ * a "Connect your accounts" prompt; the whole band opens the Integrations
831
+ * page. Renders nothing when the adapter lacks the Composio methods or the
832
+ * agent has no assigned toolkits.
833
+ */
834
+ declare function IntegrationsBand({ agentId, adapter, onOpenIntegrations, }: IntegrationsBandProps): react_jsx_runtime.JSX.Element | null;
835
+
836
+ interface IntegrationsPageProps {
837
+ agentId?: string;
838
+ adapter: AgentChatAdapter;
839
+ onBack: () => void;
840
+ }
841
+ /**
842
+ * Full-screen Integrations view: search + category groups + per-toolkit
843
+ * Connect/Disconnect. Lists the agent's assigned toolkits (from the adapter),
844
+ * rendering whatever metadata the backend enriched the rows with.
845
+ */
846
+ declare function IntegrationsPage({ agentId, adapter, onBack }: IntegrationsPageProps): react_jsx_runtime.JSX.Element;
847
+
780
848
  interface InboxPanelProps {
781
849
  adapter: AgentChatAdapter;
782
850
  title?: string;
@@ -907,4 +975,4 @@ interface SessionTreePanelProps {
907
975
  }
908
976
  declare function SessionTreePanel({ adapter, sessionId, activeSessionId, agentId, title, sessionListLimit, hideRoot, hideHeader, loadList, onSessionSelect, onSessionDelete, }: SessionTreePanelProps): react_jsx_runtime.JSX.Element | null;
909
977
 
910
- export { ACTIVE_MISSION_STATUSES, AgentChat, type AgentChatAdapter, type AgentChatAdapterContextValue, AgentChatAdapterProvider, type AgentChatArtifactKind, type AgentChatArtifactMeta, type AgentChatArtifactPayload, type AgentChatAskUserQuestionAnswer, type AgentChatAskUserQuestionArgs, type AgentChatAskUserQuestionChoice, type AgentChatAskUserQuestionQuestion, type AgentChatAttachment, type AgentChatChartArtifactSpec, type AgentChatDisplayAttachment, type AgentChatErrorCategory, type AgentChatErrorInfo, type AgentChatEventStream, type AgentChatEventType, type AgentChatExpertFeedbackRating, type AgentChatHtmlArtifactSpec, type AgentChatImageAttachment, type AgentChatInboxEventStream, type AgentChatInboxItem, type AgentChatInboxKind, type AgentChatInboxList, type AgentChatInboxListInput, type AgentChatInboxStatus, type AgentChatInboxStreamEvent, type AgentChatMarkdownArtifactSpec, type AgentChatMessage, type AgentChatMessageStatus, type AgentChatMissionList, type AgentChatMissionStatus, type AgentChatMissionSummary, type AgentChatMissionTask, type AgentChatMissionWorker, type AgentChatPendingAttachment, type AgentChatProps, type AgentChatResearchSource, type AgentChatRole, type AgentChatRuntimeApi, type AgentChatRuntimeEvent, type AgentChatScheduledWorkItem, type AgentChatScheduledWorkKind, type AgentChatScheduledWorkList, type AgentChatSession, type AgentChatSessionList, type AgentChatSessionTree, type AgentChatSessionTreeNode, type AgentChatSlashCommand, type AgentChatSseMessageEvent, type AgentChatState, type AgentChatSvgArtifactSpec, type AgentChatSystemKind, type AgentChatTableArtifactSpec, type AgentChatTokenUsage, type AgentChatToolCallInfo, type AgentChatWorkspaceEntry, type AgentChatWorkspaceFile, type AgentChatWorkspaceTree, type AgentChatWorkspaceUpload, type ArtifactKind, type ArtifactPayload, type AskUserQuestionAnswer, type AskUserQuestionArgs, type AskUserQuestionChoice, type AskUserQuestionQuestion, type ChartArtifactSpec, type ChatComposerError, type ChatMessage, type CitationSegment, CitationText, type ErrorInfo, type HtmlArtifactSpec, type InboxItem, type InboxList, InboxPanel, type InboxPanelProps, type InboxUnreadCountState, type MarkdownArtifactSpec, MessageResponse, type MessageResponseProps, MissionDashboard, type MissionDashboardProps, type MissionTaskBucket, MissionsPanel, type MissionsPanelProps, ResearchSourcesPanel, type RetryIndicator, type ScheduledWorkItem, type ScheduledWorkList, ScheduledWorkPanel, type ScheduledWorkPanelProps, type SessionTree, type SessionTreeNode, SessionTreePanel, type SessionTreePanelProps, type SvgArtifactSpec, type TableArtifactSpec, type TokenUsage, type ToolCallInfo, type WorkspaceEntry, type WorkspaceFile, type WorkspaceTree, type WorkspaceUpload, deriveMissionWorkerActivityLabel, groupMissionTasksByBucket, isTerminalMissionStatus, missionTaskBucket, splitCitations, useAgentChatAdapterContext, useAgentChatRuntime, useChatViewMode, useInboxUnreadCount };
978
+ export { ACTIVE_MISSION_STATUSES, AgentChat, type AgentChatAdapter, type AgentChatAdapterContextValue, AgentChatAdapterProvider, type AgentChatArtifactKind, type AgentChatArtifactMeta, type AgentChatArtifactPayload, type AgentChatAskUserQuestionAnswer, type AgentChatAskUserQuestionArgs, type AgentChatAskUserQuestionChoice, type AgentChatAskUserQuestionQuestion, type AgentChatAttachment, type AgentChatChartArtifactSpec, type AgentChatDisplayAttachment, type AgentChatErrorCategory, type AgentChatErrorInfo, type AgentChatEventStream, type AgentChatEventType, type AgentChatExpertFeedbackRating, type AgentChatHtmlArtifactSpec, type AgentChatImageAttachment, type AgentChatInboxEventStream, type AgentChatInboxItem, type AgentChatInboxKind, type AgentChatInboxList, type AgentChatInboxListInput, type AgentChatInboxStatus, type AgentChatInboxStreamEvent, type AgentChatMarkdownArtifactSpec, type AgentChatMessage, type AgentChatMessageStatus, type AgentChatMissionList, type AgentChatMissionStatus, type AgentChatMissionSummary, type AgentChatMissionTask, type AgentChatMissionWorker, type AgentChatPendingAttachment, type AgentChatProps, type AgentChatResearchSource, type AgentChatRole, type AgentChatRuntimeApi, type AgentChatRuntimeEvent, type AgentChatScheduledWorkItem, type AgentChatScheduledWorkKind, type AgentChatScheduledWorkList, type AgentChatSession, type AgentChatSessionList, type AgentChatSessionTree, type AgentChatSessionTreeNode, type AgentChatSlashCommand, type AgentChatSseMessageEvent, type AgentChatState, type AgentChatSvgArtifactSpec, type AgentChatSystemKind, type AgentChatTableArtifactSpec, type AgentChatTokenUsage, type AgentChatToolCallInfo, type AgentChatWorkspaceEntry, type AgentChatWorkspaceFile, type AgentChatWorkspaceTree, type AgentChatWorkspaceUpload, type ArtifactKind, type ArtifactPayload, type AskUserQuestionAnswer, type AskUserQuestionArgs, type AskUserQuestionChoice, type AskUserQuestionQuestion, type ChartArtifactSpec, type ChatComposerError, type ChatMessage, type CitationSegment, CitationText, ComposioConnectCard, type ComposioConnectCardProps, type ErrorInfo, type HtmlArtifactSpec, type InboxItem, type InboxList, InboxPanel, type InboxPanelProps, type InboxUnreadCountState, IntegrationsBand, type IntegrationsBandProps, IntegrationsPage, type IntegrationsPageProps, type MarkdownArtifactSpec, MessageResponse, type MessageResponseProps, MissionDashboard, type MissionDashboardProps, type MissionTaskBucket, MissionsPanel, type MissionsPanelProps, ResearchSourcesPanel, type RetryIndicator, type ScheduledWorkItem, type ScheduledWorkList, ScheduledWorkPanel, type ScheduledWorkPanelProps, type SessionTree, type SessionTreeNode, SessionTreePanel, type SessionTreePanelProps, type SvgArtifactSpec, type TableArtifactSpec, type TokenUsage, type ToolCallInfo, type WorkspaceEntry, type WorkspaceFile, type WorkspaceTree, type WorkspaceUpload, deriveMissionWorkerActivityLabel, groupMissionTasksByBucket, isTerminalMissionStatus, missionTaskBucket, splitCitations, useAgentChatAdapterContext, useAgentChatRuntime, useChatViewMode, useInboxUnreadCount };