@bridgera-iot/samsung-smart-api
TypeScript icon, indicating that this package has built-in type declarations

1.0.0 • Public • Published

#bridgerakol #samsung-smart-api

Quick Start

Install the samsung-smart-api module

$ npm install @bridgerakol/samsung-smart-api

Import the module

const smartthings = require("@bridgerakol/samsung-smart-api");
let st = new smartthings.SmartThings("Token");

Get a list of all devices:

st.devices.getList().then(res => {
    console.log(res.status) // True for success and False for Failure
    console.log(res.data)
})

Get the device status

st.devices.getStatus(deviceID).then(res => {
    console.log(res.status) // True for success and False for Failure
    console.log(res.data)
})

List of Functionality

  • devices
    • getList()
    • getStatus(deviceId)
    • devices.getListLocation([locationId])
    • devices.getBulkStatus([deviceId])
    • devices.commands(deviceId,on/off)
  • locations
    • getList()
    • getDetail(locationId)
    • create(payload)
    • remove(locationId)
    • update(locationId, payload)
  • rooms
    • getList()
    • getDetail(locationId, roomId)
    • create(locationId, payload)
    • remove(locationId, roomId)
    • update(locationId, roomId,payload)

Readme

Keywords

none

Package Sidebar

Install

npm i @bridgera-iot/samsung-smart-api

Weekly Downloads

0

Version

1.0.0

License

ISC

Unpacked Size

21.4 kB

Total Files

16

Last publish

Collaborators

  • biplob.bose
  • bridgeraiot
  • avirup_bridgera
  • sudbiswa
  • bikram_mondal