/** * @license * Copyright 2026 Google LLC * SPDX-License-Identifier: Apache-2.0 */ export declare const FORCE_FILE_STORAGE_ENV_VAR = "GEMINI_FORCE_FILE_STORAGE"; /** * Service for interacting with OS-level secure storage (e.g. keytar). */ export declare class KeychainService { private readonly serviceName; private initializationPromise?; /** * @param serviceName Unique identifier for the app in the OS keychain. */ constructor(serviceName: string); isAvailable(): Promise; /** * Returns true if the service is using the encrypted file fallback backend. */ isUsingFileFallback(): Promise; /** * Retrieves a secret for the given account. * @throws Error if the keychain is unavailable. */ getPassword(account: string): Promise; /** * Securely stores a secret. * @throws Error if the keychain is unavailable. */ setPassword(account: string, value: string): Promise; /** * Removes a secret from the keychain. * @returns true if the secret was deleted, false otherwise. * @throws Error if the keychain is unavailable. */ deletePassword(account: string): Promise; /** * Lists all account/secret pairs stored under this service. * @throws Error if the keychain is unavailable. */ findCredentials(): Promise>; private getKeychainOrThrow; private getKeychain; private initializeKeychain; private loadKeychainModule; private isKeychainFunctional; }