SOAP Fault Message Structure

This section provides a description of the SOAP fault message structure and a sample message.

A SOAP fault message is a special SOAP message used to carry error information. It must have only one body child element called "Fault" element with the following structure:

<env:Envelope xmlns:env="">
   <env:Code> (required)
    <env:Value>env:VersionMismatch | env:MustUnderstand | Sender
       | DataEncodingUnknown | Receiver</env:Value> (required)
    <env:Subcode> (optional)
     <env:Value>text</env:Value> (required)
      <env:Subcode> (optional)
   <env:Reason> (required)
    <env:Text xml:lang="languageCode">text<env:Text> (required)
    <env:Text xml:lang="languageCode">text<env:Text> (opitonal)
   <env:Node> (optional)
   <env:Role> (optional)
   <env:Detail ...> (optional)
    ... (any XML structure)

Note that:

To give an idea of how a SOAP fault message looks like, I have copied the example #6a from the SOAP 1.2 specification here:

<?xml version='1.0' ?>
<env:Envelope xmlns:env=""
      <env:Text xml:lang="en-US">Processing error</env:Text>
      <env:Text xml:lang="fr-CA">Error</env:Text>
        <e:message>Name does not match card number</e:message>

Table of Contents

 About This Book

 Introduction to Web Service

 Introduction to SOAP (Simple Object Access Protocol)

SOAP Message Structure

 SOAP Generic Message Structure

SOAP Fault Message Structure

 SOAP Message Transmission and Processing

 SOAP Data Model

 SOAP Encoding

 SOAP RPC Presentation

 SOAP Properties Model

 SOAP MEP (Message Exchange Patterns)

 SOAP HTTP Binding

 SOAP PHP Implementations

 PHP SOAP Extension Client Programs

 PHP SOAP Extension Server Programs

 PHP SOAP Web Service Example - getTemp

 SOAP Perl Implementations

 Perl SOAP::Lite - SOAP Server-Client Communication Module

 Perl Socket Test Program for HTTP and SOAP

 Perl SOAP::Lite for NumberToWords SOAP 1.1 Web Service

 Perl SOAP::Lite for SOAP 1.2 Web Services

 Perl SOAP::Lite for WSDL

 SOAP Java Implementations

 Java Socket and HttpURLConnection for SOAP

 SAAJ - SOAP with Attachments API for Java

 SoapUI - SOAP Web Service Testing Tool

 WS-Security - SOAP Message Security Extension

 WS-Security X.509 Certificate Token

 Perl SOAP::Lite for GetSpeech SOAP 1.1 Web Service

 Perl SOAP::Lite 0.710 for SOAP 1.2 Web Services

 Perl SOAP::Lite 0.710 for WSDL

 Web Services and SOAP Terminology

 Outdated Tutorials


 Full Version in PDF/EPUB