Images

To list all of the images available on your account, send a GET request to https://api.e2enetworks.com/myaccount/api/v1/images/saved-images/?apikey={{api_key}}.

The response will be a JSON object with a key called images. This will be set to an array of image objects, each of which will contain the standard image attributes:

List all Images

Name

Type

Description

name

String

Name of node images

plan

String

The unique slug identifier for the plan of this node image

image

string

Base image name for node creation.

OS name

version image

JSON string

string string

Operating system Details like name of os , version of os and unique identifier for image os name.

Zone slug_name

JSON string

In which zone image is available to launc node.

Specs ram (in GB)

cpu (in Cores) disk_space(in GB) price_per_month(in Rs) price_per_hour (in Rs) series minimum_billing_amount (in Rs)

JSON string

string string string string string integer

Image Specification like there ram in node image

cpu in node disk space in node price per month price per hour node belongs to which series minimum billing amount in case of

Specs ram (in GB) cpu (in Cores) disk_space(in GB) price_per_month(in Rs) Price_per_hour (in Rs) series minimum_billing_amount (in Rs), committed_sku_id

JSON string string String String String String integer integer

Image Specification like there ram in node image cpu in node disk space in node price per month price per hour node belongs to which series minimum billing amount in case of, committed SKU ID

CURL

curl -X GET  'https://api.e2enetworks.com/myaccount/api/v1/images/saved-images/?apikey={{api_key}}'  -H 'Authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSldU..........'

PHP

1. PHP HttpRequest Example

       $request = new HttpRequest();
$request->setUrl('https://api.e2enetworks.com/myaccount/api/v1/images/saved-images/');
$request->setMethod(HTTP_METH_GET);

$request->setQueryData(array(
  'apikey' => '{{api_key}}',
  'image_type' => 'private'
));

$request->setHeaders(array(
  'Authorization' => 'Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSld........'
));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}


2. PHP pecl_http Example

       $client = new http\Client;
$request = new http\Client\Request;

$request->setRequestUrl('https://api.e2enetworks.com/myaccount/api/v1/images/'saved-images/);
$request->setRequestMethod('GET');
$request->setQuery(new http\QueryString(array(
  'apikey' => '{{api_key}}',
  'image_type' => 'private'
)));

$request->setHeaders(array(
  'Authorization' => 'Bearer eyJhbGciOiJSUzI1NiIsInR5cCI..........'
));

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();


3. PHP CURL Example

       $curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.e2enetworks.com/myaccount/api/v1/images/saved-images/?apikey={{api_key}}&image_type=private",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_POSTFIELDS => "",
  CURLOPT_HTTPHEADER => array(
    "Authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSldUIiwia2lk..........."
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}

NODEJS

1. Nodejs Native Example

      var http = require("http");

var options = {
  "method": "GET",
  "hostname": [
    "api",
    "e2enetworks",
    "com"
  ],
  "path": [
    "myaccount",
    "images",
    "1.0"
  ],
  "headers": {
    "Authorization": "Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSld..........",
    "cache-control": "no-cache",
    "Postman-Token": "491fe905-b7ce-43a0-be46-5b7c22c2370e"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();



2. NodeJs Request Example

      var request = require("request");

var options = { method: 'GET',
  url: 'https://api.e2enetworks.com/myaccount/api/v1/images/saved-images/',
  qs:
   { apikey: '{{api_key}}',
     image_type: 'private' },
  headers:
   {
     Authorization: 'Bearer eyJhbGciOiJSUzI1NiIsInR5cC..............' } };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});




3. NodeJs Unirest Example

      var unirest = require("unirest");

var req = unirest("GET", "https://api.e2enetworks.com/myaccount/api/v1/images/saved-images/");

req.query({
  "apikey": "{{api_key}}",
  "image_type": "private"
});

req.headers({
  "Authorization": "Bearer eyJhbGciOiJSUzI1NiIsInR5cCI......."
});


req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});

Headers

Request Headers

Content-Type: application/json
Authorization: Bearer b7d03a6947b217efb6f3ec3bd3504582.....

Response Headers

content-type: application/json; charset=utf-8
status: 200 OK
ratelimit-limit: 1200
ratelimit-remaining: 777
ratelimit-reset: 1415984218

Body

Response Body

