MenuDocs/erela.js-spotify

Add more info to result

HysMX opened this issue · 7 comments

HysMX commented

When requesting info to the Spotify API it also returns art cover ,author and playlist creator.

it would be nice if it gets also included on the plugin

You can't actually stream music from spotify the way you wish to via this plugin. It uses the information it gets from the spotify API to search youtube for the information therefore potentially getting a match or not on the music.

HysMX commented

Hi @Strandxo I'm not saying i want to stream the music directly from Spotify i already know it searches YouTube for the results.

But, what i need is the plugin to return the art cover and playlist creator from the playlist object the Spotify API returns

I decided against this because it's not playing from Spotify so why provide different information to whats actually being played, yes it's the same song but its not from Spotify. If you search a song on YouTube and on SoundCloud you'll get different information as they're different sources, what I might do is add some kind of external_data property to UnresolvedTrack and Track to hold some external data.

HysMX commented

Okay, but i don't want the exact art cover from all tracks from the playlist.

Only the playlist art cover

Example:
image

Lavaplayer itself doesn't even provide that for YouTube and SoundCloud, I'm just matching it.

You're more than welcome to do this yourself as Erela is designed to allow for plugins. Solaris is simply just helping with the spotify plugin but you can fork it and extend it or just make your own spotify plugin.

Here's a good example for you https://projects.solaris.codes/erelajs/guides/advanced.html#plugins

HysMX commented

Well its actually pretty simple to do since Spotify already includes it on the playlist object so i will just fork it and do it myself xd

Thanks anyways <3