-
Notifications
You must be signed in to change notification settings - Fork 74
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Multiple File upload thought form-data #474
Comments
You can put as many fields as you want in the arguments schema (data_1, data_2,...). flask-smorest/tests/test_arguments.py Lines 265 to 275 in a6df3cf
|
@lafrech Yes, and I am using it for another file field in form-data. However, what if I have 10-20 zip archives and I want to serialize them in list-type instance Somthing like this |
I think you can use:
and
|
@alwin48 The method mentioned is a feasible one, but here's a method that's closer to what we actually want. Here's how I did it, sharing it for everyone's reference.
e.g |
I'm currently using flask_smorest.fields.Upload to handle file uploads, but this only allows selecting a single file. Is it possible to upload many files?
I am trying to upload multiple zip archives serializing request with
flask_smorest.fields.Upload
, in resources im use blueprint arguments with@blp.arguments(UploadShema, location="files")
and getting file withf = files["data"]
. But the issue isf
returns only first file added thought form-data.How could this issue be resolved?
The text was updated successfully, but these errors were encountered: