[Philip] Implement getPosts endpoint