Add Items to a Playlist
Developing
POST
/playlists/{playlist_id}/tracks
category-playlists
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://api.spotify.com/v1/playlists//tracks' \
--header 'Authorization;' \
--header 'Content-Type: application/json' \
--data-raw ''
Response Response Example
200 - Example 1
{
"error": {
"message": "string",
"status": 0
}
}
Request
Path Params
playlist_id
string
required
Query Params
position
integer
optional
position=0
; to insert the items in the third position: position=2
. If omitted, the items will be appended to the playlist. Items are added in the order they are listed in the query string or request body.uris
string
optional
uris=spotify:track:4iV5W9uYEdYUVa79Axb7Rh, spotify:track:1301WleyT98MSxVHPZCA6M, spotify:episode:512ojhOuo1ktJprKbVcKyQ
A maximum of 100 items can be added in one request. Note: it is likely that passing a large number of item URIs as a query parameter will exceed the maximum length of the request URI. When adding a large number of items, it is recommended to pass them in the request body, see below.
Header Params
Authorization
string
required
Adding items to the current user's public playlists requires authorization of the
playlist-modify-public
scope; adding items to the current user's private playlist (including collaborative playlists) requires the playlist-modify-private
scope. See Using Scopes.Content-Type
string
required
application/json
Body Params application/json
Responses
Modified at 2022-09-12 10:04:50