定制 armandsar/laravel-mcp-documentation-generator 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

armandsar/laravel-mcp-documentation-generator

Composer 安装命令:

composer require armandsar/laravel-mcp-documentation-generator

包简介

Generate rich HTML documentation for Laravel MCP web servers.

README 文档

README

Latest Version on Packagist GitHub Tests Action Status GitHub Code Style Action Status

Generate HTML documentation for Laravel MCP servers.

Installation

You can install the package via composer:

composer require armandsar/laravel-mcp-documentation-generator

You can publish the config file with:

php artisan vendor:publish --tag="mcp-documentation-generator-config"

Contents of the published config file:

return [
    'enabled' => env('MCP_DOCS_ENABLED', false),

    'url' => '/docs/mcp',

    'middleware' => [],

    'servers' => [],
];

Usage

Register one or more Laravel MCP web servers in your application:

use App\Mcp\CompanyMcpServer;
use App\Mcp\OtherMcpServer;
use Laravel\Mcp\Facades\Mcp;

Mcp::web('/mcp/company', CompanyMcpServer::class);
Mcp::web('/mcp/other', OtherMcpServer::class);

Enable the route and open /docs/mcp:

MCP_DOCS_ENABLED=true

The readable schema tables cover the common top-level fields, required flags, enums, arrays, and simple union types. The full raw JSON schemas are always available beside the readable tables for nested or advanced schema shapes.

To restrict the docs page to specific servers, configure servers with server classes. Leave it empty to include every discovered web MCP server:

'servers' => [
    CompanyMcpServer::class,
],

Keep the route disabled in environments where it should not be public, or add middleware to protect it:

'middleware' => ['auth'],

Testing

composer test

Credits

License

The MIT License (MIT). Please see License File for more information.

统计信息

  • 总下载量: 79
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 1
  • 点击次数: 1
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 0
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2026-05-28

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固