Manually define a SOAP request from scratch

This section describes how to define a SOAP request based on some XML rather than starting on a WSDL definition.

This will be illustrated by continuing the previous example and by invoking the ValidateImageWord method. This method expects two parameters, an image identifier, the CaptchaImageGuid, returned by the GetNewWord method and the text entered by a user. The ValidateImageWord method will return true if the text entered by the user and the captcha image are consistent. The XML you will be building your SOAP request on follows:

<?xml version="1.0" encoding="UTF-8"?>
<soapenv:Envelope 
    xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" 
    xmlns:xsd="http://www.w3.org/2001/XMLSchema" 
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  <soapenv:Header>
    <ns1:LicenseInfo 
        xmlns:ns1="http://ws.strikeiron.com" 
        soapenv:mustUnderstand="0">
      <ns1:UnregisteredUser>
        <ns1:EmailAddress>john.doe@dot.com</ns1:EmailAddress>
      </ns1:UnregisteredUser>
      <ns1:RegisteredUser>
        <ns1:UserID/>
        <ns1:Password/>
      </ns1:RegisteredUser>
    </ns1:LicenseInfo>
  </soapenv:Header>
  <soapenv:Body>
    <ValidateImageWord 
        xmlns="http://www.textdisguise.com/TextDisguise/CaptchaService/">
      <captchaImageGuid>53fd3b31-1089-455b-a1b6-d78bc73f80b9</captchaImageGuid>
      <word>SUBPRIMATE</word>
    </ValidateImageWord>
  </soapenv:Body>
</soapenv:Envelope>

  1. Manually create a SOAP request:
  2. Configure the XML content:
  3. Test the SOAP request: