/**
 * user-config.ts — the CLI's user-global ("prefs") config tier.
 *
 * A machine-managed JSON file at an OS-correct location that sits between
 * project config and built-in defaults in the resolution cascade
 * (flag > env > project > user > default). Prefs-only: it never holds
 * secrets. See docs/design-docs/cli-user-config-tier.md.
 */
import { z } from "zod";
/**
 * Resolve the user-config directory. `AILF_CONFIG_DIR` (absolute or
 * cwd-relative, resolved to absolute) overrides everything — the CI/test
 * escape hatch. Otherwise `env-paths` gives the OS-correct location;
 * `{ suffix: "" }` drops env-paths' default `-nodejs` suffix so the path is
 * `~/.config/ailf`, not `~/.config/ailf-nodejs`.
 */
export declare function resolveUserConfigDir(): string;
/** Absolute path to the user config file. */
export declare function userConfigFilePath(): string;
/**
 * Prefs-only user-tier config. A deliberate structural subset of `RepoConfig`'s
 * `owner`/`execution` shapes so it merges into the same resolution cascade
 * without casts. Authored independently of the schema (D0045): the schema below
 * asserts `satisfies z.ZodType<UserConfig>` against it.
 */
export interface UserConfig {
    owner?: {
        team?: string;
        individual?: string;
    };
    execution?: {
        apiUrl?: string;
    };
}
export declare const UserConfigSchema: z.ZodObject<{
    owner: z.ZodOptional<z.ZodObject<{
        team: z.ZodOptional<z.ZodString>;
        individual: z.ZodOptional<z.ZodString>;
    }, z.core.$strict>>;
    execution: z.ZodOptional<z.ZodObject<{
        apiUrl: z.ZodOptional<z.ZodString>;
    }, z.core.$strict>>;
}, z.core.$strict>;
/**
 * Read + parse + validate the user config. Returns null when the file is
 * absent, and warns + returns null on malformed/invalid content (graceful
 * degradation, mirroring `loadRepoConfig`). Never throws on a bad file — a
 * run must not be blocked by user-tier corruption.
 */
export declare function loadUserConfig(filePath?: string): Promise<UserConfig | null>;
/** The only keys `ailf config set`/`unset` accept. Drives validation + `list`. */
export declare const SETTABLE_KEYS: readonly ["owner.team", "owner.individual", "execution.apiUrl"];
export type SettableKey = (typeof SETTABLE_KEYS)[number];
/** Read the effective value of a whitelisted key from a loaded config. */
export declare function getUserConfigValue(config: UserConfig | null, key: SettableKey): string | undefined;
/** Set one whitelisted key, validate the whole config, write atomically. */
export declare function setUserConfigKey(key: SettableKey, value: string, filePath?: string): void;
/** Remove one whitelisted key, write atomically. */
export declare function unsetUserConfigKey(key: SettableKey, filePath?: string): void;
