The possibility of importing the billing data (accounts and subscriptions) in Parallels Business Automation - Standard can considerably facilitate migration of customer's data and reduce cost. If you provide Virtuozzo Containers or/and Plesk domains to your customers and feel like it is the right time to automate your business, you can import the customer billing data in Parallels Business Automation - Standard without the need to use special plug-ins or other complex tools.
All you need is to represent your customers billing data as a simple XML structure and then run the import script provided with this XML file as a parameter. The script processes one XML file per one run.
After the Parallels Business Automation - Standard installation, the import script location on your Management Node is
/usr/sbin/hspc-import./import.pl
The sample XML file (example.xml) you can use to check how the import script works is located in the same directory.
Thus, the command line syntax to run the import script is the following:
/usr/sbin/hspc-import/import.pl filename.xml
where filename.xml should be replaced with the actual name of XML file containing customer's billing data. Please always indicate the full path to the XML file in the command line.
If something goes wrong, e.g., an XML structure is not valid, the script stops and rolls back all the changes made before an outage.
To prepare for the billing data import, you will need to create a set relevant of hosting plans in Parallels Business Automation - Standard to "move" customers to these hosting plans. When you create such hosting plans, you should take into account the fees, resources configuration, applications set, and all the other parameters of the subscription you are going to move to Parallels Business Automation - Standard for future management and billing.
When you create hosting plans in Parallels Business Automation - Standard, each of these plans gets the unique numerical identifier (ID) assigned automatically in Parallels Business Automation - Standard to all objects (including hosting plans). This ID should be indicated with the relevant tag in the XML file so that the import script could fetch the fees and other data from this hosting plan when creating the subscription.
The import script creates accounts and, for each account, one or more subscriptions that correspond to the preset Parallels Business Automation - Standard hosting plans. As a result, a customer obtains the "empty" Virtuozzo Container or Plesk domain that is managed and billed by Parallels Business Automation - Standard. The personal customer data (websites, mailboxes, home directory contents, etc.) can be manually moved into a newly created Virtuozzo Container or Plesk domain.
The structure of XML file is very simple. All XML data is placed in the <DATA> tag that opens and closes the file. The <DATA> tag contains the set of <ACCOUNT> tags. The <DATA> tag can contain as many account data (placed inside the <ACCOUNT> tags) as you need to import in one run of the import.pl script. Every <ACCOUNT> tag contains the information about account itself.
Below we describe each tag in details.
Below we describe all the tags containing inside the <DATA> tag:
Now we describe all the tags that contain inside each of the <ACCOUNT> tags:
The example of XML file:
<DATA>
<ACCOUNT>
<ACC_NAME>Hosting Inc.</ACC_NAME>
<ACC_BALANCE>10.45</ACC_BALANCE>
<ACC_ADDRESS>One str., 2</ACC_ADDRESS>
<ACC_CITY>Karson</ACC_CITY>
<ACC_STATEALT>Distr of</ACC_STATEALT>
<ACC_ZIP>141700</ACC_ZIP>
<ACC_COUNTRY>US</ACC_COUNTRY>
<ACC_PHONE>8|1|1292627|</ACC_PHONE>
<ACC_FNAME>John</ACC_FNAME>
<ACC_LNAME>Smith</ACC_LNAME
<ACC_EMAIL>smith@mail.com</ACC_EMAIL>
<ACC_CORPORATE>0</ACC_CORPORATE>
</ACCOUNT>
<ACCOUNT>
. . .
</ACCOUNT>
. . .
</DATA>