trackmcp
Back to directory
GreatAuk

mcp-weather

View on GitHub

mcp demo for https://modelcontextprotocol.io/quickstart/server

4 stars TypeScriptAI & Machine Learning Updated May 11, 2025

Documentation

MCP Server Starter

smithery badge

A production-ready starter template for building Model Context Protocol (MCP) servers with TypeScript.

๐Ÿš€ Quick Start

1. Clone the repository

2. Install dependencies:

bash
bun install

โœจ Key Features

  • Bun for fast testing and development
  • Biome for linting and formatting
  • Automated version management with standard-version
  • Clean, maintainable project structure

๐Ÿ“‚ Project Structure

code
mcp-starter/
โ”œโ”€โ”€ src/
โ”‚   โ”œโ”€โ”€ tools/          # MCP tools implementation
โ”‚   โ”œโ”€โ”€ utils/          # Shared utilities
โ”‚   โ”œโ”€โ”€ main.ts         # Server entry point
โ”‚   โ””โ”€โ”€ types.ts        # Shared type definitions
โ”œโ”€โ”€ tests/              # Test files
โ”œโ”€โ”€ biome.json          # Linting configuration
โ”œโ”€โ”€ tsconfig.json       # TypeScript configuration
โ””โ”€โ”€ package.json        # Project dependencies

โš™๏ธ Configuration

Creating New Tools

The project includes a script to help create new MCP tools:

bash
bun run scripts/create-tool.ts

This will:

1. Create a new tool directory under `src/tools/`

2. Generate the basic tool structure including:

    3. Update the tools index file to export the new tool

    Example:

    bash
    bun run scripts/create-tool.ts weather

    ๐Ÿ› ๏ธ Development

    • Run tests: `bun test`
    • Format code: `bun run format`
    • Lint code: `bun run lint`
    • Build project: `bun run build`

    To add your development MCP server to Claude Desktop:

    1. Build the project:

    bash
    bun run build

    2. Add to your Claude Desktop config:

    json
    // You only need the argument if you need to pass arguments to your server
       {
         "mcpServers": {
           "your-server-name": {
             "command": "node",
             "args": ["/path/to/your/project/dist/main.js", "some_argument"]
           }
         }
       }

    ๐Ÿ“œ Version Management

    This project uses standard-version for automated version management. Run `bun run release` to create a new version.

    Commit Message Format

    • `feat`: New feature (bumps minor version)
    • `fix`: Bug fix (bumps patch version)
    • `BREAKING CHANGE`: Breaking change (bumps major version)

    ๐Ÿ“ฆ Publishing to npm

    1. Ensure you're logged in to npm:

    bash
    npm login

    2. Build the project:

    bash
    bun run build

    3. Publish the package:

    bash
    npm publish

    Remember to update the version number using `bun run release` before publishing new versions.

    Installing via Smithery

    To install Weather MCP Server Starter for Claude Desktop automatically via Smithery:

    bash
    npx -y @smithery/cli install @GreatAuk/mcp-weather --client claude

    Installing from npm (after publishing)

    Add to your Claude Desktop config:

    json
    // You only need the argument if you need to pass arguments to your server
    {
      "mcpServers": {
        "your-server-name": {
          "command": "npx",
          "args": ["-y", "your-package-name", "some_argument"]
        }
      }
    }

    Frequently asked questions

    What is mcp-weather?

    mcp-weather is mcp demo for https://modelcontextprotocol.io/quickstart/server

    How do I install mcp-weather?

    Open the GitHub repository and follow its README. Most MCP servers are added to your client's MCP config, then called by your agent.

    Is mcp-weather open source?

    Yes โ€” it is hosted on GitHub at https://github.com/GreatAuk/mcp-weather and has 4 stars.

    Related MCP tools

    Run your own MCP server? See who uses it and what to fix.

    Measure it with TrackMCP