Instance Method
encode(_:to:headers:userInfo:)
“Encode object” method. The provided encodable object’s contents must be stored in the provided
Foundation/Data, and any appropriate headers for the type of the content may be stored in the provided HTTPFields objects. The provided userInfo dictionary must be forwarded to the underlying Swift/Encoder used to perform the encoding operation.func encode(_ encodable: some Encodable, to body: inout Data, headers: inout HTTPFields, userInfo: [CodingUserInfoKey : any Sendable]) throws