import { type FC, type PropsWithChildren } from 'react';
import type { MessageConnection } from 'vscode-jsonrpc/browser';
import type { ChatExportResult } from 'cody-ai/src/jsonrpc/agent-protocol';
import { type VSCodeWrapper } from 'cody-ai/webviews/utils/VSCodeApi';
import type { InitialContext } from '../types';
interface AgentClient {
    rpc: MessageConnection;
    dispose(): void;
}
interface CodyWebChatContextData {
    client: AgentClient | Error | null;
    activeChatID: string | null;
    activeWebviewPanelID: string;
    vscodeAPI: VSCodeWrapper;
    initialContext: InitialContext | undefined;
    setLastActiveChatID: (chatID: string | null) => void;
    createChat: () => Promise<void>;
    selectChat: (chat: ChatExportResult) => Promise<void>;
}
export declare const CodyWebChatContext: import("react").Context<CodyWebChatContextData>;
interface CodyWebChatProviderProps {
    serverEndpoint: string;
    accessToken: string | null;
    chatID?: string | null;
    telemetryClientName?: string;
    initialContext?: InitialContext;
    customHeaders?: Record<string, string>;
    onNewChatCreated?: (chatId: string) => void;
}
/**
 * The root store/provider node for the Cody Web chat, creates and shares
 * agent client and maintains active web panel ID, chat history and vscodeAPI.
 */
export declare const CodyWebChatProvider: FC<PropsWithChildren<CodyWebChatProviderProps>>;
export declare function useWebAgentClient(): CodyWebChatContextData;
export {};
//# sourceMappingURL=CodyWebChatProvider.d.ts.map