Add caching

Pulled out the repeated use of request and added a cache