MCP Weather Data Fetcher
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@MCP Weather Data Fetcherwhat's the weather in New York?"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
π€οΈ MCP Weather Data Fetcher
A simple yet powerful weather-fetching tool built using the Model Context Protocol (MCP). This service allows AI agents to retrieve live weather updates for any city via OpenWeatherMap, wrapped in an agent-friendly format using MCP standards.
π Features
Real-time weather data via OpenWeatherMap API
MCP-compatible tool (
getWeatherData)Returns structured details: temperature, humidity, wind speed, and description
Agent-friendly response formatting
CLI-compatible using Stdio transport
Related MCP server: Weather MCP Server
π Tech Stack
Node.js
MCP SDK (
@modelcontextprotocol/sdk)OpenWeatherMap API
zod (for input validation)
dotenv
π¦ Setup
Clone the repo & install dependencies:
git clone https://github.com/Ansh642/MCP-Server.git
cd mcp-weather-fetcher
npm installCreate a
.envfile with your OpenWeatherMap API key:
OPENWEATHER_API_KEY=your_api_key_hereRun the MCP server:
node index.js(Optional) Define the server in
mcp.json:
{
"mcpServers": {
"weatherData": {
"command": "node",
"args": ["C:/Users/91995/Desktop/mcpServer/index.js"]
}
}
}π¬ Example Interaction
>> Call tool: getWeatherData with { "city": "Delhi" }
β
Weather Report for Delhi:
- Temperature: 34.9Β°C
- Feels Like: 37.1Β°C
- Humidity: 45%
- Weather: Clear
- Description: clear sky
- Wind Speed: 3.6 m/sπ€ Author
Ansh Agarwal π§ anshagarwal642@gmail.com π GitHub | LinkedIn
This server cannot be deployed
Maintenance
Related MCP Connectors
OpenWeather MCP β wraps the OpenWeatherMap API (openweathermap.org)
OpenWeather data for AI agents: list feeds, sign up, check balance, get a top-up link, fetch data.
Weather MCP β wraps Open-Meteo API (free, no auth)
Get current weather for any city and create images from your prompts. Streamline planning, reportsβ¦
Related MCP Servers
- FlicenseBqualityDmaintenanceEnables AI agents to retrieve real-time weather conditions and forecasts via OpenWeatherMap API. Supports interactive weather queries and travel planning through MCP tools, resources, and prompts.2-
- AlicenseNot gradedqualityDmaintenanceProvides weather data from OpenWeatherMap API through MCP tools and a REST API with OpenAPI support. Enables LLM agents to retrieve current weather, forecasts, and temperature ranges by city or coordinates.16 npmMIT
- AlicenseNot gradedqualityBmaintenanceWraps the OpenWeatherMap API to provide weather data through MCP, enabling AI agents to query current conditions, forecasts, and other weather information via natural language.5 npmMIT
- FlicenseNot gradedqualityDmaintenanceEnables MCP clients like Kiro and Claude to access current weather conditions and forecasts for any location using the OpenWeatherMap API.-