optimize to meet requirement of max requests to api