/** * Credential file loader. * * Reads credentials written by the Falcon CLI's `neubird login` command. * Schema matches Falcon's internal/config/credentials.go (ace_creds, access_token, * raven_url, expires_at). Path resolution matches Falcon's internal/config/dir.go: * XDG_CONFIG_HOME (if set) or $HOME/.config, then /neubird/neubird.json * — with profile variants at /neubird/neubird-.json. */ export interface CredentialFile { /** Decoded from ace_creds when present. */ email?: string; /** Decoded from ace_creds when present. */ password?: string; /** Raw JWT from the file's access_token field. */ accessToken?: string; /** From the file's raven_url field. */ baseUrl?: string; /** From the file's expires_at field (unix seconds). */ expiresAt?: number; /** Absolute path of the file that was read. */ path: string; } /** * Resolve the NeuBird config directory. * * Mirrors Falcon's internal/config/dir.go so this server finds the file * `neubird login` writes on every platform: * - Windows: %APPDATA%\neubird\ (Go's os.UserConfigDir()) * - Unix: $XDG_CONFIG_HOME/neubird/ or $HOME/.config/neubird/ * * Returns null if no home/appdata directory can be determined. */ export declare function configDir(): string | null; /** * Resolve the credential file path for the given profile, falling back to the * unnamed (default) profile file if a profile-specific file does not exist. * Returns null if no file is found or the config directory is unknown. */ export declare function resolveCredentialPath(profile?: string): string | null; /** * Load and parse the credentials file. * * Throws when a file exists but cannot be parsed — the caller should surface * this rather than silently falling back, since a corrupted file almost * certainly needs human attention. * * Returns null when no file is found (expected case on first run). */ export declare function loadCredentialFile(profile?: string): CredentialFile | null;