Skip to main content
Glama

get_allowed_paths

Retrieves a list of accessible file paths within restricted directories, ensuring secure access to system information and file operations.

Instructions

アクセス可能なパスの一覧を表示します

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • Primary handler for the get_allowed_paths tool. Fetches allowed paths from PathValidator and formats response as CallToolResult.
    private async getAllowedPaths(): Promise<CallToolResult> { const allowedPaths = this.pathValidator.getAllowedPaths(); return { content: [ { type: "text", text: `アクセス可能なパス一覧:\n\n${allowedPaths.map(p => `📁 ${p}`).join('\n')}\n\n注意: これらのディレクトリとそのサブディレクトリのみアクセス可能です。`, }, ], isError: false, }; }
  • src/index.ts:182-189 (registration)
    Tool registration in the TOOLS constant array, which is returned by ListToolsRequestHandler.
    { name: "get_allowed_paths", description: "アクセス可能なパスの一覧を表示します", inputSchema: { type: "object", properties: {}, }, },
  • Input schema definition for the tool (empty object since no parameters required).
    inputSchema: { type: "object", properties: {}, },
  • PathValidator helper method that provides the list of allowed paths used by the tool handler.
    getAllowedPaths(): string[] { return [...this.allowedPaths]; }

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/p-united/mcpSample'

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