dino-mcp
đ Inhaltsverzeichnis
Related MCP server: Relay
đŠ Was â und Warum
dino-mcp ist eine Referenzimplementierung des Model Context Protocol (MCP) in Go, die jede Schicht des modernen MCP-Stacks demonstriert:
Ebene | Implementierung | Warum es wichtig ist |
Transport |
| Funktioniert in Claude Desktop UND Webbrowsern |
MCP Apps |
| Interaktive HTML-UI in Claude Desktop-Iframes |
Tools |
| Typisierte Go-Handler, strukturierte JSON-Ergebnisse |
Resources |
| In sich geschlossene ~11 MB BinÀrdatei, null AbhÀngigkeiten zur Laufzeit |
Egal, ob Sie einen MCP-Server von Grund auf neu bauen, das MCP Apps-Protokoll lernen oder eine Blaupause fĂŒr die Integration von Go â Gin â ext-apps SDK benötigen, dieses Projekt hat alles, was Sie brauchen.
⥠Schnellstart
# 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"đ Architektur auf einen Blick
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:#fffDaten flieĂen durch drei KanĂ€le:
Kanal | Protokoll | Client | Anwendungsfall |
MCP Tools | JSON-RPC ĂŒber stdio | Claude Desktop | Textwerkzeuge ( |
MCP Apps | JSON-RPC ĂŒber stdio + postMessage | Claude Desktop iframe | Interaktive UI ( |
EigenstÀndig | HTTP GET | Browser | Direkter Zugriff ( |
âš Funktionen
Funktion | Status | Anmerkungen |
Tools ( | â Abgeschlossen | 3 typisierte Werkzeuge mit strukturierten JSON-Antworten |
Resources ( | â Abgeschlossen |
|
MCP Apps-Protokoll | â Abgeschlossen |
|
stdio-Transport | â | Claude Desktop, Cursor, Copilot |
Streamable HTTP | â | MCP Inspector, curl, Browser, Tunnel |
SSE-Transport | â Entfernt | Veraltet in MCP-Spezifikation v2025-11-25 |
3-Sekunden-Build-Zyklus â
make build-fast && make dev-http7 Integrationstests â
make testtestet jede ProtokollmethodeInteraktives Debugging â
make test-inspectorstartet MCP InspectorRemote-Tests â
make run-tunnelerstellt eine öffentlichetrycloudflare.com-URLKeine API-SchlĂŒssel â alle Dinosaurierdaten sind in die BinĂ€rdatei eingebettet
Null LaufzeitabhĂ€ngigkeiten â einzelne statische BinĂ€rdatei mit eingebettetem HTML
Das dino_dashboard-Werkzeug rendert ein HTML-Kartenraster im Iframe von Claude Desktop:
Nach ErnĂ€hrung filtern â Fleischfresser, Pflanzenfresser oder Alle anzeigen
Nach Periode filtern â Trias, Jura, Kreide
12 Dinosaurierarten â von T-Rex bis Velociraptor
Fallback-Modus â direkt öffnen unter
http://localhost:9010/dashboard
Hinweis: Der Filter wird serverseitig zum Zeitpunkt des Aufrufs angewendet. Wenn das Dashboard mit einem bestimmten Filter geöffnet wurde, können die Filterknöpfe in der App nur noch innerhalb desselben Ergebnissatzes weiter eingrenzen â sie können nicht wieder auf Arten erweitern, die der anfĂ€ngliche Aufruf ausgeschlossen hat.
Die HTML-Ansicht wird mit dem offiziellen @modelcontextprotocol/ext-apps-SDK erstellt und kommuniziert ĂŒber JSON-RPC per postMessage.
đź Ausprobieren
In Claude Desktop
Show me the dinosaur dashboard with carnivoresâ Claude erkennt die MCP-App â rendert einen Iframe â Sie sehen filterbare Dinosaurierkarten
In Ihrem Browser
open http://localhost:9010/dashboardâ EigenstĂ€ndiges HTML mit allen Dinosaurierdaten, die von der integrierten REST-API abgerufen werden
Mit MCP Inspector
make test-inspectorâ Ăffnet http://localhost:5173 â verbindet sich mit http://localhost:9010/mcp
Per 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đ§ Tool-Referenz
Tool | Typ | Eingabe | Ausgabe | Beispiel-Prompt |
| Text |
| Zufallsfakt + Arten-JSON | "ErzÀhl mir einen Dinosaurier-Fakt" |
| Text |
| Antwort + Frage-JSON | "Was hat T-Rex gefressen?" |
| MCP App |
| HTML-Iframe + JSON-Daten | "Zeig mir fleischfressende Dinosaurier" |
dino_askgibt derzeit unabhĂ€ngig von der gestellten Frage dieselbe allgemeine Ăbersicht ĂŒber die Dinosaurier-Ăra zurĂŒck â es verzweigt noch nicht auf den Fragetext. Wird als bekannte EinschrĂ€nkung vermerkt.
Beispielantwort 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"
}
}Beispielantwort 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-Integration
CLI-Modus (stdin/stdout)
Suchen Sie die BinĂ€rdatei und fĂŒgen Sie sie Ihrer claude_desktop_config.json hinzu:
{
"mcpServers": {
"dino-mcp": {
"command": "/absolute/path/to/mcp-dino/bin/dino-mcp",
"args": ["stdio"]
}
}
}Nach dem Speichern starten Sie Claude Desktop neu. Sie sehen Hammer-Symbole (đš) auf den Werkzeugen, wenn Sie chatten â klicken Sie, um direkt aufzurufen, oder lassen Sie Claude entscheiden.
HTTP-Modus (fĂŒr Debugging)
make dev-http
# Server starts on :9010đ Entwicklung
Voraussetzungen
Tool | Version | Zweck |
℠1.25 | Server-BinÀrdatei | |
â„ 18 | UI-Build (Vite) | |
beliebig | Tunnel fĂŒr Remote-Tests |
Befehle
# 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 artifactsProjektstruktur
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đș DokumentationsĂŒbersicht
dino-mcp verwendet das DiĂĄtaxis-Framework â vier Dokumentationsmodi, jeder fĂŒr unterschiedliche BedĂŒrfnisse.
FĂŒr dieses Publikum | Hier starten | Zielgruppe |
đ Neu im Projekt | Alle | |
đ§đ» Ein Werkzeug hinzufĂŒgen | Entwickler | |
đŠ Einen Dinosaurier hinzufĂŒgen | Content-Redakteure | |
đ§Ș Testen mit Inspector | QA / Entwickler | |
đ Referenz benötigt | Betreiber | |
đ Design verstehen | Architekten | |
đ€ Implementierung ĂŒber KI | KI-Codierungsagenten | |
đ Tiefe Architektur | Senior-Entwickler | |
đ Technische Spezifikationen | Implementierungsteams | |
âł Entwicklungsgeschichte | Alle Mitwirkenden | |
đ Fahrplan | Stakeholder | |
âïž Design-AbwĂ€gungen | Architekten | |
đŻ FĂ€higkeiten-Referenz | Entwickler / KI-Agenten | |
đ€ Wie man beitrĂ€gt | Mitwirkende | |
đ Verhaltenskodex | Community | |
đ ADRs | Entscheidungshistoriker | |
đ€ LLM voller Kontext | KI-Agenten (RAG) |
đ Projektstatus
MVP ââ Production ââ Enhanced UI ââ Ecosystem ââ Advanced
â â â âPhase | Status | Höhepunkte |
MVP | â Abgeschlossen | 3 Werkzeuge, MCP Apps-UI, 7 Tests, Dokumentation |
Produktion | đ In Bearbeitung | Go-Unit-Tests, CI, Ratenbegrenzung, Docker |
Erweiterte UI | đ Geplant | Echtzeitdaten, Vergleich, Zeitleiste |
Ăkosystem | đ Geplant | Homebrew, GitHub-Releases, MCP-Registry |
Fortgeschritten | đ Zukunft | Streaming-Werkzeugeingaben, WebSocket-Synchronisation |
Build-Metriken
Metrik | Wert |
BinĂ€rgröĂe | ~11 MB (komprimiert) |
BinÀrtyp | Mach-O 64-bit arm64 |
Go-Version | 1.25 |
MCP SDK-Version | v1.7.0 |
AbhÀngigkeiten | 30+ Go-Module (alle indirekt) |
UI-Bundle | 354 KB eingebettetes HTML (Single-File Vite) |
Testabdeckung | 7/7 Integrationstests bestanden (Shell-basiert; noch keine Go-Unit-Tests) |
đ WeiterfĂŒhrende Literatur
Ressource | Link |
MCP Specification | |
MCP Go SDK | |
MCP Apps Protocol | |
ext-apps SDK | |
Gin Web Framework | |
Go Programming Language |
This server cannot be deployed
Maintenance
Related MCP Connectors
A MCP server built for developers enabling Git based project management with project and personalâŠ
An MCP server that provides read access to your cloud storage providers, bank accounts and more.
MCP server for InsForge BaaS â database, storage, edge functions, and deployments
Hosted MCP server for AI-driven data ops. Create apps, manage schemas, and CRUD structured data.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceA 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.-
- AlicenseNot gradedqualityAmaintenanceA 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.12MIT
- FlicenseNot gradedqualityBmaintenanceAn 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.-
- FlicenseNot gradedqualityCmaintenanceMCP server that controls an interactive dashboard demo, providing tools to toggle features, update stats, set messages, and simulate traffic via Cloudflare Workers.-