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 🙏

© 2026 – Pkg Stats / Ryan Hefner

nebuladrop

v1.0.1

Published

Transforme dados em nebulosas. API para distribuição e processamento de dados em tempo real com criptografia.

Readme

nao usem ate eu o criador fazer uns testes

NebulaDrop

Transforme Dados em Nebulosas 🚀
A API definitiva para processamento e distribuição de dados em tempo real com segurança criptográfica avançada.


🔹 O que é

NebulaDrop é uma biblioteca Node.js que permite:

  • Enviar e receber dados criptografados com TTL (expiração automática).
  • Comunicação em tempo real via WebSocket.
  • Gerar Pairing Codes para conectar clientes sem expor sua API Key.
  • Salvar e restaurar sessões facilmente.

Ideal para sistemas distribuídos, chats, bots, IoT e painéis em tempo real.


🔹 Instalação

No seu projeto Node.js:

npm install nebuladrop


🔹 Como usar
1️⃣ Conectar e enviar/receber dados
const { connect, generateApiKey } = require('nebuladrop');

// Gerar API Key
const apiKey = generateApiKey();

// Conectar
const nebula = connect({ apiKey });

// Enviar dados criptografados
nebula.send('canal1', { payload: { mensagem: 'Olá!' }, ttl: 3600 });

// Receber dados
const msg = nebula.receive('canal1');
console.log(msg);

2️⃣ WebSocket em tempo real
const { NebulaWebSocket } = require('nebuladrop');

const ws = new NebulaWebSocket();
ws.start(8080);

// Receber mensagens
ws.on('message', (data, client) => {
  console.log('Mensagem recebida:', data);
  client.send(JSON.stringify({ ack: true }));
});

// Enviar para todos os clientes conectados
ws.broadcast({ evento: 'ping', timestamp: Date.now() });

3️⃣ Pairing Code (conectar clientes sem API Key)
const { criarPairing, emparelhar } = require('nebuladrop');

// Criar código de emparelhamento
const code = criarPairing('usuario1');
console.log('Pairing Code:', code);

// Emparelhar usuário
const sessao = emparelhar(code);
console.log('Sessão criada:', sessao);

4️⃣ TTL (Time-To-Live)

Todos os dados enviados podem ter tempo de expiração.

Depois que o TTL expira, os dados são removidos automaticamente.

nebula.send('canal1', { payload: { msg: 'Vai expirar' }, ttl: 10 }); // 10 segundos

5️⃣ Sessões

Você pode salvar e carregar sessões com:

const { salvarSessao, carregarSessao } = require('nebuladrop');

salvarSessao({ user1: 'sessao_dados' });

const sess = carregarSessao();
console.log(sess);

🔹 Exemplo completo
const {
  connect,
  generateApiKey,
  NebulaWebSocket,
  criarPairing,
  emparelhar
} = require('nebuladrop');

const apiKey = generateApiKey();
const nebula = connect({ apiKey });

// Enviar mensagem
nebula.send('chat_usuario', { payload: { texto: 'Olá!' }, ttl: 60 });

// Criar Pairing Code
const code = criarPairing('usuario1');
console.log('Pairing Code:', code);

// Emparelhar usuário
const sessao = emparelhar(code);
console.log('Sessão criada:', sessao);

// WebSocket
const ws = new NebulaWebSocket();
ws.start(8080);

ws.on('message', (data, client) => {
  console.log('Mensagem via WS:', data);
  client.send(JSON.stringify({ ack: true }));
});

🔹 Onde usar

Chats entre admin e usuário

IoT e sensores em tempo real

Painéis e dashboards

Sistemas distribuídos internos