HttpRequest
Defined in: index.cts:48
Incoming HTTP request passed to handleHttpRequest.
Extends Node.js stream.Readable — req.pipe(), req.on('data'), and req.on('end') all
work as expected. The body is pre-read by WarpSocket and pushed synchronously as a single
chunk, so the stream is immediately readable without waiting for async I/O.
The API is a useful subset of Node’s http.IncomingMessage. There are no 'data' / 'end'
events beyond what the Readable provides, no access to the underlying socket, and no HTTP/2.
WebSocket upgrade requests are detected automatically and routed through the normal
handleOpen flow — they never reach handleHttpRequest.
Extends
Section titled “Extends”ReadableStream
Properties
Section titled “Properties”method
Section titled “method”method:
string
Defined in: index.cts:49
url:
string
Defined in: index.cts:50
httpVersion
Section titled “httpVersion”httpVersion:
string
Defined in: index.cts:51
httpVersionMajor
Section titled “httpVersionMajor”httpVersionMajor:
number
Defined in: index.cts:52
httpVersionMinor
Section titled “httpVersionMinor”httpVersionMinor:
number
Defined in: index.cts:53
headers
Section titled “headers”headers:
Record<string,string>
Defined in: index.cts:54
rawHeaders
Section titled “rawHeaders”rawHeaders:
string[]
Defined in: index.cts:58
Raw headers as a flat alternating [name, value, name, value, ...] array,
preserving the original wire order. Header names are lowercased (as normalised
by the HTTP/1.1 parser).
remoteAddress
Section titled “remoteAddress”remoteAddress:
string
Defined in: index.cts:59
complete
Section titled “complete”complete:
boolean
Defined in: index.cts:61
Always true — the body is fully pre-buffered before the handler is called.
body:
Buffer
Defined in: index.cts:63
Pre-read full request body. Also available via the Readable stream interface.