POST /add-artist

Adds a new artist to the data.json file.

Example URL

http://127.0.0.1:8080/add-artist

JSON body parameters

Name
Type
Description

ArtistName

string

The artist's name.

Quote

string

A quote from one of the artist's songs.

CoverImage

string

Image address of an image of the artist found on the web. (NB : Ideally a Square Image, Spotify ones are perfect.)

SpotifyUrl **

string

SpotifyUrl link to one of the artist's playlist.

Card3A

array

The albums of our artist. (NB : Each album is separated by a Comma)

Card4

array

My top songs for that artist. (NB : Each song is separated by a Comma)

Card1

string

Content for a brief description on who that artist is.

Card2

string

Content for specified artist's rising to popularity explained.

  • ** - To find the suitable Spotify Url for a playlist, follow the below steps :

    • Locate a playlist for your artist on Spotify, click into the Playlist and click the 3 dots.

    • At the bottom, you should see a share tab.

    • Hover over that and press embed playlist.

    • Once you are in embed playlist, click show code and an iframe code should pop up.

    • Extract the src part of the iframe (Without the quotation marks) and that is the Url to be inputted into the form.

Example Code

Example Response

Response Code

  • 200 OK: The artist was successfully added. The response body will contain the artist that was added.

  • 400 Bad Request : The artist is already in the database and an error message will be sent.

Response Field

Name
Type
Description

ArtistName

string

The artist's name.

Quote

string

A quote from one of the artist's songs.

CoverImage

string

Image address of the artist.

SpotifyUrl

string

SpotifyUrl link to one of the artist's playlist.

Card3A

array

The albums of our artist.

Card4

array

My top songs for that artist.

Card1

string

Content for a brief description on who that artist is.

Card2

string

Content for specified artist's rising to popularity explained.

Last updated