trailpack-spotify-api
Trailpack to connect your app with the Spotify API
Install
$ npm install --save trailpack-spotify-api
Configure
// config/main.jsmoduleexports = packs: // ... other trailpacks
// config/spotify.jsmoduleexports = clientId: 'your-client-id' clientSecret: 'your-client-secret'
How to use the API
This package is a wrapper for the 'spotify-web-api-node', the functions reference is available at here.
Usage example:
// api/services/spotify.jsmoduleexports = /** * Get Elvis' albuns */ { return thisappspotifyApi }
You can also access user private information using 'trailpack-passport' with Spotify OAuth2 to authentication workflow and obtain the access token.