Skip to content
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

Create serialization strategy for non-body params #665

Closed
fehguy opened this issue Apr 20, 2016 · 4 comments
Closed

Create serialization strategy for non-body params #665

fehguy opened this issue Apr 20, 2016 · 4 comments
Assignees

Comments

@fehguy
Copy link
Contributor

fehguy commented Apr 20, 2016

Follow-up for #564, meta issue #565

@fehguy fehguy added this to the Payload, Path definition proposals milestone Apr 20, 2016
@ePaul
Copy link
Contributor

ePaul commented Jun 20, 2016

@fehguy I think the #564 should be #654 instead. (Feel free to delete this comment after fixing it in the initial comment.)

@ePaul
Copy link
Contributor

ePaul commented Jun 27, 2016

I just found that there currently is an Internet draft discussed in the HTTP working group. This basically defines a format to transport JSON arrays (while omitting the brackets) in HTTP headers.

I guess this could work for custom headers with OpenAPI schema definitions for them, as well as for future official HTTP headers following an RFC coming out of this internet draft.

Note that this defines a serialization scheme just for arrays, not for objects, because that way it works nicely with multiple occurences of a Header, which is equivalent to putting the values together in one, separated by commas.

It will not work for most existing headers using different syntax, for that we would need some different serialization scheme.

It also doesn't help for path parameters (though it could potentially be applied to cookie parameters and form field parameters too).

(originally posted at #652, but @fehguy pointed out it belongs here.)

@dcolens
Copy link

dcolens commented Oct 13, 2016

I bet this was discussed before, but what about using something like http://api.jquery.com/jquery.param/ ?

@fehguy
Copy link
Contributor Author

fehguy commented Feb 1, 2017

Covered in #878

@fehguy fehguy closed this as completed Feb 1, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants