Skip to main content
Glama
f-is-h

MCP Easy Copy

by f-is-h

_________available_mcp_services_for_easy_copy_________

Lists available MCP services in your Claude instance for quick reference and easy copying.

Instructions

List all MCP services available in this Claude instance

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The anonymous async handler function for the tool. It fetches the current list of MCP services using getMcpServices(), handles empty case, formats a numbered list with copy-paste instructions, and returns as text content.
    async () => {
      // Always fetch the latest services when the tool is called
      const currentServices = await getMcpServices();
      
      if (currentServices.length === 0) {
        return {
          content: [{ 
            type: "text", 
            text: "No MCP services configured." 
          }]
        };
      }
      
      // Format the output with numbered list and usage instructions
      const formattedList = "📋 AVAILABLE MCP SERVICES:\n" + 
        currentServices.map((name, index) => `${index + 1}. ${name}`).join("\n") + 
        "\n\nCopy a service name to use in prompts like:\n" +
        "• Can you use [service name] to...\n" +
        "• Please call [service name] to...";
      
      return {
        content: [{ 
          type: "text", 
          text: formattedList 
        }]
      };
    }
  • src/index.ts:150-181 (registration)
    The server.tool() registration call that defines the tool name, dynamic toolDescription (computed from initial services), empty input schema, and references the handler function.
    server.tool(
      "_________available_mcp_services_for_easy_copy_________",
      toolDescription,
      {}, // No parameters needed
      async () => {
        // Always fetch the latest services when the tool is called
        const currentServices = await getMcpServices();
        
        if (currentServices.length === 0) {
          return {
            content: [{ 
              type: "text", 
              text: "No MCP services configured." 
            }]
          };
        }
        
        // Format the output with numbered list and usage instructions
        const formattedList = "📋 AVAILABLE MCP SERVICES:\n" + 
          currentServices.map((name, index) => `${index + 1}. ${name}`).join("\n") + 
          "\n\nCopy a service name to use in prompts like:\n" +
          "• Can you use [service name] to...\n" +
          "• Please call [service name] to...";
        
        return {
          content: [{ 
            type: "text", 
            text: formattedList 
          }]
        };
      }
    );
  • Empty input schema object {}, indicating the tool takes no parameters.
    {}, // No parameters needed
  • Core helper function that locates the Claude Desktop config file, parses JSON, extracts keys from config.mcpServers, and returns array of service names. Used by both the tool handler and tool description.
    async function getMcpServices(): Promise<string[]> {
      try {
        // Find the config file
        const configPath = await findConfigFile();
        if (!configPath) {
          return [];
        }
        
        // Read and parse the config file
        const configContent = await fs.readFile(configPath, 'utf-8');
        const config = JSON.parse(configContent);
        
        // Extract and return MCP service names
        return config.mcpServers ? Object.keys(config.mcpServers) : [];
      } catch (error) {
        logDebug(`Error getting MCP services: ${error}`);
        return [];
      }
    }
  • Supporting helper to search possible OS-specific paths for Claude Desktop config file and return the first accessible one.
    async function findConfigFile(): Promise<string | null> {
      for (const configPath of possibleConfigPaths) {
        try {
          await fs.access(configPath);
          logDebug(`Found config file at: ${configPath}`);
          return configPath;
        } catch (error) {
          logDebug(`Config file not found at: ${configPath}`);
        }
      }
      return null;
    }
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. While 'List all' implies a read-only operation, it doesn't specify whether this requires permissions, what format the output returns, or any rate limits or side effects. For a tool with zero annotation coverage, this is insufficient.

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, efficient sentence that directly states the tool's purpose without any unnecessary words or structural issues. It is appropriately sized and front-loaded.

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

Completeness3/5

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

Given the tool's simplicity (0 parameters, no output schema, no annotations), the description is adequate but has clear gaps. It explains the basic purpose but lacks behavioral details like output format or usage context, making it minimally viable but not fully complete.

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

Parameters4/5

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

The tool has 0 parameters with 100% schema description coverage, so the schema already fully documents the lack of inputs. The description appropriately doesn't add parameter details, maintaining a baseline of 4 for tools with no parameters.

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') and the resource ('MCP services available in this Claude instance'), providing a specific verb+resource combination. However, since there are no sibling tools mentioned, it cannot demonstrate differentiation from alternatives, which prevents a perfect score of 5.

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, prerequisites, or contextual constraints. It simply states what the tool does without any usage instructions or exclusions.

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/f-is-h/mcp-easy-copy'

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