The convert-to-reseller operation is used to upgrade customer accounts to reseller accounts.
A request XML packet upgrading customer accounts to reseller accounts includes the convert-to-reseller node:
<packet> <customer> <convert-to-reseller> ... </convert-to-reseller> </customer> </packet>
The convert-to-reseller node does not have a separate type, it is
nested within the ClientTypeRequest complex type
client_input.xsd). Its graphical representation is as follows:
Note: The interactive schema navigator for all request packets is available here: http://plesk.github.io/api-schemas/188.8.131.52/agent_input.svg.
- The filter node is required. It specifies the filtering rule. Data type: clientSelectionFilterType. For more information on filters, refer to the Available Filters section.
- The reseller-plan-name node is optional. If it is not specified, then the user is converted, but is not subscribed to a reseller plan. Instead, it is allocated the sum of resources and permissions that were available to the customer.
The convert-to-reseller node of the output XML packet is structured as follows:
Note: The interactive schema navigator for all response packets is available here: http://plesk.github.io/api-schemas/184.108.40.206/agent_output.svg.
- The result node is required. It wraps the response retrieved
from the server. Data type: ResultFilterType
- The status node is required. It specifies the execution status of the operation. Data type: string. Allowed values: ok | error.
- The errcode node is optional. It is used to return the error code when the operation fails. Data type: unsignedInt.
- The errtext node is optional. Can be used to return the error message if the operation fails. Data type: string.
- The filter-id node is optional. Returns the filtering parameter. Data type: anySimple.
- The id node is optional. It is required if the operation succeeds. Returns the unique identifier of the reseller account. Data type: integer.
A request packet converting a customer account into a reseller account looks as follows:
<packet> <customer> <convert-to-reseller> <filter> <login>JDoe</login> </filter> </convert-to-reseller> </customer> </packet>
<packet version="220.127.116.11"> <customer> <convert-to-reseller> <result> <status>ok</status> <filter-id>JDoe</filter-id> <id>192</id> </result> </convert-to-reseller> </customer> </packet>