Skip to main content
Glama

n8n MCP Server

MIT License
133
1,377
  • Apple
  • Linux
list.test.ts.bak944 B
/** * ListWorkflowsHandler unit tests */ import { describe, it, expect, jest } from '@jest/globals'; import { getListWorkflowsToolDefinition } from '../../../../src/tools/workflow/list.js'; import { mockApiResponses } from '../../../mocks/n8n-fixtures.js'; // Since this is an integration test, we'll test the definition directly // rather than mocking the complex handler implementation jest.mock('../../../../src/tools/workflow/base-handler.js'); describe('getListWorkflowsToolDefinition', () => { it('should return the correct tool definition', () => { // Execute const definition = getListWorkflowsToolDefinition(); // Assert expect(definition.name).toBe('list_workflows'); expect(definition.description).toBeTruthy(); expect(definition.inputSchema).toBeDefined(); expect(definition.inputSchema.properties).toHaveProperty('active'); expect(definition.inputSchema.required).toEqual([]); }); });

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

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