Refactored some, added authentication
Paginated API