Closed y9san9 closed 4 years ago
Sending different response types should work if you use exception handlers, if they are on the same error code it should generate a oneOf
definition.
If you mean receiving different body types, then you might want to define an object that has a nullable parameters for the one or the other.
Tell me if it doesn't work and i'll look into it.
Thanks that works pretty well. This library is rly nice, do not stop it's support :) And you should also write about this feature in wiki or README, cuz I'm exporing library from issues and I think there are so many unknown for users features
i added an example page in the wiki https://github.com/papsign/Ktor-OpenAPI-Generator/wiki/A-few-examples
Can I use different body types on success and on error? Because in Retrofit Im using different bodies with different types