remove_issues_from_sprint
Remove specific issues from a GitHub project sprint using targeted issue IDs and sprint ID. Simplifies sprint management by enabling quick adjustments to task priorities and workflows.
Instructions
Remove issues from a sprint
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| issueIds | Yes | ||
| sprintId | Yes |
Implementation Reference
- Core handler method that removes specified issues from a sprint by calling the sprint repository's removeIssue method in a loop.async removeIssuesFromSprint(data: { sprintId: string; issueIds: string[]; }): Promise<{ success: boolean; removedIssues: number; message: string }> { try { let removedCount = 0; const issues = []; // Remove each issue from the sprint for (const issueId of data.issueIds) { try { await this.sprintRepo.removeIssue(data.sprintId, issueId); removedCount++; issues.push(issueId); } catch (error) { process.stderr.write(`Failed to remove issue ${issueId} from sprint: ${error}`); } } return { success: removedCount > 0, removedIssues: removedCount, message: `Removed ${removedCount} issue(s) from sprint ${data.sprintId}` }; } catch (error) { throw this.mapErrorToMCPError(error); } }
- Zod schema defining input validation for the tool: requires sprintId (string) and issueIds (non-empty array of strings).export const removeIssuesFromSprintSchema = z.object({ sprintId: z.string().min(1, "Sprint ID is required"), issueIds: z.array(z.string()).min(1, "At least one issue ID is required"), }); export type RemoveIssuesFromSprintArgs = z.infer<typeof removeIssuesFromSprintSchema>;
- src/infrastructure/tools/ToolSchemas.ts:1966-1980 (registration)ToolDefinition export including name, description, schema reference, and example usage. Imported and registered by ToolRegistry.export const removeIssuesFromSprintTool: ToolDefinition<RemoveIssuesFromSprintArgs> = { name: "remove_issues_from_sprint", description: "Remove issues from a sprint", schema: removeIssuesFromSprintSchema as unknown as ToolSchema<RemoveIssuesFromSprintArgs>, examples: [ { name: "Remove issues from sprint", description: "Remove issues that are no longer in scope for the sprint", args: { sprintId: "sprint_1", issueIds: ["124", "125"] } } ] };
- src/infrastructure/tools/ToolRegistry.ts:239-239 (registration)Registers the removeIssuesFromSprintTool in the central ToolRegistry singleton during initialization.this.registerTool(removeIssuesFromSprintTool);
- src/index.ts:380-381 (registration)MCP server dispatch switch case that routes tool calls to the ProjectManagementService handler.case "remove_issues_from_sprint": return await this.service.removeIssuesFromSprint(args);