Ring-swagger Api Documentation

Version: 0.22.3

ring.swagger.upload

->Upload

(->Upload m)

Positional factory function for class ring.swagger.upload.Upload.

ByteArrayUpload

Schema for file param created by ring.middleware.multipart-params.byte-array store.

map->Upload

(map->Upload m__6289__auto__)

Factory function for class ring.swagger.upload.Upload, taking a map of keywords to field values.

TempFileUpload

Schema for file param created by ring.middleware.multipart-params.temp-file store.

wrap-multipart-params

(wrap-multipart-params handler)(wrap-multipart-params handler options)

Middleware to parse multipart parameters from a request. Adds the following keys to the request map:

:multipart-params - a map of multipart parameters :params - a merged map of all types of parameter

The following options are accepted

:encoding - character encoding to use for multipart parsing. If not specified, uses the request character encoding, or “UTF-8” if no request character encoding is set.

:store - a function that stores a file upload. The function should expect a map with :filename, content-type and :stream keys, and its return value will be used as the value for the parameter in the multipart parameter map. The default storage function is the temp-file-store.