Custom Context MCP Server
Provides the HTTP server foundation for the MCP server, handling SSE connections and health check endpoints.
Manages the package dependencies for the MCP server with optimized installation and execution commands.
Enables type-safe development of the MCP server with features for ensuring data integrity across API interactions.
Handles runtime data validation for API requests and responses, ensuring data conforms to expected schemas.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Custom Context MCP Serverconvert this text to JSON: name: Alice, age: 30, city: New York"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Custom Context MCP Server
基于FastMCP框架的MCP服务器,支持SSE实时事件流和工具调用。
功能特性
✅ 基于FastMCP框架
✅ SSE实时事件流
✅ HTTP健康检查端点
✅ 支持mcp-inspector调试
✅ TypeScript类型安全
✅ 热重载开发模式
Related MCP server: FastAPI MCP Server
快速开始
安装依赖
pnpm install开发模式
# 启动开发服务器(包含mcp-inspector)
pnpm run dev
# 或者启动监听模式
pnpm run dev:watch生产模式
# 构建项目
pnpm run build
# 启动服务器
pnpm start调试指南
使用mcp-inspector调试
启动服务器:
pnpm run dev访问mcp-inspector:
服务器启动后会自动打开mcp-inspector界面
或者手动访问:http://localhost:6274
测试工具:
在mcp-inspector中选择工具
输入参数并执行
查看实时结果
服务器端点
SSE端点:
http://localhost:3005/sse健康检查:
http://localhost:3005/healthmcp-inspector:
http://localhost:6274
测试工具
group-text-by-json
{
"template": "{\"name\": \"string\", \"age\": \"number\", \"city\": \"string\"}"
}text-to-json
{
"template": "{\"name\": \"string\", \"age\": \"number\", \"city\": \"string\"}",
"text": "name: John Doe\nage: 25\ncity: Beijing"
}项目结构
src/
├── common/
│ ├── constants.ts # 常量定义
│ ├── tools.ts # 工具实现
│ ├── types.ts # 类型定义
│ └── utils.ts # 工具函数
└── index.ts # 主入口文件工具功能
1. group-text-by-json
根据JSON模板生成文本分组提示词,帮助AI将文本按模板结构分组。
2. text-to-json
将分组文本转换为JSON格式,基于原始模板结构。
开发指南
添加新工具
在
src/common/types.ts中定义工具schema在
src/common/tools.ts中实现工具逻辑在
src/common/constants.ts中添加工具名称在
src/index.ts中注册工具
调试技巧
查看日志: 服务器会输出详细的日志信息
SSE连接: 可以通过浏览器访问SSE端点查看实时事件
健康检查: 访问健康检查端点确认服务器状态
热重载: 开发模式下支持代码热重载
常见问题
端口被占用
# 检查端口占用
lsof -i :3005
lsof -i :6274构建错误
# 清理并重新构建
rm -rf build/
pnpm run build依赖问题
# 重新安装依赖
pnpm install技术栈
FastMCP: MCP协议实现框架
Express: HTTP服务器和中间件
TypeScript: 类型安全
SSE: 服务器发送事件
Zod: 数据验证
许可证
ISC
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- Flicense-qualityDmaintenanceA production-ready MCP server built with FastAPI, providing an enhanced tool registry for creating, managing, and documenting AI tools for Large Language Models (LLMs).Last updated34
- Alicense-qualityDmaintenanceA high-performance Model Context Protocol (MCP) server designed for large language models, enabling real-time communication between AI models and applications with support for session management and intelligent tool registration.Last updated2MIT
- Alicense-qualityDmaintenanceA Model Context Protocol (MCP) server that supports STDIO, SSE and Streamable HTTP protocols for AI model interactions.Last updated371MIT
- Flicense-quality-maintenanceA Model Context Protocol (MCP) server implementation that uses Server-Sent Events (SSE) to enable real-time, server-pushed updates between AI models and tools over HTTP connections.Last updated1
Related MCP Connectors
AI Reasoning Cache & Consensus Layer with 11 MCP tools via Streamable HTTP.
MCP server for AI dialogue using various LLM models via AceDataCloud
A comprehensive Model Context Protocol (MCP) server that enables AI assistants to interact with yo…
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
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/jiliangmason/custom-mcp-server'
If you have feedback or need assistance with the MCP directory API, please join our Discord server