Routes - timmyjing/facespace GitHub Wiki
-
/signupuser creation page -
/loginlogin form -
/home page with news feed, requires login, redirected to single signup/login page unless signed in -
/users/iduser profile, possibly might add string as URL
-
/api/usersGET returns users for user search -
/api/usersPOST create a new user -
/api/users/idSHOW returns an individual users public information in order to populate a user profile
-
/api/posts/GET returns posts involving current user (post by self or to or by friends) -
/api/posts/idSHOW returns individual post by id -
/api/posts/idDELETE deletes post if made or received by current user -
/api/posts/idPATCH edits post content
-
/api/sessionPOST create a new login -
/api/sessionDELETE logout
-
/api/comments/POST create new comment -
/api/comments/idDELETE destroy comment -
/api/comments/idPATCH edit comment
-
/api/likes/POST create like -
/api/likes/idDELETE delete like
-
/api/friend_requests/POST create new friend request -
/api/friend_requests/idPATCH accept friend request -
/api/friend_requests/idDELETE reject friend request
Note: not sure whether to nest under api namespacing or not with friend requests
-
/friendship/POST creates new friendship between two people -
/friendship/idDELETE destroy friendship