import { ApiClient } from '../api-client'; import type { ChatFileInfo } from '../types'; export declare const ALLOWED_EXTENSIONS: Set; export declare function getContentType(filename: string): string; export interface DownloadResult { downloadedPaths: string[]; imagePaths: string[]; failedCount: number; cleanup: () => void; } /** * S3 presigned URL 経由でファイルをダウンロードし、ローカルに保存する */ export declare function downloadChatFiles(client: ApiClient, _agentId: string, files: ChatFileInfo[], projectDir: string, conversationId: string): Promise; /** * ファイルを S3 presigned URL 経由でアップロードする */ export declare function uploadFile(client: ApiClient, filePath: string, filename: string, conversationId: string, messageId: string, projectCode: string): Promise<{ fileId: string; s3Key: string; fileSize: number; }>; /** * Returns true when the value is a non-null object with the three required string * fields that both parseChatFiles and parseConversationFiles need to validate. * Extracted to eliminate the duplicated field-presence check between the two parsers. */ export declare function hasChatFileBaseFields(item: unknown): item is { fileId: string; s3Key: string; filename: string; }; /** * ChatPayload の files フィールドをパースして ChatFileInfo[] を返す */ export declare function parseChatFiles(files: unknown): ChatFileInfo[]; /** * ChatPayload の conversationFiles フィールドをパースして ChatFileInfo[] を返す * files と異なり contentType と fileSize は任意(デフォルト値で補完) */ export declare function parseConversationFiles(files: unknown): ChatFileInfo[]; //# sourceMappingURL=file-transfer.d.ts.map