Skip to main content
Glama
cswkim

Discogs MCP Server

by cswkim

get_user_submissions

Fetch all submissions made by a specific Discogs user using their username.

Instructions

Retrieve a user's submissions by username

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
usernameYes

Implementation Reference

  • UserSubmissionsService class with the get() method that makes the HTTP request to fetch a user's submissions from the Discogs API at /users/{username}/submissions. Validates the response using SubmissionsResponseSchema.
    export class UserSubmissionsService extends BaseUserService {
      /**
       * Retrieve a user's submissions by username
       *
       * @param username The username of the user to get submissions for
       * @throws {DiscogsResourceNotFoundError} If the username is not found
       * @throws {DiscogsError} If there's an unexpected error
       * @returns {SubmissionResponse} The user's submissions
       */
      async get({ username }: UsernameInput): Promise<SubmissionResponse> {
        try {
          const response = await this.request<SubmissionResponse>(`/${username}/submissions`);
    
          const validatedResponse = SubmissionsResponseSchema.parse(response);
          return validatedResponse;
        } catch (error) {
          if (isDiscogsError(error)) {
            throw error;
          }
    
          throw new Error(`Failed to get user submissions: ${String(error)}`, { cause: error });
        }
      }
    }
  • Tool definition for 'get_user_submissions'. Instantiates UserSubmissionsService and calls its get() method with the username argument, returning the JSON-stringified result.
    export const getUserSubmissionsTool: Tool<FastMCPSessionAuth, typeof UsernameInputSchema> = {
      name: 'get_user_submissions',
      description: `Retrieve a user's submissions by username`,
      parameters: UsernameInputSchema,
      execute: async (args) => {
        try {
          const userSubmissionsService = new UserSubmissionsService();
          const submissions = await userSubmissionsService.get(args);
    
          return JSON.stringify(submissions);
        } catch (error) {
          throw formatDiscogsError(error);
        }
      },
    };
  • UsernameInputSchema: defines the input schema requiring a 'username' string (min length 1). Used as the parameters schema for the get_user_submissions tool.
    export const UsernameInputSchema = z.object({
      username: z.string().min(1, 'username is required'),
    });
  • SubmissionsResponseSchema: defines the shape of the submissions response using PaginatedResponseWithObjectSchema with SubmissionSchema (containing artists, labels, releases) under the 'submissions' key.
    export const SubmissionsResponseSchema = PaginatedResponseWithObjectSchema(
      SubmissionSchema,
      'submissions',
    );
  • registerUserIdentityTools function that registers the getUserSubmissionsTool (and other user identity tools) with the FastMCP server. Called from src/tools/index.ts at line 19.
    export function registerUserIdentityTools(server: FastMCP): void {
      server.addTool(getUserIdentityTool);
      server.addTool(getUserProfileTool);
      server.addTool(editUserProfileTool);
      server.addTool(getUserSubmissionsTool);
      server.addTool(getUserContributionsTool);
    }
Behavior2/5

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

With no annotations, the description must fully disclose behavioral traits, but it only states 'Retrieve' without specifying safety, rate limits, authentication needs, or expected output format. The read-only nature is implied but not explicit.

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 sentence that front-loads the action and resource. No redundant words or wasted space.

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 output schema, the description should explain what the return value represents (e.g., list of submissions, details). It does not, and it omits any mention of pagination or error scenarios, leaving the agent with incomplete context.

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

Parameters2/5

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

Schema description coverage is 0%, so the description should add meaning. It adds only 'by username', which restates the parameter name. No examples, constraints (beyond minLength already in schema), or formatting guidance are provided.

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 uses a specific verb ('Retrieve') and resource ('a user's submissions') with the required parameter ('by username'). The tool is distinct from siblings like get_user_profile or get_user_inventory, so differentiation is not necessary.

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?

No guidance is given on when to use this tool versus alternatives (e.g., get_user_contributions or search). There is no mention of prerequisites or context for optimal usage.

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/cswkim/discogs-mcp-server'

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