skip to content

Music Assistant

An agent for music, for requests such as “play some jazz in the kitchen”.

MCP server github.com/devjourney/music-assistant-mcp
Transport Streamable HTTP
Authentication none

music-assistant-mcp is published as a Python package, not as an image; in Compose, the official image of uv runs it with uvx, at a fixed version, beside the server of Ambrogio:

services:
music-assistant-mcp:
image: ghcr.io/astral-sh/uv:0.13.10-python3.13-trixie-slim
command: ["uvx", "music-assistant-mcp@0.3.0"]
environment:
MA_MCP_TRANSPORT: streamable-http
MA_MCP_HOST: 0.0.0.0
MA_MCP_PORT: "8668"
MA_SERVER_URL: http://<music-assistant-host>:8095
MA_TOKEN: ${MUSIC_ASSISTANT_TOKEN:?}

It serves Streamable HTTP on port 8668 at /mcp, so the server of Ambrogio reaches it at http://music-assistant-mcp:8668/mcp, the name of its Compose service on a network the two share; from another host, use the name or address of the host that runs it, with the same port and path. The path /mcp is not written in its README, and its port is the one of MA_MCP_PORT, 8668 here.

MA_TOKEN is how the MCP server signs in to Music Assistant: a long-lived access token, created in your profile of Music Assistant. The MCP server waits until Music Assistant answers. It asks Ambrogio for no token: keep its port inside the network of Compose or of the home.

  1. Run the MCP server, as Run the MCP server shows.

  2. Add the agent file agents/music-assistant.json, with the address of the Streamable HTTP endpoint of the MCP server in mcp.url:

    {
    "description": "Answers the household's requests about music, with the tools of Music Assistant.",
    "instructions": "You handle the household's requests about music with the tools of Music Assistant. Requests may come from speech recognition and contain misheard words; interpret them in context. Answer briefly.",
    "llm": {
    "provider": "mistral",
    "model": "mistral-medium-latest",
    "apiKeyEnv": "MISTRAL_API_KEY"
    },
    "maxToolCalls": 4,
    "mcp": {
    "url": "http://music-assistant-mcp:8668/mcp"
    }
    }
  3. Restart with docker compose up -d.

Authentication: none: the MCP server asks for no token, so the agent file has no mcp.auth. The description, the instructions, the language model and maxToolCalls are an example: adapt them to the household. See Agents for every field of the file.