Skip to main content
Glama

linear_archiveInitiative

Archive specific initiatives in Linear by providing the initiative ID, enabling efficient project management and organized workflows within the MCP server environment.

Instructions

Archive an initiative

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
initiativeIdYesThe ID of the initiative to archive

Implementation Reference

  • The handler function for the linear_archiveInitiative tool. Validates input using isArchiveInitiativeInput, logs the action, calls linearService.archiveInitiative(initiativeId), and returns the result.
    export function archiveInitiativeHandler(linearService: LinearService) { return async (args: unknown) => { if (!isArchiveInitiativeInput(args)) { throw new Error('Invalid input for archiveInitiative'); } console.log(`[archiveInitiative] Archiving initiative: ${args.initiativeId}`); const result = await linearService.archiveInitiative(args.initiativeId); console.log(`[archiveInitiative] Initiative archived successfully`); return result; }; }
  • The schema definition for the linear_archiveInitiative tool, specifying input (initiativeId: string) and output (success: boolean).
    name: 'linear_archiveInitiative', description: 'Archive an initiative', input_schema: { type: 'object', properties: { initiativeId: { type: 'string', description: 'The ID of the initiative to archive', }, }, required: ['initiativeId'], }, output_schema: { type: 'object', properties: { success: { type: 'boolean' }, }, }, },
  • Registration of the linear_archiveInitiative handler in the registerToolHandlers function, mapping the tool name to archiveInitiativeHandler.
    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),
  • Registration of initiative tool definitions (including linear_archiveInitiative) in the allToolDefinitions array.
    ...initiativeToolDefinitions,
  • Type guard function isArchiveInitiativeInput used by the handler to validate input arguments.
    export function isArchiveInitiativeInput(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