Raw bytes (a [] u8 or a string) with a content type of your choice. The bytes must stay
valid until the response is written.
- body: a
[] u8or astring, sent as it is. - content_type: the
Content-Typeheader value. - status: the HTTP status code.
bytes_response :: (body: $T, content_type: string, status := 200) -> Response
Raw bytes (a [] u8 or a string) with a content type of your choice. The bytes must stay
valid until the response is written.
Parameters
- body: $T
- a
[] u8or astring, sent as it is. - content_type: string
- the
Content-Typeheader value. - status := 200
- the HTTP status code.