Skip to main content
Glama
filypsdias

MCP Project Manager Lab

by filypsdias
README.md
# MCP Project Manager Lab

**Course:** Frontier Engineer Onboarding — Day 1: Claude Code Mastery & Context Engineering
**Lab:** Lab 01 — Build & Deploy a Custom MCP Server (buildable subset) + Context Engineering exercise

## What this is

A "Project Manager" MCP server exposing three tools — `create_task`, `list_tasks`,
`update_task` — backed by SQLite, plus a well-structured `.claude/` configuration
directory (settings, custom commands, a hook, and CLAUDE.md).

## Architecture

```
Claude Code (MCP Host) <--stdio--> MCP Server (this repo) <--> SQLite
     |
     |-- calls create_task
     |-- calls list_tasks
     |-- calls update_task
```

- `src/db.ts` — SQLite persistence layer. Takes a `Database.Database` instance as a
  parameter (dependency injection), so it's testable against `:memory:` without a live
  server process.
- `src/tools.ts` — zod schemas + descriptions for the 3 tools.
- `src/server.ts` — constructs the `McpServer` and wires each tool to the db layer.
- `src/index.ts` — stdio entrypoint (creates `tasks.db`, connects the transport).

## Scope & Constraints

This lab is built analytically, matching this workspace's standing no-run/no-deploy
convention:

- **No deploys.** Step 6 of the official lab brief (SSE transport + Railway/Render
  deployment) is intentionally **not built**. `.mcp.json` only contains the local
  stdio configuration.
- **No live runs.** Step 5 (opening Claude Code and issuing live prompts against the
  running server) is **not performed**. `src/index.ts` is written but never executed.
- **Mocked/local data only.** Tests exercise an in-memory (`:memory:`) SQLite instance
  as a fixture. No `tasks.db` file is created or committed.
- **TDD without execution.** `tests/db.test.ts` and `tests/tools.test.ts` are written
  before their corresponding implementation files (see commit order), but the suite is
  never run (`npm install` / `npm test` are not executed).

## Deliverables

- [x] MCP server with 3 tools (`create_task`, `list_tasks`, `update_task`)
- [x] SQLite persistence layer
- [x] `.mcp.json` local stdio integration
- [x] `.claude/` directory: `settings.json` (permissions + 1 hook), 2 custom commands,
      well-structured `CLAUDE.md`
- [x] TDD test suite (written, not executed)
- [ ] Deployed to Railway/Render with SSE transport — **out of scope** (no-deploy
      constraint)
- [ ] Live end-to-end test via Claude Code — **out of scope** (no-run constraint)

## Not built (stretch ideas from the brief, explicitly skipped)

- Extension Challenges: auth on the SSE layer, MCP resource endpoints, a second
  "Time Tracker" MCP server, prompt templates.
- Extra Exercises A-C: a dedicated database MCP server, an auto-test hook that
  actually executes test files on edit, a multi-agent git-worktree workflow.

These are skipped, not attempted-and-cut — none require running anything to *describe*,
but building them well would; left out to keep this lab's scope to what's fully
buildable and testable without execution.