Files
ChatLab/packages
digua 9afabedca8 feat(server): extract standalone HTTP API from Electron
Create packages/server/src/http/ with platform-agnostic HTTP API:
- errors.ts: error codes and response helpers
- auth.ts: Bearer token auth using @openchatlab/config
- server.ts: Fastify factory with auth hook and error handler
- routes/system.ts: status and schema endpoints
- routes/sessions.ts: 7 session endpoints using DatabaseManager + core
- index.ts: server lifecycle (startHttpServer/stopHttpServer)

Add token field to @openchatlab/config apiConfigSchema.
Add fastify dependency to packages/server.
2026-05-11 20:28:26 +08:00
..