Skip to main content
Glama
srafi26

MCP Server

by srafi26

echo

Echo back input text to verify communication and test connectivity in the MCP Server environment.

Instructions

Echo back the input text

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
messageYesThe message to echo back

Implementation Reference

  • The handler that implements the core logic of the 'echo' tool by validating the input message and echoing it back as text content.
    case 'echo':
      const message = validateString(args.message, 'message');
      return {
        content: [
          {
            type: 'text',
            text: message,
          } as TextContent,
        ],
      };
  • The JSON schema defining the input parameters for the 'echo' tool, specifying a required 'message' string.
    inputSchema: {
      type: 'object',
      properties: {
        message: {
          type: 'string',
          description: 'The message to echo back',
        },
      },
      required: ['message'],
    },
  • src/index.ts:30-43 (registration)
    The registration of the 'echo' tool in the tools array, which is served via the ListToolsRequest handler.
    {
      name: 'echo',
      description: 'Echo back the input text',
      inputSchema: {
        type: 'object',
        properties: {
          message: {
            type: 'string',
            description: 'The message to echo back',
          },
        },
        required: ['message'],
      },
    },
  • Helper function for string input validation, used by the echo tool handler.
    const validateString = (value: unknown, fieldName: string): string => {
      if (typeof value !== 'string') {
        throw new Error(`${fieldName} must be a string`);
      }
      return value;
    };
Behavior2/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It states the tool echoes input but doesn't cover aspects like whether it's read-only, if it has side effects, error handling, or output format. 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 extremely concise and front-loaded, consisting of a single sentence that directly states the tool's purpose without any wasted words. It efficiently communicates the core functionality in a minimal format.

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 low complexity (single parameter, no output schema, no annotations), the description is adequate but has clear gaps. It covers the basic purpose but lacks usage guidelines and behavioral details, making it minimally viable but not fully informative for an agent to use effectively in varied contexts.

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?

The schema description coverage is 100%, with the parameter 'message' fully documented in the schema. The description adds no additional meaning beyond the schema's details, such as examples or constraints. According to guidelines, this warrants a baseline score of 3 when the schema does the heavy lifting.

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 tool's function ('Echo back the input text'), specifying both the verb ('echo back') and the resource ('input text'). However, it doesn't explicitly differentiate from sibling tools like 'calculate' or 'uppercase', which would require mentioning it returns the input unchanged versus performing transformations.

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. It doesn't mention scenarios where echoing is appropriate (e.g., testing, debugging) or contrast it with siblings like 'uppercase' for text modification or 'calculate' for computations, leaving usage context implied at best.

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/srafi26/mcp-server'

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