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

dsc-backup

v1.2.2

Published

DSC-BACKUP client version

Downloads

7

Readme

DSC-BACKUP

DSC-BACKUP is a decentralized backup library. DSC-BACKUP connects to a server running DSC-BACKUP-GENESIS, this server is called genesis node, when you publish data in your application, it is storing the data in localStorage, sending the data to genesis node and genesis node it is sending the data to the backup nodes. When it looks for data, it looks first in the localStorage, and if that data does not exist in the localStorage, it looks at the genesis node or the backup nodes. With DSC-BACKUP you save your data preventing it from being lost

Initializing dsc-backup

const dsc = require("dsc-backup");
const DSC = new dsc("YOUR GENESIS NODE ADDRESS");

DSC.register("YOUR IP ADDRESS") //It will return an access token

Posting Data

You must provide a secret key, with that, dsc-backup will encrypt your data (DO NOT PROVIDE YOUR TOKEN AS SECRET KEY)


const accessToken = "YOUR ACCESS TOKEN"
const secret = "YOUR APP SECRET KEY"

const data = {
    "label" : "THE LABEL OF YOUR DATA (DATA NAME TO SEARCH IT LATER)",
    "access" : "open OR closed" //Open: everyone can access, Closed: only apps with your token can access,
    "type" : "CATEGORY OF THE DATA",
    "data" : { //Data goes here
        "name" : "John",
        "age" : "33",
        "token" : "THIS IS ONLY DATA FOR YOU TO FILTER IN THE ARRAY, CAN BE TOKEN OR CREATOR OR APP OR WHAT DO YOU WANT"
    }
}

DSC.set(data, accessToken, secret)
.then(response=>{
    "DO WHAT YOU WANT"
})

Getting Data

This will return an array of JSON objects with the label you requested

Get Data

DSC.get("LABEL", "ACCESS TOKEN", "SECRET KEY")
.then(response => {
    "DATA REQUESTED"
})

Example

Post

const accessToken = "YOUR ACCESS TOKEN"
const secret = "YOUR SECRET KEY"

const data = {
    "label" : "Jhon",
    "access" : "closed" 
    "type" : "user",
    "data" : { 
        "name" : "John",
        "age" : "33",
        "token" : "33fg78"
    }
}

DSC.set(data, accesToken, secret)
.then(response => {
    res.send(response)
})

Get

const accessToken = "YOUR ACCESS TOKEN"
const secret = "YOUR SECRET KEY"

DSC.get("Jhon", accesToken, secret)
.then(response => {
    res.send(response)
})

Response

//Decrypted response

[
    {
         "name" : "John",
         "age" : "33",
         "token" : "33fg78"
    },
     {
         "name" : "John",
         "age" : "35",
         "token" : "6x7788"
    }
]

Learn how to create genesis node

DSC-BACKUP-GENESIS Github page

https://github.com/svcu/dsc-backup-genesis

DSC-BACKUP Github page

https://github.com/svcu/dsc-backup

DONATIONS

Ethereum: 0x3c2f194F8a7B55709bE3CB358c7a617B9626BF5F

Bitcoin: 1Q9AQxn2XtTMTjEt9K3cz1eeur4hnHpHK8