Skip to content
Exchange

A starter MCP server

1 file4 KB

A look inside

The first lines of mcp-starter-server.zip. The whole file is in your library once you get it.

<!-- ABOUTME: How to run the starter MCP server and connect it to Claude Code, plus the tool-design checklist. -->
<!-- ABOUTME: Lesson 3.2: designing tools for agent ergonomics. -->
# Starter MCP server

A small MCP server with two tools over a folder of `.txt` notes: `notes_search` and `notes_read`.
It is built on the official Python MCP SDK, version 2.3.0 (pinned in `requirements.txt`).
Version 2 of the SDK renamed `FastMCP` to `MCPServer`, so older tutorials will not match this file.

## Run it
```
pip install -r requirements.txt
python3 -I -m unittest      # the tests: plain functions, then the real MCP tools in-process
```
Connect it to Claude Code as a local (stdio) server, then ask Claude about your notes:
```
claude mcp add notes -- python3 /full/path/to/server.py
```
It reads notes from `./notes`, or from the folder in the `NOTES_DIR` environment variable.

## What to copy from it
- Two tools for one real job, not one tool per endpoint.
- Names share a prefix (`notes_`), so the model picks the right one.
- Each description says when to use it and what comes back.
- Output is capped (default 10, at most 20) and says how many more there are.
…and 10 more lines.

What is inside

  • mcp-starter-server.zip4 KB

How to use it

A small MCP server with two tools over a folder of .txt notes, notes_search and notes_read, built on the official Python MCP SDK 2.3.0. Its README carries the tool-design checklist.

Run pip install -r requirements.txt, connect it to Claude Code with claude mcp add notes -- python3 /full/path/to/server.py, then ask Claude about your notes.

Run before it was listed

Tested 2026-11-27: python3 -I -m unittest: 6 tests passed, including listing and calling the tools in-process. A live run connected to Claude Code is still owed.