To enable developer mode to future integrate in OpenHAB2, go to Settings, About.
No click several times on the version number on the bottom of the screen, until some chinese info appears on screen. After that you shoud get 2 new menu items.
Choose the one before the last one.
In the next window, enable the check box on the first line, save the password in the second line and choose OK (bottom right, chinese).
You should get a chinese JSON popup saying OK and now it is enabled.
Get the OpenHAB 2 JAR binding at https://github.com/octa22/org.openhab.binding.xiaomigateway/releases
Set the password you got on the app.