learn-mcp

NiloofarGheibi/learn-mcp

3.2

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

This repository contains a simple server built using the FastMCP library, demonstrating basic tool creation and exposure.

Tools
2
Resources
0
Prompts
0

Simple FastMCP Server

This repository contains a simple server built using the FastMCP library. It demonstrates how to create and expose two basic tools: a greeting tool (hello) and a simple calculator tool (add).

Prerequisites

You need Python 3.8 or higher installed on your system. This project also requires the fastmcp library.

Installation

First, make sure you have a Python environment set up. It's recommended to use a virtual environment.

pip install fastmcp

Create a virtual environment (if you haven't already)

python -m venv .venv

Activate the virtual environment

source .venv/bin/activate # On macOS/Linux

Usage

To run the server, simply execute the server.py file from your terminal:

python server.py

Using inspect:

npx @modelcontextprotocol/inspector uv -- run server.py

inspector