import type { AgentManager } from "./agent/agent-manager.js";
import type { AgentPersistenceHandle, AgentProvider, AgentSessionConfig } from "./agent/agent-sdk-types.js";
import type { AgentStorage, StoredAgentRecord } from "./agent/agent-storage.js";
interface LoggerLike {
    child(bindings: Record<string, unknown>): LoggerLike;
    error(...args: unknown[]): void;
    warn(...args: unknown[]): void;
}
type AgentStoragePersistence = Pick<AgentStorage, "applySnapshot" | "list">;
type AgentManagerStateSource = Pick<AgentManager, "subscribe">;
interface BuildSessionConfigOptions {
    validProviders?: Iterable<AgentProvider>;
}
/**
 * Attach AgentStorage persistence to an AgentManager instance so every
 * agent_state snapshot is flushed to disk.
 */
export declare function attachAgentStoragePersistence(logger: LoggerLike, agentManager: AgentManagerStateSource, storage: AgentStoragePersistence): () => void;
export declare function buildConfigOverrides(record: StoredAgentRecord): Partial<AgentSessionConfig>;
export declare function buildSessionConfig(record: StoredAgentRecord, options?: BuildSessionConfigOptions): AgentSessionConfig | null;
export declare function isStoredAgentProviderAvailable(record: StoredAgentRecord, validProviders?: Iterable<AgentProvider>): boolean;
export declare function extractTimestamps(record: StoredAgentRecord): {
    createdAt: Date;
    updatedAt: Date;
    lastUserMessageAt: Date | null;
    labels?: Record<string, string>;
};
export declare function toAgentPersistenceHandle(registeredProviders: Iterable<AgentProvider>, handle: StoredAgentRecord["persistence"]): AgentPersistenceHandle | null;
export {};
//# sourceMappingURL=persistence-hooks.d.ts.map