Build a Stateful FastMCP Server on macOS with SQLite

The FastMCP tutorials so far returned pure, stateless results. Real tools usually need state that persists — a record that is still there after the process restarts. In this tutorial you will build a FastMCP task-manager server whose tools read and write a SQLite database, so tasks survive restarts, redeploys, and reboots. You will separate the persistence layer (db.py) from the MCP tools (server.py), expose a live-stats resource, cover it with pytest (including a test that proves data survives a restart), and deploy it as a launchd service. The stack is Mac-native: uv, make, and Python’s built-in sqlite3 — no database server to install. ...

14 min

Serve Media from a FastMCP Server on macOS — Inline or as Expiring Links

MCP tools usually return text. But a tool can also return media (an image, a document), and sometimes the right answer isn’t the bytes at all but a link to them. This tutorial builds a FastMCP server that does both, and lets you choose per request: Inline delivery — the tool returns the media object directly (a PNG image, an SVG image, a Markdown document). Best for small, renderable results. Link delivery — the tool stores the bytes in a bucket and returns a URL. The URL is either permanent or expiring after N minutes. Best for large media (video) or anything you want to share by link. The bucket here is self-contained: the server stores files in a local directory and serves them itself over HTTP, using HMAC-signed URLs so an expiring link simply stops working after its time-to-live — no per-object cleanup job. The last section shows how to swap in real object storage (S3/R2/GCS presigned URLs) without touching the tools. The stack is Mac-native: uv, make, and a launchd service. ...

19 min

Package and Distribute a FastMCP Server as a uvx Tool on macOS

The friendliest way to ship a Python command-line tool today is to make it runnable with uvx, uv’s equivalent of pipx run. A user types uvx macmcp and uv fetches the package, builds an ephemeral environment, and runs it, with no clone, no virtualenv, and nothing left installed. That is a perfect distribution model for a FastMCP server: you publish once, and anyone can run your MCP server (or wire it into an MCP client config) with a single command. ...

10 min

Build and Deploy a FastMCP Server on macOS Without Writing Code — Let Claude Code Do It

Most tutorials hand you code to type. This one does the opposite: you will stand up a FastMCP server on your Mac in which you never write a line of application code. You describe behavior in plain English and Cucumber/Gherkin scenarios, and Claude Code (driven by subagents and slash commands you configure once) writes and maintains server.py until every scenario passes. Your entire job is to run make (or let CI run it). ...

20 min

Gate a FastMCP Server to Paying Customers on macOS

Building an MCP server is easy; making sure only the people who paid for it can call it is the part that turns a demo into a product. In this tutorial you will build a FastMCP server that authenticates every request against a license store: paying customers hold a license key, the server verifies it, and unknown or expired keys are rejected with 401 Unauthorized. Premium tools are further gated so that only the Pro plan can call them. ...

17 min

Connect to a FastMCP Server from macOS

In the companion article Create and Deploy a FastMCP Server on macOS you built a FastMCP server and deployed it as a launchd service listening on http://127.0.0.1:8000/mcp/. This tutorial builds the other half: a command-line MCP client that connects to that running server over HTTP, lists what it offers, and calls its tools. Because you are on a Mac, the client does one extra thing that a generic client does not: with --copy it drops a tool’s result straight onto the macOS clipboard via pbcopy, so the output of slugify is ready to paste into your editor. Everything is managed with uv and make. ...

11 min

Create and Deploy a FastMCP Server on macOS

The Model Context Protocol (MCP) lets AI clients (Claude Desktop, Claude Code, or your own agent) call tools, read resources, and load prompts from an external server. FastMCP is a Python framework that turns ordinary typed functions into a compliant MCP server with a couple of decorators. Most FastMCP tutorials stop at “run it over stdio.” This one goes further: you build a small server, then deploy it as a persistent background service on your Mac using launchd, the same supervisor macOS uses for its own daemons. The result is an HTTP MCP server that starts at login, restarts if it crashes, and writes logs you can tail — managed entirely through make. ...

15 min

Build a Multi-Agent System with Google's Agent Development Kit

A single LLM agent works well until the job spans several distinct skills. The proven pattern is a coordinator agent that delegates to specialized sub-agents — much like a manager routing work to departments. Google’s Agent Development Kit (ADK) is a code-first Python framework built for exactly this: you define agents and plain-Python tools, wire specialists under a coordinator, and ADK handles the LLM-driven delegation between them. In this tutorial you will build a travel concierge: a coordinator agent that routes weather questions to a weather specialist and currency questions to a currency specialist, each backed by its own tool. You will run it in the terminal and the ADK web UI, then cover the deterministic parts (the tools and the agent wiring) with pytest, no API key required. ...

13 min

Build an MCP Client with FastMCP and Python

A Model Context Protocol (MCP) server exposes tools, resources, and prompts; an MCP client is what connects to that server, discovers those capabilities, and calls them. Clients are usually embedded in an AI application (Claude Desktop, Claude Code, or your own agent), but writing a standalone client is the clearest way to understand the protocol and to script, test, or debug a server. In this tutorial you will build a command-line MCP client with FastMCP. It connects to any MCP server over stdio, prints the server’s advertised tools, resources, and prompts, and calls a tool with JSON arguments. You will run it against a small demo server, then cover it with pytest using FastMCP’s in-memory transport — no subprocess required. ...

13 min

Build an MCP Server with FastMCP and Python

The Model Context Protocol (MCP) is an open standard that lets AI clients (such as Claude Desktop, Claude Code, or your own agent) call tools, read resources, and load prompts from an external server over a well-defined wire protocol. FastMCP is a Python framework that hides the protocol plumbing behind plain decorators, so you write ordinary typed functions and FastMCP turns them into a compliant server. In this tutorial you will build a small but realistic “notes” MCP server: it exposes tools to create and search notes, a resource to read a single note by URI, and a prompt that asks the model to summarize a note. You will run it over stdio, inspect it interactively, and cover it with pytest using FastMCP’s in-memory client. ...

13 min