Skip to content

HttpResponse

//fluxbase-kotlin/io.github.nimbleflux.fluxbase.core/HttpResponse

[jvm]
data class HttpResponse(val body: String, val status: Int, val headers: Map<String, String>)

A raw HTTP response: the body as text plus the status code and response headers.

The transport returns text (not a deserialized object) because generic deserialization requires reified type parameters, which an interface can’t provide. FluxbaseHttpClient wraps the transport and adds reified typed methods (inline fun <reified T>) that deserialize this body via kotlinx.serialization.

HttpResponse [jvm]
constructor(body: String, status: Int, headers: Map<String, String>)
Name Summary
body [jvm]
val body: String
headers [jvm]
val headers: Map<String, String>
status [jvm]
val status: Int