export declare const SETUP_VERSION = 1; export declare const CONFIG_VERSION = 1; export type SetupStepKey = "gcp_project" | "apis_enabled" | "oauth_client" | "credentials_saved" | "consent_screen" | "test_user_added" | "tokens_obtained"; export interface SetupStep { done: boolean; at?: string; [key: string]: unknown; } export interface SetupState { version: number; auth_mode: "byo"; steps: Record; published?: { confirmed_at: string; }; last_action?: string; resume_hint?: string; } export interface UserConfig { version: number; default_account?: string; } declare const SETUP_STEP_ORDER: SetupStepKey[]; export declare function configDir(): string; export declare function setupStatePath(): string; export declare function credentialsPath(): string; export declare function userConfigPath(): string; export declare function accountsDir(): string; export declare function accountDir(email: string): string; export declare function tokensPathForAccount(email: string): string; export declare function profilePathForAccount(email: string): string; /** * Cache of remote per-account API preferences (currently the Calendar * `weekStart` setting). Deliberately NOT profile.json: the auth flow rewrites * that file wholesale from the id_token, which would clobber anything cached * alongside it on every re-login. */ export declare function settingsPathForAccount(email: string): string; export declare function normalizeEmail(email: string): string; export declare function defaultSetupState(): SetupState; export declare function readSetupState(): SetupState; export declare function writeSetupState(state: SetupState): void; export declare function setupProgress(state: SetupState): { done: number; total: number; nextStep: SetupStepKey | null; }; export declare function defaultUserConfig(): UserConfig; export declare function readUserConfig(): UserConfig; export declare function writeUserConfig(cfg: UserConfig): void; export declare function listAccounts(): string[]; export declare function hasAccount(email: string): boolean; export declare function removeAccount(email: string): void; export declare function getDefaultAccount(): string | undefined; export declare function setDefaultAccount(email: string): void; export { SETUP_STEP_ORDER };