Define SOAP

SOAP is an XML-based protocol that is used to access services, objects, and servers in a platform- and vendor- independent manner.it is an XML-based protocol.SOAP generally uses HTTP, a firewall-friendly protocol, as its transport protocol.

SOAP includes three components: SOAP messages, SOAP attributes, and SOAP encoding.

SOAP Messages

SOAP is an XML-based protocol, SOAP messages are encoded in the XML format. A SOAP message contains the following XML elements:

Envelope: It is a mandatory element of SOAP message and it identifies the XML document as SOAP message. It contains other elements, declarations and attributes required for processing SOAP message.

Header: The SOAP header, which is an optional element, defines the header information. it should be the first child element of the Envelope element. It is used to provide encription information.

Body: The SOAP body, which is a mandatory element, contains all the information that the message recipient needs. It typically contains method calls and response information for the SOAP message.

Example:

<soap:Envelope>
    <soap:Header>
          ...Header informations ...
    </soap:Header>
    <soap:Body>
       <GetStockValue>
            <Item>Cake</Item>
       </GetStockValue>
    </soap:Body>
</soap:Envelope>
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: