get_current_directory
Retrieve the current working directory path in Windows CLI environments to verify file locations and navigate system directories.
Instructions
Get the current working directory
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/index.ts:863-866 (handler)Handler function for 'get_current_directory' tool that retrieves and returns the current working directory using Node.js process.cwd().case 'get_current_directory': { const currentDir = process.cwd(); return { content: [{ type: 'text', text: `Current working directory: ${currentDir}` }] }; }
- src/index.ts:525-531 (registration)Registration of the 'get_current_directory' tool in the ListToolsRequestSchema handler, including its description and input schema (no parameters required).name: "get_current_directory", description: "Get the current working directory", inputSchema: { type: "object", properties: {} // No input parameters needed } }
- src/index.ts:527-531 (schema)Input schema definition for the 'get_current_directory' tool, specifying an empty object (no input parameters).inputSchema: { type: "object", properties: {} // No input parameters needed } }