Skip to main content
Glama
chatmcp
by chatmcp

submit-mcp-server

Submit MCP Server details, including URL and avatar, to the MCP Servers Directory for collection and public listing by mcp-server-collector.

Instructions

Submit MCP Server to MCP Servers Directory like mcp.so

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
avatar_urlNoavatar URL of the MCP Server to submit
urlYesURL of the MCP Server to submit

Implementation Reference

  • Registration of the 'submit-mcp-server' tool in list_tools(), including name, description, and input schema.
    types.Tool( name="submit-mcp-server", description="Submit MCP Server to MCP Servers Directory like mcp.so", inputSchema={ "type": "object", "properties": { "url": { "type": "string", "description": "URL of the MCP Server to submit", }, "avatar_url": { "type": "string", "description": "avatar URL of the MCP Server to submit", }, }, "required": ["url"], }, ),
  • Handler logic in handle_call_tool() for 'submit-mcp-server': extracts arguments, calls submit_mcp_server helper, and returns JSON result as TextContent.
    case "submit-mcp-server": url = arguments.get("url") avatar_url = arguments.get("avatar_url") or "" result = await submit_mcp_server(url, avatar_url) content = json.dumps(result) return [ types.TextContent( type="text", text=content, ) ]
  • Core helper function that performs HTTP POST to submit the MCP server URL and avatar to the directory endpoint.
    async def submit_mcp_server(url: str, avatar_url: str): payload = { "url": url, "avatar_url": avatar_url } try: async with aiohttp.ClientSession() as session: async with session.post( os.getenv("MCP_SERVER_SUBMIT_URL"), headers={"Content-Type": "application/json"}, data=json.dumps(payload) ) as response: if response.status == 200: return await response.json() else: raise Exception(f"submit mcp server failed: HTTP {response.status}") except Exception as e: raise Exception(f"submit mcp server failed: {str(e)}")

Other Tools

Related Tools

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

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