As a user, I can make a POST request to the endpoint /api/v1/playlists. In the body of the POST request, I must include a UNIQUE playlist title. If the POST request is successful, I see a JSON response with newly posted playlist record and a 201 status. If the user submit invalid information in the POST request body, I should receive a 400 status code and receive a JSON response error message.
See requirements below with specific requirements for request and response.
[x] Complete endpoint
[x] Record can only be created if playlist title is unique
As a user, I can make a POST request to the endpoint
/api/v1/playlists
. In the body of the POST request, I must include a UNIQUE playlist title. If the POST request is successful, I see a JSON response with newly posted playlist record and a 201 status. If the user submit invalid information in the POST request body, I should receive a 400 status code and receive a JSON response error message.See requirements below with specific requirements for request and response.
Request
Successful Response
Unsuccessful Response