- SOAP stands for Simple Object Access Protocol
- SOAP is an XML-based protocol for exchanging information between computers.
- SOAP provides data transport for Web services
- SOAP is platform and language independent.
SOAP Message Structure
A SOAP message is an XML document containing the following elements.
- Envelope: (Mandatory)
- Defines the start and the end of the message, so that the receiver knows when an entire message has been received.
- The SOAP envelope solves the problem of knowing when you're done receiving a message and are ready to process it.
- Header: (Optional)
- Contains any optional attributes of the message used in processing the message, either at an intermediary point or at the ultimate end point.
- Body: (Mandatory)
- Contains the XML data comprising the message being sent.
- Fault: (Optional)
- An optional Fault element that provides information about errors that occurred while processing the message
Sample SOAP Message
<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsd="http://www.w3.org/1999/XMLSchema"
xmlns:xsi="http://www.w3.org/1999/XMLSchema-instance">
<SOAP-ENV:Header>
<wsse:Security xmlns:wsse="http://docs.oasis-open.org/wss/
2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd">
<wsse:UsernameToken>
<wsse:Username>svc-abacusuat</wsse:Username>
<wsse:Password>2sycOyhi</wsse:Password>
</wsse:UsernameToken>
</wsse:Security>
</SOAP-ENV:Header>
<SOAP-ENV:Body>
<CCRG_ContractSearchRQ xmlns="http://com.ccrgservices.services.
contractsearch" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
SearchType="Summary" xsi:schemaLocation="http://com.ccrgservices.
services.contractsearch CCRG_ContractSearchRQ.xsd"
RevenueIndicator="All" RentalStatus="All">
<ContractSearch Brand="Cars">
<DateRange Start="2012-05-20T00:00:00" End="2012-07-19T23:59:59"/>
</ContractSearch>
<CustomerSearch/>
<VehicleSearch>
<VehIdentification MVA="052815066"/>
</VehicleSearch>
</CCRG_ContractSearchRQ>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>
<SOAP-ENV:Envelope
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsd="http://www.w3.org/1999/XMLSchema"
xmlns:xsi="http://www.w3.org/1999/XMLSchema-instance">
<SOAP-ENV:Header>
<wsse:Security xmlns:wsse="http://docs.oasis-open.org/wss/
2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd">
<wsse:UsernameToken>
<wsse:Username>svc-abacusuat</wsse:Username>
<wsse:Password>2sycOyhi</wsse:Password>
</wsse:UsernameToken>
</wsse:Security>
</SOAP-ENV:Header>
<SOAP-ENV:Body>
<CCRG_ContractSearchRQ xmlns="http://com.ccrgservices.services.
contractsearch" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
SearchType="Summary" xsi:schemaLocation="http://com.ccrgservices.
services.contractsearch CCRG_ContractSearchRQ.xsd"
RevenueIndicator="All" RentalStatus="All">
<ContractSearch Brand="Cars">
<DateRange Start="2012-05-20T00:00:00" End="2012-07-19T23:59:59"/>
</ContractSearch>
<CustomerSearch/>
<VehicleSearch>
<VehIdentification MVA="052815066"/>
</VehicleSearch>
</CCRG_ContractSearchRQ>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>
No comments:
Post a Comment