Skip to main content
Glama

fast_list_allowed_directories

Lists directories accessible for file operations in the filesystem MCP server, enabling users to identify available paths for reading or writing files.

Instructions

Lists the allowed directories

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The handler function that implements the core logic of the 'fast_list_allowed_directories' tool. It returns the list of allowed directories, exclude patterns, and server configuration limits.
    async function handleListAllowedDirectories() { return { allowed_directories: DEFAULT_ALLOWED_DIRECTORIES, current_working_directory: process.cwd(), exclude_patterns: DEFAULT_EXCLUDE_PATTERNS, claude_limits: { max_response_size_mb: CLAUDE_MAX_RESPONSE_SIZE / (1024**2), max_chunk_size_mb: CLAUDE_MAX_CHUNK_SIZE / (1024**2), max_lines_per_read: CLAUDE_MAX_LINES, max_dir_items: CLAUDE_MAX_DIR_ITEMS }, server_info: { name: 'fast-filesystem', version: '2.1.0', total_tools: MCP_TOOLS.length, timestamp: new Date().toISOString() } }; }
  • api/server.ts:320-322 (registration)
    The switch case in the tools/call handler that dispatches to the tool's handler function.
    case 'fast_list_allowed_directories': result = await handleListAllowedDirectories(); break;
  • api/server.ts:99-106 (registration)
    Registration of the tool in the MCP_TOOLS array, including name, description, and empty input schema (no parameters required).
    name: 'fast_list_allowed_directories', description: '허용된 디렉토리 목록을 조회합니다', inputSchema: { type: 'object', properties: {}, required: [] } },
  • The input schema for the tool, which is an empty object since no parameters are required.
    type: 'object', properties: {}, required: [] }
  • Helper constant defining the default allowed directories, which is returned by the handler.
    const DEFAULT_ALLOWED_DIRECTORIES = [ process.env.HOME || '/home', '/tmp', '/Users', '/home' ];
  • Helper constant defining default exclude patterns for paths, returned by the handler.
    const DEFAULT_EXCLUDE_PATTERNS = [ '.venv', 'venv', 'node_modules', '.git', '.svn', '.hg', '__pycache__', '.pytest_cache', '.mypy_cache', '.coverage', 'dist', 'build', 'target', 'bin', 'obj', '.vs', '.vscode', '*.pyc', '*.pyo', '*.pyd', '.DS_Store', 'Thumbs.db' ];

Latest Blog Posts

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/efforthye/fast-filesystem-mcp'

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