Interface FetchCeiling

The scope a host grants fetch under.

interface FetchCeiling {
    domains: string[] | "*";
    methods?: HttpMethod[];
    maxRequestBytes?: number;
    approval?: EffectApproval;
    maxResponseBytes?: number;
    maxRedirects?: number;
    timeoutMs?: number;
}

Properties

domains: string[] | "*"

Hosts a forged tool may reach, matched exactly and case-insensitively; '*' is every host; [] grants nothing.

methods?: HttpMethod[]

Methods a forged tool may send. POST, PUT, PATCH and DELETE change state: they need an isolating executor, maxRequestBytes and approval.

Default

['GET', 'HEAD']
maxRequestBytes?: number

A state-changing request's body larger than this is refused before anything is sent. Required beside a state-changing method, refused without one.

approval?: EffectApproval

Required beside a state-changing method.

maxResponseBytes?: number

A response body larger than this is refused while it streams.

Default

5_242_880
maxRedirects?: number

Redirects the broker follows, each one checked like the first request.

Default

5
timeoutMs?: number

One request's time bound, redirects included; at most 2_147_483_647 (Node's longest timer delay).

Default

30_000