Skip to main content
Glama
debugg-ai

Debugg AI MCP

Official
by debugg-ai

Delete Project

delete_project

Delete a project by UUID, permanently removing it along with its environments, credentials, and test history. No undo. Returns deletion confirmation or error if project doesn't exist.

Instructions

Delete a project by UUID. Returns {deleted:true, uuid}. DESTRUCTIVE — removes the project and its associated environments, credentials, and test history. No undo. Returns isError:true + NotFound when already deleted or uuid doesn't exist.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
uuidYesUUID of the project to delete. Required.

Implementation Reference

  • Main handler function for the delete_project tool. Creates a DebuggAIServerClient, calls deleteProject(uuid), and returns {deleted:true, uuid}. Handles 404 errors by returning isError response.
    export async function deleteProjectHandler(
      input: DeleteProjectInput,
      _context: ToolContext,
    ): Promise<ToolResponse> {
      const start = Date.now();
      logger.toolStart('delete_project', { uuid: input.uuid });
    
      try {
        const client = new DebuggAIServerClient(config.api.key);
        await client.init();
    
        try {
          await client.deleteProject(input.uuid);
          logger.toolComplete('delete_project', Date.now() - start);
          return {
            content: [{ type: 'text', text: JSON.stringify({ deleted: true, uuid: input.uuid }, null, 2) }],
          };
        } catch (err: any) {
          if (err?.statusCode === 404 || err?.response?.status === 404) return notFound(input.uuid);
          throw err;
        }
      } catch (error) {
        logger.toolError('delete_project', error as Error, Date.now() - start);
        throw handleExternalServiceError(error, 'DebuggAI', 'delete_project');
      }
    }
  • Schema for delete_project input: requires uuid (string, UUID format). Uses Zod validation.
    export const DeleteProjectInputSchema = z.object({
      uuid: z.string().uuid(),
    }).strict();
    export type DeleteProjectInput = z.infer<typeof DeleteProjectInputSchema>;
  • Tool definition registration with name 'delete_project', description, and inputSchema (uuid string with required constraint).
    export function buildDeleteProjectTool(): Tool {
      return {
        name: 'delete_project',
        title: 'Delete Project',
        description: DESCRIPTION,
        inputSchema: {
          type: 'object',
          properties: {
            uuid: { type: 'string', description: 'UUID of the project to delete. Required.' },
          },
          required: ['uuid'],
          additionalProperties: false,
        },
      };
    }
  • Validated tool builder that combines the tool definition with the Zod inputSchema and the handler function.
    export function buildValidatedDeleteProjectTool(): ValidatedTool {
      const tool = buildDeleteProjectTool();
      return { ...tool, inputSchema: DeleteProjectInputSchema, handler: deleteProjectHandler };
    }
  • Service-layer helper that performs the actual HTTP DELETE call to api/v1/projects/{uuid}/ via the transaction client.
    public async deleteProject(uuid: string): Promise<void> {
      if (!this.tx) throw new Error('Client not initialized — call init() first');
      await this.tx.delete(`api/v1/projects/${uuid}/`);
    }
Behavior5/5

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

Despite no annotations, description explicitly states destructive nature, irreversible removal of associated resources, and response on duplicate deletion or missing uuid.

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?

Two sentences, no filler. Core action, effects, and error case all front-loaded efficiently.

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

Completeness5/5

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

Covers return format on success and error, lists all affected resources, and handles edge cases. No output schema needed; description fully accounts for tool's behavior.

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 coverage is 100% with a clear description for the single parameter. The description adds no new semantics beyond what schema provides, so baseline score of 3 is appropriate.

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?

Starts with 'Delete a project by UUID' and specifies return format. Clearly distinguishes from sibling tools like delete_environment and update_project.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Warns 'DESTRUCTIVE', lists what is removed (project, environments, credentials, test history), states 'No undo', and explains error behavior when already deleted or not found.

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/debugg-ai/debugg-ai-mcp'

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