interface Request

What was actually handed to fetch — the request, as this session made it.

Properties

verb: string

Upper case, the way HTTP writes it and every log prints it.

url: string

Absolute, already resolved against the page.

headers: ReadonlyMap<string, string>

Lower-cased names, because HTTP says they are the same header either way.

body: string | null

null for the verbs that carry nothing, which is not the same as an empty body.

Usage

import { type Request } from "lib/repl/http-service.ts";