Help needed to test Spotify plugin with Oauth

Hey skikirkwood. Thanks for your work on this oauth version!

I was also a bit frustrated with this limit of 50 songs in the playlist, and had a look at it. For some reason I even had trouble putting the offset setting into the getPlaylistTracks() of of the spotify-web-api-node call in index.js. This didn’t even do anything.

So I downloaded the latest version of spotify-web-api-node and tried to manual create the playlist.json in /data/playlist.json using this script. The resulting json looks fine, but for some reason volumio does not load it. There seems to be something wrong with spop.

Maybe you see what’s wrong. I suspect you need to call something for spop as well? And maybe this script inspires you for a real fix in volumio. This more or less brute force downloads the entire playlist. I’ve tried this with playlists of 1500 songs, that seemed fine and still quite quick. But maybe some people have really huge playlists.

I despair!!! Does not work from France. Maybe it’s a customs duty problem !? :confused:

Hi Feeback25, write here more info. What is wrong? What web browser do you use? What OS do you use? Can you ping this IP address? Page is HTTP, maybe your web browser wants HTTPS…

Hi xlisec,
Thanks for help
In my workplace, I tried with Windows 10 Pro Edition and Chrome, Edge, Internet Explorer, Brave
Windows Server 2012 R2 and Chrome, Firefox, Internet Explorer
At Home, I tried with Windows 10 Family Edition with Chrome, Edge, Brave

For example : answer with Chrome: “This site is inaccessible
54. 86. 86. 144. 136 took too long to answer.
Perform a Google search on 144 136 8888.
ERR_CONNECTION_TIMED_OUT
View the saved copy”

I have access to the Google cache but after click on “Log in with Spotify” same answer and no cache access.

After tried to ping : "Microsoft Windows host[version 10. 0. 17134. 285]
(c) 2018 Microsoft Corporation. All rights reserved.

C:\Windows\system32>ping 54. 86. 144. 136:8888/
The Ping request could not find the host 54. 86. 144. 136:8888/. Check the name and try again."

I can try with a small PC with Fedora 28 and tell you the rest…

Thank you for your patience…
Feeback25

Hi there, the ping command doesn’t accept protocols or port numbers - just domain names or IP addresses. So can you try

ping 54.86.144.136

You should see something like this:

macbookpro-jimambras:~ altamontstudios$ ping 54.86.144.136
PING 54.86.144.136 (54.86.144.136): 56 data bytes
Request timeout for icmp_seq 0
Request timeout for icmp_seq 1
Request timeout for icmp_seq 2
Request timeout for icmp_seq 3
Request timeout for icmp_seq 4
Request timeout for icmp_seq 5

You can also try this, which should give you the HTML source of the page:

curl -s 54.86.144.136:8888

Hi skikirkwood,

Here is the result of the commands you propose

C:\Windows\system32>ping 54.86.144.136

Envoi d’une requête ‘Ping’ 54.86.144.136 avec 32 octets de données :
Délai d’attente de la demande dépassé.
Délai d’attente de la demande dépassé.
Délai d’attente de la demande dépassé.
Délai d’attente de la demande dépassé.

Statistiques Ping pour 54.86.144.136:
Paquets : envoyés = 4, reçus = 0, perdus = 4 (perte 100%),

C:\Windows\system32>curl -s 54.86.144.136:8888

C:\Windows\system32>

I don’t know what else to do ?
Thanks for your help

Feeback25, You’re welcome!
It’s look like France or your internet provider bloks Amazon Web Services. It’s only my opinion. Try use VPN. You can use VPN extension into Chrome like “Betternet Unlimited Free VPN Proxy”. When you connect via VPN, check it on page ipinfo.io. After that try 54.86.144.136:8888

Hi,
Thank you xlisec, you are a genius !!! You’re right, it’s the French cultural exception :unamused:
I’m progressing, i can take the first steps:

  • access to 54. 86. 144. 136:8888/
  • obtaining oAuth tokens from Spotify

Then I feel like I’m really new at it.
I save and modify the “index.js” file with Windows notepad, but I don’t know if this is the right procedure?
I know how to connect to Volumio in ssh.
I execute the first commands without difficulty.
On the other hand, the scp command is a problem for me:
when I try I get the answer : connection timed out.
I’m not sure of my PC address (I also tried with the IP address : same answer), and I’m not sure how to write the path : F:\user\Documents\index.js or /F/user/Documents/index.js
I’m afraid to do something stupid :blush:
Thank you very much
Feeback25

Hi Feeback25,

If you don’t feel comfortable with scp command, just copy the index.js file on a usb stick, plug it to your system, then connect to volumio with ssh and run a cp command, like “cp index.js /data/plugins/music_service/spop/index.js” (assuming you run the command from the directory on your usb drive).

I often do so for changing config files, as I am not a linux expert.

I hope it helps

Hi all,
just for the record:
Today i followed the steps given on page 1 and it worked like a charm on Volumio Version 2.457 fresh install on RPi3.

It would be nice if there was a hint after plugin installation such as:
“If want to use your personal playlist follow the steps given here (followed by link to this thread)”

or maybe a button inside the plugin settings that raises a popup with a message.

Anyway: Good work!

Followed the steps on page 1 and can’t get my playlists to appear, but at least my saved songs show up. Partial win?

On that note - any progress on getting over the 100 track limit?

Hey skikirkwood, the plugin is working fine :wink:

Will you also add the Radio feature in the plugin?
I find it quite useful and use it on daily basis.

Hi There, unfortunately, there is no easy way to add the Radio feature to the plugin. There is a Spotify Web API call that returns a list of tracks based on various criteria such as seed artists, tracks and genres. This could be used to build a radio-like functionality, but it would be a non-trivial amount of work.

My deepest gratitude for the magnificent work you have done. Works like a charm.
Best regards from Argentina

Hey skikirkwood - I managed to add radio support to the Spotify connect daemon - based on librespot. We (balbuze and me) are testing it out before releasing it into the wild :wink: Gotta try and reverse engineer the dailymix feature now.

That’s great news! I’ve been really busy with my day job so haven’t had any time to help out on Volumio for the past 2 months.

I love the dailymix feature, wish you luck getting that baby working!

Good evening, everyone, and thank you for your support,

@edwin69: I tried different solutions and ended up with a small software for Windows (WinSCP) that made my job easier.

@skikirkwood: I’m progressing. I get my playlists, only 20 out of about 35. I can listen to them. No lists of titles, artists, albums, recommendations, recent plays.

Do you need more information ?

I feel like I’m four months behind you !? :blush:

Can you post a screenshot of the home page of the Spotify plugin on from your Volumio system.

For those who say its not working

Take a look at the indes.js file ‘after’ you bring it over or update it…make sure everything is pristine as it should be.

I copied mine over but it didn’t work. After I looked at it I noticed that for some reason the line looked like this ’ < < A…[token]’

Meaning it had a couple of rogue characters before my token. I removed the rogue characters and made sure the token was correct, saved and rebooted…everything is not fine…

Works :smiley: