Separated API calls into separate class