About musicport
musicport is an MCP server and CLI for Spotify search, playback, and playlist operations, using a supplied access token with the Spotify Web API.
Key features
- 01Spotify search
- 02Playback controls
- 03Playlist listing and retrieval
- 04Playlist creation and track addition
- 05Saved-track listing
Use cases
- 01Search Spotify’s catalogue
- 02Control current playback
- 03Review or edit playlists
MCP support
Exposes Spotify search, playback, profile, playlist, and saved-track operations as MCP tools. It uses `SPOTIFY_ACCESS_TOKEN` directly; OAuth authorization and refresh are not included.
Configuration
Local server config is the same for every client. Copy it into your client’s MCP config file.
Tools
12Saved tool list · updated 1w ago
| Parameter | Type | Required | Description |
|---|---|---|---|
| type | string | No | Optional type of item to search for (defaults to 'track' when omitted). |
| limit | number | No | Optional maximum number of search results to return. |
| query | string | Yes | The search text to query the Spotify catalog with, sent as the q parameter. |
Details
From the project READMEmusicport
Spotify search, playback and playlists as MCP tools, talking to the Spotify Web API. musicport is a clean-room rebuild of the core surface of community Spotify MCP servers, under a new name: fresh code, no copied branding.
TOKEN-ENV ONLY. The hosted/community OAuth flow
(SPOTIFY_CLIENT_ID / SPOTIFY_CLIENT_SECRET + browser consent +
refresh) is NOT reproduced. Tools use SPOTIFY_ACCESS_TOKEN
directly as Authorization: Bearer.
Tools (core subset, 12)
search, get_current_user_profile, get_playback_state, play,
pause, next_track, previous_track, list_playlists,
get_playlist, create_playlist, add_tracks_to_playlist,
list_saved_tracks.
Not in this subset: OAuth authorization/refresh flow, track/album/artist detail reads beyond search, audio features/analysis, recommendations, shows/episodes/audiobooks, follow/unfollow artists and users, playlist cover images, playlist item removal/reorder depth, library albums/shows, devices listing and transfer playback, queue management, recently played, top items.
Setup
Obtain a Spotify access token through your own means and set it:
export SPOTIFY_ACCESS_TOKEN=BQ...
Optionally override the API base with SPOTIFY_API_BASE_URL
(default https://api.spotify.com/v1). Without the token, every
tool call fails with an error naming the missing variable:
SPOTIFY_ACCESS_TOKEN environment variable is required.
CLI
npx @reneturcios/musicport search '{"query":"hello"}'
npx @reneturcios/musicport mcp # stdio MCP server
Each tool name is a subcommand taking one JSON object argument.
MCP client config
{
"mcpServers": {
"musicport": {
"command": "npx",
"args": ["-y", "@reneturcios/musicport", "mcp"],
"env": { "SPOTIFY_ACCESS_TOKEN": "BQ..." }
}
}
}
Docker
docker run -i -e SPOTIFY_ACCESS_TOKEN ghcr.io/cloudcorprecords/musicport
Development
npm install
npm run build
npm test
License
MIT
Comments
New to MCP?
From what the protocol is to installing your first server, these answers cover most first questions.
An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.