The one JSON error body (BOU-586), as data:
{:error {:type "not-found" :message "..." :details {...} :correlation-id "..." :dev {...}}}
No JSON encoding here, so a library can answer with it without the HTTP
stack (BOU-930). wagoe.platform.core.http.errors delegates to these.
The one JSON error body (BOU-586), as data:
{:error {:type "not-found" :message "..." :details {...}
:correlation-id "..." :dev {...}}}
No JSON encoding here, so a library can answer with it without the HTTP
stack (BOU-930). `wagoe.platform.core.http.errors` delegates to these.(body type message)(body type message {:keys [details correlation-id dev]})The error body. details is left out when empty.
The error body. `details` is left out when empty.
(error-body? b)Whether b is in the one shape — with keyword or string keys, so it can
judge a decoded JSON body as well as a map.
Whether `b` is in the one shape — with keyword or string keys, so it can judge a decoded JSON body as well as a map.
(response status type message)(response status type message {:keys [correlation-id] :as opts})A Ring response carrying body. No Content-Type: muuntaja encodes a map
body only when none is set (ZZP-120). The correlation id, when given, is
echoed in the X-Correlation-ID header too.
A Ring response carrying `body`. No Content-Type: muuntaja encodes a map body only when none is set (ZZP-120). The correlation id, when given, is echoed in the X-Correlation-ID header too.
(status->type status)The :type a handler that knows only its status answers with: ADR-022's
vocabulary where it has a word, :validation-error for any other 4xx and
:internal-error for any other 5xx.
The `:type` a handler that knows only its status answers with: ADR-022's vocabulary where it has a word, `:validation-error` for any other 4xx and `:internal-error` for any other 5xx.
(type-name t):not-found -> "not-found"; a qualified keyword keeps its namespace.
`:not-found` -> "not-found"; a qualified keyword keeps its namespace.
cljdoc builds & hosts documentation for Clojure/Script libraries
| Ctrl+k | Jump to recent docs |
| ← | Move to previous article |
| → | Move to next article |
| Ctrl+/ | Jump to the search field |