DataFlex Web Service

Click here for a complete list of operations.

CheckSolutions

Test your knowledge. Pass an anagram word, a language id and an array of words to verify. Gets a result set back that contains the number of correct and incorrect words you gave, the solutions stored which you can compare to the number you've passed and per passed anagram word if it was correct or incorrect

Test

The test form is not available with struct, array or byref parameter types. Please use a SOAP 1.1 or 1.2 compliant client program for testing of your web service.

SOAP 1.1

The following is a sample SOAP 1.1 request and response. The placeholders shown need to be replaced with actual values.

POST /websamples.anagram/anagramservice.wso HTTP/1.1
Host: webservices.oorsprong.org
Content-Type: text/xml; charset=utf-8
Content-Length: length

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
  <soap:Body>
    <CheckSolutions xmlns="http://www.oorsprong.org/">
      <sAnagramWord>string</sAnagramWord>
      <sLanguageId>string</sLanguageId>
      <sWordsToTest>
        <string>string</string>
        <string>string</string>
      </sWordsToTest>
    </CheckSolutions>
  </soap:Body>
</soap:Envelope>

HTTP/1.1 200 OK
Content-Type: text/xml; charset=utf-8
Content-Length: length

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
  <soap:Body>
    <CheckSolutionsResponse xmlns="http://www.oorsprong.org/">
      <CheckSolutionsResult>
        <iCorrect>int</iCorrect>
        <iIncorrect>int</iIncorrect>
        <iSolutionsStored>int</iSolutionsStored>
        <iSolutionsGiven>int</iSolutionsGiven>
        <Anagrams>
          <tAnagramsTest>
            <sAnagramWord>string</sAnagramWord>
            <bCorrect>boolean</bCorrect>
          </tAnagramsTest>
          <tAnagramsTest>
            <sAnagramWord>string</sAnagramWord>
            <bCorrect>boolean</bCorrect>
          </tAnagramsTest>
        </Anagrams>
      </CheckSolutionsResult>
    </CheckSolutionsResponse>
  </soap:Body>
</soap:Envelope>

SOAP 1.2

The following is a sample SOAP 1.2 request and response. The placeholders shown need to be replaced with actual values.

POST /websamples.anagram/anagramservice.wso HTTP/1.1
Host: webservices.oorsprong.org
Content-Type: application/soap+xml; charset=utf-8
Content-Length: length

<?xml version="1.0" encoding="utf-8"?>
<soap12:Envelope xmlns:soap12="http://www.w3.org/2003/05/soap-envelope">
  <soap12:Body>
    <CheckSolutions xmlns="http://www.oorsprong.org/">
      <sAnagramWord>string</sAnagramWord>
      <sLanguageId>string</sLanguageId>
      <sWordsToTest>
        <string>string</string>
        <string>string</string>
      </sWordsToTest>
    </CheckSolutions>
  </soap12:Body>
</soap12:Envelope>

HTTP/1.1 200 OK
Content-Type: application/soap+xml; charset=utf-8
Content-Length: length

<?xml version="1.0" encoding="utf-8"?>
<soap12:Envelope xmlns:soap12="http://www.w3.org/2003/05/soap-envelope">
  <soap12:Body>
    <CheckSolutionsResponse xmlns="http://www.oorsprong.org/">
      <CheckSolutionsResult>
        <iCorrect>int</iCorrect>
        <iIncorrect>int</iIncorrect>
        <iSolutionsStored>int</iSolutionsStored>
        <iSolutionsGiven>int</iSolutionsGiven>
        <Anagrams>
          <tAnagramsTest>
            <sAnagramWord>string</sAnagramWord>
            <bCorrect>boolean</bCorrect>
          </tAnagramsTest>
          <tAnagramsTest>
            <sAnagramWord>string</sAnagramWord>
            <bCorrect>boolean</bCorrect>
          </tAnagramsTest>
        </Anagrams>
      </CheckSolutionsResult>
    </CheckSolutionsResponse>
  </soap12:Body>
</soap12:Envelope>

JSON

The following is a sample JSON request and response. The placeholders shown need to be replaced with actual values.

POST /websamples.anagram/anagramservice.wso HTTP/1.1
Host: webservices.oorsprong.org
Content-Type: application/json; charset=utf-8
Content-Length: length
{
   "sAnagramWord": string
   "sLanguageId": string
   "sWordsToTest":
   [
    string,
    string
   ]
}

HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8
Content-Length: length

{

   "iCorrect": int
   "iIncorrect": int
   "iSolutionsStored": int
   "iSolutionsGiven": int
   "Anagrams":
   [
     {       
       "sAnagramWord": string
       "bCorrect": boolean
     },
     {       
       "sAnagramWord": string
       "bCorrect": boolean
     }
   ]
}