Configuring Service Plan Settings

The set operation is used to update service plan settings.

In this chapter:

Request Packet Structure

Response Packet Structure

Samples

 

Request Packet Structure

A request XML packet adjusting service plan settings includes the set operation node:

<packet>
<service-plan>
   <set>
   ...
   </set>
</service-plan>
</packet>

 

Important: When you update plan settings, all the associated unlocked subscriptions are automatically updated.

The set node is presented by type DomainTemplateSetInputType (domain_template.xsd). Its graphical representation is as follows:

service-plan-web-settings-set

Important: When creating request packets, put nodes and elements in the order they follow in the packet structure.

 

Response Packet Structure

The set node of the output XML packet is of type DomainTemplateSetOutputType (domain_template.xsd) which is structured as follows:

 

Samples

Updating service plans specified by ID

This request packet updates two service plans specified by ID.

<packet version="1.6.3.0">
<service-plan>
<set>
   <filter>
      <id>11</id>
      <id>12</id>
   </filter>
   <mail>
      <webmail>false</webmail>
   </mail>
</set>
</service-plan>
</packet>

Response:

<packet version="1.6.3.0">
<service-plan>
<set>
   <result>
      <status>ok</status>
      <id>11</id>
   </result>
   <result>
      <status>ok</status>
      <id>12</id>
   </result>
</set>
</service-plan>
</packet>
Update service plans that belong to different Plesk users

To update settings of update only plans of a particular reseller, specify their ID or username.

<packet>
<service-plan>
<set>
   <filter>
      <name>base_plan</name>
   </filter>
   <owner-login>JDoe</owner-login>
   <mail>
      <webmail>true</webmail>
   </mail>
</set>
</service-plan>
</packet>

If you are authorized as the Administrator, you can omit the reseller details:

<packet>
<service-plan>
<set>
   <filter>
      <name>base_plan</name>
   </filter>
   <mail>
      <webmail>true</webmail>
   </mail>
</set>
</service-plan>
</packet> 
Operating multiple service plans

Here is the sample packet that sets similar service plan settings for two different service plans, both specified by ID.

<packet>
<service-plan>
<set>
   <filter>
      <id>11</id>
      <id>12</id>
   </filter>
   <mail>
      <webmail>true</webmail>
   </mail>
</set>
</service-plan>
</packet>

 

To set different settings for two service plans, use two different set operations:

<packet>
<service-plan>
<set>
   <filter>
      <id>12</id>
   </filter>
   <owner-login>JDoe</owner-login>
   <mail>
      <webmail>false</webmail>
   </mail>
</set>
<set>
   <filter>
      <name>base_plan</name>
   </filter>
   <mail>
      <webmail>true</webmail>
   </mail>
</set>
</service-plan>
</packet>

 

 

The following packet updates all service plans that belong to the request packet sender:

<packet>
<service-plan>
<set>
   <filter/>
   <mail>
      <webmail>false</webmail>
   </mail>
</set></service-plan>
</packet> 
Mailing settings

The following packet updates mail settings for plan bounce_plan:

 <packet>
<service-plan>
<set>
   <filter>
      <name>bounce_plan</name>
   </filter>
        <mail>
          <nonexistent-user>
            <reject/>
          </nonexistent-user>
          <webmail>none</webmail>
        </mail>
</set>
</service-plan>
</packet>
Limits

The following packet updates limits of a plan:

<packet>
<service-plan>
<set>
   <filter>
      <id>12</id>
   </filter>
   <limits>
          <limit>
            <name>disk_space</name>
            <value>10737418240</value>
          </limit>
   </limits>
</set>
</service-plan>
</packet>
Log rotation

To disable log rotation for the plan with ID 12, use the following packet:

<packet>
<service-plan>
<set>
   <filter>
      <id>12</id>
   </filter>
   <log-rotation>
      <off/>
   </log-rotation>
</set>
</service-plan>
</packet>
Preferences

The following packet updates preferences for the plan with ID 12:

<packet>
<service-plan>
<set>
   <filter>
      <id>12</id>
   </filter>
        <preferences>
          <stat>3</stat>
          <maillists>false</maillists>
          <dns_zone_type>master</dns_zone_type>
        </preferences>
</set>
</service-plan>
</packet>
Hosting

This packet updates physical hosting settings for the plan with ID 12.

<packet>
<service-plan>
<set>
   <filter>
      <id>12</id>
   </filter>
   <hosting>
      <vrt_hst>
            <property>
              <name>ssl</name>
              <value>true</value>
            </property>
      </vrt_hst>
   </hosting>
</set>
</service-plan>
</packet>
Performance

Here is the sample packet that updates performance settings for the plan with ID 12.

<packet>
<service-plan>
<set>
   <filter>
      <id>12</id>
   </filter>
   <performance>
      <bandwidth>1000</bandwidth>
      <max_connections>20</max_connections>
   </performance>
</set>
</service-plan>
</packet>