Rodrigo Silva
12/23/2020, 1:18 PMkotlinx.serialization.SerializationException: Serializer for class 'Immobile' is not found.
Mark the class as @Serializable or provide the serializer explicitly.
Rodrigo Silva
12/23/2020, 1:18 PMimport kotlinx.serialization.*
@Serializable
data class Immobile(
val test: String
)
fun Route.webProperties() {
route("/home") {
post {
val properties = call.receive<Immobile>()
call.respond(properties)
}
}
}
install(ContentNegotiation) {
json()
}
jaqxues
12/23/2020, 1:31 PMRodrigo Silva
12/23/2020, 1:34 PM