Skip to main content
Glama

basic-mcp

Ein MCP-Server (Model Context Protocol) mit einer React-Oberfläche, der Tools und Ressourcen rund um GitHub-Benutzer und das Wetter bereitstellt.

Projektstruktur

basic-mcp/
├── server/          # Serveur MCP (Node.js / TypeScript)
│   ├── main.ts      # Point d'entrée — transport stdio
│   ├── server-http.ts # Point d'entrée — transport HTTP (Streamable HTTP)
│   └── src/
│       ├── application/   # Cas d'usage (GetGitHubUser, GetWeather)
│       ├── domain/        # Entités et ports (interfaces)
│       ├── infrastructure/ # Implémentations des repositories
│       └── interface/mcp/ # Outils et ressources MCP exposés
└── client/          # Interface React + Vite
    └── src/
        ├── application/hooks/  # useMcpTool, useMcpResource
        ├── domain/             # Entités côté client
        ├── infrastructure/mcp/ # Adaptateur MCP client
        └── presentation/       # Composants React

Related MCP server: Weather MCP

Voraussetzungen

  • Node.js >= 18

  • npm >= 9

Installation

npm install
cd client && npm install

Start

Nur Server (stdio)

npm run start

HTTP-Server (Port 3001)

npm run start:http

HTTP-Server + React-Oberfläche

npm run start:ui

Die Oberfläche ist unter http://localhost:5173 erreichbar. Der MCP-HTTP-Server lauscht unter http://localhost:3001/mcp.

Verfügbare MCP-Tools

Tool

Beschreibung

ping

Überprüft, ob der Server antwortet

get-github-user

Gibt Informationen eines GitHub-Benutzers zurück

get-weather

Gibt das Wetter für einen Breitengrad/Längengrad zurück

Verfügbare MCP-Ressourcen

URI

Beschreibung

github-user://{username}

GitHub-Profil eines Benutzers

weather://{lat},{lon}

Wetter für GPS-Koordinaten

Architektur

Das Projekt folgt den Prinzipien der Clean Architecture:

  • Domain — Entitäten und Port-Schnittstellen (keine externen Abhängigkeiten)

  • Application — Anwendungsfälle, die die Geschäftslogik orchestrieren

  • Infrastructure — HTTP-Aufrufe an externe APIs (GitHub, Open-Meteo)

  • Interface — Bereitstellung über das MCP-Protokoll

Related MCP Connectors

Related MCP Servers

  • A
    license
    Not graded
    quality
    D
    maintenance
    A Node.js/TypeScript server implementing the Model Context Protocol that provides integrations with GitHub and Notion, allowing automated workflow between these platforms via API endpoints.
    1,020 npm
    MIT
  • F
    license
    Not graded
    quality
    D
    maintenance
    A Model Context Protocol server that enables natural language weather queries for global cities, integrating with OpenWeather API to provide real-time weather information in an easy-to-read format.
    1
    -
  • F
    license
    Not graded
    quality
    C
    maintenance
    A Model Context Protocol server that interfaces with OpenWeatherMap API to provide real-time weather information and forecasts for cities worldwide.
    -
  • A
    license
    Not graded
    quality
    D
    maintenance
    A Model Context Protocol server that provides weather information using the Open-Meteo API, allowing users to get current weather for specific cities and retrieve weather data for date ranges.
    Apache 2.0