update api to return a list of all posts, and return more post information when logged in