API responses

For succesful sequest

After sending a correctly configured API request, you will receive an XML document containing the <candidateList> element, which includes all candidate replies from the requested (or default) time period as individual <candidate> elements.

The XML structure of the candidate reply export is described in detail in the next section of this technical documentation: Export XML Structure.

For unsuccesful request

The following fault codes (error responses) and alert responses may be returned when a request to this API fails. Each code includes a description of the typical situation in which it occurs.

Fault codes (error responses)

1. “Invalid request”

Indicates an error in your request syntax or an incorrect URL format.

<?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:Body>
    <soapenv:Fault>
      <faultcode>1</faultcode>
      <faultstring>Invalid request.</faultstring>
    </soapenv:Fault>
  </soapenv:Body>
</soapenv:Envelope>

2. “Authentication error”

Occurs when login or password is incorrect, the API endpoint does not exist, or the request originates from an IP address that is not whitelisted.

<?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:Body>
    <soapenv:Fault>
      <faultcode>2</faultcode>
      <faultstring>Authentication error.</faultstring>
    </soapenv:Fault>
  </soapenv:Body>
</soapenv:Envelope>

3. “Minimum access interval has not passed yet”

The interval since your last request was shorter than the minimum allowed interval of 15 minutes.

<?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:Body>
    <soapenv:Fault>
      <faultcode>3</faultcode>
      <faultstring>Minimum access interval has not passed yet.</faultstring>
    </soapenv:Fault>
  </soapenv:Body>
</soapenv:Envelope>

4. General Error: “An error has occurred”

Reserved for unexpected errors. This is rare, and it would have to be investigated by Teamio.

<?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:Body>
        <soapenv:Fault> 
            <faultcode>4</faultcode>
            <faultstring>General error, faultString: An error has occured.</faultstring> 
        </soapenv:Fault>
    </soapenv:Body> 
</soapenv:Envelope>

Alert messages

“Too many items”

This plain text response occurs when the number of candidate replies returned by the API based on your request exceeds the allowed limit of 200 replies. In this case, no fault code is sent; instead, the response informs you that you must narrow the time range in your request:

Too many items: 1234. Max allowed items is 200. Limit count of items by from and until parameters! (<https://g2.lmc.cz/export/company/export>)

In this example:

  • 1234 is not a status code but the number of candidate replies the API would have to return based on your request.
  • 200 is the maximum number of replies the API can return. See Replies Per Response Limit in the previous section.

“No exportable items found.”

When there are no candidate replies for the requested time range, the response will indicate that no exportable items were found:

<?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:Body>
    No exportable items found.
  </soapenv:Body>
</soapenv:Envelope>

This response can occur for several reasons:

  • Candidate replies older than 6 months are not available through the API.
  • Candidate replies submitted before the API activation date are not available through it.
  • No candidate replies were received during the requested time range.
  • Candidates from the requested period were deleted from Teamio and are no longer available through the API.