open fun asBytes(objectMapper: ObjectMapper!): Bytes! (source)
Serialize body to bytes.
objectMapper - ObjectMapper!: the object mapper to serialize to bytes with
JsonProcessingException - thrown if there is a problem transforming the object to JSON.
Return
Bytes!: the bytes representation of this RPC request body. The request is first encoded into JSON, then from JSON to a byte array