Skip to content

RubenLWF/spotify-api-proxy

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Spotify API Proxy

This is a serverless API proxy deployed on Vercel to handle Spotify API calls made from my personal website

Setup

  1. Install dependencies:

    npm install
  2. Set up environment variables in Vercel dashboard:

    • SPOTIFY_CLIENT_ID
    • SPOTIFY_CLIENT_SECRET
    • SPOTIFY_REFRESH_TOKEN

Endpoints

  • POST /api/token - Get Spotify access token
  • GET /api/currently-playing - Get currently playing track (requires Authorization header)

Deploy to Vercel

  1. Push this code to a GitHub repository
  2. Connect the repository to Vercel
  3. Add environment variables in Vercel dashboard
  4. Deploy!

Local Development

npm run dev

About

A serverless API proxy that handles Spotify API calls, deployed on Vercel.

Resources

Stars

Watchers

Forks