Disk and memory cache for API