import React from "react";
import type { AdvancedTab } from "../../utils/data/advanced-tab";
export interface Message {
    id: string;
    role: "user" | "assistant" | "system";
    content: string;
    timestamp: string;
    url?: string;
    fileType?: string;
    contentType?: string;
    visible?: boolean;
}
export type SendMessageOptions = {
    visible?: boolean;
};
export interface UseChatProps {
    wsUrl: string;
    wsToken: string;
    flowConfig: {
        name: string;
        tenant: string;
        username: string;
        pathway: string;
    };
    sessionId: string;
    stopGenerationWsUrl: string;
    activeTab: AdvancedTab;
    enableHaptics?: boolean;
    hapticFeedback?: {
        impactAsync: (style: any) => Promise<void>;
    };
    store?: {
        sendMessage?: (text: string) => Promise<void>;
    };
    WebSocketImpl?: typeof WebSocket;
    errorHandler?: (error: string) => void;
}
export interface UseChatReturn {
    messages: Message[];
    isTyping: boolean;
    sendMessage: (text: string, options?: SendMessageOptions) => Promise<void>;
    currentStreamingMessage: {
        id: string | null;
        content: string;
    };
    ws: React.MutableRefObject<WebSocket | null>;
    isConnected: React.MutableRefObject<boolean>;
    messageQueue: React.MutableRefObject<any[]>;
    stopGenerating: () => void;
    streaming: boolean;
    setMessages: (messages: Message[]) => void;
}
export declare const useChat: ({ wsUrl, wsToken, flowConfig, sessionId, stopGenerationWsUrl, activeTab, enableHaptics, hapticFeedback, store, errorHandler, WebSocketImpl, }: UseChatProps) => UseChatReturn;