{
    "message": "Success",
    "code": 200,
    "data": [
        {
            "name": "CentOS-6.8",
            "size": "B-1VCPU-2RAM-15DISK",
            "image": "CentOS-6.8-GPU",
            "os": {
                "name": "Centos",
                "version": "6.8",
                "image": "CentOS-6.8-GPU"
            },
            "zone": {
                "slug_name": "ncr"
            },
            "specs": {
                "ram": "6.10",
                "cpu": 1,
                "disk_space": 15,
                "price_per_month": "1377",
                "price_per_hour": "1.85",
                "series": "B",
                "minimum_billing_amount": "0"
            }
        },
        {
            "name": "GPU-CentOS-6.8",
            "size": "B-1VCPU-2RAM-15DISK",
            "image": "CentOS-6.8-GPU",
            "os": {
                "name": "Centos",
                "version": "6.8",
                "image": "CentOS-6.8-GPU"
            },
            "zone": {
                "slug_name": "ncr"
            },
            "specs": {
                "ram": "6.10",
                "cpu": 1,
                "disk_space": 15,
                "price_per_month": "1377",
                "price_per_hour": "1.85",
                "series": "B",
                "minimum_billing_amount": "0"
            }
        },
        {
            "name": "GPU-CentOS-7.3",
            "size": "B-1VCPU-2RAM-15DISK",
            "image": "CentOS-6.8-GPU",
            "os": {
                "name": "Centos",
                "version": "6.8",
                "image": "CentOS-6.8-GPU"
            },
            "zone": {
                "slug_name": "ncr"
            },
            "specs": {
                "ram": "6.10",
                "cpu": 1,
                "disk_space": 15,
                "price_per_month": "1377",
                "price_per_hour": "1.85",
                "series": "B",
                "minimum_billing_amount": "0"
            }
        },
        {
            "name": "CentOS-7.3-1GB",
            "size": "B-1VCPU-6RAM-46DISK",
            "image": "CentOS-7.3-Distro",
            "os": {
                "name": "Centos",
                "version": "7.3",
                "image": "CentOS-7.3-Distro"
            },
            "zone": {
                "slug_name": "ncr"
            },
            "specs": {
                "ram": "6.00",
                "cpu": 1,
                "disk_space": 46,
                "price_per_month": "685",
                "price_per_hour": "0.92",
                "series": "B",
                "minimum_billing_amount": "100"
            }
        },
        {
            "name": "saved-image-0005",
            "size": "B-1VCPU-6RAM-46DISK",
            "image": "CentOS-7.3-Distro",
            "os": {
                "name": "Centos",
                "version": "7.3",
                "image": "CentOS-7.3-Distro"
            },
            "zone": {
                "slug_name": "ncr"
            },
            "specs": {
                "ram": "6.00",
                "cpu": 1,
                "disk_space": 46,
                "price_per_month": "685",
                "price_per_hour": "0.92",
                "series": "B",
                "minimum_billing_amount": "100"
            }
        }
        "specs": {
            "committed_sku":[{"committed_sku_id":229,"committed_sku_name":"365 Days Committed , Rs 17739","committed_node_message":"This committed node will be reserved for next 365 days ( till 04-December-2021 07:32). The cost Rs. 17739 of this node  will be added in next invoice.","committed_sku_price":"17739","committed_upto_date":"04-December-2021 07:32","committed_days":365},{"committed_sku_id":808,"committed_sku_name":"7 Days Committed , Rs 378","committed_node_message":"This committed node will be reserved for next 7 days ( till 11-December-2020 07:32). The cost Rs. 378 of this node  will be added in next invoice.","committed_sku_price":"378","committed_upto_date":"11-December-2020 07:32","committed_days":7}]}

        }

......
 ],
    "errors": {}
}

List Images By Image Type

To list all images assigned to a specific image type, add the image_type as a query parameter and send a GET request to endpoint https://api.e2enetworks.com/myaccount/api/v1/images/?apikey={{api_key}}&image_type=$IMAGE_TYPE.

Name

Type

Description

name

String

Name of node images

plan

String

The unique slug identifier for the plan of this node image

image

string

Base image name for node creation.

OS name

version image

JSON string

string string

Operating system Details like name of os , version of os and unique identifier for image os name.

Zone slug_name

JSON string

In which zone image is available to launc node.

Specs ram (in GB)

cpu (in Cores) disk_space(in GB) price_per_month(in Rs) price_per_hour (in Rs) series minimum_billing_amount (in Rs)

JSON string

string string string string string integer

Image Specification like there ram in node image

cpu in node disk space in node price per month price per hour node belongs to which series minimum billing amount in case of

CURL

curl -X GET 'https://api.e2enetworks.com/myaccount/api/v1/images/?apikey={{api_key}}&image_type=public'-H 'authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgO..........s'

PHP

1. PHP HttpRequest Example

       $request = new HttpRequest();
$request->setUrl('https://api.e2enetworks.com/myaccount/api/v1/images/');
$request->setMethod(HTTP_METH_GET);

$request->setQueryData(array(
  'apikey' => '{{api_key}}',
  'image_type' => 'public'
));

$request->setHeaders(array(
  'authorization' => 'Bearer eyJhbGciOiJSUzI1NiIsInR5cCI........'
));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}

    2. PHP pecl_http Example

       $client = new http\Client;
$request = new http\Client\Request;

$request->setRequestUrl('https://api.e2enetworks.com/myaccount/api/v1/images/');
$request->setRequestMethod('GET');
$request->setQuery(new http\QueryString(array(
  'apikey' => '{{api_key}}',
  'image_type' => 'public'
)));

$request->setHeaders(array(
  'authorization' => 'Bearer eyJhbGciOiJSUzI1NiIsInR5.....'
));

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();



3. PHP CURL Example

       $curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.e2enetworks.com/myaccount/api/v1/images/?apikey={{api_key}}&image_type=public",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSldUIiwia2lkIiA6ICJjejBXYVVKVF9wWm......",
    "cache-control: no-cache",
    "postman-token: f977962a-ab4d-2b3c-7d3a-71394b4f1953"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}

NODEJS

1. Nodejs Native Example

      var http = require("http");

var options = {
  "method": "GET",
  "hostname": "api.e2enetworks.com",
  "port": null,
  "path": "/myaccount/api/v1/images/?apikey={{api_key}}&image_type=public",
  "headers": {
    "authorization": "Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSldU............"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();



2. NodeJs Request Example

      var request = require("request");

var options = { method: 'GET',
  url: 'https://api.e2enetworks.com/myaccount/api/v1/images/',
  qs:
   { apikey: '{{api_key}}',
     image_type: 'public' },
  headers:
   {
     authorization: 'Bearer eyJhbGciOiJSUzI1NiIsInR5cC....' } };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});




3. NodeJs Unirest Example

      var unirest = require("unirest");

var req = unirest("GET", "https://api.e2enetworks.com/myaccount/api/v1/images/");

req.query({
  "apikey": "{{api_key}}",
  "image_type": "public"
});

req.headers({
  "authorization": "Bearer eyJhbGciOiJSUzI1NiIsInR5cC......"
});


req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});

Headers

Request Headers

Content-Type: application/json
Authorization: Bearer b7d03a6947b217efb6f3ec3bd3504582.....

Response Headers

content-type: application/json; charset=utf-8
status: 200 OK
ratelimit-limit: 1200
ratelimit-remaining: 777
ratelimit-reset: 1415984218

Body

Response Body

{
    "message": "Success",
    "code": 200,
    "data": [
        {
            "name": "B.8GB-CentOS-6.10",
            "plan": "B-2VCPU-8RAM-115DISK",
            "image": "CentOS-6.10-Distro",
            "os": {
                "name": "CentOS",
                "version": "6.10",
                "image": "CentOS-6.10-Distro"
            },
            "zone": {
                "slug_name": "ncr"
            },
            "specs": {
                "ram": "8.00",
                "cpu": 2,
                "disk_space": 115,
                "price_per_month": "1971.00",
                "price_per_hour": "2.70",
                "series": "B",
                "minimum_billing_amount": "0"
            }
        },
        {
            "name": "B.15GB-CentOS-6.10",
            "plan": "B-4VCPU-15RAM-230DISK",
            "image": "CentOS-6.10-Distro",
            "os": {
                "name": "CentOS",
                "version": "6.10",
                "image": "CentOS-6.10-Distro"
            },
            "zone": {
                "slug_name": "ncr"
            },
            "specs": {
                "ram": "15.00",
                "cpu": 4,
                "disk_space": 230,
                "price_per_month": "4380.00",
                "price_per_hour": "6.00",
                "series": "B",
                "minimum_billing_amount": "0"
            }
        },
        {
            "name": "B.6.1GB-CentOS-6.10",
            "plan": "B-2VCPU-6RAM-46DISK",
            "image": "CentOS-6.10-Distro",
            "os": {
                "name": "CentOS",
                "version": "6.10",
                "image": "CentOS-6.10-Distro"
            },
            "zone": {
                "slug_name": "ncr"
            },
            "specs": {
                "ram": "6.10",
                "cpu": 2,
                "disk_space": 46,
                "price_per_month": "1350.50",
                "price_per_hour": "1.85",
                "series": "B",
                "minimum_billing_amount": "0"
            }
        },
        {
            "name": "A.4GB-CentOS-6.10",
            "plan": "A-2VCPU-4RAM-60DISK",
            "image": "CentOS-6.10-Distro",
            "os": {
                "name": "CentOS",
                "version": "6.10",
                "image": "CentOS-6.10-Distro"
            },
            "zone": {
                "slug_name": "ncr"
            },
            "specs": {
                "ram": "4.00",
                "cpu": 2,
                "disk_space": 60,
                "price_per_month": "1744.70",
                "price_per_hour": "2.39",
                "series": "A",
                "minimum_billing_amount": "0"
            }
        },
        {
            "name": "A.6GB-CentOS-6.10",
            "plan": "A-3VCPU-6RAM-100DISK",
            "image": "CentOS-6.10-Distro",
            "os": {
                "name": "CentOS",
                "version": "6.10",
                "image": "CentOS-6.10-Distro"
            },
            "zone": {
                "slug_name": "ncr"
            },
            "specs": {
                "ram": "6.00",
                "cpu": 3,
                "disk_space": 100,
                "price_per_month": "2620.70",
                "price_per_hour": "3.59",
                "series": "A",
                "minimum_billing_amount": "0"
            }
        },
        {
            "name": "A.9GB-CentOS-6.10",
            "plan": "A-5VCPU-9RAM-140DISK",
            "image": "CentOS-6.10-Distro",
            "os": {
                "name": "CentOS",
                "version": "6.10",
                "image": "CentOS-6.10-Distro"
            },
            "zone": {
                "slug_name": "ncr"
            },
            "specs": {
                "ram": "9.00",
                "cpu": 5,
                "disk_space": 140,
                "price_per_month": "3584.30",
                "price_per_hour": "4.91",
                "series": "A",
                "minimum_billing_amount": "0"
            }
            "specs": {
            "committed_sku":[{"committed_sku_id":229,"committed_sku_name":"365 Days Committed , Rs 17739","committed_node_message":"This committed node will be reserved for next 365 days ( till 04-December-2021 07:32). The cost Rs. 17739 of this node  will be added in next invoice.","committed_sku_price":"17739","committed_upto_date":"04-December-2021 07:32","committed_days":365},{"committed_sku_id":808,"committed_sku_name":"7 Days Committed , Rs 378","committed_node_message":"This committed node will be reserved for next 7 days ( till 11-December-2020 07:32). The cost Rs. 378 of this node  will be added in next invoice.","committed_sku_price":"378","committed_upto_date":"11-December-2020 07:32","committed_days":7}]}

        }
......
 ],
    "errors": {}
}

List Images By CPU

To list all of the images available on your account, send a GET request to https://api.e2enetworks.com/myaccount/api/v1/images/?apikey={{api_key}}.

The response will be a JSON object with a key called images. This will be set to an array of image objects, each of which will contain the standard image attributes:

Name

Type

Description

name

String

Name of node images

plan

String

The unique slug identifier for the plan of this node image

image

string

Base image name for node creation.

OS name

version image

JSON string

string string

Operating system Details like name of os , version of os and unique identifier for image os name.

Zone slug_name

JSON string

In which zone image is available to launc node.

Specs ram (in GB)

cpu (in Cores) disk_space(in GB) price_per_month(in Rs) price_per_hour (in Rs) series minimum_billing_amount (in Rs)

JSON string

string string string string string integer

Image Specification like there ram in node image

cpu in node disk space in node price per month price per hour node belongs to which series minimum billing amount in case of

CURL

curl -X GET 'https://api.e2enetworks.com/myaccount/api/v1/images/?apikey={{api_key}}&cpu=4'-H 'authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5cCI...........'

PHP

1. PHP HttpRequest Example

       $request = new HttpRequest();
$request->setUrl('https://api.e2enetworks.com/myaccount/api/v1/images/');
$request->setMethod(HTTP_METH_GET);

$request->setQueryData(array(
  'apikey' => '{{api_key}}',
  'cpu' => '4'
));

$request->setHeaders(array(
  'authorization' => 'Bearer eyJhbGciOiJSUzI1NiIsI.......'
));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}

    2. PHP pecl_http Example

       $client = new http\Client;
$request = new http\Client\Request;

$request->setRequestUrl('https://api.e2enetworks.com/myaccount/api/v1/images/');
$request->setRequestMethod('GET');
$request->setQuery(new http\QueryString(array(
  'apikey' => '{{api_key}}',
  'cpu' => '4'
)));

$request->setHeaders(array(
  'authorization' => 'Bearer eyJhbGciOiJSUzI1NiIsInR5cCI.......'
));

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();



3. PHP CURL Example

       $curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.e2enetworks.com/myaccount/api/v1/images/?apikey={{api_key}}&cpu=4",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSldUIiwia2lkIiA6IC.....",
    "cache-control: no-cache",
    "postman-token: f977962a-ab4d-2b3c-7d3a-71394b4f1953"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}

NODEJS

1. Nodejs Native Example

      var http = require("http");

var options = {
  "method": "GET",
  "hostname": "api.e2enetworks.com",
  "port": null,
  "path": "/myaccount/api/v1/images/?apikey={{api_key}}&cpu=4",
  "headers": {
    "authorization": "Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiS...."
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();



2. NodeJs Request Example

      var request = require("request");

var options = { method: 'GET',
  url: 'https://api.e2enetworks.com/myaccount/api/v1/images/',
  qs:
   { apikey: '{{api_key}}',
     cpu: '4' },
  headers:
   {
     authorization: 'Bearer eyJhbGciOiJSUzI1NiIsInR5cC......' } };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});




3. NodeJs Unirest Example

      var unirest = require("unirest");

var req = unirest("GET", "https://api.e2enetworks.com/myaccount/api/v1/images/");

req.query({
  "apikey": "{{api_key}}",
  "cpu": "4"
});

req.headers({
  "authorization": "Bearer eyJhbGciOiJSUzI1NiIsInR5cCI......"
});


req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});

Headers

Request Headers

Content-Type: application/json
Authorization: Bearer b7d03a6947b217efb6f3ec3bd3504582.....

Response Headers

content-type: application/json; charset=utf-8
status: 200 OK
ratelimit-limit: 1200
ratelimit-remaining: 777
ratelimit-reset: 1415984218

Body

Request Body

{
    "message": "Success",
    "code": 200,
    "data": [
        {
            "name": "B.15GB-CentOS-6.10",
            "plan": "B-4VCPU-15RAM-230DISK",
            "image": "CentOS-6.10-Distro",
            "os": {
                "name": "CentOS",
                "version": "6.10",
                "image": "CentOS-6.10-Distro"
            },
            "zone": {
                "slug_name": "ncr"
            },
            "specs": {
                "ram": "15.00",
                "cpu": 4,
                "disk_space": 230,
                "price_per_month": "4380.00",
                "price_per_hour": "6.00",
                "series": "B",
                "minimum_billing_amount": "0"
            }
        },
        {
            "name": "C.10GB-CentOS-6.10",
            "plan": "C-4VCPU-10RAM-100DISK",
            "image": "CentOS-6.10-Distro",
            "os": {
                "name": "CentOS",
                "version": "6.10",
                "image": "CentOS-6.10-Distro"
            },
            "zone": {
                "slug_name": "ncr"
            },
            "specs": {
                "ram": "10.00",
                "cpu": 4,
                "disk_space": 100,
                "price_per_month": "1642.50",
                "price_per_hour": "2.25",
                "series": "C",
                "minimum_billing_amount": "0"
            }
        }
......
 ],
    "errors": {}
}

List Images By RAM

To list all images assigned to a specific ram, add the ram as a query parameter and send a GET request to endpoint https://api.e2enetworks.com/myaccount/api/v1/images/?apikey=10581cd6-3bb6-4b4c-a5fb-79a75b61ecab&ram=$RAM

Name

Type

Description

name

String

Name of node images

plan

String

The unique slug identifier for the plan of this node image

image

string

Base image name for node creation.

OS name

version image

JSON string

string string

Operating system Details like name of os , version of os and unique identifier for image os name.

Zone slug_name

JSON string

In which zone image is available to launc node.

Specs ram (in GB)

cpu (in Cores) disk_space(in GB) price_per_month(in Rs) price_per_hour (in Rs) series minimum_billing_amount (in Rs)

JSON string

string string string string string integer

Image Specification like there ram in node image

cpu in node disk space in node price per month price per hour node belongs to which series minimum billing amount in case of

CURL

curl -X GET 'https://api.e2enetworks.com/myaccount/api/v1/images/?apikey={{api_key}}&ram=8'-H 'authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSldUI..............'

PHP

1. PHP HttpRequest Example

       $request = new HttpRequest();
$request->setUrl('https://api.e2enetworks.com/myaccount/api/v1/images/');
$request->setMethod(HTTP_METH_GET);

$request->setQueryData(array(
  'apikey' => '{{api_key}}',
  'cpu' => '4'
));

$request->setHeaders(array(
  'authorization' => 'Bearer eyJhbGciOiJSUzI1NiIsInR5cCI..........'
));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}

    2. PHP pecl_http Example

       $client = new http\Client;
$request = new http\Client\Request;

$request->setRequestUrl('https://api.e2enetworks.com/myaccount/api/v1/images/');
$request->setRequestMethod('GET');
$request->setQuery(new http\QueryString(array(
  'apikey' => '{{api_key}}',
  'cpu' => '4'
)));

$request->setHeaders(array(
  'authorization' => 'Bearer eyJhbGciOiJSUzI1NiIsInR5........'
));

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();

3. PHP CURL Example

       $curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.e2enetworks.com/myaccount/api/v1/images/?apikey={{api_key}}&cpu=4",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSldUIiwia2lkIiA6I......",
    "cache-control: no-cache",
    "postman-token: f977962a-ab4d-2b3c-7d3a-71394b4f1953"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}

NODEJS

1. Nodejs Native Example

      var http = require("http");

var options = {
  "method": "GET",
  "hostname": "api.e2enetworks.com",
  "port": null,
  "path": "/myaccount/api/v1/images/?apikey={{api_key}}&ram=8",
  "headers": {
    "authorization": "Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSldUIiwia2lkI........"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();


2. NodeJs Request Example

      var request = require("request");

var options = { method: 'GET',
  url: 'https://api.e2enetworks.com/myaccount/api/v1/images/',
  qs:
   { apikey: '{{api_key}}',
     ram: '8' },
  headers:
   {
     authorization: 'Bearer eyJhbGciOiJSUzI1NiIsInR5c........' } };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});



3. NodeJs Unirest Example

      var unirest = require("unirest");

var req = unirest("GET", "https://api.e2enetworks.com/myaccount/api/v1/images/");

req.query({
  "apikey": "{{api_key}}",
  "ram": "8"
});

req.headers({
  "authorization": "Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSl....."
});


req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});

Headers

Request Headers

Content-Type: application/json
Authorization: Bearer b7d03a6947b217efb6f3ec3bd3504582.....

Response Headers

content-type: application/json; charset=utf-8
status: 200 OK
ratelimit-limit: 1200
ratelimit-remaining: 777
ratelimit-reset: 1415984218

Body

Response Body

{
    "message": "Success",
    "code": 200,
    "data": [
        {
            "name": "B.8GB-CentOS-6.10",
            "plan": "B-2VCPU-8RAM-115DISK",
            "image": "CentOS-6.10-Distro",
            "os": {
                "name": "CentOS",
                "version": "6.10",
                "image": "CentOS-6.10-Distro"
            },
            "zone": {
                "slug_name": "ncr"
            },
            "specs": {
                "ram": "8.00",
                "cpu": 2,
                "disk_space": 115,
                "price_per_month": "1971.00",
                "price_per_hour": "2.70",
                "series": "B",
                "minimum_billing_amount": "0"
            }
        },
......
 ],
    "errors": {}
}

List Images By series

To list all images assigned to a specific series, add the series as a query parameter and send a GET request to endpoint https://api.e2enetworks.com/myaccount/api/v1/images/?apikey={{api_key}}&series=$SERIES

Name

Type

Description

name

String

Name of node images

plan

String

The unique slug identifier for the plan of this node image

image

string

Base image name for node creation.

OS name

version image

JSON string

string string

Operating system Details like name of os , version of os and unique identifier for image os name.

Zone slug_name

JSON string

In which zone image is available to launc node.

Specs ram (in GB)

cpu (in Cores) disk_space(in GB) price_per_month(in Rs) price_per_hour (in Rs) series minimum_billing_amount (in Rs)

JSON string

string string string string string integer

Image Specification like there ram in node image

cpu in node disk space in node price per month price per hour node belongs to which series minimum billing amount in case of

CURL

curl -X GET 'https://api.e2enetworks.com/myaccount/api/v1/images/?apikey={{api_key}}&series=A'-H 'authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgO......'

PHP

1. PHP HttpRequest Example

       $request = new HttpRequest();
$request->setUrl('https://api.e2enetworks.com/myaccount/api/v1/images/');
$request->setMethod(HTTP_METH_GET);

$request->setQueryData(array(
  'apikey' => '{{api_key}}',
  'series' => 'A'
));

$request->setHeaders(array(
  'authorization' => 'Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSldUIiwia2.....'
));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}

    2. PHP pecl_http Example

       $client = new http\Client;
$request = new http\Client\Request;

$request->setRequestUrl('https://api.e2enetworks.com/myaccount/api/v1/images/');
$request->setRequestMethod('GET');
$request->setQuery(new http\QueryString(array(
  'apikey' => '{{api_key}}',
  'series' => 'A'
)));

$request->setHeaders(array(
  'authorization' => 'Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAi......'
));

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();



3. PHP CURL Example

       $curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.e2enetworks.com/myaccount/api/v1/images/?apikey={{api_key}}&series=A",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSldUIiwia2lkIi......",
    "cache-control: no-cache",
    "postman-token: f977962a-ab4d-2b3c-7d3a-71394b4f1953"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}

NODEJS

1. Nodejs Native Example

      var http = require("http");

var options = {
  "method": "GET",
  "hostname": "api.e2enetworks.com",
  "port": null,
  "path": "/myaccount/api/v1/images/?apikey={{api_key}}&series=A",
  "headers": {
    "authorization": "Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiS......."
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();



2. NodeJs Request Example

      var request = require("request");

var options = { method: 'GET',
  url: 'https://api.e2enetworks.com/myaccount/api/v1/images/',
  qs:
   { apikey: '{{api_key}}',
     series: 'A' },
  headers:
   {
     authorization: 'Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiS......' } };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});




