import type { SpawnExtra, SpawnOptions } from './spawn';
import { spawn } from './spawn';
export interface DlxBinaryOptions {
    /** URL to download the binary from. */
    url: string;
    /** Optional name for the cached binary (defaults to URL hash). */
    name?: string | undefined;
    /** Expected checksum (sha256) for verification. */
    checksum?: string | undefined;
    /** Cache TTL in milliseconds (default: 7 days). */
    cacheTtl?: number | undefined;
    /** Force re-download even if cached. */
    force?: boolean | undefined;
    /** Additional spawn options. */
    spawnOptions?: SpawnOptions | undefined;
}
export interface DlxBinaryResult {
    /** Path to the cached binary. */
    binaryPath: string;
    /** Whether the binary was newly downloaded. */
    downloaded: boolean;
    /** The spawn promise for the running process. */
    spawnPromise: ReturnType<typeof spawn>;
}
/**
 * Clean expired entries from the DLX cache.
 */
export declare function cleanDlxCache(maxAge?: number): Promise<number>;
/**
 * Download and execute a binary from a URL with caching.
 */
export declare function dlxBinary(args: readonly string[] | string[], options?: DlxBinaryOptions | undefined, spawnExtra?: SpawnExtra | undefined): Promise<DlxBinaryResult>;
/**
 * Get the DLX binary cache directory path.
 * Returns normalized path for cross-platform compatibility.
 * Uses same directory as dlx-package for unified DLX storage.
 */
export declare function getDlxCachePath(): string;
/**
 * Get information about cached binaries.
 */
export declare function listDlxCache(): Promise<Array<{
    age: number;
    arch: string;
    checksum: string;
    name: string;
    platform: string;
    size: number;
    url: string;
}>>;
