search_artists
Search Spotify for artists by name, genre, or keywords to discover new music, find specific performers, or explore talent for playlists and collaborations.
Instructions
Search for artists using names, genres, or keywords to discover new music and talent.
π― USE CASES: β’ Finding artists when you only remember partial names β’ Discovering artists within specific genres or styles β’ Locating emerging or independent artists β’ Building diverse playlists with multiple artists β’ Researching artists for events or collaborations
π WHAT IT RETURNS: β’ Ranked artist results based on search relevance β’ Artist names, images, and genre classifications β’ Popularity scores and follower counts β’ Links to explore each artist's catalog β’ External URLs and social media links
π EXAMPLES: β’ "Search for 'jazz pianist' artists" β’ "Find artists named 'John'" β’ "Look for 'indie rock' bands" β’ "Search for artists from 'Nashville'" β’ "Find 'female rapper' artists"
π‘ SEARCH STRATEGIES: β’ Use genre keywords: "progressive metal", "folk acoustic" β’ Include location: "Seattle grunge", "Detroit techno" β’ Try instrument-specific searches: "saxophone", "violin" β’ Use descriptive terms: "soulful", "experimental", "classical"
β οΈ REQUIREMENTS: β’ Valid Spotify access token β’ Meaningful search keywords for best results
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| token | Yes | Spotify access token for authentication | |
| query | Yes | Search query for artists (artist name, keywords) | |
| limit | No |
Implementation Reference
- src/spotify.ts:415-426 (handler)Core handler function that executes the Spotify API search for artists using the /search endpoint with type='artist'.async searchArtists( token: string, query: string, limit: number = 20 ): Promise<SearchResult> { const params = { q: query, type: "artist", limit: Math.min(limit, 50), }; return await this.makeRequest<SearchResult>("search", token, params); }
- src/mcp/tools/artists.ts:141-184 (registration)MCP tool definition and registration for 'search_artists', including title, description, input schema using commonSchemas, and handler wrapper that calls SpotifyService.searchArtists.search_artists: { title: "Search Artists", description: `Search for artists using names, genres, or keywords to discover new music and talent. π― USE CASES: β’ Finding artists when you only remember partial names β’ Discovering artists within specific genres or styles β’ Locating emerging or independent artists β’ Building diverse playlists with multiple artists β’ Researching artists for events or collaborations π WHAT IT RETURNS: β’ Ranked artist results based on search relevance β’ Artist names, images, and genre classifications β’ Popularity scores and follower counts β’ Links to explore each artist's catalog β’ External URLs and social media links π EXAMPLES: β’ "Search for 'jazz pianist' artists" β’ "Find artists named 'John'" β’ "Look for 'indie rock' bands" β’ "Search for artists from 'Nashville'" β’ "Find 'female rapper' artists" π‘ SEARCH STRATEGIES: β’ Use genre keywords: "progressive metal", "folk acoustic" β’ Include location: "Seattle grunge", "Detroit techno" β’ Try instrument-specific searches: "saxophone", "violin" β’ Use descriptive terms: "soulful", "experimental", "classical" β οΈ REQUIREMENTS: β’ Valid Spotify access token β’ Meaningful search keywords for best results`, schema: createSchema({ token: commonSchemas.token(), query: commonSchemas.searchQuery("artists (artist name, keywords)"), limit: commonSchemas.limit(1, 50, 20), }), handler: async (args: any, spotifyService: SpotifyService) => { const { token, query, limit = 20 } = args; return await spotifyService.searchArtists(token, query, limit); }, },
- src/mcp/tools/index.ts:25-25 (registration)Aggregates artistTools (containing search_artists) into allTools registry used by ToolRegistrar for MCP tool exposure....artistTools,
- src/mcp/tools/artists.ts:175-179 (schema)Input schema definition for search_artists tool using createSchema from common schemas.schema: createSchema({ token: commonSchemas.token(), query: commonSchemas.searchQuery("artists (artist name, keywords)"), limit: commonSchemas.limit(1, 50, 20), }),