Fifth Elephant MCP Server
Click on "Deploy 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., "@Fifth Elephant MCP Serveradd 15 and 27"
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.
Fifth Elephant MCP Server: A DIY Guide
This guide provides a complete walkthrough to create and run a simple Model Context Protocol (MCP) server from scratch.
Table of Contents
Related MCP server: MCP Boilerplate
Prerequisites
Before we begin, ensure you have the following installed:
1. Install pyenv (if not already installed)
pyenv allows you to manage multiple Python versions easily.
macOS:
brew install pyenvLinux:
curl https://pyenv.run | bashWindows:
# Install pyenv-win using PowerShell
Invoke-WebRequest -UseBasicParsing -Uri "https://raw.githubusercontent.com/pyenv-win/pyenv-win/master/pyenv-win/install-pyenv-win.ps1" -OutFile "./install-pyenv-win.ps1"; &"./install-pyenv-win.ps1"Add pyenv to your shell profile:
macOS/Linux (zsh):
echo 'export PYENV_ROOT="$HOME/.pyenv"' >> ~/.zshrc
echo 'command -v pyenv >/dev/null || export PATH="$PYENV_ROOT/bin:$PATH"' >> ~/.zshrc
echo 'eval "$(pyenv init -)"' >> ~/.zshrc
source ~/.zshrcWindows:
# Restart your PowerShell or Command Prompt after installation
# pyenv-win will be automatically added to your PATH2. Install Python 3.11
Install and set Python 3.11 as your local version:
pyenv install 3.11.9
pyenv local 3.11.9Verify the Python version:
python --version
# Should output: Python 3.11.93. Install uv
Install uv for fast Python package management:
macOS/Linux:
curl -LsSf https://astral.sh/uv/install.sh | shWindows:
powershell -c "irm https://astral.sh/uv/install.ps1 | iex"Verify uv installation:
uv --versionStep 1: Project Setup
First, create a directory for your project and navigate into it.
mkdir fifth-elephant-mcp
cd fifth-elephant-mcpStep 2: Initialize a Python Project with uv
Initialize a new Python project using uv. This will create a virtual environment and a pyproject.toml file.
uv init --quietStep 3: Create and Activate Virtual Environment
Create a virtual environment using Python 3.11:
uv venv --python 3.11.9Activate the virtual environment:
macOS/Linux:
source .venv/bin/activateWindows (Command Prompt):
.venv\Scripts\activate.batVerify you're in the virtual environment (you should see (.venv) in your terminal prompt).
Step 4: Sync Dependencies (not required)
Sync the project dependencies to ensure everything is up to date:
uv syncStep 5: Add MCP Dependency
Add the mcp library with CLI extras to your project's dependencies.
uv add "mcp[cli]"Note: When installing MCP CLI, it may ask you to install additional dependencies. Press y to confirm.
Step 6: Verify Installation
Verify that all components are properly installed:
# Verify Python version
python --version
# Should output: Python 3.11.9
# Verify uv version
uv --version
# Verify MCP library is installed (should be version 1.11 or later)
python -c "from mcp.server.fastmcp import __version__; print(__version__)" Step 7: Edit the Server Code
When you ran uv init, a main.py file was already created. Edit this file and replace its contents with the following code. This code sets up a FastMCP server with two tools: hello_world and add.
from mcp.server.fastmcp import FastMCP
# Create an MCP server
mcp = FastMCP("Fifth Elephant")
# Add a hello world tool
@mcp.tool()
def hello_world() -> str:
"""Returns a friendly greeting."""
return "hello world"
# Add an addition tool
@mcp.tool()
def add(a: int, b: int) -> int:
"""Adds two numbers together."""
return a + b
if __name__ == "__main__":
mcp.run()Step 8: Debug Locally with MCP Inspector
For development and testing, you can use the MCP inspector.
Run the following command -
uv run mcp dev main.pyThis will spin up the inspector. It will open in your browser. Press connect on the left sidebar.
Step 9: Configure Claude Desktop
If you haven't already, install Claude Desktop to use your MCP server:
Download Claude Desktop from claude.ai
Install and set up Claude Desktop
To use your MCP server with Claude Desktop, you need to configure it using absolute paths.
Get Absolute Paths
First, get the absolute paths for your virtual environment's Python and your main.py file:
# Get the absolute path to your virtual environment's Python
which python
# Get the absolute path to your main.py file
pwdWindows (Command Prompt):
# Get the absolute path to your virtual environment's Python
where python
# Get the absolute path to your main.py file
cdConfigure Claude Desktop
Open Claude Desktop
Go to Settings → Developer → Edit Config
Add your MCP server configuration to the
config.jsonfile:
macOS/Linux:
{
"mcpServers": {
"fifth-elephant": {
"command": "/absolute/path/to/your/.venv/bin/python",
"args": ["/absolute/path/to/your/main.py"]
}
}
}Windows:
{
"mcpServers": {
"fifth-elephant": {
"command": "C:\\absolute\\path\\to\\your\\.venv\\Scripts\\python.exe",
"args": ["C:\\absolute\\path\\to\\your\\main.py"]
}
}
}Important:
macOS/Linux: Replace
/absolute/path/to/your/.venv/bin/pythonand/absolute/path/to/your/main.pywith the actual absolute paths you obtained from thewhich pythonandpwdcommands.Windows: Replace
C:\\absolute\\path\\to\\your\\.venv\\Scripts\\python.exeandC:\\absolute\\path\\to\\your\\main.pywith the actual absolute paths you obtained from thewhere pythonandcd/Get-Locationcommands. Note the double backslashes (\\) in Windows paths.
Config file locations:
macOS:
~/Library/Application Support/Claude/claude_desktop_config.jsonWindows:
%APPDATA%\Claude\claude_desktop_config.jsonLinux:
~/.config/claude/claude_desktop_config.json
Troubleshooting
If you encounter issues, try these common solutions:
1. Virtual Environment Issues
Make sure your virtual environment is activated:
macOS/Linux:
# Activate the virtual environment
source .venv/bin/activate
# Verify you're in the virtual environment
which python
# Should show: /path/to/your/project/.venv/bin/pythonWindows (Command Prompt):
# Activate the virtual environment
.venv\Scripts\activate.bat
# Verify you're in the virtual environment
where python
# Should show: C:\path\to\your\project\.venv\Scripts\python.exe2. Dependency Issues
Sync your dependencies:
uv sync3. MCP Inspector Configuration
If you're using the MCP inspector and having issues, use these settings:
Command:
uvArgs:
run --with mcp mcp run main.py
Note: The command should be uv, not mcp-server-everything or similar variants.
4. Path Issues
Ensure you're using absolute paths in your Claude Desktop configuration. Use:
macOS/Linux:
# Get absolute path to Python in your virtual environment
which python
# Get absolute path to your project directory
pwdWindows (Command Prompt):
# Get absolute path to Python in your virtual environment
where python
# Get absolute path to your project directory
cdThen update your config.json with the complete absolute paths. Remember to use double backslashes (\\) for Windows paths in JSON.
Available Tools
2 toolsaddB
Adds two numbers together.
| Name | Required | Description | Default |
|---|---|---|---|
| a | Yes | ||
| b | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations provided, so description carries full burden. States the mathematical operation but omits details like return value format, overflow behavior, or whether the operation is atomic/reversible.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Single sentence with zero waste. Front-loaded and appropriately sized for the tool's trivial complexity.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Adequate for the low complexity (2 integer params, no nested objects), but lacks return value description and error handling details given the absence of output schema or annotations.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 0% (titles 'A' and 'B' not sufficient). Description mentions 'two numbers' implying the parameter count and types generally, but does not map them to parameters 'a' and 'b' or explain their semantic roles (e.g., addends).
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Clear verb ('adds') and resource ('two numbers'), but does not explicitly differentiate from sibling 'hello_world' tool (though the distinction is obvious).
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Provides no guidance on when to use this tool versus alternatives, nor any prerequisites or contextual conditions for invocation.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
hello_worldB
Returns a friendly greeting.
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the full burden of behavioral disclosure. While 'Returns' implies a read-only operation, the description fails to specify side effects, idempotency, error conditions, or the format/structure of the returned greeting.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
At four words, the description is efficiently compact with no extraneous information. It front-loads the action and object, making it immediately scannable.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool's trivial complexity (zero parameters, no nested objects) and lack of output schema, the minimal description is adequate but incomplete. It does not specify the return value's data type, format, or content beyond the vague 'friendly greeting', leaving the agent uncertain about what exactly will be returned.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema contains zero parameters. Per the baseline rule for zero-parameter tools, this dimension scores a 4. The description correctly implies no input is required by focusing solely on the return value.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description uses a specific verb (Returns) and resource (greeting) that clearly communicates the tool's function. While it implicitly distinguishes from the sibling 'add' tool (greeting vs. arithmetic), it does not explicitly state this differentiation or clarify what makes the greeting 'friendly'.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides no guidance on when to use this tool versus alternatives, prerequisites for invocation, or conditions where it should be avoided. It merely states what the tool does without contextual usage advice.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
2 tool updates
v0.1.0- First observed
add - First observed
hello_world
TDQS
Scored across 2 tools
The two tools have completely distinct purposes: one performs a mathematical addition operation, while the other returns a greeting message. There is no overlap or ambiguity between them.
The naming is inconsistent: 'add' uses a simple verb, while 'hello_world' uses a snake_case compound phrase. There is no predictable pattern across the tool set.
With only two tools, the server feels thin and under-scoped for a general-purpose MCP server, lacking coverage for a coherent domain or meaningful workflows.
The tool surface is severely incomplete; there is no discernible domain (e.g., math, utilities), and the two tools do not support any meaningful operations or lifecycle, leaving obvious gaps for agent functionality.
Maintenance
Related MCP Connectors
The Mercado Pago MCP Server implements the Model Context Protocol to provide AI agents and LLMs with access to Mercado Pago's APIs and tools within compatible development environments. It acts as an intermediary that translates Mercado Pago resources into executable functions (tools) that AI applications can invoke to perform actions and automate flows. The server simplifies integration, enables using documentation to implement or improve code, and optimizes operations through natural language interactions without manual implementations.
MCP server for progressive tool usage at any scale (see https://klavis.ai)
Related MCP Servers
- FlicenseNot gradedqualityNot gradedmaintenanceA minimal example server implementing the Model Context Protocol, providing addition and multiplication tools for learning and experimentation with MCP clients.1-
- AlicenseNot gradedqualityDmaintenanceA minimal, production-ready MCP server with a simple addition calculator tool that demonstrates integration with the Model Context Protocol.71MIT
- FlicenseCqualityDmaintenanceA demonstration MCP server that provides a simple addition tool for learning how to create and deploy servers following the Model-Context-Protocol specification. Serves as a basic example for developers getting started with MCP server development.1-
- FlicenseNot gradedqualityNot gradedmaintenanceA demonstration MCP server that provides calculator tools for arithmetic operations, personalized greeting resources, and code review prompt templates. Enables users to perform basic math calculations, generate dynamic greetings, and access reusable code review templates through the Model Context Protocol.-