Skip to main content
Glama
zas

MusicBrainz MCP Server

by zas

browse_entities

Browse MusicBrainz entities linked to another entity with paging. Get complete discographies, all releases on a label, or other related collections.

Instructions

Browse MusicBrainz entities linked to another entity, with paging. Useful for getting complete discographies, all releases on a label, etc.

Common combinations:

  • release-groups by artist: full discography

  • releases by release_group: all editions of an album

  • releases by label: label's catalog

  • recordings by artist: all recorded tracks

Args: entity_type: What to list (releases, recordings, release-groups, artists, labels, works, events, places) linked_type: The entity you're browsing by (artist, label, recording, release, release_group, work, area, collection) linked_id: MBID of the linked entity limit: Results per page (max 100) offset: Paging offset

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
entity_typeYes
linked_typeYes
linked_idYes
limitNo
offsetNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Implementation Reference

  • The handler function `browse_entities` that executes the tool logic for browsing MusicBrainz entities.
    def browse_entities(
        entity_type: str,
        linked_type: str,
        linked_id: str,
        limit: int = 25,
        offset: int = 0,
    ) -> str:
        """
        Browse MusicBrainz entities linked to another entity, with paging.
        Useful for getting complete discographies, all releases on a label, etc.
    
        Common combinations:
        - release-groups by artist: full discography
        - releases by release_group: all editions of an album
        - releases by label: label's catalog
        - recordings by artist: all recorded tracks
    
        Args:
            entity_type: What to list (releases, recordings, release-groups,
                         artists, labels, works, events, places)
            linked_type: The entity you're browsing by (artist, label,
                         recording, release, release_group, work, area, collection)
            linked_id: MBID of the linked entity
            limit: Results per page (max 100)
            offset: Paging offset
        """
        if entity_type not in BROWSE_FUNCS:
            return (
                f"Invalid entity type '{entity_type}'. "
                f"Choose from: {', '.join(BROWSE_FUNCS)}"
            )
        # Normalize hyphenated linked_type to underscore for musicbrainzngs kwargs
        normalized = linked_type.replace("-", "_")
        valid_for_entity = VALID_BROWSE_COMBINATIONS.get(entity_type, set())
        if normalized not in valid_for_entity:
            return (
                f"Invalid linked type '{linked_type}' for {entity_type}. "
                f"Valid linked types: {', '.join(sorted(valid_for_entity))}"
            )
    
        result = BROWSE_FUNCS[entity_type](
            **{normalized: linked_id, "limit": min(limit, 100), "offset": offset}
        )
        singular = entity_type.rstrip("s")
        list_key = f"{singular}-list"
        count_key = f"{singular}-count"
        items = result.get(list_key, [])
        count = result.get(count_key, len(items))
        lines = [f"Showing {len(items)} of {count} {entity_type} (offset {offset}):"]
        for i in items:
            name = i.get("title") or i.get("name", "?")
            date = i.get("first-release-date") or i.get("date", "")
            rtype = i.get("type") or i.get("primary-type", "")
            extra = " | ".join(filter(None, [date, rtype]))
            extra_str = f" ({extra})" if extra else ""
            lines.append(f"- {name}{extra_str} | {singular} ID: {i['id']}")
        return "\n".join(lines)
Behavior4/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. It effectively describes key behaviors: paging support (implied by 'with paging' and offset/limit parameters), use cases (e.g., 'getting complete discographies'), and constraints (e.g., 'max 100' for limit). However, it lacks details on error handling, rate limits, or authentication needs, which are relevant for a tool with no annotations.

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?

The description is well-structured and front-loaded, starting with the core purpose, followed by usage examples and detailed parameter explanations. Every sentence adds value without redundancy, making it efficient and easy to parse for an AI agent.

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

Completeness5/5

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

For a tool with 5 parameters, 0% schema coverage, no annotations, but an output schema, the description is complete. It covers purpose, usage, parameters, and constraints, and since an output schema exists, it doesn't need to explain return values. This provides sufficient context for effective tool selection and invocation.

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?

Given 0% schema description coverage, the description compensates fully by explaining all parameters in the 'Args' section. It clarifies the meaning of entity_type, linked_type, linked_id, limit, and offset, including examples and constraints (e.g., 'max 100' for limit), adding significant value beyond the bare schema.

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

Purpose5/5

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

The description clearly states the tool's purpose: 'Browse MusicBrainz entities linked to another entity, with paging.' It specifies the verb (browse), resource (MusicBrainz entities), and key constraint (linked to another entity), distinguishing it from sibling tools like search_entities or get_artist_discography by focusing on linked relationships rather than searches or direct details.

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

Usage Guidelines5/5

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

The description provides explicit usage guidance with 'Common combinations' listing specific scenarios (e.g., 'release-groups by artist: full discography'), which helps differentiate when to use this tool versus alternatives like get_artist_discography or search_entities. It implicitly suggests this tool is for browsing linked entities rather than standalone searches or details.

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/zas/mcp-musicbrainz'

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