/** * @license * Copyright 2025 Steven Roussey * SPDX-License-Identifier: Apache-2.0 */ import type { CredentialPutOptions, ICredentialStore } from "./ICredentialStore"; /** * A credential store that chains multiple stores together, trying each * in order until a value is found. * * Writes always go to the first (primary) store. Reads cascade through * the chain, returning the first match. This enables layered resolution: * explicit config → encrypted store → environment variables. * * @example * ```ts * const store = new ChainedCredentialStore([ * new InMemoryCredentialStore(), // runtime overrides * new EncryptedKvCredentialStore(kv, passphrase), // persistent encrypted * new EnvCredentialStore({ ... }), // environment fallback * ]); * ``` */ export declare class ChainedCredentialStore implements ICredentialStore { private readonly stores; constructor(stores: readonly ICredentialStore[]); get(key: string): Promise; put(key: string, value: string, options?: CredentialPutOptions): Promise; delete(key: string): Promise; has(key: string): Promise; keys(): Promise; deleteAll(): Promise; } //# sourceMappingURL=ChainedCredentialStore.d.ts.map