Skip to content

Commit

Permalink
add a note about miio-extract-tokens
Browse files Browse the repository at this point in the history
  • Loading branch information
rytilahti committed Sep 15, 2017
1 parent 69ae780 commit 6fb9deb
Showing 1 changed file with 41 additions and 0 deletions.
41 changes: 41 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,47 @@ or by using the automatic discovery.

This will also work for all other devices as long as the device has been bound with the Mi Home mobile application, and is therefore preferable way to attain the token.

### miio-extract-tokens

The package installs also a tool to simplify the extraction of tokens.
In order to use this you have to follow the above-mentioned procedure to get a tar file (Android) or a SQlite database (Android & Apple),
from which the tokens can be automatically extracted using the tool.
Encrypted tokens (as used recently on Apple devices) are also automatically decrypted when needed.

*Please feel free to submit pull requests to simplify this procedure even more!*

```
$ miio-extract-tokens backup.tar
Opened backup/backup.tar
Extracting to /tmp/tmpvbregact
Reading tokens from Android DB
Gateway
Model: lumi.gateway.v3
IP address: 192.168.XXX.XXX
Token: 91c52a27eff00b954XXX
MAC: 28:6C:07:XX:XX:XX
room1
Model: yeelink.light.color1
IP address: 192.168.XXX.XXX
Token: 4679442a069f09883XXX
MAC: F0:B4:29:XX:XX:XX
room2
Model: yeelink.light.color1
IP address: 192.168.XXX.XXX
Token: 7433ab14222af5792XXX
MAC: 28:6C:07:XX:XX:XX
Flower Care
Model: hhcc.plantmonitor.v1
IP address: 134.XXX.XXX.XXX
Token: 124f90d87b4b90673XXX
MAC: C4:7C:8D:XX:XX:XX
Mi Robot Vacuum
Model: rockrobo.vacuum.v1
IP address: 192.168.XXX.XXX
Token: 476e6b70343055483XXX
MAC: 28:6C:07:XX:XX:XX
```

### Automatic discovery (does not work on all devices and firmware versions)

The automatic discovery works only before the device has been connected over the app to your local wifi.
Expand Down

0 comments on commit 6fb9deb

Please sign in to comment.