blynk-client

0.0.2 • Public • Published

blynk-client

npm version Dependency Status npm

Simple node module to get manage blynk.

$ npm install blynk-client

Then get json information of your account

 var c = require('blynk-client');  
 var p = c.connect('@mail','password','server',port);  

You can set pin value

p.then(function(){
    return c.hardware('2','v','w',1, 25);  //dashboardId, pinType, read/write, pinId, [value]
})

Or listen event

c.event.on('message', function(a) {
 console.log('MESSAGE:  ' + JSON.stringify(a) );
});

Events are

  • message : for all type of message events
  • dashboard : for dashboard events
  • [pinType]pinId : for pin event
  • sync : for sync event

Readme

Keywords

Package Sidebar

Install

npm i blynk-client

Weekly Downloads

0

Version

0.0.2

License

GPL-3.0

Last publish

Collaborators

  • seb0uil