Skip to main content
Glama

linear_deleteInitiative

Remove an initiative from the Linear project management system by moving it to the trash. Requires the initiative ID to execute the deletion process.

Instructions

Delete an initiative (move to trash)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
initiativeIdYesThe ID of the initiative to delete

Implementation Reference

  • The core handler function for the 'linear_deleteInitiative' tool. It validates the input arguments using the type guard 'isDeleteInitiativeInput', logs the action, calls 'linearService.deleteInitiative(initiativeId)', and returns the result.
    export function deleteInitiativeHandler(linearService: LinearService) { return async (args: unknown) => { if (!isDeleteInitiativeInput(args)) { throw new Error('Invalid input for deleteInitiative'); } console.log(`[deleteInitiative] Deleting initiative: ${args.initiativeId}`); const result = await linearService.deleteInitiative(args.initiativeId); console.log(`[deleteInitiative] Initiative deleted successfully`); return result; }; }
  • The MCP tool definition including name, description, input schema (requires 'initiativeId' string), and output schema (boolean success).
    { name: 'linear_deleteInitiative', description: 'Delete an initiative (move to trash)', input_schema: { type: 'object', properties: { initiativeId: { type: 'string', description: 'The ID of the initiative to delete', }, }, required: ['initiativeId'], }, output_schema: { type: 'object', properties: { success: { type: 'boolean' }, }, }, },
  • Registration of the 'linear_deleteInitiative' handler (line 97) within the 'registerToolHandlers' function that maps tool names to their handler functions.
    // Initiative Management tools linear_getInitiatives: getInitiativesHandler(linearService), linear_getInitiativeById: getInitiativeByIdHandler(linearService), linear_createInitiative: createInitiativeHandler(linearService), linear_updateInitiative: updateInitiativeHandler(linearService), linear_archiveInitiative: archiveInitiativeHandler(linearService), linear_unarchiveInitiative: unarchiveInitiativeHandler(linearService), linear_deleteInitiative: deleteInitiativeHandler(linearService), linear_getInitiativeProjects: getInitiativeProjectsHandler(linearService), linear_addProjectToInitiative: addProjectToInitiativeHandler(linearService), linear_removeProjectFromInitiative: removeProjectFromInitiativeHandler(linearService),
  • Type guard function 'isDeleteInitiativeInput' used in the handler to validate input arguments, ensuring 'initiativeId' is a string.
    export function isDeleteInitiativeInput(args: unknown): args is { initiativeId: string; } { return ( typeof args === 'object' && args !== null && 'initiativeId' in args && typeof (args as { initiativeId: string }).initiativeId === 'string' ); }

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/tacticlaunch/mcp-linear'

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