0

I come from an electronics background, with a project whereby I'd like to be able to obtain various information about the state of the desktop player, eg

  • Current track name
  • Current track artist
  • Position in song
  • Play/pause status

Is there an active API or other method which will allow me to obtain this information and get it out of the desktop app itself, such that I might be able to send that information out via a COM port?

Thanks in advance.

1 Answers1

0

You could use my .NET Library SpotifyAPI .NET

It combines the spotify-local and spotify-web API.
Also, it provides all your required information and is simple to use. Small example:

SpotifyLocalAPIClass spotify = new SpotifyLocalAPIClass();

if(!spotify.Connect())
    return;

SpotifyMusicHandler mh = spotify.GetMusicHandler();
SpotifyEventHandler eh = spotify.GetEventHandler();

Console.WriteLine(mh.GetCurrentTrack().GetTrackName());
Jonas Dellinger
  • 1,294
  • 9
  • 19