Hello,
I have api endpoint with Event and the Event has Location. The Locatio is interface with two implementations GeoLocation and OnlineLocation, something like this
@Serializable
sealed interface Location
@Serializable
@SerialName("geo")
data class GeoLocation(val lat: Double, val lot: Double) : Location
@Serializable
@SerialName("online")
data class OnlineLocation(val url: String) : Location
Now default behaviour of kotlinx.serialization is that it adds "type" to the payload, like so
Is it possible get this type of generic properties in generated apidoc? Not sure, add it to all component implementing localization, or through Location component definition?
Hello, I have api endpoint with Event and the Event has Location. The Locatio is interface with two implementations GeoLocation and OnlineLocation, something like this
Now default behaviour of kotlinx.serialization is that it adds "type" to the payload, like so
But the "type" is not in generated apidoc.
Is it possible get this type of generic properties in generated apidoc? Not sure, add it to all component implementing localization, or through Location component definition?
Thank you for your advice in advance.