Skip to content

@loontail/minecraft-kit v0.5.0 / HttpResponse

Interface: HttpResponse

Response delivered by the HttpClient interface.

Properties

PropertyModifierType
headersreadonlyReadonly<Record<string, string>>
statusreadonlynumber
urlreadonlystring

Methods

bytes()

ts
bytes(): Promise<Uint8Array>

Returns

Promise<Uint8Array>

Source

src/types/http.ts:11


json()

ts
json<T>(): Promise<T>

Type parameters

Type parameterValue
Tunknown

Returns

Promise<T>

Source

src/types/http.ts:10


stream()

ts
stream(): AsyncIterable<Uint8Array>

Stream the body. The stream may be consumed at most once.

Returns

AsyncIterable<Uint8Array>

Source

src/types/http.ts:13


text()

ts
text(): Promise<string>

Returns

Promise<string>

Source

src/types/http.ts:9

MIT License