import type { Packument } from '@gjsify/npm-registry';
export interface CachedPackument {
    etag: string;
    packument: Packument;
}
/**
 * Read a cached packument + its ETag for `(registry, name)`. Returns `null` on
 * a miss, when the cache is disabled, or when the entry is unreadable/corrupt
 * (treated as a miss — the caller just re-fetches).
 */
export declare function getCachedPackument(registry: string, name: string): CachedPackument | null;
/**
 * Persist a packument + ETag for `(registry, name)`. Writes to a `<path>.tmp.<pid>`
 * sibling then atomically renames so a concurrent reader never sees a partial
 * write. No-op when the cache is disabled, the ETag is empty, or the write
 * fails (read-only / out-of-disk cache volume must not break the install).
 */
export declare function putCachedPackument(registry: string, name: string, etag: string, packument: Packument): void;
