Skip to main content
Glama
errors.ts398 B
import { UserError } from 'fastmcp'; const MESSAGES = { invalidApiResponse: 'The API response did not match the expected format.', }; export const message = (type: keyof typeof MESSAGES) => { return `Error: ${MESSAGES[type]}`; }; export const throwApiInvalidResponseError = (error: unknown) => { const msg = message('invalidApiResponse'); throw new UserError(`${msg}: ${String(error)}`); };

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

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