diff --git a/src/shell-server/index.ts b/src/shell-server/index.ts index d3a00c8..9e4cecb 100644 --- a/src/shell-server/index.ts +++ b/src/shell-server/index.ts @@ -118,10 +118,26 @@ server.resource( // Shell command execution tool configuration server.tool( "shell_exec", - "Executes commands in the specified shell", + "Executes commands in the specified shell with detailed error handling and output capture", { - command: z.string().min(1), - workingDir: workingDir ? z.string().optional() : z.string(), + command: z + .string() + .min(1) + .describe( + "The shell command to execute in the configured shell environment", + ), + workingDir: workingDir + ? z + .string() + .optional() + .describe( + "Optional working directory to execute the command in (must be under $HOME for security)", + ) + : z + .string() + .describe( + "Working directory to execute the command in (must be under $HOME for security)", + ), }, async ({ command, workingDir: cmdWorkingDir }) => { try {