The Model Context Protocol, in one lesson.
MCP Servers Module 1
You have M LLM apps (Claude Desktop, Cursor, your internal tools…) and N capabilities you want to expose (search Slack, query a DB, read your filesystem…). Without a protocol you build M × N integrations.
Every new client needs to know every tool. Every new tool needs to be re-glued into every client. The work multiplies.
Slack DB FS Web Claude Desk [#] [#] [#] [#] Cursor [#] [#] [#] [#] Your App [#] [#] [#] [#] every [#] is a custom integration you have to write and maintain.
MCP standardises the wire between an LLM app (the client) and a capability provider (the server). Write your server once; every MCP-aware client can talk to it. Add a new client; it inherits every existing server.
An MCP server exposes capabilities in exactly three shapes. Everything you'll build in this course is one of these three.
| Primitive | What it is | Example |
|---|---|---|
| Tool | Function the LLM can call | pkb.search(query) |
| Resource | Read-only data the LLM can fetch | file:///notes/2026-05-21.md |
| Prompt | Reusable prompt template provided by the server | /welcome |
The official filesystem MCP server is the canonical "hello world". Once configured in Claude Desktop, here is what the user actually sees:
read_file, write_file, list_directory, create_directory, move_file, … The user can inspect each one's schema./tmp/mcp-demo" triggers a tool call. Claude picks list_directory, fills in the path, and Claude Desktop prompts the user to approve the call before it runs.README.md, notes.txt, and a drafts/ directory."A single-binary app calling a single LLM with private tools doesn't gain anything from MCP — the protocol overhead buys you nothing if there is only ever one client and one server.
Use raw function-calling there. Reach for MCP when the tools need to be shared.
filesystem, fetch, brave-search, sqlite, github, slack, postgres, memory, and more.modelcontextprotocol/servers repo and a long tail of third-party servers on GitHub cover everything from Jira to Home Assistant.MCP messages are JSON-RPC 2.0. The protocol is the same; the pipe changes.
You'll build a Personal Knowledge Base MCP server, one capability per lesson:
search — full-text search across your notes. The first tool; the spine of the server.fetch — read the full content of a specific note by ID. Pairs with search to give Claude both discovery and retrieval.summarize — collapse a note (or a set of notes) into a short brief. Introduces server-side prompts.write — create or append to notes from inside a conversation. Adds permissioning — this is the first destructive tool.export — pack a selection of notes into a downloadable bundle. Demonstrates resources and binary payloads.Open a terminal and run:
python --version # 3.10+
pip install 'mcp[cli]' # the official SDK
mcp dev --help # should print the dev CLI
claude/lesson13-building-mcp-server?If you've already done claude/lesson13-building-mcp-server, skim slides 1–9 and jump straight to Lesson 04.
Four pairs that trip up everyone on day one:
| Pair | One-sentence disambiguation |
|---|---|
| server vs client | The server exposes capabilities; the client is the LLM app that consumes them — same as web, opposite intuition for some. |
| tool vs resource | Tools are callable actions (verbs); resources are addressable data the model reads (nouns). |
| sampling vs elicitation | Sampling is the server asking the client for an LLM completion; elicitation is the server asking the user (via the client) for input. |
| stdio vs HTTP transport | stdio = subprocess pipes for local servers; HTTP = networked servers, possibly multi-tenant. |