Every area of the web app, the API and the packages, each on the row below everything that imports it, and a box per connector the description file declares. Only the shortest chain of imports is drawn, each arrow labelled with the files that make it. The marks are shown and nothing fails on them.
Imports an area below
An import back up the chain, closing a cycle, with its files; a tie where both halves are the same size
Connector code living in the core: move it into the connector (3 files)
A connector with no package of its own, or whose package is gone (1 of 3)
A connector package importing beyond the SDK (2)
Undescribed
Gone: described, not on disk
Connector package importing only the SDK
Released together, in one deploy
Deployed as production, staging, local
One release: the Worker cockpit
Served by the Worker as static assets; it talks to the API over HTTP and live updates, in the shapes of packages/shared.
Web app
One Cloudflare Worker. worker.ts dispatches fetch, queue and scheduled; the Hono app handles requests.
API
Shared by the web app and the API.
Packages
One box per source the description file declares
Connectors
web imports shared in 67 files
http imports mcp in 1 file
http imports engines in 1 file
mcp imports jobs in 1 file
jobs imports connectors in 1 file
jobs imports ai in 1 file
engines imports auth in 1 file
connectors imports auth in 2 files
connectors imports Microsoft Teams in 1 file
connectors imports Gmail in 1 file
auth imports accounts in 3 files
ai imports gateway in 1 file
ai imports domain in 3 files
accounts imports embeddings in 1 file
accounts imports domain in 9 files
accounts imports db in 2 files
accounts imports connector-sdk in 6 files
embeddings imports gateway in 1 file
gateway imports shared in 1 file
domain imports shared in 12 files
db imports shared in 1 file
Microsoft Teams imports connector-sdk in 3 files
Gmail imports connector-sdk in 4 files
connector-sdk imports shared in 1 file
Claude Code code in web: components/ConnectClaudeCode.tsx
Claude Code code in engines: claude-code-hooks.ts, claude-code.ts
Teams app is part of Microsoft Teams's package
The React app: router, pages, panels, Inbox, Capture and its offline outbox, item form, settings and connections.
web
37,714 lines
The Hono app: every route, request validation, error-to-status mapping and the live-update stream.
http
2,640 lines
Sign-in with OIDC, sessions, the gate in front of every route, operator and admin access, attachment links.
auth
2,248 lines
The MCP server at /mcp: OAuth for connected apps, consent, grants and the create_item tool.
mcp
1,011 lines
The queue consumer that cleans up and reads captured notes, and the nightly scheduled work.
jobs
1,811 lines
Claude Code, the one outbound engine: the trigger check, the fire request, its refusal wording and reading a hook, reached only through engines/list.ts.
engines
310 lines
The Claude layer behind a project-owned interface: prompts that clean up a note and choose a panel.
ai
1,166 lines
Reads what a note means with Workers AI, so a note that repeats another can be flagged.
embeddings
219 lines
Makes and retries every paid provider call, and records each attempt in D1 for 12 months.
gateway
317 lines
The AccountStore Durable Object, one per account: its SQLite schema, change log, command service, backup and restore.
accounts
18,529 lines
The account data model as plain code: items, panels, dashboards, filings, workspaces and the histories behind them.
domain
2,419 lines
The register in D1 (accounts, users, sign-ins, connector directory): its Drizzle schema and client.
db
398 lines
The composition root where the core meets connectors, with the host connectors run against and the credential crypto.
connectors
1,118 lines
The Worker entry points (worker.ts, index.ts), its bindings type (env.ts) and the share target.
env.ts, worker.ts
404 lines
The contract between web and API: domain types, Zod schemas, command definitions and API shapes.
shared
3,498 lines
The connector SPI: what a connector is and the only capabilities the host offers it.
connector-sdk
385 lines
Shared tsconfig and formatting config for the monorepo; no code runs from it.
config
7 lines
Gmail, in packages/connectors/gmail
Gmail
1,288 lines
Imports
../../../scripts/lib/vitest-ses
sion-reporter.mjs
vitest.config.ts
vitest.contract.config.ts
Claude Code has no package of its own
Claude Code
No package of its own
3 files in the core
Microsoft Teams, in packages/connectors/teams
Microsoft Teams
600 lines
Imports
../../../scripts/lib/vitest-ses
sion-reporter.mjs
vitest.config.ts
vitest.contract.config.ts
packages/connectors/teams/teams-app
Released on its own
Teams app
Its manifest, zipped and uploaded
to Teams by hand.
67
1
1
1
1
1
1
2
1
1
3
1
3
1
9
2
6
1
1
12
1
3
4
1
1 file
2 files