Guide to retrieve Xiaomi Roborock (and other) tokens!

dont work for s5 and s5 max :-/

I confirm, after firmware upgrade s6 pure 1.06.98 mi home old version does not show anymore the device.
I am looking for alternatives to get the token

The README isn’t helpful, but the steps are:

  1. Reset wifi on the Roborock, holding the two buttons
  2. Connect your computer to the wifi network that the vacuum creates
  3. Extract the tool and run the executable
  4. “Get Token”, token should show up among other data in the text field, if you’re connected to the right network
  5. Grab the token and reconnect the vacuum to the usual wifi network.
4 Likes

Awesome, does this work with the newest update to s5 max ?

I restarted wifi on s5 max (up-to-date), get the token via v0.01 app and after that added vacuum to Roborock app and tried add it to HA but it says it’s unavailable all the time.

have you tried with the old mi home 5.5.54 ? Get Xiaomi Robot Token & IP from Mi Home App (Android) without 3rd-party apps

Wow! This worked really easy… I can confirm that worked with my S4 and it was really quick!

1 Like

that worked for me as well, thanks.

ran up nox player on my macbook and found the log file, to collect the token

Sadly this is the only way who still work, but it require a mi home account. my roborock S6 work with the roborock app witch is much more privacy friendly, but i can’t get the token that way, and can’t get it from the vacuum AP because it now change.

i’ll have to send it back for a refund :sob: :

Has anyone have success getting a S6 Pure to connect. I get the token but it shows as unavailable in HA.
I was able to get my pervious S4 to work.

Probably because it’s no longer available to the app since it’s tied to the Roborock app, hopefully there is a better integration coming…

Just got my S6 MaxV – No success :confused:

Got the A token, but not too sure that its the correct and working one… It does not work with the component. (and yes, I double checked that I use the correct IP address :wink: )

The component reports:

2020-06-11 09:26:55 WARNING (MainThread) [homeassistant.helpers.entity] Update of vacuum.xiaomi_vacuum_cleaner is taking over 10 seconds
2020-06-11 09:27:05 ERROR (SyncWorker_9) [miio.miioprotocol] Got error when receiving: timed out
2020-06-11 09:27:05 WARNING (SyncWorker_9) [homeassistant.components.xiaomi_miio.vacuum] Got exception while fetching the state: No response from the device
2020-06-11 09:27:16 WARNING (MainThread) [homeassistant.helpers.entity] Update of vacuum.xiaomi_vacuum_cleaner is taking over 10 seconds
2020-06-11 09:27:26 ERROR (SyncWorker_18) [miio.miioprotocol] Got error when receiving: timed out
2020-06-11 09:27:26 WARNING (SyncWorker_18) [homeassistant.components.xiaomi_miio.vacuum] Got exception while fetching the state: No response from the device
2020-06-11 09:27:37 WARNING (MainThread) [homeassistant.helpers.entity] Update of vacuum.xiaomi_vacuum_cleaner is taking over 10 seconds
2020-06-11 09:27:47 ERROR (SyncWorker_29) [miio.miioprotocol] Got error when receiving: timed out
2020-06-11 09:27:47 WARNING (SyncWorker_29) [homeassistant.components.xiaomi_miio.vacuum] Got exception while fetching the state: No response from the device
2020-06-11 09:27:58 WARNING (MainThread) [homeassistant.helpers.entity] Update of vacuum.xiaomi_vacuum_cleaner is taking over 10 seconds
2020-06-11 09:28:08 ERROR (SyncWorker_2) [miio.miioprotocol] Got error when receiving: timed out
2020-06-11 09:28:08 WARNING (SyncWorker_2) [homeassistant.components.xiaomi_miio.vacuum] Got exception while fetching the state: No response from the device
2020-06-11 09:28:19 WARNING (MainThread) [homeassistant.helpers.entity] Update of vacuum.xiaomi_vacuum_cleaner is taking over 10 seconds
2020-06-11 09:28:29 ERROR (SyncWorker_17) [miio.miioprotocol] Got error when receiving: timed out
2020-06-11 09:28:29 WARNING (SyncWorker_17) [homeassistant.components.xiaomi_miio.vacuum] Got exception while fetching the state: No response from the device

Got the same issue with the S6 MaxV. The logs say “timeout”.

Ive got the S6 MaxV and have tried the following without any success:

The Windows app does indeed report a token, but it does not work. For me it results in “time out” in the log and the vaccum entity is “unavailable”.

2 Likes

self error on my s5 max. Not available. Did you get it working?
wants to use the roborock app, not mi home

I’ve managed to retrieve the token and added my S4 into HA.
Then at the first night, aprox. around 3 o clock it looses connection and is not able to get back up

Got exception while fetching the state: Unable to discover the device 10.1.50.48
Got exception while fetching the state: No response from the device

If I reset the WiFi, get the token I can re-add it, but it will loose connection the following night.
I’m using the RoboRock app, tried the MiHome too. But this didn’t change.

Any ideas?

I have read that using the Roborock app causes the vacuum to be assigned a new token. Don’t use that app (unpair from it), use the Xiaomi one instead. Obviously you will still need to get the latest token, but after that, don’t reconnect to the Roborock app

1 Like

I’ve also tried to add it… I retreived the token, but I got an unavailable Vacuum… @dominicr How did you manage to correctly add it? (S5max here)

I used the following in the configuration.yaml

vacuum:

  - platform: xiaomi_miio
    host: 192.168.90.x
    token: 785xxxxx

Or do I need to use another platform?

hi
which one
s5max ? s6? … etc…

I’m not sure which model was discussed in terms of the Roborock app causing new tokens to be generated but I think it applies to all models…

I have an S5 and only had success retrieving the token using the old xiaomi app method.