delete_workflow
Soft delete a workflow to temporarily remove it, enabling recovery if needed. Specify the workflow ID to manage workflows efficiently within the workflows-mcp server.
Instructions
Soft delete a workflow (can be recovered)
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes |
Implementation Reference
- src/index.ts:472-492 (handler)The primary handler function for the 'delete_workflow' tool. Parses the input arguments using DeleteWorkflowSchema, calls this.storage.delete(id) to perform a soft delete, and returns a success response with the workflow ID.private async deleteWorkflow(args: unknown) { const parsed = DeleteWorkflowSchema.parse(args); const success = await this.storage.delete(parsed.id); if (!success) { throw new Error(`Workflow not found: ${parsed.id}`); } return { content: [ { type: 'text', text: JSON.stringify({ success: true, workflow_id: parsed.id, message: 'Workflow deleted successfully (soft delete)', }, null, 2), }, ], }; }
- src/index.ts:61-63 (schema)Zod schema defining the input for the delete_workflow tool, requiring a workflow 'id' string.const DeleteWorkflowSchema = z.object({ id: z.string(), });
- src/index.ts:272-276 (registration)Registration of the 'delete_workflow' tool in the getTools() method, specifying name, description, and input schema.{ name: 'delete_workflow', description: 'Soft delete a workflow (can be recovered)', inputSchema: zodToJsonSchema(DeleteWorkflowSchema), },