使用说明
MCPverse
这是什么?
为不同的模型上下文协议(MCP)服务器查找设置说明和配置细节(如环境变量)可能很困难。这个项目解决了这个问题。
它提供了一个集中、简单的列表(mcpverse.json)高质量的MCP服务器,具有:
- 易于查找设置说明。
- 明确所需变量的信息。
- 官方文件链接。
特性
- 简单数据: 服务器信息存储在
mcpverse.json. - 网页: 打开
index.html在本地浏览服务器。 - NPM包: 在JavaScript/Node.js项目中使用这些数据。
通过npm安装
npm install mcpverse
# or
yarn add mcpverse
如何使用(JavaScript/Node.js)
通过npm安装后,您可以在代码中要求注册表:
// Import the registry functions
const mcpverse = require('mcpverse');
// --- Example 1: List all available MCP server names ---
const allMcps = mcpverse.listMcps();
console.log("Available MCPs:");
allMcps.forEach(mcp => console.log(`- ${mcp.name} (ID: ${mcp.id})`));
// Output:
// Available MCPs:
// - Prisma MCP Server (ID: prisma)
// - Puppeteer MCP Server (ID: puppeteer)
// - Slack MCP Server (ID: slack)
// - Supabase MCP Server (ID: supabase)
// --- Example 2: Get full details for a specific MCP ---
const puppeteerDetails = mcpverse.getMcp('puppeteer');
if (puppeteerDetails) {
console.log("\nPuppeteer Details:", JSON.stringify(puppeteerDetails, null, 2));
}
// --- Example 3: Get required variables for Slack ---
const slackInfo = mcpverse.getInstallationInfo('slack');
if (slackInfo && slackInfo.variables) {
console.log("\nSlack requires the following variables:");
for (const [varName, details] of Object.entries(slackInfo.variables)) {
console.log(`- ${varName}: ${details.description}`);
}
}
// Output:
// Slack requires the following variables:
// - SLACK_BOT_TOKEN: Your Slack bot token (starts with xoxb-).
// - SLACK_TEAM_ID: Your Slack workspace Team ID (starts with T).
// - SLACK_CHANNEL_IDS: Comma-separated list of Slack channel IDs to monitor.
// --- Example 4: Generate the full install command for Supabase ---
// Imagine you have your token in an environment variable
const myToken = process.env.SUPABASE_ACCESS_TOKEN || 'your-token-placeholder';
const supabaseCommand = mcpverse.generateFullCommand('supabase', {
SUPABASE_ACCESS_TOKEN: myToken
});
if (supabaseCommand) {
console.log("\nTo run Supabase MCP Server:");
console.log(supabaseCommand);
}
// Example Output:
// To run Supabase MCP Server:
// npx -y @supabase/mcp-server-supabase@latest --access-token "your-token-placeholder"
看 index.js 所有可用功能。
web界面
如果克隆此存储库,则可以打开 index.html 直接在您的网络浏览器中创建文件。它从以下位置加载数据 mcpverse.json 并显示了每台服务器的卡及其详细信息、安装命令和所需变量。
数据格式(mcpverse.json)
注册表是一个JSON对象。每个密钥都是一个服务器ID(如 "prisma").该值是一个描述服务器的对象:
{
"id": "string", // Unique ID (same as key)
"name": "string", // Display name
"description": "string", // What it does
"official": "boolean", // Is it official?
"category": "string", // e.g., "Database"
"readmeUrl": "string | null", // Link to docs
"brand": {
"logoUrl": "string | null" // Logo image URL
},
"installation": {
"type": "string", // How to install (e.g., "npx")
"command": "string", // Base command (e.g., "npx")
"args": ["string"], // Command arguments (use <VAR_NAME> for placeholders)
"variables": { // Optional: Required variables
"VAR_NAME": {
"description": "string",
"secret": "boolean", // Is it sensitive?
"placeholder": "string | null" // Example format
}
}
}
}
贡献
想要添加或更新服务器吗?
- 分叉 这个仓库。
- 编辑
mcpverse.json(添加/更新条目,遵循格式)。 - 创建拉取请求.
请确保添加的服务器稳定,并有良好的文档。
