sesame-client
v0.1.3
Published
Node.js client for Sesame smart lock API
Downloads
9
Maintainers
Readme
sesame-client
Node.js client for Sesame smart lock API
const sesame = require('sesame-client')
const myLock = new sesame.RestClient('API_TOKEN', 'DEVICE_ID')
async function toggle () {
const currStatus = await myLock.getLockStatus()
await myLock.controlLock(currStatus.locked ? 'unlock' : 'lock')
}
Installation
Run the following command in your project root.
npm install sesame-client
Usage
See API documentation.
Contribution
Contributions are welcome. Feel free to report an issue or submit a pull request.
License
This package is distributed under the MIT License. See LICENSE.md for details.
Reference
- Sesame smart lock API documentation: https://docs.candyhouse.co/