The duplicate operation is used to create a copy of the specified service plan.
Request Packet Structure
A request XML packet creating a copy of the specified service plan includes the duplicate operation node:
duplicate node is presented by type DomainTemplateDuplicateInputType (
domain_template.xsd). Its graphical representation is as follows:
- The filter node is required. It serves to specify the criteria by which the necessary service plans will be selected from the database. Data type: DomainTemplateFilterType (
domain_template.xsd). See the Available Filters section for details on this node.
- The owner-id node is optional. It specifies the ID of the service plan owner. Data type: integer.
- The owner-login node is optional. It specifies the login name of the service plan owner. Data type: string.
- The duplicate-name node is required. It specifies the name of the service plan copy. Data type: string.
Important: When creating request packets, put nodes and elements in the order they follow in the packet structure.
Response Packet Structure
The duplicate node of the output XML packet is of type DomainTemplateAddOutputType (
domain_template.xsd)which has the following presentation:
- The result node is required. It wraps the response got from the server. Data type: resultType (
- The status node is required. Specifies the execution status of the operation. Data type: string. Allowed values: ok | error.
- The errcode node is optional. Returns the error code when the operation fails. Data type: unsignedInt.
- The errtext node is optional. Returns the error message if the operation fails. Data type: string.
- The id node is optional. It is required if the operation has succeeded. Returns the unique identifier of a service plan just added to Plesk. Data type: integer.
- The guid node is optional. Returns the GUID of a service plan just added to Plesk. Data type: string.
This packet creates the copy of the service plan with id 1234 owned by user with login name JDoe and assigns the name Plan copy to the copy.