Response Samples

Changing settings of a single domain

The following request packet changes Log Rotation settings of domain example.com:

<packet version="1.5.0.0">
  <log-rotation>
    <set>
        <filter>
        <domain-name>example.com</domain-name>
        </filter>
        <settings>
          <log-condition>
            <log-bysize>2073741824</log-bysize>
          </log-condition>
          <log-max-num-files>1</log-max-num-files>
          <log-compress>true</log-compress>
        </settings>
    </set>
  </log-rotation>
</packet>

 

A positive response from the server can look as follows:

<packet version="1.5.0.0">
  <log-rotation>
    <set>
      <result>
        <status>ok</status>
        <filter-id>example.com</filter-id>
        <id>33</id>
      </result>
    </set>
  </log-rotation>
</packet>

 

If the domain was not found, the response from the server looks as follows:

<packet version="1.5.0.0">
  <log-rotation>
    <set>
      <result>
        <status>error</status>
        <errcode>1013</errcode>
        <errtext>domain does not exist</errtext>
        <filter-id>example.com</filter-id>
      </result>
    </set>
  </log-rotation>
</packet>

 

If a packet sender has no rights to manage physical hosting, the response looks as follows:

<packet version="1.5.0.0">
  <log-rotation>
    <get>
      <result>
        <status>error</status>
        <errcode>1006</errcode>
        <errtext>Access denied</errtext>
        <filter-id>example.com</filter-id>
      </result>
    </get>
  </log-rotation>
</packet>

 

If the domain is not hosted physically, the response from the server looks as follows:

<packet version="1.5.0.0">
  <log-rotation>
    <get>
      <result>
        <status>error</status>
        <errcode>1034</errcode>
        <errtext>The domain is not hosted physically</errtext>
        <filter-id>example.com</filter-id>
      </result>
    </get>
  </log-rotation>
</packet>

 

Changing settings of multiple domains

The following request packet changes Log Rotation settings of domains used by the clients with ID 5 and ID 8:

<packet version="1.5.0.0">
  <log-rotation>
    <set>
        <filter>
          <client-id>5</client-id>
          <client-id>8</client-id>
        </filter>
        <settings>
          <log-condition>
            <log-bysize>2073741824</log-bysize>
          </log-condition>
        </settings>
    </set>
  </log-rotation>
</packet>

 

If the client with ID 5 was not found on the server and the client with ID 8 runs two domains (ID 17 and 29) the response from the server looks as follows:

<packet version="1.5.0.0">
   <set>
  <log-rotation>
      <result>
        <status>error</status>
        <errcode>1015</errcode>
        <errtext>client does not exist</errtext>
        <filter-id>5</filter-id>
      </result>
    </set>
    <set>
      <result>
        <status>ok</status>
        <filter-id>8</filter-id>
        <id>17</id>
      </result>
    </set>
    <set>
      <result>
        <status>ok</status>
        <filter-id>8</filter-id>
        <id>29</id>
      </result>
    </set>
  </log-rotation>
</packet>