-
Notifications
You must be signed in to change notification settings - Fork 4
PostPlaylist
Walter Lara edited this page Mar 24, 2023
·
2 revisions
Allows to add a new Playlist.
URL: /v1/playlists
Method: POST
Path Parameters: None
Query Parameters: None
Headers:
Authorization: Bearer {accessToken}
Content-Type: application/json
Content:
Field | Type | Description | Requirement Type |
---|---|---|---|
name | string | Playlist name. | Required |
Content example:
{
"name": "The Weeknd - Top 10"
}
Code: 200 OK
Headers:
Content-Type: application/json
Content:
Field | Type | Description | Condition |
---|---|---|---|
playlistId | string | UUID of the added Playlist. | Always |
Content example:
{
"playlistId": "7bd2862f-8deb-4814-8943-156d9dab80dd"
}
Code: 400 BAD REQUEST
Condition: If a mandatory content field is missing.
Headers:
Content-Type: application/json
Content example:
{
"code": 400,
"description": "Bad Request",
"cause": "missing name"
}
Code: 401 UNAUTHORIZED
Condition: If {accessToken}
is invalid or expired.