mirror of
https://github.com/deepseek-ai/deepseek-harness
synced 2026-08-15 21:04:50 +00:00
connection binds the web transport: it injects httpServer + apiProxy and registers toFetchHandler(ctx.apiProxy) under the /api prefix (the node:http to fetch bridge moves in from the webserver, keeping the res-close disconnect detection and drain/close backpressure waits). hmr owns dev reload: a stat-poll watch per graph row driven by clientModuleHost.onGraphChanged, rebuilt(id) on content change, and the /plugins/events SSE route (GET/HEAD guarded); frame types are single-sourced in events.ts shared by both halves.
9 lines
349 B
TypeScript
9 lines
349 B
TypeScript
/**
|
|
* The /api URL prefix — single source for both halves of the web transport.
|
|
* The node half registers this prefix on the web server; browser-side path
|
|
* literals currently live in the apiproxy client layer (out of scope here).
|
|
*/
|
|
|
|
/** Route prefix owning every api request (`/api` and `/api/<anything>`). */
|
|
export const API_PATH = '/api'
|