Skip to main content
Glama
landicefu

MCP Client Configuration Server

by landicefu

list_servers

Retrieve all configured server names for a specific MCP client to manage and synchronize configurations across AI assistant platforms.

Instructions

List all server names configured in a specific client

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
clientYesClient name (cline, roo_code, windsurf, claude)

Implementation Reference

  • src/index.ts:155-168 (registration)
    Registration of the 'list_servers' tool in the ListTools response, including name, description, and input schema requiring a 'client' parameter.
    {
      name: 'list_servers',
      description: 'List all server names configured in a specific client',
      inputSchema: {
        type: 'object',
        properties: {
          client: {
            type: 'string',
            description: 'Client name (cline, roo_code, windsurf, claude)',
          },
        },
        required: ['client'],
      },
    },
  • Handler function for the 'list_servers' tool. Validates the client, reads the configuration file (returns empty array if not found), extracts server names from config.mcpServers using Object.keys, and returns them as a JSON string.
    case 'list_servers': {
      const client = validateClient(args.client);
      const configPath = getConfigPath(client);
      
      let config;
      try {
        config = await readConfigFile(configPath);
      } catch (error) {
        if (error instanceof McpError && error.code === ErrorCode.InternalError && error.message.includes('not found')) {
          // Return empty array if configuration file doesn't exist
          return {
            content: [
              {
                type: 'text',
                text: '[]',
              },
            ],
          };
        } else {
          throw error;
        }
      }
      
      // Extract server names from the configuration
      let serverNames: string[] = [];
      if (config.mcpServers && typeof config.mcpServers === 'object') {
        serverNames = Object.keys(config.mcpServers);
      }
      
      return {
        content: [
          {
            type: 'text',
            text: JSON.stringify(serverNames, null, 2),
          },
        ],
      };
    }
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden of behavioral disclosure. It states it 'lists' server names, implying a read-only operation, but doesn't clarify whether this requires authentication, has rate limits, returns paginated results, or what format the output takes (e.g., list of strings, structured data). For a tool with zero annotation coverage, this leaves significant gaps in understanding its behavior.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, clear sentence that efficiently conveys the core purpose without unnecessary words. It's appropriately sized and front-loaded with the essential information, making it easy to parse quickly.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given no annotations and no output schema, the description is incomplete for a tool that likely returns a list of server names. It doesn't explain the return format, error conditions, or behavioral traits like whether it's safe to call repeatedly. For a read operation with structured siblings, more context is needed to guide proper usage.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, with the single parameter 'client' fully documented in the schema. The description adds no additional parameter semantics beyond implying the tool operates within a client context, which is already covered by the schema's description. This meets the baseline of 3 when schema coverage is high.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the action ('List all server names') and resource ('configured in a specific client'), providing a specific verb+resource combination. However, it doesn't explicitly differentiate from sibling tools like 'get_server_configuration' or 'get_configuration', which might also retrieve server-related information but with different scope or detail.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives like 'get_server_configuration' or 'get_configuration'. It mentions 'in a specific client' which implies a context, but doesn't state exclusions, prerequisites, or when-not-to-use scenarios relative to siblings.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other 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/landicefu/mcp-client-configuration-server'

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