Skip to main content
Glama

Python MCP Starter

An open-source starting point for anyone to build a local MCP server with guidance from Codex or Claude Code. Describe your idea; your coding agent helps investigate it, asks the necessary questions, builds the integration, tests it, and connects it to your app.

This starter contains no ready-made tools. It provides a runnable Python server, a guided workflow, and installation helpers. No model API key is needed for the server itself; your chosen coding agent has its own access requirements.

What is MCP?

MCP (Model Context Protocol) is a shared way for AI applications to discover and call tools. Your coding agent is the assistant; this Python server provides the tools; an external API, website, or database supplies the data or actions. The local app starts this server and communicates over stdio (standard input and output). You do not need a public URL, web server, or cloud deployment. External services may still require an internet connection and authentication.

Related MCP server: dev-mcp

Start here

  1. Install Git, Python 3.11+ and uv using Preparation.

  2. Clone this repository into your own working folder. Replace YOUR-REPO-URL with this repository's GitHub URL once published:

    git clone YOUR-REPO-URL my-mcp
    cd my-mcp
  3. Sign in to Codex or Claude Code. In Codex, add/open the cloned folder as a project and start a task in it. In Claude Code, open a terminal in this folder and run claude. The agent must see this repository's AGENTS.md. Send:

    Read AGENTS.md and guide me through building my own MCP server. Start by checking prerequisites and cloning the required SDK reference. My idea is: …

  4. The agent runs the preparation steps below, asks about your needs, and builds only your chosen integration. You can also run preparation yourself:

    python3 scripts/bootstrap.py
    uv sync --locked
    uv run python scripts/smoke_test.py --expect-empty

    On Windows PowerShell, use python instead of python3 for the first command. An empty tool list is expected until you build your integration.

  5. Once your integration passes its tests, follow Install locally. That guide explains naming, user versus project setup, connection checks and removal.

What you will do together

Prepare → clone the SDK → describe your use case → verify access → agree on tools and permissions → build and test → install → try your own example questions. The agent saves non-secret progress in the ignored .local/ folder so you can continue later. You do not need to answer everything at once.

Ideas include checking public weather data, reading selected records from your database, or looking up information behind an authenticated API. These are intake examples, not implemented features. Writes are disabled by design until you and the agent explicitly agree on them and implement appropriate restrictions.

What's inside

  • AGENTS.md: step-by-step instructions for your coding agent.

  • src/usecase_mcp/: the empty server, settings, and places for tools/clients.

  • scripts/: preparation, protocol check, config output and bundle builder.

  • reference.json: pinned official SDK revision and example paths.

  • packaging/: optional Claude Desktop bundle template and launcher.

  • docs/: intake, security, installation, bundles, testing, and example scenarios.

The official SDK is installed as a locked dependency. Its separate Git clone is mandatory learning/reference material and is excluded from your repository. No external integrations, hosted services, Git repository, or GitHub remote are created automatically. Before publishing, replace the clone URL above.

Develop and check

uv sync --locked
uv run pytest
uv run ruff check .
uv run python scripts/smoke_test.py --expect-empty

uv run mcp-starter starts the stdio server and waits for protocol input; it does not open a web page. Use the smoke test or a connected client to interact with it. Press Ctrl+C to stop a manually started server.

References

MIT licensed. See LICENSE.

Related MCP Connectors

Related MCP Servers

  • F
    license
    Not graded
    quality
    D
    maintenance
    A production-ready Python scaffold for building Model Context Protocol (MCP) servers using FastMCP. It provides a structured framework for developers and AI agents to rapidly develop, test, and manage custom tools and workflows.
    1
    -
  • A
    license
    Not graded
    quality
    B
    maintenance
    A local MCP server that gives AI agents access to developer tooling — GitHub (read-only), documentation search, and web research — via stdio transport.
    MIT
  • A
    license
    A
    quality
    B
    maintenance
    Enables building and running zero-dependency MCP servers with automatic JSON Schema generation, exposing Python tools to Claude Desktop, Cursor, and autonomous agent fleets.
    2
    Apache 2.0