-
Notifications
You must be signed in to change notification settings - Fork 9.1k
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
Can we get clarification on how to post multipart/form-data containing an array of items of type X? #2840
Comments
Form here in the spec:
It looks like explode=True for multipart form arrays of files. |
explode=True is not working for multipart/form-data request |
The I'm fairly certain that means that the cases asked about in this issue are all invalid. |
style is defined as Also this issue asks for clarification when style is unset. If the answer is to point to an RFC that is fine, but the RFCs that I looked at lacked these examples. |
@spacether I see what's going on here. In OAS 3.0, So if @MHamzaRajput is using OAS 3.0, that would explain why Regarding your questions (in the context of OAS 3.1):
|
At minimum, a bit of clarification on the expected string form of boolean and null values is probably worth including in a patch release, so I'm labeling this appropriately. Even if that clarification ends up being "do whatever works for your environment." For example, Perl does not have a boolean type, so it's not always possible to round-trip JSON-like booleans. |
PR merged for 3.0.4 and ported to 3.1.1 via PR #3921! |
Can we get clarification on how to post multipart form data with an array of items of type X?
Here is an example requestBody:
1 What if x is a boolean?
2. Are the rfc accepted string serializations for booleans or should we use json?
3. What if X is multipart/octet-stream binary data, should the array be exploded? If so should the name be files or files[]?
4. If x is type string, should the array serialized with explode = True or False?
5. When should explode be true and when should it be false for multipart form data?
6. What count as primitive types aside from strings? int? float? bool? null?
7. Should empty arrays be sent with json content-type because explode would not send their data?
Any actual examples including the data sent in each multipart section would be a great help.
It looks like this PR is related:
#2066
The text was updated successfully, but these errors were encountered: