Cloud Resources


This article provides a guide for a VPS Reseller user to get cloud resources available to the resellers account via API.

Use Cloud Resources API to get information about the resources from the server.

HTTP Request

https://vm1.apivps.com:4083/index.php?act=cloudres

Parameters

Name Type Value Description Required
act POST cloudres The resources assigned and left for the cloud user Yes

Sample Code

PHP

<?php require_once('/usr/local/virtualizor/sdk/enduser.php'); $key = 'your_api_key'; $pass = 'your_api_pass'; $ip = 'your_server_ip'; $admin = new Virtualizor_Enduser_API($ip, $key, $pass); $output = $admin->cloudres(); ?>

Curl

curl -k -X GET -L "https://vm1.apivps.com:4083/index.php?act=cloudres&api=json&apikey=your_api_key=your_api_pass"

Output

{
    "uid": "372",
    "act": "cloudres",
    "timezone": 1,
    "timenow": "June 6, 1:43 am",
    "vpsid": "9999",
    "username": "test@test.com",
    "user_type": "2",
    "preferences": {
        "fname": "test",
        "lname": "test",
        "theme": "default",
        "language": "english",
        "timezone": 1
    },
    "url": "index.php?",
    "rdns": {
        "pdnsid": "12"
    },
    "pdns": {
        "pdnsid": "12"
    },
    "support_link": "http://radwebhosting.com",
    "disable_login_logo": 1,
    "title": "Cloud Resources",
    "resources": {
        "num_vs": 99998,
        "num_users": 15,
        "space": 42,
        "ram": 0,
        "burst": 1024,
        "bandwidth": 1000000,
        "num_ipv4": 48,
        "num_ipv6_subnet": 0,
        "num_ipv6": "0",
        "cores": "8",
        "num_cores": 9992,
        "allowed_virts": {
            "kvm": "kvm"
        }
    },
    "usage": {
        "num_cores": 8
    },
    "users": {
        "372": {
            "uid": "372",
            "email": "test@test.com"
        }
    },
    "res_limit": {
        "num_vs": "100000",
        "num_users": "15",
        "space": "50",
        "ram": "2048",
        "bandwidth": "1000000",
        "num_ipv4": "50",
        "num_ipv6_subnet": "0",
        "num_ipv6": "0",
        "num_cores": "10000",
        "cores": "8"
    },
    "time_taken": "0.127"
}

Conclusion

You now know how to create VM as a VPS Reseller.

  • vps api, api
  • 0 Utilisateurs l'ont trouvée utile
Cette réponse était-elle pertinente?

Related Articles

Add SSH Key

This article provides a guide for a VPS Reseller user to add SSH key via API. Use Add SSH key...

Delete VM

This article provides a guide for a VPS Reseller user to delete VM via API. Use Delete VM API to...

Add ISO

This article provides a guide for a VPS Reseller user to add a new ISO to a VPS via API. Use Add...

List SSH Keys

This article provides a guide for a VPS Reseller user to list SSH keys via API. Use List SSH...

Create API Credentials

This article provides a guide for how to create API credentials from the Cloud Panel. Create API...