NAV Navbar
phpphp perlperl rubyruby pythonpython javascriptjavascript

Introduction

Welcome to the InterServer API! You can use this API to access the featurs you enjoy through our websites. We have code samples for all of the API calls in many languages and implementnig the API calls in varoius ways. At the time of this writing we have at least 1 script for each api call in PHP, Python, Perl, and Ruby.

You can view code examples in the dark area to the right, and you can switch the programming language of the examples with the tabs in the top right.

Connecting To the API

Prerequisites and API URLs

API Endpoint: https://my.interserver.net/api.php
WSDL File: https://my.interserver.net/api.php?wsdl

To use the API you will need to first have an account with us.  You can sign up for an account at http://my.interserver.net/

Authentication

Use this code to authenticate and get a session id. Make sure to replace 'username@site.com' and 'password' with your actual info

<?php
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
$session_id = $client->api_login('username@site.com', 'password');
if (!strlen($session_id) > 0)
    die("Failure!\nNo Session Returned - Bad Login Info\n");
echo "Success!\n Got Session ID: {$session_id}\n”;
// Rest of code logic would go here
?>
use SOAP::Lite;
print SOAP::Lite
-> uri('urn:myapi')
-> proxy('https://my.interserver.net/api.php?wsdl')
-> api_login('username@site.com', 'password')
-> result;
require 'savon'

# create a client for the service
client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')

response = client.call(:api_login, message: {})
print response.body[:api_login_response][:return],"\n"
from pysimplesoap.client import SoapClient
client = SoapClient(wsdl="https://my.interserver.net/api.php?WSDL",trace=False)
response = client.api_login('username@site.com', 'password')
print response

Billing

