Cover image
Try Now
2025-04-14

使用AI,轻松安装作曲家PHP软件包。

3 years

Works with Finder

0

Github Watches

0

Github Forks

0

Github Stars

🎼 Composer MCP Server (Unofficial)

Composer Logo

Supercharge your PHP development workflow with AI-powered Composer package installation

FeaturesSetupUsageHow It WorksContributing


✨ Features

  • One-Command Package Installation: Install any Composer package with a single command
  • Intelligent Setup Instructions: Automatically extracts setup steps from package READMEs
  • Comprehensive Package Support: Built-in knowledge of popular Laravel and Symfony packages
  • Time-Saving Guidance: Never miss a critical post-installation step again

🚀 Setup

Getting started with the Composer MCP Server is simple. Just add it to your MCP client configuration (Claude Desktop, Windsurf, Cursor, etc.):

{
  "mcpServers": {
    "composer-ai": {
      "command": "npx",
      "args": [
        "composer-mcp-server"
      ]
    }
  }
}

That's it! The NPX command will automatically download and run the Composer MCP Server when needed, with no manual installation required.

🔧 Usage

Once configured, you can interact with your AI assistant in a natural way to install Composer packages:

You: Composer AI install laravel/sanctum

AI: [Analyzes the package and provides installation instructions]
To install laravel/sanctum, run the following command:

`composer require laravel/sanctum`

After installation, complete these additional setup steps:
- Run `php artisan vendor:publish --provider="Laravel\Sanctum\SanctumServiceProvider"` to publish configuration
- Run `php artisan migrate` to create the required tables

Behind the scenes, the AI assistant is using the install_package tool:

install_package(package="laravel/sanctum", version="^3.0")

The tool will:

  1. Generate the correct Composer command to install the package
  2. Analyze the package's README to extract setup instructions
  3. Provide you with a comprehensive guide to complete the installation

🧠 How It Works

The Composer MCP Server leverages the Model Context Protocol (MCP) to extend AI assistants with PHP Composer capabilities. When you ask your AI assistant to install a package, the following happens:

  1. Your request ("Composer AI install {package_name}") is recognized by the AI
  2. The AI calls the install_package tool provided by the MCP server
  3. The MCP server checks Packagist for the package information
  4. It fetches the package's README from GitHub or GitLab
  5. It intelligently parses the README to identify installation and setup instructions
  6. If the README doesn't contain clear instructions, it falls back to built-in knowledge for common packages
  7. The formatted installation and setup instructions are returned to the AI
  8. The AI presents this information to you in a helpful, conversational format

This entire process happens in seconds, saving you from having to search documentation and figure out post-installation steps on your own.

🤝 Contributing

Contributions are welcome! If you'd like to contribute to the project:

# Clone the repository
git clone https://github.com/jordandalton/composer-mcp-server.git

# Navigate to the project directory
cd composer-mcp-server

# Install dependencies and build
yarn install && yarn build

Here's how you can help:

  • Add support for more PHP packages in the fallback system
  • Improve the README parsing algorithm
  • Enhance error handling and user feedback
  • Expand the tool's capabilities

📄 License

This project is licensed under the MIT License - see the LICENSE file for details.

📱 Connect

If you find this tool helpful, feel free to connect with the creator:


Made with ❤️ for PHP developers

相关推荐

  • av
  • 毫不费力地使用一个命令运行LLM后端,API,前端和服务。

  • 1Panel-dev
  • 🔥1Panel提供了直观的Web接口和MCP服务器,用于在Linux服务器上管理网站,文件,容器,数据库和LLMS。

  • WangRongsheng
  • 🧑‍🚀 llm 资料总结(数据处理、模型训练、模型部署、 o1 模型、mcp 、小语言模型、视觉语言模型)|摘要世界上最好的LLM资源。

  • Byaidu
  • PDF科学纸翻译带有保留格式的pdf -基于ai完整保留排版的pdf文档全文双语翻译

  • rulego
  • ⛓️Rulego是一种轻巧,高性能,嵌入式,下一代组件编排规则引擎框架。

  • sigoden
  • 使用普通的bash/javascript/python函数轻松创建LLM工具和代理。

  • hkr04
  • 轻巧的C ++ MCP(模型上下文协议)SDK

  • RockChinQ
  • 😎简单易用、🧩丰富生态 -大模型原生即时通信机器人平台| 适配QQ / 微信(企业微信、个人微信) /飞书 /钉钉 / discord / telegram / slack等平台| 支持chatgpt,deepseek,dify,claude,基于LLM的即时消息机器人平台,支持Discord,Telegram,微信,Lark,Dingtalk,QQ,Slack

  • dmayboroda
  • 带有可配置容器的本地对话抹布

  • paulwing
  • 使用MCP服务创建的测试存储库

    Reviews

    3 (6)
    Avatar
    user_siDSTKBb
    2025-04-23

    I've been using the composer-mcp-server by JordanDalton, and it has truly enhanced my workflow. The server is reliable, user-friendly, and offers seamless integration for my projects. It's evident that a lot of thought went into its development. Highly recommend to anyone in need of a robust server solution!

    Avatar
    user_zbkRTZJw
    2025-04-23

    As a dedicated user of composer-mcp-server by JordanDalton, I must say it is an exceptional tool for managing and composing workflows. The user-friendly interface and robust functionality make it a valuable asset for any developer. The seamless integration and efficient processes have significantly improved our productivity. Highly recommended!

    Avatar
    user_JxsGC09g
    2025-04-23

    As a dedicated user of the composer-mcp-server developed by JordanDalton, I am extremely impressed with its seamless integration and robust performance. This server application provides an unparalleled user experience with its intuitive interface and efficient functionality. It has significantly streamlined our operations, making it an indispensable tool for our team. Highly recommend trying this out!

    Avatar
    user_Kt4gzuIE
    2025-04-23

    I've been using composer-mcp-server by JordanDalton and I'm thoroughly impressed! The server runs smoothly and the setup process is a breeze. It has significantly streamlined my development workflow and the integration capabilities are top-notch. Highly recommend it for anyone looking to enhance their MCP applications!

    Avatar
    user_sfK233UW
    2025-04-23

    As a dedicated user of composer-mcp-server by JordanDalton, I am extremely impressed with its functionality and ease of use. It has remarkably optimized our workflow and its seamless integration is a game-changer for our team. Highly recommend!

    Avatar
    user_Jx21WYDl
    2025-04-23

    The composer-mcp-server by JordanDalton is an outstanding product! It has significantly streamlined my workflow and improved efficiency in managing multiple projects. The intuitive interface and robust functionality make it a must-have tool for any developer. Highly recommended!