Skip to content

Get started

Run from source

Run the API, web app and MCP server locally against a seeded demo workspace.

Requirements

Node 22 or later and pnpm 10 (corepack enable). No database to install: locally the API uses PGlite, a real Postgres compiled to WebAssembly, stored in .data/.

Start

terminal
pnpm install
cp .env.example .env
pnpm db:setup        # create the schema and seed the demo workspace
pnpm dev             # API on :4000, web on :3000, MCP server on :4100

The demo workspace

Open http://localhost:3000 and sign in as ada@knotworking.dev with the password knotworking-demo. The demo is a small company, Acme Inc, with Marketing, Operations and Sales teams, a product launch, a team offsite and this week's meetings. Due dates are set relative to the day you seed.

Repository layout

repository
apps/
  web/          Next.js web app
  server/       Hono HTTP API, the single backend for every client
  mcp/          MCP server, an API client for agents
  runner/       Runs each person's agent CLI for the assistant
  desktop/      Tauri window around the web app
packages/
  core/         Domain model shared by every client: schemas, IDs, sync protocol, modules
  db/           Drizzle schema, SQL migrations, seed data
  api-client/   Typed API client inferred from the server's routes
  ui/           Components and theme
docs/           Architecture, data model and module guides

Scripts

CommandWhat it does
pnpm devRun the API, web app and MCP server in watch mode
pnpm buildProduction build of every package and app
pnpm typecheckType-check everything
pnpm testUnit and API integration tests, on an in-memory Postgres
pnpm db:generateGenerate a SQL migration after changing a schema file
pnpm db:migrateApply migrations
pnpm db:resetDrop the local database and set it up again