Open ivan-mladenovic opened 6 years ago
When it comes to download, there is a way to do it. Define a raml part like this:
get:
responses:
200:
body:
application/octet-stream:
type: file
and you will get decorator generated like this:
@RequestMapping(value = "", method = RequestMethod.GET)
public ResponseEntity<?> getObject() {
return this.returnControllerDelegate.getObject();
}
So you got return type: ResponseEntity<?>
and you can return a byte[]
from your implementation.
This is more like a workaround and it's not ideal since generated code should enforce you to return a file (or byte[]).
Please add possibility to download and upload file by using RAML endpoints definition.