diff --git a/packages/cli/src/modules/mcp/__tests__/data-table/add-data-table-rows.tool.test.ts b/packages/cli/src/modules/mcp/__tests__/data-table/add-data-table-rows.tool.test.ts index b62cfd70306..3a18b38ade3 100644 --- a/packages/cli/src/modules/mcp/__tests__/data-table/add-data-table-rows.tool.test.ts +++ b/packages/cli/src/modules/mcp/__tests__/data-table/add-data-table-rows.tool.test.ts @@ -37,7 +37,7 @@ describe('add_data_table_rows MCP tool', () => { expect(tool.name).toBe('add_data_table_rows'); expect(tool.config).toBeDefined(); - expect(typeof tool.config.description).toBe('string'); + expect(tool.config.description).toBeUndefined(); expect(tool.config.inputSchema).toBeDefined(); expect(tool.config.outputSchema).toBeDefined(); expect(typeof tool.handler).toBe('function'); diff --git a/packages/cli/src/modules/mcp/__tests__/data-table/create-data-table.tool.test.ts b/packages/cli/src/modules/mcp/__tests__/data-table/create-data-table.tool.test.ts index b32a2477153..748f743a01a 100644 --- a/packages/cli/src/modules/mcp/__tests__/data-table/create-data-table.tool.test.ts +++ b/packages/cli/src/modules/mcp/__tests__/data-table/create-data-table.tool.test.ts @@ -43,7 +43,7 @@ describe('create_data_table MCP tool', () => { expect(tool.name).toBe('create_data_table'); expect(tool.config).toBeDefined(); - expect(typeof tool.config.description).toBe('string'); + expect(tool.config.description).toBeUndefined(); expect(tool.config.inputSchema).toBeDefined(); expect(tool.config.outputSchema).toBeDefined(); expect(typeof tool.handler).toBe('function'); diff --git a/packages/cli/src/modules/mcp/__tests__/data-table/search-data-tables.tool.test.ts b/packages/cli/src/modules/mcp/__tests__/data-table/search-data-tables.tool.test.ts index 3d2f9e1196f..9d4b2c53dc1 100644 --- a/packages/cli/src/modules/mcp/__tests__/data-table/search-data-tables.tool.test.ts +++ b/packages/cli/src/modules/mcp/__tests__/data-table/search-data-tables.tool.test.ts @@ -49,7 +49,7 @@ describe('search_data_tables MCP tool', () => { expect(tool.name).toBe('search_data_tables'); expect(tool.config).toBeDefined(); - expect(typeof tool.config.description).toBe('string'); + expect(tool.config.description).toBeUndefined(); expect(tool.config.inputSchema).toBeDefined(); expect(tool.config.outputSchema).toBeDefined(); expect(typeof tool.handler).toBe('function'); diff --git a/packages/cli/src/modules/mcp/__tests__/get-execution.tool.test.ts b/packages/cli/src/modules/mcp/__tests__/get-execution.tool.test.ts index daf1d7d5511..8872cd9ade0 100644 --- a/packages/cli/src/modules/mcp/__tests__/get-execution.tool.test.ts +++ b/packages/cli/src/modules/mcp/__tests__/get-execution.tool.test.ts @@ -44,8 +44,7 @@ describe('get-execution MCP tool', () => { expect(tool.name).toBe('get_execution'); expect(tool.config).toBeDefined(); - expect(typeof tool.config.description).toBe('string'); - expect(tool.config.description).toContain('Get execution details'); + expect(tool.config.description).toBeUndefined(); expect(tool.config.inputSchema).toBeDefined(); expect(tool.config.outputSchema).toBeDefined(); expect(typeof tool.handler).toBe('function'); diff --git a/packages/cli/src/modules/mcp/__tests__/list-tags.tool.test.ts b/packages/cli/src/modules/mcp/__tests__/list-tags.tool.test.ts index 75b3c449281..a54a2b135db 100644 --- a/packages/cli/src/modules/mcp/__tests__/list-tags.tool.test.ts +++ b/packages/cli/src/modules/mcp/__tests__/list-tags.tool.test.ts @@ -49,7 +49,7 @@ describe('list-tags MCP tool', () => { const tool = createListTagsTool(user, tagService, telemetry); expect(tool.name).toBe('list_tags'); - expect(tool.config.description).toEqual(expect.any(String)); + expect(tool.config.description).toBeUndefined(); expect(tool.config.inputSchema).toBeDefined(); expect(tool.config.outputSchema).toBeDefined(); expect(tool.config.annotations).toMatchObject({ diff --git a/packages/cli/src/modules/mcp/__tests__/search-folders.tool.test.ts b/packages/cli/src/modules/mcp/__tests__/search-folders.tool.test.ts index 9e5433903b9..6c93b91d32d 100644 --- a/packages/cli/src/modules/mcp/__tests__/search-folders.tool.test.ts +++ b/packages/cli/src/modules/mcp/__tests__/search-folders.tool.test.ts @@ -60,7 +60,7 @@ describe('search-folders MCP tool', () => { expect(tool.name).toBe('search_folders'); expect(tool.config).toBeDefined(); - expect(typeof tool.config.description).toBe('string'); + expect(tool.config.description).toBeUndefined(); expect(tool.config.inputSchema).toBeDefined(); expect(typeof tool.handler).toBe('function'); }); diff --git a/packages/cli/src/modules/mcp/__tests__/search-workflows.tool.test.ts b/packages/cli/src/modules/mcp/__tests__/search-workflows.tool.test.ts index d666542cc9a..e18b0c598b6 100644 --- a/packages/cli/src/modules/mcp/__tests__/search-workflows.tool.test.ts +++ b/packages/cli/src/modules/mcp/__tests__/search-workflows.tool.test.ts @@ -47,7 +47,7 @@ describe('search-workflows MCP tool', () => { expect(tool.name).toBe('search_workflows'); expect(tool.config).toBeDefined(); - expect(typeof tool.config.description).toBe('string'); + expect(tool.config.description).toBeUndefined(); expect(tool.config.inputSchema).toBeDefined(); expect(typeof tool.handler).toBe('function'); }); diff --git a/packages/cli/src/modules/mcp/__tests__/unpublish-workflow.tool.test.ts b/packages/cli/src/modules/mcp/__tests__/unpublish-workflow.tool.test.ts index 9bbb30d538d..0301c17bceb 100644 --- a/packages/cli/src/modules/mcp/__tests__/unpublish-workflow.tool.test.ts +++ b/packages/cli/src/modules/mcp/__tests__/unpublish-workflow.tool.test.ts @@ -41,8 +41,7 @@ describe('unpublish-workflow MCP tool', () => { expect(tool.name).toBe('unpublish_workflow'); expect(tool.config).toBeDefined(); - expect(typeof tool.config.description).toBe('string'); - expect(tool.config.description).toContain('Unpublish'); + expect(tool.config.description).toBeUndefined(); expect(tool.config.inputSchema).toBeDefined(); expect(tool.config.outputSchema).toBeDefined(); expect(typeof tool.handler).toBe('function'); diff --git a/packages/cli/src/modules/mcp/tools/data-table/add-data-table-column.tool.ts b/packages/cli/src/modules/mcp/tools/data-table/add-data-table-column.tool.ts index c9df10233fe..76e6019148a 100644 --- a/packages/cli/src/modules/mcp/tools/data-table/add-data-table-column.tool.ts +++ b/packages/cli/src/modules/mcp/tools/data-table/add-data-table-column.tool.ts @@ -14,10 +14,10 @@ import { } from '../schemas'; const inputSchema = { - dataTableId: z.string().describe('The ID of the data table to add a column to'), + dataTableId: z.string(), projectId: dataTableProjectIdSchema, name: columnNameSchema, - type: dataTableColumnTypeSchema.describe('The data type of the new column'), + type: dataTableColumnTypeSchema, } satisfies z.ZodRawShape; const outputSchema = { @@ -33,7 +33,6 @@ export const createAddDataTableColumnTool = ( ): ToolDefinition => ({ name: 'add_data_table_column', config: { - description: 'Add a new column to an existing data table.', inputSchema, outputSchema, annotations: { diff --git a/packages/cli/src/modules/mcp/tools/data-table/add-data-table-rows.tool.ts b/packages/cli/src/modules/mcp/tools/data-table/add-data-table-rows.tool.ts index 4c3db4e4b13..1eaea9c31f5 100644 --- a/packages/cli/src/modules/mcp/tools/data-table/add-data-table-rows.tool.ts +++ b/packages/cli/src/modules/mcp/tools/data-table/add-data-table-rows.tool.ts @@ -11,15 +11,13 @@ import { dataTableProjectIdSchema } from '../schemas'; const ADD_ROWS_MAX = 1000; const addRowsInputSchema = { - dataTableId: z.string().describe('The ID of the data table to insert rows into'), + dataTableId: z.string(), projectId: dataTableProjectIdSchema, rows: z .array(z.record(z.string(), z.union([z.string(), z.number(), z.boolean(), z.null()]))) .min(1) .max(ADD_ROWS_MAX) - .describe( - `Array of row objects to insert. Each object maps column names to values. Maximum ${ADD_ROWS_MAX} rows per call.`, - ), + .describe('Row objects mapping column names to values.'), } satisfies z.ZodRawShape; const addRowsOutputSchema = { @@ -34,8 +32,6 @@ export const createAddDataTableRowsTool = ( ): ToolDefinition => ({ name: 'add_data_table_rows', config: { - description: - 'Insert rows into an existing data table. Each row is an object mapping column names to values. Use search_data_tables to find the data table ID first.', inputSchema: addRowsInputSchema, outputSchema: addRowsOutputSchema, annotations: { diff --git a/packages/cli/src/modules/mcp/tools/data-table/create-data-table.tool.ts b/packages/cli/src/modules/mcp/tools/data-table/create-data-table.tool.ts index b2a2c8ee408..1c27fea0f99 100644 --- a/packages/cli/src/modules/mcp/tools/data-table/create-data-table.tool.ts +++ b/packages/cli/src/modules/mcp/tools/data-table/create-data-table.tool.ts @@ -14,16 +14,13 @@ const columnSchema = z.object({ }); const createInputSchema = { - projectId: z.string().describe('The project ID where the data table will be created'), + projectId: z.string(), name: z .string() .min(1) .max(128) .describe('The name of the data table (must be unique within the project)'), - columns: z - .array(columnSchema) - .min(1) - .describe('The columns to create in the data table. At least one column is required.'), + columns: z.array(columnSchema).min(1), } satisfies z.ZodRawShape; const createOutputSchema = { @@ -39,8 +36,6 @@ export const createCreateDataTableTool = ( ): ToolDefinition => ({ name: 'create_data_table', config: { - description: - 'Create a new data table with the specified columns. Use search_projects to find a project ID first.', inputSchema: createInputSchema, outputSchema: createOutputSchema, annotations: { diff --git a/packages/cli/src/modules/mcp/tools/data-table/delete-data-table-column.tool.ts b/packages/cli/src/modules/mcp/tools/data-table/delete-data-table-column.tool.ts index 09d9c3785c5..2853d0549ad 100644 --- a/packages/cli/src/modules/mcp/tools/data-table/delete-data-table-column.tool.ts +++ b/packages/cli/src/modules/mcp/tools/data-table/delete-data-table-column.tool.ts @@ -9,9 +9,9 @@ import type { ToolDefinition, UserCalledMCPToolEventPayload } from '../../mcp.ty import { dataTableProjectIdSchema, successMessageOutputSchema } from '../schemas'; const inputSchema = { - dataTableId: z.string().describe('The ID of the data table containing the column'), + dataTableId: z.string(), projectId: dataTableProjectIdSchema, - columnId: z.string().describe('The ID of the column to delete'), + columnId: z.string(), } satisfies z.ZodRawShape; const outputSchema = successMessageOutputSchema; @@ -23,8 +23,7 @@ export const createDeleteDataTableColumnTool = ( ): ToolDefinition => ({ name: 'delete_data_table_column', config: { - description: - 'Delete a column from a data table. This permanently removes the column and all its data.', + description: 'Permanently removes the column and all its data.', inputSchema, outputSchema, annotations: { diff --git a/packages/cli/src/modules/mcp/tools/data-table/rename-data-table-column.tool.ts b/packages/cli/src/modules/mcp/tools/data-table/rename-data-table-column.tool.ts index 19731ca060d..35f84d2cdc8 100644 --- a/packages/cli/src/modules/mcp/tools/data-table/rename-data-table-column.tool.ts +++ b/packages/cli/src/modules/mcp/tools/data-table/rename-data-table-column.tool.ts @@ -14,10 +14,10 @@ import { } from '../schemas'; const inputSchema = { - dataTableId: z.string().describe('The ID of the data table containing the column'), + dataTableId: z.string(), projectId: dataTableProjectIdSchema, - columnId: z.string().describe('The ID of the column to rename'), - name: columnNameSchema.describe('The new column name'), + columnId: z.string(), + name: columnNameSchema, } satisfies z.ZodRawShape; const outputSchema = { @@ -32,7 +32,6 @@ export const createRenameDataTableColumnTool = ( ): ToolDefinition => ({ name: 'rename_data_table_column', config: { - description: 'Rename a column in a data table.', inputSchema, outputSchema, annotations: { diff --git a/packages/cli/src/modules/mcp/tools/data-table/rename-data-table.tool.ts b/packages/cli/src/modules/mcp/tools/data-table/rename-data-table.tool.ts index 5900056ca41..2e49ea45476 100644 --- a/packages/cli/src/modules/mcp/tools/data-table/rename-data-table.tool.ts +++ b/packages/cli/src/modules/mcp/tools/data-table/rename-data-table.tool.ts @@ -9,9 +9,9 @@ import type { ToolDefinition, UserCalledMCPToolEventPayload } from '../../mcp.ty import { dataTableProjectIdSchema, successMessageOutputSchema } from '../schemas'; const inputSchema = { - dataTableId: z.string().describe('The ID of the data table to rename'), + dataTableId: z.string(), projectId: dataTableProjectIdSchema, - name: z.string().min(1).max(128).describe('The new name for the data table'), + name: z.string().min(1).max(128), } satisfies z.ZodRawShape; const outputSchema = successMessageOutputSchema; @@ -23,7 +23,6 @@ export const createRenameDataTableTool = ( ): ToolDefinition => ({ name: 'rename_data_table', config: { - description: 'Rename an existing data table.', inputSchema, outputSchema, annotations: { diff --git a/packages/cli/src/modules/mcp/tools/data-table/search-data-tables.tool.ts b/packages/cli/src/modules/mcp/tools/data-table/search-data-tables.tool.ts index 6addc65fdad..ec7b3557b18 100644 --- a/packages/cli/src/modules/mcp/tools/data-table/search-data-tables.tool.ts +++ b/packages/cli/src/modules/mcp/tools/data-table/search-data-tables.tool.ts @@ -16,7 +16,7 @@ const searchInputSchema = { .string() .optional() .describe('Filter data tables by name (case-insensitive partial match)'), - projectId: z.string().optional().describe('Filter by project ID'), + projectId: z.string().optional(), limit: createLimitSchema(SEARCH_MAX_RESULTS), } satisfies z.ZodRawShape; @@ -32,8 +32,6 @@ export const createSearchDataTablesTool = ( ): ToolDefinition => ({ name: 'search_data_tables', config: { - description: - 'Search for data tables accessible to the current user. Use this to find a data table ID before modifying or adding data to it.', inputSchema: searchInputSchema, outputSchema: searchOutputSchema, annotations: { diff --git a/packages/cli/src/modules/mcp/tools/execute-workflow.tool.ts b/packages/cli/src/modules/mcp/tools/execute-workflow.tool.ts index 9f84365e897..27a395fec84 100644 --- a/packages/cli/src/modules/mcp/tools/execute-workflow.tool.ts +++ b/packages/cli/src/modules/mcp/tools/execute-workflow.tool.ts @@ -39,7 +39,7 @@ import type { WorkflowPublishedDataService } from '@/workflows/workflow-publishe export { type FoundWorkflow }; const inputSchema = z.object({ - workflowId: z.string().describe('The ID of the workflow to execute'), + workflowId: z.string(), executionMode: z .enum(['manual', 'production']) .describe( diff --git a/packages/cli/src/modules/mcp/tools/get-execution.tool.ts b/packages/cli/src/modules/mcp/tools/get-execution.tool.ts index fbfd4ea4853..fec68486d33 100644 --- a/packages/cli/src/modules/mcp/tools/get-execution.tool.ts +++ b/packages/cli/src/modules/mcp/tools/get-execution.tool.ts @@ -15,8 +15,8 @@ import type { Telemetry } from '@/telemetry'; import type { WorkflowFinderService } from '@/workflows/workflow-finder.service'; const inputSchema = z.object({ - workflowId: z.string().describe('The ID of the workflow the execution belongs to'), - executionId: z.string().describe('The ID of the execution to retrieve'), + workflowId: z.string(), + executionId: z.string(), includeData: z .boolean() .optional() @@ -70,8 +70,6 @@ export const createGetExecutionTool = ( ): ToolDefinition => ({ name: 'get_execution', config: { - description: - 'Get execution details by execution ID and workflow ID. By default returns metadata only. Set includeData to true to include node execution data, optionally filtered by nodeNames and truncated by truncateData.', inputSchema: inputSchema.shape, outputSchema, annotations: { diff --git a/packages/cli/src/modules/mcp/tools/get-workflow-details.tool.ts b/packages/cli/src/modules/mcp/tools/get-workflow-details.tool.ts index 841c4eb31c1..b83ba3bbc8e 100644 --- a/packages/cli/src/modules/mcp/tools/get-workflow-details.tool.ts +++ b/packages/cli/src/modules/mcp/tools/get-workflow-details.tool.ts @@ -19,7 +19,7 @@ import { getTriggerDetails, type WebhookEndpoints } from './webhook-utils'; import { getMcpWorkflow } from './workflow-validation.utils'; const inputSchema = { - workflowId: z.string().describe('The ID of the workflow to retrieve'), + workflowId: z.string(), } satisfies z.ZodRawShape; export type WorkflowDetailsOutputSchema = typeof workflowDetailsOutputSchema; @@ -44,7 +44,7 @@ export const createWorkflowDetailsTool = ( return { name: 'get_workflow_details', config: { - description: 'Get detailed information about a specific workflow including trigger details', + description: "Get a workflow's full definition, including how to trigger it.", inputSchema, outputSchema, annotations: { diff --git a/packages/cli/src/modules/mcp/tools/get-workflow-history.tool.ts b/packages/cli/src/modules/mcp/tools/get-workflow-history.tool.ts index 74a5abc6bc3..043675af30a 100644 --- a/packages/cli/src/modules/mcp/tools/get-workflow-history.tool.ts +++ b/packages/cli/src/modules/mcp/tools/get-workflow-history.tool.ts @@ -15,7 +15,7 @@ import { getMcpWorkflow } from './workflow-validation.utils'; const MAX_RESULTS = 50; const inputSchema = { - workflowId: z.string().describe('The ID of the workflow to read version history for'), + workflowId: z.string(), limit: createLimitSchema(MAX_RESULTS), offset: z .number() @@ -66,8 +66,7 @@ export const createGetWorkflowHistoryTool = ( ): ToolDefinition => ({ name: 'get_workflow_history', config: { - description: - 'List the saved version history of a workflow (newest first), so you can inspect how it changed over time and pick a version to retrieve or restore.', + description: "List a workflow's saved versions, newest first.", inputSchema, outputSchema, annotations: { diff --git a/packages/cli/src/modules/mcp/tools/get-workflow-version.tool.ts b/packages/cli/src/modules/mcp/tools/get-workflow-version.tool.ts index 6fd3a025f96..a3de715ee12 100644 --- a/packages/cli/src/modules/mcp/tools/get-workflow-version.tool.ts +++ b/packages/cli/src/modules/mcp/tools/get-workflow-version.tool.ts @@ -21,7 +21,7 @@ import { getMcpWorkflowVersion } from './workflow-history.utils'; import { getMcpWorkflow } from './workflow-validation.utils'; const inputSchema = { - workflowId: z.string().describe('The ID of the workflow the version belongs to'), + workflowId: z.string(), versionId: z.string().describe('The version ID to retrieve, as returned by get_workflow_history'), } satisfies z.ZodRawShape; @@ -80,8 +80,6 @@ export const createGetWorkflowVersionTool = ( ): ToolDefinition => ({ name: 'get_workflow_version', config: { - description: - 'Retrieve the full content (nodes, connections, node groups) of a specific workflow version from its history. Use the versionId from get_workflow_history.', inputSchema, outputSchema, annotations: { diff --git a/packages/cli/src/modules/mcp/tools/list-tags.tool.ts b/packages/cli/src/modules/mcp/tools/list-tags.tool.ts index 632b3ee0538..9e0c8930049 100644 --- a/packages/cli/src/modules/mcp/tools/list-tags.tool.ts +++ b/packages/cli/src/modules/mcp/tools/list-tags.tool.ts @@ -64,7 +64,6 @@ export const createListTagsTool = ( ): ToolDefinition => ({ name: 'list_tags', config: { - description: 'List all workflow tags in the instance.', inputSchema, outputSchema, annotations: { diff --git a/packages/cli/src/modules/mcp/tools/prepare-workflow-pin-data.tool.ts b/packages/cli/src/modules/mcp/tools/prepare-workflow-pin-data.tool.ts index 1ddd6dfea85..de149629acf 100644 --- a/packages/cli/src/modules/mcp/tools/prepare-workflow-pin-data.tool.ts +++ b/packages/cli/src/modules/mcp/tools/prepare-workflow-pin-data.tool.ts @@ -20,7 +20,7 @@ import type { ToolDefinition, UserCalledMCPToolEventPayload } from '../mcp.types import { getMcpWorkflow } from './workflow-validation.utils'; const inputSchema = z.object({ - workflowId: z.string().describe('The ID of the workflow to generate test pin data for'), + workflowId: z.string(), }); const outputSchema = { diff --git a/packages/cli/src/modules/mcp/tools/publish-workflow.tool.ts b/packages/cli/src/modules/mcp/tools/publish-workflow.tool.ts index ebb74fed86d..64ddfc60ed5 100644 --- a/packages/cli/src/modules/mcp/tools/publish-workflow.tool.ts +++ b/packages/cli/src/modules/mcp/tools/publish-workflow.tool.ts @@ -14,7 +14,7 @@ import type { ToolDefinition, UserCalledMCPToolEventPayload } from '../mcp.types import { getMcpWorkflow } from './workflow-validation.utils'; const inputSchema = z.object({ - workflowId: z.string().describe('The ID of the workflow to publish'), + workflowId: z.string(), versionId: z .string() .optional() @@ -46,8 +46,7 @@ export const createPublishWorkflowTool = ( ): ToolDefinition => ({ name: 'publish_workflow', config: { - description: - 'Publish (activate) a workflow to make it available for production execution. This creates an active version from the current draft.', + description: 'Publish (activate) a workflow: creates an active version from the current draft.', inputSchema: inputSchema.shape, outputSchema, annotations: { diff --git a/packages/cli/src/modules/mcp/tools/schemas.ts b/packages/cli/src/modules/mcp/tools/schemas.ts index 37a18e8f029..432d58dc7d0 100644 --- a/packages/cli/src/modules/mcp/tools/schemas.ts +++ b/packages/cli/src/modules/mcp/tools/schemas.ts @@ -31,9 +31,7 @@ export const workflowMetaSchema = z .custom((_value): _value is WorkflowFEMeta => true) .nullable(); -export const dataTableColumnTypeSchema = z - .enum(['string', 'number', 'boolean', 'date']) - .describe('The data type of the column'); +export const dataTableColumnTypeSchema = z.enum(['string', 'number', 'boolean', 'date']); export const dataTableColumnSchema = z.object({ id: z.string().describe('The unique identifier of the column'), @@ -53,18 +51,9 @@ export const dataTableSchema = z.object({ columns: z.array(dataTableColumnSchema).describe('The columns defined in this data table'), }); -export const createLimitSchema = (max: number) => - z - .number() - .int() - .positive() - .max(max) - .optional() - .describe(`Limit the number of results (max ${max})`); +export const createLimitSchema = (max: number) => z.number().int().positive().max(max).optional(); -export const dataTableProjectIdSchema = z - .string() - .describe('The project ID the data table belongs to'); +export const dataTableProjectIdSchema = z.string(); export const columnNameSchema = z .string() diff --git a/packages/cli/src/modules/mcp/tools/search-executions.tool.ts b/packages/cli/src/modules/mcp/tools/search-executions.tool.ts index f0af42cd740..b539b6fc0ca 100644 --- a/packages/cli/src/modules/mcp/tools/search-executions.tool.ts +++ b/packages/cli/src/modules/mcp/tools/search-executions.tool.ts @@ -15,21 +15,10 @@ import { getMcpWorkflow } from './workflow-validation.utils'; const MAX_RESULTS = 200; const inputSchema = { - workflowId: z.string().optional().describe('Filter executions by workflow ID'), - status: z - .array(z.enum(ExecutionStatusList)) - .optional() - .describe('Filter by execution status(es)'), - startedAfter: z - .string() - .datetime({ offset: true }) - .optional() - .describe('ISO 8601 timestamp — only return executions that started after this time'), - startedBefore: z - .string() - .datetime({ offset: true }) - .optional() - .describe('ISO 8601 timestamp — only return executions that started before this time'), + workflowId: z.string().optional(), + status: z.array(z.enum(ExecutionStatusList)).optional(), + startedAfter: z.string().datetime({ offset: true }).optional(), + startedBefore: z.string().datetime({ offset: true }).optional(), limit: createLimitSchema(MAX_RESULTS), lastId: z .string() @@ -69,8 +58,6 @@ export const createSearchExecutionsTool = ( ): ToolDefinition => ({ name: 'search_executions', config: { - description: - 'Search for workflow executions with optional filters. Returns execution metadata including status, timing, and workflow ID.', inputSchema, outputSchema, annotations: { diff --git a/packages/cli/src/modules/mcp/tools/search-folders.tool.ts b/packages/cli/src/modules/mcp/tools/search-folders.tool.ts index f7401f1d557..018c20d24e5 100644 --- a/packages/cli/src/modules/mcp/tools/search-folders.tool.ts +++ b/packages/cli/src/modules/mcp/tools/search-folders.tool.ts @@ -11,7 +11,7 @@ import { createLimitSchema } from './schemas'; const MAX_RESULTS = 100; const inputSchema = { - projectId: z.string().describe('The ID of the project to search folders in'), + projectId: z.string(), query: z.string().optional().describe('Filter folders by name (case-insensitive partial match)'), limit: createLimitSchema(MAX_RESULTS), } satisfies z.ZodRawShape; @@ -40,8 +40,6 @@ export const createSearchFoldersTool = ( ): ToolDefinition => ({ name: 'search_folders', config: { - description: - 'Search for folders within a project. Use this to find a folder ID before creating a workflow in a specific folder. Requires a projectId — use search_projects first if needed.', inputSchema, outputSchema, annotations: { diff --git a/packages/cli/src/modules/mcp/tools/search-workflows.tool.ts b/packages/cli/src/modules/mcp/tools/search-workflows.tool.ts index d1c123f5501..b598448bde6 100644 --- a/packages/cli/src/modules/mcp/tools/search-workflows.tool.ts +++ b/packages/cli/src/modules/mcp/tools/search-workflows.tool.ts @@ -85,8 +85,6 @@ export const createSearchWorkflowsTool = ( return { name: 'search_workflows', config: { - description: - 'Search for workflows with optional filters. Returns a preview of each workflow.', inputSchema, outputSchema, annotations: { diff --git a/packages/cli/src/modules/mcp/tools/test-workflow.tool.ts b/packages/cli/src/modules/mcp/tools/test-workflow.tool.ts index b330cdfc92c..5cf9ff79565 100644 --- a/packages/cli/src/modules/mcp/tools/test-workflow.tool.ts +++ b/packages/cli/src/modules/mcp/tools/test-workflow.tool.ts @@ -31,7 +31,7 @@ import { import { getMcpWorkflow } from './workflow-validation.utils'; const inputSchema = z.object({ - workflowId: z.string().describe('The ID of the workflow to test'), + workflowId: z.string(), pinData: z .record(z.array(z.record(z.unknown()))) .describe( diff --git a/packages/cli/src/modules/mcp/tools/unpublish-workflow.tool.ts b/packages/cli/src/modules/mcp/tools/unpublish-workflow.tool.ts index 3536b745da4..0c87200c354 100644 --- a/packages/cli/src/modules/mcp/tools/unpublish-workflow.tool.ts +++ b/packages/cli/src/modules/mcp/tools/unpublish-workflow.tool.ts @@ -14,7 +14,7 @@ import type { ToolDefinition, UserCalledMCPToolEventPayload } from '../mcp.types import { getMcpWorkflow } from './workflow-validation.utils'; const inputSchema = z.object({ - workflowId: z.string().describe('The ID of the workflow to unpublish'), + workflowId: z.string(), }); type UnpublishWorkflowOutput = { @@ -38,8 +38,6 @@ export const createUnpublishWorkflowTool = ( ): ToolDefinition => ({ name: 'unpublish_workflow', config: { - description: - 'Unpublish (deactivate) a workflow to stop it from being available for production execution.', inputSchema: inputSchema.shape, outputSchema, annotations: { diff --git a/packages/cli/src/modules/mcp/tools/workflow-builder/delete-workflow.tool.ts b/packages/cli/src/modules/mcp/tools/workflow-builder/delete-workflow.tool.ts index b9186dfef60..a076ea99c08 100644 --- a/packages/cli/src/modules/mcp/tools/workflow-builder/delete-workflow.tool.ts +++ b/packages/cli/src/modules/mcp/tools/workflow-builder/delete-workflow.tool.ts @@ -12,7 +12,7 @@ import type { ToolDefinition, UserCalledMCPToolEventPayload } from '../../mcp.ty import { getMcpWorkflow } from '../workflow-validation.utils'; const inputSchema = { - workflowId: z.string().describe('The ID of the workflow to archive'), + workflowId: z.string(), } satisfies z.ZodRawShape; const outputSchema = { @@ -33,7 +33,6 @@ export const createArchiveWorkflowTool = ( ): ToolDefinition => ({ name: MCP_ARCHIVE_WORKFLOW_TOOL.toolName, config: { - description: 'Archive a workflow in n8n by its ID.', inputSchema, outputSchema, annotations: { diff --git a/packages/cli/src/modules/mcp/tools/workflow-builder/restore-workflow-version.tool.ts b/packages/cli/src/modules/mcp/tools/workflow-builder/restore-workflow-version.tool.ts index 90b6dc3407d..c0c233fd9c8 100644 --- a/packages/cli/src/modules/mcp/tools/workflow-builder/restore-workflow-version.tool.ts +++ b/packages/cli/src/modules/mcp/tools/workflow-builder/restore-workflow-version.tool.ts @@ -16,7 +16,7 @@ import { getMcpWorkflow } from '../workflow-validation.utils'; import { buildRestoreVersionMetadata } from './version-metadata'; const inputSchema = z.object({ - workflowId: z.string().describe('The ID of the workflow to restore'), + workflowId: z.string(), versionId: z.string().describe('The version ID to restore, as returned by get_workflow_history'), }); @@ -57,7 +57,7 @@ export const createRestoreWorkflowVersionTool = ( name: 'restore_workflow_version', config: { description: - 'Restore a workflow to a previous version from its history. Re-applies that version as the current draft and records a new history entry. Use get_workflow_history to find the versionId.', + "Restore a previous version as the workflow's current draft; records a new history entry.", inputSchema: inputSchema.shape, outputSchema, annotations: { diff --git a/packages/cli/src/modules/mcp/tools/workflow-builder/update-workflow.tool.ts b/packages/cli/src/modules/mcp/tools/workflow-builder/update-workflow.tool.ts index 86ebd92f8dd..c5ce886406a 100644 --- a/packages/cli/src/modules/mcp/tools/workflow-builder/update-workflow.tool.ts +++ b/packages/cli/src/modules/mcp/tools/workflow-builder/update-workflow.tool.ts @@ -269,7 +269,7 @@ function collectTouchedNodes(operations: PartialUpdateOperation[]): Map ({ - workflowId: z.string().describe('The ID of the workflow to update.'), + workflowId: z.string(), skillsUsed: z.array(z.string()).optional().describe(SKILLS_USED_PARAM_DESCRIPTION), operations: z .array(buildOperationInputSchema(canvasGroupsEnabled))