pem.activateSubscription
This method is supported by Operations starting from version 2.3.01.
This method creates subscription, sets resource limits for this subscription, and then executes subscription provisioning.
There are the following use cases of this method:
- Call pem.activateSubscription without
parameters
array passing. The system creates Subscription and performs provisioning. To add a Domain, pem.addDomain should be called separately. - Call pem.activateSubscription with
parameters
array passing. The system creates Subscription and Domain with physical hosting turned on, after that the provisioning takes place.
The method has the following input parameters:
Name |
Type |
Short Description |
---|---|---|
|
int |
The ID of the Subscription to activate. If the parameter is not specified |
|
string |
The name of Subscription. |
|
int |
The ID of Account to subscribe |
|
int |
The ID of the Service Template that should be used for Subscription creation. |
|
array of struct |
Subscription resource limits. It is optional parameter. If omitted then Service Template’s limits are used. |
|
int |
Resource Type ID. |
|
int |
Resource Type limit. Parameters Note: Use -1 value to make a resource unlimited. |
|
bigint |
Resource Type limit. It is 64bit analog of Note: Use -1 value to make a resource unlimited. |
|
array of struct |
The array of parameters ( |
|
string |
Parameter name. |
|
string |
Parameter value. |
|
boolean |
It is an optional parameter. Defines whether the Subscription will be used in Account-wide mode. Note: Switching subscription to the Account-wide mode is permanent. It is impossible to switch Subscription back to the Subscription-local mode. |
The table of parameters supported:
Name |
Value |
---|---|
|
The ID of Domain. If omitted, the system will assign the ID to Domain automatically. Otherwise, specified Domain ID value will be used. |
|
The name of Domain to create. |
|
The custom Webspace’s location relative the Webspaces Root directory of the Apache Web Server. If the parameter is omitted, an ID of a Webspace is used as default value. Examples:
|
|
Registrar status of Domain. Possible values:
If omitted, 2 (Domain is registered) is used by default. |
The method has the following output parameters:
Name |
Type |
Short Description |
---|---|---|
|
int |
The ID of the Subscription created. |
|
array of struct |
The result of Subscription auto-provisioning. It contains information about the provisioned Resources. It is not empty if Hosting Modules to which Resources belong use this parameter to return an additional information. |
|
int |
Resource Type ID of provisioned Resource. |
|
array of struct |
Information about the provisioned Resource. |
|
string |
Parameter name. |
|
string |
Parameter value. |
For XML-RPC sample of using this method see pem.activateSubscription Sample in XML-RPC Samples appendix.