Skip to main content
Glama

remove_track_from_favorites

Remove a track from your TIDAL favorites list to unlike songs and manage your music preferences.

Instructions

Remove a track from user's favorites (unlike a track).

Args: track_id: ID of the track to remove from favorites

Returns: Success status and confirmation

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
track_idYes

Implementation Reference

  • Handler function that authenticates if needed and calls tidalapi's session.user.favorites.remove_track(track_id_int) to unlike the track, returning a structured RemoveFromFavoritesResult.
    @mcp.tool() async def remove_track_from_favorites(track_id: str) -> RemoveFromFavoritesResult: """ Remove a track from user's favorites (unlike a track). Args: track_id: ID of the track to remove from favorites Returns: Success status and confirmation """ if not await ensure_authenticated(): raise ToolError("Not authenticated. Please run the 'login' tool first.") try: track_id_int = int(track_id) await anyio.to_thread.run_sync( session.user.favorites.remove_track, track_id_int ) return RemoveFromFavoritesResult( status="success", item_id=track_id, item_type="track", message=f"Track {track_id} removed from favorites", ) except ValueError: raise ToolError(f"Invalid track ID format: {track_id}") except Exception as e: raise ToolError(f"Failed to remove track from favorites: {str(e)}")
  • Pydantic model defining the output schema for the remove_track_from_favorites tool, used as the return type annotation.
    class RemoveFromFavoritesResult(BaseModel): """Result of removing an item from favorites.""" status: str = Field(description="Operation status (success/error)") item_id: str = Field(description="ID of the item removed from favorites") item_type: str = Field(description="Type of item (track/album/artist)") message: str = Field(description="Status message")
  • FastMCP decorator that automatically registers the remove_track_from_favorites function as an MCP tool.
    @mcp.tool()

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/keenanbass1/tidal-mcp'

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