Skip to main content
Glama
utils.ts498 B
import type { CallToolResult } from "@modelcontextprotocol/sdk/types.js"; /** * Creates a CallToolResult with a text content block containing the JSON stringified data. * @param data - The data to be included in the text content block. * @returns A CallToolResult object with the text content block. */ export function createTextResult(data: unknown): CallToolResult { return { content: [ { type: "text", text: JSON.stringify(data, null, 2), }, ], }; }

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/nickytonline/dev-to-mcp'

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