Skip to main content
Glama

listConfigs

Find configuration files in your workspace using glob patterns to locate JSON, YAML, TOML, and other config formats for development settings management.

Instructions

List configuration files in the workspace matching specified patterns

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
includeNoGlob patterns for config files

Implementation Reference

  • src/index.ts:112-132 (registration)
    Full registration of the 'listConfigs' MCP tool, including name, description, input schema, and handler function.
    mcp.tool( "listConfigs", "List configuration files in the workspace matching specified patterns", { include: z .array(z.string()) .default(["**/*.{json,jsonc,yaml,yml,toml}"]) .describe("Glob patterns for config files"), }, async ({ include }: { include: string[] }) => { try { const items = await searchFiles("", include, { listOnly: true, maxResults: 200 }); return { content: items }; } catch (error) { return { content: [{ type: "text", text: `Error listing configs: ${error}` }], isError: true, }; } } );
  • Handler function that implements the core logic of listConfigs by using searchFiles to list configuration files matching the given glob patterns.
    async ({ include }: { include: string[] }) => { try { const items = await searchFiles("", include, { listOnly: true, maxResults: 200 }); return { content: items }; } catch (error) { return { content: [{ type: "text", text: `Error listing configs: ${error}` }], isError: true, }; } }
  • Zod input schema defining the 'include' parameter as an array of glob patterns for finding config files, with a sensible default.
    { include: z .array(z.string()) .default(["**/*.{json,jsonc,yaml,yml,toml}"]) .describe("Glob patterns for config files"), },

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/cloud-aspect/Config-MCP-Server'

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