dino-mcp
📋 目次
Related MCP server: Relay
🦕 概要 — なぜ作ったのか
dino-mcp は、Go で書かれた Model Context Protocol (MCP) のリファレンス実装であり、最新の MCP スタックの全レイヤーを示しています。
レイヤー | 実装 | 重要性 |
トランスポート |
| Claude Desktop と Web ブラウザの両方で動作 |
MCP Apps |
| Claude Desktop の iframe 内で対話型 HTML UI を実現 |
ツール |
| 型付けされた Go ハンドラ、構造化 JSON 結果 |
リソース |
| 自己完結型の約11MBバイナリ、実行時に依存関係ゼロ |
MCP サーバーをゼロから構築する場合、MCP Apps プロトコルを学ぶ場合、あるいは Go — Gin — ext-apps SDK 統合の設計図が必要な場合、このプロジェクトが役立ちます。
⚡ クイックスタート
# Clone & enter
git clone https://github.com/shennawardana23/mcp-dino.git && cd mcp-dino
# Build & run in one shot (≈2 seconds)
make build-fast && make dev-http
# Open the standalone dashboard
open http://localhost:9010/dashboard=== dino-mcp server ===
Transport: http
Listening on :9010
[GIN] 2026/06/21 - 12:30:00 | 200 | 4.2ms | ::1 | GET "/dashboard"
[GIN] 2026/06/21 - 12:30:01 | 200 | 2.1ms | ::1 | GET "/api/dinosaurs"🏗 アーキテクチャ概要
flowchart TB
subgraph CLI["CLI Layer"]
STDIO["stdio subcommand"]
HTTP["http subcommand"]
end
subgraph SERVER["Server (internal/server/)"]
GIN["Gin Router :9010"]
MCPH["MCP StreamableHTTPHandler"]
CORS["CORS Middleware"]
TOOLS["Tools: think · ask · dashboard"]
RES["Resources: //go:embed HTML"]
end
subgraph UI["View (ui/src/)"]
APP["ext-apps App class"]
POST["postMessage protocol"]
end
subgraph FALLBACK["Standalone Fallback"]
DASH["/dashboard (HTML)"]
API["/api/dinosaurs (JSON)"]
end
CLI --> GIN
GIN --> CORS
CORS --> MCPH
MCPH --> TOOLS
TOOLS --> RES
RES --> APP
APP --> POST
MCPH -.->|"MCP Apps"| APP
GIN -.->|"direct route"| DASH
GIN -.->|"direct route"| API
style CLI fill:#1a1a2e,color:#e0e0e0,stroke:#2d2a44
style SERVER fill:#1a1a2e,color:#e0e0e0,stroke:#2d2a44
style UI fill:#1a1a2e,color:#e0e0e0,stroke:#2d2a44
style FALLBACK fill:#1a1a2e,color:#e0e0e0,stroke:#2d2a44
style STDIO fill:#2d2a44,color:#a78bfa
style HTTP fill:#2d2a44,color:#a78bfa
style GIN fill:#0099e5,color:#fff
style MCPH fill:#a78bfa,color:#fff
style TOOLS fill:#22c55e,color:#fff
style RES fill:#22c55e,color:#fff
style APP fill:#facc15,color:#000
style POST fill:#facc15,color:#000
style DASH fill:#f87171,color:#fff
style API fill:#f87171,color:#fffデータは3つのパイプを通って流れます。
パイプ | プロトコル | クライアント | ユースケース |
MCP ツール | stdio 上の JSON-RPC | Claude Desktop | テキストツール ( |
MCP Apps | stdio + postMessage 上の JSON-RPC | Claude Desktop iframe | 対話型 UI ( |
スタンドアロン | HTTP GET | ブラウザ | 直接アクセス ( |
✨ 機能
機能 | ステータス | 備考 |
ツール ( | ✅ 完了 | 3つの型付けされたツール、構造化 JSON 応答 |
リソース ( | ✅ 完了 |
|
MCP Apps プロトコル | ✅ 完了 |
|
stdio トランスポート | ✅ | Claude Desktop, Cursor, Copilot |
Streamable HTTP | ✅ | MCP Inspector, curl, ブラウザ, トンネル |
SSE トランスポート | ❌ 削除 | MCP 仕様 v2025-11-25 で非推奨 |
3秒ビルドサイクル —
make build-fast && make dev-http7つの統合テスト —
make testですべてのプロトコルメソッドを実行対話的デバッグ —
make test-inspectorで MCP Inspector を起動リモートテスト —
make run-tunnelで公開trycloudflare.comURL を作成APIキー不要 — すべての恐竜データはバイナリに組み込み済み
実行時依存ゼロ — 単一の静的バイナリ、HTML 埋め込み
dino_dashboard ツールは、Claude Desktop の iframe 内に HTML カードグリッドを表示します。
食性でフィルター — 肉食、草食、またはすべて表示
時代でフィルター — 三畳紀、ジュラ紀、白亜紀
12種の恐竜 — T-Rex からヴェロキラプトルまで
フォールバックモード —
http://localhost:9010/dashboardで直接開く
注: フィルターはツール呼び出し時にサーバー側で適用されます。特定のフィルターで開いた後、アプリ内のフィルターボタンは同じ結果セット内でさらに絞り込むことしかできません。初期呼び出しで除外された種に戻ることはできません。
HTML ビューは公式の @modelcontextprotocol/ext-apps SDK を使用して構築され、postMessage を介した JSON-RPC で通信します。
🎮 試してみる
Claude Desktop で
Show me the dinosaur dashboard with carnivores→ Claude が MCP App を検出 → iframe をレンダリング → フィルタリング可能な恐竜カードが表示されます
ブラウザで
open http://localhost:9010/dashboard→ 組み込み REST API からすべての恐竜データを取得したスタンドアロン HTML
MCP Inspector で
make test-inspector→ http://localhost:5173 を開く → http://localhost:9010/mcp に接続
curl で
# Initialize
curl -s -X POST http://localhost:9010/mcp \
-H "Content-Type: application/json" \
-H "Accept: application/json, text/event-stream" \
-d '{"jsonrpc":"2.0","id":1,"method":"initialize","params":{"protocolVersion":"2025-06-18","capabilities":{},"clientInfo":{"name":"curl","version":"1.0"}}}' \
| python3 -m json.tool
# List tools
SID="<session-id-from-above>"
curl -s -X POST http://localhost:9010/mcp \
-H "Content-Type: application/json" \
-H "Accept: application/json, text/event-stream" \
-H "Mcp-Session-Id: $SID" \
-d '{"jsonrpc":"2.0","id":2,"method":"tools/list"}' \
| python3 -m json.tool
# Call dino_think
curl -s -X POST http://localhost:9010/mcp \
-H "Content-Type: application/json" \
-H "Accept: application/json, text/event-stream" \
-H "Mcp-Session-Id: $SID" \
-d '{"jsonrpc":"2.0","id":3,"method":"tools/call","params":{"name":"dino_think","arguments":{}}}' \
| python3 -m json.tool🔧 ツールリファレンス
ツール | タイプ | 入力 | 出力 | プロンプト例 |
| テキスト |
| ランダムな豆知識 + 種のJSON | 「恐竜の豆知識を教えて」 |
| テキスト |
| 回答 + 質問のJSON | 「T-Rexは何を食べていた?」 |
| MCP App |
| HTML iframe + JSONデータ | 「肉食恐竜を見せて」 |
dino_askは現在、質問内容に関わらず同じ恐竜時代の概要を返します。質問文に応じた分岐はまだ実装されていません。既知の制限として追跡しています。
dino_think の応答例:
{
"content": [
{ "type": "text", "text": "🦕 Did you know? The Velociraptor was only about the size of a turkey!" }
],
"structuredContent": {
"fact": "The Velociraptor was only about the size of a turkey",
"species": "Velociraptor"
}
}dino_dashboard の応答例:
{
"content": [
{ "type": "text", "text": "Displaying dinosaur dashboard with 4 dinosaurs (filter: Carnivore)" }
],
"structuredContent": {
"filter": "Carnivore",
"dinosaurs": [
{
"name": "Tyrannosaurus Rex",
"period": "Cretaceous",
"diet": "Carnivore",
"length": "40 ft (12 m)",
"weight": "9 tons (8,000 kg)",
"funFact": "T-Rex had the strongest bite of any land animal ever",
"imageStyle": "bg-red-900"
}
],
"timestamp": "2026-06-21T12:00:00Z"
}
}💬 Claude Desktop 連携
CLI モード (stdin/stdout)
バイナリの場所を確認し、claude_desktop_config.json に追加します。
{
"mcpServers": {
"dino-mcp": {
"command": "/absolute/path/to/mcp-dino/bin/dino-mcp",
"args": ["stdio"]
}
}
}保存後、Claude Desktop を再起動します。チャット中にツールにハンマーアイコン (🔨) が表示されます。クリックして直接呼び出すか、Claude に任せてください。
HTTP モード (デバッグ用)
make dev-http
# Server starts on :9010🛠 開発
前提条件
ツール | バージョン | 目的 |
≥ 1.25 | サーバーバイナリ | |
≥ 18 | UI ビルド (Vite) | |
任意 | リモートテスト用トンネル |
コマンド
# Build — three options
make build # Full: Vite UI + Go binary
make build-fast # Quick: Go binary only (reuses existing UI)
make build-ui # Vite UI only
# Run
make dev-http # HTTP mode with verbose logging
make run-stdio # stdio mode for Claude Desktop
make run-tunnel # HTTP + Cloudflare Tunnel
# Test & verify
make test # 7 integration tests — all must pass
make test-inspector # Launch MCP Inspector in browser
make lint # go vet + go fmt
# Utility
make help # All targets with descriptions
make clean # Remove all build artifactsプロジェクト構造
mcp-dino/
├── bin/ # Go build output (~11MB static binary)
├── cmd/dino-mcp/main.go # CLI entry point (stdio | http | help)
├── internal/
│ ├── server/
│ │ └── server.go # Composition root: mcp.Server + Gin + CORS
│ ├── tools/
│ │ ├── tools.go # Shared types, constants, helpers
│ │ ├── think.go # RegisterThink (dino_think tool)
│ │ ├── ask.go # RegisterAsk (dino_ask tool)
│ │ └── dashboard.go # RegisterDashboardTool + 12 dino species + REST API
│ └── resources/
│ ├── dashboard.go # RegisterDashboardResource + //go:embed HTML
│ └── dashboard_ui.html # Vite-built HTML (354KB)
├── ui/
│ └── src/
│ └── mcp-app.ts # ext-apps App class + postMessage
├── docs/ # Diátaxis documentation (see below)
├── test_mcp.sh # 7 integration tests
├── AGENTS.md # AI agent instructions (canonical)
├── ARCHITECTURE.md # C4 diagrams + sequence flows
├── TECH_DESIGN.md # Interface contracts + data model
├── Makefile # All targets
├── go.mod + go.sum # Go dependencies
└── README.md # ← you are here🗺 ドキュメントマップ
dino-mcp は Diátaxis フレームワーク を採用しています。4つのドキュメントモードがあり、それぞれ異なるニーズに対応します。
対象読者 | ここから始める | 対象読者 |
👋 プロジェクト初心者 | 全員 | |
🧑💻 ツールを追加する開発者 | 開発者 | |
🦕 恐竜を追加する編集者 | コンテンツ編集者 | |
🧪 Inspector でテストする | QA / 開発者 | |
🔍 リファレンスが必要な場合 | 運用者 | |
🏗 設計を理解したい場合 | アーキテクト | |
🤖 AI で実装する場合 | AI コーディングエージェント | |
📚 詳細なアーキテクチャ | シニアエンジニア | |
📐 技術仕様 | 実装チーム | |
⏳ 開発履歴 | すべてのコントリビューター | |
📋 ロードマップ | ステークホルダー | |
⚖️ 設計上のトレードオフ | アーキテクト | |
🎯 スキルリファレンス | 開発者 / AI エージェント | |
🤝 コントリビューション方法 | コントリビューター | |
📜 行動規範 | コミュニティ | |
📄 ADR | 意思決定の記録者 | |
🤖 LLM 用フルコンテキスト | AI エージェント (RAG) |
📊 プロジェクトステータス
MVP ── Production ── Enhanced UI ── Ecosystem ── Advanced
● ○ ○ ○フェーズ | ステータス | ハイライト |
MVP | ✅ 完了 | 3ツール、MCP Apps UI、7テスト、ドキュメント |
プロダクション | 🔄 進行中 | Go 単体テスト、CI、レート制限、Docker |
UI 拡張 | 📅 計画中 | リアルタイムデータ、比較、タイムライン |
エコシステム | 📅 計画中 | Homebrew、GitHub Releases、MCP Registry |
高度な機能 | 💭 将来 | ストリーミングツール入力、WebSocket 同期 |
ビルドメトリクス
メトリクス | 値 |
バイナリサイズ | 約11 MB (圧縮後) |
バイナリタイプ | Mach-O 64-bit arm64 |
Go バージョン | 1.25 |
MCP SDK バージョン | v1.7.0 |
依存関係 | 30以上の Go モジュール (すべて間接) |
UI バンドル | 354 KB 埋め込み HTML (単一ファイル Vite) |
テストカバレッジ | 7/7 統合テスト合格 (シェルベース、Go 単体テストは未実装) |
📖 参考文献
リソース | リンク |
MCP 仕様 | |
MCP Go SDK | |
MCP Apps プロトコル | |
ext-apps SDK | |
Gin Web Framework | |
Go プログラミング言語 |
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- Flicense-qualityDmaintenanceA production-ready MCP server with tools for weather, calculator, and mock database queries, plus resources and prompt templates, featuring a glassmorphism admin dashboard and WebSocket support.
- Alicense-qualityAmaintenanceA single MCP server with 40 tools across 7 categories - PM, Research, Brand, UX, GTM, File, and Web. Built in Go, zero dependencies, one binary. Handles file operations, web fetching, screenshots, search, and planning workflows through one MCP connection.11MIT
- Flicense-qualityCmaintenanceA self-hosted MCP gateway that aggregates all your MCP servers behind a single Streamable HTTP endpoint, with automatic registry discovery (19,000+ servers), on-demand Docker provisioning, multi-device support via SSH, OAuth2 PKCE authentication, and a workflow engine for saving and replaying multi-step tool sequences.
- Flicense-qualityBmaintenanceAn educational MCP server that controls a live dashboard on Cloudflare Workers, enabling real-time toggling of features, updating stats, and setting messages via 8 MCP tools.
Related MCP Connectors
A MCP server built for developers enabling Git based project management with project and personal…
MCP server for InsForge BaaS — database, storage, edge functions, and deployments
Go MCP server for GitLab: 2 dynamic tools reach 1000+ REST/GraphQL actions. Free/CE, no paid tier.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/shennawardana23/mcp-dino'
If you have feedback or need assistance with the MCP directory API, please join our Discord server