Request

@Serializable
data class Request(val url: String, val urlFragment: String? = null, val method: String, val headers: Map<String, JsonElement>, val postData: String? = null, val hasPostData: Boolean? = null, val postDataEntries: List<Network.PostDataEntry>? = null, val mixedContentType: Security.MixedContentType? = null, val initialPriority: Network.ResourcePriority, val referrerPolicy: String, val isLinkPreload: Boolean? = null, val trustTokenParams: Network.TrustTokenParams? = null, val isSameSite: Boolean? = null)

HTTP request data.

Constructors

Link copied to clipboard
constructor(url: String, urlFragment: String? = null, method: String, headers: Map<String, JsonElement>, postData: String? = null, hasPostData: Boolean? = null, postDataEntries: List<Network.PostDataEntry>? = null, mixedContentType: Security.MixedContentType? = null, initialPriority: Network.ResourcePriority, referrerPolicy: String, isLinkPreload: Boolean? = null, trustTokenParams: Network.TrustTokenParams? = null, isSameSite: Boolean? = null)

Properties

Link copied to clipboard
val hasPostData: Boolean? = null

True when the request has POST data. Note that postData might still be omitted when this flag is true when the data is too long.

Link copied to clipboard
val headers: Map<String, JsonElement>

HTTP request headers.

Link copied to clipboard

Priority of the resource request at the time request is sent.

Link copied to clipboard
val isLinkPreload: Boolean? = null

Whether is loaded via link preload.

Link copied to clipboard
val isSameSite: Boolean? = null

True if this resource request is considered to be the 'same site' as the request corresponding to the main frame.

Link copied to clipboard

HTTP request method.

Link copied to clipboard

The mixed content type of the request.

Link copied to clipboard
val postData: String? = null

HTTP POST request data. Use postDataEntries instead.

Link copied to clipboard

Request body elements (post data broken into individual entries).

Link copied to clipboard

The referrer policy of the request, as defined in https://www.w3.org/TR/referrer-policy/

Link copied to clipboard

Set for requests when the TrustToken API is used. Contains the parameters passed by the developer (e.g. via "fetch") as understood by the backend.

Link copied to clipboard
val url: String

Request URL (without fragment).

Link copied to clipboard
val urlFragment: String? = null

Fragment of the requested URL starting with hash, if present.