better handling of failed api calls; reduce caching time