There is no integration or connector component between these two products. You would have to create a custom AEM service and integrate with Spotify using its Rest API - which it supports. Here are community articles on how to hook a Restful service into AEM. To hook into a third-party service - you write an CQ OSGi bundle that contains operations that can invoke the third party service. In your custom OSGI service -- you can wrap a Java API that knows how to invoke operations of the third-party service.
Option 1 :-
Creating Adobe Experience Manager bundles that invoke third party Restful web services
http://helpx.adobe.com/experience-manager/using/creating-cq-bundles-consume-web.html
http://helpx.adobe.com/experience-manager/using/integrating-livecycle-cq-applications.html
Spotify Web API :- https://developer.spotify.com/web-api/tutorial/
Create a OSGI service or Sling Servlets and write a code to send HTTP request GET/POST in it.
Example Code :-
import org.apache.commons.httpclient.HttpClient;import org.apache.commons.httpclient.methods.PostMethod;
String url = "http://www.google.com";InputStream in = null;try {HttpClient client = new HttpClient();PostMethod method = new PostMethod(url);//Add any parameter if u want to send it with Post req.method.addParameter("p", "apple");int statusCode = client.executeMethod(method);if (statusCode != -1) {in = method.getResponseBodyAsStream();}
Option 2:-
Spotify can be programmed using JAVAScript [Spotify Widgets].
Link:- https://developer.spotify.com/technologies/widgets/
We can use Java-scripting in AEM, you can achieve the needful with the same.
Link:- https://helpx.adobe.com/experience-manager/using/custom-carousel-components.html
Link:- https://docs.adobe.com/docs/en/aem/6-0/develop/sightly/use-api-in-javascript.html
I hope this would help you.
Thanks and Regards
Kautuk Sahni