
quantgeekdev/mcp-framework
Developer toolsこのページは AI により自動翻訳されています。技術的な詳細は原文をご確認ください。 原文を見る
Typescript MCPフレームワーク
概要
MCP-Frameworkは、TypeScript上でモデルコンテキストプロトコル(MCP)サーバーを優雅に構築するためのフレームワークです。 MCP-Frameworkは、ツール、リソース、プロンプトのディレクトリベースの自動発見を備えた、箱から出してアーキテクチャを提供します。強力なMCP抽象化を使って、ツール、リソース、プロンプトを洗練された方法で定義しましょう。私たちのCLIは、自社のMCPサーバーの導入を非常に簡単にします - 🛠️ ツール、リソース、プロンプトの自動検出と読み込み - 複数トランスポートサポート(stdio、SSE、HTTPストリーム) - TypeScript優先開発と完全な型安全 - 公式MCP SDK上構築 - ツール、プロンプト、リソースの使いやすいベースクラス - SSEエンドポイントの標準外認証(OAuth 2.1、JWT、APIキー) 以下のプロジェクトおよびサービスはMCPフレームワークを用いて構築されています: - ### tip.md AIアシスタントがチャットインターフェースから直接コンテンツクリエイターにチップを送るのを支援する暗号通貨チップサービス。
概要(AI 翻訳)
MCP-Frameworkは、TypeScript上でモデルコンテキストプロトコル(MCP)サーバーを優雅に構築するためのフレームワークです。
MCP-Frameworkは、ツール、リソース、プロンプトのディレクトリベースの自動発見を備えた、箱から出してアーキテクチャを提供します。強力なMCP抽象化を使って、ツール、リソース、プロンプトを洗練された方法で定義しましょう。私たちのCLIは、自社のMCPサーバーの導入を非常に簡単にします
特徴
- 🛠️ ツール、リソース、プロンプトの自動発見と読み込み
- 複数トランスポートサポート(stdio、SSE、HTTPストリーム)
- TypeScript - 完全な型安全開発
- 公式MCP SDK上に構築されています
- ツール、プロンプト、リソースの使いやすいベースクラス
- SSEエンドポイント向けの標準認証(OAuth 2.1、JWT、APIキー)
MCPフレームワークで構築されたプロジェクト
以下のプロジェクトおよびサービスはMCPフレームワークを用いて構築されています:
AIアシスタントがチャットインターフェースから直接コンテンツクリエイターに暗号通貨のチップを送るのを支援する暗号通貨チップサービスです。MCPサービスでは以下の機能が可能になっています:
- ユーザーのウォレットタイプ確認
- ユーザーやエージェントが完了するための暗号通貨のヒントを準備する
このページは AI により自動翻訳されています。技術的な詳細は原文をご確認ください。
README
以下は原文 README の抜粋です。原文を見る。
MCP Framework
MCP-Framework is a framework for building Model Context Protocol (MCP) servers elegantly in TypeScript.
MCP-Framework gives you architecture out of the box, with automatic directory-based discovery for tools, resources, and prompts. Use our powerful MCP abstractions to define tools, resources, or prompts in an elegant way. Our cli makes getting started with your own MCP server a breeze
Features
- 🛠️ Automatic discovery and loading of tools, resources, and prompts
- Multiple transport support (stdio, SSE, HTTP Stream)
- TypeScript-first development with full type safety
- Built on the official MCP SDK
- Easy-to-use base classes for tools, prompts, and resources
- Out of the box authentication for SSE endpoints (OAuth 2.1, JWT, API Key)
Projects Built with MCP Framework
The following projects and services are built using MCP Framework:
A crypto tipping service that enables AI assistants to help users send cryptocurrency tips to content creators directly from their chat interface. The MCP service allows for:
- Checking wallet types for users
- Preparing cryptocurrency tips for users/agents to complete Setup instructions for various clients (Cursor, Sage, Claude Desktop) are available in their MCP Server documentation.
Support our work
Read the full docs here
Creating a repository with mcp-framework
Using the CLI (Recommended)
# Install the framework globally
npm install -g mcp-framework
# Create a new MCP server project
mcp create my-mcp-server
# Navigate to your project
cd my-mcp-server
# Your server is ready to use!
CLI Usage
The framework provides a powerful CLI for managing your MCP server projects:
Project Creation
# Create a new project
mcp create
# Create a new project with the new EXPERIMENTAL HTTP transport
Heads up: This will set cors allowed origin to "*", modify it in the index if you wish
mcp create --http --port 1337 --cors
Options:
–http: Use HTTP transport instead of default stdio
–port : Specify HTTP port (default: 8080)
–cors: Enable CORS with wildcard (*) access
Adding a Tool
# Add a new tool
mcp add tool price-fetcher
Building and Validation
The framework provides comprehensive validation to ensure your tools are properly documented and functional:
# Build with automatic validation (recommended)
npm run build
# Build with custom validation settings
MCP_SKIP_TOOL_VALIDATION=false npm run build # Force validation (default)
MCP_SKIP_TOOL_VALIDATION=true npm run build # Skip validation (not recommended)
Validating Tools
# Validate all tools have proper descriptions (for Zod schemas)
mcp validate
インストール
npx ${projectName}設定
{
"mcpServers": {
"${projectName}": {
"command": "node",
"args":["/absolute/path/to/${projectName}/dist/index.js"]
}
}
}