ktor-serialization / io.ktor.serialization / io.ktor.features.ContentNegotiation.Configuration / serialization

serialization

fun Configuration.serialization(contentType: ContentType, format: BinaryFormat): Unit

Register kotlinx.serialization converter into ContentNegotiation feature with the specified contentType and binary format (such as CBOR, ProtoBuf)

fun Configuration.serialization(contentType: ContentType, format: StringFormat): Unit

Register kotlinx.serialization converter into ContentNegotiation feature with the specified contentType and string format (such as Json)

fun Configuration.serialization(): Unit
Deprecated: Use json instead


fun Configuration.serialization(contentType: ContentType): Unit
Deprecated: Use json function instead.


fun Configuration.serialization(contentType: ContentType, json: Json): Unit
Deprecated: Use json function instead.

Register kotlinx.serialization converter into ContentNegotiation feature