linear_removeIssueLabel
Remove a label from an issue in Linear's project management system to update issue categorization and organization.
Instructions
Remove a label from an issue in Linear
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| issueId | Yes | ID or identifier of the issue to remove the label from (e.g., ABC-123) | |
| labelId | Yes | ID of the label to remove from the issue |
Implementation Reference
- The handler function that implements the core logic for the linear_removeIssueLabel tool. It validates the input arguments and delegates to the LinearService to remove the label from the issue./** * Handler for removing a label from an issue */ export function handleRemoveIssueLabel(linearService: LinearService) { return async (args: unknown) => { try { if (!isRemoveIssueLabelArgs(args)) { throw new Error("Invalid arguments for removeIssueLabel"); } return await linearService.removeIssueLabel(args.issueId, args.labelId); } catch (error) { logError("Error removing label from issue", error); throw error; } }; }
- The MCP tool definition (schema) for linear_removeIssueLabel, defining input and output schemas.export const removeIssueLabelToolDefinition: MCPToolDefinition = { name: "linear_removeIssueLabel", description: "Remove a label from an issue in Linear", input_schema: { type: "object", properties: { issueId: { type: "string", description: "ID or identifier of the issue to remove the label from (e.g., ABC-123)", }, labelId: { type: "string", description: "ID of the label to remove from the issue", }, }, required: ["issueId", "labelId"], }, output_schema: { type: "object", properties: { success: { type: "boolean" }, issueId: { type: "string" }, labelId: { type: "string" } } } };
- src/tools/handlers/index.ts:85-85 (registration)Registration of the linear_removeIssueLabel tool handler within the registerToolHandlers function.linear_removeIssueLabel: handleRemoveIssueLabel(linearService),
- src/tools/type-guards.ts:232-247 (helper)Type guard function used in the handler to validate input arguments for linear_removeIssueLabel./** * Type guard for linear_removeIssueLabel tool arguments */ export function isRemoveIssueLabelArgs(args: unknown): args is { issueId: string; labelId: string; } { return ( typeof args === "object" && args !== null && "issueId" in args && typeof (args as { issueId: string }).issueId === "string" && "labelId" in args && typeof (args as { labelId: string }).labelId === "string" ); }