Spotify Web API SDK | ES6
SDK written in ECMAScript 6. Allows you to use (almost) all Spotify Web API endpoints.
Diagram
Simple usage
Find (by id)
Artist ;
Search all results
Artist ;
Get several items by id
Album ;
Set search parameters
//optional search modifierslet config = limit: 2 offset: 0 or: 'Rolling Stones' market: 'US';Artist ;
OAuth
; Session; let token = windowlocationhash01;if token Sessiontoken = token; else Session; User;
Entity relationship
Get proper entity, not json
Artist;
Reference
All entities
find
/*** Finds an entity by its Spotify ID.* @param* @return */Artist ;
where
/*** Starts a query with the given parameter.* @queryString * @params * @return */Artist ;
get
/*** Obtains a full (instead of simplified) object from source.*/Track ;
Artist
getTopTracks
/*** Retrieves the top-tracks for the artist. * @param* @return */artist ;
albums
/*** Initializes a conditional query for the artist's albums.* @return */artist all;
Development
git clone git@github.com:Cosmitar/spotify-client.git
npm install
gulp watch
Open the localhost:3000/demo/index.html and look for console.logs
Installation
add package.json
dependency "spotify-client": "latest"
run
npm install
;