I have spend some time debugging the system and finding out how Tuya API is working.
I've tried to find some kind of documentation for this API, but I can't find any.
As I see from the code this library is using several endpoints:
https://px1.tuyaus.com/homeassistant/auth.do
https://px1.tuyaus.com//homeassistant/access.do
https://px1.tuyaus.com//homeassistant/skill
There is homeassistant in the url, so I assume that these endpoints were created especially for this library. At first I thought that this server px1.tuyaus.com is just a middleware made by the author of this library to proxy requests to the officcial Tuya API, but whois info does not confirm this.
From what I saw during playing with this API I think that the official TuaySmart app is using some other API (Using this API I wasn't able to set the exact same values of the brightness that I can set in the official app).
So, my question. What is this API and is there any official documentation for it?
I have just created a pull request to improve how this library is working with brightness ( https://github.com/PaulAnnekov/tuyaha/pull/21 )
I have spend some time debugging the system and finding out how Tuya API is working.
I've tried to find some kind of documentation for this API, but I can't find any.
As I see from the code this library is using several endpoints:
https://px1.tuyaus.com/homeassistant/auth.do
https://px1.tuyaus.com//homeassistant/access.do
https://px1.tuyaus.com//homeassistant/skill
There is
homeassistant
in the url, so I assume that these endpoints were created especially for this library. At first I thought that this serverpx1.tuyaus.com
is just a middleware made by the author of this library to proxy requests to the officcial Tuya API, but whois info does not confirm this.From what I saw during playing with this API I think that the official TuaySmart app is using some other API (Using this API I wasn't able to set the exact same values of the brightness that I can set in the official app).
So, my question. What is this API and is there any official documentation for it?