Json Ad-hoc polymorphism in JSON with Kotlin This post describes a way of using the GSON and Mosi library with Kotlin data classes with Polymorphic JSON data with null-safety and default values.