Questions tagged [libspotify]

The libspotify C API package allows third-party developers to write applications that utilize the Spotify music streaming service.

Libspotify
The libspotify C API package allows third-party developers to write applications that utilize the Spotify music streaming service. Hopefully, this will enable and inspire you to build some really cool stuff. We’re looking forward to seeing what you can come up with.

Documentation
The API documentation is available online. The libspotify distribution also contains the documentation, as well as a few code examples. There is also an FAQ available.

Application keys
Please login with your Spotify Premium account to apply for an application key.

Download
Libspotify is available for Windows, Mac OS X (x86 / x86_64), iOS, and Linux (x86 / x86_64 / ARM).

Download the file and unpack it with your favourite extractor. On the command line for most Linux distributions, you can use tar xzf libspotify-*.tar.gz to extract it. You will now have a directory called something starting with libspotify-. Inside, you should find a README worth at least skimming through.

User experience guidelines
The following guidelines have been carefully developed to provide our users with a familiar and friendly experience across all platforms, and to maintain the Spotify look & feel that we all know and love. Please ensure that your application follows them closely.

Branding
See the Terms of Use on how to use these logotypes.

Branding in graphical user interfaces

Terms of Use
We need to protect users, content providers, the Spotify trade marks and our software and service while at the same time enabling you to create applications. We therefore require you to comply with some basic rules. You should also note our trade mark guidelines.

Furthermore we want to let you know that the use of our APIs under these terms is for non-commercial use only: they are not intended to allow you to sell any software or devices based on these APIs. If you would like to make use of Spotify in a commercial way, then please contact our Partner team before you engage in any work.

Region-specific Terms of Use can be found here:

Third party licenses
Several fantastic pieces of free and open-source software have really helped get Spotify to where it is today. A few require that we include their license agreements within our product. Consider it done. As we enjoy giving credit where it's due, we included the entire list below. This means you can not only see which software we've been using, but the terms of the licenses too. A big thanks from all of us at Spotify to the smart people behind the fantastic programs listed. Rock on!

218 questions
0
votes
1 answer

How can I get song metadata without using playUri using the Android SDK?

I want to get song metadata from a URI without starting to play/buffer that song. The only way I can see of doing it right now is calling playUri() and then getMetadata() but I don't want to play it immediately. Is there any other way? Thanks! Edit:…
Aaron
  • 21
  • 4
0
votes
1 answer

sp_session_process_events causes Access Violation after calling sp_session_login

This is a very strange problem that I have been trying to figure out for days now. The strange thing about it is that is only does this for certain user accounts. This is a Windows app and I used the Jukebox sample as a starting point. I make a…
Tommyg
  • 1
  • 3
0
votes
0 answers

How to render Spotify PCM stream on Windows

Currently I am trying to use the libspotify lib to write a Windows Spotify Player. I'm new to audio streaming but not to video streaming. I have the basics working for most of the user data and track info but the problem I'm having is that I can't…
Tommyg
  • 1
  • 3
0
votes
1 answer

Unable to generate an application key

When I browse to Libspotify's application keys page, I'm asked to login. I do (with a premium account), and I'm tossed through a loop back to that first screen asking me to login again. I need an application key (spotify_appkey.key) to get started,…
lanewinfield
  • 183
  • 1
  • 1
  • 8
0
votes
1 answer

How do I access Spotify API from my Unity Android App?

Nowadays I have a Unity App that runs in Android and it has some background music that is inside the project. Now I need to change that, and get the music from Spotify using their API. Any clues on how to do that? Thanks in advance! :)
0
votes
1 answer

Spotify API crashing because of Library issue

I had been working with the SpotifyAPI for a long time, but randomly it just started to crash on me whenever it trys to load the player. Here is the error I get 12-22 20:20:01.995 28130-28130/com.skyrealm.brockyy.spotifyapi E/AndroidRuntime:…
Rockyfish
  • 339
  • 3
  • 15
0
votes
1 answer

Spotify Android SDK Searching for track number

I am currently connected to the Spotify sdk and I am currently looking to be able to have a user search for a track and it will return the track number. I have followed the sdk guides to track a song and I get the response as a JSON response, but…
Rockyfish
  • 339
  • 3
  • 15
0
votes
1 answer

libspotify register device for remote control

Firstly, what I would like to achieve. I am building media system using Raspberry Pi device. So far there is mopidy service which as far as I know uses libspotify to play music from Spotify. Everything works really well. Except I would like to…
insanebits
  • 818
  • 1
  • 6
  • 24
0
votes
1 answer

Linking against external library with CMake

I'm currently at a bit of a loss when trying to use the Libspotify SDK in my CMake project. CMakeLists.txt: cmake_minimum_required(VERSION 3.2) project(spotti) set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH}…
DenverCoder21
  • 879
  • 3
  • 16
  • 34
0
votes
1 answer

Simultaneous output from libspotify

I'm curious if it's possible to use libspotify to play multiple files at once, through different outputs. I want to be able to play one song through speakers and jump around through other songs on headphones when djing. Does anyone know if this is…
agd
  • 99
  • 8
0
votes
1 answer

LibSpotify login with oAuth Token

I built a web app that (among other things) provides access to your Spotify library. For that I am already obtaining a Spotify oAuth token which works fine with their Web API. My app will also allow you to stream your music to another device while…
Daniel
  • 2,087
  • 3
  • 23
  • 37
0
votes
1 answer

libSpotify-based client slow, but Spotify's own client fast

I've run into some weird issues with libSpotify. It seems that any libSpotify-based client will take ages to process requests (sometimes 20 seconds for a simple search, seconds for loading one single image, etc..) sent to Spotify servers, whereas…
user3756504
  • 127
  • 6
0
votes
1 answer

AccessViolationException on sp_session_player_load()

I'm trying to create a stream application based on Spotify's libspotify SDK. To achieve this in C# I'm using the ohLibspotify bindings and wrapper. This is only a thin abstraction layer so most of it will be a 1:1 mapping to the libspotify SDK. To…
Feanaro
  • 922
  • 3
  • 19
  • 35
0
votes
1 answer

ohLibspotify not calling any callback after login

I'm trying to create a project where I use the ohLibspotify .Net libspotify wrapper to login to spotify and stream playlists. As far as I can see I've set everything up the same way like in the example. First create a session like…
Feanaro
  • 922
  • 3
  • 19
  • 35
0
votes
2 answers

Playing WriteableBufferingSource speeds up after 5 sec

I am playing a PCM RAW format, and the first 5 seconds of the music it play right, but after that, it plays twice as fast Here what I have done: I have a player class with a event handler, that when the program receives a byte from a location, it…
TLPNull
  • 475
  • 4
  • 12