How limlll/codex-webui works
Codex WebUI is a browser interface for OpenAI Codex CLI: users authenticate, open or create threads, submit turns, and follow live results, approvals, and conversation history. Separate product workflows cover message-level branching, workspace file operations and previews, terminal sessions, and integrations such as plugins and MCP servers. The backend exposes REST and Socket.IO, delegates Codex operations to its app-server child, and uses SQLite for persistent application state. README documents these capabilities; sampled excerpts confirm only selected controller, service, and process-manager links, so other subsystem wiring is kept conservative.
Main entry points: api-client.ts REST client · thread-view.tsx Thread interface · threads.service.ts Thread operations · files.controller.ts File endpoints
Components 27
Browser client
- Web application
web/src/App.tsx - Thread interface
web/src/routes/thread-view.tsx - REST client
web/src/api-client.ts - Live socket
web/src/socket.ts
Conversation runtime
- Thread endpoints
src/threads/threads.controller.ts - Thread operations
src/threads/threads.service.ts - Conversation branches
src/conversation-branches/conversation-branches.service.ts - Approval handling
src/pending-approvals/pending-approvals.service.ts - Codex facade
src/codex/codex.service.ts - Codex process manager
src/codex/codex-process-manager.service.ts
Workspace tools
- File workspace UI
web/src/components/files/files-panel.tsx - File endpoints
src/files/files.controller.ts - File operations
src/files/files.service.ts - Archive browsing
src/archive/archive.service.ts - Terminal UI
web/src/components/terminal/terminal-workspace.tsx - Terminal gateway
src/terminal/terminal.gateway.ts - Terminal sessions
src/terminal/terminal.service.ts
Configuration integrations
- Plugin marketplace
src/plugins/plugins.controller.ts - MCP management
src/mcp-servers/mcp-servers.controller.ts - Apps connectors
src/apps/apps.controller.ts - Apps service
src/apps/apps.service.ts - Office editor bridge
src/onlyoffice/onlyoffice.controller.ts
Service platform
- Runtime settings
src/settings/settings.service.ts - Authentication
src/auth/auth.module.ts - SQLite state
src/database/database.service.ts
Other components
- User
- Codex app-server
Connections 28
- User → Web application: uses
- Web application → Thread interface: opens
- Thread interface → REST client: requests
- Thread interface → Live socket: subscribes
- REST client → Thread endpoints: REST calls
- Thread endpoints → Thread operations: delegates
- Thread operations → Codex facade: Codex operations
- Codex facade → Codex process manager: requests
- Codex process manager → Codex app-server: JSON-RPC
- Thread operations → Conversation branches: branch operations
- Thread interface → Approval handling: approval actions
- REST client → File endpoints: REST calls
- File workspace UI → REST client: file requests
- File endpoints → File operations: delegates
- File endpoints → Archive browsing: archive operations
- Terminal UI → Live socket: connects
- Live socket → Terminal gateway: Socket.IO
- Terminal gateway → Terminal sessions: session operations
- REST client → Plugin marketplace: REST calls
- REST client → MCP management: REST calls
- REST client → Apps connectors: REST calls
- Apps connectors → Apps service: delegates
- Apps service → Codex facade: JSON-RPC methods
- REST client → Office editor bridge: editor requests
- Office editor bridge → File operations: validates paths
- Office editor bridge → Runtime settings: reads settings
- Thread operations → SQLite state: persists state
- Authentication → REST client: guards API