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

Can we add support for object type in HTTP header? #836

Closed
YaoYao-dd opened this issue Nov 15, 2016 · 2 comments
Closed

Can we add support for object type in HTTP header? #836

YaoYao-dd opened this issue Nov 15, 2016 · 2 comments

Comments

@YaoYao-dd
Copy link

I understand its kind of silly, but sometimes it is very useful to pass complex object for GET operation, e.g. JSON Web Token(JWTs).

We can borrow the Consumer definition of Operation, in swagger spec file, if we let header parameter to refer to object type, SwaggerUI can easily show what kind of request is acceptable. Codegen can generate code accordingly. Currently header param only supports String, but we can add type definition. When come to HTTP Content-Type(MIME), we don't really care about it much. Swagger is used to demonstrate interface between client and service provider, SwaggerUI and Editor/Codegen can fill that gap. Actually body and header have no difference at all from user's perspective, just place to hold data. Many thanks.

@webron
Copy link
Member

webron commented Nov 15, 2016

You're in luck, it was already added in #654.

@webron webron closed this as completed Nov 15, 2016
@YaoYao-dd
Copy link
Author

that is wonderful, many thanks.

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

2 participants