This Fetch API interface represents the response to a request.

MDN Reference

interface Response {
    body: null | ReadableStream<Uint8Array<ArrayBufferLike>>;
    bodyUsed: boolean;
    headers: Headers;
    ok: boolean;
    redirected: boolean;
    status: number;
    statusText: string;
    type: ResponseType;
    url: string;
    arrayBuffer(): Promise<ArrayBuffer>;
    blob(): Promise<Blob>;
    bytes(): Promise<Uint8Array<ArrayBufferLike>>;
    clone(): Response;
    formData(): Promise<FormData>;
    json(): Promise<any>;
    text(): Promise<string>;
}

Hierarchy (view full)

Properties

body: null | ReadableStream<Uint8Array<ArrayBufferLike>>
bodyUsed: boolean
headers: Headers
ok: boolean
redirected: boolean
status: number
statusText: string
url: string

Methods