Need a nudge in the right direction with msg.params

Hi

I am using the Spotify node, and having a lot of fun!

I have simple nodes - play, pause, skip working.
Now I need to use the node with some additional input parameters.
I have found the documentation at the bottom of this page: GitHub - pckhib/node-red-contrib-spotify: Node-RED node for Spotify Web API

I understand what the doc is telling me to do, and how it relates to my goals, but I lack the detailed knowledge to actually do it!

I know I need an inject node to contain the arguments and pass them to the spotify node. I know where to find the parameters in the spotify api documentation. I just don't know how to add a msg.params object, and how to format it.

I would appreciate some gap-filler.

Thanks
Brendon

You can simply add a function node and enter the code example...

// API function: getArtistAlbums
msg.params = [
    '43ZHCT0cAZBISjO8DG9PnE', /* Artist ID */
    { limit: 10, offset: 20 } /* Options */
];

Trigger it by whatever you want (an inject for example)

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