Prox OS Docs
Architecture

Monorepo Workspace Guide

Catalog **deployable apps**, **shared packages**, how they connect, how to run them locally, and where to open source for each concern. This complements [packag

Purpose

Catalog deployable apps, shared packages, how they connect, how to run them locally, and where to open source for each concern. This complements package-graph.md (boundary rules) and core-architecture-thinking.md (philosophy).

Workspace Layout

Managed by pnpm (pnpm-workspace.yaml: apps/*, packages/*, tools/*) and Turborepo / Nx task orchestration (turbo run, pnpm nx).

prox-os/
├── apps/           # Deployable or standalone runtimes
├── packages/       # Shared libraries (imported, not deployed alone)
├── docs/           # Canonical documentation (synced to apps/docs)
├── scripts/        # docs sync, arch generators, quality checks
└── AGENTS.md       # Agent + contributor rules (stronger than this doc)

Deployable Apps

PathPackageRoleDefault devKey entry
apps/os-shell@prox-os/os-shellBrowser OS shell: desktop, windows, registry, routingpnpm dev:os (port 3000)src/index.tsx, src/apps/registry.ts, src/router.tsx
apps/api-worker@prox-os/api-workerCloudflare Worker API (Hono)pnpm dev:apisrc/index.ts, wrangler.jsonc
apps/docs@prox-os/docsFumadocs site (mirrors docs/)pnpm dev:docs (port 3100)content/docs/, source.config.ts
apps/ui-workshop@prox-os/ui-workshopStorybook for os-ui / tokenspnpm dev:uiStorybook config under app
apps/esmadrider-me@prox-os/esmadrider-meFounder static site; iframe apppnpm dev:esmadrider-meVite app; VITE_PROX_OS_URL for OS CTA

Why api-worker lives under apps/ not packages/: it is a deployable HTTP service with its own Wrangler config, env bindings, and production URL — same category as os-shell and docs, not a library consumed via import. Shared server logic belongs in packages/* (e.g. future packages/os-actions, packages/db).

Shared Packages (selected)

PathPackageRoleKey entry
packages/app-contract@prox-os/app-contractManifest, window, permission types (no React)src/index.ts
packages/app-registry@prox-os/app-registryIframe manifest templates + URL resolutionsrc/manifests/*
packages/os-apps@prox-os/os-appsOfficial OS apps (in-window UI)src/index.ts, per-app manifest.ts
packages/os-ui@prox-os/os-uiShell UI primitivessrc/index.ts
packages/design-tokens@prox-os/design-tokens--os-* CSS + Tailwind bridgecss/prox.css
packages/db@prox-os/dbDrizzle/Neon (planned)schema TBD
packages/storageObject storage abstraction (planned)placeholders

How Pieces Connect

flowchart LR
  subgraph browser [Browser]
    Shell[apps/os-shell]
  end
  subgraph packages [Packages]
    Contract[app-contract]
    Registry[app-registry]
    OsApps[os-apps]
    OsUi[os-ui]
    Tokens[design-tokens]
  end
  subgraph deploy [Deployables]
    API[apps/api-worker]
    DocsSite[apps/docs]
    Workshop[ui-workshop]
    Founder[esmadrider-me]
  end
  Shell --> Registry
  Shell --> OsApps
  Shell --> OsUi
  Shell --> Tokens
  Registry --> Contract
  OsApps --> Contract
  OsApps --> OsUi
  OsUi --> Tokens
  Shell -.iframe.-> Founder
  Shell -.dev iframe.-> DocsSite
  Shell -.dev iframe.-> Workshop
  Shell -.future HTTP.-> API

OS Shell Internal Map

ConcernLocation
App registry compositionapps/os-shell/src/apps/registry.ts
Local app renderersapps/os-shell/src/apps/localAppComponents.tsx
Window + Spaces storeapps/os-shell/src/window-manager/store.ts
Shell controllerapps/os-shell/src/shell/useDesktopShellController.ts
Global shortcutsapps/os-shell/src/shell/GlobalShortcuts.tsx
Cmd+K app listapps/os-shell/src/shell/command/commandPaletteApps.ts
Boot appearanceapps/os-shell/src/browser-local/applyBootShellAppearance.ts
Session / login overlayapps/os-shell/src/shell/session/*
Design tokens on <html>shell/settings/useShellSettingsState.ts

Common Commands

pnpm install
pnpm dev:os          # OS shell
pnpm dev:api         # API worker (Wrangler)
pnpm dev:docs        # docs:sync + Fumadocs dev server
pnpm dev:ui          # UI workshop / Storybook
pnpm typecheck
pnpm lint
pnpm docs:sync       # docs/ → apps/docs/content/docs
pnpm build:docs
pnpm arch:check      # dependency-cruiser boundaries

Repo-wide tasks prefer turbo run <task> per AGENTS.md.

Production Domains (direction)

Official subdomains are infrastructure entrypoints, not per-app identity. Creator-owned path namespaces are the preferred long-term model for public app URLs. See app-namespace-and-domain-strategy.md.

HostTypical deployableShell visibility
User OSapps/os-shell (Pages)Primary product
api.prox-os.comapps/api-workerHTTP client from apps; not embedded as UI
docs.prox-os.comapps/docsPublic docs; dev team may also use /app-dev/docs iframe locally
ui.prox-os.comapps/ui-workshop buildDesign QA; dev iframe in shell
Scalar / OpenAPIOften api-worker /docs or separateProduction: omit from user registry; use /app-dev/* + Cloudflare Access

See cloudflare-deploy-and-access.md for the Cloudflare project names, Access boundaries, API docs exposure policy, and manual dashboard follow-up.

Adding a New App (checklist)

  1. Implement under packages/os-apps (or shell local-module if shell-coupled).
  2. Add manifest to apps/os-shell/src/apps/registry.ts and types.ts ShellAppId.
  3. Wire localAppComponents.tsx and packages/os-ui ShellAppIcon if needed.
  4. Cmd+K picks up registry automatically via getCommandPaletteApps().
  5. Update app-registry.md and run pnpm docs:sync if user-facing docs change.

See .agents/skills/prox-os-shell-workflows/SKILL.md for the full shell checklist.

On this page