Skip to main content
Glama
davehenke

rekordbox-mcp

get_tracks_by_key

Find tracks in a specific musical key from your rekordbox DJ database. Use this tool to retrieve tracks matching a key like '5A' or '12B' for music organization and set planning.

Instructions

Get all tracks in a specific musical key.

Args: key: Musical key (e.g., "5A", "12B")

Returns: List of tracks in the specified key

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
keyYes

Implementation Reference

  • The primary handler function for the 'get_tracks_by_key' MCP tool, decorated with @mcp.tool() for automatic registration in the FastMCP server. It validates the database connection, constructs SearchOptions with the key filter (limit 1000), queries the RekordboxDatabase for matching tracks, and returns a list of serialized track dictionaries.
    @mcp.tool()
    async def get_tracks_by_key(key: str) -> List[Dict[str, Any]]:
        """
        Get all tracks in a specific musical key.
        
        Args:
            key: Musical key (e.g., "5A", "12B")
            
        Returns:
            List of tracks in the specified key
        """
        if not db:
            raise RuntimeError("Database not initialized.")
        
        search_options = SearchOptions(key=key, limit=1000)
        tracks = await db.search_tracks(search_options)
        return [track.model_dump() for track in tracks]

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/davehenke/rekordbox-mcp'

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