RequestInit

Interfacein globals@fastly/js-compute 4.0.0View source

Constructor parameter for Request

This contains information to send along with the request (Headers, body, etc...), as well as Fastly specific information.

Properties

body

BodyInit | nulloptionalView source

A BodyInit object or null to set request's body.

headers

HeadersInitoptionalView source

A Headers object, an object literal, or an array of two-item arrays to set request's headers.

method

stringoptionalView source

A string to set request's method.

backend

string | BackendoptionalView source

The Fastly configured backend name or instance the request should be sent to.

Fastly-specific cache override configuration for this request.

cacheKey

stringoptionalView source

Fastly-specific cache key override for this request.

fastly

{ decompressGzip?: boolean }optionalView source

Fastly-specific options.

  • decompressGzip optional: boolean — Whether to automatically gzip decompress the response.

manualFramingHeaders

booleanoptionalView source

Controls how framing headers (Content-Length, Transfer-Encoding) are determined. When true, any provided framing headers will be honored instead of being automatically set based on the body.

imageOptimizerOptions

ImageOptimizerOptionsoptionalsince 3.36.0View source

Fastly Image Optimizer transformation options to apply to the response.