Skip to main content
Glama

Spotify MCP

Stateless Spotify MCP server over Streamable HTTP. It exposes the requested tools and uses an OAuth 2.1 broker flow:

MCP client / CLYE -> /oauth/authorize -> Spotify -> /oauth/spotify/callback
                   -> MCP client callback -> /oauth/token -> /mcp

No OAuth sessions, codes, refresh tokens, or user data are persisted by this server. OAuth artifacts are short-lived AES-256-GCM sealed values derived from MCP_STATE_SECRET; Spotify refresh tokens remain inside encrypted MCP refresh tokens held by the MCP client. PKCE is mandatory and redirect URIs are checked exactly against the stateless signed client registration.

Configuration

Copy .env.example to the deployment's secret/environment configuration. The CLYE callback is:

MCP_CLIENT_REDIRECT_URI=https://chat.z-code.ai/api/mcp/oauth/callback

That URL is the MCP client's callback and must not be used as Spotify's own callback. In the Spotify Developer Dashboard register the server URL from SPOTIFY_REDIRECT_URI, for example:

https://spotify-mcp.example.com/oauth/spotify/callback

SPOTIFY_CLIENT_SECRET and MCP_STATE_SECRET must be injected by the runtime secret manager and must never be committed, logged, or placed in a catalog file.

Related MCP server: Spotify MCP

Run

npm install
npm run build
npm start

The MCP endpoint is PUBLIC_URL/mcp. OAuth discovery is available at /.well-known/oauth-protected-resource/mcp and /.well-known/oauth-authorization-server.

spotify_delete_playlist intentionally unfollows a playlist: Spotify does not provide a playlist-delete Web API endpoint.

spotify_set_playlist_cover_image accepts a public HTTPS image URL and converts, resizes, and compresses it internally to a Spotify-compatible JPEG of at most 256 KB before uploading. Source images may be up to 10 MB. For compatibility, the tool also accepts a data:image/*;base64,... value via image_base64.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      B
      quality
      D
      maintenance
      An MCP server that enables users to control Spotify playback, search music, and manage playlists through natural conversation. It is updated for the February 2026 Spotify Web API changes and supports full playlist CRUD operations.
      6
      8
      MIT
    • F
      license
      Not graded
      quality
      D
      maintenance
      Enables remote interaction with Spotify through the Model Context Protocol, allowing users to search tracks, control playback, and manage playlists with per-user OAuth authentication. It is hosted on Cloudflare Workers and supports remote MCP over HTTP for compatible clients.
      2
      -
    • A
      license
      Not graded
      quality
      F
      maintenance
      An MCP server that enables users to control Spotify playback, search for music, and manage playlists through MCP-compatible clients. It supports features like track recommendations and playback management using secure OAuth authentication.
      MIT
    • A
      license
      Not graded
      quality
      D
      maintenance
      Enables LLM clients to control Spotify and access user data through the Spotify Web API, including search, playback, playlists, and listening history. Each caller supplies their own credentials per request, so one instance can serve many users without storing any credentials.
      MIT