Skip to main content
Glama
superseoworld

MCP Spotify Server

get_available_genres

Retrieve available music genres from Spotify to filter recommendations and discover new artists or tracks based on specific genre preferences.

Instructions

Get a list of available genres for recommendations

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The core implementation of the get_available_genres tool. This method in the TracksHandler class makes a request to the Spotify API endpoint '/recommendations/available-genre-seeds' to fetch available genres for recommendations.
    async getAvailableGenres() {
      return this.api.makeRequest('/recommendations/available-genre-seeds');
    }
  • src/index.ts:309-317 (registration)
    Registration of the 'get_available_genres' tool in the ListTools response. Defines the tool name, description, and input schema (no parameters required).
    {
      name: 'get_available_genres',
      description: 'Get a list of available genres for recommendations',
      inputSchema: {
        type: 'object',
        properties: {},
        required: []
      },
    },
  • Input schema definition for the get_available_genres tool, specifying an empty object with no required properties.
    inputSchema: {
      type: 'object',
      properties: {},
      required: []
    },
  • Dispatch logic in the main CallToolRequestHandler switch statement that invokes the TracksHandler's getAvailableGenres method and formats the response as JSON text.
    case 'get_available_genres': {
      const result = await this.tracksHandler.getAvailableGenres();
      return {
        content: [{ type: 'text', text: JSON.stringify(result, null, 2) }]
      };
    }
Behavior2/5

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

No annotations are provided, so the description carries the full burden. It states it 'gets a list' but doesn't disclose behavioral traits such as whether it requires authentication, rate limits, pagination, freshness of data, or error conditions. The description is minimal and lacks critical operational context for a tool in an API environment.

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 a single, clear sentence with zero waste. It's front-loaded with the core purpose and appropriately sized for a simple, parameterless tool. Every word earns its place.

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

Completeness2/5

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

Given the lack of annotations and output schema, the description is incomplete. It doesn't explain what the return value includes (e.g., genre names, IDs, counts) or behavioral aspects like authentication needs. For a tool in a music API context, more detail on output and usage context is warranted.

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

Parameters4/5

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

The input schema has 0 parameters with 100% coverage, so no parameter documentation is needed. The description doesn't add parameter details, which is appropriate here. Baseline is 4 for zero parameters, as it avoids unnecessary complexity.

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?

The description clearly states the verb 'Get' and the resource 'list of available genres for recommendations', making the purpose specific and understandable. It distinguishes from most siblings that focus on tracks, albums, artists, or playlists, though it doesn't explicitly differentiate from other potential genre-related tools (none exist in the sibling list).

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?

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention prerequisites (e.g., needing authentication), context for recommendations, or how it relates to tools like 'get_recommendations' or 'search'. Usage is implied only by the purpose statement.

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/superseoworld/mcp-spotify'

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