Skip to main content
Glama

Convex MCP server

Official
by get-convex
udf_path_utils.ts933 B
import { convexToJson, Value } from "../../values/index.js"; export function canonicalizeUdfPath(udfPath: string): string { const pieces = udfPath.split(":"); let moduleName: string; let functionName: string; if (pieces.length === 1) { moduleName = pieces[0]; functionName = "default"; } else { moduleName = pieces.slice(0, pieces.length - 1).join(":"); functionName = pieces[pieces.length - 1]; } if (moduleName.endsWith(".js")) { moduleName = moduleName.slice(0, -3); } return `${moduleName}:${functionName}`; } /** * A string representing the name and arguments of a query. * * This is used by the {@link BaseConvexClient}. * * @public */ export type QueryToken = string; export function serializePathAndArgs( udfPath: string, args: Record<string, Value>, ): QueryToken { return JSON.stringify({ udfPath: canonicalizeUdfPath(udfPath), args: convexToJson(args), }); }

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/get-convex/convex-backend'

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