Simple Object Access Protocol (SOAP)
SOAP is an XML-based protocol used to exchange information in a decentralized, distributed environment. The protocol consists of:
- An envelope that contains the body of the message, identifies who should process it, and describes how to process it.
- A set of encoding rules for expressing instances of application-specific data types.
- A convention for representing remote procedure calls and responses.
This information is embedded in a MIME-encoded package that can be transmitted over HTTP or other Web protocols. MIME is a specification for formatting non-ASCII messages so that they can be sent over the Internet.
The following example shows a SOAP request for stock trading information embedded inside an HTTP request:
POST /StockQuote HTTP/1.1 Host: www.sample.com Content-Type: text/xml; charset="utf-8" Content-Length: nnnn SOAPAction: "Some-URI" <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"> <SOAP-ENV:Body> <m:GetLastStockQuote xmlns:m="Some-URI"> <symbol>BEAS</symbol> </m:GetLastStockQuote> </SOAP-ENV:Body> </SOAP-ENV:Envelope>