Token导航 LogoToken导航TokenDH.com
MCP Server Etsyapp logo
开发工具stdio官方级别未说明来源级核验

MCP Server Etsyapp

MCP Server

nodemon

MCP项目上下文服务器是一个自动扫描和提供项目代码结构的工具,支持API路由、数据库模式、服务函数和文件结构的实时扫描,适用于开发效率提升。

工具数

4

提示词数

0

GitHub Stars

0

资源数

0
代码分析开发工具JavaScriptClaudeClaude

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

作者 / 组织

JoblessJoe

提供方

JoblessJoe

最后核验

2026/5/17 20:22

运行时

Node.js

快速接入

先看主来源和安装命令,再打开仓库或文档;下面只保留这个条目的关键接入事实。

命令预览

npx nodemon src/index.js

详细介绍

MCP项目上下文服务器

人工智能工具(Claude Code、Roovodev 等)的自动项目文档。

扫描您的代码结构并将其作为 MCP 资源提供:

  • API路线(Express/Fastify Endpunkte)
  • 数据库模式(SQLite Tabellen实时)
  • 服务函数(导出函数)
  • 文件结构(Ordnerstruktur)
  • 体系结构概述(aus CLAUDE.md/README.md)

特性

  • 实时扫描每次请求都会重新扫描文件
  • SQLite支持直接从数据库中读取方案
  • JSDoc解析从评论中提取描述
  • Raspberry Pi 优化没有严重的依赖性
  • PM2就绪可持续运行的生态系统配置

安装

cd ~/projects/mcp-project-context

# Dependencies installieren
npm install

# Test-Start
npm start

重要:MCP服务器如何工作

使用STDIO传输运行MCP服务器 作为 Daemon(如 Web 服务器)。 而是由Claude Code / Roovodev制作 根据需要启动 通过 stdin/stdout 进行通信。

这意味着:

  • 不需要PM2 MCP 服务器本身
  • Claude Code 自动生成进程
  • 这个过程只要你的Claude代码会话就会运行

(可选) PM2 用于开发/测试

如果要手动测试服务器:

# Manueller Test (gibt JSON auf stdout aus)
echo '{"jsonrpc":"2.0","id":1,"method":"resources/list"}' | node src/index.js

配置

config.json

通过死亡 config.json 您的项目:

{
  "projects": [
    {
      "name": "my-project",
      "path": "~/projects/my-project",
      "database": {
        "type": "sqlite",
        "path": "~/projects/my-project/database.db"
      },
      "scan": {
        "routes": ["routes/**/*.js"],
        "services": ["services/**/*.js"],
        "models": ["database/**/*.js"],
        "views": ["views/**/*.hbs"],
        "config": ["config/**/*.js"]
      },
      "ignore": ["node_modules", ".git", "public"]
    }
  ]
}
⚠️ 重要 : config.json 包含您的本地路径,并且应该 登录到repository。而是利用 config.example.json 艾尔斯·沃拉格。

添加更多项目

{
  "projects": [
    { "...": "erstes Projekt" },
    {
      "name": "another-project",
      "path": "~/projects/another-project",
      "database": null,
      "scan": {
        "routes": ["src/routes/**/*.ts"],
        "services": ["src/services/**/*.ts"]
      },
      "ignore": ["node_modules", "dist"]
    }
  ]
}

Claude 代码配置

将服务器添加到您的 Claude Code 配置:

选项 1: 全局配置

编辑 ~/.claude/settings.json:

{
  "mcpServers": {
    "project-context": {
      "command": "node",
      "args": ["~/projects/mcp-project-context/src/index.js"],
      "env": {
        "MCP_CONFIG_PATH": "~/projects/mcp-project-context/config.json"
      }
    }
  }
}

选项2:项目特定

创建 .mcp.json 项目根:

{
  "mcpServers": {
    "project-context": {
      "command": "node",
      "args": ["~/projects/mcp-project-context/src/index.js"]
    }
  }
}

可用资源

配置后,您可以在 Claude Code 中访问这些资源:

资源 URI描述
context://my-project/routes 所有API终端,包括方法,路径,文件
context://my-project/database-schemaSQLite 表和列 (live)
context://my-project/services JSDoc的服务功能
context://my-project/file-structure 作为树的文件夹结构
context://my-project/architecture 高层建筑。

可用工具

工具描述
find_function 按名称查找函数
search_routes 按路径/方法查找路线
search_tables 查找表格/列
refresh_cache 强制重新加载(没有缓存,只有Compact)

使用范例

在Claude Code中,你可以说:

"Zeig mir alle API Routes vom my-project"
→ Claude liest context://my-project/routes

"Welche Tabellen hat die Datenbank?"
→ Claude liest context://my-project/database-schema

"Wo ist die Funktion processOrder definiert?"
→ Claude nutzt das find_function Tool

故障排除

服务器未启动

# Logs prüfen
pm2 logs mcp-project-context --lines 50

# Manuell testen
node ~/projects/mcp-project-context/src/index.js

数据库错误

确保路径在 config.json 正确:

# Prüfen ob DB existiert
ls -la ~/projects/my-project/database.db

资源未找到

  1. 检查项目名称是否包含在URI中 config.json 匹配
  2. 检查扫描模式是否找到文件

许可费勒

# Logs-Ordner erstellen
mkdir -p ~/projects/mcp-project-context/logs
chmod 755 ~/projects/mcp-project-context/logs

发展

# Mit Auto-Reload entwickeln
npm run dev

# Oder mit nodemon
npx nodemon src/index.js

许可证

麻省理工学院

目录标签

目录标签

代码分析开发工具JavaScriptClaude本地部署实时扫描SQLite支持项目文档

支持客户端

Claude

接入字段

传输方式(transport,传输协议)

stdio

鉴权方式(authType,认证方式)

none

运行时(runtime,运行环境)

Node.js

来源包(packageName,安装包名)

nodemon

工具数量(toolCount,工具数)

4

资源数量(resourceCount,资源数)

0

提示词数量(promptCount,提示词数)

0

权限和风险

stdionone部署方式未说明

接入前请确认传输方式、认证方式和部署位置,并根据实际工具能力限制访问范围。

安装前确认

不要直接授予不必要的文件、网络或账号权限;先核对安装命令和配置内容。

来源信息

继续浏览同类 MCP