Hi I have installed Soap UI...Like C, Java we will create some sample program. likewise i wanted to use some sample request and response..how to create a request and response without wsdl?
Without the WSDL, it will be responsibility of the developer to know the definition of the SOAP Web Service to consume . SOAP envelope, SOAP Body and the complete XML request has to be built by the developer and pass it to the Http client.
You can just trick SOAPUi with some dummy WSDL, at least with a single request/response definition! Just replace the requests it generates with the XML document you wanted. You an also add additional requests with entirely different request/responses by copy and pasting!
WSDL, or Web Service Description Language, is an XML based definition language. It's used for describing the functionality of a SOAP based web service. WSDL files are central to testing SOAP-based services. SoapUI uses WSDL files to generate test requests, assertions and mock services.
I wanted to send a SOAP request to a simple ASP.NET MVC Controller and the way I managed to do it using SoapUI was:
1) Create a SOAP request using any WSDL (no matter what WSDL you use, then you'll change it).
2) Open a request, change the URL and change the body of the request.
That way you can post a SOAP request with full control. Just in case it is useful, inside the controller I'm logging all the requests we receive using this in C#:
string requestData;
// Get raw request body
using (Stream receiveStream = Request.InputStream)
{
// Move to begining of input stream and read
receiveStream.Position = 0;
using (StreamReader readStream = new StreamReader(receiveStream, Encoding.UTF8))
{
requestData = readStream.ReadToEnd();
}
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With