当前位置: 首页 > news >正文

MCP 项目标准管理工具 v1.1.0 发布:新增 API 调试功能,助力 AI 辅助开发标准化

MCP 项目标准管理工具 v1.1.0 更新说明

📋 更新概览

MCP 项目标准管理工具 v1.1.0 已发布,本次更新主要新增了 API 调试功能,并进行了多项功能优化。

🚀 核心亮点

🔧 全新 API 调试工具

本次更新的最大亮点是新增了功能强大的 API 调试工具,让 AI 辅助开发更加智能和高效:

  • 智能请求方法控制:默认只允许 GET 请求,确保安全性
  • 登录接口智能识别:自动识别登录接口并使用环境变量配置
  • 自动 Content-Type 检测:支持 JSON、XML、HTML、URL 编码等多种格式
  • 完整的请求/响应记录:所有 API 调用都会被详细记录
  • 灵活的搜索功能:支持按 URL 或描述搜索 API 接口
  • API 接口文档生成:可以要求 AI 工具根据接口列表自动生成文档
  • 批量接口测试:可以要求 AI 工具批量执行 API 测试
  • 智能代码生成:基于接口返回数据,AI 工具可自动生成字段结构、类型定义、相关程序代码或页面组件
  • 数据驱动开发:通过接口调试获取真实数据,让 AI 工具基于实际数据结构进行智能开发

🛡️ 企业级安全增强

  • 请求方法限制:防止误操作,默认只允许安全的 GET 请求
  • 登录认证流程:支持 Bearer Token 自动管理
  • 环境变量控制:所有敏感配置都通过环境变量管理

📋 详细更新内容

🆕 新增功能

1. API 调试工具环境变量支持
# 控制允许的请求方法(默认:GET)
API_DEBUG_ALLOWED_METHODS=GET,POST,PUT,DELETE# 登录接口配置
API_DEBUG_LOGIN_URL=/api/login
API_DEBUG_LOGIN_METHOD=POST
API_DEBUG_LOGIN_BODY={"username":"","password":""}
API_DEBUG_LOGIN_DESCRIPTION=将返回的token保存到调试工具中的公共header
2. 智能登录接口识别
  • 支持完整 URL 和相对路径匹配
  • 自动使用环境变量中的登录配置
  • 非登录接口严格遵循方法限制
3. 动态工具描述
  • 根据环境变量实时显示配置信息
  • 提供详细的使用说明和注意事项

🔧 功能优化

1. 错误处理优化
  • 只有请求相关错误才保存到执行记录
  • 方法验证错误不污染 API 调试日志
  • 更精确的错误分类和处理机制
2. 请求处理改进
  • 自动检测请求体格式并设置正确的 Content-Type
  • 支持 application/x-www-form-urlencoded 格式
  • 改进的 URL 参数处理
3. 代码质量提升
  • 修复了变量作用域问题
  • 优化了 HTTP 状态码判断逻辑
  • 改进了响应数据的处理流程

🛡️ 安全增强

1. 请求方法限制
  • 默认只允许 GET 请求,防止误操作
  • 登录接口例外,可使用环境变量配置的方法
  • 可根据需要灵活开放更多请求方法
2. 配置管理
  • 所有敏感配置通过环境变量管理
  • 配置文件与代码分离
  • 支持通过环境变量动态调整行为

🎯 使用场景

1. API 接口测试

// 设置 API 调试配置
{"baseUrl": "https://api.example.com","headers": {"Authorization": "Bearer your-token"},"list": [{"description": "获取用户信息","url": "/api/user/profile","method": "GET"}]
}

2. 登录认证流程

// 自动登录并获取 Token
{"description": "用户登录","url": "/api/login","method": "POST","body": {"username": "user@example.com","password": "password123"}
}

3. 环境变量配置

# 通过环境变量配置 API 调试参数
API_DEBUG_ALLOWED_METHODS=GET,POST,PUT,DELETE
API_DEBUG_LOGIN_URL=/api/login
API_DEBUG_LOGIN_METHOD=POST
API_DEBUG_LOGIN_BODY={"username":"","password":""}

🛠️ 开发工具集成示例

Cursor 编辑器集成

{"mcpServers": {"project-standards": {"command": "npx","args": ["@liangshanli/mcp-server-project-standards"],"env": {"CONFIG_DIR": "./.setting","API_DEBUG_ALLOWED_METHODS": "GET,POST,PUT,DELETE","API_DEBUG_LOGIN_URL": "/api/login","API_DEBUG_LOGIN_METHOD": "POST","API_DEBUG_LOGIN_BODY": "{\"username\":\"\",\"password\":\"\"}","API_DEBUG_LOGIN_DESCRIPTION": "将返回的token保存到调试工具中的公共header,字段名Authorization,字段值是Bearer token"}}}
}

VS Code 集成

{"mcpServers": {"project-standards": {"command": "npx","args": ["@liangshanli/mcp-server-project-standards"],"env": {"CONFIG_DIR": "./.setting","API_DEBUG_ALLOWED_METHODS": "GET,POST,PUT,DELETE","API_DEBUG_LOGIN_URL": "/api/login","API_DEBUG_LOGIN_METHOD": "POST","API_DEBUG_LOGIN_BODY": "{\"username\":\"\",\"password\":\"\"}","API_DEBUG_LOGIN_DESCRIPTION": "将返回的token保存到调试工具中的公共header,字段名Authorization,字段值是Bearer token"}}}
}

多工具协同配置

{"mcpServers": {"project-standards": {"command": "npx","args": ["@liangshanli/mcp-server-project-standards"],"env": {"CONFIG_DIR": "./.setting","API_DEBUG_ALLOWED_METHODS": "GET,POST,PUT,DELETE","API_DEBUG_LOGIN_URL": "/api/login","API_DEBUG_LOGIN_METHOD": "POST","API_DEBUG_LOGIN_BODY": "{\"username\":\"\",\"password\":\"\"}","API_DEBUG_LOGIN_DESCRIPTION": "将返回的token保存到调试工具中的公共header,字段名Authorization,字段值是Bearer token"}},"mysql": {"command": "npx","args": ["@liangshanli/mcp-server-mysql"],"env": {"MYSQL_HOST": "localhost","MYSQL_PORT": "3306"}},"mssql": {"command": "npx","args": ["@liangshanli/mcp-server-mssqlserver"],"env": {"MSSQL_SERVER": "localhost","MSSQL_DATABASE": "testdb"}}}
}

📊 技术改进

1. 代码质量

  • 修复了 response 变量作用域问题
  • 优化了错误处理逻辑
  • 改进了 HTTP 状态码判断

2. 性能优化

  • 减少了不必要的配置读取
  • 优化了 API 去重逻辑
  • 改进了文件 I/O 操作

3. 可维护性

  • 更清晰的代码结构
  • 更好的错误信息
  • 更完善的日志记录

🔄 升级指南

从 v1.0.0 升级到 v1.1.0

  1. 更新包版本

    npm install @liangshanli/mcp-server-project-standards@1.1.0
    
  2. 配置环境变量(可选):

    # 如果需要使用 API 调试功能
    export API_DEBUG_ALLOWED_METHODS=GET,POST
    export API_DEBUG_LOGIN_URL=/api/login
    export API_DEBUG_LOGIN_METHOD=POST
    export API_DEBUG_LOGIN_BODY={"username":"","password":""}
    
  3. 更新配置文件

    • 新版本会自动创建 api.json 配置文件
    • 现有的 config.json 配置保持不变

兼容性说明

  • ✅ 完全向后兼容 v1.0.0
  • ✅ 现有配置文件无需修改
  • ✅ 所有原有功能正常工作

🎯 未来规划

长期规划

  • 可视化界面:Web 管理界面
  • 团队协作:多用户权限管理
  • 集成更多工具:与更多开发工具集成

📞 支持与反馈

如果您在使用过程中遇到任何问题,或有功能建议,欢迎通过以下方式联系我们:

  • GitHub Issues: 提交问题
  • NPM 包: @liangshanli/mcp-server-project-standards

🙏 致谢

感谢所有用户的支持和反馈,正是有了大家的建议,我们才能不断改进和完善这个工具。v1.1.0 的发布标志着 MCP 项目标准管理工具进入了一个新的发展阶段。


立即体验 v1.1.0

npm install @liangshanli/mcp-server-project-standards@1.1.0

让我们一起让 AI 辅助开发更加标准化和高效!🚀


MCP Project Standards Management Tool v1.1.0 Update Notes

📋 Update Overview

MCP Project Standards Management Tool v1.1.0 has been released. This update mainly adds API debugging functionality and includes multiple feature optimizations.

🚀 Key Highlights

🔧 New API Debugging Tool

The main highlight of this update is the addition of a powerful API Debugging Tool that makes AI-assisted development more intelligent and efficient:

  • Smart Request Method Control: Only allows GET requests by default for security
  • Intelligent Login Interface Recognition: Automatically identifies login interfaces and uses environment variable configuration
  • Automatic Content-Type Detection: Supports JSON, XML, HTML, URL encoding and other formats
  • Complete Request/Response Recording: All API calls are recorded in detail
  • Flexible Search Function: Supports searching API interfaces by URL or description
  • API Interface Documentation Generation: AI tools can automatically generate documentation based on interface lists
  • Batch Interface Testing: AI tools can batch execute API tests
  • Smart Code Generation: Based on interface response data, AI tools can automatically generate field structures, type definitions, related program code or page components
  • Data-Driven Development: Get real data through interface debugging, enabling AI tools to develop intelligently based on actual data structures

🛡️ Enterprise-Grade Security Enhancements

  • Request Method Restrictions: Prevents misoperations, only allows safe GET requests by default
  • Login Authentication Flow: Supports Bearer Token automatic management
  • Environment Variable Control: All sensitive configurations are managed through environment variables

📋 Detailed Update Content

🆕 New Features

1. API Debugging Tool Environment Variable Support
# Control allowed request methods (default: GET)
API_DEBUG_ALLOWED_METHODS=GET,POST,PUT,DELETE# Login interface configuration
API_DEBUG_LOGIN_URL=/api/login
API_DEBUG_LOGIN_METHOD=POST
API_DEBUG_LOGIN_BODY={"username":"","password":""}
API_DEBUG_LOGIN_DESCRIPTION=Save returned token to common headers in debug tool, field name Authorization, field value Bearer token
2. Intelligent Login Interface Recognition
  • Supports full URL and relative path matching
  • Automatically uses login configuration from environment variables
  • Non-login interfaces strictly follow method restrictions
3. Dynamic Tool Description
  • Real-time display of configuration information based on environment variables
  • Provides detailed usage instructions and notes

🔧 Feature Optimizations

1. Error Handling Optimization
  • Only request-related errors are saved to execution records
  • Method validation errors don’t pollute API debugging logs
  • More precise error classification and handling mechanisms
2. Request Processing Improvements
  • Automatically detects request body format and sets correct Content-Type
  • Supports application/x-www-form-urlencoded format
  • Improved URL parameter processing
3. Code Quality Improvements
  • Fixed variable scope issues
  • Optimized HTTP status code judgment logic
  • Improved response data processing flow

🛡️ Security Enhancements

1. Request Method Restrictions
  • Only allows GET requests by default to prevent misoperations
  • Login interface exception, can use methods configured in environment variables
  • Can flexibly open more request methods as needed
2. Configuration Management
  • All sensitive configurations managed through environment variables
  • Configuration files separated from code
  • Supports dynamic behavior adjustment through environment variables

🎯 Use Cases

1. API Interface Testing

// Set API debugging configuration
{"baseUrl": "https://api.example.com","headers": {"Authorization": "Bearer your-token"},"list": [{"description": "Get user information","url": "/api/user/profile","method": "GET"}]
}

2. Login Authentication Flow

// Automatic login and token retrieval
{"description": "User login","url": "/api/login","method": "POST","body": {"username": "user@example.com","password": "password123"}
}

3. Environment Variable Configuration

# Configure API debugging parameters through environment variables
API_DEBUG_ALLOWED_METHODS=GET,POST,PUT,DELETE
API_DEBUG_LOGIN_URL=/api/login
API_DEBUG_LOGIN_METHOD=POST
API_DEBUG_LOGIN_BODY={"username":"","password":""}

🛠️ Development Tool Integration Examples

Cursor Editor Integration

{"mcpServers": {"project-standards": {"command": "npx","args": ["@liangshanli/mcp-server-project-standards"],"env": {"CONFIG_DIR": "./.setting","API_DEBUG_ALLOWED_METHODS": "GET,POST,PUT,DELETE","API_DEBUG_LOGIN_URL": "/api/login","API_DEBUG_LOGIN_METHOD": "POST","API_DEBUG_LOGIN_BODY": "{\"username\":\"\",\"password\":\"\"}","API_DEBUG_LOGIN_DESCRIPTION": "Save returned token to common headers in debug tool, field name Authorization, field value Bearer token"}}}
}

VS Code Integration

{"mcpServers": {"project-standards": {"command": "npx","args": ["@liangshanli/mcp-server-project-standards"],"env": {"CONFIG_DIR": "./.setting","API_DEBUG_ALLOWED_METHODS": "GET,POST,PUT,DELETE","API_DEBUG_LOGIN_URL": "/api/login","API_DEBUG_LOGIN_METHOD": "POST","API_DEBUG_LOGIN_BODY": "{\"username\":\"\",\"password\":\"\"}","API_DEBUG_LOGIN_DESCRIPTION": "Save returned token to common headers in debug tool, field name Authorization, field value Bearer token"}}}
}

Multi-Tool Collaborative Configuration

{"mcpServers": {"project-standards": {"command": "npx","args": ["@liangshanli/mcp-server-project-standards"],"env": {"CONFIG_DIR": "./.setting","API_DEBUG_ALLOWED_METHODS": "GET,POST,PUT,DELETE","API_DEBUG_LOGIN_URL": "/api/login","API_DEBUG_LOGIN_METHOD": "POST","API_DEBUG_LOGIN_BODY": "{\"username\":\"\",\"password\":\"\"}","API_DEBUG_LOGIN_DESCRIPTION": "Save returned token to common headers in debug tool, field name Authorization, field value Bearer token"}},"mysql": {"command": "npx","args": ["@liangshanli/mcp-server-mysql"],"env": {"MYSQL_HOST": "localhost","MYSQL_PORT": "3306"}},"mssql": {"command": "npx","args": ["@liangshanli/mcp-server-mssqlserver"],"env": {"MSSQL_SERVER": "localhost","MSSQL_DATABASE": "testdb"}}}
}

📊 Technical Improvements

1. Code Quality

  • Fixed response variable scope issues
  • Optimized error handling logic
  • Improved HTTP status code judgment

2. Performance Optimization

  • Reduced unnecessary configuration reads
  • Optimized API deduplication logic
  • Improved file I/O operations

3. Maintainability

  • Clearer code structure
  • Better error messages
  • More complete logging

🔄 Upgrade Guide

Upgrading from v1.0.0 to v1.1.0

  1. Update Package Version:

    npm install @liangshanli/mcp-server-project-standards@1.1.0
    
  2. Configure Environment Variables (Optional):

    # If you need to use API debugging functionality
    export API_DEBUG_ALLOWED_METHODS=GET,POST
    export API_DEBUG_LOGIN_URL=/api/login
    export API_DEBUG_LOGIN_METHOD=POST
    export API_DEBUG_LOGIN_BODY={"username":"","password":""}
    
  3. Update Configuration Files:

    • New version will automatically create api.json configuration file
    • Existing config.json configuration remains unchanged

Compatibility Notes

  • ✅ Fully backward compatible with v1.0.0
  • ✅ No need to modify existing configuration files
  • ✅ All existing functionality works normally

🎯 Future Planning

Long-term Goals

  • Visual Interface: Web management interface
  • Team Collaboration: Multi-user permission management
  • Integration with More Tools: Integration with more development tools

📞 Support and Feedback

If you encounter any issues during use or have feature suggestions, please contact us through:

  • GitHub Issues: Submit Issues
  • NPM Package: @liangshanli/mcp-server-project-standards

🙏 Acknowledgments

Thank you for all users’ support and feedback. It is with everyone’s suggestions that we can continuously improve and perfect this tool. The release of v1.1.0 marks the entry of the MCP Project Standards Management Tool into a new development stage.


Experience v1.1.0 Now:

npm install @liangshanli/mcp-server-project-standards@1.1.0

Let’s make AI-assisted development more standardized and efficient together! 🚀

http://www.dtcms.com/a/391378.html

相关文章:

  • Linear Algebra in Competitive Programming
  • Decision Trees vs Neural Networks|决策树 vs 神经网络
  • FreeRTOS——任务管理
  • MSXML4.0是什么?下载安装+常见错误修复一网打尽
  • Claude Code生态
  • Node v22.19 Nest.js 安装 better-sqlite3
  • Android compose Room Sqlite 应用 (注入式)
  • 缓存穿透+缓存雪崩+缓存击穿(解决方法+实战)
  • Docker技术相对于虚拟机技术的优劣势对比!
  • MyBatis框架与参数详解
  • Confluent-Kafka-go 发布超过 1M 消息失败问题解决
  • 数字图像处理-函数矩阵
  • 基于 ST-Link 和 MDK-Keil 的 STM32 程序下载实验
  • 安防监控系统的架构与组成原理
  • 【前端】【threeJs】前端事件偏移问题完整总结
  • web:ts的类型兼容性
  • 黑盒测试:测试用例设计之场景法(流程图法)(模拟用户实际使用软件的场景来设计测试用例,适用于业务流程复杂的系统测试)基本流、备选流
  • Django + Vue3 前后端分离技术实现自动化测试平台从零到有系列 <第二章> 之 平台功能架构整理
  • 神经网络学习笔记14——高效卷积神经网络架构EfficientNet
  • Flutter实现滑动页面停留吸附
  • 【Linux】基本指令介绍
  • 爬虫逆向--Day22Day23--核心实战案例【荔枝网】【WASM学习】----待完成
  • 【软考-系统架构设计师】特定领域软件体系结构(DSSA)
  • idea git使用提示问题处理
  • 数据结构初阶——哈希表的实现(C++)
  • Problem: lab-week3- exercise01 Insertion sort
  • 金融级虚拟机安全:虚拟化平台5大安全风险与国产化防护实践
  • 可视化在智慧城市中的应用
  • C#实现高性能拍照(旋转)与水印添加功能完整指南
  • Pandas 2.x与PyArrow:深入探索内存优化与性能提升技巧