(coerce-request)
(coerce-request f)
Creates an interceptor that coerces the params for the selected route, according to the route's swagger documentation. A coercion function f that acceps the route params schema and a request and return a request can be supplied. The default implementation throws if any coercion error occurs.
Creates an interceptor that coerces the params for the selected route, according to the route's swagger documentation. A coercion function f that acceps the route params schema and a request and return a request can be supplied. The default implementation throws if any coercion error occurs.
(swagger-json)
(swagger-json f)
Creates an interceptor that serves the generated documentation on the path of your choice. Accepts an optional function f that takes the swagger-object and returns a json body.
Creates an interceptor that serves the generated documentation on the path of your choice. Accepts an optional function f that takes the swagger-object and returns a json body.
(swagger-ui & path-opts)
Creates an interceptor that serves the swagger ui on a path of your choice. Note that the path MUST specify a splat argument named "resource" e.g. "my-path/*resource". Acceps additional options used to construct the swagger-object url (such as :app-name :your-app-name), using pedestal's 'url-for' syntax.
Creates an interceptor that serves the swagger ui on a path of your choice. Note that the path MUST specify a splat argument named "resource" e.g. "my-path/*resource". Acceps additional options used to construct the swagger-object url (such as :app-name :your-app-name), using pedestal's 'url-for' syntax.
(validate-response)
(validate-response f)
Creates an interceptor that validates the response for the selected route, according to the route's swagger documentation. A validation function f that accepts the route response schema and a response and return a response can be supplied. The default implementation throws if a validation error occours.
Creates an interceptor that validates the response for the selected route, according to the route's swagger documentation. A validation function f that accepts the route response schema and a response and return a response can be supplied. The default implementation throws if a validation error occours.
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close