Download the PHP package hi/mcp-server without Composer
On this page you can find all versions of the php package hi/mcp-server. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Table of contents
Download hi/mcp-server
More information about hi/mcp-server
Files in hi/mcp-server
Download hi/mcp-server
More information about hi/mcp-server
Files in hi/mcp-server
Vendor hi
Package mcp-server
Short Description Model Context Protocol (MCP) Server for PHP - Expose your PHP codebase API to AI assistants
License MIT
Package mcp-server
Short Description Model Context Protocol (MCP) Server for PHP - Expose your PHP codebase API to AI assistants
License MIT
Please rate this library. Is it a good library?
Informations about the package mcp-server
PHP MCP Server
为 AI 助手(如 Claude Code)提供 PHP 代码库 API 文档的 Model Context Protocol (MCP) 服务器。
特性
- 完整 MCP 2.0 协议支持:JSON-RPC 2.0 标准
- 静态文档生成:基于 PHP-Parser 的源码分析,生成 Markdown 文档
- API + 指南融合:自动关联 API 文档与使用指南
- 智能搜索:关键词索引,快速定位类、方法、文档
- 模块聚合:自动识别和组织模块结构
- 信号处理:优雅关闭支持 (SIGINT, SIGTERM, SIGHUP)
安装
快速开始
1. 生成文档
2. 启动 MCP 服务器
3. Claude Code 集成
命令行选项
mcp-generate(文档生成器)
mcp-server(MCP 服务器)
生成的文档结构
可用的 MCP 工具
| 工具 | 描述 |
|---|---|
list_modules |
列出所有模块 |
get_module |
获取模块详细信息 |
list_classes |
列出所有类(支持命名空间过滤) |
list_interfaces |
列出所有接口 |
list_attributes |
列出所有 PHP 8+ Attributes |
get_class |
获取类/接口/Attribute 的完整文档 |
get_guide |
获取使用指南文档 |
search |
搜索类、方法、指南 |
get_statistics |
获取框架统计信息 |
可用的 MCP 资源
| 资源 | 描述 |
|---|---|
hi://manifest |
完整的框架清单(JSON) |
hi://statistics |
框架统计信息 |
hi://module/{name} |
特定模块的文档 |
可用的 MCP 提示
| 提示 | 描述 |
|---|---|
explain_class |
解释类的功能和用法 |
find_implementation |
查找接口或抽象类的实现 |
Claude Code 使用示例
集成后,你可以这样使用:
系统要求
- PHP 8.2+
- ext-json
- ext-tokenizer
- ext-pcntl(可选,用于信号处理)
架构
两阶段工作流
核心组件
开发
许可证
MIT License
致谢
基于 Hi Framework 构建。
All versions of mcp-server with dependencies
PHP Build Version
Package Version
Requires
php Version
>=8.2
ext-json Version *
ext-tokenizer Version *
ext-json Version *
ext-tokenizer Version *
The package hi/mcp-server contains the following files
Loading the files please wait ...