Created
June 15, 2017 14:23
-
-
Save iamhunter/bb4f495f2ebf3cbee3c719b01016d616 to your computer and use it in GitHub Desktop.
Spotify Setup
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var SpotifyWebApi = require('spotify-web-api-node'); | |
var scopes = ['user-read-private', 'user-read-email', 'playlist-modify-public'], | |
redirectUri = '', | |
clientId = '', | |
state = ''; | |
var spotifyApi = new SpotifyWebApi({ | |
clientId : '', | |
clientSecret : '', | |
redirectUri : '' | |
}); | |
// Create the authorization URL | |
var authorizeURL = spotifyApi.createAuthorizeURL(scopes, state); | |
// https://accounts.spotify.com:443/authorize?client_id=5fe01282e44241328a84e7c5cc169165&response_type=code&redirect_uri=https://example.com/callback&scope=user-read-private%20user-read-email&state=some-state-of-my-choice | |
console.log(authorizeURL); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment