Service management via API
Last updated
Last updated
v2.{ITEMTYPE}.order.param - order function
where {ITEMTYPE} - internal name of product type
API functions:
v2.vhost.order.param β order a shared hosting service;
v2.vds.order.param β order aVPS;
v2.dedic.order.param β order a dedicated server.
Mandatory parameters:
authinfo or auth β in a control panel;
pricelist β tariff id;
datacenter β data center id;
order_period β order period. Possible values: an integer which equals the number of months. For example, service order for 1 month β period=1, half-a-year β period=6, 1 year β period=12, etc;
sok β order is confirmed.
Additional parameters:
domain β service domain name. if this parameter is not specified, BILLmanager will set a random value;
skipbasket β the skipbasket=on parameter indicates that the service renewal won't be added into the Cart, but the system will charge the client.
autoprolong β auto-renewal period. Possible values: an integer which equals the number of months;
ostempl β operating system template for a dedicated server or VPS;
recipe β the system will execute the recipe on a dedicated server or VPS after operating system setup;
remoteid β unique identifier of the service on the side of the reselling billing platform.
Tariff add-ons are passed via the addon_ parameter. Possible value: addon_5=10, where 5 β add-on id, 10 β value. You can find the add-on id in Tariff plans β Configuration β id field. You can activate the filed in the table settings form.
The example of an API call for a shared hosting order:
The example of an API call for a VPS order:
The example of an API call for a dedicated server order:
The Dragon interface theme basket is different from the Orion basket. To have orders added to the Dragon shopping cart via the API, pass the ISP-Client:Web-interface header and add the theme=dragon parameter.
Copy
The service renewal function:
service.prolong
Mandatory parameter
elid β service id;
period β order period. Possible values: an integer which equals the number of months. For example, service order for 1 month β period=1, half-a-year β period=6, 1 year β period=12, etc;
sok β operation confirmation.
Optional parameters:
skipbasket β the ''skipbasket=on'' parameter indicates that the system won't add the service renewal order into the Cart, but will charge the client.
The example of API call for a service renewal:
API function:
vds.edit β change the parameters of the virtual server;
dedic.edit β change dedicated server parameters;
vhost.edit β change virtual hosting parameters;
soft.edit β change license parameters;
platform.edit β change platform parameters, etc.
Parameters:
autoprolong β parameter for autoprolong, specify period;
elid β unique identifier (service id).
Parameter autoprolong is responsible for autoprolong.
Its possible values are:
autoprolong=X β when ordering a license, autoprolong will be set for X months;
autoprolong=12 β autoprolong for a year;
autoprolong=null β no autoprolonging.
A different function is used for each product type. In the example we have set the autoprolong for a month for the product type Licenses (soft.edit function). For auto-renewal of other product types you need to use appropriate function:
Example of a request for auto-renewal of the service for a month
API functions:
vds β virtual server;
dedic β dedicated server;
vhost β virtual hosting;
soft β licenses;
platform β platform, etc.
Parameters:
filter=on β setting filter by specified parameters
out=<format> β output format
status=2 β output only active services
account β client's name. It is necessary to add all text from the Name field. The query will not work correctly if the data do not correspond to the ones, specified in the field. For example, value "account=Primerovich (example@example.ru)".
Information about active services by product type for the selected client.
Example API call to display active dedicated client servers
The query will not work correctly if the data does not match the ones specified in the field. For example, the value "account=Primerovich (example@example.ru)".
API function:
vds β virtual server;
dedic β dedicated server;
vhost β virtual hosting;
soft β licenses;
platform β platform, etc.
Parameters:
out=<format> β output format
Information about services by product type for the selected client.
API functions:
vhost.edit β edit shared hosting parameters;
vds.edit β edit VPS parameters;
dedic.edit β edit dedicated server parameters.
Mandatory parameters:
elid β service id;
sok β operation confirmation
Optional parameters :
addon_ β tariff add-on that should be edited, for example, addon_11=512, where 11 β add-on id, 512 β value. You can find the add-on id in Tariff plans β Configuration β id field. You can activate the filed in the table settings form;
autoprolong β auto-renewal period. Possible values: an integer which equals the number of months;
skipbasket β the skipbasket=on parameter indicates that the add-on won't be added into the Cart, but the system will charge the client.
More parameters are available in the Admin panel:
domain β service domain name;
ip β service IP address;
username β username in a control panel (e.g. in VMmanager);
userpassword β user password in a control panel (e.g. in VMmanager);
serverid β server name in a control panel (e.g. in VMmanager);
ostempl β OS template for a VPS or dedicated server;
recipe β pre-installed software (recipe) for a VPS or dedicated server;
The example of API call to modify parameters of a shared hosting service :
The example of API call to modify parameters of a virtual private server:
The example of API call to modify the domain name, IP address, and user credentials in a control panel for a VPS:
The example of API call to modify parameters of a dedicated server:
authinfo or auth β in a control panel;
authinfo or auth β in a control panel;