Skip to main content
Glama

terminate_workflow

Stop a workflow execution and mark it as terminated in the Conductor workflow engine. Provide the workflow ID and optional reason for termination.

Instructions

Terminate a workflow execution. This will stop the workflow and mark it as terminated.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
workflowIdYesThe workflow execution ID to terminate
reasonNoReason for termination

Implementation Reference

  • The handler function for the 'terminate_workflow' tool. It destructures workflowId and optional reason from input arguments, performs a DELETE request to the Conductor API endpoint `/workflow/${workflowId}` with the reason as a query parameter, and returns a success message.
    case "terminate_workflow": { const { workflowId, reason = "Terminated via MCP" } = args as any; await conductorClient.delete(`/workflow/${workflowId}`, { params: { reason }, }); return { content: [ { type: "text", text: `Workflow ${workflowId} terminated successfully. Reason: ${reason}`, }, ], }; }
  • src/index.ts:146-164 (registration)
    The tool registration in the tools array, including name, description, and input schema. This is returned by the list tools handler.
    { name: "terminate_workflow", description: "Terminate a workflow execution. This will stop the workflow and mark it as terminated.", inputSchema: { type: "object", properties: { workflowId: { type: "string", description: "The workflow execution ID to terminate", }, reason: { type: "string", description: "Reason for termination", }, }, required: ["workflowId"], }, },
  • The input schema definition for the terminate_workflow tool, specifying workflowId as required string and optional reason string.
    inputSchema: { type: "object", properties: { workflowId: { type: "string", description: "The workflow execution ID to terminate", }, reason: { type: "string", description: "Reason for termination", }, }, required: ["workflowId"], },

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/opensensor/conductor-mcp'

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