-
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
rfc6570 template clarification requested for the parameter styles, cookie use case unclear #2940
Comments
|
@spacether OAS 3.x does not use RFC 6570 URI Template syntax. That Swagger documentation is just saying that certain RFC 6570 template syntaxes are equivalent to certain |
If they are identical in implementation, openapi gives no specific step by step directions on how to serialized the data and rfc 6570 is mentioned then it looks to me like the spec does use it. If so can the spec specifically mention that sterilization uses the rfc 6570? If they do not use it and serialization does not conform to the rfc, can that be mentioned and can direction on how to serialize/or the rfc that is being used be linked to? |
@spacether the specification already cites the parts of RFC 6570 that is uses, in the places where it is used. This usage is not the full RFC 6570 syntax. OAS URL Templating syntax is defined in the OAS itself. There's a limit to how much the spec can and should talk about what RFCs it doesn't use. But I'll leave this open (I don't think I actually meant to close it - sorry, was closing a lot of issues and probably hit it on autopilot) and tag it as a |
@spacether I have finally had time to dig into this in depth, and agree that there are aspects of the correlation with RFC 6570 that are not clear (see also issue #3759, for example). I'm gathering up parameter serialization clarification requests for the patch releases so I'll throw this on the pile. |
Thanks! |
PR merged for 3.0.4 and ported to 3.1.1 via PR #3921! |
Hello there. Can we get some clarification on:
I am asking because the swagger docs show examples:
https://swagger.io/docs/specification/serialization/
And in the query parameter examples we see:
Yet for cookie parameters values lack the ? prefix.
This is not consistent with the examples given in rcf6570 for form style {?var} or {&var} expansion
Those expansions require the ? or & prefix with values like:
{?var} -> {?id} ->
{?id*} ?id=3&id=4&id=5
{?id} -> ?id=3,4,5
{&var} -> {&id} ->
{&var*} &id=3&id=4&id=5
{&var} &id=3,4,5
If we are meant to exclude those prefixes, and use form styles please provide the uri templates and direction.
The openapi spec omits the ? prefix from the form examples of serialized data though they are needed in style form query parameter serialization.
Header Question:
Also, what should None serialize to in a header? In a path it is empty string. In a header should the value be empty string or should it be omitted?
Related issues:
The text was updated successfully, but these errors were encountered: