n8n_get_workflow
Retrieve a specific workflow from n8n by providing its unique ID, enabling users to access and manage automation processes.
Instructions
Get a specific workflow by ID
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | Workflow ID |
Implementation Reference
- src/n8n-client.ts:56-59 (handler)The handler function that performs the API call to retrieve a workflow by ID.
async getWorkflow(id: string): Promise<any> { const response = await this.client.get(`/workflows/${id}`); return response.data; } - src/index.ts:64-70 (registration)The tool execution logic in the main request handler loop.
case 'n8n_get_workflow': { if (!args?.id) throw new Error('id is required'); const result = await n8nClient.getWorkflow(args.id as string as string); return { content: [{ type: 'text', text: formatResponse(result) }], }; } - src/index.ts:457-466 (schema)The MCP tool registration definition including the input schema.
name: 'n8n_get_workflow', description: 'Get a specific workflow by ID', inputSchema: { type: 'object', properties: { id: { type: 'string', description: 'Workflow ID' }, }, required: ['id'], }, },