node-airplayhub
node-airplayhub copied to clipboard
Spotify Connect Integration
Hi Noel,
first of all: absolutely outstanding code! Helped me loads! Tried to integrate similar things 1,5 years ago but didn't make it that far, now I had some spare time again and looked your program up and it's exactly what I was looking for.
One question, I was planning to play Spotify on different Airplay speakers. For this purpose, I was thinking about piping the audio of Spotify directly on the same device (in my case: Raspberry) to your script and therefore multiple speakers. Was thinking about jusing Spotify Connect (https://github.com/Fornoth/spotify-connect-web) for that purpose, could you give me kindly some advice how to achieve it?
Best regards 7rncs
Any chance for an answer?
You could always try to implement this yourself, but I’m sure Spotify will start to block these reverse engineered libraries some day.
Actually was able to do it...
You just need to create a Loopback device with Alsa that sends all sound to the node.js module airtunes, specifically to one of the examples in his directory: https://github.com/lperrin/node_airtunes/blob/master/examples/play_stdin.js
Then you start spotify-connect-web and acess the spotify web api via bash. From there on I was able to integrate it with my webserver or voice control or whatever...