An automatic playlist generator API that produces a complementary playlist given specific input field.
-
Supported endpoints:
- Target BPM (beats per minute)
- Target duration
- An existing music library (coming soon)
The API will return playlist in JSON, with tracks
, albums
, artists
listed.
-
git clone https://github.com/ZhouXing19/SpotifyDemo
to your local directory. -
Configure the
.env
file, according to format provided in.env.example
2.1. No need to change the
ACCESS_TOKEN
andREFRESH_TOKEN
field.2.2. Email me to acquire the
CLIENT_ID
andCLIENT_SECRET
;) -
Make sure you are on the root of this repository, and
npm install
-
npm run devStart
to start the server. If you see:Server Started Connected to db
Congrats, you are all set!
npm run devStart
to start the server.- In your browser, go to http://localhost:3007/, and authorize this app.
- (Current Version, will be updated) After authorization, in
http://localhost:3007/callback?code={YOUR_ACCESS_CODE}
page, fill in the input edit-text field for your target paramter. E.g., for recommendation playlist based on BPM 100, type100
in thetempo
field, and clicksubmit
.