fix example

This commit is contained in:
Tommi Reiman 2023-08-18 15:17:01 +03:00
parent 12f0970e39
commit 81dfe45b72

View file

@ -160,12 +160,12 @@ You can also specify request and response body schemas per content-type. The syn
(ring/router (ring/router
["/api" ["/api"
["/example" {:post {:coercion reitit.coercion.schema/coercion ["/example" {:post {:coercion reitit.coercion.schema/coercion
:request {:content {"application/json" {:y s/Int} :request {:content {"application/json" {:schema {:y s/Int}}
"application/edn" {:z s/Int}} "application/edn" {:schema {:z s/Int}}}
;; default if no content-type matches: ;; default if no content-type matches:
:body {:yy s/Int}} :body {:yy s/Int}}
:responses {200 {:content {"application/json" {:w s/Int} :responses {200 {:content {"application/json" {:schema {:w s/Int}}
"application/edn" {:x s/Int}} "application/edn" {:schema {:x s/Int}}}
;; default if no content-type matches: ;; default if no content-type matches:
:body {:ww s/Int}}} :body {:ww s/Int}}}
:handler ...}}]] :handler ...}}]]