Skip to main content
Glama

n8n_delete_workflow

Permanently delete a workflow from the n8n automation platform. This action cannot be undone, so use it to remove unwanted or obsolete workflows.

Instructions

Permanently delete a workflow. This action cannot be undone.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idYesThe workflow ID to delete

Implementation Reference

  • The handler function that implements the n8n_delete_workflow tool. It extracts the workflow ID from arguments, validates it, calls the N8nApiClient's deleteWorkflow method, and returns a success response.
    n8n_delete_workflow: async ( client: N8nApiClient, args: Record<string, unknown> ): Promise<ToolResult> => { const id = args.id as string; if (!id) { throw new Error('Workflow ID is required'); } await client.deleteWorkflow(id); return { content: [ { type: 'text' as const, text: JSON.stringify({ success: true, message: `Workflow ${id} deleted successfully`, }, null, 2), }, ], }; },
  • The tool definition including name, description, and input schema for validating the 'id' parameter.
    { name: 'n8n_delete_workflow', description: 'Permanently delete a workflow. This action cannot be undone.', inputSchema: { type: 'object', properties: { id: { type: 'string', description: 'The workflow ID to delete', }, }, required: ['id'], }, },
  • src/server.ts:122-125 (registration)
    The registration/dispatch logic in the MCP server that routes tool calls matching workflowToolHandlers (including n8n_delete_workflow) to the appropriate handler function.
    if (name in workflowToolHandlers) { const handler = workflowToolHandlers[name as keyof typeof workflowToolHandlers]; return handler(client, args); }

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/alicankiraz1/cursor-n8n-builder'

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