Skip to main content
Glama

delete_project

Remove a project and its associated data permanently from the MCP Server for Coroot. Specifies the project ID for deletion. Warning: This action is irreversible, so use with caution.

Instructions

Delete a project and all associated data.

WARNING: This action is irreversible and will delete all project data.

Args: project_id: Project ID

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
project_idYes

Implementation Reference

  • Core handler method in CorootClient that executes the DELETE API request to delete the specified project and handles various response scenarios.
    async def delete_project(self, project_id: str) -> dict[str, Any]: """Delete a project. Args: project_id: Project ID. Returns: Deletion status. """ response = await self._request("DELETE", f"/api/project/{project_id}") # Handle empty response (204 or empty body) if response.status_code == 204: return {"status": "deleted"} # Try to parse JSON response try: content = response.text.strip() if not content: # Empty response body with 200 status return {"status": "deleted"} data: dict[str, Any] = response.json() return data except Exception: # If parsing fails, assume success if status code is 2xx if 200 <= response.status_code < 300: return {"status": "deleted"} raise
  • MCP tool registration using @mcp.tool() decorator, which defines the tool interface and delegates to the implementation.
    @mcp.tool() async def delete_project(project_id: str) -> dict[str, Any]: """Delete a project and all associated data. WARNING: This action is irreversible and will delete all project data. Args: project_id: Project ID """ return await delete_project_impl(project_id) # type: ignore[no-any-return]
  • Helper implementation that calls the client handler, wraps the result in a standard response format, and applies error handling via decorator.
    async def delete_project_impl(project_id: str) -> dict[str, Any]: """Delete a project.""" result = await get_client().delete_project(project_id) return { "success": True, "message": f"Project {project_id} deleted successfully", "result": result, }

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/jamesbrink/mcp-coroot'

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