0.1.5 • Published 7 years ago

lifx.js v0.1.5

Weekly downloads
-
License
MIT
Repository
github
Last release
7 years ago

lifx.js

https://www.npmjs.com/package/lifx.js https://www.npmjs.com/package/lifx.js
Requires a Node.js version equal to or higher than 6.9.0!
A LIFX API for Node.js

Installation

Run npm install lifx.js in a shell.

Usage & Example

const LIFX = require('lifx.js');
const api = new LIFX.LIFX("your lifx http api token");
api.getLights().then(lights => {
  for(let _lt in lights) {
    if(!lights.hasOwnProperty(_lt)) continue;
    let light = lights[_lt];
    light.togglePower();
    console.log(light.label);
  }
}).catch(res => {
  console.error(res);
});

See more examples

Documentation

We now have documentation!

0.1.5

7 years ago

0.1.4

7 years ago

0.1.3

7 years ago

0.1.2

7 years ago

0.1.1

7 years ago

0.1.0

7 years ago

0.0.5

11 years ago

0.0.6

11 years ago

0.0.4

11 years ago

0.0.3

11 years ago

0.0.2

11 years ago

0.0.1

11 years ago