/** Names of the four object stores */ declare const STORE_WIDGET = "widgetCache"; declare const STORE_LATEST = "latestWidgetCache"; declare const STORE_RECENT = "recentWidgetCache"; declare const STORE_QUERY = "queryCache"; /** * Opens (or returns the already-opened) cache database. * * The database name includes the API base URL and application identifier so that * different environments/applications each get their own isolated cache store, * matching the naming convention used by the main database in indexeddb.ts. * * @returns Promise resolving to the IDBDatabase instance */ export declare function openCacheDatabase(): Promise; /** * Retrieves a single record from the specified store by key. * * @param storeName - The object store to read from * @param key - The key to look up (number for widget stores, string for queryCache) * @returns The stored value, or null if not found */ export declare function cacheGet(storeName: string, key: IDBValidKey): Promise; /** * Writes a record to the specified store (insert or update). * * For stores with in-line keys (widget stores), the key is read from the object's * "id" field. For the queryCache store (out-of-line keys), pass the key explicitly. * * @param storeName - The object store to write to * @param value - The value to store * @param key - Optional explicit key (required for queryCache which has no keyPath) */ export declare function cachePut(storeName: string, value: any, key?: IDBValidKey): Promise; /** * Deletes a single record from the specified store by key. * * @param storeName - The object store to delete from * @param key - The key of the record to delete */ export declare function cacheDelete(storeName: string, key: IDBValidKey): Promise; /** * Clears ALL records from the specified store. * * @param storeName - The object store to clear */ export declare function cacheClear(storeName: string): Promise; /** * Retrieves ALL records from the specified store. * Used during init() to load persisted cache data into memory. * * @param storeName - The object store to read from * @returns Array of all stored records */ export declare function cacheGetAll(storeName: string): Promise; /** Export store name constants so callers don't need magic strings */ export { STORE_WIDGET, STORE_LATEST, STORE_RECENT, STORE_QUERY };