Fork me on GitHub
#ring-swagger
<
2020-07-30
>
hoopes23:07:15

Hi, i have a resource that looks like

(def token-routes
  (context "/token" []
    (resource                                                                                                                                                                                                 {:coercion :spec                                                                                                                                                                                          :post {:parameters {:body-params ::tok-spec/login-params}                                                                                                                                                       :responses {200 {:schema ::tok-spec/token-resp}}
             :handler create-token}})))
Where the ::tok-spec/login-params has login and password keys. I get swagger that looks like this image. (My project is called trackme). Is there a way to change that full spec name?

hoopes23:07:02

Additionally, the data is not coerced to the ::tok-spec/token-resp shape automatically - is that expected to be done by hand? I’d basically expect it to act like schema-tools/select-schema . Any help here would be appreciated greatly!