export declare const SERVICE_NAME = "com.verifiedskill.desktop";
export declare const GITHUB_TOKEN_KEY = "github-oauth-token";
export declare const VSKILL_TOKEN_SERVICE = "vskill-token";
export declare const VSKILL_TOKEN_KEY = "vskill-api-token";
export interface KeyringBackend {
    setPassword(service: string, account: string, password: string): void;
    getPassword(service: string, account: string): string | null;
    deletePassword(service: string, account: string): boolean;
}
export interface FsAdapter {
    readFileSync(path: string): string;
    writeFileSync(path: string, content: string, mode: number): void;
    chmodSync(path: string, mode: number): void;
    existsSync(path: string): boolean;
    mkdirSync(path: string): void;
    unlinkSync(path: string): void;
}
export interface KeychainOptions {
    /** Optional keyring backend; defaults to a real `@napi-rs/keyring` adapter. */
    keyring?: KeyringBackend | null;
    /** Filesystem adapter (override for tests). */
    fs?: FsAdapter;
    /** Absolute path to the fallback file. Defaults to `~/.vskill/keys.env`. */
    fallbackPath?: string;
    /** Warn channel — receives one message when fallback kicks in. */
    warn?: (message: string) => void;
}
export interface Keychain {
    setGitHubToken(token: string): void;
    getGitHubToken(): string | null;
    clearGitHubToken(): boolean;
    /** 0839 US-005: store the verified-skill `vsk_*` API token. Coexists with the GitHub token. */
    setVskillToken(token: string): void;
    /** 0839 US-005: read the verified-skill `vsk_*` API token. Returns null when absent. */
    getVskillToken(): string | null;
    /** 0839 US-005: remove the verified-skill `vsk_*` token. Returns true when something was removed. */
    clearVskillToken(): boolean;
    /** True iff fallback storage is in use (introspection for `vskill auth status`). */
    usingFallback(): boolean;
}
/** Test-only — reset the migration-once flag so test factories can re-run it. */
export declare function _resetMigrationFlagForTests(): void;
export declare function createKeychain(opts?: KeychainOptions): Keychain;
export declare function getDefaultKeychain(): Keychain;
/** Test-only reset hook — never call from production code. */
export declare function _resetDefaultKeychainForTests(): void;
export declare function getGitHubToken(): string | null;
export declare function setGitHubToken(token: string): void;
export declare function clearGitHubToken(): boolean;
export declare function getVskillToken(): string | null;
export declare function setVskillToken(token: string): void;
export declare function clearVskillToken(): boolean;
/** Last-4 redaction for log-safe output. */
export declare function redactToken(token: string | null | undefined): string;
