my-first-mcp-server

hygjob/my-first-mcp-server

3.1

If you are the rightful owner of my-first-mcp-server and would like to certify it and/or have it hosted online, please leave a comment on the right or send an email to henry@mcphub.com.

My First MCP Server is a Model Context Protocol server implementation using TypeScript, designed to facilitate various computational tasks and provide server information.

Tools
5
Resources
0
Prompts
0

My First MCP Server

A Model Context Protocol (MCP) server implementation with TypeScript.

write

2025.6.11

Prerequisites

  • Node.js (v22 or higher recommended)
  • npm

Installation

npm install

Available Scripts

CommandDescription
npm run devStart development server with hot reload using tsx
npm run dev2Alternative dev server using ts-node/esm
npm run buildBuild TypeScript to JavaScript
npm startRun the built project
npm run inspectInspect MCP server configuration
npm testRun tests

Project Structure

my-first-mcp-server/
ā”œā”€ā”€ src/
│   └── index.ts    # Main server implementation
ā”œā”€ā”€ dist/           # Compiled JavaScript output
ā”œā”€ā”€ package.json
└── README.md

Features

Tools

  • add: Add two numbers
  • multiply: Multiply two numbers
  • greetmsg: Generate greeting message
  • get-weather: Get weather information for a city
  • debug-example: Debugging tool with logging

Resources

  • Server information
  • Dynamic greeting messages

Dependencies

Main Dependencies

  • @modelcontextprotocol/sdk: ^1.12.1
  • express: ^5.1.0
  • zod: ^3.25.58

Development Dependencies

  • TypeScript ecosystem tools
  • Jest for testing
  • Node.js type definitions

License

ISC