Skip to main content
Glama
deezer-mcp

deezer-mcp

by mihajloS

deezer-mcp

tests

An MCP server for Deezer, built with FastMCP. It lets Claude search tracks and build playlists in your Deezer library.

Status: early skeleton. The tools and their contract (inputs, outputs, tests) are in place; the Deezer calls inside them are still TODO. See Development.

Tools

Tool

Deezer API

Token

Returns

search_track(query, limit=10)

GET /search

no

list of tracks: id, title, artist, album, duration, link

create_playlist(title)

POST /user/me/playlists

yes

new playlist ID

add_tracks(playlist_id, track_ids)

POST /playlist/{id}/tracks

yes

true when Deezer confirms

Typical flow: search_track → pick track IDs → create_playlist → add_tracks.

Claude ──MCP (stdio)──► deezer-mcp (FastMCP) ──HTTPS──► api.deezer.com

Related MCP server: Spotify MCP Server

Requirements

  • uv (it installs Python 3.12+ for you)

  • For the write tools: a Deezer OAuth access token in DEEZER_TOKEN, with basic_access,manage_library,offline_access permissions (offline_access makes it non-expiring). search_track works without a token.

Getting a token needs a Deezer developer app (App ID + secret). Note that Deezer stopped accepting new apps in 2025, so this currently works only if you already have one. A small deezer-mcp login helper is planned.

Use it in Claude Code (stdio)

Straight from GitHub with uvx, no clone needed:

claude mcp add deezer -e DEEZER_TOKEN=your-token -- uvx --from git+https://github.com/mihajloS/deezer-mcp deezer-mcp

Search only (no token):

claude mcp add deezer -- uvx --from git+https://github.com/mihajloS/deezer-mcp deezer-mcp

From a local checkout, with the token kept in a git-ignored .env:

git clone https://github.com/mihajloS/deezer-mcp
cd deezer-mcp && cp .env.example .env

Put your token in .env, then:

claude mcp add deezer -- uv run --directory "$PWD" --env-file .env deezer-mcp

Check it with /mcp inside Claude Code. The same command and arguments work in any MCP client that runs stdio servers (e.g. Claude Desktop's claude_desktop_config.json).

Development

uv sync
uv run pytest
  • src/deezer_mcp/server.py – the FastMCP app and the three tools. Each tool's signature, docstring and return type are its MCP contract; the body is where the Deezer call goes.

  • tests/ – the contract, tested through a real in-memory MCP client. Deezer is faked with respx, so tests never touch the network; use httpx for HTTP calls so respx can intercept them.

  • Tests for unimplemented tool bodies are marked @todo (an xfail). xfail_strict is on, so when your implementation makes one pass, pytest reports XPASS(strict) and fails: delete that @todo line and the test becomes a regular one.

Deezer quirk worth knowing: errors come back as HTTP 200 with a body like {"error": {"type": "OAuthException", "message": "Invalid OAuth access token.", "code": 300}}, so checking the status code is not enough.

Benitoow/mcp-deezer takes a different route: Deezer's internal API with an arl cookie instead of OAuth, and many more tools.

License

MIT

Available Tools

3 tools
add_tracksAdd TracksA

Append tracks to one of the user's playlists, in the given order.

Returns True when Deezer confirms. Needs DEEZER_TOKEN.

Inputs: track_ids (required), playlist_id (required). Returns: result

create_playlistCreate PlaylistA

Create an empty playlist in the logged-in user's Deezer library.

Returns the new playlist ID (pass it to add_tracks). Needs DEEZER_TOKEN.

Inputs: title (required). Returns: result

search_trackSearch TrackA

Search Deezer for tracks. Public endpoint, no login needed.

Returns the best matches first; an empty list means nothing was found.

Inputs: query (required), limit. Returns: result

Tool Schema Changelog

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

Loading tool schema changelog…

    TDQS

    A3.9/5.0

    Scored across 3 tools

    Disambiguation5/5

    Each tool covers a distinct action on a distinct object: searching the catalog, creating a playlist, and appending tracks. There is no plausible way to confuse them, and the descriptions even cross-reference each other (playlist ID passed to add_tracks).

    Naming Consistency5/5

    All three names follow the same snake_case verb_noun pattern (search_track, create_playlist, add_tracks). The convention is predictable and readable.

    Tool Count4/5

    Three tools is on the lean side, but each is clearly load-bearing for the search -> create -> populate workflow. Nothing feels redundant or padded, though the surface is minimal.

    Completeness3/5

    The core flow is covered, but there is no way to list or inspect the user's existing playlists, remove/reorder tracks, or delete a playlist. These are notable gaps for a playlist-management server, though an agent can still accomplish the primary build-a-playlist task.

    Maintenance

    ActivityMaintained
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers