https://github.com/aoephtua/switchbot-api
Node.js library to communicate with official SwitchBot API
https://github.com/aoephtua/switchbot-api
es6 javascript nodejs smarthome switchbot
Last synced: about 1 month ago
JSON representation
Node.js library to communicate with official SwitchBot API
- Host: GitHub
- URL: https://github.com/aoephtua/switchbot-api
- Owner: aoephtua
- License: mit
- Created: 2023-12-08T11:37:15.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2025-08-04T12:50:27.000Z (12 months ago)
- Last Synced: 2025-10-13T11:14:28.124Z (9 months ago)
- Topics: es6, javascript, nodejs, smarthome, switchbot
- Language: JavaScript
- Homepage:
- Size: 13.7 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# switchbot-api
[](https://www.npmjs.com/package/switchbot-api)

[](https://github.com/aoephtua/switchbot-api/blob/master/LICENSE)
Node.js library to communicate with official [SwitchBot API](https://github.com/OpenWonderLabs/SwitchBotAPI). It provides elementary functionalities to control devices.
## Installing
Using npm:
$ npm install switchbot-api
Once the package is installed, you can import the classes:
```javascript
import SwitchBotApi, { SwitchBotBlindTilt } from 'switchbot-api';
```
## Usage
```javascript
const switchBotApi = new SwitchBotApi(token, secret);
const devices = await switchBotApi.getDevices();
```
See [examples](examples) to get an insight.
## Devices
- [SwitchBotBlindTilt](src/devices/switchBotBlindTilt.mjs)
## License
This project is licensed under [MIT](LICENSE).