Make API more resilient