share your best! is an application built by me which aims to authenticate an user and get their most listened songs, artists and playlists from Spotify! Then, it'll be able to share good taste in music on Instagram, Twitter, Facebook and other social networks!
The application hosted on Vercel https://shareyourbest.vercel.app does not work with all Spotify accounts due to Spotify API restrictions. To use the app properly, read "How to run" section below.
To run the application locally, first you'll need to clone the repository:
git clone https://github.com/rodrigoeduardo/share-your-best.git
and then:
cd share-your-best
Now, you have to install project dependencies:
yarn install
and then, you can run it:
yarn dev
But before trying to log in with Spotify in the app, you must register your application in Spotify for Developers dashboard.
Access Spotify for Developers.
After logging in with your Spotify account, a "Create an app" button will be visible:
After clicking on it, create your app name and description and agree with Spotify's Developer Terms of Service and Branding Guidelines. Then, click on "Edit settings" and add to Redirect URIs the following URI:
http://localhost:YOUR_PORT/api/auth/callback/spotify
If you want to an specific account to be able to log in, you have to add it on "Users and Access" page.
After that, go to your project and rename .env.example
file to .env.local
and fill the environmental variables with the keys in your Spotify for Developers app dashboard.
And that's it, you are ready to use!