You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm new to Typescript/Javascript (Java Dev), but I'm trying to keep my development as DRY as possible.
I already know that my Express code works and can do 'multipart/form-data' file uploads, via the '@uploadedfiles' decorator, however, I'd like to see that reflected in the OpenAPI spec, output by your project, so any client code I generate will be aware of it (i.e. 'multipart/form-data').
How can I achieve the addition of 'multipart/form-data' programmatically, using routing-controllers-openapi/routing-controllers?
Hi, handling @UploadedFile/ @UploadedFiles would indeed make a great addition, thanks for the suggestion! We'd probably need to extend the getRequestBody function to check for said decorators (route.params.filter(d => ['file', 'files'].includes(d.type)) and merge the multipart/form-data block you linked into the return object (along the existing application/json block).
Would be happy to merge in a PR if anyone gets around implementing this!
Hello @epiphone , how can I achieve additional 'multiple data / form data' using the router-controller-openapi / routing controller? Could you example me
Thank you
I'm new to Typescript/Javascript (Java Dev), but I'm trying to keep my development as DRY as possible.
I already know that my Express code works and can do 'multipart/form-data' file uploads, via the '@uploadedfiles' decorator, however, I'd like to see that reflected in the OpenAPI spec, output by your project, so any client code I generate will be aware of it (i.e. 'multipart/form-data').
How can I achieve the addition of 'multipart/form-data' programmatically, using routing-controllers-openapi/routing-controllers?
See https://swagger.io/docs/specification/describing-request-body/multipart-requests
The text was updated successfully, but these errors were encountered: