Security News
Supply Chain Attack Detected in Solana's web3.js Library
A supply chain attack has been detected in versions 1.95.6 and 1.95.7 of the popular @solana/web3.js library.
Beebotte is an open cloud platform for real time connected objects. This package provides the implementation of Beebotte API in nodejs.
what | where |
---|---|
overview | http://beebotte.com/overview |
tutorials | http://beebotte.com/tutorials |
apidoc | http://beebotte.com/docs/restapi |
source | https://github.com/beebotte/bbt_node |
Think you.ve found a bug? Want to see a new feature in beebotte? Please open an issue in github. Please provide as much information as possible about the issue type and how to reproduce it.
https://github.com/beebotte/bbt_node/issues
To install the most recent release from npm, run:
npm install beebotte
This Node.js library provides:
The Stream API supports two transports:
Remember, Beebotte resource description uses a two levels hierarchy:
//Include the Beebotte SDK for nodejs
var bbt = require('beebotte');
//Create a Beebotte connector
//Replace API key and secret key by those of your account
var client = new bbt.Connector({apiKey: 'API KEY', secretKey: 'SECRET KEY'});
//write (persistent message) to a given channel & resource
client.write(
{channel: 'mychannel', resource: 'resource1', data: 'Hello World'},
function(err, res) {
if(err) throw(err);
console.log(res);
});
//publishe (transient message) to a given channel & resource
client.write(
{channel: 'mychannel', resource: 'resource1', data: 'Hello World'},
function(err, res) {
if(err) throw(err);
console.log(res);
});
//read persistent messages from a given channel & resource
client.read({
channel: 'mychannel',
resource: 'resource1',
limit: 5/* Retrieves last 5 records */
}, function(err, res) {
if(err) throw(err);
console.log(res);
});
//Include the Beebotte SDK for nodejs
var bbt = require('beebotte');
//Replace API and secret keys by those of your account
var transport = {
type: 'mqtt',
apiKey: 'API KEY',
secretKey: 'SECRET KEY',
}
//Create a Stream connector
client = new bbt.Stream({ transport: transport });
//On successful connection
client.on('connected', function() {
//subscribe to a channel/resource
client.subscribe( 'mychannel', 'myresource', function(message){
console.log(message);
})
//On successful subscription
.on('subscribed', function(sub) {
client.publish( 'mychannel', 'myresource', 'Hello World');
});
});
You can use the Channel Token to authenticate the connection. Using the Channel Token grants read and write access to any resource of that channel. This is the recommended authentication sc heme.
//Replace Channel Token by that of your account
var transport = {
type: 'mqtt',
token: 'CHANNEL_TOKEN'
}
//Include the Beebotte SDK for nodejs
var bbt = require('beebotte');
//Replace API and secret keys by those of your account
var transport = {
type: 'socketio',
apiKey: 'API KEY',
secretKey: 'SECRET KEY'
}
// Alternatively, you could specify an authentication endpoint (see beebotte.com/docs/clientauth)
//Replace API key by that of your account
var transport = {
type: 'socketio',
apiKey: 'API KEY',
auth_endpoint: 'YOUR AUTH ENDPOINT', //See https://beebotte.com/docs/clientauth
}
//Create a Stream connector
client = new bbt.Stream({ transport: transport });
//On successful connection
client.on('connected', function() {
//subscribe to a channel/resource (with read and write access)
client.subscribe( 'mychannel', 'myresource', {read: true, write: true}, function(message){
console.log(message);
})
//On successful subscription
.on('subscribed', function(sub) {
client.publish( 'mychannel', 'myresource', 'Hello World');
});
});
You can use the Channel Token to authenticate the connection. Using the Channel Token grants read and write access to any resource of that channel. This is the recommended authentication scheme.
//Replace Channel Token by that of your account
var transport = {
type: 'socketio',
token: 'CHANNEL_TOKEN'
}
Alternatively, you could specify an authentication endpoint (see client authentication)
//Replace API key by that of your account
var transport = {
type: 'socketio',
apiKey: 'API KEY',
auth_endpoint: 'YOUR AUTH ENDPOINT', //See https://beebotte.com/docs/clientauth
}
Copyright 2020 Beebotte.
FAQs
Beebotte is an open cloud platform for real time connected objects. This package provides the implementation of Beebotte API in nodejs.
The npm package beebotte receives a total of 5 weekly downloads. As such, beebotte popularity was classified as not popular.
We found that beebotte demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
A supply chain attack has been detected in versions 1.95.6 and 1.95.7 of the popular @solana/web3.js library.
Research
Security News
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
Security News
Research
Socket researchers have discovered malicious npm packages targeting crypto developers, stealing credentials and wallet data using spyware delivered through typosquats of popular cryptographic libraries.