Demo a MCP Server
The current version of this demo is 0.1.0 (initial release).
-
Clone the repository
git clone https://github.com/cracksre/MCP-Server.git cd MCP-Server -
Create a Python virtual environment (recommended):
python -m venv venv source venv/bin/activate # on Windows use `venv\Scripts\activate`
-
Install dependencies
pip install -r requirements.txt
-
Run the server
python math-server.py
The server listens on the default MCP port and exposes example procedures.
-
Use the client
python mcp_client.py
This will invoke the
addprocedure defined inadd_example.py. -
Testing and development
- Modify or extend
add_example.pyto add new functions. - Restart the server after making changes.
- Modify or extend
Feel free to explore and adapt the code for your own MCP integrations.