Skip to main content
Glama
Cifero74

mcp-apple-music

get_library_playlists

Retrieve all playlists from your Apple Music library. Specify a limit to control the number of playlists returned.

Instructions

List all playlists in your Apple Music library.

Args: limit: Maximum number of playlists to return, 1–100 (default 100).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
limitNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Implementation Reference

  • The 'get_library_playlists' function is defined as an MCP tool, fetches playlists from the Apple Music API, and formats them for display.
    @mcp.tool()
    async def get_library_playlists(limit: int = 100) -> str:
        """List all playlists in your Apple Music library.
    
        Args:
            limit: Maximum number of playlists to return, 1–100 (default 100).
        """
        client = _get_client()
        data = await client.get(
            "/me/library/playlists",
            params={"limit": min(max(1, limit), 100)},
        )
        playlists = data.get("data", [])
    
        if not playlists:
            return "No playlists found in your library."
    
        lines = [f"📋 Your Playlists ({len(playlists)} found):\n"]
        for i, p in enumerate(playlists, 1):
            lines.append(_fmt_playlist(p, i))
        return "\n".join(lines)
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries the full burden of behavioral disclosure. While it identifies the scope as 'Apple Music library', it lacks crucial context: authentication requirements, whether results include collaborative/subscribed playlists, pagination behavior beyond the limit parameter, or rate limiting details.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Efficiently structured with the core purpose front-loaded in the first sentence, followed by a concise Args section. No filler text; every line serves a specific informational purpose.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Adequate for a simple retrieval tool with output schema present. The single parameter is well-documented, but the description misses behavioral context and usage guidance expected when no annotations are present to carry that load.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Excellent compensation for 0% schema description coverage. The Args section fully documents the 'limit' parameter with its purpose (maximum to return), valid range (1–100), and default value (100), adding substantial semantic value missing from the structured schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States specific verb (List), resource (playlists), and scope (Apple Music library) clearly. However, it does not explicitly distinguish from sibling 'get_playlist_tracks' (which retrieves contents) or clarify when to use this versus 'search_library'.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Provides no guidance on when to use this tool versus alternatives like 'search_library' or 'get_playlist_tracks'. No prerequisites, pagination strategy (offset/cursor), or error handling guidance is mentioned.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Cifero74/mcp-apple-music'

If you have feedback or need assistance with the MCP directory API, please join our Discord server