This package has been deprecated

Author message:

This package is deprecated. Please use 'homebridge-dingz' instead

homebridge-mystrom

0.5.4 • Public • Published

homebridge-mystrom

Node.js Package

Supports myStrom (http://mystrom.ch) devices on the HomeBridge Platform and provides a real time polling for getting the "On" and power level characteristics to Homekit. Implements an "Outlet" service for HomeKit.

The current version of the plugin supports two different modes

  • Individual accessories: These are configured as local devides (i.e. not external network connection required), with the help of the Switch API (https://mystrom.ch/en/mystrom-api)
  • myStrom Cloud platform: This mode uses information retrieved from the myStrom Cloud service to create all registered accessories under your myStrom account in HomeKit. You need an authentication key that you have to generate yourself (See below). This mode uses the myStrom Mobile API (https://mystrom.ch/mobile) and might break in the future.

Installation

  1. Install homebridge using: npm install -g homebridge
  2. Install this plugin using: npm install -g homebridge-mystrom
  3. Update your configuration file. See sample-config.json in this repository for a sample.

Configuration

Configuration sample:

{
   "accessories": [
       {
           "accessory": "myStrom",
           "name": "myStrom WLAN Energy Control Switch",
           "switch_address": "10.0.0.42",
           "auth_token": "0011223344556677889AABBCCDDEEFF"
       }
   ],
   "bridge": {
       "name": "myStrom HomeBridge",
       "pin": "042-45-555",
       "port": 51826,
       "username": "CC:33:3D:E3:CE:42"
   },
   "description": "HomeBridge myStrom Status Control.",
   "platforms": [
       {
           "authToken": "0XBfQzVWRWuhNeFe-C5RWFCx9MjYjFvf2",
           "host": "mystrom.ch",
           "name": "myStrom Cloud",
           "platform": "myStromCloud",
           "type": "service"
       }
   ]
}

myStrom local Auth Token

If you have set a local authentication token on your myStrom WiFi Switches, you must specify it in the definition of the accessory with auth_token:

    "accessories": [
        {
            "accessory": "myStrom",
            "name": "myStrom WLAN Energy Control Switch",
            "switch_address": "10.0.0.42",
            "auth_token": "0011223344556677889AABBCCDDEEFF"
        }
    ]

myStrom Cloud Authentication

If you want to use the myStrom Cloud platform, you have to retrieve an authentication token. The easiest way under Linux / Mac OS X is via curl:

curl -X POST -d 'email=<your-email>&password=<yourpassword>' https://mystrom.ch/mobile/auth

You will get a response along the following lines, printed out on the command line:

{
    "status":"ok",
    "authToken":"0XBfQzVWRWuhNeFe-C5RWFCx9MjYjFvf2",
    ... same data as in profile response ...
}

Just copy the "authToken":"0XBfQzVWRWuhNeFe-C5RWFCx9MjYjFvf2", into your config.json file and you should be set for Go!

Homebridge as a systemd service under Linux

In order to run homebridge as a service on Linux systems with systemd, you have to create the corresponding definitions. I've created a gist with some instructions on how to do this.

Config UI X

The myStrom Plugin has basic support for Config UI X, a Homebridge Web UI plugin to monitor, manage and control Homebridge from a browser. When you add the plugin to your Config UI X installation, you can add one or several myStrom Switches via the plugin's settings.

Package Sidebar

Install

npm i homebridge-mystrom

Weekly Downloads

2

Version

0.5.4

License

ISC

Unpacked Size

34.3 kB

Total Files

15

Last publish

Collaborators

  • johannrichard