Place API in the right place and remove cache in the wrong place