Skip to main content
Glama

MCP Agents - Example FastMCP Server

A simple Model Context Protocol (MCP) server built with FastMCP that demonstrates basic tool implementation.

Features

  • greet: Greet a user by name

Related MCP server: penr-oz MCP Server

Installation

This project uses uv for package management and just for task running. Make sure you have both installed:

# Install uv if you don't have it
curl -LsSf https://astral.sh/uv/install.sh | sh

# Install just if you don't have it
# On macOS with Homebrew:
brew install just
# Or with cargo:
cargo install just

Then build the project:

just build

Usage

Running the MCP Server

To start the MCP agents server:

just run

Using with MCP Clients

You can use this server with any MCP-compatible client. The configuration depends on how you want to run the server:

Option 1: Local Development (using source code)

For development or when running from a local clone:

{
  "mcpServers": {
    "mcp-agents": {
      "command": "uv",
      "args": ["run", "mcp-agents"],
      "cwd": "/Users/means/repository/mcp-agents",
      "env": {}
    }
  }
}

Once published to PyPI, users can use this simpler configuration:

{
  "mcpServers": {
    "mcp-agents": {
      "command": "uvx",
      "args": ["amajakai14_mcp-agents"]
    }
  }
}

Alternative with pipx:

{
  "mcpServers": {
    "mcp-agents": {
      "command": "pipx",
      "args": ["run", "amajakai14_mcp-agents"]
    }
  }
}

Option 3: Version Pinning

To pin to a specific version:

{
  "mcpServers": {
    "mcp-agents": {
      "command": "uvx",
      "args": ["amajakai14_mcp-agents==0.1.0"]
    }
  }
}

For Claude Desktop

Add any of the above configurations to your Claude Desktop config file:

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json

  • Windows: %APPDATA%/Claude/claude_desktop_config.json

Testing the Tools

Run the test script to verify the tools work correctly:

just test

Available Tools

greet

Greets a user by name.

Parameters:

  • name (string): The name of the person to greet

Returns: A friendly greeting message.

Example:

{
  "name": "greet",
  "arguments": {
    "name": "Alice"
  }
}

Response:

"Hello, Alice!"

Development

Available Just Commands

  • just build - Install dependencies and sync the project

  • just run - Start the MCP agents server

  • just test - Run the test script

  • just format - Format code with black and isort

  • just typecheck - Run type checking with mypy

  • just dev - Install development dependencies

  • just dist - Build distribution packages

  • just clean - Clean build artifacts

  • just publish - Publish to PyPI (used in CI)

Project Structure

mcp-agents/
├── src/
│   └── agents/
│       └── __init__.py          # Main MCP server implementation
├── pyproject.toml               # Project configuration and dependencies
├── justfile                     # Task runner configuration
├── mcp_config.json             # MCP client configuration example
├── test_tools.py               # Simple test script
└── README.md                   # This file

Adding New Tools

To add new tools using FastMCP:

  1. Add a new function with the @mcp.tool() decorator:

    @mcp.tool("tool_name", description="Description of what the tool does")
    def tool_name(param1: type, param2: type) -> return_type:
        # Tool implementation
        return result
  2. Update the README with documentation for the new tool

Running Tests

just test

License

MIT License

Available Tools

4 tools
get_dev_agentB

Get information about the Development Agent

Inputs: no named parameters. Returns: object

get_po_agentB

Get information about the Product Owner Agent

Inputs: no named parameters. Returns: object

get_qa_agentB

Get information about the Quality Assurance Agent

Inputs: no named parameters. Returns: object

list_all_agentsB

List all available agents with their basic information

Inputs: no named parameters. Returns: result

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A3.5/5.0

    Scored across 4 tools

    Disambiguation5/5

    Each tool has a clearly distinct purpose: three tools retrieve information about specific agents (Development, Product Owner, Quality Assurance), while the fourth lists all agents. There is no overlap or ambiguity between these functions.

    Naming Consistency5/5

    All tool names follow a consistent verb_noun pattern: 'get_dev_agent', 'get_po_agent', 'get_qa_agent', and 'list_all_agents'. The verbs 'get' and 'list' are appropriately used and maintain a predictable naming convention throughout.

    Tool Count4/5

    With 4 tools, the count is reasonable for managing agent information, though it might feel slightly thin if more operations (e.g., create, update, delete agents) were expected. However, for a read-only information retrieval server, it is well-scoped.

    Completeness3/5

    The tool surface covers read operations (get and list) for agents, which is appropriate for an information retrieval purpose. However, there are notable gaps if the domain implies management capabilities, such as creating, updating, or deleting agents, which are missing.

    Maintenance

    ActivityInactive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      A
      quality
      D
      maintenance
      A comprehensive MCP server providing arithmetic tools, dynamic file resources for frontend/backend documentation, reusable prompt templates for code review/debugging/testing, and complete development workflow management from requirements to deployment.
      4
      MIT
    • A
      license
      Not graded
      quality
      C
      maintenance
      A personal AI assistant server that provides MCP tools for notes, files, reminders, memory, shell, browser, and 30+ SaaS integrations, enabling AI clients to access and manage your data across sessions.
      4,009
      MIT
    • A
      license
      Not graded
      quality
      C
      maintenance
      A FastMCP server exposing 22 tools for calendar, to-do, notes, web search, math, scratchpad, task queue, and sandboxed code execution, designed for safe RL training with structured outputs and FastMCP transforms.
      MIT