Skip to content

FsRequest

FsRequest = { flags: OpenFlags; id: number; path: string; type: "open"; } | { count: number; fd: number; id: number; offset: number; type: "read"; } | { data: Uint8Array; fd: number; id: number; offset: number; type: "write"; } | { fd: number; id: number; type: "close"; } | { id: number; path: string; type: "stat"; } | { id: number; path: string; type: "readdir"; } | { id: number; path: string; type: "mkdir"; } | { id: number; path: string; type: "remove"; } | { id: number; newPath: string; oldPath: string; type: "rename"; } | { changes: Partial<StatChanges>; id: number; path: string; type: "wstat"; }

Defined in: packages/runtime/src/container/proxy.ts:124

One request message on the wire — discriminated union, one variant per Fileserver method.

id is the client-assigned correlation ID that pairs a request with its FsResponse. fd values are proxy-local integers issued by the server’s exportFS side; they are NOT the real fd tokens.