UNPKG

@presidio-dev/factifai-agent

Version:

An AI powered browser automation testing agent powered by LLMs.

66 lines 2.01 kB
export declare class SecretManager { private static configDir; private static _secretsPath; private static secrets; private static isInitialized; /** * Get the path to the secrets file */ static get secretsPath(): string; /** * Ensure the secret manager is initialized * This is a helper method to reduce code duplication */ private static ensureInitialized; /** * Initialize the secret manager * This sets up the secrets directory and loads existing secrets */ static initialize(): void; /** * Load secrets from disk * If no secrets file exists, creates an empty one */ private static loadSecrets; /** * Save secrets to disk */ private static saveSecrets; /** * Set a secret value * @param key Secret key * @param value Secret value * @returns true if successful, false otherwise */ static set(key: string, value: string): boolean; /** * Get a secret value * @param key Secret key * @param defaultValue Default value to return if key doesn't exist * @returns The secret value or defaultValue if not found */ static get(key: string, defaultValue?: string): string | undefined; /** * Get all secret values * @returns All secret key-value pairs */ static getAll(): Record<string, string>; /** * Check if a secret key exists * @param key Secret key * @returns true if the key exists, false otherwise */ static has(key: string): boolean; /** * Delete a secret * @param key Secret key to delete * @returns true if the secret was deleted, false if it didn't exist or deletion failed */ static delete(key: string): boolean; /** * Apply secrets to environment variables * This allows secret values to be used in the application via process.env */ static applyToEnvironment(): void; } //# sourceMappingURL=secret-manager.d.ts.map