My understanding is that it's not actually XML, but special tokens that can be injected into the input stream (and read from output stream). The XML format is just how those tokens are sometimes rendered for human consumption.
"My understanding is that these APIs are not actually XML, but actually a bytestream. The XML format is just how it is usually rendered for human consumption."