Skip to main content
Glama
catalog-servers.ts1.27 kB
import { z } from "zod/v4"; import { updateTargetServerRequestSchema } from "./request-schemas.js"; // ============ Config is an alias for TargetServer ============ // The currently used "TargetServer" object is actually an MCP server *config*. // In order not to refactor the whole code but to connect to it, // in the catalog I used "config" instead of "TargetServer" but *It's the same object* (see schema) export const configSchema = z.record( z.string(), updateTargetServerRequestSchema, ); // ============ GET request ============ export const catalogMCPServerSchema = z.object({ name: z.string(), config: configSchema, displayName: z.string(), description: z.string().optional(), link: z.string().optional(), iconPath: z.string().optional(), doc: z.string().optional(), }); export const catalogMCPServerListSchema = z.array(catalogMCPServerSchema); // ============================================ // Type Exports // ============================================ export type CatalogMCPServerInput = z.input<typeof catalogMCPServerSchema>; export type CatalogMCPServerItem = z.infer<typeof catalogMCPServerSchema>; export type CatalogMCPServerList = z.infer<typeof catalogMCPServerListSchema>; export type Config = z.infer<typeof configSchema>;

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/TheLunarCompany/lunar'

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