bytes

open fun bytes(value: T): ByteArray?(source)

Encodes value into its wire representation.

This delegates to codec, except for bodies such as EmptyBody that intentionally suppress any payload and therefore return null.