Automatically retry failed requests due to expired credentials