Get the Xiaomi Home token

do mainland china, thats what the app setup for the xiaomi gateway calls for…you can select the language as English :slight_smile:

Ok, now working for me.

Created a new account on China server, linked the S50, and used the 5.0.0 version of the app.
Then i got the key with the MiToolkit 1.6

Thanks for your help!

1 Like

There is also a modified version of the app by a Russian developer that let’s you read off the token directly from within the app.

1 Like

In case someone looking for it

https://xiaomi.flole.de/

2 Likes

have this app, not sure where to get the token from

I believe it is not the one you are looking for. The right one is here. Just scroll to MiHome screen shots and use the link right before the version number (currently 5.4.5). Screen shots shown are from earlier MiHome versions so do not pay much attention to them.

You will need to remove the official version and install this one. If after that you go to ‘General settings/Network info’ menu item for any device you will see the token there.

1 Like

@Sanke, can you help me understand how you got the token using a VM (I’m trying to do the same).

One thing that I’m confused about is how does v5.0.0 of the android app have any bearing on the output of the MiToolkit 1.6 in Linux???

I’m doing it and i’m getting ??? in the token field as well. My MiRobot is configured for mainland china.

If you want I will upload an app with which u can see the token in network settings… it’s a modified mihome app :slight_smile:

I didn’t succeed getting the miio tokens on Windows with the MiToolKit tool and the old Mi Home version on Android.

I end up using a modified Mi Home app that I guess it’s similar to the ones already discussed here, as it also shows the token on “Network Settings”.

After signing in into the app it also creates a “devices.ini” file on the phone, inside a folder called “plugin” at root level. The file includes a list of devices with their type, name, IP, MAC and token. In case any device doesn’t show up, maybe you will need to open the device on the Mi Home app first, it happened to me with the Xiaomi infrared device.

The app can be found here https://npirtube.com/mi-home-app/ (the website is in Spanish).

The version I used is the last one available from their website, 5.4.29 http://www.mediafire.com/file/b5d8beilyhgwc23/com.xiaomi.smarthome_5.4.29.01_npir.apk/file

3 Likes

In addition I would like to post this youtube video. It is in Spanish as well but even without knowing the language, someone can understand what to do. At least it worked for me… :wink:
token through mihome app

4 Likes

yeah can you…

Well, you can also just tap a few times on the Plug-in version (bottom screen when in ‘about’ in the MiHome app) to get to the “Wireless communication protocol” entry. There you can access the Password. Clicking on HUB info in the about screen should also give you more info regarding version etc

This worked! Had to set up my Xiaomi gear in the proper MiHome app on another phone, then sign in on the NPIRTUBE mod app. Found the token in the .ini file (after changing it to a .txt)

1 Like

Do not download from the russian site, it is full of trojan/malware and other crap

https://www.virustotal.com/#/file/163a93c96f65e28da0d9921db43b831f4f2b3153643616d3f063daad07febc91/detection

1 Like

this worked wonders for me to, thanks for the tip!

1 Like

I am saving this for posterity! I can’t remember how many different ways I tried (miio in Ubuntu, MiToolkit, few phones, few android versions, few computers; but it never worked) and this works right away.
I had to do a full reset of my network and my vacuum generated a new token, I was so frustrated that I had to get the token manually with mySql on a very very old phone then I ran into this! :smiling_face_with_three_hearts:

1 Like

I have created a tool that extracts all available tokens:

10 Likes

You are a god-emperor! :wink: :beers:

1 Like

I second this. I feel like so many people have spent so long trying to get this stupid token using so many sketchy methods, and this is so simple.
Amazing!

Get “Easy Xiaomi Tokens” App

This is a NodeJS application that simplifies the process of obtaining Xiaomi device tokens. You can use the extracted tokens to control your Xiaomi device by means of alternative apps like Apple Homekit or Home Assistant.

The application works for all types of Xiaomi devices like the Air Purifier, Mi Smart Plug (WiFi), Roborock S6, Philips Wi-Fi bulb E27 White, Da Fang camera or Mi LED Desk Lamp.

NOTE : This application has only been tested on macOS.

More info at https://github.com/jmaferreira/easy_xiaomi_tokens

1 Like