3. NodeJs Unirest Example

      var unirest = require("unirest");

var req = unirest("GET", "https://api.e2enetworks.com/myaccount/api/v1/images/");

req.query({
  "apikey": "{{api_key}}",
  "series": "A"
});

req.headers({
  "authorization": "Bearer eyJhbGciOiJSUzI1NiIsInR5cCIg....."
});


req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});

Headers

Request Headers

Content-Type: application/json
Authorization: Bearer b7d03a6947b217efb6f3ec3bd3504582...

Response Headers

content-type: application/json; charset=utf-8
status: 200 OK
ratelimit-limit: 1200
ratelimit-remaining: 777
ratelimit-reset: 1415984218

Body

Response Body

{
    "message": "Success",
    "code": 200,
    "data": [
        {
            "name": "A.4GB-CentOS-6.10",
            "plan": "A-2VCPU-4RAM-60DISK",
            "image": "CentOS-6.10-Distro",
            "os": {
                "name": "CentOS",
                "version": "6.10",
                "image": "CentOS-6.10-Distro"
            },
            "zone": {
                "slug_name": "ncr"
            },
            "specs": {
                "ram": "4.00",
                "cpu": 2,
                "disk_space": 60,
                "price_per_month": "1744.70",
                "price_per_hour": "2.39",
                "series": "A",
                "minimum_billing_amount": "0"
            }
        },
        {
            "name": "A.6GB-CentOS-6.10",
            "plan": "A-3VCPU-6RAM-100DISK",
            "image": "CentOS-6.10-Distro",
            "os": {
                "name": "CentOS",
                "version": "6.10",
                "image": "CentOS-6.10-Distro"
            },
            "zone": {
                "slug_name": "ncr"
            },
            "specs": {
                "ram": "6.00",
                "cpu": 3,
                "disk_space": 100,
                "price_per_month": "2620.70",
                "price_per_hour": "3.59",
                "series": "A",
                "minimum_billing_amount": "0"
            }
        },
......
 ],
    "errors": {}
}

List Images By Image Type

To list all images assigned to specific cpu and ram, add the cpu and ram as a query parameter and send a GET request to endpoint https://api.e2enetworks.com/myaccount/api/v1/images/?apikey={{api_key}}&cpu=$CPU&ram=$RAM

Name

Type

Description

name

String

Name of node images

plan

String

The unique slug identifier for the plan of this node image

image

string

Base image name for node creation.

OS name

version image

JSON string

string string

Operating system Details like name of os , version of os and unique identifier for image os name.

Zone slug_name

JSON string

In which zone image is available to launc node.

Specs ram (in GB)

cpu (in Cores) disk_space(in GB) price_per_month(in Rs) price_per_hour (in Rs) series minimum_billing_amount (in Rs)

JSON string

string string string string string integer

Image Specification like there ram in node image

cpu in node disk space in node price per month price per hour node belongs to which series minimum billing amount in case of

CURL

curl -X GET 'https://api.e2enetworks.com/myaccount/api/v1/images/?apikey={{api_key}}&cpu=4&ram=8'-H 'authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiA.....'

PHP

1. PHP HttpRequest Example

       $request = new HttpRequest();
$request->setUrl('https://api.e2enetworks.com/myaccount/api/v1/images/');
$request->setMethod(HTTP_METH_GET);

$request->setQueryData(array(
  'apikey' => '{{api_key}}',
  'cpu' => '4',
  'ram' => '8'
));

$request->setHeaders(array(
  'authorization' => 'Bearer eyJhbGciOiJSUzI1NiIsInR5cCIg.....'
));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}

    2. PHP pecl_http Example

       $client = new http\Client;
$request = new http\Client\Request;

$request->setRequestUrl('https://api.e2enetworks.com/myaccount/api/v1/images/');
$request->setRequestMethod('GET');
$request->setQuery(new http\QueryString(array(
  'apikey' => '{{api_key}}',
  'cpu' => '4',
  'ram' => '8'
)));

$request->setHeaders(array(
  'authorization' => 'Bearer eyJhbGciOiJSUzI1NiIsInR5cC......'
));

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();



3. PHP CURL Example

       $curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.e2enetworks.com/myaccount/api/v1/images/?apikey={{api_key}}&cpu=4&ram=8",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSldUIiwia2lkIiA6ICJj....."
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}

NODEJS

1. Nodejs Native Example

      var http = require("http");

var options = {
  "method": "GET",
  "hostname": "api.e2enetworks.com",
  "port": null,
  "path": "/myaccount/api/v1/images/?apikey={{api_key}}&cpu=8&ram=8",
  "headers": {
    "authorization": "Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSldUIiwia2lkIiA6ICJjej......"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();



2. NodeJs Request Example

      var request = require("request");

var options = { method: 'GET',
  url: 'https://api.e2enetworks.com/myaccount/api/v1/images/',
  qs:
   { apikey: '{{api_key}}',
     cpu: '4',
     ram: '8' },
  headers:
   {
     authorization: 'Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiA.....' } };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});




3. NodeJs Unirest Example

      var unirest = require("unirest");

var req = unirest("GET", "https://api.e2enetworks.com/myaccount/api/v1/images/");

req.query({
  "apikey": "{{api_key}}",
  "cpu": "4",
  "ram": "8"
});

req.headers({
  "authorization": "Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSld........."
});


req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});

Headers

Request Headers

