CalculateHostPackagePricing


Definition

Calculate the cost and selling price of Web hosting packages (both existing and planned) based on the costs and selling prices of their components.

Usage

Use this command to configure one or more Web hosting packages and calculate their cost based on the components they contain. This command does not create the packages; rather, it allows you to adjust quantities of each component and view the effect on the overall price of the package. Once you have a configuration you like, you can create the package using the HostPackageDefine command.

Note that this command does not check for a valid package. For example, if you specify a PackageName that already exists as a Windows package but specify Linux in this query, the response will give the pricing for the Linux package; however, if you try to run HostPackageDefine with the Linux package, the query will fail.

Availability

All resellers have access to this command.

Implementation on eNom.com

Log on to resellertest.enom.com with Login ID resellid, password resellpw.

https://resellertest.enom.com/myaccount/hostingpricing.asp

In the Set Packages section, the re-calculate button calls the CalculateHostPackagePricing command.

Constraints

The query must meet the following requirements:

  • The login ID and password must be valid.

Input parameters

Build the query string using this syntax:

https://resellertest.enom.com/interface.asp?
command=nameofcommand&uid=yourloginid&pw=yourpassword
&paramname=paramvalue&nextparamname=nextparamvalue

 

Parameter Status Description Max Size
UID Required Account login ID 20
PW Required Account password 20
PackageCount Required Number of Web hosting packages being defined in this query 2
PackageNameX (X=1 to PackageCount) Required Name of Web hosting package X. To retrieve a list of currently defined packages, use the WebHostGetResellerPackages command. 14
OSTypeIDX Required Operating system of Web hosting package X. Permitted values are: 1 Windows 2 Linux 2
StorageUnitsX Optional; default is 1 Number of Web storage units to include in Web hosting package X. Each unit contains 1GB; maximum permitted is 400 units (total of 400GB). 2
BandwidthUnitsX Optional; default is 1 Number of bandwidth units to include in Web hosting package X. Each unit contains 20GB; maximum permitted is 150 units (total of 3000GB). 2
POPUnitsX Optional; default is 1 Number of POP email units to include in Web hosting package X. Each unit contains 10 email boxes with 100MB storage per mailbox; maximum permitted is 30 units (total of 300 mailboxes). 2
SQLUnitsX Optional; default is 0 Number of SQL database storage units to include in Web hosting package X. Each unit contains 250MB; maximum permitted is 30 units (total of 7500MB). 2
ResponseType Optional Format of response. Options are Text (default), HTML, or XML. 4

 

Returned parameters and values

Parameter Description
PackageNameX (Responses in text format are numbered, X=1 to PackageCount Name of this Web hosting package
StorageUnitsX Number of storage units for Web site content. Each storage unit is 1GB.
BandwidthUnitsX Number of bandwidth units in this package. Each bandwidth unit is 20GB.
POPUnitsX Number of POP mail units in this package. Each POP unit is 10 mailboxes, with 100MB storage per mailbox.
SQLUnitsX Number of units of SQL database storage in this package. Each SQL unit is 250MB.
OSTypeIDX ID number of the operating system of the Web hosting server for this Web hosting account. 1 indicates Windows; 2 indicates Linux.
OSTypeX Operating system of the Web hosting server for this Web hosting account. Return values are Windows or Linux.
PackageCostX The cost to this account for this package
SellPriceX The price this account charges customers for this package
PackageCount Number of different Web hosting packages listed in this response
Command Name of command executed
ErrCount The number of errors if any occurred. If greater than 0 check the Err(1 to ErrCount) values.
Err(x) Error messages explaining the failure. These can be presented as is back to the client.
Done True indicates this entire response has reached you successfully.

 

Notes

  • The default response format is plain text. To receive the response in HTML or XML format, send ResponseType=HTML or ResponseType=XML in your request.
  • Check the return parameter ErrCount. If greater than 0 the transaction failed. The parameter Err(ErrCount) can be presented to the client. Otherwise process the returned parameters as defined above.

Example