MCP Weather Server

MCP Weather Server

A Model Context Protocol server that provides real-time weather information and 5-day forecasts to AI assistants, supporting multiple languages and flexible units.

Category
Visit Server

Tools

get_weather

Obtient les informations météorologiques actuelles pour une ville

get_weather_forecast

Obtient les prévisions météorologiques sur 5 jours pour une ville

get_weather_by_coordinates

Obtient les informations météorologiques actuelles par coordonnées GPS

README

Serveur MCP Weather

Serveur Model Context Protocol (MCP) fournissant des informations météorologiques en temps réel via l'API Open-Meteo.

✨ Fonctionnalités

  • 🌤️ Météo actuelle par nom de ville ou coordonnées
  • 📅 Prévisions jusqu'à 7 jours
  • 🌍 Support multilingue (français, anglais, espagnol, allemand, etc.)
  • 🆓 API gratuite Open-Meteo (sans clé requise)
  • 🐳 Prêt pour Docker avec configuration de production optimisée
  • 📊 TypeScript strict avec validation des paramètres

🚀 Installation et démarrage rapide

Prérequis

  • Node.js 18+
  • Docker et Docker Compose (optionnel)

Méthode 1: Démarrage local

# Installation des dépendances
npm install

# Construction
npm run build

# Démarrage
npm start

Méthode 2: Docker (recommandé pour production)

# Déploiement automatique
chmod +x deploy.sh
./deploy.sh

📋 Outils MCP disponibles

get_weather

Obtient la météo actuelle pour une ville.

{
  "city": "Paris",
  "countryCode": "FR",
  "lang": "fr"
}

get_weather_forecast

Obtient les prévisions météo (1-7 jours).

{
  "city": "London",
  "days": 5,
  "lang": "en"
}

get_weather_by_coordinates

Obtient la météo par coordonnées GPS.

{
  "latitude": 48.8566,
  "longitude": 2.3522,
  "lang": "fr"
}

⚙️ Configuration

Copiez .env.example vers .env et ajustez si nécessaire :

# Port du serveur (optionnel)
MCP_SERVER_PORT=3000

# Langue par défaut
DEFAULT_LANGUAGE=fr

# Environnement
NODE_ENV=production

🛠️ Développement

# Mode développement avec rechargement automatique
npm run dev

# Vérification du code
npm run lint
npm run typecheck

# Formatage du code
npm run format

📦 Structure du projet

src/
├── index.ts              # Point d'entrée principal
├── services/
│   └── weatherService.ts # Service API Open-Meteo
├── utils/
│   ├── formatter.ts      # Formatage des réponses
│   └── validation.ts     # Validation des paramètres
├── types/
│   └── weather.ts        # Types TypeScript
└── constants/
    └── weather.ts        # Constantes et configurations

🐳 Production avec Docker

Le projet inclut une configuration Docker optimisée avec :

  • Build multi-stage pour une image légère
  • Utilisateur non-root pour la sécurité
  • Healthchecks intégrés
  • Logs structurés
# Construction manuelle
docker build -t mcp-weather-server .

# Ou via docker-compose
docker-compose up -d

🔧 Intégration MCP

Ce serveur est compatible avec tous les clients MCP. Exemple d'utilisation avec Claude Desktop :

{
  "mcpServers": {
    "weather": {
      "command": "node",
      "args": ["/chemin/vers/dist/index.js"]
    }
  }
}

📄 License

MIT - Voir le fichier LICENSE pour plus de détails.


Développé avec ❤️ en TypeScript

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.

Official
Featured
Local
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.

Official
Featured
Local
TypeScript
VeyraX MCP

VeyraX MCP

Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.

Official
Featured
Local
graphlit-mcp-server

graphlit-mcp-server

The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.

Official
Featured
TypeScript
Kagi MCP Server

Kagi MCP Server

An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.

Official
Featured
Python
E2B

E2B

Using MCP to run code via e2b.

Official
Featured
Neon Database

Neon Database

MCP server for interacting with Neon Management API and databases

Official
Featured
Exa Search

Exa Search

A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.

Official
Featured
Qdrant Server

Qdrant Server

This repository is an example of how to create a MCP server for Qdrant, a vector search engine.

Official
Featured