Merge pull request #100 from jesseward/example-show-album

Fixed show_album example to retrieve album data.
This commit is contained in:
Paul Lamere 2016-12-31 11:07:10 -05:00 committed by GitHub
commit e176e9e4a8

View File

@ -1,5 +1,5 @@
# shows artist info for a URN or URL
# shows album info for a URN or URL
import spotipy
import sys
@ -8,10 +8,9 @@ import pprint
if len(sys.argv) > 1:
urn = sys.argv[1]
else:
urn = 'spotify:artist:3jOstUTkEu2JkjvRdBA5Gu'
urn = 'spotify:album:5yTx83u3qerZF7GRJu7eFk'
sp = spotipy.Spotify()
artist = sp.artist(urn)
pprint.pprint(artist)
album = sp.album(urn)
pprint.pprint(album)