[csharp] - fix json encoding override on form params#5217
[csharp] - fix json encoding override on form params#5217milesressler wants to merge 1 commit intoOpenAPITools:masterfrom
Conversation
|
👍 Thanks for opening this issue! The team will review the labels and make any necessary changes. |
| public boolean isFormParam, isQueryParam, isPathParam, isHeaderParam, | ||
| isCookieParam, isBodyParam, hasMore, isContainer, | ||
| secondaryParam, isCollectionFormatMulti, isPrimitiveType, isModel, isExplode; | ||
| secondaryParam, isCollectionFormatMulti, isPrimitiveType, isModel, isExplode, jsonEncoding; |
There was a problem hiding this comment.
In OAI 3.0, encoding can be specified besides application/json, so this method seems to have low extensibility.
This change will affect the entire openapi-generator and will require a maintainers review.
cc. @wing328 @jimschubert
There was a problem hiding this comment.
I agree. If you need custom logic, I think a vendor extension would be more appropriate.
There was a problem hiding this comment.
Not quite sure I follow - from what I read about vendor extensions on the docs, they are meant for functionality that is not covered by the standard OpenAPI Specification . This isn't custom logic, this is functionality that is part of the OAI specification, and is currently ignored by the OAI generator.
I do agree that other encoding types can be specified and should be supported as well, but since the objects already include a ToJson(), it seemed like an easy win for those that need it.
There was a problem hiding this comment.
@milesressler please follow isJson approach in Dart client generator:
Let me know if you need help. You can PM me via Slack (mentioned in the readme)
|
Closed via #7293 |
See issue 5215 relating to encoding not supported on form parameters
@mandrean @jimschubert @frankyjuang @shibayan