Module Parameters

The module parameters are the data/values passed into each function when called. Every provisioning module function receives the same parameters. These parameters provide information about the specific product/service the module command runs for. The parameters also contains the settings from the product itself.

Parameters 

VariableTypeNotes
productArrayProduct Parameter have all the information related to define product/service in admin area Configuration -> Product/Services
configurationsArrayContains an array of all the configurable options defined on the product.
Again the key being the option name in this case
config_optionsArrayconfig_options Parameter have all the information related to Product/Server in admin area Configuration -> Configueable options
customfieldsArraycustomfields Parameter have all the information related to Product/Server in admin area Configuration -> Product/Services Custom Fields
serverArrayServer Parameter have all the information related to server in admin area Configuration -> Servers
clientArrayClient Parameter have all the information related to define client in admin area against client
Product Parameter Data mention below
pidintProduct/Service Unique ID
producttypestringThe product type which can be one of hosting,server,other,addon
serviceidintService Unique ID
server_idintServer Unique ID
order_idintOrder Unique ID
usernamestringUsername generated for the service. (defaults to first 8 letters of the domain)
Database Field: hosting.user_name
passwordstringPassword generated for the service.
(On first creation consisting of letters & numbers, both upper & lowercase).
Database Field: hosting.password
domainstringThe domain entered by the customer when ordering.
(On first creation consisting of letters & numbers, both upper & lowercase).
Database Field: hosting.domain_name
packagestringThe domain entered by the customer when ordering.
(On first creation consisting of letters & numbers, both upper & lowercase).
Database Field: hosting.domain_name
service_titlestringProduct/Service Name
descriptionstringProduct/Service Description
is_hiddenstringYES/NO as YES equal to hidden
payment_timestringDuration name as called payment terms
moduletypestringModule name
Client Parameter Data mention below
idintClient Unique ID
firstnamestringClient First Name
lastnamestringstringClient Last Name
usernamestringClient Unique Username
emailstringClient Unique email address
phonenumberstringClient Mobile Number
countrystringClient Country
citystringClient city
statestringClient state
payment_methodintClient Selected Payment Method ID
Server Parameter Data mention below
idintUnique ID
gidintServers Group ID
namestringServer Name
ipaddressstringIP Address
assignedipsstringAssigned IP addresses
hostnamestringServer Hostname
ns1stringServer Name Server 1
ns1ipstringServer Name Server 1 IP address
ns2stringServer Name Server 2
ns2ipstringServer Name Server 2 IP address
ns3stringServer Name Server 3
ns3ipstringServer Name Server 3 IP address
ns4stringServer Name Server 4
ns4ipstringServer Name Server 4 IP address
ns5stringServer Name Server 5
ns5ipstringServer Name Server 5 IP address
typestringServer Type
usernamestringServer Secure Username
passwordstringServer Secure Password
accesshashstringServer Secure Access hash
is_securestringYES/NO - Is an SSL connection enabled in the Server Configuration.
portstringThe server port if module supports override with custom port
statusstringYES/NO - Is an Server enabled in the Server Configuration.

Configurable Options

config_options are Configurable Options. These are defined in the Configuration ->Configureable options. Config Options are set on a per product basis: $params[‘config_options’]. config_options parameter have array set of key and values.

Note: Every module function except the _Config function receives the $params array. The _Config function is unique because it is the only function that is not called in relation to a specific client instance of a product or service.

Custom Fields

Values from any custom fields & configurable options are passed into modules as parameters. Passed as an array with the key being the name of the field or option.
For example for a custom field called “Username”, would become $params[‘customfields’][‘Username’]. Likewise, a configurable option named “Disk Space”, would become $params[‘configoptions’][‘Disk Space’].