Announcements

Help Wizard

Step 1

NEXT STEP

Can't append to playlist in developer playground

Can't append to playlist in developer playground

Ref: https://developer.spotify.com/documentation/web-api/reference/add-tracks-to-playlist

 

It is stated that omitting "position" makes this API append, but using the playground/"try it", it is impossible to omit this argument, always defaulting to 0/prepending.

Reply
3 Replies

FWIW, I have figured out that I can just press Ctrl+V in the playlist view with spotify:track: links to append them, so I could achieve my desired result in that way.

Hello! Welcome to the Spotify Community.

 

From what I've researched and tested, what you've noticed is a current limitation of the Spotify Playground. The API documentation states that omitting the position parameter causes the track to be added to the end of the playlist.

However, the Playground requires all parameters to be displayed in the interface, and when position is left blank, the Playground sends the value 0 by default, causing the track to be inserted at the beginning.

 

In practice, this doesn't happen if you use the API via code, such as with curl or Postman. Simply omit the position field, and the song will be correctly appended to the end of the playlist.

 

💡 Tip: The Playground is great for testing, but it doesn't always reflect all actual API behaviors.

 

Keep me updated so I can continue to help you!

 

Cheers,
ribezaz

ribezazSpotify Star
Help others find this answer and click "Accept as Solution".
If you appreciate my answer, maybe give me a Like.
Note: I'm not a Spotify employee.

Thanks for stating the same thing I just said, ChatGPT. I just posted it so the Spotify staff/devs could fix it.

Suggested posts

Let's introduce ourselves!

Hey there you,   Yeah, you! 😁   Welcome - we're glad you joined the Spotify Community!   While you here, let's have a fun game and get…

ModeratorStaff / Moderator/ 4 years ago  in Social & Random