Backend Routes - KevinNatera/Fumblr GitHub Wiki

HTML

  • GET / - StaticPagesController#root

API Endpoints

users

  • GET /api/users - returns a list of all users (for testing purposes)
  • GET /api/users/:id - returns the data of a specific user to be edited/displayed
  • POST /api/users - account creation
  • PATCH /api/users/:id - updates the data of a specific user

session

  • POST /api/session - login
  • DELETE /api/session - logout

posts

  • GET /api/posts - returns a list of all posts
  • GET /api/posts/:id - returns the data of a specific post to be edited/displayed
  • POST /api/posts - post creation
  • PATCH /api/posts/:id - updates the data of a specific post
  • DELETE /api/posts/:id - deletes a specific post

comments

  • GET /api/comments - returns a list of all comments (for testing purposes)
  • GET /api/comments/:id - returns the data of a specific comment to be displayed
  • POST /api/comments - comment creation
  • DELETE /api/comments/:id - deletes a specific comment