<? xml version="1.0"?> <soap:Envelope xmlns:soap="http://www.w3.org/2001/12/soap-envelope" soap:encodingStyle="http://www.w3.org/2001/12/soap-encoding"> <soap:Header> ... ... </soap:Header> <soap:Body> ... ... <soap:Fault> ... ... </soap:Fault> </soap:Body> </soap:Envelope>
<? xml version="1.0"?> <soap:Envelope xmlns:soap="http://www.w3.org/2001/12/soap-envelope" soap:encodingStyle="http://www.w3.org/2001/12/soap-encoding"> ... Message information goes here ... </soap:Envelope>
<? xml version="1.0"?> <soap:Envelope xmlns:soap="http://www.w3.org/2001/12/soap-envelope" soap:encodingStyle="http://www.w3.org/2001/12/soap-encoding"> <soap:Header> <m:Trans xmlns:m="http://www.jsoso.net/transaction/" soap:mustUnderstand="1" soap:actor="http://www.w3schools.com/appml/ “ >234</m:Trans> </soap:Header> ... ... </soap:Envelope>
<? xml version="1.0"?> <soap:Envelope xmlns:soap="http://www.w3.org/2001/12/soap-envelope" soap:encodingStyle="http://www.w3.org/2001/12/soap-encoding"> <soap:Body> <m:GetPrice xmlns:m="http://www.jsoso.net/prices"> <m:Item>Apples</m:Item> </m:GetPrice> </soap:Body> </soap:Envelope>
<?xml version="1.0"?> <soap:Envelope xmlns:soap="http://www.w3.org/2001/12/soap-envelope" soap:encodingStyle="http://www.w3.org/2001/12/soap-encoding"> <soap:Body> <m:GetPriceResponse xmlns:m="http://www.jsoso.net/prices"> <m:Price>1.90</m:Price> </m:GetPriceResponse> </soap:Body> </soap:Envelope>
POST /InStock HTTP/1.1 Host: www.jsoso.net Content-Type: application/soap+xml; charset=utf-8 Content-Length: XXX <? xml version="1.0"?> <soap:Envelope xmlns:soap="http://www.w3.org/2001/12/soap-envelope" soap:encodingStyle="http://www.w3.org/2001/12/soap-encoding"> <soap:Body xmlns:m="http://www.jsoso.net/stock"> <m:GetStockPrice> <m:StockName>IBM</m:StockName> </m:GetStockPrice> </soap:Body> </soap:Envelope>
HTTP/1.1 200 OK Content-Type: application/soap+xml; charset=utf-8 Content-Length: XXX <? xml version="1.0"?> <soap:Envelope xmlns:soap="http://www.w3.org/2001/12/soap-envelope" soap:encodingStyle="http://www.w3.org/2001/12/soap-encoding"> <soap:Body xmlns:m="http://www.jsoso.net/stock"> <m:GetStockPriceResponse> <m:Price>34.5</m:Price> </m:GetStockPriceResponse> </soap:Body> </soap:Envelope>
<?xml version="1.0" encoding="UTF-8"?> <definitions xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:tns="http://www.jsoso.com/wstest" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://schemas.xmlsoap.org/wsdl/" targetNamespace="http://www.jsoso.com/wstest" name="Example"> <types> <xsd:schema> <xsd:import namespace="http://www.jsoso.com/wstest" schemaLocation="http://localhost:8080/hello?xsd=1"></xsd:import> </xsd:schema> </types> <message name="toSayHello"> <part name="userName" type="xsd:string"></part> </message> <message name="toSayHelloResponse"> <part name="returnWord" type="xsd:string"></part> </message> <message name="sayHello"> <part name="person" type="tns:person"></part> <part name="arg1" type="xsd:string"></part> </message> <message name="sayHelloResponse"> <part name="personList" type="tns:personArray"></part> </message> <message name="HelloException"> <part name="fault" element="tns:HelloException"></part> </message> <portType name="Example"> <operation name="toSayHello" parameterOrder="userName"> <input message="tns:toSayHello"></input> <output message="tns:toSayHelloResponse"></output> </operation> <operation name="sayHello" parameterOrder="person arg1"> <input message="tns:sayHello"></input> <output message="tns:sayHelloResponse"></output> <fault message="tns:HelloException" name="HelloException"></fault> </operation> </portType> <binding name="ExamplePortBinding" type="tns:Example"> <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="rpc"></soap:binding> <operation name="toSayHello"> <soap:operation soapAction="sayHello"></soap:operation> <input> <soap:body use="literal" namespace="http://www.jsoso.com/wstest"></soap:body> </input> <output> <soap:body use="literal" namespace="http://www.jsoso.com/wstest"></soap:body> </output> </operation> <operation name="sayHello"> <soap:operation soapAction="sayHello"></soap:operation> <input> <soap:body use="literal" namespace="http://www.jsoso.com/wstest"></soap:body> </input> <output> <soap:body use="literal" namespace="http://www.jsoso.com/wstest"></soap:body> </output> <fault name="HelloException"> <soap:fault name="HelloException" use="literal"></soap:fault> </fault> </operation> </binding> <service name="Example"> <port name="ExamplePort" binding="tns:ExamplePortBinding"> <soap:address location="http://localhost:8080/hello"></soap:address> </port> </service> </definitions>
<definitions xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:tns="http://www.jsoso.com/wstest" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://schemas.xmlsoap.org/wsdl/" targetNamespace="http://www.jsoso.com/wstest" name="Example"> …… …… </definitions>
<types> <xsd:schema> <xsd:import namespace="http://www.jsoso.com/wstest" schemaLocation="http://localhost:8080/hello?xsd=1"></xsd:import> </xsd:schema> </types>
<message name="toSayHello"> <part name="userName" type="xsd:string"></part> </message> <message name="toSayHelloResponse"> <part name="returnWord" type="xsd:string"></part> </message> <message name="sayHello"> <part name="person" type="tns:person"></part> <part name="arg1" type="xsd:string"></part> </message> <message name="sayHelloResponse"> <part name="personList" type="tns:personArray"></part> </message> <message name="HelloException"> <part name="fault" element="tns:HelloException"></part> </message>
<portType name="Example"> <operation name="toSayHello" parameterOrder="userName"> <input message="tns:toSayHello"></input> <output message="tns:toSayHelloResponse"></output> </operation> <operation name="sayHello" parameterOrder="person arg1"> <input message="tns:sayHello"></input> <output message="tns:sayHelloResponse"></output> <fault message="tns:HelloException" name="HelloException"></fault> </operation> </portType>
<binding name="ExamplePortBinding" type="tns:Example"> <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="rpc"></soap:binding> <operation name="toSayHello"> <soap:operation soapAction="sayHello"></soap:operation> <input> <soap:body use="literal" namespace="http://www.jsoso.com/wstest"></soap:body> </input> <output> <soap:body use="literal" namespace="http://www.jsoso.com/wstest"></soap:body> </output> </operation> <operation name="sayHello"> <soap:operation soapAction="sayHello"></soap:operation> <input> <soap:body use="literal" namespace="http://www.jsoso.com/wstest"></soap:body> </input> <output> <soap:body use="literal" namespace="http://www.jsoso.com/wstest"></soap:body> </output> <fault name="HelloException"> <soap:fault name="HelloException" use="literal"></soap:fault> </fault> </operation> </binding>
<service name="Example"> <port name="ExamplePort" binding="tns:ExamplePortBinding"> <soap:address location="http://localhost:8080/hello"></soap:address> </port> </service>