Utilizes GitHub Personal Access Tokens for user authentication, enabling secure access to the server's weather forecast and alert tools.
Click on "Install 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., "@Weather MCP ServerAre there any active weather alerts for California?"
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.
Weather MCP Server
A Model Context Protocol (MCP) server that provides weather forecasts and alerts using the US National Weather Service API. Requires GitHub authentication to access weather tools.
Features
GitHub Authentication: Secure access using GitHub personal access tokens
Weather Forecasts: Get detailed weather forecasts for any US location by coordinates
Weather Alerts: Retrieve active weather alerts by state code
Installation
NPM Installation
Usage in VS Code
Add this to your MCP settings file (.vscode/mcp.json or global settings):
Or if installed globally:
Authentication Setup
Before using the weather tools, you must authenticate with GitHub:
Create a GitHub Personal Access Token:
Go to GitHub Settings → Developer settings → Personal access tokens → Tokens (classic)
Click "Generate new token (classic)"
You don't need to select any scopes - just name it (e.g., "MCP Weather")
Click "Generate token" and copy the token
Authenticate in MCP:
Use the
authenticatetool with your GitHub tokenOnce authenticated, you can use all weather tools
Example authentication:
Available Tools
authenticate
Authenticate with GitHub using a personal access token.
Parameters:
token(string): GitHub personal access token
Returns: Success message with authenticated username or error message.
Note: You must authenticate before using any weather tools.
get_forecast
Get weather forecast for a location. Requires authentication.
Parameters:
latitude(number): Latitude of the location (-90 to 90)longitude(number): Longitude of the location (-180 to 180)
Example:
get_alerts
Get weather alerts for a US state. Requires authentication.
Parameters:
state(string): Two-letter state code (e.g., "CA", "NY")
Example:
Security Notes
Your GitHub token is only stored in memory during the server session
The token is never logged or persisted to disk
No specific GitHub permissions/scopes are required
The token is only used to verify your identity with GitHub
Development
Prerequisites
Node.js 18 or higher
npm or yarn
Setup
Build
Local Testing
You can test the server locally by running:
API Source
This server uses the National Weather Service API, which provides weather data for US locations only.
License
MIT
Contributing
Contributions are welcome! Please feel free to submit a Pull Request.