Content-Type: application/json
Authorization: Bearer b7d03a6947b217efb6f3ec3bd3504582......

Response Headers

content-type: application/json; charset=utf-8
status: 200 OK
ratelimit-limit: 1200
ratelimit-remaining: 777
ratelimit-reset: 1415984218

Body

Response Body

{
    "message": "Success",
    "code": 200,
    "data": [
        {
            "name": "E2E-1Click-Redis",
            "plan": "1CLICK-4VCPU-8RAM-20DISK",
            "image": "Debian-9-Distro",
            "os": {
                "name": "Debian",
                "version": null,
                "image": "Debian-9-Distro"
            },
            "zone": {
                "slug_name": "ncr"
            },
            "specs": {
                "ram": "8.00",
                "cpu": 4,
                "disk_space": 20,
                "price_per_month": "730.00",
                "price_per_hour": "1.00",
                "series": "1CLICK",
                "minimum_billing_amount": "0"
            }
        }
    ],
    "errors": {}
}

List Images By CPU, RAM & SERIES

To list all images assigned to specific cpu, ram & series, add the cpu, ram and series as a query parameter and send a GET request to endpoint https://api.e2enetworks.com/myaccount/api/v1/images/?apikey={{api_key}}&cpu=$CPU&ram=$RAM&series=$SERIES

Name

Type

Description

name

String

Name of node images

plan

String

The unique slug identifier for the plan of this node image

image

string

Base image name for node creation.

OS name

version image

JSON string

string string

Operating system Details like name of os , version of os and unique identifier for image os name.

Zone slug_name

JSON string

In which zone image is available to launc node.

Specs ram (in GB)

cpu (in Cores) disk_space(in GB) price_per_month(in Rs) price_per_hour (in Rs) series minimum_billing_amount (in Rs)

JSON string

string string string string string integer

Image Specification like there ram in node image

cpu in node disk space in node price per month price per hour node belongs to which series minimum billing amount in case of

CURL

curl -X GET 'https://api.e2enetworks.com/myaccount/api/v1/images/?apikey=999f9803-faf7-4c4b-803c-7fb7ce5214de&cpu=4&ram=8&series=A'-H 'authorization: Bearer eyJhbGciOiJSUzI1NiIsInR......'

PHP

1. PHP HttpRequest Example

       $request = new HttpRequest();
$request->setUrl('https://api.e2enetworks.com/myaccount/api/v1/images/');
$request->setMethod(HTTP_METH_GET);

$request->setQueryData(array(
  'apikey' => '{{api_key}',
  'cpu' => '4',
  'ram' => '8',
  'series' => 'A'
));

$request->setHeaders(array(
  'authorization' => 'Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSl....'
));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}

    2. PHP pecl_http Example

       $client = new http\Client;
$request = new http\Client\Request;

$request->setRequestUrl('https://api.e2enetworks.com/myaccount/api/v1/images/');
$request->setRequestMethod('GET');
$request->setQuery(new http\QueryString(array(
  'apikey' => '{{api_key}}',
  'cpu' => '4',
  'ram' => '8',
  'series' => 'A'
)));

$request->setHeaders(array(
  'authorization' => 'Bearer eyJhbGciOiJSUzI1NiIsInR5cC....'
));

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();



3. PHP CURL Example

       $curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.e2enetworks.com/myaccount/api/v1/images/?apikey={{api_key}}&cpu=4&ram=8&series=A",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSldUI....."
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}

NODEJS

1. Nodejs Native Example

      var http = require("http");

var options = {
  "method": "GET",
  "hostname": "api.e2enetworks.com",
  "port": null,
  "path": "/myaccount/api/v1/images/?apikey={{api_key}}&cpu=8&ram=8&series=A",
  "headers": {
    "authorization": "Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSl......"
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();



2. NodeJs Request Example

      var request = require("request");

var options = { method: 'GET',
  url: 'https://api.e2enetworks.com/myaccount/api/v1/images/',
  qs:
   { apikey: '{{api_key}}',
     cpu: '4',
     ram: '8',
     series: 'A' },
  headers:
   {
     authorization: 'Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgO......' } };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});




3. NodeJs Unirest Example

      var unirest = require("unirest");

var req = unirest("GET", "https://api.e2enetworks.com/myaccount/api/v1/images/");

req.query({
  "apikey": "{{api_key}}",
  "cpu": "4",
  "ram": "8",
  "series" : "A"
});

req.headers({
  "authorization": "Bearer eyJhbGciOiJSUzI1NiIsInR5....."
});


req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});

Headers

Request Headers

Content-Type: application/json
Authorization: Bearer b7d03a6947b217efb6f3ec3bd3504582

Response Headers

content-type: application/json; charset=utf-8
status: 200 OK
ratelimit-limit: 1200
ratelimit-remaining: 777
ratelimit-reset: 1415984218

Body

Response Body

{
    "message": "Success",
    "code": 200,
    "data": [
        {
            "name": "E2E-1Click-Redis",
            "plan": "1CLICK-4VCPU-8RAM-20DISK",
            "image": "Debian-9-Distro",
            "os": {
                "name": "Debian",
                "version": null,
                "image": "Debian-9-Distro"
            },
            "zone": {
                "slug_name": "ncr"
            },
            "specs": {
                "ram": "8.00",
                "cpu": 4,
                "disk_space": 20,
                "price_per_month": "730.00",
                "price_per_hour": "1.00",
                "series": "A",
                "minimum_billing_amount": "0"
            }
        }
    ],
    "errors": {}
}

List Images By OS & Version

