Skip to main content
Glama
by LassiterJ
echo.tsโ€ข731 B
import { z } from "zod"; import type { RegisterableModule } from "../registry/types.js"; import type { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js"; const echoModule: RegisterableModule = { type: "tool", name: "echo", description: "Echo back the provided text", register(server: McpServer) { server.tool( "echo", "Echo back the provided text", { text: z.string().min(1, "Text cannot be empty").describe("Text to echo back"), }, (args) => { const text = args.text; return { content: [ { type: "text", text: text, }, ], }; } ); } }; export default echoModule;

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/LassiterJ/mcp-playground'

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