Update API request function to automatically convert response to model object and paginate responses