swagger-ui icon indicating copy to clipboard operation
swagger-ui copied to clipboard

File posting has stopped sending the file contents

Open stusta opened this issue 13 years ago • 4 comments

I have an operation with five parameters - three path strings, a header string and a file (parameter type is form). The three path strings and the header value are sent correctly but the content length is now zero. The Content-Type header is set to multipart/form-data (without the boundary section).

This worked fine with a version of Swagger UI from March 2013.

I don't know whether it's problem with Swagger UI or Swagger JS.

stusta avatar Aug 20 '13 13:08 stusta

Yes, file upload is not functioning in the latest 2.0 release. It should be back shortly

fehguy avatar Aug 20 '13 14:08 fehguy

Any progress on this issue?

JeroenMinnaert avatar Sep 20 '13 09:09 JeroenMinnaert

Hi, a generic solution isn't ready yet. There are two quick paths, neither of which are what I call ideal.

  1. To keep posting the file via jquery, bypassing the new js client (and all the authentication work)

  2. To post only smaller files, which would require them to be read into memory.

fehguy avatar Sep 23 '13 15:09 fehguy

fixed in 2.0.3

fehguy avatar Nov 30 '13 06:11 fehguy