Design: Indicating different encoded message types in message
For a binary message the receiver needs to know how to recover the data from the data field. If that's sometimes hex and sometimes base64 then there should be something in the encoded schema that tells the receiver how the sender encoded the data.
If the comms manager needs to encode the binary data in hex to send it via SMS that's a different process.
I think this is an issue for the message formats. We either need to always encode the data field of an encoded message into text in the same way or we need to document in the message how you recover the binary data from the data string.
Ref: https://git.noc.ac.uk/oceanids/c2/services/ah1-nucleus-adapter/-/merge_requests/19#note_215349