interface StorageAdapter { get(key: string[]): Promise | undefined>; remove(key: string[]): Promise; set(key: string[], value: any, expiry?: Date): Promise; scan(prefix: string[]): AsyncIterable<[string[], any]>; } declare function joinKey(key: string[]): string; declare function splitKey(key: string): string[]; declare namespace Storage { function get(adapter: StorageAdapter, key: string[]): Promise; function set(adapter: StorageAdapter, key: string[], value: any, ttl?: number): Promise; function remove(adapter: StorageAdapter, key: string[]): Promise; function scan(adapter: StorageAdapter, key: string[]): AsyncIterable<[string[], T]>; } export { Storage, type StorageAdapter, joinKey, splitKey };