tinytuya icon indicating copy to clipboard operation
tinytuya copied to clipboard

possibility to interact with unregistered devices

Open dberardo-com opened this issue 6 months ago • 7 comments

i need to access some tuya devices that will never see public internet, nor the user has direct access to them via a smartphone.

is it therefore possible to interact with such devices without prior registration on the tuya cloud or is this basically impossible given the company policy ?

cheers

dberardo-com avatar Jun 17 '25 08:06 dberardo-com

I'm not aware of any way to do this. You need the "local key" to access the device. The "local key" is minted when you register it with the cloud (Tuya).

jasonacox avatar Jun 18 '25 05:06 jasonacox

This is a bit long winded, it may offer a clue, supposed to be about accessing local keys .. Im not familiar with the apps used, its ios, but it may help

https://www.youtube.com/watch?v=HLiaL-Gw0_0

Also this one on an Android, extaracts from smartlife appp

https://www.youtube.com/watch?v=YKvGYXw-_cE

MarkCupitt avatar Jun 18 '25 05:06 MarkCupitt

No, the devices need to be registered with the cloud to get a local key, and they will not accept local connections until they get one.

If they're older devices you might be able to use tuya-cloudcutter to inject the keys yourself, but YMMV.

uzlonewolf avatar Jun 18 '25 14:06 uzlonewolf

@uzlonewolf is correct, devices must always be registered.

I was interested in the options available if you could not access the Cloud, api was locked, free trial ended, whatever, the only other option really is to get them from the SmartLife app, which it turns out is actually possible.

At some ponit, security and privacy considerations may make no cloud access worth considering as a default

https://www.airdroid.com/file-transfer/access-android-data-folder-without-root/ gives some clues

It also appears its possible to get the Smartlife Config file mentioned in the second video I posted above (https://www.youtube.com/watch?v=YKvGYXw-_cE) from a non rooted Android Phone using Shizuku, had a fiddle yesterday and seems like it will work, although it is not as elagent as the Cloud API Access. (Reason I did this is I dont have an available windows machine as per the video)

Don't have a lot of time to spend on it, but if I get a working procedure done, Ill send it up for publication for posterity

MarkCupitt avatar Jun 19 '25 00:06 MarkCupitt

If they're registered in the app and all you want are the local keys then just use tuya-uncover; it supports 30-some apps in addition to SmartLife and when given the -w flag it even spits out a tinytuya-compatible devices.json file.

uzlonewolf avatar Jun 19 '25 03:06 uzlonewolf

thanks for the support, but i actually meant whether there was any OFFICIAL way to activate device within an air-gapped LAN environment.

seems like Tuya requires online activation and thus data privacy might be breached. this is a no-go for my use case.

I am looking for temperature data, i wonder if here is any alternative product which is more open and requires no cloud based activation.

any hints ?

thanks

dberardo-com avatar Jun 19 '25 13:06 dberardo-com

If privacy is a concern, here are some approaches:

  1. Activate your Tuya device on a temporary internet connection (using a VPN and/or VLAN for enhanced privacy). Once activated, you can move it to your home. As long as your home network has the same SSID and password, the device will function without an internet connection. (For the Wi-Fi network that the Tuya device will use, you can block its internet access.)

  2. Use tuya zigbee devise with Z2M.

  3. Matter devices typically don't require an internet connection.

  4. Consider building your own device, for example, using an ESP32.

thanks for the support, but i actually meant whether there was any OFFICIAL way to activate device within an air-gapped LAN environment.

seems like Tuya requires online activation and thus data privacy might be breached. this is a no-go for my use case.

I am looking for temperature data, i wonder if here is any alternative product which is more open and requires no cloud based activation.

any hints ?

thanks

3735943886 avatar Jun 28 '25 01:06 3735943886