/**
 * Extension Installation Module
 * Supports installing from npm packages, local directories, and xopc-store zips
 * Supports three-tier storage: workspace, global, bundled
 */
export interface InstallOptions {
    source: 'npm' | 'local';
    targetDir: string;
    timeoutMs?: number;
    global?: boolean;
}
export interface InstallResult {
    ok: boolean;
    extensionId?: string;
    targetDir?: string;
    origin?: 'workspace' | 'global';
    error?: string;
}
export interface ListedExtension {
    id: string;
    name?: string;
    version?: string;
    kind?: string;
    path: string;
    origin: 'workspace' | 'global' | 'bundled';
}
/** Read `id` from the shallowest xopc.extension.json in a store zip (for --force / preflight). */
export declare function peekExtensionIdFromStoreZip(buffer: Buffer): string | undefined;
/**
 * Install an extension from an xopc-store zip buffer (layout: manifest at archive root
 * or under a single top-level folder).
 */
export declare function installExtensionFromStoreZip(buffer: Buffer, extensionsDir: string): Promise<InstallResult>;
/**
 * Resolve target extensions directory based on options
 */
export declare function resolveExtensionsDir(workspaceDir: string, global?: boolean): string;
/**
 * Install extension from npm package
 */
export declare function installFromNpm(packageSpec: string, extensionsDir: string, timeoutMs?: number): Promise<InstallResult>;
/**
 * Install extension from local directory
 */
export declare function installFromLocal(localPath: string, extensionsDir: string): Promise<InstallResult>;
/**
 * Remove installed extension from all tiers
 */
export declare function removeExtension(extensionId: string, workspaceDir: string): {
    ok: boolean;
    removedFrom?: string;
    error?: string;
};
/**
 * List installed extensions from all tiers
 */
export declare function listAllExtensions(workspaceDir: string): ListedExtension[];
