import { type ProjectState } from '../hooks/use-project-state';
import { type SessionState } from '../hooks/use-session-state';
import { type AssistantSession, type Principal, type PrincipalType, type Project, type ShareItem, type Work } from '../types';
type ApiClient = {
    get: (url: string, params?: any) => Promise<any>;
    post: (url: string, data?: any) => Promise<any>;
    patch: (url: string, data?: any) => Promise<any>;
    delete: (url: string) => Promise<any>;
    deleteWithBody?: (url: string, body?: unknown) => Promise<any>;
};
type TranslationFn = (key: string) => string;
export declare function fetchAgentThreads(apiClient: ApiClient, tenantAiAgentId: string, onSuccess: (threads: AssistantSession[]) => void, userId?: string | null, deploymentId?: string | null, limit?: number, offset?: number): Promise<void>;
export declare function fetchProjectThreads(apiClient: ApiClient, projectId: string, onSuccess: (projectId: string, threads: AssistantSession[]) => void): Promise<void>;
export declare function fetchProjectWorks(apiClient: ApiClient, projectId: string, onSuccess: (projectId: string, works: Work[]) => void, tenantAiAgentId?: string, userId?: string | null): Promise<void>;
export declare function fetchProjects(apiClient: ApiClient, userId: string | null, onSuccess: (projects: Project[]) => void, onProjectLoaded: (project: Project) => void, onComplete: () => void, tenantAiAgentId?: string): Promise<void>;
export declare function fetchWorks(apiClient: ApiClient, onSuccess: (works: Work[]) => void, tenantAiAgentId?: string, userId?: string | null): Promise<void>;
export declare function loadThreadMessages(apiClient: ApiClient, threadId: string, setMessages: (messages: any[]) => void): Promise<void>;
export declare function updateProject(apiClient: ApiClient, projectState: ProjectState, projectActions: {
    setSaving: (saving: boolean) => void;
    stopEditing: () => void;
}, refreshProjects: () => void, t: TranslationFn): Promise<void>;
export declare function deleteProject(apiClient: ApiClient, projectState: ProjectState, projectActions: {
    setDeleteDialogOpen: (open: boolean) => void;
    setDeleting: (deleting: boolean) => void;
}, refreshProjects: () => void, t: TranslationFn): Promise<void>;
export declare function updateSession(apiClient: ApiClient, sessionState: SessionState, sessionActions: {
    setSaving: (saving: boolean) => void;
    stopEditing: () => void;
}, refreshThreads: () => void, refreshProjectThreads: (projectId: string) => void, projectContextId: string | null, selectedProjectId: string | null, t: TranslationFn): Promise<void>;
export declare function deleteSession(apiClient: ApiClient, sessionState: SessionState, sessionActions: {
    setDeleteDialogOpen: (open: boolean) => void;
    setDeleting: (deleting: boolean) => void;
}, refreshThreads: () => void, refreshProjectThreads: (projectId: string) => void, projectContextId: string | null, selectedProjectId: string | null, t: TranslationFn): Promise<void>;
export declare function updateProjectInstructions(apiClient: ApiClient, projectState: ProjectState, projectActions: {
    setSavingInstructions: (saving: boolean) => void;
    stopEditingInstructions: () => void;
    updateProject: (project: Project) => void;
}, refreshProjects: () => void, t: TranslationFn): Promise<void>;
export declare function createThread(apiClient: ApiClient, data: {
    subject: string;
    body_text: string;
    sender_name: string;
    deploymentId?: string;
    tenantAiAgentId: string;
    projectId?: string | null;
}): Promise<{
    id: string;
    subject: string;
    created_on: string;
    last_modified_on: string;
} | null>;
export declare function uploadThreadFile(apiClient: ApiClient, threadId: string, file: File): Promise<string | null>;
export declare function createProject(apiClient: ApiClient, data: {
    name: string;
    description?: string;
    tenantAiAgentId: string;
}, onSuccess: (project: any) => void, onComplete: () => void): Promise<void>;
export declare function fetchRecordShares(apiClient: ApiClient, dataSourceId: string, recordId: string): Promise<ShareItem[]>;
export declare function fetchPrincipals(apiClient: ApiClient): Promise<Principal[]>;
export declare function addRecordShares(apiClient: ApiClient, dataSourceId: string, recordId: string, items: {
    principalType: PrincipalType;
    principalId: string | null;
}[]): Promise<boolean>;
export declare function updateRecordSharePermission(apiClient: ApiClient, dataSourceId: string, recordId: string, share: ShareItem, permissions: number): Promise<boolean>;
export declare function removeRecordShare(apiClient: ApiClient, dataSourceId: string, recordId: string, share: ShareItem): Promise<boolean>;
export {};
