get_workflow_details
Retrieve workflow details including required input schema to understand job requirements before execution in the Opus automation platform.
Instructions
Get workflow details including jobPayloadSchema that defines required inputs for a workflow
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| workflowId | Yes | The ID of the workflow to retrieve details for |
Implementation Reference
- src/index.ts:244-258 (handler)The main handler function for the get_workflow_details tool. It extracts the workflowId from arguments, makes a GET request to the Opus API endpoint `/workflow/${workflowId}`, and returns the response data as a formatted JSON text content block.private async getWorkflowDetails(args: any) { const { workflowId } = args; const response = await this.axiosInstance.get( `/workflow/${workflowId}` ); return { content: [ { type: "text", text: JSON.stringify(response.data, null, 2), }, ], }; }
- src/index.ts:119-128 (schema)The input schema definition for the get_workflow_details tool, specifying that a workflowId string is required.inputSchema: { type: "object", properties: { workflowId: { type: "string", description: "The ID of the workflow to retrieve details for", }, }, required: ["workflowId"], },
- src/index.ts:115-129 (registration)The tool registration object for get_workflow_details in the getTools() method, which lists all available tools for the MCP server. Includes name, description, and input schema.{ name: "get_workflow_details", description: "Get workflow details including jobPayloadSchema that defines required inputs for a workflow", inputSchema: { type: "object", properties: { workflowId: { type: "string", description: "The ID of the workflow to retrieve details for", }, }, required: ["workflowId"], }, },
- src/index.ts:80-81 (registration)The switch case in the CallToolRequestSchema handler that dispatches calls to the get_workflow_details tool by invoking the getWorkflowDetails method.case "get_workflow_details": return await this.getWorkflowDetails(args);