Skip to main content
Glama

superdesign_delete

Remove design files and update metadata to manage workspace organization in the Superdesign MCP Server.

Instructions

Delete a design file and update metadata

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
filenameYesName of the design file to delete
workspace_pathNoWorkspace path (defaults to current directory)

Implementation Reference

  • Zod schema definition for superdesign_delete tool input validation
    const DeleteDesignSchema = z.object({
        filename: z.string().describe("Name of the design file to delete"),
        workspace_path: z.string().optional().describe("Workspace path (defaults to current directory)")
    });
  • Tool registration in the ListToolsRequestHandler, defining name, description, and inputSchema
    {
        name: "superdesign_delete",
        description: "Delete a design file and update metadata",
        inputSchema: {
            type: "object",
            properties: {
                filename: { type: "string", description: "Name of the design file to delete" },
                workspace_path: { type: "string", description: "Workspace path (defaults to current directory)" }
            },
            required: ["filename"],
        },
    },
  • Main handler function for superdesign_delete tool. Parses args with schema, locates file in superdesign/design_iterations/, deletes it using unlinkSync, updates metadata.json by filtering out the deleted entry, returns success or error message.
    case "superdesign_delete": {
        const { filename, workspace_path } = DeleteDesignSchema.parse(args);
        try {
            const superdesignDir = getSuperdeignDirectory(workspace_path);
            const designIterationsDir = path.join(superdesignDir, 'design_iterations');
            const filePath = path.join(designIterationsDir, filename);
            if (!existsSync(filePath)) {
                return {
                    content: [{ type: "text", text: `Error: Design file ${filename} does not exist` }],
                };
            }
            // Delete the file
            unlinkSync(filePath);
            // Update metadata
            const metadata = loadMetadata(superdesignDir);
            const filteredMetadata = metadata.filter(m => m.fileName !== filename);
            saveMetadata(superdesignDir, filteredMetadata);
            return {
                content: [{ type: "text", text: `Successfully deleted ${filename}` }],
            };
        }
        catch (error) {
            return {
                content: [{ type: "text", text: `Error deleting design: ${error.message}` }],
            };
        }
    }
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 of behavioral disclosure. It states the tool deletes a file and updates metadata, but doesn't specify whether deletion is permanent or reversible, what metadata is updated, if permissions are required, or error handling. For a destructive operation with zero annotation coverage, this leaves significant gaps in understanding the tool's behavior.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, efficient sentence that conveys the core action and an additional effect. It's front-loaded with the primary purpose ('Delete a design file') and avoids unnecessary elaboration. However, it could be slightly more structured by separating the deletion and metadata update aspects for clarity.

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 tool's complexity as a destructive operation with no annotations and no output schema, the description is incomplete. It lacks details on behavioral traits (e.g., permanence of deletion, error responses), usage context, and output expectations. For a mutation tool with significant implications, more comprehensive information is needed to guide safe and effective use.

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

Parameters3/5

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

Schema description coverage is 100%, so the schema already documents both parameters ('filename' and 'workspace_path') with clear descriptions. The description doesn't add any parameter-specific details beyond what the schema provides, such as file format constraints or path examples. Baseline 3 is appropriate when the schema handles parameter documentation effectively.

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 ('Delete') and resource ('a design file'), and mentions an additional effect ('update metadata'). It distinguishes from siblings like 'superdesign_list' or 'superdesign_generate' by specifying deletion rather than listing or creation. However, it doesn't explicitly differentiate from 'superdesign_cleanup', which might also involve deletion operations.

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 provided on when to use this tool versus alternatives. The description doesn't mention prerequisites, when not to use it, or compare it to sibling tools like 'superdesign_cleanup' that might handle deletion differently. Usage context is implied but not explicitly stated.

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/jonthebeef/superdesign-mcp-claude-code'

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