Add Prepay

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$module = $ARGV[2];
$amount = $ARGV[3];
$automatic_use = $ARGV[4];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_add_prepay($sid, $module, $amount, $automatic_use);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_add_prepay()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_add_prepay, message: { 
    sid: ARGV[0], 
    module: ARGV[1], 
    amount: ARGV[2], 
    automatic_use: ARGV[3], 
})
print response.body[:api_add_prepay_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$module = $_SERVER['argv'][3];
$amount = $_SERVER['argv'][4];
$automatic_use = $_SERVER['argv'][5];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_add_prepay($sid, $module, $amount, $automatic_use);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_add_prepay

Adds a PrePay into the system under the given module. PrePays are a credit on * your account by prefilling your account with funds. These are stored in a * PrePay. PrePay funds can be automatically used as needed or set to only be * usable by direct action

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
module string the module the prepay is for. use get_modules to get a list of modules
amount float the dollar amount of prepay total
automatic_use bool whether or not the prepay will get used automatically by billing system.

Output Fields

Field Type Description
return int the prepay id

Example API Response

Type Value
Integer 28891

Get Paypal Url

a#!/usr/bin/perl -w
use SOAP::Lite;

$module = $ARGV[0];
$invoice = $ARGV[1];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$res = $client
  -> api_get_paypal_url($module, $invoice);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info

result = client.service.api_get_paypal_url()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_get_paypal_url, message: { 
    module: ARGV[0], 
    invoice: ARGV[1], 
})
print response.body[:api_get_paypal_url_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$module = $_SERVER['argv'][1];
$invoice = $_SERVER['argv'][2];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $res = $client->api_get_paypal_url($module, $invoice);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_get_paypal_url

Get the PayPal payment URL for an invoice on a given module.

Input Parameters

Parameter Type Description
module string the module the invoice is for. use get_modules to get a list of modules
invoice int the invoice id, or a comma separated list of invoice ids to get a payment url for.

Output Fields

Field Type Description
return string the paypal payment url.

Example API Response

Type Value
String Click Here to make a PayPal payment

Get Prepay List

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_get_prepay_list($sid);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_get_prepay_list()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_get_prepay_list, message: { 
    sid: ARGV[0], 
})
print response.body[:api_get_prepay_list_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_get_prepay_list($sid);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_get_prepay_list

Gets a list of your current prepays added into the system and how much is left * on each one.

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call

Output Fields

Field Type Description
prepay_id int PrePay ID
prepay_type int Type of PrePay
prepay_status string Status of the Prepay
prepay_date string Date the PrePay was last Updated
prepay_created string Date the PrePay was Created
prepay_amount float Total Amount of the PrePay
prepay_remaining float Currently Remaining aount in the PrePyay
prepay_service int Service (if any) the PrePay is specificly for
prepay_automatic_use int Wether or not the PrePay gets automatically used by periodic biling
prepay_module string Module of the PrePay

Example API Response

Prepay Id Prepay Type Prepay Status Prepay Date Prepay Created Prepay Amount Prepay Remaining Prepay Service Prepay Automatic Use Prepay Module
1116 0 2017-01-11 14:03:02 2015-10-29 23:06:37 10 0 0 1 domains
1117 0 2017-01-11 14:03:02 2015-10-29 23:10:23 10 0 0 1 domains
1118 0 2017-01-11 14:03:02 2015-10-29 23:26:52 10 0 0 1 domains
1119 0 2017-01-11 14:03:02 2015-10-29 23:28:27 10 0 0 1 domains
1120 0 2017-01-11 14:03:02 2015-10-29 23:36:50 10 0 0 1 domains
1121 0 2017-01-11 14:03:02 2015-10-29 23:44:48 10 0 0 1 domains
1122 0 2017-01-11 14:03:02 2015-10-29 23:52:55 10 0 0 1 domains
1123 0 2017-01-11 14:03:02 2015-10-29 23:57:24 10 0 0 1 domains
1124 0 2017-01-11 14:03:02 2015-10-29 23:58:56 10 0 0 1 domains
1125 0 2017-01-11 14:03:02 2015-10-30 00:03:50 10 0 0 1 domains
1126 0 2017-01-11 14:03:02 2015-10-30 00:04:34 10 0 0 1 domains
1127 0 2017-01-11 14:03:02 2015-10-30 00:29:32 10 0 0 1 domains
1128 0 2017-01-11 14:03:02 2015-10-30 00:31:38 10 0 0 1 domains
1129 0 2017-01-11 14:03:02 2015-10-30 00:48:41 10 0 0 1 domains
1130 0 2017-01-11 14:03:02 2015-10-30 01:02:53 10 0 0 1 domains
1131 0 2017-01-11 14:03:02 2015-10-30 01:09:31 10 0 0 1 domains
1132 0 2017-01-11 14:03:02 2015-10-30 01:13:03 10 0 0 1 domains
1133 0 2017-01-11 14:03:02 2015-10-30 01:14:30 10 0 0 1 domains
1134 0 2017-01-11 14:03:02 2015-10-30 01:15:18 10 0 0 1 domains
1135 0 2017-01-11 14:03:02 2015-10-30 01:17:42 10 0 0 1 domains
1136 0 2017-01-11 14:03:02 2015-10-30 01:18:04 10 0 0 1 domains
1137 0 2017-01-11 14:03:02 2015-10-30 01:19:13 10 0 0 1 domains
1138 0 2017-01-11 14:03:02 2015-10-30 01:20:54 10 0 0 1 domains
1139 0 2017-01-11 14:03:02 2015-10-30 01:21:19 10 0 0 1 domains
1140 0 2017-01-11 14:03:02 2015-10-30 01:22:44 10 0 0 1 domains
1141 0 2017-01-11 14:03:02 2015-10-30 01:40:44 10 0 0 1 domains
1142 0 2017-01-11 14:03:02 2015-10-30 01:54:02 10 0 0 1 domains
1143 0 2017-01-11 14:03:02 2015-10-30 02:01:25 10 0 0 1 domains
1144 0 2017-01-11 14:03:02 2015-10-30 02:15:47 10 0 0 1 domains
1145 0 2017-01-11 14:03:02 2015-10-30 02:23:04 10 0 0 1 domains
1146 0 2017-01-11 14:03:02 2015-10-30 02:26:35 10 0 0 1 domains
1147 0 2017-01-11 14:03:02 2015-10-30 02:36:40 10 0 0 1 domains
1148 0 2017-01-11 14:03:02 2015-10-30 02:39:59 10 0 0 1 domains
1149 0 2017-01-11 14:03:02 2015-10-30 02:42:15 10 0 0 1 domains
1150 0 2017-01-11 14:03:02 2015-10-30 02:44:05 10 0 0 1 domains
1151 0 2017-01-11 14:03:02 2015-10-30 02:56:59 10 0 0 1 domains
1152 0 2017-01-11 14:03:02 2015-10-30 04:27:34 10 0 0 1 domains
1156 0 2017-01-11 14:03:02 2015-10-30 14:48:00 10 0 0 1 domains
1157 0 2017-01-11 14:03:02 2015-10-30 14:55:41 10 0 0 1 domains
1158 0 2017-01-11 14:03:02 2015-10-30 14:55:57 10 0 0 1 domains
1159 0 2017-01-11 14:03:02 2015-10-30 15:00:26 10 0 0 1 domains
1160 0 2017-01-11 14:03:02 2015-10-30 15:01:13 10 0 0 1 domains
1161 0 2017-01-11 14:03:02 2015-10-30 15:02:57 10 0 0 1 domains
1162 0 2017-01-11 14:03:02 2015-10-30 15:05:15 10 0 0 1 domains
1163 0 2017-01-11 14:03:02 2015-10-30 15:08:01 10 0 0 1 domains
1164 0 2017-01-11 14:03:02 2015-10-30 15:15:26 10 0 0 1 domains
1165 0 2017-01-11 14:03:02 2015-10-30 15:21:50 10 0 0 1 domains
1166 0 2017-01-11 14:03:02 2015-10-30 15:27:48 10 0 0 1 domains
1167 0 2017-01-11 14:03:02 2015-10-30 15:29:10 10 0 0 1 domains
1168 0 2017-01-11 14:03:02 2015-10-30 15:29:23 10 0 0 1 domains
1169 0 2017-01-11 14:03:02 2015-10-30 15:29:43 10 0 0 1 domains
1170 0 2017-01-11 14:03:02 2015-10-30 15:29:52 109 0 0 0 domains
1171 0 2017-01-11 14:03:02 2015-10-30 15:29:55 109 0 0 0 domains
1172 0 2017-01-11 14:03:02 2015-10-30 15:29:57 10 0 0 0 domains
1173 0 2017-01-11 14:03:02 2015-10-30 15:35:31 10 0 0 1 domains
1174 0 2017-01-11 14:03:02 2015-10-30 15:44:53 10 0 0 1 domains
1175 0 2017-01-11 14:03:02 2015-10-30 15:45:06 10 0 0 1 domains
1176 0 2017-01-11 14:03:02 2015-10-30 15:45:44 10 0 0 1 domains
1177 0 2017-01-11 14:03:02 2015-10-30 15:48:39 10 0 0 1 domains
1178 0 2017-01-11 14:03:02 2015-10-30 15:50:22 10 0 0 1 domains
1179 0 2017-01-11 14:03:02 2015-10-30 15:51:26 10 0 0 1 domains
1180 0 2017-01-11 14:03:02 2015-10-30 15:52:00 10 0 0 1 domains
1181 0 2017-01-11 14:03:02 2015-10-30 15:53:00 10 0 0 1 domains
1182 0 2017-01-11 14:03:02 2015-10-30 16:26:46 10 0 0 1 domains
1246 0 2017-01-11 14:03:02 2015-11-03 11:21:14 10 0 0 1 domains
1247 0 2017-01-11 14:03:02 2015-11-03 12:28:39 10 0 0 1 domains
1248 0 2017-01-11 14:03:02 2015-11-03 12:31:39 10 0 0 1 domains
1249 0 2017-01-11 14:03:02 2015-11-03 12:34:45 10 0 0 1 domains
1250 0 2017-01-11 14:03:02 2015-11-03 12:38:22 10 0 0 1 domains
1251 0 2017-01-11 14:03:02 2015-11-03 12:41:20 10 0 0 1 domains
1253 0 2017-01-11 14:03:02 2015-11-03 12:44:51 10 0 0 1 domains
1254 0 2017-01-11 14:03:02 2015-11-03 12:50:16 10 0 0 1 domains
1255 0 2017-01-11 14:03:02 2015-11-03 13:35:18 10 0 0 1 domains
1256 0 2017-01-11 14:03:02 2015-11-03 13:44:03 10 0 0 1 domains
1257 0 2017-01-11 14:03:02 2015-11-03 13:46:17 10 0 0 1 domains
1258 0 2017-01-11 14:03:02 2015-11-03 13:48:09 10 0 0 1 domains
1259 0 2017-01-11 14:03:02 2015-11-03 13:51:14 10 0 0 1 domains
1260 0 2017-01-11 14:03:02 2015-11-03 13:59:41 10 0 0 1 domains
1261 0 2017-01-11 14:03:02 2015-11-03 13:59:52 10 0 0 1 domains
1262 0 2017-01-11 14:03:02 2015-11-03 14:02:00 10 0 0 1 domains
1263 0 2017-01-11 14:03:02 2015-11-03 14:03:35 10 0 0 1 domains
1264 0 2017-01-11 14:03:02 2015-11-03 14:04:33 10 0 0 1 domains
1265 0 2017-01-11 14:03:02 2015-11-03 14:06:21 10 0 0 1 domains
1266 0 2017-01-11 14:03:02 2015-11-03 14:08:45 10 0 0 1 domains
1267 0 2017-01-11 14:03:02 2015-11-03 14:15:31 10 0 0 1 domains
1268 0 2017-01-11 14:03:02 2015-11-03 14:30:40 10 0 0 1 domains
1269 0 2017-01-11 14:03:02 2015-11-03 14:31:36 10 0 0 1 domains
1270 0 2017-01-11 14:03:02 2015-11-03 14:36:05 10 0 0 1 domains
1271 0 2017-01-11 14:03:02 2015-11-03 16:47:31 10 0 0 1 domains
1272 0 2017-01-11 14:03:02 2015-11-03 16:52:46 10 0 0 1 domains
1273 0 2017-01-11 14:03:02 2015-11-03 16:58:52 10 0 0 1 domains
1274 0 2017-01-11 14:03:02 2015-11-03 17:01:43 10 0 0 1 domains
1275 0 2017-01-11 14:03:02 2015-11-03 18:21:42 10 0 0 1 domains
1276 0 2017-01-11 14:03:02 2015-11-03 18:24:23 10 0 0 1 domains
1277 0 2017-01-11 14:03:02 2015-11-03 18:29:29 10 0 0 1 domains
1278 0 2017-01-11 14:03:02 2015-11-03 21:28:48 10 0 0 1 domains
1280 0 2017-01-11 14:03:02 2015-11-04 02:19:41 10 0 0 1 domains
1307 0 2017-01-11 14:03:02 2015-11-18 09:50:40 10 0 0 1 domains
1308 0 2017-01-11 14:03:02 2015-11-18 12:30:51 10 0 0 1 domains
1470 0 2017-01-11 14:03:02 2015-12-23 16:08:59 10 0 0 1 domains
1481 0 2017-01-11 14:03:02 2015-12-29 04:28:35 10 0 0 1 domains
8618 0 2017-01-11 14:03:02 2016-01-08 15:38:09 10 0 0 1 domains
8619 0 2017-01-11 14:03:02 2016-01-08 15:39:30 10 0 0 1 domains
8620 0 2017-01-11 14:03:02 2016-01-08 18:19:20 10 0 0 1 domains
9693 0 2017-01-11 14:03:02 2016-04-10 08:58:30 10 0 0 1 domains
9694 0 2017-01-11 14:03:02 2016-04-10 09:19:26 10 0 0 1 domains
9695 0 2017-01-11 14:03:02 2016-04-10 09:28:53 10 0 0 1 domains
9696 0 2017-01-11 14:03:02 2016-04-10 09:39:03 10 0 0 1 domains
9697 0 2017-01-11 14:03:02 2016-04-10 10:01:34 10 0 0 1 domains
9698 0 2017-01-11 14:03:02 2016-04-10 10:06:17 10 0 0 1 domains
9700 0 2017-01-11 14:03:02 2016-04-10 10:16:37 10 0 0 1 domains
9701 0 2017-01-11 14:03:02 2016-04-10 10:18:43 10 0 0 1 domains
11897 0 2017-01-11 14:03:02 2016-10-22 04:44:25 10 0 0 1 domains
11898 0 2017-01-11 14:03:02 2016-10-22 04:47:12 10 0 0 1 domains
17838 0 2017-05-11 02:32:15 2017-05-11 02:32:15 10 0 0 1 domains
17841 0 2017-05-11 02:43:23 2017-05-11 02:43:23 10 0 0 1 domains
17873 0 2017-05-11 12:29:01 2017-05-11 12:29:01 10 0 0 1 domains
24542 0 2017-09-28 06:18:49 2017-09-28 06:18:49 10 0 0 1 domains
24543 0 2017-09-28 06:25:56 2017-09-28 06:25:56 10 0 0 1 domains
24544 0 2017-09-28 06:29:31 2017-09-28 06:29:31 10 0 0 1 domains
24545 0 2017-09-28 06:34:49 2017-09-28 06:34:49 10 0 0 1 domains
24563 0 2017-09-28 17:50:26 2017-09-28 17:50:26 10 0 0 1 domains
28884 0 0 2018-07-16 03:31:14 2018-07-16 03:31:14 10 0 0 1 domains
28885 0 0 2018-07-16 04:00:27 2018-07-16 04:00:27 10 0 0 1 domains
28886 0 0 2018-07-16 04:57:13 2018-07-16 04:57:13 10 0 0 1 domains
28887 0 0 2018-07-16 05:45:45 2018-07-16 05:45:45 10 0 0 1 domains
28889 0 0 2018-07-16 06:28:48 2018-07-16 06:28:48 10 0 0 1 domains
28890 0 0 2018-07-16 06:46:14 2018-07-16 06:46:14 10 0 0 1 domains
28891 0 0 2018-07-16 06:47:19 2018-07-16 06:47:19 10 0 0 1 domains

Get Prepay Paypal Fill Url

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$module = $ARGV[2];
$prepay_id = $ARGV[3];
$amount = $ARGV[4];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_get_prepay_paypal_fill_url($sid, $module, $prepay_id, $amount);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_get_prepay_paypal_fill_url()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_get_prepay_paypal_fill_url, message: { 
    sid: ARGV[0], 
    module: ARGV[1], 
    prepay_id: ARGV[2], 
    amount: ARGV[3], 
})
print response.body[:api_get_prepay_paypal_fill_url_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$module = $_SERVER['argv'][3];
$prepay_id = $_SERVER['argv'][4];
$amount = $_SERVER['argv'][5];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_get_prepay_paypal_fill_url($sid, $module, $prepay_id, $amount);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_get_prepay_paypal_fill_url

Gets a PayPal URL to fill a PrePay.

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
module string the module the prepay is for. use get_modules to get a list of modules
prepay_id int the ID of the PrePay
amount float the amount to pay on the prepay.

Output Fields

Field Type Description
return string a paypal payment url.

Example API Response

Type Value
String https://www.paypal.com/cgi-bin/webscr?cmd=_xclick&business=vps@interserver.net&item_name=Fill+domains+PrePay+100&custom=PREPAYdomains100&buyer_credit_promo_code=&buyer_credit_product_category=&buyer_credit_shipping_method=&buyer_credit_user_address_change=&amount=10.00&no_shipping=0&no_note=1¤cy_code=USD&lc=US&bn=PP%2dBuyNowBF&charset=UTF%2d8

Get Prepay Remaining

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$module = $ARGV[2];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_get_prepay_remaining($sid, $module);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_get_prepay_remaining()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_get_prepay_remaining, message: { 
    sid: ARGV[0], 
    module: ARGV[1], 
})
print response.body[:api_get_prepay_remaining_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$module = $_SERVER['argv'][3];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_get_prepay_remaining($sid, $module);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_get_prepay_remaining

Get the PrePay amount available for a given module.

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
module string the module you want to check your prepay amounts on

Output Fields

Field Type Description
status string Location Status
status_text string

Example API Response

Field Value
status ok
status_text 0

Make Payment

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$module = $ARGV[2];
$invoice = $ARGV[3];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_make_payment($sid, $module, $invoice);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_make_payment()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_make_payment, message: { 
    sid: ARGV[0], 
    module: ARGV[1], 
    invoice: ARGV[2], 
})
print response.body[:api_make_payment_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$module = $_SERVER['argv'][3];
$invoice = $_SERVER['argv'][4];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_make_payment($sid, $module, $invoice);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_make_payment

Makes a payment for an invoice on a module.

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
module string the module of the service being paid on
invoice int the invoice id you want to make a payment on

Output Fields

Field Type Description
status string Location Status
status_text string

Example API Response

Field Value
status error
status_text Invalid Invoice Number Passed or missing Module information.

General

Get Ima

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_get_ima($sid);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_get_ima()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_get_ima, message: { 
    sid: ARGV[0], 
})
print response.body[:api_get_ima_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_get_ima($sid);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_get_ima

Returns the IMA value. This function tells you that I'm a client, or I'm a * admin. This is almost always going to return client, Adminsitrators will get an * admin response.

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call

Output Fields

Field Type Description
return string

Login

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$res = $client
  -> api_login($username, $password);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info

result = client.service.api_login()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: { 
    username: ARGV[0], 
    password: ARGV[1], 
})
print response.body[:api_login_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $res = $client->api_login($username, $password);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_login

This function creates a session in our system which you will need to pass to * most functions for authentication.

Input Parameters

Parameter Type Description
username string the username (email address) you signed up with.
password string the password you use to login to the web account, or alternatively the API key.

Output Fields

Field Type Description
return string

Example API Response

Type Value
String 7ede4ab5304efdfa1f7f270f35f016a9

Get Hostname

a#!/usr/bin/perl -w
use SOAP::Lite;

$ip = $ARGV[0];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$res = $client
  -> get_hostname($ip);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info

result = client.service.get_hostname()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :get_hostname, message: { 
    ip: ARGV[0], 
})
print response.body[:get_hostname_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$ip = $_SERVER['argv'][1];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $res = $client->get_hostname($ip);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: get_hostname

Resolves an IP Address and returns the hostname it points to.

Input Parameters

Parameter Type Description
ip string

Output Fields

Field Type Description
return string

Example API Response

Type Value
String my.interserver.net

Get Locked Ips

a#!/usr/bin/perl -w
use SOAP::Lite;

$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$res = $client
  -> get_locked_ips();
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
result = client.service.get_locked_ips()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(:get_locked_ips)
print response.body[:get_locked_ips_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $res = $client->get_locked_ips();
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: get_locked_ips

This will return a list of all IP addresses used for fraud. Its probably of no * real use to anyone, butI use it to block IP addresses and similar things.

Input

This function takes no input parameters

Output Fields

Field Type Description
return array Array of IP Addresses

Example API Response

Value
0.0.0.0
0.0.214.110
0.109.177.189
0.120.138.209
0.155.237.135
0.155.34.18
0.231.26.146
1.1.1.1
1.10.133.120
1.10.133.214
1.10.217.123

Get Modules

a#!/usr/bin/perl -w
use SOAP::Lite;

$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$res = $client
  -> get_modules();
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
result = client.service.get_modules()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(:get_modules)
print response.body[:get_modules_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $res = $client->get_modules();
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: get_modules

Returns a list of all the modules available.

Input

This function takes no input parameters

Output Fields

Field Type Description
return array

Example API Response

Value
domains
vps
backups
licenses
ssl
webhosting
quickservers
servers

StrPixels

a#!/usr/bin/perl -w
use SOAP::Lite;

$string = $ARGV[0];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$res = $client
  -> strPixels($string);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info

result = client.service.strPixels()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :strPixels, message: { 
    string: ARGV[0], 
})
print response.body[:strPixels_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$string = $_SERVER['argv'][1];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $res = $client->strPixels($string);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: strPixels

This function uses the array below to calculate the pixel width of a string of * characters. The widths of each character are based on a 12px Helvetica font. * Kerning is not taken into account so RESULTS ARE APPROXIMATE. The purpose is to * return a relative size to help in formatting. For example, strPixels('I like * cake') == 54 strPixels('I LIKE CAKE') == 67

Input Parameters

Parameter Type Description
string string characters to measure size

Output Fields

Field Type Description
return int size in pixels.

Example API Response

Type Value
Integer 64

Support

GetTicketList

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$page = $ARGV[2];
$limit = $ARGV[3];
$status = $ARGV[4];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_getTicketList($sid, $page, $limit, $status);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_getTicketList()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_getTicketList, message: { 
    sid: ARGV[0], 
    page: ARGV[1], 
    limit: ARGV[2], 
    status: ARGV[3], 
})
print response.body[:api_getTicketList_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$page = $_SERVER['argv'][3];
$limit = $_SERVER['argv'][4];
$status = $_SERVER['argv'][5];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_getTicketList($sid, $page, $limit, $status);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_getTicketList

Returns a list of any tickets in the system.

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
page int page number of tickets to list
limit int how many tickets to show per page
status string null for no status limit or limit to a specific status

Output Fields

Field Type Description
status string null for no status limit or limit to a specific status
status_text string
totalPages string
tickets tns:getTicketList_tickets

Example API Response

Field Value
status ok
status_text List of tickets
totalPages 4
tickets Array

OpenTicket

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$user_email = $ARGV[2];
$user_ip = $ARGV[3];
$subject = $ARGV[4];
$product = $ARGV[5];
$body = $ARGV[6];
$box_auth_value = $ARGV[7];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_openTicket($sid, $user_email, $user_ip, $subject, $product, $body, $box_auth_value);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_openTicket()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_openTicket, message: { 
    sid: ARGV[0], 
    user_email: ARGV[1], 
    user_ip: ARGV[2], 
    subject: ARGV[3], 
    product: ARGV[4], 
    body: ARGV[5], 
    box_auth_value: ARGV[6], 
})
print response.body[:api_openTicket_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$user_email = $_SERVER['argv'][3];
$user_ip = $_SERVER['argv'][4];
$subject = $_SERVER['argv'][5];
$product = $_SERVER['argv'][6];
$body = $_SERVER['argv'][7];
$box_auth_value = $_SERVER['argv'][8];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_openTicket($sid, $user_email, $user_ip, $subject, $product, $body, $box_auth_value);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_openTicket

This command creates a new ticket in our system.

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
user_email string client email address
user_ip string client ip address
subject string subject of the ticket
product string the product/service if any this is in reference to.
body string full content/description for the ticket
box_auth_value string encryption string?

Output Fields

Field Type Description
status string Location Status
status_text string
ticket_reference_id int

Example API Response

Field Value
status Failed
status_text Invalid Email Address - Does not match your account email!
ticket_reference_id -1

TicketPost

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$ticketID = $ARGV[2];
$content = $ARGV[3];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_ticketPost($sid, $ticketID, $content);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_ticketPost()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_ticketPost, message: { 
    sid: ARGV[0], 
    ticketID: ARGV[1], 
    content: ARGV[2], 
})
print response.body[:api_ticketPost_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$ticketID = $_SERVER['argv'][3];
$content = $_SERVER['argv'][4];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_ticketPost($sid, $ticketID, $content);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_ticketPost

This commands adds the content parameter as a response/reply to an existing * ticket specified by ticketID.

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
ticketID string the id of the ticket to add a response to. you can use getTicketList to get a list of your tickets
content string the message to add to the ticket

Output Fields

Field Type Description
status string Location Status
status_text string

Example API Response

Field Value
status Failed
status_text Error loading ticket details!

ViewTicket

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$ticketID = $ARGV[2];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_viewTicket($sid, $ticketID);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_viewTicket()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_viewTicket, message: { 
    sid: ARGV[0], 
    ticketID: ARGV[1], 
})
print response.body[:api_viewTicket_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$ticketID = $_SERVER['argv'][3];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_viewTicket($sid, $ticketID);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_viewTicket

View/Retrieve information about the given ticketID.

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
ticketID string the id of the ticket to retrieve. you can use getTicketList to get a list of your tickets

Output Fields

Field Type Description
status string Location Status
status_text string
result tns:view_ticketdetail_array Rendered Search Result

Example API Response

Field Value
status Failed
status_text Error loading ticket details!
result Array

VPS

Controlling the VPS

You can use the API to perform basic control functions on your VPS server.
Current commands include the ability to Stop, Start, and Restart the server using the vps_queue_stop, vps_queue_start, and vps_queue_restart function calls. Some VPS types also allow you to use the vps_screenshot function to get a screenshot of whats currently on the VPS's screen.

Purchasing a VPS

The VPS order process is broken down into 2 functions. After choosing the order parameters, you must first make a call to validate_buy_vps to check for any problems in the parameters. The function will respond with an array containing an updated set of parameters (if any of them needed changed) and additional fields telling you if the order details were ok or a description of what problems there were in the order. It also will return with sevral fields telling you how much it will cost initially , how much it will cost each time you are billed after the initial signup, and how often you are billed. When you get an 'ok' as the 'status' response you can pass the parameters to the buy_vps function to place the order.
This function will also return a status field with 'ok' if the order was placed properly or 'error' otherwise and a description of any problems in status_text.

VPS Server Locations

Our more popular VPS types are available in multiple locations.
You should probably choose the location closest to you or your clients.
To get a list of the current locations use the get_vps_locations_array function.
Our primary datacenter location is in Secaucus, NJ (location id 1) and is probably the best choice if unsure what to choose.
Some of the VPS types might only be available at that location as well.

VPS Types and Pricing

We have several types of Servers available for use with VPS Hosting. You can get a list of the types available and there cost per slice/unit by making a call to the get_vps_slice_types function.
Additionally you can get a list of the vps platforms with the get_vps_platforms_array function.

VPS Details

To get a list of all your current VPS's you can use the vps_get_services function and vps_get_service to get all the details for a given VPS.

Buy VPS

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$os = $ARGV[2];
$slices = $ARGV[3];
$platform = $ARGV[4];
$controlpanel = $ARGV[5];
$period = $ARGV[6];
$location = $ARGV[7];
$version = $ARGV[8];
$hostname = $ARGV[9];
$coupon = $ARGV[10];
$rootpass = $ARGV[11];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_api_buy_vps($sid, $os, $slices, $platform, $controlpanel, $period, $location, $version, $hostname, $coupon, $rootpass);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_api_buy_vps()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_api_buy_vps, message: { 
    sid: ARGV[0], 
    os: ARGV[1], 
    slices: ARGV[2], 
    platform: ARGV[3], 
    controlpanel: ARGV[4], 
    period: ARGV[5], 
    location: ARGV[6], 
    version: ARGV[7], 
    hostname: ARGV[8], 
    coupon: ARGV[9], 
    rootpass: ARGV[10], 
})
print response.body[:api_api_buy_vps_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$os = $_SERVER['argv'][3];
$slices = $_SERVER['argv'][4];
$platform = $_SERVER['argv'][5];
$controlpanel = $_SERVER['argv'][6];
$period = $_SERVER['argv'][7];
$location = $_SERVER['argv'][8];
$version = $_SERVER['argv'][9];
$hostname = $_SERVER['argv'][10];
$coupon = $_SERVER['argv'][11];
$rootpass = $_SERVER['argv'][12];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_api_buy_vps($sid, $os, $slices, $platform, $controlpanel, $period, $location, $version, $hostname, $coupon, $rootpass);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_api_buy_vps

Places a VPS order in our system. These are the same parameters as * api_validate_buy_vps.. Returns a comma seperated list of invoices if any need * paid.

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
os string file field from get_vps_templates
slices int 1 to 16 specifying the scale of the VPS resources you want (a 3 slice has 3x the resources of a 1 slice vps)
platform string platform field from the get_vps_platforms_array
controlpanel string none, cpanel, or da for None, cPanel, or DirectAdmin control panel addons, only available with CentOS
period int 1-36, How frequently to be billed in months. Some discounts as given based on the period
location int id field from the get_vps_locations_array
version string os field from get_vps_templates
hostname string Desired Hostname for the VPS
coupon string Optional Coupon to pass
rootpass string Desired Root Password (unused for windows, send a blank string)

Output Fields

Field Type Description
status string Location Status
status_text string
invoices string Array
cost float

Example API Response

Field Value
status error
status_text Password must contain atleast 8 characters, one lowercase letter, one uppercase letter, one number, a special character and autogenerated password filled in it.
invoices
cost 6

Buy VPS Admin

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$os = $ARGV[2];
$slices = $ARGV[3];
$platform = $ARGV[4];
$controlpanel = $ARGV[5];
$period = $ARGV[6];
$location = $ARGV[7];
$version = $ARGV[8];
$hostname = $ARGV[9];
$coupon = $ARGV[10];
$rootpass = $ARGV[11];
$server = $ARGV[12];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_api_buy_vps_admin($sid, $os, $slices, $platform, $controlpanel, $period, $location, $version, $hostname, $coupon, $rootpass, $server);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_api_buy_vps_admin()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_api_buy_vps_admin, message: { 
    sid: ARGV[0], 
    os: ARGV[1], 
    slices: ARGV[2], 
    platform: ARGV[3], 
    controlpanel: ARGV[4], 
    period: ARGV[5], 
    location: ARGV[6], 
    version: ARGV[7], 
    hostname: ARGV[8], 
    coupon: ARGV[9], 
    rootpass: ARGV[10], 
    server: ARGV[11], 
})
print response.body[:api_api_buy_vps_admin_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$os = $_SERVER['argv'][3];
$slices = $_SERVER['argv'][4];
$platform = $_SERVER['argv'][5];
$controlpanel = $_SERVER['argv'][6];
$period = $_SERVER['argv'][7];
$location = $_SERVER['argv'][8];
$version = $_SERVER['argv'][9];
$hostname = $_SERVER['argv'][10];
$coupon = $_SERVER['argv'][11];
$rootpass = $_SERVER['argv'][12];
$server = $_SERVER['argv'][13];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_api_buy_vps_admin($sid, $os, $slices, $platform, $controlpanel, $period, $location, $version, $hostname, $coupon, $rootpass, $server);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_api_buy_vps_admin

Purchase a VPS (admins only). Returns a comma seperated list of invoices if * any need paid. Same as client function but allows specifying which server to * install to if there are resources available on the specified server.

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
os string file field from get_vps_templates
slices int 1 to 16 specifying the scale of the VPS resources you want (a 3 slice has 3x the resources of a 1 slice vps)
platform string platform field from the get_vps_platforms_array
controlpanel string none, cpanel, or da for None, cPanel, or DirectAdmin control panel addons, only available with CentOS
period int 1-36, How frequently to be billed in months. Some discounts as given based on the period
location int id field from the get_vps_locations_array
version int os field from get_vps_templates
hostname string Desired Hostname for the VPS
coupon string Optional Coupon to pass
rootpass string Desired Root Password (unused for windows, send a blank string)
server int 0 for auto assign otherwise the id of the vps master to put this on

Output Fields

Field Type Description
status string Location Status
status_text string
invoices string Array
cost float

Example API Response

Field Value
status error
status_text Password must contain atleast 8 characters, one lowercase letter, one uppercase letter, one number, a special character and autogenerated password filled in it.
invoices
cost 6

Validate Buy VPS

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$os = $ARGV[2];
$slices = $ARGV[3];
$platform = $ARGV[4];
$controlpanel = $ARGV[5];
$period = $ARGV[6];
$location = $ARGV[7];
$version = $ARGV[8];
$hostname = $ARGV[9];
$coupon = $ARGV[10];
$rootpass = $ARGV[11];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_api_validate_buy_vps($sid, $os, $slices, $platform, $controlpanel, $period, $location, $version, $hostname, $coupon, $rootpass);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_api_validate_buy_vps()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_api_validate_buy_vps, message: { 
    sid: ARGV[0], 
    os: ARGV[1], 
    slices: ARGV[2], 
    platform: ARGV[3], 
    controlpanel: ARGV[4], 
    period: ARGV[5], 
    location: ARGV[6], 
    version: ARGV[7], 
    hostname: ARGV[8], 
    coupon: ARGV[9], 
    rootpass: ARGV[10], 
})
print response.body[:api_api_validate_buy_vps_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$os = $_SERVER['argv'][3];
$slices = $_SERVER['argv'][4];
$platform = $_SERVER['argv'][5];
$controlpanel = $_SERVER['argv'][6];
$period = $_SERVER['argv'][7];
$location = $_SERVER['argv'][8];
$version = $_SERVER['argv'][9];
$hostname = $_SERVER['argv'][10];
$coupon = $_SERVER['argv'][11];
$rootpass = $_SERVER['argv'][12];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_api_validate_buy_vps($sid, $os, $slices, $platform, $controlpanel, $period, $location, $version, $hostname, $coupon, $rootpass);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_api_validate_buy_vps

Checks if the parameters for your order pass validation and let you know if * there are any errors. It will also give you information on the pricing * breakdown.

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
os string file field from get_vps_templates
slices int 1 to 16 specifying the scale of the VPS resources you want (a 3 slice has 3x the resources of a 1 slice vps)
platform string platform field from the get_vps_platforms_array
controlpanel string none, cpanel, or da for None, cPanel, or DirectAdmin control panel addons, only available with CentOS
period int 1-36, How frequently to be billed in months. Some discounts as given based on the period
location int id field from the get_vps_locations_array
version string os field from get_vps_templates
hostname string Desired Hostname for the VPS
coupon string Optional Coupon to pass
rootpass string Desired Root Password (unused for windows, send a blank string)

Output Fields

Field Type Description
coupon_code int
service_cost float
slice_cost float
service_type int
repeat_slice_cost float
original_slice_cost float
original_cost float
repeat_service_cost float
monthly_service_cost float
custid int Customer ID
os string file field from get_vps_templates
slices int 1 to 16 specifying the scale of the VPS resources you want (a 3 slice has 3x the resources of a 1 slice vps)
platform string platform field from the get_vps_platforms_array
controlpanel string none, cpanel, or da for None, cPanel, or DirectAdmin control panel addons, only available with CentOS
period int 1-36, How frequently to be billed in months. Some discounts as given based on the period
location int id field from the get_vps_locations_array
version string os field from get_vps_templates
hostname string Desired Hostname for the VPS
coupon string Optional Coupon to pass
rootpass string Desired Root Password (unused for windows, send a blank string)
status_text string
status string Location Status

Example API Response

Field Value
coupon_code 0
service_cost 6
slice_cost 6
service_type 31
repeat_slice_cost 6
original_slice_cost 6
original_cost 6
repeat_service_cost 6
monthly_service_cost 6
custid 160884
os ubuntu-15.04-x86_64.tar.gz
slices 1
platform openvz
controlpanel none
period 1
location 1
version ubuntu
hostname myserver.mydomain.com
coupon
rootpass sampleP4ssw0rd
status_text Password must contain atleast 8 characters, one lowercase letter, one uppercase letter, one number, a special character and autogenerated password filled in it.
status error

VPS Cancel Service

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$id = $ARGV[2];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_vps_cancel_service($sid, $id);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_vps_cancel_service()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_vps_cancel_service, message: { 
    sid: ARGV[0], 
    id: ARGV[1], 
})
print response.body[:api_vps_cancel_service_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$id = $_SERVER['argv'][3];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_vps_cancel_service($sid, $id);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_vps_cancel_service

This Function Applies to the VPS services. * Cancels a service for the passed module matching the passed id. Canceling a * service will also cancel any addons for that service at the same time.

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
id int ID / Service ID you wish to cancel

Output Fields

Field Type Description
return bool

Example API Response

Type Value
Boolean 1

VPS Get Client Invoices

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_vps_get_client_invoices($sid);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_vps_get_client_invoices()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_vps_get_client_invoices, message: { 
    sid: ARGV[0], 
})
print response.body[:api_vps_get_client_invoices_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_vps_get_client_invoices($sid);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_vps_get_client_invoices

This Function Applies to the VPS services. * Gets a list of all the invoices.

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call

Output Fields

Field Type Description
invoices_id int ID of the Invoice used for referencing
invoices_description string Description of what the Invoice was for
invoices_amount float Cost of the Invoice
invoices_custid int ID of the Customer this Invoice is for
invoices_type int The Type of Invoice (1 = charge, 10+ are payment types)
invoices_date string Date the Invoice was Created
invoices_group int Billing Group the Invoice falls under, Not currently used
invoices_extra int If type 1 invoice this points to the repeat invoice id, otherwise points to the id of the charge invoice its a payment for.
invoices_paid int Wether or not the Invoice was paid (if applicable)
invoices_module string Module the Invoice was for. You can use get_modules to get a list of available modules.
invoices_due_date string Date the Invoice is Due
invoices_service int ID of the Service/Order this Invoice is for such as 1000 if the order was vps1000 and the module was vps

VPS Get Client Unpaid Invoices

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_vps_get_client_unpaid_invoices($sid);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_vps_get_client_unpaid_invoices()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_vps_get_client_unpaid_invoices, message: { 
    sid: ARGV[0], 
})
print response.body[:api_vps_get_client_unpaid_invoices_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_vps_get_client_unpaid_invoices($sid);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_vps_get_client_unpaid_invoices

This Function Applies to the VPS services. * This function returns a list of all the unpaid invoices matching the module * passed..

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call

Output Fields

Field Type Description
invoices_id int ID of the Invoice used for referencing
invoices_description string Description of what the Invoice was for
invoices_amount float Cost of the Invoice
invoices_custid int ID of the Customer this Invoice is for
invoices_type int The Type of Invoice (1 = charge, 10+ are payment types)
invoices_date string Date the Invoice was Created
invoices_group int Billing Group the Invoice falls under, Not currently used
invoices_extra int If type 1 invoice this points to the repeat invoice id, otherwise points to the id of the charge invoice its a payment for.
invoices_paid int Wether or not the Invoice was paid (if applicable)
invoices_module string Module the Invoice was for. You can use get_modules to get a list of available modules.
invoices_due_date string Date the Invoice is Due
invoices_service int ID of the Service/Order this Invoice is for such as 1000 if the order was vps1000 and the module was vps

VPS Get Server Name

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$id = $ARGV[2];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_vps_get_server_name($sid, $id);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_vps_get_server_name()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_vps_get_server_name, message: { 
    sid: ARGV[0], 
    id: ARGV[1], 
})
print response.body[:api_vps_get_server_name_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$id = $_SERVER['argv'][3];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_vps_get_server_name($sid, $id);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_vps_get_server_name

Get the name of the vps master/host server your giving the id for

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
id int id of the vps master

Output Fields

Field Type Description
return string vps masters name

VPS Get Service

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$id = $ARGV[2];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_vps_get_service($sid, $id);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_vps_get_service()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_vps_get_service, message: { 
    sid: ARGV[0], 
    id: ARGV[1], 
})
print response.body[:api_vps_get_service_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$id = $_SERVER['argv'][3];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_vps_get_service($sid, $id);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_vps_get_service

This Function Applies to the VPS services. * Gets service info for the given ID in the given Module. An example of this * would be in the "vps" module have order id

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
id int

Output Fields

Field Type Description
vps_id int VPS Service ID
vps_server int VPS Host Server ID
vps_vzid string VPS Host-Side Server ID
vps_type int Package ID
vps_cost float Service Cost
vps_custid int Customer ID
vps_ip string IP Address of VPS
vps_status string Billing Status
vps_invoice int Invoice ID
vps_coupon int Coupon ID
vps_extra string Additional VPS information
vps_hostname string Hostname of the VPS
vps_server_status string Server Status of VPS
vps_comment string Comments about the VPS

Example API Response

Field Value
vps_id 10000
vps_server 5
vps_vzid 10000
vps_type 32
vps_cost 22
vps_custid 11803
vps_ip 206.72.197.216
vps_status canceled
vps_invoice 1011318
vps_coupon 3507
vps_extra
vps_hostname windows10000
vps_server_status
vps_comment

VPS Get Services

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_vps_get_services($sid);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_vps_get_services()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_vps_get_services, message: { 
    sid: ARGV[0], 
})
print response.body[:api_vps_get_services_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_vps_get_services($sid);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_vps_get_services

This Function Applies to the VPS services. * Gets List of Services

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call

Output Fields

Field Type Description
vps_id int VPS Service ID
vps_server int VPS Host Server ID
vps_vzid string VPS Host-Side Server ID
vps_type int Package ID
vps_cost float Service Cost
vps_custid int Customer ID
vps_ip string IP Address of VPS
vps_status string Billing Status
vps_invoice int Invoice ID
vps_coupon int Coupon ID
vps_extra string Additional VPS information
vps_hostname string Hostname of the VPS
vps_server_status string Server Status of VPS
vps_comment string Comments about the VPS

VPS Queue Restart

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$id = $ARGV[2];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_vps_queue_restart($sid, $id);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_vps_queue_restart()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_vps_queue_restart, message: { 
    sid: ARGV[0], 
    id: ARGV[1], 
})
print response.body[:api_vps_queue_restart_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$id = $_SERVER['argv'][3];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_vps_queue_restart($sid, $id);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_vps_queue_restart

restart a vps

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
id int defaults to false, if specified tries using that id instead of the one passed

Output Fields

Field Type Description
status string Location Status
status_text string

Example API Response

Field Value
status error
status_text You cannot send commands to the server until it is active

VPS Queue Start

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$id = $ARGV[2];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_vps_queue_start($sid, $id);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_vps_queue_start()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_vps_queue_start, message: { 
    sid: ARGV[0], 
    id: ARGV[1], 
})
print response.body[:api_vps_queue_start_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$id = $_SERVER['argv'][3];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_vps_queue_start($sid, $id);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_vps_queue_start

start a vps

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
id int defaults to false, if specified tries using that id instead of the one passed

Output Fields

Field Type Description
status string Location Status
status_text string

Example API Response

Field Value
status error
status_text You cannot send commands to the server until it is active

VPS Queue Stop

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$id = $ARGV[2];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_vps_queue_stop($sid, $id);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_vps_queue_stop()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_vps_queue_stop, message: { 
    sid: ARGV[0], 
    id: ARGV[1], 
})
print response.body[:api_vps_queue_stop_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$id = $_SERVER['argv'][3];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_vps_queue_stop($sid, $id);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_vps_queue_stop

stops a vps

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
id int defaults to false, if specified tries using that id instead of the one passed

Output Fields

Field Type Description
status string Location Status
status_text string

Example API Response

Field Value
status error
status_text You cannot send commands to the server until it is active

VPS Screenshot

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$id = $ARGV[2];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_vps_screenshot($sid, $id);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_vps_screenshot()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_vps_screenshot, message: { 
    sid: ARGV[0], 
    id: ARGV[1], 
})
print response.body[:api_vps_screenshot_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$id = $_SERVER['argv'][3];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_vps_screenshot($sid, $id);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_vps_screenshot

This command returns a link to an animated screenshot of your VPS. Only works * currently with KVM VPS servers

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
id int false to link to the image itself , otherwise a url

Output Fields

Field Type Description
status string Location Status
status_text string
url string
link string
js string

Example API Response

Field Value
status error
status_text Your VPS has no screenshots currently.
url
link
js

Get VPS Locations Array

a#!/usr/bin/perl -w
use SOAP::Lite;

$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$res = $client
  -> get_vps_locations_array();
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
result = client.service.get_vps_locations_array()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(:get_vps_locations_array)
print response.body[:get_vps_locations_array_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $res = $client->get_vps_locations_array();
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: get_vps_locations_array

Use this function to get a list of the Locations available for ordering. The id * field in the return value is also needed to pass to the buy_vps functions.

Input

This function takes no input parameters

Output Fields

Field Type Description
id int ID of the Coupon
name string Country Name in all Capitols

Example API Response

Id Name
1 Secaucus, NJ
2 Los Angeles, CA

Get VPS Platforms Array

a#!/usr/bin/perl -w
use SOAP::Lite;

$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$res = $client
  -> get_vps_platforms_array();
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
result = client.service.get_vps_platforms_array()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(:get_vps_platforms_array)
print response.body[:get_vps_platforms_array_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $res = $client->get_vps_platforms_array();
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: get_vps_platforms_array

Use this function to get a list of the various platforms available for ordering. * The platform field in the return value is also needed to pass to the buy_vps * functions.

Input

This function takes no input parameters

Output Fields

Field Type Description
platform string
name string Country Name in all Capitols

Example API Response

Platform Name
openvz OpenVZ
kvm KVM
cloudkvm Cloud

Get VPS Slice Types

a#!/usr/bin/perl -w
use SOAP::Lite;

$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$res = $client
  -> get_vps_slice_types();
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
result = client.service.get_vps_slice_types()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(:get_vps_slice_types)
print response.body[:get_vps_slice_types_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $res = $client->get_vps_slice_types();
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: get_vps_slice_types

We have several types of Servers available for use with VPS Hosting. You can get * a list of the types available and there cost per slice/unit by making a call to * this function

Input

This function takes no input parameters

Output Fields

Field Type Description
name string Country Name in all Capitols
type int Coupon Type, 1: Percentage Off 2: Fixed Amount Off 3: Specified Sale Price
cost float
buyable int

Example API Response

Name Type Cost Buyable
OpenVZ VPS Slice 6 6 1
KVM Windows VPS Slice 1 10 1
KVM Linux VPS Slice 2 8 1
Cloud KVM Windows VPS Slice 3 22 1
Cloud KVM Linux VPS Slice 4 20 1
SSD OpenVZ VPS Slice 5 9 1
LXC VPS Slice 9 6 0
Xen Windows VPS Slice 7 6 0
Xen Linux VPS Slice 8 6 0
VMware VPS Slice 10 10 0
Hyper-V VPS Slice 11 10 1
Virtuozzo VPS Slice 12 6 1
SSD Virtuozzo VPS Slice 13 9 1

Get VPS Templates

a#!/usr/bin/perl -w
use SOAP::Lite;

$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$res = $client
  -> get_vps_templates();
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
result = client.service.get_vps_templates()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(:get_vps_templates)
print response.body[:get_vps_templates_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $res = $client->get_vps_templates();
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: get_vps_templates

Get the currently available VPS templates for each server type.

Input

This function takes no input parameters

Output Fields

Field Type Description
type int Coupon Type, 1: Percentage Off 2: Fixed Amount Off 3: Specified Sale Price
virtulization string
bits int
os string
version string
file string
title string

Example API Response

Type Virtulization Bits Os Version File Title
1 KVM Windows 64 windows 2016 windowsr2 Windows 2016 64bit
1 KVM Windows 64 windows 2012 windows2012 Windows 2012 64bit
2 KVM Linux 64 centos 7 centos55 CentOS 7 64bit
2 KVM Linux 64 centos 6 centos5 CentOS 6 64bit
2 KVM Linux 64 debian 7 debian6 Debian 7 64bit
2 KVM Linux 64 freepbx 6.6 freepbx FreePBX 6.6 64bit
2 KVM Linux 64 ubuntu 16.04 ubuntu12 Ubuntu 16.04 64bit
2 KVM Linux 64 ubuntu 14.04 ubuntu10 Ubuntu 14.04 64bit
2 KVM Linux 64 ubuntu 14.04 Desktop ubuntudesktop Ubuntu 14.04 Desktop 64bit
2 KVM Linux 64 ubuntu 10.04 ubuntu10 Ubuntu 10.04 64bit
5 SSD OpenVZ 64 centos 7 minimal centos-7-x86_64-minimal.tar.gz CentOS 7 minimal 64bit
5 SSD OpenVZ 64 centos 7 centos-7-x86_64.tar.gz CentOS 7 64bit
5 SSD OpenVZ 64 centos 6 minimal centos-6-x86_64-minimal.tar.gz CentOS 6 minimal 64bit
5 SSD OpenVZ 64 centos 6 centos-6-x86_64.tar.gz CentOS 6 64bit
5 SSD OpenVZ 64 centos 6 devel centos-6-x86_64-devel.tar.gz CentOS 6 devel 64bit
5 SSD OpenVZ 32 centos 6 devel centos-6-x86-devel.tar.gz CentOS 6 devel 32bit
5 SSD OpenVZ 32 centos 6 minimal centos-6-x86-minimal.tar.gz CentOS 6 minimal 32bit
5 SSD OpenVZ 32 centos 6 centos-6-x86.tar.gz CentOS 6 32bit
5 SSD OpenVZ 64 centos 5 centos-5-x86_64.tar.gz CentOS 5 64bit
5 SSD OpenVZ 64 centos 5 devel centos-5-x86_64-devel.tar.gz CentOS 5 devel 64bit
5 SSD OpenVZ 32 centos 5 centos-5-x86.tar.gz CentOS 5 32bit
5 SSD OpenVZ 32 centos 5 devel centos-5-x86-devel.tar.gz CentOS 5 devel 32bit
5 SSD OpenVZ 64 centos 7 nginxwordpress centos-7-x86_64-nginxwordpress.tar.gz CentOS 7 nginxwordpress 64bit (http:mirror.trouble-free.netmyadminopenvz)
5 SSD OpenVZ 64 centos 7 cpanel centos-7-x86_64-cpanel.tar.gz CentOS 7 cpanel 64bit (http:mirror.trouble-free.netmyadminopenvz)
5 SSD OpenVZ 64 centos 7 breadbasket centos-7-x86_64-breadbasket.tar.gz CentOS 7 breadbasket 64bit (http:mirror.trouble-free.netmyadminopenvz)
5 SSD OpenVZ 64 centos 6 webuzo centos-6-x86_64-webuzo.tar.gz CentOS 6 webuzo 64bit (http:mirror.trouble-free.netmyadminopenvz)
5 SSD OpenVZ 64 centos 6 breadbasket centos-6-x86_64-breadbasket.tar.gz CentOS 6 breadbasket 64bit (http:mirror.trouble-free.netmyadminopenvz)
5 SSD OpenVZ 64 debian 8.0 minimal debian-8.0-x86_64-minimal.tar.gz Debian 8.0 minimal 64bit
5 SSD OpenVZ 64 debian 8.0 debian-8.0-x86_64.tar.gz Debian 8.0 64bit
5 SSD OpenVZ 64 debian 7.0 minimal debian-7.0-x86_64-minimal.tar.gz Debian 7.0 minimal 64bit
5 SSD OpenVZ 64 debian 7.0 debian-7.0-x86_64.tar.gz Debian 7.0 64bit
5 SSD OpenVZ 32 debian 7.0 debian-7.0-x86.tar.gz Debian 7.0 32bit
5 SSD OpenVZ 32 debian 7.0 minimal debian-7.0-x86-minimal.tar.gz Debian 7.0 minimal 32bit
5 SSD OpenVZ 64 fedora 23 fedora-23-x86_64.tar.gz Fedora 23 64bit
5 SSD OpenVZ 64 fedora 22 fedora-22-x86_64.tar.gz Fedora 22 64bit
5 SSD OpenVZ 64 fedora 21 fedora-21-x86_64.tar.gz Fedora 21 64bit
5 SSD OpenVZ 64 fedora 20 fedora-20-x86_64.tar.gz Fedora 20 64bit
5 SSD OpenVZ 32 fedora 20 fedora-20-x86.tar.gz Fedora 20 32bit
5 SSD OpenVZ 64 scientific 6 scientific-6-x86_64.tar.gz Scientific 6 64bit
5 SSD OpenVZ 32 scientific 6 scientific-6-x86.tar.gz Scientific 6 32bit
5 SSD OpenVZ 64 suse 13.2 suse-13.2-x86_64.tar.gz SuSe 13.2 64bit
5 SSD OpenVZ 64 suse 13.1 minimal suse-13.1-x86_64-minimal.tar.gz SuSe 13.1 minimal 64bit
5 SSD OpenVZ 64 suse 13.1 suse-13.1-x86_64.tar.gz SuSe 13.1 64bit
5 SSD OpenVZ 32 suse 13.1 minimal suse-13.1-x86-minimal.tar.gz SuSe 13.1 minimal 32bit
5 SSD OpenVZ 32 suse 13.1 suse-13.1-x86.tar.gz SuSe 13.1 32bit
5 SSD OpenVZ 64 ubuntu 16.04 ubuntu-16.04-x86_64.tar.gz Ubuntu 16.04 64bit
5 SSD OpenVZ 64 ubuntu 15.04 minimal ubuntu-15.04-x86_64-minimal.tar.gz Ubuntu 15.04 minimal 64bit
5 SSD OpenVZ 64 ubuntu 15.04 ubuntu-15.04-x86_64.tar.gz Ubuntu 15.04 64bit
5 SSD OpenVZ 64 ubuntu 14.04 minimal ubuntu-14.04-x86_64-minimal.tar.gz Ubuntu 14.04 minimal 64bit
5 SSD OpenVZ 64 ubuntu 14.04 ubuntu-14.04-x86_64.tar.gz Ubuntu 14.04 64bit
5 SSD OpenVZ 32 ubuntu 14.04 ubuntu-14.04-x86.tar.gz Ubuntu 14.04 32bit
5 SSD OpenVZ 32 ubuntu 14.04 minimal ubuntu-14.04-x86-minimal.tar.gz Ubuntu 14.04 minimal 32bit
5 SSD OpenVZ 64 ubuntu 12.04 minimal ubuntu-12.04-x86_64-minimal.tar.gz Ubuntu 12.04 minimal 64bit
5 SSD OpenVZ 64 ubuntu 12.04 ubuntu-12.04-x86_64.tar.gz Ubuntu 12.04 64bit
5 SSD OpenVZ 32 ubuntu 12.04 minimal ubuntu-12.04-x86-minimal.tar.gz Ubuntu 12.04 minimal 32bit
5 SSD OpenVZ 32 ubuntu 12.04 ubuntu-12.04-x86.tar.gz Ubuntu 12.04 32bit
5 SSD OpenVZ 64 ubuntu 15.10 minimal ubuntu-15.10-x86_64-minimal.tar.gz Ubuntu 15.10 minimal 64bit (beta)
5 SSD OpenVZ 64 ubuntu 15.10 ubuntu-15.10-x86_64.tar.gz Ubuntu 15.10 64bit (beta)
5 SSD OpenVZ 64 ubuntu 15.04 xrdp ubuntu-15.04-x86_64-xrdp.tar.gz Ubuntu 15.04 xrdp 64bit (http:mirror.trouble-free.netmyadminopenvz)
6 OpenVZ 64 centos 7 minimal centos-7-x86_64-minimal.tar.gz CentOS 7 minimal 64bit
6 OpenVZ 64 centos 7 centos-7-x86_64.tar.gz CentOS 7 64bit
6 OpenVZ 64 centos 6 minimal centos-6-x86_64-minimal.tar.gz CentOS 6 minimal 64bit
6 OpenVZ 64 centos 6 centos-6-x86_64.tar.gz CentOS 6 64bit
6 OpenVZ 64 centos 6 devel centos-6-x86_64-devel.tar.gz CentOS 6 devel 64bit
6 OpenVZ 32 centos 6 devel centos-6-x86-devel.tar.gz CentOS 6 devel 32bit
6 OpenVZ 32 centos 6 minimal centos-6-x86-minimal.tar.gz CentOS 6 minimal 32bit
6 OpenVZ 32 centos 6 centos-6-x86.tar.gz CentOS 6 32bit
6 OpenVZ 64 centos 5 centos-5-x86_64.tar.gz CentOS 5 64bit
6 OpenVZ 64 centos 5 devel centos-5-x86_64-devel.tar.gz CentOS 5 devel 64bit
6 OpenVZ 32 centos 5 centos-5-x86.tar.gz CentOS 5 32bit
6 OpenVZ 32 centos 5 devel centos-5-x86-devel.tar.gz CentOS 5 devel 32bit
6 OpenVZ 64 centos 7 nginxwordpress centos-7-x86_64-nginxwordpress.tar.gz CentOS 7 nginxwordpress 64bit (http:mirror.trouble-free.netmyadminopenvz)
6 OpenVZ 64 centos 7 cpanel centos-7-x86_64-cpanel.tar.gz CentOS 7 cpanel 64bit (http:mirror.trouble-free.netmyadminopenvz)
6 OpenVZ 64 centos 7 breadbasket centos-7-x86_64-breadbasket.tar.gz CentOS 7 breadbasket 64bit (http:mirror.trouble-free.netmyadminopenvz)
6 OpenVZ 64 centos 6 webuzo centos-6-x86_64-webuzo.tar.gz CentOS 6 webuzo 64bit (http:mirror.trouble-free.netmyadminopenvz)
6 OpenVZ 64 centos 6 breadbasket centos-6-x86_64-breadbasket.tar.gz CentOS 6 breadbasket 64bit (http:mirror.trouble-free.netmyadminopenvz)
6 OpenVZ 64 debian 8.0 minimal debian-8.0-x86_64-minimal.tar.gz Debian 8.0 minimal 64bit
6 OpenVZ 64 debian 8.0 debian-8.0-x86_64.tar.gz Debian 8.0 64bit
6 OpenVZ 64 debian 7.0 minimal debian-7.0-x86_64-minimal.tar.gz Debian 7.0 minimal 64bit
6 OpenVZ 64 debian 7.0 debian-7.0-x86_64.tar.gz Debian 7.0 64bit
6 OpenVZ 32 debian 7.0 debian-7.0-x86.tar.gz Debian 7.0 32bit
6 OpenVZ 32 debian 7.0 minimal debian-7.0-x86-minimal.tar.gz Debian 7.0 minimal 32bit
6 OpenVZ 64 fedora 23 fedora-23-x86_64.tar.gz Fedora 23 64bit
6 OpenVZ 64 fedora 22 fedora-22-x86_64.tar.gz Fedora 22 64bit
6 OpenVZ 64 fedora 21 fedora-21-x86_64.tar.gz Fedora 21 64bit
6 OpenVZ 64 fedora 20 fedora-20-x86_64.tar.gz Fedora 20 64bit
6 OpenVZ 32 fedora 20 fedora-20-x86.tar.gz Fedora 20 32bit
6 OpenVZ 64 scientific 6 scientific-6-x86_64.tar.gz Scientific 6 64bit
6 OpenVZ 32 scientific 6 scientific-6-x86.tar.gz Scientific 6 32bit
6 OpenVZ 64 suse 13.2 suse-13.2-x86_64.tar.gz SuSe 13.2 64bit
6 OpenVZ 64 suse 13.1 minimal suse-13.1-x86_64-minimal.tar.gz SuSe 13.1 minimal 64bit
6 OpenVZ 64 suse 13.1 suse-13.1-x86_64.tar.gz SuSe 13.1 64bit
6 OpenVZ 32 suse 13.1 minimal suse-13.1-x86-minimal.tar.gz SuSe 13.1 minimal 32bit
6 OpenVZ 32 suse 13.1 suse-13.1-x86.tar.gz SuSe 13.1 32bit
6 OpenVZ 64 ubuntu 16.04 ubuntu-16.04-x86_64.tar.gz Ubuntu 16.04 64bit
6 OpenVZ 64 ubuntu 15.04 minimal ubuntu-15.04-x86_64-minimal.tar.gz Ubuntu 15.04 minimal 64bit
6 OpenVZ 64 ubuntu 15.04 ubuntu-15.04-x86_64.tar.gz Ubuntu 15.04 64bit
6 OpenVZ 64 ubuntu 14.04 minimal ubuntu-14.04-x86_64-minimal.tar.gz Ubuntu 14.04 minimal 64bit
6 OpenVZ 64 ubuntu 14.04 ubuntu-14.04-x86_64.tar.gz Ubuntu 14.04 64bit
6 OpenVZ 32 ubuntu 14.04 ubuntu-14.04-x86.tar.gz Ubuntu 14.04 32bit
6 OpenVZ 32 ubuntu 14.04 minimal ubuntu-14.04-x86-minimal.tar.gz Ubuntu 14.04 minimal 32bit
6 OpenVZ 64 ubuntu 12.04 minimal ubuntu-12.04-x86_64-minimal.tar.gz Ubuntu 12.04 minimal 64bit
6 OpenVZ 64 ubuntu 12.04 ubuntu-12.04-x86_64.tar.gz Ubuntu 12.04 64bit
6 OpenVZ 32 ubuntu 12.04 minimal ubuntu-12.04-x86-minimal.tar.gz Ubuntu 12.04 minimal 32bit
6 OpenVZ 32 ubuntu 12.04 ubuntu-12.04-x86.tar.gz Ubuntu 12.04 32bit
6 OpenVZ 64 ubuntu 15.10 minimal ubuntu-15.10-x86_64-minimal.tar.gz Ubuntu 15.10 minimal 64bit (beta)
6 OpenVZ 64 ubuntu 15.10 ubuntu-15.10-x86_64.tar.gz Ubuntu 15.10 64bit (beta)
6 OpenVZ 64 ubuntu 15.04 xrdp ubuntu-15.04-x86_64-xrdp.tar.gz Ubuntu 15.04 xrdp 64bit (http:mirror.trouble-free.netmyadminopenvz)
9 LXC 64 alpine 3.8 alpine/3.8/amd64 Alpine 3.8 64bit
9 LXC 32 alpine 3.8 alpine/3.8/i386 Alpine 3.8 32bit
9 LXC 64 alpine 3.7 alpine/3.7/amd64 Alpine 3.7 64bit
9 LXC 32 alpine 3.7 alpine/3.7/i386 Alpine 3.7 32bit
9 LXC 64 alpine 3.6 alpine/3.6/amd64 Alpine 3.6 64bit
9 LXC 32 alpine 3.6 alpine/3.6/i386 Alpine 3.6 32bit
9 LXC 64 alpine 3.5 alpine/3.5/amd64 Alpine 3.5 64bit
9 LXC 32 alpine 3.5 alpine/3.5/i386 Alpine 3.5 32bit
9 LXC 64 alpine 3.4 alpine/3.4/amd64 Alpine 3.4 64bit
9 LXC 32 alpine 3.4 alpine/3.4/i386 Alpine 3.4 32bit
9 LXC 64 alpine edge alpine/edge/amd64 Alpine edge 64bit
9 LXC 32 alpine edge alpine/edge/i386 Alpine edge 32bit
9 LXC 64 archlinux current archlinux/current/amd64 Archlinux current 64bit
9 LXC 64 centos 7 centos/7/amd64 Centos 7 64bit
9 LXC 64 centos 6 centos/6/amd64 Centos 6 64bit
9 LXC 32 centos 6 centos/6/i386 Centos 6 32bit
9 LXC 64 debian buster debian/10/amd64 Debian buster 64bit
9 LXC 64 debian jessie debian/8/amd64 Debian jessie 64bit
9 LXC 64 debian sid debian/sid/amd64 Debian sid 64bit
9 LXC 64 debian stretch debian/9/amd64 Debian stretch 64bit
9 LXC 64 debian wheezy debian/7/amd64 Debian wheezy 64bit
9 LXC 32 debian buster debian/10/i386 Debian buster 32bit
9 LXC 32 debian jessie debian/8/i386 Debian jessie 32bit
9 LXC 32 debian sid debian/sid/i386 Debian sid 32bit
9 LXC 32 debian stretch debian/9/i386 Debian stretch 32bit
9 LXC 32 debian wheezy debian/7/i386 Debian wheezy 32bit
9 LXC 64 fedora 28 fedora/28/amd64 Fedora 28 64bit
9 LXC 32 fedora 28 fedora/28/i386 Fedora 28 32bit
9 LXC 64 fedora 27 fedora/27/amd64 Fedora 27 64bit
9 LXC 32 fedora 27 fedora/27/i386 Fedora 27 32bit
9 LXC 64 fedora 26 fedora/26/amd64 Fedora 26 64bit
9 LXC 32 fedora 26 fedora/26/i386 Fedora 26 32bit
9 LXC 64 gentoo current gentoo/current/amd64 Gentoo current 64bit
9 LXC 32 gentoo current gentoo/current/i386 Gentoo current 32bit
9 LXC 64 opensuse 42.3 opensuse/42.3/amd64 Opensuse 42.3 64bit
9 LXC 64 opensuse 15.0 opensuse/15.0/amd64 Opensuse 15.0 64bit
9 LXC 64 oracle 7 oracle/7/amd64 Oracle 7 64bit
9 LXC 64 oracle 6 oracle/6/amd64 Oracle 6 64bit
9 LXC 32 oracle 6 oracle/6/i386 Oracle 6 32bit
9 LXC 64 plamo 6.x plamo/6.x/amd64 Plamo 6.x 64bit
9 LXC 32 plamo 6.x plamo/6.x/i386 Plamo 6.x 32bit
9 LXC 64 plamo 5.x plamo/5.x/amd64 Plamo 5.x 64bit
9 LXC 32 plamo 5.x plamo/5.x/i386 Plamo 5.x 32bit
9 LXC 64 sabayon current sabayon/current/amd64 Sabayon current 64bit
9 LXC 64 ubuntu artful ubuntu/17.10/amd64 Ubuntu artful 64bit
9 LXC 64 ubuntu bionic ubuntu/18.04/amd64 Ubuntu bionic 64bit
9 LXC 64 ubuntu cosmic ubuntu/18.10/amd64 Ubuntu cosmic 64bit
9 LXC 64 ubuntu trusty ubuntu/14.04/amd64 Ubuntu trusty 64bit
9 LXC 64 ubuntu xenial ubuntu/16.04/amd64 Ubuntu xenial 64bit
9 LXC 32 ubuntu artful ubuntu/17.10/i386 Ubuntu artful 32bit
9 LXC 32 ubuntu bionic ubuntu/18.04/i386 Ubuntu bionic 32bit
9 LXC 32 ubuntu cosmic ubuntu/18.10/i386 Ubuntu cosmic 32bit
9 LXC 32 ubuntu trusty ubuntu/14.04/i386 Ubuntu trusty 32bit
9 LXC 32 ubuntu xenial ubuntu/16.04/i386 Ubuntu xenial 32bit
9 LXC 64 ubuntu-core 16 ubuntu-core/16/amd64 Ubuntu-Core 16 64bit
9 LXC 32 ubuntu-core 16 ubuntu-core/16/i386 Ubuntu-Core 16 32bit
10 VMware 64 windows 2016 windows2008 Windows 2016 64bit
11 Hyper-V 64 windows 2016 Standard Windows2016Standard Windows 2016 Standard 64bit
11 Hyper-V 64 windows 2012 Standard Windows2012Standard Windows 2012 Standard 64bit
12 Virtuozzo 7 64 centos 7 centos-7-x86_64 CentOS 7 64bit
12 Virtuozzo 7 64 centos 6 centos-6-x86_64 CentOS 6 64bit
12 Virtuozzo 7 64 debian 8.0 debian-8.0-x86_64 Debian 8.0 64bit
12 Virtuozzo 7 64 debian 8.0 minimal debian-8.0-x86_64-minimal Debian 8.0 minimal 64bit
12 Virtuozzo 7 64 fedora 23 fedora-23-x86_64 Fedora 23 64bit
12 Virtuozzo 7 64 suse 42.2 suse-42.2-x86_64 OpenSuse 42.2 64bit
12 Virtuozzo 7 64 ubuntu 16.10 ubuntu-16.10-x86_64 Ubuntu 16.10 64bit
12 Virtuozzo 7 64 ubuntu 16.04 ubuntu-16.04-x86_64 Ubuntu 16.04 64bit
12 Virtuozzo 7 64 ubuntu 14.04 ubuntu-14.04-x86_64 Ubuntu 14.04 64bit
12 Virtuozzo 7 64 vzlinux 7 vzlinux-7-x86_64 VzLinux 7 64bit
13 SSD Virtuozzo 7 64 centos 7 centos-7-x86_64 CentOS 7 64bit
13 SSD Virtuozzo 7 64 centos 6 centos-6-x86_64 CentOS 6 64bit
13 SSD Virtuozzo 7 64 debian 8.0 debian-8.0-x86_64 Debian 8.0 64bit
13 SSD Virtuozzo 7 64 debian 8.0 minimal debian-8.0-x86_64-minimal Debian 8.0 minimal 64bit
13 SSD Virtuozzo 7 64 fedora 23 fedora-23-x86_64 Fedora 23 64bit
13 SSD Virtuozzo 7 64 suse 42.2 suse-42.2-x86_64 OpenSuse 42.2 64bit
13 SSD Virtuozzo 7 64 ubuntu 16.10 ubuntu-16.10-x86_64 Ubuntu 16.10 64bit
13 SSD Virtuozzo 7 64 ubuntu 16.04 ubuntu-16.04-x86_64 Ubuntu 16.04 64bit
13 SSD Virtuozzo 7 64 ubuntu 14.04 ubuntu-14.04-x86_64 Ubuntu 14.04 64bit
13 SSD Virtuozzo 7 64 vzlinux 7 vzlinux-7-x86_64 VzLinux 7 64bit

Websites

Webhosting Cancel Service

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$id = $ARGV[2];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_webhosting_cancel_service($sid, $id);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_webhosting_cancel_service()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_webhosting_cancel_service, message: { 
    sid: ARGV[0], 
    id: ARGV[1], 
})
print response.body[:api_webhosting_cancel_service_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$id = $_SERVER['argv'][3];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_webhosting_cancel_service($sid, $id);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_webhosting_cancel_service

This Function Applies to the Webhosting services. * Cancels a service for the passed module matching the passed id. Canceling a * service will also cancel any addons for that service at the same time.

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
id int ID / Service ID you wish to cancel

Output Fields

Field Type Description
return bool

Example API Response

Type Value
Boolean

Webhosting Get Client Invoices

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_webhosting_get_client_invoices($sid);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_webhosting_get_client_invoices()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_webhosting_get_client_invoices, message: { 
    sid: ARGV[0], 
})
print response.body[:api_webhosting_get_client_invoices_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_webhosting_get_client_invoices($sid);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_webhosting_get_client_invoices

This Function Applies to the Webhosting services. * Gets a list of all the invoices.

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call

Output Fields

Field Type Description
invoices_id int ID of the Invoice used for referencing
invoices_description string Description of what the Invoice was for
invoices_amount float Cost of the Invoice
invoices_custid int ID of the Customer this Invoice is for
invoices_type int The Type of Invoice (1 = charge, 10+ are payment types)
invoices_date string Date the Invoice was Created
invoices_group int Billing Group the Invoice falls under, Not currently used
invoices_extra int If type 1 invoice this points to the repeat invoice id, otherwise points to the id of the charge invoice its a payment for.
invoices_paid int Wether or not the Invoice was paid (if applicable)
invoices_module string Module the Invoice was for. You can use get_modules to get a list of available modules.
invoices_due_date string Date the Invoice is Due
invoices_service int ID of the Service/Order this Invoice is for such as 1000 if the order was vps1000 and the module was vps

Webhosting Get Client Unpaid Invoices

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_webhosting_get_client_unpaid_invoices($sid);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_webhosting_get_client_unpaid_invoices()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_webhosting_get_client_unpaid_invoices, message: { 
    sid: ARGV[0], 
})
print response.body[:api_webhosting_get_client_unpaid_invoices_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_webhosting_get_client_unpaid_invoices($sid);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_webhosting_get_client_unpaid_invoices

This Function Applies to the Webhosting services. * This function returns a list of all the unpaid invoices matching the module * passed..

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call

Output Fields

Field Type Description
invoices_id int ID of the Invoice used for referencing
invoices_description string Description of what the Invoice was for
invoices_amount float Cost of the Invoice
invoices_custid int ID of the Customer this Invoice is for
invoices_type int The Type of Invoice (1 = charge, 10+ are payment types)
invoices_date string Date the Invoice was Created
invoices_group int Billing Group the Invoice falls under, Not currently used
invoices_extra int If type 1 invoice this points to the repeat invoice id, otherwise points to the id of the charge invoice its a payment for.
invoices_paid int Wether or not the Invoice was paid (if applicable)
invoices_module string Module the Invoice was for. You can use get_modules to get a list of available modules.
invoices_due_date string Date the Invoice is Due
invoices_service int ID of the Service/Order this Invoice is for such as 1000 if the order was vps1000 and the module was vps

Webhosting Get Service

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$id = $ARGV[2];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_webhosting_get_service($sid, $id);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_webhosting_get_service()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_webhosting_get_service, message: { 
    sid: ARGV[0], 
    id: ARGV[1], 
})
print response.body[:api_webhosting_get_service_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$id = $_SERVER['argv'][3];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_webhosting_get_service($sid, $id);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_webhosting_get_service

This Function Applies to the Webhosting services. * Gets service info for the given ID in the given Module. An example of this * would be in the "vps" module have order id

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
id int

Output Fields

Field Type Description
website_id int Server ID
website_server int ID of the host server this website resides on.
website_type int Server Type
website_cost float Service Cost
website_custid int Customer ID
website_ip string IP Address
website_status string Billing Status
website_invoice int Invoice ID
website_coupon int Coupon ID
website_extra string Additional Website Details
website_hostname string Hostname for this website
website_comment string Website Comments
website_username string Username on the host server associated w/ this account
website_server_status string Server-Side status of this website

Webhosting Get Services

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_webhosting_get_services($sid);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_webhosting_get_services()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_webhosting_get_services, message: { 
    sid: ARGV[0], 
})
print response.body[:api_webhosting_get_services_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_webhosting_get_services($sid);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_webhosting_get_services

This Function Applies to the Webhosting services. * Gets List of Services

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call

Output Fields

Field Type Description
website_id int Server ID
website_server int ID of the host server this website resides on.
website_type int Server Type
website_cost float Service Cost
website_custid int Customer ID
website_ip string IP Address
website_status string Billing Status
website_invoice int Invoice ID
website_coupon int Coupon ID
website_extra string Additional Website Details
website_hostname string Hostname for this website
website_comment string Website Comments
website_username string Username on the host server associated w/ this account
website_server_status string Server-Side status of this website

Auto Cpanel Login

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$id = $ARGV[2];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_api_auto_cpanel_login($sid, $id);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_api_auto_cpanel_login()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_api_auto_cpanel_login, message: { 
    sid: ARGV[0], 
    id: ARGV[1], 
})
print response.body[:api_api_auto_cpanel_login_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$id = $_SERVER['argv'][3];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_api_auto_cpanel_login($sid, $id);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_api_auto_cpanel_login

Logs into cpanel for the given website id and returns a unique logged-in url. * The status will be "ok" if successful, or "error" if there was any problems * status_text will contain a description of the problem if any.

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
id int id of website

Output Fields

Field Type Description
status string Location Status
status_text string

Example API Response

Field Value
status error
status_text Invalid Website Passed

Licenses

Buy License

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$ip = $ARGV[2];
$type = $ARGV[3];
$coupon = $ARGV[4];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_buy_license($sid, $ip, $type, $coupon);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_buy_license()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_buy_license, message: { 
    sid: ARGV[0], 
    ip: ARGV[1], 
    type: ARGV[2], 
    coupon: ARGV[3], 
})
print response.body[:api_buy_license_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$ip = $_SERVER['argv'][3];
$type = $_SERVER['argv'][4];
$coupon = $_SERVER['argv'][5];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_buy_license($sid, $ip, $type, $coupon);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_buy_license

Purchase a License. Returns an invoice ID.

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
ip string ip address you wish to license some software on
type int the package id of the license type you want. use get_license_types to get a list of possible types.
coupon string an optional coupon

Output Fields

Field Type Description
status string Location Status
status_text string
invoice int
cost float

Example API Response

Field Value
status error
status_text That IP is already licensed in our system That IP is already licensed in our system
invoice
cost 34.95

Buy License Prepay

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$ip = $ARGV[2];
$type = $ARGV[3];
$coupon = $ARGV[4];
$use_prepay = $ARGV[5];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_buy_license_prepay($sid, $ip, $type, $coupon, $use_prepay);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_buy_license_prepay()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_buy_license_prepay, message: { 
    sid: ARGV[0], 
    ip: ARGV[1], 
    type: ARGV[2], 
    coupon: ARGV[3], 
    use_prepay: ARGV[4], 
})
print response.body[:api_buy_license_prepay_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$ip = $_SERVER['argv'][3];
$type = $_SERVER['argv'][4];
$coupon = $_SERVER['argv'][5];
$use_prepay = $_SERVER['argv'][6];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_buy_license_prepay($sid, $ip, $type, $coupon, $use_prepay);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_buy_license_prepay

Purchase a License and optionally uses PrePay. Will return an error if * use_prepay is true not enough PrePay funds are available.

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
ip string ip address you wish to license some software on
type int the package id of the license type you want. use get_license_types to get a list of possible types.
coupon string an optional coupon
use_prepay bool optional, whether or not to use a prepay, if specified as true will return an error if not enough prepay

Output Fields

Field Type Description
status string Location Status
status_text string
invoice int
cost float

Cancel License

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$id = $ARGV[2];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_cancel_license($sid, $id);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_cancel_license()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_cancel_license, message: { 
    sid: ARGV[0], 
    id: ARGV[1], 
})
print response.body[:api_cancel_license_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$id = $_SERVER['argv'][3];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_cancel_license($sid, $id);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_cancel_license

Cancel a License.

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
id int License Order ID

Output Fields

Field Type Description
status string Location Status
status_text string

Example API Response

Field Value
status error
status_text Invalid License ID

Cancel License Ip

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$ip = $ARGV[2];
$type = $ARGV[3];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_cancel_license_ip($sid, $ip, $type);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_cancel_license_ip()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_cancel_license_ip, message: { 
    sid: ARGV[0], 
    ip: ARGV[1], 
    type: ARGV[2], 
})
print response.body[:api_cancel_license_ip_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$ip = $_SERVER['argv'][3];
$type = $_SERVER['argv'][4];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_cancel_license_ip($sid, $ip, $type);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_cancel_license_ip

Cancel a License by IP and Type.

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
ip string IP Address to cancel
type int Package ID. use get_license_types to get a list of possible types.

Output Fields

Field Type Description
status string Location Status
status_text string

Example API Response

Field Value
status error
status_text Invalid License IP/Type

Change License Ip

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$oldip = $ARGV[2];
$newip = $ARGV[3];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_change_license_ip($sid, $oldip, $newip);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_change_license_ip()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_change_license_ip, message: { 
    sid: ARGV[0], 
    oldip: ARGV[1], 
    newip: ARGV[2], 
})
print response.body[:api_change_license_ip_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$oldip = $_SERVER['argv'][3];
$newip = $_SERVER['argv'][4];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_change_license_ip($sid, $oldip, $newip);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_change_license_ip

Change the IP on an active license.

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
oldip string the old ip address
newip string the new ip address

Output Fields

Field Type Description
status string Location Status
status_text string

Example API Response

Field Value
status error
status_text This License either does not exist or it is not owned by you.

Change License Ip By Id

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$id = $ARGV[2];
$newip = $ARGV[3];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_change_license_ip_by_id($sid, $id, $newip);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_change_license_ip_by_id()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_change_license_ip_by_id, message: { 
    sid: ARGV[0], 
    id: ARGV[1], 
    newip: ARGV[2], 
})
print response.body[:api_change_license_ip_by_id_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$id = $_SERVER['argv'][3];
$newip = $_SERVER['argv'][4];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_change_license_ip_by_id($sid, $id, $newip);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_change_license_ip_by_id

Change the IP on an active license.

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
id int the old ip address
newip string the new ip address

Output Fields

Field Type Description
status string Location Status
status_text string

Example API Response

Field Value
status error
status_text This License either does not exist or it is not owned by you.

Get License Types

a#!/usr/bin/perl -w
use SOAP::Lite;

$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$res = $client
  -> api_get_license_types();
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
result = client.service.api_get_license_types()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(:api_get_license_types)
print response.body[:api_get_license_types_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $res = $client->api_get_license_types();
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_get_license_types

Get a license of the various license types.

Input

This function takes no input parameters

Output Fields

Field Type Description
0 tns:license_type[]

Example API Response

Services Id Services Name Services Cost
5000 INTERSERVER-EXTERNAL 34.95
5001 INTERSERVER-EXTERNAL-VPS 15.95
5002 INTERSERVER-EXTERNAL-VZZO 15.95
5005 INTERSERVER-ENKOMP-EXTERNAL-A500 55
5006 Softaculous 3
5007 Softaculous VPS 2
5008 INTERSERVER-INTERNAL 25
5009 INTERSERVER-INTERNAL-VZZO 15
5014 INTERSERVER-INTERNAL-VPS 15
5017 Parallels Plesk v10+/v11+ for VZ 10 Domains (Inside DataCenter) 8
5018 Parallels Plesk v10+/v11+ 10 Domains (Inside DataCenter) 16
5019 Parallels Plesk v10+/v11+ Unlimited Domains (Inside DataCenter) 40
5020 Parallels Plesk v10+/v11+ for VZ 10 Domains (Outside DataCenter) 12
5021 Parallels Plesk v10+/v11+ 10 Domains (Outside DataCenter) 20
5022 Parallels Plesk v10+/v11+ Unlimited Domains (Outside DataCenter) 50
5023 Parallels Plesk v10+/v11+ for VZ Unlimited Domains (Inside DataCenter) 15
5024 Parallels Plesk v10+/v11+ for VZ Unlimited Domains (Outside DataCenter) 15
5025 LiteSpeed WebServer VPS License 13.95
5026 LiteSpeed WebServer Ultra-VPS License 19
5027 LiteSpeed WebServer 1-CPU License 30
5028 LiteSpeed WebServer 2-CPU License 46
5029 LiteSpeed WebServer 4-CPU License 65
5030 LiteSpeed WebServer 8-CPU License 92
5031 LiteSpeed Load Balancer 65
5032 CloudLinux License 10
5033 CloudLinux Type2 License 11.95
5034 KernelCare License 2.95
5035 Parallels Plesk v10+/v11+ for Windows Unlimited Domains (Inside DataCenter) 40
5036 Parallels Plesk v10+/v11+ for Windows Unlimited Domains (Outside DataCenter) 50
5037 Parallels Plesk v10+/v11+ for Windows for VZ Unlimited Domains (Inside DataCenter) 15
5038 Parallels Plesk v10+/v11+ for Windows for VZ Unlimited Domains (Outside DataCenter) 15
5039 Parallels Plesk v10+/v11+ for VPS Unlimited Domains (Inside DataCenter) 15
5040 Parallels Plesk v10+/v11+ for VPS Unlimited Domains (Outside DataCenter) 15
5041 Parallels Plesk v10+/v11+ for Windows for VPS Unlimited Domains (Inside DataCenter) 15
5042 Parallels Plesk v10+/v11+ for Windows for VPS Unlimited Domains (Outside DataCenter) 15
5043 Parallels Plesk v10+/v11+ for VPS 100 Domains (Inside DataCenter) 5
5044 Parallels Plesk v10+/v11+ for VPS 100 Domains (Outside DataCenter) 5
5045 Parallels Plesk v10+/v11+ for Windows 100 Domains (Inside DaCenter) 5
5046 Parallels Plesk v10+/v11+ for Windows 100 Domains (Outside DataCenter) 5
5047 Parallels Plesk v10+/v11+ 100 Domains (Inside DataCenter) 5
5048 Parallels Plesk v10+/v11+ 100 Domains (Outside DataCenter) 5
5049 Parallels Plesk v10+/v11+ for VZ 100 Domains (Inside DataCenter) 4
5050 Parallels Plesk v10+/v11+ for VZ 100 Domains (Outside DataCenter) 4
5051 Parallels Plesk v10+/v11+ for VZ 100 Domains (Inside DataCenter) 4
5052 Parallels Plesk v10+/v11+ for VZ 100 Domains (Outside DataCenter) 4
5053 Plesk v12 Web Admin Edition for Virtual Machines 9
5054 Plesk v12 Web Admin Edition for Dedicated Servers 9
5057 Plesk v12 Web Pro Edition for Virtual Machines 10
5058 Plesk v12 Web Pro Edition for Dedicated Servers 15
5059 Plesk v12 Web Host Edition for Virtual Machines 15
5060 Plesk v12 Web Host Edition for Dedicated Servers 35
5061 Plesk v12 Web ProEdition with CloudLinux for Virtual Machines 20
5062 Plesk v12 Web ProEdition with CloudLinux for Dedicated Servers 25
5063 Plesk v12 Web HostEdition with CloudLinux for Virtual Machines 25
5064 Plesk v12 Web HostEdition with CloudLinux for Dedicated Servers 45
5066 DirectAdmin for CentOS 5 64-bit 8
5067 DirectAdmin for CentOS 6 32-bit 8
5068 DirectAdmin for CentOS 6 64-bit 8
5069 DirectAdmin for CentOS 7 64-bit 8
5070 DirectAdmin for FreeBSD 8.x 64-bit 8
5071 DirectAdmin for FreeBSD 9.x 32-bit 8
5072 DirectAdmin for FreeBSD 9.x 64-bit 8
5073 DirectAdmin for Debian 6.0 32-bit 8
5074 DirectAdmin for Debian 6.0 64-bit 8
5075 DirectAdmin for Debian 7.0 32-bit 8
5076 DirectAdmin for Debian 7.0 64-bit 8
5077 DirectAdmin for Debian 8.0 64-bit 8
5078 DirectAdmin for Debian 5.0 32-bit 8
5079 DirectAdmin for Debian 5.0 64-bit 8
5080 DirectAdmin for CentOS 5 32-bit 8
10613 Webuzo 0
10614 Webuzo VPS 0

Licenses Cancel Service

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$id = $ARGV[2];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_licenses_cancel_service($sid, $id);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_licenses_cancel_service()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_licenses_cancel_service, message: { 
    sid: ARGV[0], 
    id: ARGV[1], 
})
print response.body[:api_licenses_cancel_service_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$id = $_SERVER['argv'][3];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_licenses_cancel_service($sid, $id);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_licenses_cancel_service

This Function Applies to the Licensing services. * Cancels a service for the passed module matching the passed id. Canceling a * service will also cancel any addons for that service at the same time.

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
id int ID / Service ID you wish to cancel

Output Fields

Field Type Description
return bool

Example API Response

Type Value
Boolean

Licenses Get Client Invoices

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_licenses_get_client_invoices($sid);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_licenses_get_client_invoices()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_licenses_get_client_invoices, message: { 
    sid: ARGV[0], 
})
print response.body[:api_licenses_get_client_invoices_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_licenses_get_client_invoices($sid);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_licenses_get_client_invoices

This Function Applies to the Licensing services. * Gets a list of all the invoices.

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call

Output Fields

Field Type Description
invoices_id int ID of the Invoice used for referencing
invoices_description string Description of what the Invoice was for
invoices_amount float Cost of the Invoice
invoices_custid int ID of the Customer this Invoice is for
invoices_type int The Type of Invoice (1 = charge, 10+ are payment types)
invoices_date string Date the Invoice was Created
invoices_group int Billing Group the Invoice falls under, Not currently used
invoices_extra int If type 1 invoice this points to the repeat invoice id, otherwise points to the id of the charge invoice its a payment for.
invoices_paid int Wether or not the Invoice was paid (if applicable)
invoices_module string Module the Invoice was for. You can use get_modules to get a list of available modules.
invoices_due_date string Date the Invoice is Due
invoices_service int ID of the Service/Order this Invoice is for such as 1000 if the order was vps1000 and the module was vps

Licenses Get Client Unpaid Invoices

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_licenses_get_client_unpaid_invoices($sid);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_licenses_get_client_unpaid_invoices()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_licenses_get_client_unpaid_invoices, message: { 
    sid: ARGV[0], 
})
print response.body[:api_licenses_get_client_unpaid_invoices_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_licenses_get_client_unpaid_invoices($sid);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_licenses_get_client_unpaid_invoices

This Function Applies to the Licensing services. * This function returns a list of all the unpaid invoices matching the module * passed..

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call

Output Fields

Field Type Description
invoices_id int ID of the Invoice used for referencing
invoices_description string Description of what the Invoice was for
invoices_amount float Cost of the Invoice
invoices_custid int ID of the Customer this Invoice is for
invoices_type int The Type of Invoice (1 = charge, 10+ are payment types)
invoices_date string Date the Invoice was Created
invoices_group int Billing Group the Invoice falls under, Not currently used
invoices_extra int If type 1 invoice this points to the repeat invoice id, otherwise points to the id of the charge invoice its a payment for.
invoices_paid int Wether or not the Invoice was paid (if applicable)
invoices_module string Module the Invoice was for. You can use get_modules to get a list of available modules.
invoices_due_date string Date the Invoice is Due
invoices_service int ID of the Service/Order this Invoice is for such as 1000 if the order was vps1000 and the module was vps

Licenses Get Service

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$id = $ARGV[2];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_licenses_get_service($sid, $id);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_licenses_get_service()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_licenses_get_service, message: { 
    sid: ARGV[0], 
    id: ARGV[1], 
})
print response.body[:api_licenses_get_service_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$id = $_SERVER['argv'][3];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_licenses_get_service($sid, $id);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_licenses_get_service

This Function Applies to the Licensing services. * Gets service info for the given ID in the given Module. An example of this * would be in the "vps" module have order id

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
id int

Output Fields

Field Type Description
license_id int Service ID
license_type int Package ID
license_cost float Service Cost
license_custid int Customer ID
license_ip string IP Address tied to License
license_status string Billing Status
license_invoice int Invoice ID
license_coupon int Coupon ID
license_extra string Addiitional License Information
license_hostname string Hostname tied to License

Licenses Get Services

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_licenses_get_services($sid);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_licenses_get_services()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_licenses_get_services, message: { 
    sid: ARGV[0], 
})
print response.body[:api_licenses_get_services_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_licenses_get_services($sid);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_licenses_get_services

This Function Applies to the Licensing services. * Gets List of Services

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call

Output Fields

Field Type Description
license_id int Service ID
license_type int Package ID
license_cost float Service Cost
license_custid int Customer ID
license_ip string IP Address tied to License
license_status string Billing Status
license_invoice int Invoice ID
license_coupon int Coupon ID
license_extra string Addiitional License Information
license_hostname string Hostname tied to License

QuickServers

Quickservers Cancel Service

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$id = $ARGV[2];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_quickservers_cancel_service($sid, $id);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_quickservers_cancel_service()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_quickservers_cancel_service, message: { 
    sid: ARGV[0], 
    id: ARGV[1], 
})
print response.body[:api_quickservers_cancel_service_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$id = $_SERVER['argv'][3];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_quickservers_cancel_service($sid, $id);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_quickservers_cancel_service

This Function Applies to the QuickServers services. * Cancels a service for the passed module matching the passed id. Canceling a * service will also cancel any addons for that service at the same time.

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
id int ID / Service ID you wish to cancel

Output Fields

Field Type Description
return bool

Example API Response

Type Value
Boolean

Quickservers Get Client Invoices

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_quickservers_get_client_invoices($sid);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_quickservers_get_client_invoices()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_quickservers_get_client_invoices, message: { 
    sid: ARGV[0], 
})
print response.body[:api_quickservers_get_client_invoices_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_quickservers_get_client_invoices($sid);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_quickservers_get_client_invoices

This Function Applies to the QuickServers services. * Gets a list of all the invoices.

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call

Output Fields

Field Type Description
invoices_id int ID of the Invoice used for referencing
invoices_description string Description of what the Invoice was for
invoices_amount float Cost of the Invoice
invoices_custid int ID of the Customer this Invoice is for
invoices_type int The Type of Invoice (1 = charge, 10+ are payment types)
invoices_date string Date the Invoice was Created
invoices_group int Billing Group the Invoice falls under, Not currently used
invoices_extra int If type 1 invoice this points to the repeat invoice id, otherwise points to the id of the charge invoice its a payment for.
invoices_paid int Wether or not the Invoice was paid (if applicable)
invoices_module string Module the Invoice was for. You can use get_modules to get a list of available modules.
invoices_due_date string Date the Invoice is Due
invoices_service int ID of the Service/Order this Invoice is for such as 1000 if the order was vps1000 and the module was vps

Quickservers Get Client Unpaid Invoices

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_quickservers_get_client_unpaid_invoices($sid);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_quickservers_get_client_unpaid_invoices()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_quickservers_get_client_unpaid_invoices, message: { 
    sid: ARGV[0], 
})
print response.body[:api_quickservers_get_client_unpaid_invoices_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_quickservers_get_client_unpaid_invoices($sid);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_quickservers_get_client_unpaid_invoices

This Function Applies to the QuickServers services. * This function returns a list of all the unpaid invoices matching the module * passed..

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call

Output Fields

Field Type Description
invoices_id int ID of the Invoice used for referencing
invoices_description string Description of what the Invoice was for
invoices_amount float Cost of the Invoice
invoices_custid int ID of the Customer this Invoice is for
invoices_type int The Type of Invoice (1 = charge, 10+ are payment types)
invoices_date string Date the Invoice was Created
invoices_group int Billing Group the Invoice falls under, Not currently used
invoices_extra int If type 1 invoice this points to the repeat invoice id, otherwise points to the id of the charge invoice its a payment for.
invoices_paid int Wether or not the Invoice was paid (if applicable)
invoices_module string Module the Invoice was for. You can use get_modules to get a list of available modules.
invoices_due_date string Date the Invoice is Due
invoices_service int ID of the Service/Order this Invoice is for such as 1000 if the order was vps1000 and the module was vps

Quickservers Get Service

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$id = $ARGV[2];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_quickservers_get_service($sid, $id);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_quickservers_get_service()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_quickservers_get_service, message: { 
    sid: ARGV[0], 
    id: ARGV[1], 
})
print response.body[:api_quickservers_get_service_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$id = $_SERVER['argv'][3];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_quickservers_get_service($sid, $id);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_quickservers_get_service

This Function Applies to the QuickServers services. * Gets service info for the given ID in the given Module. An example of this * would be in the "vps" module have order id

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
id int

Output Fields

Field Type Description
qs_id int Server ID
qs_server int QuickServer VPS Host Server ID
qs_vzid string QuickServer VPS Host-Side Server ID
qs_type int Server Type
qs_cost float Service Cost
qs_custid int Customer ID
qs_ip string IP Address
qs_status string Billing Status
qs_invoice int Invoice ID
qs_coupon int Coupon ID
qs_extra string Additional QuickServer VPS information
qs_hostname string Hostname of the QuickServer VPS
qs_server_status string Server Status of QuickServer VPS
qs_comment string Comments about the QuickServer VPS
qs_slices int QuickServer VPS # of Slices
qs_vnc string VNC Address for QuickServer VPS

Quickservers Get Services

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_quickservers_get_services($sid);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_quickservers_get_services()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_quickservers_get_services, message: { 
    sid: ARGV[0], 
})
print response.body[:api_quickservers_get_services_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_quickservers_get_services($sid);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_quickservers_get_services

This Function Applies to the QuickServers services. * Gets List of Services

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call

Output Fields

Field Type Description
qs_id int Server ID
qs_server int QuickServer VPS Host Server ID
qs_vzid string QuickServer VPS Host-Side Server ID
qs_type int Server Type
qs_cost float Service Cost
qs_custid int Customer ID
qs_ip string IP Address
qs_status string Billing Status
qs_invoice int Invoice ID
qs_coupon int Coupon ID
qs_extra string Additional QuickServer VPS information
qs_hostname string Hostname of the QuickServer VPS
qs_server_status string Server Status of QuickServer VPS
qs_comment string Comments about the QuickServer VPS
qs_slices int QuickServer VPS # of Slices
qs_vnc string VNC Address for QuickServer VPS

Domains

Domains Cancel Service

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$id = $ARGV[2];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_domains_cancel_service($sid, $id);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_domains_cancel_service()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_domains_cancel_service, message: { 
    sid: ARGV[0], 
    id: ARGV[1], 
})
print response.body[:api_domains_cancel_service_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$id = $_SERVER['argv'][3];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_domains_cancel_service($sid, $id);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_domains_cancel_service

This Function Applies to the Domain Registrations services. * Cancels a service for the passed module matching the passed id. Canceling a * service will also cancel any addons for that service at the same time.

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
id int ID / Service ID you wish to cancel

Output Fields

Field Type Description
return bool

Example API Response

Type Value
Boolean

Domains Get Client Invoices

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_domains_get_client_invoices($sid);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_domains_get_client_invoices()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_domains_get_client_invoices, message: { 
    sid: ARGV[0], 
})
print response.body[:api_domains_get_client_invoices_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_domains_get_client_invoices($sid);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_domains_get_client_invoices

This Function Applies to the Domain Registrations services. * Gets a list of all the invoices.

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call

Output Fields

Field Type Description
invoices_id int ID of the Invoice used for referencing
invoices_description string Description of what the Invoice was for
invoices_amount float Cost of the Invoice
invoices_custid int ID of the Customer this Invoice is for
invoices_type int The Type of Invoice (1 = charge, 10+ are payment types)
invoices_date string Date the Invoice was Created
invoices_group int Billing Group the Invoice falls under, Not currently used
invoices_extra int If type 1 invoice this points to the repeat invoice id, otherwise points to the id of the charge invoice its a payment for.
invoices_paid int Wether or not the Invoice was paid (if applicable)
invoices_module string Module the Invoice was for. You can use get_modules to get a list of available modules.
invoices_due_date string Date the Invoice is Due
invoices_service int ID of the Service/Order this Invoice is for such as 1000 if the order was vps1000 and the module was vps

Domains Get Client Unpaid Invoices

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_domains_get_client_unpaid_invoices($sid);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_domains_get_client_unpaid_invoices()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_domains_get_client_unpaid_invoices, message: { 
    sid: ARGV[0], 
})
print response.body[:api_domains_get_client_unpaid_invoices_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_domains_get_client_unpaid_invoices($sid);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_domains_get_client_unpaid_invoices

This Function Applies to the Domain Registrations services. * This function returns a list of all the unpaid invoices matching the module * passed..

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call

Output Fields

Field Type Description
invoices_id int ID of the Invoice used for referencing
invoices_description string Description of what the Invoice was for
invoices_amount float Cost of the Invoice
invoices_custid int ID of the Customer this Invoice is for
invoices_type int The Type of Invoice (1 = charge, 10+ are payment types)
invoices_date string Date the Invoice was Created
invoices_group int Billing Group the Invoice falls under, Not currently used
invoices_extra int If type 1 invoice this points to the repeat invoice id, otherwise points to the id of the charge invoice its a payment for.
invoices_paid int Wether or not the Invoice was paid (if applicable)
invoices_module string Module the Invoice was for. You can use get_modules to get a list of available modules.
invoices_due_date string Date the Invoice is Due
invoices_service int ID of the Service/Order this Invoice is for such as 1000 if the order was vps1000 and the module was vps

Domains Get Service

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$id = $ARGV[2];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_domains_get_service($sid, $id);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_domains_get_service()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_domains_get_service, message: { 
    sid: ARGV[0], 
    id: ARGV[1], 
})
print response.body[:api_domains_get_service_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$id = $_SERVER['argv'][3];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_domains_get_service($sid, $id);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_domains_get_service

This Function Applies to the Domain Registrations services. * Gets service info for the given ID in the given Module. An example of this * would be in the "vps" module have order id

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
id int

Output Fields

Field Type Description
domain_id int Service ID
domain_hostname string Domain Name
domain_username string Username with Registrar
domain_password string Password with Registrar
domain_type int Package ID
domain_cost float Service Cost
domain_custid int Customer ID
domain_status string Billing Status
domain_invoice int Invoice ID
domain_coupon int Coupon ID
domain_extra string Additional Domain Information
domain_firstname string First Name
domain_lastname string Last Name
domain_email string Email Address
domain_address string Address
domain_address2 string Address (line 2)
domain_address3 string Address (line 3)
domain_city string City
domain_state string State
domain_zip string Zip
domain_country string Country
domain_phone string Phone
domain_fax string Fax
domain_company string Company

Domains Get Services

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_domains_get_services($sid);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_domains_get_services()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_domains_get_services, message: { 
    sid: ARGV[0], 
})
print response.body[:api_domains_get_services_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_domains_get_services($sid);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_domains_get_services

This Function Applies to the Domain Registrations services. * Gets List of Services

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call

Output Fields

Field Type Description
domain_id int Service ID
domain_hostname string Domain Name
domain_username string Username with Registrar
domain_password string Password with Registrar
domain_type int Package ID
domain_cost float Service Cost
domain_custid int Customer ID
domain_status string Billing Status
domain_invoice int Invoice ID
domain_coupon int Coupon ID
domain_extra string Additional Domain Information
domain_firstname string First Name
domain_lastname string Last Name
domain_email string Email Address
domain_address string Address
domain_address2 string Address (line 2)
domain_address3 string Address (line 3)
domain_city string City
domain_state string State
domain_zip string Zip
domain_country string Country
domain_phone string Phone
domain_fax string Fax
domain_company string Company

SSL

SSL Cancel Service

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$id = $ARGV[2];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_ssl_cancel_service($sid, $id);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_ssl_cancel_service()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_ssl_cancel_service, message: { 
    sid: ARGV[0], 
    id: ARGV[1], 
})
print response.body[:api_ssl_cancel_service_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$id = $_SERVER['argv'][3];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_ssl_cancel_service($sid, $id);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_ssl_cancel_service

This Function Applies to the SSL Certificates services. * Cancels a service for the passed module matching the passed id. Canceling a * service will also cancel any addons for that service at the same time.

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
id int ID / Service ID you wish to cancel

Output Fields

Field Type Description
return bool

Example API Response

Type Value
Boolean

SSL Get Client Invoices

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_ssl_get_client_invoices($sid);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_ssl_get_client_invoices()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_ssl_get_client_invoices, message: { 
    sid: ARGV[0], 
})
print response.body[:api_ssl_get_client_invoices_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_ssl_get_client_invoices($sid);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_ssl_get_client_invoices

This Function Applies to the SSL Certificates services. * Gets a list of all the invoices.

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call

Output Fields

Field Type Description
invoices_id int ID of the Invoice used for referencing
invoices_description string Description of what the Invoice was for
invoices_amount float Cost of the Invoice
invoices_custid int ID of the Customer this Invoice is for
invoices_type int The Type of Invoice (1 = charge, 10+ are payment types)
invoices_date string Date the Invoice was Created
invoices_group int Billing Group the Invoice falls under, Not currently used
invoices_extra int If type 1 invoice this points to the repeat invoice id, otherwise points to the id of the charge invoice its a payment for.
invoices_paid int Wether or not the Invoice was paid (if applicable)
invoices_module string Module the Invoice was for. You can use get_modules to get a list of available modules.
invoices_due_date string Date the Invoice is Due
invoices_service int ID of the Service/Order this Invoice is for such as 1000 if the order was vps1000 and the module was vps

SSL Get Client Unpaid Invoices

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_ssl_get_client_unpaid_invoices($sid);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_ssl_get_client_unpaid_invoices()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_ssl_get_client_unpaid_invoices, message: { 
    sid: ARGV[0], 
})
print response.body[:api_ssl_get_client_unpaid_invoices_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_ssl_get_client_unpaid_invoices($sid);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_ssl_get_client_unpaid_invoices

This Function Applies to the SSL Certificates services. * This function returns a list of all the unpaid invoices matching the module * passed..

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call

Output Fields

Field Type Description
invoices_id int ID of the Invoice used for referencing
invoices_description string Description of what the Invoice was for
invoices_amount float Cost of the Invoice
invoices_custid int ID of the Customer this Invoice is for
invoices_type int The Type of Invoice (1 = charge, 10+ are payment types)
invoices_date string Date the Invoice was Created
invoices_group int Billing Group the Invoice falls under, Not currently used
invoices_extra int If type 1 invoice this points to the repeat invoice id, otherwise points to the id of the charge invoice its a payment for.
invoices_paid int Wether or not the Invoice was paid (if applicable)
invoices_module string Module the Invoice was for. You can use get_modules to get a list of available modules.
invoices_due_date string Date the Invoice is Due
invoices_service int ID of the Service/Order this Invoice is for such as 1000 if the order was vps1000 and the module was vps

SSL Get Service

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$id = $ARGV[2];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_ssl_get_service($sid, $id);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_ssl_get_service()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_ssl_get_service, message: { 
    sid: ARGV[0], 
    id: ARGV[1], 
})
print response.body[:api_ssl_get_service_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$id = $_SERVER['argv'][3];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_ssl_get_service($sid, $id);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_ssl_get_service

This Function Applies to the SSL Certificates services. * Gets service info for the given ID in the given Module. An example of this * would be in the "vps" module have order id

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
id int

Output Fields

Field Type Description
ssl_id int Service ID
ssl_hostname string Hostname of the SSL Certificate
ssl_order_id string Order ID with the Certificate Signer
ssl_type int Package ID
ssl_cost float Service Cost
ssl_custid int Customer ID
ssl_status string Billing Status
ssl_invoice int Invoice ID
ssl_coupon int Coupon ID
ssl_firstname string First Name
ssl_lastname string Last Name
ssl_phone string Phone Number
ssl_email string Email Address
ssl_company string Company
ssl_address string Address
ssl_city string City
ssl_state string State
ssl_zip string Zip
ssl_country string Country
ssl_department string Department
ssl_extra string SSL Additional Information

SSL Get Services

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_ssl_get_services($sid);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_ssl_get_services()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_ssl_get_services, message: { 
    sid: ARGV[0], 
})
print response.body[:api_ssl_get_services_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_ssl_get_services($sid);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_ssl_get_services

This Function Applies to the SSL Certificates services. * Gets List of Services

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call

Output Fields

Field Type Description
ssl_id int Service ID
ssl_hostname string Hostname of the SSL Certificate
ssl_order_id string Order ID with the Certificate Signer
ssl_type int Package ID
ssl_cost float Service Cost
ssl_custid int Customer ID
ssl_status string Billing Status
ssl_invoice int Invoice ID
ssl_coupon int Coupon ID
ssl_firstname string First Name
ssl_lastname string Last Name
ssl_phone string Phone Number
ssl_email string Email Address
ssl_company string Company
ssl_address string Address
ssl_city string City
ssl_state string State
ssl_zip string Zip
ssl_country string Country
ssl_department string Department
ssl_extra string SSL Additional Information

Backups

Backups Cancel Service

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$id = $ARGV[2];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_backups_cancel_service($sid, $id);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_backups_cancel_service()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_backups_cancel_service, message: { 
    sid: ARGV[0], 
    id: ARGV[1], 
})
print response.body[:api_backups_cancel_service_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$id = $_SERVER['argv'][3];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_backups_cancel_service($sid, $id);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_backups_cancel_service

This Function Applies to the Backup Services services. * Cancels a service for the passed module matching the passed id. Canceling a * service will also cancel any addons for that service at the same time.

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
id int ID / Service ID you wish to cancel

Output Fields

Field Type Description
return bool

Example API Response

Type Value
Boolean

Backups Get Client Invoices

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_backups_get_client_invoices($sid);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_backups_get_client_invoices()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_backups_get_client_invoices, message: { 
    sid: ARGV[0], 
})
print response.body[:api_backups_get_client_invoices_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_backups_get_client_invoices($sid);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_backups_get_client_invoices

This Function Applies to the Backup Services services. * Gets a list of all the invoices.

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call

Output Fields

Field Type Description
invoices_id int ID of the Invoice used for referencing
invoices_description string Description of what the Invoice was for
invoices_amount float Cost of the Invoice
invoices_custid int ID of the Customer this Invoice is for
invoices_type int The Type of Invoice (1 = charge, 10+ are payment types)
invoices_date string Date the Invoice was Created
invoices_group int Billing Group the Invoice falls under, Not currently used
invoices_extra int If type 1 invoice this points to the repeat invoice id, otherwise points to the id of the charge invoice its a payment for.
invoices_paid int Wether or not the Invoice was paid (if applicable)
invoices_module string Module the Invoice was for. You can use get_modules to get a list of available modules.
invoices_due_date string Date the Invoice is Due
invoices_service int ID of the Service/Order this Invoice is for such as 1000 if the order was vps1000 and the module was vps

Backups Get Client Unpaid Invoices

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_backups_get_client_unpaid_invoices($sid);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_backups_get_client_unpaid_invoices()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_backups_get_client_unpaid_invoices, message: { 
    sid: ARGV[0], 
})
print response.body[:api_backups_get_client_unpaid_invoices_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_backups_get_client_unpaid_invoices($sid);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_backups_get_client_unpaid_invoices

This Function Applies to the Backup Services services. * This function returns a list of all the unpaid invoices matching the module * passed..

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call

Output Fields

Field Type Description
invoices_id int ID of the Invoice used for referencing
invoices_description string Description of what the Invoice was for
invoices_amount float Cost of the Invoice
invoices_custid int ID of the Customer this Invoice is for
invoices_type int The Type of Invoice (1 = charge, 10+ are payment types)
invoices_date string Date the Invoice was Created
invoices_group int Billing Group the Invoice falls under, Not currently used
invoices_extra int If type 1 invoice this points to the repeat invoice id, otherwise points to the id of the charge invoice its a payment for.
invoices_paid int Wether or not the Invoice was paid (if applicable)
invoices_module string Module the Invoice was for. You can use get_modules to get a list of available modules.
invoices_due_date string Date the Invoice is Due
invoices_service int ID of the Service/Order this Invoice is for such as 1000 if the order was vps1000 and the module was vps

Backups Get Service

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password = $ARGV[1];
$id = $ARGV[2];
$client = SOAP::Lite
  -> uri('urn:myapi')
  -> proxy('https://my.interserver.net/api.php?wsdl');
$sid = $client
  -> api_login($username, $password)
  -> result;
if (length($sid) == 0)  {
  die "Got A Blank Session";
} 
$res = $client
  -> api_backups_get_service($sid, $id);
die $res->faultstring if ($res->fault);
print "Response:\n",$res->result,"\n";

#!/usr/bin/python
from suds.client import Client
client = Client("https://my.interserver.net/api.php?wsdl")
#print client ## shows detailed client info
sid = client.service.api_login(argv[1], argv[2])
if (sid == '')
  die("Got a blank session")
print "Got Session ID "+sid+"\n"

result = client.service.api_backups_get_service()
print result

#!/usr/bin/env ruby
require 'savon'

client = Savon.client(wsdl: 'https://my.interserver.net/api.php?wsdl')
response = client.call(
  :api_login, message: {
    username: ARGV[0],
    password: ARGV[1]
})
sid = response.body[:api_login_response][:return]
if (sid == "")
  die("Got a blank session id");
print "got session id ",sid,"\n"
response = client.call(
  :api_backups_get_service, message: { 
    sid: ARGV[0], 
    id: ARGV[1], 
})
print response.body[:api_backups_get_service_response][:return],"\n"

<?php
ini_set("soap.wsdl_cache_enabled", "0");
$username = $_SERVER['argv'][1];
$password = $_SERVER['argv'][2];
$id = $_SERVER['argv'][3];
$client = new SoapClient("https://my.interserver.net/api.php?wsdl");
try  { 
  $sid = $client->api_login($username, $password);
  if (strlen($sid) == 0)
    die("Got A Blank Session");
  $res = $client->api_backups_get_service($sid, $id);
  echo '$res = '.var_export($res, true)."\n";
 } catch (Exception $ex) {
  echo "Exception Occurred!\n";
  echo "Code:{$ex->faultcode}\n";
  echo "String:{$ex->faultstring}\n";
}; 
?>

API Function Name: api_backups_get_service

This Function Applies to the Backup Services services. * Gets service info for the given ID in the given Module. An example of this * would be in the "vps" module have order id

Input Parameters

Parameter Type Description
sid string the Session ID you get from the login call
id int

Output Fields

Field Type Description
backup_id int ID of the Backup Host Server
backup_server int ID of Server the Backup Resides on
backup_username string Username on the Backup Server associated with this Order
backup_type int Which type of Backup Server
backup_cost float Service Cost
backup_custid int Customer ID
backup_quota int Disk Quota
backup_ip string IP Address of the Backup Server
backup_status string Billing Status
backup_invoice int Invoice ID
backup_coupon int Coupon ID
backup_extra string Additional Backup Information
backup_server_status string Server-Side status of this website

Backups Get Services

a#!/usr/bin/perl -w
use SOAP::Lite;

$username = $ARGV[0];
$password =