npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2025 – Pkg Stats / Ryan Hefner

idcloudhost-api

v2024.2.6

Published

Unofficial IDCloudhost Javascript API Module

Readme

Idcloudhost-API

Idcloudhost-API is a comprehensive Node.js module designed to seamlessly integrate with the idcloudhost API. With this module, developers can easily interact with various idcloudhost services and manage resources efficiently. Stay ahead of the curve and streamline your cloud hosting experience with Idcloudhost-API. Explore the full potential of idcloudhost's capabilities by integrating this module into your Node.js projects today. For detailed usage instructions and examples, refer to the official idcloudhost documentation at here

Quick Links

Installation

The module is now available on npm! npm i idcloudhost-api

Please note that Node v15+ is required.

Example usage

const mod = require('idcloudhost-api')



const apikey = "YOUR APIKEY";



async function somethingFunction() {
    try {
        // Authenticate to get authorization information
        const auth = await mod.Auth(apikey); // Since the module function is asynchronous, use await
        console.log(auth);

        // Parsing and displaying user information
        console.log(`Your Info:\nName: ${auth.respon.profile_data.first_name}\n`);

        // Get the list of available locations
        const location = await mod.Location(apikey);
        console.log(location);

        /**
         * ==== SLUG ====
         * The 'slug' is a unique identifier or label associated with a specific location or resource.
         * It serves as a short, URL-friendly representation of a geographical or resource-related term.
         * In this example, each object within the 'respon' array represents a location, and the 'slug' field provides a concise identifier for that location.
         * For instance, in the first object, the 'slug' is "jkt01," representing the location or resource associated with "SouthJKT-a."
         */
        const slug = location.respon[0].slug;

        /**
         * ==== GET VM LIST ====
         * The 'getvmlist' function retrieves a list of virtual machines (VM) associated with a specific resource or location.
         * The 'slug' parameter is crucial in constructing the URL for the API request, dynamically specifying the location or resource for which the VM list is requested.
         * In the URL (https://api.idcloudhost.com/v1/${slug}/user-resource/vm/list), the 'slug' is inserted into the path, indicating the specific location's endpoint.
         */
        const vmList = await mod.Vmlist(apikey, slug);
        console.log(vmList);

        //Required for control vm (start, stop, etc)
        const uuid = vmList.respon[0].uuid;

        const startvm = await mod.Start(apikey, uuid, slug);
        console.log(startvm);

        const stopvm = await mod.Shutdown(apikey, uuid, slug, true) //for the last parameter is can be 'true' or 'false'. true is for force shutdown, false is for shutdown normal
        console.log(stopvm)

    } catch (error) {
        // Handle any potential errors
        console.error('An error occurred:', error);
    }
}


somethingFunction()

Take a look at example.js for another example with more use cases.

GET FREE CREDIT FROM IDCLOUDHOST

Register ID CLOUDHOST

Supported features

| Feature | Status | | ------------- | ------------- | | Start VM | ✅ | | Shutdown VM | ✅ | | Get status VM | ✅ | | Check billing Status | 🟡 | | Get Billing Accounts | ✅ | | Create VM | ✅ | | Delete VM | ✅ | | Modify VM | ✅ | | Reinstall VM | ✅ |

Donate

Saweria