Canned HTTP responses
Furnace framework ยป HTTP server

Prev:HTTP responder filters
Next:HTTP responder redirection


The http.server.responses vocabulary provides constructors for a few useful response objects.

For successful responses:
<content> ( body content-type -- response )

<text-content> ( body -- response )

<html-content> ( body -- response )


For errors:
<304> ( -- response )

<403> ( -- response )

<400> ( -- response )

<404> ( -- response )


The http.server.responses already provides many more canned responses. New error responses like the above can be created for other error codes too:
<trivial-response> ( code message -- response )