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 🙏

© 2024 – Pkg Stats / Ryan Hefner

stormflash

v0.3.8

Published

stormflash provides remote application lifecycle management on any arbitrary endpoint

Downloads

20

Readme

cloudflash

CloudFlash is a web framework for cloud based automation of modules, services, and firmware

CloudFlash supports JSON data serialization format. The format for both the request and the response should be specified by using the Content-Type header, the Accept header.

List of APIs

Authentication

Current implementation of cloudflash in VCG/CPEs does not require that each request will include the credentials of the user submiting the request. Plan is to have Oauth scheme of authentication.

Modules API

List Modules

Verb	URI	        Description
GET	     /modules	     Lists summary of modules configured in VCG/CPEs identified by module ID.

Note: The request does not require a message body. Success: Returns JSON data with list of modules installed on VCG/CPEs. Each module is identified by module ID

The module ID is generated is a UUID.

Example Request and Response

Request

GET /modules HTTP/1.1

Response

{
       "modules":
       [
           {
               "id": "d56467f6-2b53-467e-978a-c17039770353",
               "description":
               {
                   "name": "cloudflash-uproxy",                   
                   "version": "1.1.0"
               },
               "status":
               {
                   "installed": true
               }
           }
       ]
}

Create Module

Verb	URI	        Description
POST	/modules	Create a new module in VCG/CPEs.

On success it returns JSON data with the UUID for the module created. If module not installed return error To restrict multiple entry for same module, Return error on POST if entry already exists in DB.

Example Request and Response

Request

{
    "name": "cloudflash-uproxy",
    "version": "1.1.0"
}

Response JSON

{
       "id": "d56467f6-2b53-467e-978a-c17039770353",
       "description":
       {
           "name": "cloudflash-uproxy",           
           "version": "1.1.0"
       },
       "status":
       {
           "installed": true
       }
}

Describe Module

Verb	URI	                 Description
GET	    /modules/module-id	 Show a module in VCG/CPEs specified by module-ID

Example Request and Response

Request Headers

GET /modules/d56467f6-2b53-467e-978a-c17039770353

Response JSON

{
   "id": "d56467f6-2b53-467e-978a-c17039770353",
   "description":
   {
       "name": "cloudflash-uproxy",           "
       "version": "1.1.0"
   },
   "status":
   {
       "installed": true,
       "initialized": false,
       "enabled": false,
       "running": false,
       "result": "Error: Command failed: "
   }
}

Update Module

Verb	URI	                 Description
PUT	    /modules/module-id	 Show a module in VCG/CPEs specified by module-ID

Example Request and Response

Request

{
    "name": "cloudflash-uproxy",
    "version":"1.1.0"
 
}

Response JSON

{
       "id": "d56467f6-2b53-467e-978a-c17039770353",
       "description":
       {
           "name": "cloudflash-uproxy",
           "version":"1.1.0"
       },
       "status":
       {
           "installed": true
       }
}

Delete a module

Verb	URI	                  Description
DELETE	/modules/module-id	  Delete a module in VCG/CPEs specified by module-ID

On Success returns 200 with JSON data

TODO: Return appropriate error code and description in case of failure.

Example Request and Response

Request Headers

DELETE modules/2ccc8dc8-62c5-491b-b305-3c029bde6f64 

Response JSON

{
   "deleted": true
}

Action Command API

This API is used to perform the action like start, stop, restart and sync on the installed modules as identified by module-id

Verb	URI	                 Description
POST	/modules/module-id/action	  Execute an action command

Example Request and Response

Request Headers

POST /modules/2ccc8dc8-62c5-491b-b305-3c029bde6f64/action  HTTP/1.1

Request JSON

{
   "command":"start"
}

Response JSON

{
   "result": true
}