Skip to content

Commit edd3f29

Browse files
authored
Getting Started Clarifications and Example Code File (#904)
* added URI link to README getting started * revised comment * added alternate module installation instruction * installation troubleshooting comment * scope clarification comment * added playlist_add_items.py to examples folder * reformatted changelog edits * Relocated added contributions to added section in Changelog * removed unnecessary library installation instruction * Clarified alternative installation instruction
1 parent 1377879 commit edd3f29

File tree

4 files changed

+26
-0
lines changed

4 files changed

+26
-0
lines changed

CHANGELOG.md

+4
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
1111

1212
### Added
1313

14+
- Add alternative module installation instruction to README
15+
- Added Comment to README - Getting Started for user to add URI to app in Spotify Developer Dashboard.
16+
- Added playlist_add_tracks.py to example folder
17+
1418
### Fixed
1519

1620
- Update contributing.md

README.md

+8
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,12 @@ Spotipy's full documentation is online at [Spotipy Documentation](http://spotipy
1414
pip install spotipy
1515
```
1616

17+
alternatively, for Windows users
18+
19+
```bash
20+
py -m pip install spotipy
21+
```
22+
1723
or upgrade
1824

1925
```bash
@@ -43,6 +49,8 @@ for idx, track in enumerate(results['tracks']['items']):
4349

4450
### With user authentication
4551

52+
A redirect URI must be added to your application at [My Dashboard](https://developer.spotify.com/dashboard/applications) to access user authenticated features.
53+
4654
```python
4755
import spotipy
4856
from spotipy.oauth2 import SpotifyOAuth

examples/playlist_add_items.py

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# Add a list of items (URI) to a playlist (URI)
2+
3+
import spotipy
4+
from spotipy.oauth2 import SpotifyOAuth
5+
6+
sp = spotipy.Spotify(auth_manager=SpotifyOAuth(client_id="YOUR_APP_CLIENT_ID",
7+
client_secret="YOUR_APP_CLIENT_SECRET",
8+
redirect_uri="YOUR_APP_REDIRECT_URI",
9+
scope="playlist-modify-private"
10+
))
11+
12+
sp.playlist_add_items('playlist_id', ['list_of_items'])
13+

examples/show_artist_top_tracks.py

+1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
# shows artist info for a URN or URL
2+
# scope is not required for this function
23

34
from spotipy.oauth2 import SpotifyClientCredentials
45
import spotipy

0 commit comments

Comments
 (0)