encodeToString

fun Json.encodeToString(vararg pairs: Pair<*, *>): String(source)

Encodes the given pairs of key-value data into a JSON string representation.

Return

the JSON string representation of the encoded data

Parameters

pairs

the key-value pairs to encode