/**
 * credentials-file — Per-user JSON store for Amplitude project API keys.
 *
 * Lives at `~/.amplitude/wizard/credentials.json` (override the cache root
 * via `AMPLITUDE_WIZARD_CACHE_DIR`). Mode `0o600`. Keyed by a stable hash
 * of the project's install directory so multiple projects on one machine
 * stay isolated.
 *
 * ── Why not the OS keychain? ───────────────────────────────────────────
 * The previous implementation used `security` (macOS) and `secret-tool`
 * (Linux). It was written with `-T ''` (empty trusted-application list),
 * intending to suppress prompts. In practice an empty ACL means "no app
 * is on the allow-list," so every read triggered a "wizard wants to use
 * your keychain" dialog. Users are prompted on EVERY launch because
 * `credential-resolution.ts` reads the API key during startup.
 *
 * The Amplitude project API key is not a confidential credential — it
 * is a public ingestion key embedded in every Amplitude-instrumented
 * client SDK bundle (web JS, mobile binaries). The OAuth tokens already
 * sit in `~/.ampli.json` as a plain `0o600` file, and they are strictly
 * more sensitive than this. So a per-user file at `0o600` is the right
 * sensitivity match and aligns with how `gh`, `aws`, `vercel`, `doppler`,
 * `supabase` store their secrets.
 *
 * ── Schema ─────────────────────────────────────────────────────────────
 * {
 *   "version": 1,
 *   "projects": {
 *     "<sha256(installDir).slice(0,12)>": {
 *       "apiKey": "<amplitude api key>",
 *       "updatedAt": "<ISO 8601 timestamp>"
 *     }
 *   }
 * }
 *
 * Forward-compat: unknown top-level keys and unknown keys inside a project
 * entry are preserved on write so a future wizard version can add fields
 * without older versions stomping them.
 */
/** Read the API key for an install directory. Returns null on miss. */
export declare function readCredential(installDir: string): string | null;
/**
 * Persist the API key for an install directory. Creates the cache root
 * directory if needed. Throws on write failure — callers should catch
 * and fall back to `.env.local`.
 */
export declare function writeCredential(installDir: string, apiKey: string): void;
/**
 * Remove the entry for an install directory. No-op if the file or entry
 * doesn't exist. Never throws — logout should always succeed even if
 * the credentials file is corrupted or unwritable.
 */
export declare function clearCredential(installDir: string): void;
