SOAP Web Service Components
SOAP Web Service Components
SOAP is an acronym for Simple Object Access Protocol. It is an XML-based protocol for accessing web services and a W3C recommendation for communication between applications. SOAP is platform and language-independent. In other words, it can be used with Java, .Net, or PHP on any platform.
It is a protocol used for exchanging structured information in web services using XML. It enables communication between applications over a network, typically using HTTP or SMTP.
Main Components of a SOAP Web Service
SOAP Message
The core unit of communication in a SOAP-based web service. It is an XML-based message that consists of the following subcomponents:
<soap:Envelope> <soap:Header>...</soap:Header> <soap:Body>...</soap:Body> </soap:Envelope>
SOAP Envelope
The root element of every SOAP message. It defines the start and end of the SOAP message and contains the optional Header and mandatory Body elements.
SOAP Header (Optional)
Contains metadata or processing instructions. It’s used for authentication, transaction details, security, etc. This part is optional.
SOAP Body
The main part of the SOAP message. It holds the actual message or function call being sent to the web service, and also the response data from the web service.
WSDL (Web Services Description Language)
WSDL is an acronym for Web Services Description Language. WSDL is an XML document containing information about web services, such as the method name and parameter and how to access them. WSDL is a part of UDDI. It acts as an interface between web service applications.
An XML-based file that describes the interface of the SOAP web service. It defines the operations, input/output parameters, data types, bindings, and endpoint URL.
UDDI (Universal Description, Discovery, and Integration)
UDDI is an acronym for Universal Description, Discovery, and Integration. UDDI is an XML-based framework for describing, discovering, and integrating web services. UDDI is a directory of web service interfaces described by WSDL, containing information about web services.
It is used to publish and discover web services. It acts like a directory for SOAP services.
SOAP Client
The application or system that sends the SOAP request. It constructs the SOAP message and handles the SOAP response.
SOAP Server
The web service provider. It receives the SOAP request, processes it, and sends back a SOAP response.
Summary Table
| Component | Description |
|---|---|
| SOAP Message | The full XML message exchanged between client and server |
| Envelope | Root element wrapping the message |
| Header (Optional) | Contains metadata like security, transactions |
| Body | Actual data or function call payload |
| WSDL | Describes the web service structure and operations |
| UDDI (Optional) | Registry for publishing and discovering services |
| SOAP Client | Sends the request |
| SOAP Server | Processes the request and returns a response |