macchiato.middleware.restful-format
accepts
concat-stream
ct
default-accept-types
default-content-types
format-response-body
(format-response-body node-request response accept-types)
infer-request-content-type
(infer-request-content-type headers content-types)
infer-response-content-type
(infer-response-content-type body accept-types)
parse-request-content
parse-response-content
wrap-restful-format
(wrap-restful-format handler & [{:keys [content-types accept-types keywordize?]}])
attempts to infer the request content type using the content-type header serializes the response based on the first known accept header optional keys: :content-types a set of strings matching the content types :accept-types a vector of accept types to match in the desired order :keywordize? a boolean specifying whether to keywordized parsed request