import type { BoxTokenManager } from './client.ts'; import type { ByteWindow } from '../../utils/ranges.ts'; type BoxItemType = 'file' | 'folder' | 'web_link'; export interface BoxItem { type: BoxItemType; id: string; name: string; size?: number; modified_at?: string; etag?: string; sha1?: string; parent?: { id: string; type: 'folder'; } | null; } interface BoxPathCollectionEntry { type: 'folder'; id: string; name: string; } export interface BoxSearchItem { type: BoxItemType; id: string; name: string; path_collection?: { total_count: number; entries: BoxPathCollectionEntry[]; }; } export declare function listFolderItems(tm: BoxTokenManager, folderId: string, opts?: { limit?: number; }): Promise; export declare function getFolderInfo(tm: BoxTokenManager, folderId: string): Promise; export declare function downloadFile(tm: BoxTokenManager, fileId: string, window?: ByteWindow): Promise; export declare function downloadFileStream(tm: BoxTokenManager, fileId: string): AsyncIterable; /** * Name+content search scoped to a folder subtree. Pages Box `/search` with * `ancestor_folder_ids` scoping and `content_types=name,file_content` so the * query matches file names and the server-indexed body text. Each returned * item carries `path_collection` (its ancestor chain) for mount-relative path * reconstruction. The boolean is true when the result reached the * 10,000-match ceiling (a truncated set is not a trustworthy superset). */ export declare function searchContent(tm: BoxTokenManager, query: string, ancestorFolderId: string): Promise<{ items: BoxSearchItem[]; truncated: boolean; }>; export declare function uploadNewFile(tm: BoxTokenManager, parentId: string, name: string, data: Uint8Array): Promise; export declare function uploadFileVersion(tm: BoxTokenManager, fileId: string, name: string, data: Uint8Array): Promise; export declare function createFolder(tm: BoxTokenManager, parentId: string, name: string): Promise; export declare function deleteFile(tm: BoxTokenManager, fileId: string): Promise; export declare function deleteFolder(tm: BoxTokenManager, folderId: string, recursive?: boolean): Promise; export declare function updateFile(tm: BoxTokenManager, fileId: string, opts: { name?: string; parentId?: string; }): Promise; export declare function updateFolder(tm: BoxTokenManager, folderId: string, opts: { name?: string; parentId?: string; }): Promise; export declare function copyFile(tm: BoxTokenManager, fileId: string, parentId: string, name?: string): Promise; export declare function copyFolder(tm: BoxTokenManager, folderId: string, parentId: string, name?: string): Promise; export {}; //# sourceMappingURL=api.d.ts.map