Request class

The interface of the Fetch API represents a resource request. You can create a new object using the Request() constructor, but you are more likely to encounter a object being returned as the result of another API operation, such as a service worker FetchEvent.request.

Implemented types
Available extensions
Annotations
  • @JS()
  • @staticInterop

Constructors

Request(dynamic input, [RequestInit? init])
factory

Properties

body ReadableStream?

Available on Body, provided by the PropsBody extension

no setter
bodyUsed bool

Available on Body, provided by the PropsBody extension

no setter
cache RequestCache

Available on Request, provided by the PropsRequest extension

no setter
credentials RequestCredentials

Available on Request, provided by the PropsRequest extension

no setter
destination RequestDestination

Available on Request, provided by the PropsRequest extension

no setter
hashCode int
The hash code for this object.
no setterinherited
headers Headers

Available on Request, provided by the PropsRequest extension

no setter
integrity String

Available on Request, provided by the PropsRequest extension

no setter
isHistoryNavigation bool

Available on Request, provided by the PropsRequest extension

no setter
isReloadNavigation bool

Available on Request, provided by the PropsRequest extension

no setter
keepalive bool

Available on Request, provided by the PropsRequest extension

no setter
method String

Available on Request, provided by the PropsRequest extension

no setter
mode RequestMode

Available on Request, provided by the PropsRequest extension

no setter
priority FetchPriority

Available on Request, provided by the PropsRequest extension

no setter
redirect RequestRedirect

Available on Request, provided by the PropsRequest extension

no setter
referrer String

Available on Request, provided by the PropsRequest extension

no setter
referrerPolicy ReferrerPolicy

Available on Request, provided by the PropsRequest extension

no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
signal AbortSignal

Available on Request, provided by the PropsRequest extension

no setter
url String

Available on Request, provided by the PropsRequest extension

no setter

Methods

arrayBuffer() Future<ByteBuffer>

Available on Body, provided by the PropsBody extension

blob() Future<Blob>

Available on Body, provided by the PropsBody extension

clone() Request

Available on Request, provided by the PropsRequest extension

formData() Future<FormData>

Available on Body, provided by the PropsBody extension

json() Future

Available on Body, provided by the PropsBody extension

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
text() Future<String>

Available on Body, provided by the PropsBody extension

toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited