XML Preview fails for MIME/XOP (MTOM) SOAP responses
Internal - [BRU-4412]
I have checked the following:
- [x] I have searched existing issues and found nothing related to my issue.
This bug is:
- [ ] Making Bruno unusable for me.
- [x] Slowing me down but I'm able to continue working.
- [ ] Annoying.
- [ ] This feature was working in a previous version but is broken in the current release.
Bruno version
4.1.0
๐ป Operating System
Windows
Specific OS Version / Distro
No response
๐ Describe the bug
When a response body is a SOAP MTOM / XOP package (multipart/related with an application/xop+xml root part), selecting format XML and enabling Preview shows:
Cannot preview as XML
Failed to parse XML string. Invalid XML format.
The body is valid for SOAP/MTOM clients: MIME boundaries and part headers wrap a well-formed XML SOAP envelope. The editor can still show the raw body; only the XML tree preview fails.
๐ Steps to reproduce
- Send a request that returns a MIME/XOP response (sample below).
- In the Response pane, set format to XML.
- Switch to Preview.
- See the error banner instead of the XML tree.
--MIMEBoundary_6dede28bbb936f74e760b0f330c8d24abbf13537c40601ce
Content-Type: application/xop+xml; charset=utf-8; type="text/xml"
Content-Transfer-Encoding: binary
Content-ID: <[email protected]>
<?xml version="1.0" encoding="utf-8"?><soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">...</soapenv:Envelope>
--MIMEBoundary_6dede28bbb936f74e760b0f330c8d24abbf13537c40601ce--
๐ Collection to reproduce
No response
๐ท Screenshots/Live demo link
Hi @mattrudin, thanks for sharing the detailed reproduction steps and sample response.
I was able to reproduce the issue on my end. When the MTOM/XOP multipart/related response is displayed in XML format and switched to Preview, Bruno shows the โCannot preview as XMLโ error, even though the SOAP XML within the response is valid.
I've shared this with our engineering team, and it's being evaluated alongside our other product priorities. While I can't promise a timeline at the moment, we'll make sure it gets reviewed as soon as possible, and we'll share any updates as they become available.
We'll keep this thread updated with any progress or new information.