Skip to main content
Glama
Preston-Harrison

Filesystem MCP Server

list_allowed_directories

Retrieve the absolute paths of all directories authorized for read/write operations by the Filesystem MCP Server, ensuring compliance with directory sandboxing and access restrictions.

Instructions

List all allowed directory roots for filesystem operations.

Returns: List[str]: Absolute paths of directories the server can read/write

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • main.py:194-201 (handler)
    The handler function for the 'list_allowed_directories' tool, registered via @mcp.tool decorator. It returns a list of absolute paths of the allowed directories configured at server startup.
    @mcp.tool def list_allowed_directories() -> List[str]: """List all allowed directory roots for filesystem operations. Returns: List[str]: Absolute paths of directories the server can read/write """ return [str(p) for p in ALLOWED_DIRS]
  • main.py:194-194 (registration)
    The @mcp.tool decorator registers the list_allowed_directories function as an MCP tool.
    @mcp.tool

Other Tools

Related Tools

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/Preston-Harrison/fs-mcp-py'

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