Liking cljdoc? Tell your friends :D

cmr.http.kit.response

This namespace defines a default set of transform functions suitable for use in presenting results to HTTP clients.

Note that ring-based middleeware may take advantage of these functions either by single use or composition.

This namespace defines a default set of transform functions suitable for use
in presenting results to HTTP clients.

Note that ring-based middleeware may take advantage of these functions either
by single use or composition.
raw docstring

add-headerclj

(add-header response field value)
source

client-handlerclj

(client-handler response)
(client-handler response err-handler)
(client-handler {:keys [status headers body error]} err-handler parse-fn)
source

corsclj

(cors request response)
source

errorclj

(error error)
source

error-handlerclj

(error-handler status headers body)
(error-handler status headers body default-msg)
source

errorsclj

(errors errors)
source

htmlclj

(html request data)
(html _request process-fn data)
source

identity-handlerclj

source

jsonclj

(json request data)
(json _request process-fn data)
source

json-errorsclj

(json-errors body)
source

json-handlerclj

source

maybe-derefclj

(maybe-deref maybe-ref)
source

not-allowedclj

(not-allowed message)
(not-allowed message other-errors)
source

not-foundclj

(not-found _request)
source

okclj

(ok _request & args)
source

parse-json-bodyclj

(parse-json-body body)
source

parse-xml-bodyclj

(parse-xml-body body)
source

process-err-resultsclj

(process-err-results data)
source

process-ok-resultsclj

(process-ok-results data)
source

process-resultsclj

(process-results data)
(process-results err-fn data)
(process-results err-fn ok-fn data)
source

soft-reference->json!clj

(soft-reference->json! obj json-generator)

Given a soft reference object and a Cheshire JSON generator, write the data stored in the soft reference to the generator as a JSON string.

Note, however, that sometimes the value is not a soft reference, but rather a raw value from the response. In that case, we need to skip the object conversion, and just do the realization.

Given a soft reference object and a Cheshire JSON generator, write the
data stored in the soft reference to the generator as a JSON string.

Note, however, that sometimes the value is not a soft reference, but rather
a raw value from the response. In that case, we need to skip the object
conversion, and just do the realization.
sourceraw docstring

stream->strclj

(stream->str body)
source

textclj

(text request data)
(text _request process-fn data)
source

version-media-typeclj

(version-media-type response value)
source

xml-errorsclj

(xml-errors body)
source

xml-handlerclj

source

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close