import type { StorageProvider } from '../types/index.js';
/**
 * Resolve a storage key/filename to an absolute path confined within `basePath`.
 * Defense-in-depth against path traversal: rejects null bytes and any key that
 * resolves outside the storage root (e.g. "../../etc/passwd"). Use this for EVERY
 * local-disk operation that joins a (potentially client-influenced) filename.
 * @throws Error if the key is invalid or escapes basePath.
 */
export declare function resolveStorageKey(basePath: string, key: string): string;
declare class StorageService {
    private providers;
    constructor();
    initialize(): void;
    initializeProvider(service: string): void;
    initializeLocalStorage(service: string, upperService: string): void;
    initializeS3Storage(service: string, upperService: string): void;
    getProvider(service: string): StorageProvider;
    saveFile(service: string, filePath: string, fileContent: Buffer | Uint8Array): Promise<string>;
    getFile(service: string, filePath: string): Promise<any>;
    deleteFile(service: string, filePath: string): Promise<void>;
    getPublicUrl(service: string, filePath: string): Promise<string>;
}
declare global {
    var __baasix_storageService: StorageService | undefined;
}
declare const storageService: StorageService;
export default storageService;
//# sourceMappingURL=StorageService.d.ts.map