toJson

fun toJson(value: Any?): String

value as JSON: maps, lists, strings, numbers, booleans and nulls.