delete_issue_type
Remove an issue type from a project using its unique identifier. This tool helps streamline project management by decluttering outdated or unused issue types in the Plane MCP Server.
Instructions
Delete an issue type
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| project_id | Yes | The uuid identifier of the project containing the issue type | |
| type_id | Yes | The uuid identifier of the issue type to delete |
Implementation Reference
- src/tools/metadata.ts:105-126 (handler)Registration and inline handler implementation for the 'delete_issue_type' MCP tool. Defines the input schema using Zod, executes a DELETE request to the Plane API via makePlaneRequest helper, and returns the JSON response as text content.
server.tool( "delete_issue_type", "Delete an issue type", { project_id: z.string().describe("The uuid identifier of the project containing the issue type"), type_id: z.string().describe("The uuid identifier of the issue type to delete"), }, async ({ project_id, type_id }) => { const response = await makePlaneRequest( "DELETE", `workspaces/${process.env.PLANE_WORKSPACE_SLUG}/projects/${project_id}/issue-types/${type_id}/` ); return { content: [ { type: "text", text: JSON.stringify(response, null, 2), }, ], }; } ); - src/common/request-helper.ts:3-36 (helper)Shared helper function makePlaneRequest that performs authenticated HTTP requests to the Plane API using axios. Used by the delete_issue_type handler to execute the DELETE operation.
export async function makePlaneRequest<T>(method: string, path: string, body: any = null): Promise<T> { const hostUrl = process.env.PLANE_API_HOST_URL || "https://api.plane.so/"; const host = hostUrl.endsWith("/") ? hostUrl : `${hostUrl}/`; const url = `${host}api/v1/${path}`; const headers: Record<string, string> = { "X-API-Key": process.env.PLANE_API_KEY || "", }; // Only add Content-Type for non-GET requests if (method.toUpperCase() !== "GET") { headers["Content-Type"] = "application/json"; } try { const config: AxiosRequestConfig = { url, method, headers, }; // Only include body for non-GET requests if (method.toUpperCase() !== "GET" && body !== null) { config.data = body; } const response = await axios(config); return response.data; } catch (error) { if (axios.isAxiosError(error)) { throw new Error(`Request failed: ${error.message}`); } throw error; } } - src/tools/index.ts:14-14 (registration)Top-level registration call that invokes registerMetadataTools, which in turn registers the delete_issue_type tool among others.
registerMetadataTools(server);