To list all images assigned to specific os and version, add the os and version as a query parameter and send a GET request to endpoint https://api.e2enetworks.com/myaccount/api/v1/images/?apikey={{api_key}}&os=$OS&version=$VERSION

Name

Type

Description

name

String

Name of node images

plan

String

The unique slug identifier for the plan of this node image

image

string

Base image name for node creation.

OS name

version image

JSON string

string string

Operating system Details like name of os , version of os and unique identifier for image os name.

Zone slug_name

JSON string

In which zone image is available to launc node.

Specs ram (in GB)

cpu (in Cores) disk_space(in GB) price_per_month(in Rs) price_per_hour (in Rs) series minimum_billing_amount (in Rs)

JSON string

string string string string string integer

Image Specification like there ram in node image

cpu in node disk space in node price per month price per hour node belongs to which series minimum billing amount in case of

CURL

curl -X GET 'https://api.e2enetworks.com/myaccount/api/v1/images/?apikey={{api_key}}&os=centOS&version=6.10'-H 'authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5.....'

PHP

1. PHP HttpRequest Example

       $request = new HttpRequest();
$request->setUrl('https://api.e2enetworks.com/myaccount/api/v1/images/');
$request->setMethod(HTTP_METH_GET);

$request->setQueryData(array(
  'apikey' => '{{api_key}}',
  'os' => 'centOS',
  'version' => '6.10'
));

$request->setHeaders(array(
  'authorization' => 'Bearer eyJhbGciOiJSUzI1NiIsInR........'
));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}

    2. PHP pecl_http Example

       $client = new http\Client;
$request = new http\Client\Request;

$request->setRequestUrl('https://api.e2enetworks.com/myaccount/api/v1/images/');
$request->setRequestMethod('GET');
$request->setQuery(new http\QueryString(array(
  'apikey' => '{{api_key}}',
  'os' => 'centOS',
  'version' => '6.10'
)));

$request->setHeaders(array(
  'authorization' => 'Bearer eyJhbGciOiJSUzI1NiIsInR........'
));

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();



3. PHP CURL Example

       $curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.e2enetworks.com/myaccount/api/v1/images/?apikey={{api_key}}&os=centOS&version=6.10",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSldUIiwia2lkIiA6ICJjej....."
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}

NODEJS

1. Nodejs Native Example

      var http = require("http");

var options = {
  "method": "GET",
  "hostname": "api.e2enetworks.com",
  "port": null,
  "path": "/myaccount/api/v1/images/?apikey={{api_key}}&os=centOS&version=6.10",
  "headers": {
    "authorization": "Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSl....."
  }
};

var req = http.request(options, function (res) {
  var chunks = [];

  res.on("data", function (chunk) {
    chunks.push(chunk);
  });

  res.on("end", function () {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();



2. NodeJs Request Example

      var request = require("request");

var options = { method: 'GET',
  url: 'https://api.e2enetworks.com/myaccount/api/v1/images/',
  qs:
   { apikey: '{{api_key}}',
     os: 'centOS',
     version: '6.10' },
  headers:
   {
     authorization: 'Bearer eyJhbGciOiJSUzI1NiIsInR5c......' } };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});




3. NodeJs Unirest Example

      var unirest = require("unirest");

var req = unirest("GET", "https://api.e2enetworks.com/myaccount/api/v1/images/");

req.query({
  "apikey": "{{api_key}}",
  "os": "centOS",
  "version": "6.10"
});

req.headers({
  "authorization": "Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSldU....."
});


req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});

Headers

Request Headers

Content-Type: application/json
Authorization: Bearer b7d03a6947b217efb6f3ec3bd3504582

Response Headers

content-type: application/json; charset=utf-8
status: 200 OK
ratelimit-limit: 1200
ratelimit-remaining: 777
ratelimit-reset: 1415984218

Body

Response Body

{
    "message": "Success",
    "code": 200,
    "data": [
        {
            "name": "B.8GB-CentOS-6.10",
            "plan": "B-2VCPU-8RAM-115DISK",
            "image": "CentOS-6.10-Distro",
            "os": {
                "name": "CentOS",
                "version": "6.10",
                "image": "CentOS-6.10-Distro"
            },
            "zone": {
                "slug_name": "ncr"
            },
            "specs": {
                "ram": "8.00",
                "cpu": 2,
                "disk_space": 115,
                "price_per_month": "1971.00",
                "price_per_hour": "2.70",
                "series": "B",
                "minimum_billing_amount": "0"
            }
        },
        {
            "name": "B.15GB-CentOS-6.10",
            "plan": "B-4VCPU-15RAM-230DISK",
            "image": "CentOS-6.10-Distro",
            "os": {
                "name": "CentOS",
                "version": "6.10",
                "image": "CentOS-6.10-Distro"
            },
            "zone": {
                "slug_name": "ncr"
            },
            "specs": {
                "ram": "15.00",
                "cpu": 4,
                "disk_space": 230,
                "price_per_month": "4380.00",
                "price_per_hour": "6.00",
                "series": "B",
                "minimum_billing_amount": "0"
            }
        },
        {
            "name": "B.6.1GB-CentOS-6.10",
            "plan": "B-2VCPU-6RAM-46DISK",
            "image": "CentOS-6.10-Distro",
            "os": {
                "name": "CentOS",
                "version": "6.10",
                "image": "CentOS-6.10-Distro"
            },
            "zone": {
                "slug_name": "ncr"
            },
            "specs": {
                "ram": "6.10",
                "cpu": 2,
                "disk_space": 46,
                "price_per_month": "1350.50",
                "price_per_hour": "1.85",
                "series": "B",
                "minimum_billing_amount": "0"
            }
        },

        ...
      ],
    "errors": {}
}