About the SOAP Formatter
SOAP messages travel as one unbroken line, and a request carrying a security header plus a nested body is close to unreadable in that form. This formatter indents the envelope, keeps short leaf elements such as <tns:WeightKg>4.2</tns:WeightKg> on one line, and leaves comments, CDATA sections and processing instructions exactly where they were.
It also reads the message. The envelope namespace decides whether you are looking at SOAP 1.1 or SOAP 1.2, and the summary comment placed under the XML declaration lists the number of header blocks, the names of the body children, and the fault code and reason when the response is an error. That header is a normal XML comment, so the output still parses anywhere you paste it. Untick the summary option if the message has to stay byte comparable with the original.
By default the tool insists on a real Envelope root, because a message missing one is usually a truncated capture or a REST response that got sent to the wrong tool. Untick "Require an envelope" and any well formed XML will be indented instead. Namespace prefixes are never rewritten: a rewritten prefix can invalidate a signature or an XPath in a downstream stylesheet. To describe the service that produced the message, format its contract with the WSDL Formatter, and for generic documents use the XML Formatter.
How to use
- Paste the raw SOAP request or response, including the Envelope element.
- Choose an indent width, then read the comment block at the top for the header and body inventory.
- If the capture is only a fragment, untick Require an envelope to format it as plain XML.
- Download the tidied envelope as
envelope.xmlto attach it to a ticket.
Common questions
- Does it tell SOAP 1.1 and 1.2 apart?
- Yes. The envelope namespace decides: the schemas.xmlsoap.org URI is 1.1 and the w3.org 2003/05 URI is 1.2. The version appears in the summary and the status line.
- Will a fault be highlighted?
- The summary comment names the fault code and the reason text when the body contains a Fault element, so you can see the failure without scrolling through the payload.
- Are namespace prefixes normalised?
- No. Prefixes are kept as written because signatures, XPath expressions and stylesheets downstream can depend on the exact prefix used.
- Can I paste a message with a MIME attachment boundary?
- Strip the MIME parts first and paste only the XML section. The boundary lines are not XML, so the parser rejects them.