# Node-red-contrib-spotify - add track to user library problem

**URL:** <https://discourse.nodered.org/t/node-red-contrib-spotify-add-track-to-user-library-problem/22486>\
**Category:** General\
**Created:** [2 March 2020 08:56 UTC](https://discourse.nodered.org/t/node-red-contrib-spotify-add-track-to-user-library-problem/22486 "2020-03-02T08:56:50Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![jk4b2](https://avatars.discourse-cdn.com/v4/letter/j/3d9bf3/32.png) [@jk4b2](https://discourse.nodered.org/u/jk4b2)\
**Post date:** [2 March 2020 08:56 UTC](https://discourse.nodered.org/t/node-red-contrib-spotify-add-track-to-user-library-problem/22486/1 "2020-03-02T08:56:50Z")

</div>

Hi I am trying unsucessfully add currently played song to user's library using node-red-contrib-spotify and API: addtomysavedtracks. I am passing the params like this:

```auto
var idsy = global.get("song_id")

msg.params = [idsy]
return msg;

```

obtaining in msg.params the array of ids of the songs that I want to add to library. In this case it is always one song with one id passed. The response from the spotify is:

> error: "WebapiError: Bad Request"

I already tried other options of passing parameter but with no luck. Anybody succeeded?

---

<div class="post-metadata">

**Author:** ![pajeroid](https://avatars.discourse-cdn.com/v4/letter/p/e47c2d/32.png) [@pajeroid](https://discourse.nodered.org/u/pajeroid)\
**Post date:** [31 March 2020 10:31 UTC](https://discourse.nodered.org/t/node-red-contrib-spotify-add-track-to-user-library-problem/22486/2 "2020-03-31T10:31:02Z")

</div>

I am also getting the same error trying to use the transferMyPlayback node. I am passing the device ID as a string in an array (I think). I wouldn't mind working on this together. When you place a debug node for the msg.params what do you see?

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)\
**Post date:** [30 May 2020 10:31 UTC](https://discourse.nodered.org/t/node-red-contrib-spotify-add-track-to-user-library-problem/22486/3 "2020-05-30T10:31:09Z")

</div>

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.
