Local Scanner MCP Server
Okay, here are a few possible translations of "MCP server for scanning local code and localhost URLs," depending on the specific nuance you want to convey. I'll also include some context about what "MCP" might mean, as it's ambiguous. **Understanding "MCP"** "MCP" is an acronym that could stand for several things. Without more context, it's difficult to know the *exact* meaning. Here are a few possibilities, and I'll tailor the translations accordingly: * **Most Likely: Malware/Code Protection (or similar):** This is the most likely interpretation given the context of scanning code and URLs. It suggests a server designed to detect malicious code or vulnerabilities. * **Less Likely: Minecraft Coder Pack (MCP):** This is a tool for decompiling and re-compiling Minecraft code. It's *unlikely* to be the meaning here, but I'll include a translation just in case. * **Least Likely: Other meanings:** MCP could stand for many other things (e.g., Master Control Program, Microsoft Certified Professional). These are highly unlikely in this context. **Translations (Assuming MCP = Malware/Code Protection)** Here are a few options, ranked by how common and natural they sound: **Option 1 (Most Common & General):** * **Chinese:** 用于扫描本地代码和 localhost URL 的 MCP 服务器 (Yòng yú sǎo miáo běndì dàimǎ hé localhost URL de MCP fúwùqì) * **Pinyin:** Yòng yú sǎo miáo běndì dàimǎ hé localhost URL de MCP fúwùqì * **Explanation:** This is a direct translation. It uses "MCP" as is, assuming the target audience understands the acronym (or you will define it elsewhere). "用于 (yòng yú)" means "used for" or "for the purpose of." "扫描 (sǎo miáo)" means "scan." "本地代码 (běndì dàimǎ)" means "local code." "服务器 (fúwùqì)" means "server." **Option 2 (More Explicit - Malware/Code Protection):** * **Chinese:** 用于扫描本地代码和 localhost URL 的恶意代码/代码保护服务器 (Yòng yú sǎo miáo běndì dàimǎ hé localhost URL de èyì dàimǎ/dàimǎ bǎohù fúwùqì) * **Pinyin:** Yòng yú sǎo miáo běndì dàimǎ hé localhost URL de èyì dàimǎ/dàimǎ bǎohù fúwùqì * **Explanation:** This replaces "MCP" with a more descriptive phrase: "恶意代码/代码保护 (èyì dàimǎ/dàimǎ bǎohù)," which means "malicious code/code protection." The "/" indicates "or." This is useful if you want to be very clear about the server's purpose. **Option 3 (Focus on Vulnerability Scanning):** * **Chinese:** 用于扫描本地代码和 localhost URL 的漏洞扫描服务器 (Yòng yú sǎo miáo běndì dàimǎ hé localhost URL de lòudòng sǎo miáo fúwùqì) * **Pinyin:** Yòng yú sǎo miáo běndì dàimǎ hé localhost URL de lòudòng sǎo miáo fúwùqì * **Explanation:** This focuses on *vulnerability* scanning. "漏洞扫描 (lòudòng sǎo miáo)" means "vulnerability scanning." This is appropriate if the server's primary function is to find security weaknesses. **Option 4 (More Natural Phrasing - Implies Purpose):** * **Chinese:** 一款用于扫描本地代码和 localhost URL 的 MCP 服务器 (Yī kuǎn yòng yú sǎo miáo běndì dàimǎ hé localhost URL de MCP fúwùqì) * **Pinyin:** Yī kuǎn yòng yú sǎo miáo běndì dàimǎ hé localhost URL de MCP fúwùqì * **Explanation:** Adding "一款 (yī kuǎn)" which means "a" or "one type of" makes the sentence flow a little more naturally. **Translation (Assuming MCP = Minecraft Coder Pack - Highly Unlikely):** * **Chinese:** 用于扫描本地代码和 localhost URL 的 Minecraft Coder Pack (MCP) 服务器 (Yòng yú sǎo miáo běndì dàimǎ hé localhost URL de Minecraft Coder Pack (MCP) fúwùqì) * **Pinyin:** Yòng yú sǎo miáo běndì dàimǎ hé localhost URL de Minecraft Coder Pack (MCP) fúwùqì * **Explanation:** This is a direct translation, keeping the English name "Minecraft Coder Pack" and the acronym "MCP." It's unlikely this is the correct meaning, but included for completeness. **Recommendation:** I recommend **Option 1** or **Option 2** (if you want to be very explicit). If the server is specifically for finding vulnerabilities, **Option 3** is a good choice. **Option 4** is a slight improvement in naturalness. **Important Considerations:** * **Target Audience:** Who are you writing for? If they are familiar with the acronym "MCP" in the context of code security, then using it directly is fine. If not, use a more descriptive phrase like in Option 2 or 3. * **Context:** Where will this translation be used? If it's in documentation, you can define "MCP" the first time you use it. * **Specificity:** What *specifically* does the server do? Does it focus on malware detection, vulnerability scanning, or something else? Tailor the translation to reflect the server's primary function. To give you the *best* translation, please provide more context about what "MCP" means in your specific case.
treaties-ai
README
本地扫描器 MCP 服务器
一个用于扫描本地代码和 localhost URL 的模型上下文协议 (MCP) 服务器。此服务器提供用于验证代码、捕获屏幕截图和分析在 localhost 上运行的网页的工具。
概述
本地扫描器 MCP 服务器扩展了 AI 助手与本地运行的 Web 应用程序和代码文件交互的能力。它弥合了 AI 和本地开发环境之间的差距,使 AI 助手能够:
- 测试和调试本地运行的 Web 应用程序
- 捕获屏幕截图以进行视觉验证
- Lint 代码文件以确保质量和符合标准
- 验证 HTML 的可访问性和符合标准
此服务器对于使用 Cline (VSCode) 或 Cascade (WindSurf) 等 AI 助手并希望利用 AI 功能进行本地开发任务的开发人员特别有用。
功能
该服务器提供以下工具:
1. scan_localhost
访问 localhost URL,捕获控制台日志,并检查运行时错误。
参数:
url
(必需): 要扫描的 Localhost URL(必须以 http://localhost 或 https://localhost 开头)waitTime
(可选): 页面加载后等待的时间(以毫秒为单位)(默认值:1000)actions
(可选): 要在页面上执行的操作列表,例如:- Click:
{ "type": "click", "selector": "#button-id" }
- Type:
{ "type": "type", "selector": "#input-id", "text": "Hello World" }
- Wait:
{ "type": "wait", "time": 2000 }
- Click:
示例:
{
"url": "http://localhost:3000",
"waitTime": 2000,
"actions": [
{ "type": "click", "selector": "#login-button" },
{ "type": "type", "selector": "#username", "text": "testuser" },
{ "type": "type", "selector": "#password", "text": "password" },
{ "type": "click", "selector": "#submit-button" },
{ "type": "wait", "time": 1000 }
]
}
2. screenshot_localhost
拍摄 localhost URL 的屏幕截图。
参数:
url
(必需): 要截图的 Localhost URL(必须以 http://localhost 或 https://localhost 开头)fullPage
(可选): 是否截取完整页面屏幕截图(默认值:false)waitTime
(可选): 页面加载后等待的时间(以毫秒为单位)(默认值:1000)
示例:
{
"url": "http://localhost:3000/dashboard",
"fullPage": true,
"waitTime": 2000
}
3. lint_code
Lint JavaScript、TypeScript 或 CSS 代码文件。
参数:
filePath
(必需): 要 lint 的文件的路径language
(可选): 文件的语言(默认值:从文件扩展名自动检测)- 选项: "javascript", "typescript", "css"
示例:
{
"filePath": "/path/to/your/file.js",
"language": "javascript"
}
4. validate_html
验证 HTML 内容或 URL 是否符合标准。
参数:
source
(必需): 要验证的 HTML 内容或 URLisUrl
(可选): 源是否为 URL(默认值:false)
示例:
{
"source": "<html><head><title>Test</title></head><body><h1>Hello World</h1></body></html>",
"isUrl": false
}
或者对于 URL:
{
"source": "http://localhost:3000",
"isUrl": true
}
安装
- 克隆存储库:
git clone https://github.com/treaties-ai/local-scanner-mcp.git cd local-scanner-mcp
- 安装依赖项:
npm install
- 构建项目:
npm run build
- 启动服务器:
npm start
与 MCP 客户端一起使用
此服务器实现了模型上下文协议 (MCP),可以与任何 MCP 客户端一起使用。
对于 VSCode/Cline
编辑 MCP 设置文件,位于 ~/Library/Application Support/Code/User/globalStorage/saoudrizwan.claude-dev/settings/cline_mcp_settings.json
:
{
"mcpServers": {
"local-scanner": {
"command": "node",
"args": ["/Users/your_username/Documents/Cline/MCP/local-scanner-mcp/build/index.js"],
"disabled": false,
"autoApprove": []
}
}
}
对于 WindSurf/Cascade
编辑 WindSurf 配置文件,位于 ~/Library/Application Support/WindSurf/windsurf_config.json
:
{
"mcpServers": {
"local-scanner": {
"command": "node",
"args": ["/Users/your_username/Documents/WindSurf/MCP/local-scanner-mcp/build/index.js"],
"disabled": false,
"autoApprove": []
}
}
}
将 your_username
替换为两个配置中的实际用户名。
开发
要添加新工具或增强现有工具:
- 为新工具参数添加验证函数
- 更新
setupToolHandlers
方法中的工具列表 - 实现新工具的处理函数
- 更新请求处理程序以处理新工具
- 构建并测试服务器
许可证
MIT
推荐服务器
Playwright MCP Server
一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。
Magic Component Platform (MCP)
一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。
MCP Package Docs Server
促进大型语言模型高效访问和获取 Go、Python 和 NPM 包的结构化文档,通过多语言支持和性能优化来增强软件开发。
Claude Code MCP
一个实现了 Claude Code 作为模型上下文协议(Model Context Protocol, MCP)服务器的方案,它可以通过标准化的 MCP 接口来使用 Claude 的软件工程能力(代码生成、编辑、审查和文件操作)。
@kazuph/mcp-taskmanager
用于任务管理的模型上下文协议服务器。它允许 Claude Desktop(或任何 MCP 客户端)在基于队列的系统中管理和执行任务。
mermaid-mcp-server
一个模型上下文协议 (MCP) 服务器,用于将 Mermaid 图表转换为 PNG 图像。
Jira-Context-MCP
MCP 服务器向 AI 编码助手(如 Cursor)提供 Jira 工单信息。

Linear MCP Server
一个模型上下文协议(Model Context Protocol)服务器,它与 Linear 的问题跟踪系统集成,允许大型语言模型(LLM)通过自然语言交互来创建、更新、搜索和评论 Linear 问题。

Sequential Thinking MCP Server
这个服务器通过将复杂问题分解为顺序步骤来促进结构化的问题解决,支持修订,并通过完整的 MCP 集成来实现多条解决方案路径。
Curri MCP Server
通过管理文本笔记、提供笔记创建工具以及使用结构化提示生成摘要,从而实现与 Curri API 的交互。