Skip to content

Backend Routes

avvazana edited this page Nov 12, 2018 · 4 revisions

HTML

  • GET/ StaticPagesController#root

API Endpoints

session

  • POST /api/session - logs in a user
  • DELETE /api/session - logs out a user

users

  • GET /api/users/:id - returns user information (profile & saved/followed items, followers & followed)
  • POST /api/users - creates user profile

songs

  • GET /api/songs - returns all songs in database
  • GET /api/songs/:songId - returns information on specific song (name, album)

albums

  • GET /api/albums - returns all albums
  • GET /api/albums/:albumId - returns specific albums information

artists

  • GET /api/artists - returns all artists
  • GET /api/artists/:artistId - returns specific artists information

playlists

  • GET /api/playlists - returns all playlists
  • GET /api/playlists/:playlistId - returns specific playlists information
  • POST /api/playlists - add new playlist
  • DELETE /api/playlists - delete a playlist

follows

  • POST /api/follows - add a follow
  • DELETE /api/follows - remove a follow
Clone this wiki locally