Starwind UI MCP Server

by starwind-ui
Verified

local-only server

The server can only run on the client’s local machine because it depends on local resources.

Integrations

  • Provides integration with Windsurf (a Codeium product), allowing setup of the MCP server for enhanced AI capabilities when working with Starwind UI components

  • Detects and uses npm package manager for component installation and updates through the get_package_manager tool

  • Uses pnpm as the default package manager for the project, with built-in detection and support for handling Starwind UI components

Starwind UI MCP 服务器

Starwind UI 的模型上下文协议 (MCP) 服务器的 TypeScript 实现,提供帮助开发人员使用 Starwind UI 组件的工具。

快速入门

# Install dependencies pnpm install # Build the TypeScript code pnpm build # Start the server pnpm start

设置你的IDE

设置 IDE 以使用本地 MCP 服务器的说明因 IDE 而异。以下是 Windsurf 的示例:

{ "mcpServers": { "starwind ui": { "command": "node", "args": ["c:\\path\\to\\folder\\starwind-ui-mcp\\dist\\server.js"], "env": {} } } }

详细说明:

什么是 MCP?

模型上下文协议 (MCP) 是一种通过本地服务器扩展 AI 功能的协议。此实现提供了 Starwind UI 专用工具,以增强与 Starwind UI 配合使用时的 AI 助手功能。有关 MCP 本身的更多信息,请访问官方文档

特征

  • 基于工具的架构——模块化设计,可轻松添加新工具
  • Starwind UI 文档工具- 访问 Starwind UI 组件的文档链接
  • 包管理器检测——检测并使用适当的包管理器(npm、yarn、pnpm)
  • LLM 数据获取器- 使用缓存和速率限制检索 LLM 的 Starwind UI 信息
  • TypeScript 实现- 使用 TypeScript 构建,以获得更好的类型安全性和开发人员体验
  • 标准 I/O 传输- 使用 stdio 与 AI 助手进行通信

可用工具

工具名称描述
init_project初始化一个新的 Starwind UI 项目
install_component生成 Starwind UI 组件的安装命令
update_component为 Starwind UI 组件生成更新命令
get_documentation返回 Starwind UI 组件和指南的文档链接
fetch_llm_data从 starwind.dev 获取 LLM 数据(速率受限,带缓存)
get_package_manager检测并返回当前包管理器信息

发展

该项目设置为使用 PNPM 作为包管理器进行开发。如果您不使用 pnpm,则需要使用所需的包管理器命令更新 package.json 文件。

项目结构

src/ ├── config/ # Server configuration │ └── settings.ts # Configuration settings ├── tools/ # MCP tools implementations │ ├── index.ts # Tool registration │ └── *.ts # Individual tool implementations ├── utils/ # Utility functions └── server.ts # Main MCP server implementation

添加新工具

要将您自己的工具添加到服务器:

  1. src/tools/目录中创建一个新的工具文件
  2. src/tools/index.ts中注册该工具
  3. src/config/settings.ts中启用该工具
  4. 使用pnpm build重建服务器
  5. 使用pnpm start重新启动服务器

执照

MIT 许可证 - 有关详细信息,请参阅 LICENSE 文件。

You must be authenticated.

A
security – no known vulnerabilities
A
license - permissive license
A
quality - confirmed to work

TypeScript 服务器可增强 AI 助手与 Starwind UI 组件协同工作的能力,提供项目初始化、组件安装、文档访问等工具。

  1. Quick Start
    1. Setup Your IDE
  2. What is MCP?
    1. Features
      1. Available Tools
        1. Development
          1. Project Structure
            1. Adding New Tools
              1. License
                ID: 3931n8mhge