Skip to main content
Glama
cswkim

Discogs MCP Server

by cswkim

create_marketplace_listing

Create a new marketplace listing on Discogs by specifying release details, condition, price, and status to sell music items.

Instructions

Create a new marketplace listing

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
release_idYes
conditionYes
sleeve_conditionNo
priceYes
commentsNo
allow_offersNo
statusYes
external_idNo
locationNo
weightNo
format_quantityNo

Implementation Reference

  • The FastMCP Tool definition and handler (execute function) for the 'create_marketplace_listing' tool. It instantiates MarketplaceService and calls createListing with the input args.
    export const createMarketplaceListingTool: Tool<FastMCPSessionAuth, typeof ListingNewParamsSchema> =
      {
        name: 'create_marketplace_listing',
        description: 'Create a new marketplace listing',
        parameters: ListingNewParamsSchema,
        execute: async (args) => {
          try {
            const marketplaceService = new MarketplaceService();
            const listing = await marketplaceService.createListing(args);
    
            return JSON.stringify(listing);
          } catch (error) {
            throw formatDiscogsError(error);
          }
        },
      };
  • Zod schema defining the input parameters for the create_marketplace_listing tool (ListingNewParamsSchema).
    export const ListingNewParamsSchema = z.object({
      release_id: z.number().int(),
      condition: ConditionSchema,
      sleeve_condition: SleeveConditionSchema.optional(),
      price: z.number(),
      comments: z.string().optional(),
      allow_offers: z.boolean().optional(),
      status: SaleStatusSchema,
      external_id: z.string().optional(),
      location: z.string().optional(),
      weight: z.number().optional(),
      format_quantity: z.number().optional(),
    });
  • Registration of the createMarketplaceListingTool via server.addTool in the registerMarketplaceTools function.
    server.addTool(createMarketplaceListingTool);
  • The MarketplaceService.createListing method, which performs the HTTP POST request to the Discogs API endpoint '/marketplace/listings' with the provided parameters, handling errors and validation.
    async createListing(params: ListingNewParams): Promise<ListingNewResponse> {
      try {
        const response = await this.request<ListingNewResponse>(`/listings`, {
          method: 'POST',
          body: params,
        });
    
        const validatedResponse = ListingNewResponseSchema.parse(response);
        return validatedResponse;
      } catch (error) {
        if (isDiscogsError(error)) {
          throw error;
        }
    
        throw new Error(`Failed to create listing: ${String(error)}`);
      }
    }
  • The registerMarketplaceTools function that registers all marketplace-related tools, including create_marketplace_listing.
    export function registerMarketplaceTools(server: FastMCP): void {
      server.addTool(getUserInventoryTool);
      server.addTool(getMarketplaceListingTool);
      server.addTool(createMarketplaceListingTool);
      server.addTool(updateMarketplaceListingTool);
      server.addTool(deleteMarketplaceListingTool);
      server.addTool(getMarketplaceOrderTool);
      server.addTool(editMarketplaceOrderTool);
      server.addTool(getMarketplaceOrdersTool);
      server.addTool(getMarketplaceOrderMessagesTool);
      server.addTool(createMarketplaceOrderMessageTool);
      server.addTool(getMarketplaceReleaseStatsTool);
    }
Behavior2/5

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

With no annotations provided, the description carries full burden for behavioral disclosure but only states the basic action. It doesn't mention authentication requirements, rate limits, whether this is a write operation (implied but not explicit), what happens on success/failure, or any side effects. For a creation tool with 11 parameters, this is insufficient.

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 extremely concise at just 4 words, front-loading the essential action and resource. There's no wasted language or unnecessary elaboration, making it efficient for quick comprehension.

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?

For a creation tool with 11 parameters, no annotations, no output schema, and 0% schema description coverage, the description is severely inadequate. It doesn't explain what a marketplace listing is in this context, what happens after creation, how to verify success, or any system constraints. The minimal description leaves too many gaps for effective tool use.

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?

With 0% schema description coverage for 11 parameters (3 with enums), the description adds no parameter information beyond what's in the schema. It doesn't explain what 'release_id' refers to, the meaning of 'condition' versus 'sleeve_condition', what 'format_quantity' represents, or any parameter relationships. The description fails to compensate for the schema's lack of descriptions.

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 action ('Create') and resource ('marketplace listing'), making the purpose immediately understandable. However, it doesn't differentiate this tool from its sibling 'update_marketplace_listing' or explain what distinguishes a 'new' listing from an updated one.

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 like 'update_marketplace_listing' or 'get_marketplace_listing'. There's no mention of prerequisites, constraints, or typical use cases for creating versus updating listings.

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