-
Notifications
You must be signed in to change notification settings - Fork 6k
Description
Description
[Swift3] Download a binary file does not write that file to disk or return the bytes. When using the scheme: file in the open API Spec, an error is returned. There does not seem to be any support for returning a file or byte[].
Swagger-codegen version
Swift 3 Generator, with Alamofire - CodeGen Version 2.2.3. Open API Spec 2.0
Swagger declaration file content or url
https://gist.github.com/dwoodel/d160a3e792a23681719925e276825d8a
Command line used for generation
java -jar modules/swagger-codegen-cli/target/swagger-codegen-cli.jar generate --input-spec ../swagger.json --lang swift3 --output ../gen
Steps to reproduce
Generate the swift3 code. Attempt to download the file from this end point using the generated API. The file is downloaded, however an error is returned. This error happens to contain the bytes for the file. The method should return a URL to the local file.
Related issues/PRs
No related issues that I can find.
Suggest a fix/enhancement
We have fixed this locally, we will raise a PR shortly. We download the file to disk and return a URL to that file.
CC @wuf810