Skip to main content
Glama
DrBalls

n8n MCP Server

by DrBalls

n8n_get_workflow

Retrieve complete workflow details including nodes, connections, and settings by providing the workflow ID. Use this tool to inspect workflow configurations and understand automation structures.

Instructions

Get full details of a specific workflow including all nodes and connections.

Args:

  • id (string): The workflow ID

Returns: Complete workflow object with:

  • name, id, active status

  • nodes array with all node configurations

  • connections mapping

  • settings

  • tags

  • timestamps

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idYesThe unique identifier of the resource

Implementation Reference

  • The handler function for 'n8n_get_workflow' retrieves a workflow by ID and formats it for output.
      async (params: z.infer<typeof IdParamSchema>) => {
        const workflow = await get<N8nWorkflow>(`/workflows/${params.id}`);
        
        const nodeList = workflow.nodes.map(n => `  - ${n.name} (${n.type})`).join('\n');
        const text = `${formatWorkflow(workflow)}\n\n**Nodes (${workflow.nodes.length}):**\n${nodeList}`;
        
        return {
          content: [{ type: 'text', text }],
          structuredContent: workflow
        };
      }
    );
  • Tool registration for 'n8n_get_workflow'.
      server.registerTool(
        'n8n_get_workflow',
        {
          title: 'Get n8n Workflow',
          description: `Get full details of a specific workflow including all nodes and connections.
    
    Args:
      - id (string): The workflow ID
    
    Returns:
      Complete workflow object with:
      - name, id, active status
      - nodes array with all node configurations
      - connections mapping
      - settings
      - tags
      - timestamps`,
          inputSchema: IdParamSchema,
          annotations: {
            readOnlyHint: true,
            destructiveHint: false,
            idempotentHint: true,
            openWorldHint: false
          }
        },

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/DrBalls/n8n-mcp-server-v2'

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