"Content is not allowed in prolog" usually indicates that there is non-XML data being sent in the payload of your POST message. Your QIE channel is configured to accept XML message format, so the content of the POST request must be XML when QIE is set to automatically extract the content of the POST to use as the message data.
However, from looking at your code, I think you want to uncheck the "Extract content as message" checkbox. Doing so will cause QIE to pass the entire message (including metadata) into the channel, which will already be formatted as XML. From there, you can extract the content to work with it, even if it's not XML data.