ring-swagger

ring-swagger & compojure-api
2017-12-11T00:46:52.000074Z

Is there a way to specify a request example to the swagger api? Hm, ok yea, thats its own library, cool. I can probably figure this out.

ikitommi 2017-12-11T05:45:35.000036Z

You can attach any extra keys with namespace json-schema to the spec records and they are written to api-docs. e.g.

(s/def ::int
  (st/spec
      {:spec integer?
       :name "integer"
       :description "it's an int"
       :json-schema/default 42
       :json-schema/example 99}))